Home | History | Annotate | Download | only in CodeGen

Lines Matching refs:COPY

55 //     b = copy A <-- cross-bank copy
56 // C = copy b <-- cross-bank copy
58 // b = copy A <-- cross-bank copy
59 // C = copy A <-- same-bank copy
62 // b = bitcast A <-- cross-bank copy
63 // C = bitcast b <-- cross-bank copy
65 // b = bitcast A <-- cross-bank copy
66 // C = copy A <-- same-bank copy
95 DisableAdvCopyOpt("disable-adv-copy-opt", cl::Hidden, cl::init(true),
96 cl::desc("Disable advanced copy optimization"));
146 /// a (chain of) copy related instructions.
150 /// def = COPY src.
155 /// def = COPY v2.sub0
157 /// Using a ValueTracker for def = COPY v2.sub0 will give the following
160 /// Then, def can be rewritten into def = COPY v0.
173 /// bails on everything that is not a copy or a bitcast.
186 /// \brief Specialized version of getNextSource for Copy instructions.
209 /// through complex instructions. By default (false), it handles only copy
253 /// optimizeExtInstr - If instruction is a copy-like instruction, i.e. it reads
329 // %reg1027 = COPY %reg1025:4
334 // the COPY here, it will give us the value after the <sext>, not the
362 std::copy(ExtendedUses.begin(), ExtendedUses.end(),
392 MachineInstr *Copy = BuildMI(*UseMBB, UseMI, UseMI->getDebugLoc(),
393 TII->get(TargetOpcode::COPY), NewVR)
397 Copy->getOperand(0).setSubReg(SubIdx);
398 Copy->getOperand(0).setIsUndef();
476 // Plain copy.
480 /// \brief Get the index of the definition and source for \p Copy
482 /// \pre Copy.isCopy() or Copy.isBitcast().
483 /// \return True if the Copy instruction has only one register source
486 static bool getCopyOrBitcastDefUseIdx(const MachineInstr &Copy,
488 assert((Copy.isCopy() || Copy.isBitcast()) && "Wrong operation type.");
489 if (Copy.isCopy()) {
490 // Copy instruction are supposed to be: Def = Src.
491 if (Copy.getDesc().getNumOperands() != 2)
495 assert(Copy.getOperand(DefIdx).isDef() && "Use comes before def!");
500 if (Copy.getDesc().getNumDefs() != 1)
503 SrcIdx = Copy.getDesc().getNumOperands();
505 const MachineOperand &MO = Copy.getOperand(OpIdx);
518 /// \brief Optimize a copy or bitcast instruction to avoid cross
519 /// register bank copy. The optimization looks through a chain of
525 /// friendly. This optimization does not remove any copy as it may
528 /// \pre \p MI is a Copy (MI->isCopy() is true)
571 // If this source does not incur a cross register bank copy, use it.
580 // Rewrite the copy to avoid a cross register bank penalty.
584 TII->get(TargetOpcode::COPY), NewVR)
787 // Copy instruction are supposed to be: Def = Src.
805 // Bail if there are effects that a plain copy will not expose.