[llvm] [SLP] NFC. Make InstructionsState more constant. (PR #118609)
Alexey Bataev via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 5 11:38:06 PST 2024
================
@@ -7426,17 +7435,17 @@ bool BoUpSLP::areAltOperandsProfitable(const InstructionsState &S,
unsigned Opcode1 = S.getAltOpcode();
SmallBitVector OpcodeMask(getAltInstrMask(VL, Opcode0, Opcode1));
// If this pattern is supported by the target then consider it profitable.
- if (TTI->isLegalAltInstr(getWidenedType(S.MainOp->getType(), VL.size()),
+ if (TTI->isLegalAltInstr(getWidenedType(S.getMainOp()->getType(), VL.size()),
Opcode0, Opcode1, OpcodeMask))
return true;
SmallVector<ValueList> Operands;
- for (unsigned I : seq<unsigned>(0, S.MainOp->getNumOperands())) {
+ for (unsigned I : seq<unsigned>(0, S.getMainOp()->getNumOperands())) {
----------------
alexey-bataev wrote:
`for (unsigned I : seq<unsigned>(S.getMainOp()->getNumOperands())) {`
https://github.com/llvm/llvm-project/pull/118609
More information about the llvm-commits
mailing list