Skip to content

Commit a372f44

Browse files
committed
no multiple fi folding
1 parent 82fd0c7 commit a372f44

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

llvm/lib/Target/AMDGPU/SIInstrInfo.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6063,6 +6063,12 @@ bool SIInstrInfo::isOperandLegal(const MachineInstr &MI, unsigned OpIdx,
60636063
!isInlineConstant(Op, InstDesc.operands()[i]) &&
60646064
!Op.isIdenticalTo(*MO))
60656065
return false;
6066+
6067+
// Do not fold a frame index into an instruction that already has a frame
6068+
// index. The frame index handling code doesn't handle fixing up operand
6069+
// constraints if there are multiple indexes.
6070+
if (Op.isFI() && MO->isFI())
6071+
return false;
60666072
}
60676073
} else if (IsInlineConst && ST.hasNoF16PseudoScalarTransInlineConstants() &&
60686074
isF16PseudoScalarTrans(MI.getOpcode())) {

0 commit comments

Comments
 (0)