Skip to content

Commit 6b26dd5

Browse files
authored
[RISCV][GISel] Remove unneeded code from RISCVCallLowering::canLowerReturn. NFC (#162144)
This code calculates FirstMaskArgument which used to be an argument to RISCV_CC, but was removed over a year ago.
1 parent f642236 commit 6b26dd5

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

llvm/lib/Target/RISCV/GISel/RISCVCallLowering.cpp

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -439,18 +439,6 @@ bool RISCVCallLowering::canLowerReturn(MachineFunction &MF,
439439
CCState CCInfo(CallConv, IsVarArg, MF, ArgLocs,
440440
MF.getFunction().getContext());
441441

442-
const RISCVSubtarget &Subtarget = MF.getSubtarget<RISCVSubtarget>();
443-
444-
std::optional<unsigned> FirstMaskArgument = std::nullopt;
445-
// Preassign the first mask argument.
446-
if (Subtarget.hasVInstructions()) {
447-
for (const auto &ArgIdx : enumerate(Outs)) {
448-
MVT ArgVT = MVT::getVT(ArgIdx.value().Ty);
449-
if (ArgVT.isVector() && ArgVT.getVectorElementType() == MVT::i1)
450-
FirstMaskArgument = ArgIdx.index();
451-
}
452-
}
453-
454442
for (unsigned I = 0, E = Outs.size(); I < E; ++I) {
455443
MVT VT = MVT::getVT(Outs[I].Ty);
456444
if (CC_RISCV(I, VT, VT, CCValAssign::Full, Outs[I].Flags[0], CCInfo,

0 commit comments

Comments
 (0)