File tree 2 files changed +17
-2
lines changed
2 files changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -59,8 +59,7 @@ bool FinalizeISel::runOnMachineFunction(MachineFunction &MF) {
59
59
60
60
// Set AdjustsStack to true if the instruction selector emits a stack
61
61
// frame setup instruction or a stack aligning inlineasm.
62
- if (MI.getOpcode () == TII->getCallFrameSetupOpcode () ||
63
- MI.isStackAligningInlineAsm ())
62
+ if (TII->isFrameInstr (MI) || MI.isStackAligningInlineAsm ())
64
63
MF.getFrameInfo ().setAdjustsStack (true );
65
64
66
65
// If MI is a pseudo, expand it.
Original file line number Diff line number Diff line change
1
+ ; RUN: llc < %s -mtriple=s390x-linux-gnu -verify-machineinstrs | FileCheck %s
2
+ ;
3
+ ; Test that inserting a new MBB near a call during finalize isel custom
4
+ ; insertion does not cause all frame instructions to be missed. That would
5
+ ; result in a missing to set the AdjustsStack flag.
6
+
7
+ ; CHECK-LABEL: fun
8
+ define void @fun (i1 %cc ) {
9
+ %sel = select i1 %cc , i32 5 , i32 0
10
+ tail call void @input_report_abs (i32 %sel )
11
+ %sel2 = select i1 %cc , i32 6 , i32 1
12
+ tail call void @input_report_abs (i32 %sel2 )
13
+ ret void
14
+ }
15
+
16
+ declare void @input_report_abs (i32 )
You can’t perform that action at this time.
0 commit comments