Skip to content

Commit be00190

Browse files
authored
[TII][X86] Do not schedule frame-setup/frame-destory instructions (llvm#96611)
frame-setup/frame-destroy instruction can not be scheduled around by PostRAScheduler. Their order is critical for SEH.
1 parent 54cb5ca commit be00190

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

llvm/lib/Target/X86/X86InstrInfo.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8832,6 +8832,11 @@ bool X86InstrInfo::isSchedulingBoundary(const MachineInstr &MI,
88328832
Opcode == X86::PLDTILECFGV)
88338833
return true;
88348834

8835+
// Frame setup and destory can't be scheduled around.
8836+
if (MI.getFlag(MachineInstr::FrameSetup) ||
8837+
MI.getFlag(MachineInstr::FrameDestroy))
8838+
return true;
8839+
88358840
return TargetInstrInfo::isSchedulingBoundary(MI, MBB, MF);
88368841
}
88378842

0 commit comments

Comments
 (0)