Skip to content

Commit 7cf26e0

Browse files
committed
[AArch64] Fix -Wunused-function of getLivePhysRegsUpTo in AArch64FrameLowering.cpp (NFC)
/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp:1428:13: error: unused function 'getLivePhysRegsUpTo' [-Werror,-Wunused-function] static void getLivePhysRegsUpTo(MachineInstr &MI, const TargetRegisterInfo &TRI, ^ 1 error generated.
1 parent 7c3c8a1 commit 7cf26e0

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/lib/Target/AArch64/AArch64FrameLowering.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1423,6 +1423,7 @@ static void emitDefineCFAWithFP(MachineFunction &MF, MachineBasicBlock &MBB,
14231423
.setMIFlags(MachineInstr::FrameSetup);
14241424
}
14251425

1426+
#ifndef NDEBUG
14261427
/// Collect live registers from the end of \p MI's parent up to (including) \p
14271428
/// MI in \p LiveRegs.
14281429
static void getLivePhysRegsUpTo(MachineInstr &MI, const TargetRegisterInfo &TRI,
@@ -1434,6 +1435,7 @@ static void getLivePhysRegsUpTo(MachineInstr &MI, const TargetRegisterInfo &TRI,
14341435
reverse(make_range(MI.getIterator(), MBB.instr_end())))
14351436
LiveRegs.stepBackward(MI);
14361437
}
1438+
#endif
14371439

14381440
void AArch64FrameLowering::emitPrologue(MachineFunction &MF,
14391441
MachineBasicBlock &MBB) const {

0 commit comments

Comments
 (0)