[llvm-branch-commits] [llvm] AMDGPU: Mark dead carry-out when rewriting scalar carry op to VALU (PR #225738)

Pankaj Dwivedi via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Wed Sep 23 05:58:43 PDT 2026


================
@@ -8920,11 +8920,14 @@ void SIInstrInfo::moveToVALUImpl(
   // Remove any references to SCC. Vector instructions can't read from it, and
   // We're just about to add the implicit use / defs of VCC, and we don't want
   // both.
+  bool DeadSCCDef = false;
   for (MachineOperand &Op : Inst.implicit_operands()) {
     if (Op.getReg() == AMDGPU::SCC) {
       // Only propagate through live-def of SCC.
       if (Op.isDef() && !Op.isDead())
----------------
PankajDwivedi-25 wrote:

NIT: we are making Op.isDef() check twice, Can we make it nested?

https://github.com/llvm/llvm-project/pull/225738


More information about the llvm-branch-commits mailing list