/external/swiftshader/third_party/LLVM/unittests/Transforms/Utils/ |
Local.cpp | 29 PHINode *phi = builder.CreatePHI(Type::getInt32Ty(C), 2); local 35 phi->addIncoming(phi, bb0); 36 phi->addIncoming(phi, bb1); 38 // The PHI will be removed 39 EXPECT_TRUE(RecursivelyDeleteDeadPHINode(phi)); 46 phi = builder.CreatePHI(Type::getInt32Ty(C), 0); 48 EXPECT_TRUE(RecursivelyDeleteDeadPHINode(phi)); 51 phi = builder.CreatePHI(Type::getInt32Ty(C), 0) [all...] |
/external/v8/src/crankshaft/ |
hydrogen-infer-types.cc | 33 HPhi* phi = block->phis()->at(j); local 34 worklist_.Add(phi, zone()); 35 in_worklist_.Add(phi->id());
|
hydrogen-redundant-phi.cc | 5 #include "src/crankshaft/hydrogen-redundant-phi.h" 47 HPhi* phi = phis->at(i); local 48 if (phi->CheckFlag(HValue::kIsDead)) continue; // Already replaced. 50 HValue* replacement = phi->GetRedundantReplacement(); 52 phi->SetFlag(HValue::kIsDead); 53 for (HUseIterator it(phi->uses()); !it.Done(); it.Advance()) { 56 // Iterate again if used in another non-dead phi. 59 phi->block()->RemovePhi(phi);
|
hydrogen-dce.cc | 58 HPhi* phi = block->phis()->at(j); local 59 if (phi->CannotBeEliminated()) MarkLive(phi, &worklist); 85 HPhi* phi = block->phis()->at(j); local 86 if (!phi->CheckFlag(HValue::kIsLive)) { 87 worklist.Add(phi, zone()); 89 phi->ClearFlag(HValue::kIsLive); 94 // Process phis separately to avoid simultaneously mutating the phi list. 96 HPhi* phi = worklist.RemoveLast(); local 97 HBasicBlock* block = phi->block() [all...] |
hydrogen-infer-representation.cc | 21 // (1) Initialize bit vectors and count real uses. Each phi gets a 34 // phi is connected to another phi if its value is used either directly or 42 HPhi* phi = phi_list->at(i); local 43 for (HUseIterator it(phi->uses()); !it.Done(); it.Advance()) { 97 // Simplify constant phi inputs where possible. 103 // Use the phi reachability information from step 2 to 104 // sum up the non-phi use counts of all connected phis. 106 HPhi* phi = phi_list->at(i); local 112 if (index != i) phi->AddNonPhiUsesFrom(it_use); // Don't count twice 143 HPhi* phi = phis->at(j); local [all...] |
hydrogen-osr.cc | 97 HPhi* phi = phis->at(j); local 98 if (phi->HasMergedIndex()) { 99 osr_values_->at(phi->merged_index())->set_incoming_value(phi);
|
hydrogen-uint32-analysis.cc | 84 // There is a phi use of this value from a phi that is not yet 102 // There is a phi use of this value from a phi that is not yet 115 // Check if all operands to the given phi are marked with kUint32 flag. 116 bool HUint32AnalysisPhase::CheckPhiOperands(HPhi* phi) { 117 if (!phi->CheckFlag(HInstruction::kUint32)) { 118 // This phi is not uint32 safe. No need to check operands. 122 for (int j = 0; j < phi->OperandCount(); j++) { 123 HValue* operand = phi->OperandAt(j) 177 HPhi* phi = phis_[i]; local 192 HPhi* phi = worklist.RemoveLast(); local 201 HPhi* phi = phis_[i]; local [all...] |
/art/compiler/optimizing/ |
live_ranges_test.cc | 150 * 22: phi 174 // Last use is the phi at the return block so instruction is live until 190 // Last use is the phi at the return block. 194 // Test for the phi. 220 * 14: phi 253 // Last use is the loop phi so instruction is live until 274 // Test for the phi. 298 * 10: phi 309 * We want to make sure the phi at 10 has a lifetime hole after the add at 20. 333 // Last use is the loop phi so instruction is live unti 339 HPhi* phi = liveness.GetInstructionFromSsaIndex(1)->AsPhi(); local 443 HPhi* phi = liveness.GetInstructionFromSsaIndex(4)->AsPhi(); local [all...] |
ssa_phi_elimination.cc | 36 // Add to the worklist phis referenced by non-phi instructions. 39 HPhi* phi = inst_it.Current()->AsPhi(); local 40 if (phi->IsDead()) { 44 bool keep_alive = (graph_->IsDebuggable() && phi->HasEnvironmentUses()); 46 for (const HUseListNode<HInstruction*>& use : phi->GetUses()) { 55 worklist_.push_back(phi); 57 phi->SetDead(); 59 initially_live.insert(phi); 65 // Process the worklist by propagating liveness to phi inputs. 67 HPhi* phi = worklist_.back() local 89 HPhi* phi; local 133 HPhi* phi = worklist_.back(); local [all...] |
select_generator.cc | 54 // Returns nullptr if `block` has either no phis or there is more than one phi 55 // with different inputs at `index1` and `index2`. Otherwise returns that phi. 61 HPhi* phi = it.Current()->AsPhi(); local 62 if (phi->InputAt(index1) != phi->InputAt(index2)) { 64 // First phi with different inputs for the two indices found. 65 select_phi = phi; 111 HPhi* phi = GetSingleChangedPhi(merge_block, predecessor_index_true, predecessor_index_false); local 112 if (phi == nullptr) { 115 HInstruction* true_value = phi->InputAt(predecessor_index_true) [all...] |
/external/apache-commons-math/src/main/java/org/apache/commons/math/optimization/fitting/ |
HarmonicFunction.java | 23 /** Harmonic function of the form <code>f (t) = a cos (ω t + φ)</code>. 35 /** Phase φ. */ 36 private final double phi; field in class:HarmonicFunction 41 * @param phi phase 43 public HarmonicFunction(double a, double omega, double phi) { 46 this.phi = phi; 51 return a * FastMath.cos(omega * x + phi); 56 return new HarmonicFunction(a * omega, omega, phi + FastMath.PI / 2); 73 /** Get the phase φ [all...] |
/external/libvncserver/test/ |
copyrecttest.c | 22 double r,phi=0; local 38 phi=0; 41 phi+=0.02; 42 if(phi>2*M_PI) 43 phi-=2*M_PI; 45 x=width*(0.5+cos(phi)*r); 46 y=height*(0.5+sin(phi)*r); 48 unsigned int dx=width*0.5*(1-cos(phi)*r)-x, 49 dy=height*0.5*(1-sin(phi)*r)-y;
|
/external/llvm/unittests/Transforms/Utils/ |
Local.cpp | 29 PHINode *phi = builder.CreatePHI(Type::getInt32Ty(C), 2); local 35 phi->addIncoming(phi, bb0); 36 phi->addIncoming(phi, bb1); 38 // The PHI will be removed 39 EXPECT_TRUE(RecursivelyDeleteDeadPHINode(phi)); 46 phi = builder.CreatePHI(Type::getInt32Ty(C), 0); 48 EXPECT_TRUE(RecursivelyDeleteDeadPHINode(phi)); 51 phi = builder.CreatePHI(Type::getInt32Ty(C), 0) [all...] |
/external/mesa3d/src/compiler/nir/ |
nir_opt_conditional_discard.c | 60 * make sure no subsequent phi nodes point at this if. 66 nir_phi_instr *phi = nir_instr_as_phi(instr); local 68 nir_foreach_phi_src(phi_src, phi) {
|
nir_opt_remove_phis.c | 52 * This is a pass for removing phi nodes that look like: 53 * a = phi(b, b, b, ...) 58 * phi node's predecessors, which means it must dominate the phi node as well 59 * as all of the phi node's uses. In essence, the phi node acts as a copy 60 * instruction. b can't be another phi node in the same block, since the only 61 * time when phi nodes can source other phi nodes defined in the same block is 62 * at the loop header, and in that case one of the sources of the phi has t 75 nir_phi_instr *phi = nir_instr_as_phi(instr); local [all...] |
nir_opt_peephole_select.c | 39 * phi 41 * phi 131 /* The only uses of this definition must be phi's in the successor */ 179 * statement containing only moves to phi nodes in this block. We can 180 * just remove that entire CF node and replace all of the phi nodes with 206 nir_phi_instr *phi = nir_instr_as_phi(instr); local 212 assert(exec_list_length(&phi->srcs) == 2); 213 nir_foreach_phi_src(src, phi) { 222 phi->dest.ssa.num_components, 223 phi->dest.ssa.bit_size, phi->dest.ssa.name) [all...] |
nir_propagate_invariant.c | 129 nir_phi_instr *phi = nir_instr_as_phi(instr); local 130 if (!dest_is_invariant(&phi->dest, invariants)) 133 nir_foreach_phi_src(src, phi) {
|
nir_liveness.c | 34 * This liveness pass treats phi nodes as being melded to the space between 35 * blocks so that the destinations of a phi are in the livein of the block 40 * SSA value may not dominate a use is if the use is in a phi node and the 41 * uses in phi no are in the live-out of the corresponding predecessor 42 * block but not in the live-in of the block containing the phi node. 113 * Phi nodes exist "between" blocks and all the phi nodes at the start of a 130 nir_phi_instr *phi = nir_instr_as_phi(instr); local 132 assert(phi->dest.is_ssa); 133 set_ssa_def_dead(&phi->dest.ssa, live) 139 nir_phi_instr *phi = nir_instr_as_phi(instr); local [all...] |
nir_lower_indirect_derefs.c | 74 /* We're a load. We need to insert a phi node */ 75 nir_phi_instr *phi = nir_phi_instr_create(b->shader); local 77 nir_ssa_dest_init(&phi->instr, &phi->dest, 80 nir_phi_src *src0 = ralloc(phi, nir_phi_src); 83 exec_list_push_tail(&phi->srcs, &src0->node); 85 nir_phi_src *src1 = ralloc(phi, nir_phi_src); 88 exec_list_push_tail(&phi->srcs, &src1->node); 90 nir_builder_instr_insert(b, &phi->instr); 91 *dest = &phi->dest.ssa [all...] |
nir_opt_copy_propagate.c | 118 /* Don't let copy propagation land us with a phi that has more 123 nir_phi_instr *phi = nir_instr_as_phi(parent_instr); local 124 assert(phi->dest.is_ssa); 125 if (phi->dest.ssa.num_components !=
|
/external/r8/src/test/java/com/android/tools/r8/smali/ |
CatchSuccessorFallthroughTest.java | 13 import com.android.tools.r8.ir.code.Phi; 73 // Find the exit block and assert that the value is a phi merging the exceptional edge 79 // Check it has one phi with two operands / two predecessors. 84 // Next we find and check that the phi values come from the expected predecessor. 87 Phi phi = block.getPhis().get(0); local 88 for (Value operand : phi.getOperands()) {
|
/external/llvm/lib/CodeGen/ |
UnreachableBlockElim.cpp | 182 // Cleanup PHI nodes. 185 // Prune unneeded PHI entries. 188 MachineBasicBlock::iterator phi = BB->begin(); local 189 while (phi != BB->end() && phi->isPHI()) { 190 for (unsigned i = phi->getNumOperands() - 1; i >= 2; i-=2) 191 if (!preds.count(phi->getOperand(i).getMBB())) { 192 phi->RemoveOperand(i); 193 phi->RemoveOperand(i-1); 197 if (phi->getNumOperands() == 3) [all...] |
/external/ltp/testcases/open_posix_testsuite/functional/semaphores/ |
sem_philosopher.c | 119 pthread_t phi[PH_NUM]; local 144 pthread_create(&phi[i], NULL, (void *)philosopher, &PhID[i]); 148 pthread_join(phi[i], NULL);
|
/external/mesa3d/src/gallium/drivers/freedreno/ir3/ |
ir3_nir_lower_if_else.c | 74 /* The only uses of this definition must be phi's in the 114 * the end of the block w/ a phi.. 133 nir_phi_instr *phi = nir_instr_as_phi(instr); local 134 if (!valid_dest(block, &phi->dest)) 212 /* If the block is empty, then it certainly doesn't have any phi nodes, 245 * statement containing only moves to phi nodes in this block. We can 246 * just remove that entire CF node and replace all of the phi nodes with 266 nir_phi_instr *phi = nir_instr_as_phi(instr); local 272 assert(exec_list_length(&phi->srcs) == 2); 273 nir_foreach_phi_src(src, phi) { [all...] |
/external/swiftshader/third_party/LLVM/lib/CodeGen/ |
UnreachableBlockElim.cpp | 175 // Cleanup PHI nodes. 178 // Prune unneeded PHI entries. 181 MachineBasicBlock::iterator phi = BB->begin(); local 182 while (phi != BB->end() && phi->isPHI()) { 183 for (unsigned i = phi->getNumOperands() - 1; i >= 2; i-=2) 184 if (!preds.count(phi->getOperand(i).getMBB())) { 185 phi->RemoveOperand(i); 186 phi->RemoveOperand(i-1); 190 if (phi->getNumOperands() == 3) [all...] |