1 ; RUN: llc < %s -mtriple=x86_64-pc-mingw32 | FileCheck %s -check-prefix=WIN64
5 declare i32 @personality(...)
7 ; Check for 'nop' between the last call and the epilogue.
8 define void @foo1() personality i32 (...)* @personality {
18 %1 = landingpad { i8*, i32 } cleanup
19 resume { i8*, i32 } %1
22 ; WIN64: .seh_proc foo1
25 ; WIN64: addq ${{[0-9]+}}, %rsp
27 ; Check for 'ud2' after noreturn call
28 ; WIN64: callq _Unwind_Resume
33 ; Check it still works when blocks are reordered.
34 @something = global i32 0
35 define void @foo2(i1 zeroext %cond ) {
36 br i1 %cond, label %a, label %b, !prof !0
42 store i32 0, i32* @something
47 !0 = !{!"branch_weights", i32 100, i32 0}
51 ; WIN64: addq ${{[0-9]+}}, %rsp
55 ; Check nop is not emitted when call is not adjacent to epilogue.
64 ; WIN64: addq ${{[0-9]+}}, %rsp