1 ; RUN: llc < %s -mtriple=x86_64-apple-darwin | FileCheck %s 2 3 ; CHECK-LABEL: .section __LLVM_STACKMAPS,__llvm_stackmaps 4 ; CHECK-NEXT: __LLVM_StackMaps: 5 ; version 6 ; CHECK-NEXT: .byte 1 7 ; reserved 8 ; CHECK-NEXT: .byte 0 9 ; reserved 10 ; CHECK-NEXT: .short 0 11 ; # functions 12 ; CHECK-NEXT: .long 2 13 ; # constants 14 ; CHECK-NEXT: .long 2 15 ; # records 16 ; CHECK-NEXT: .long 2 17 ; function address & stack size 18 ; CHECK-NEXT: .quad _foo 19 ; CHECK-NEXT: .quad 8 20 ; function address & stack size 21 ; CHECK-NEXT: .quad _bar 22 ; CHECK-NEXT: .quad 8 23 24 ; Constants Array: 25 ; CHECK-NEXT: .quad 9223372036854775807 26 ; CHECK-NEXT: .quad -9223372036854775808 27 28 ; Patchpoint ID 29 ; CHECK-NEXT: .quad 0 30 ; Instruction offset 31 ; CHECK-NEXT: .long L{{.*}}-_foo 32 ; reserved 33 ; CHECK-NEXT: .short 0 34 ; # locations 35 ; CHECK-NEXT: .short 1 36 ; ConstantIndex 37 ; CHECK-NEXT: .byte 5 38 ; reserved 39 ; CHECK-NEXT: .byte 8 40 ; Dwarf RegNum 41 ; CHECK-NEXT: .short 0 42 ; Offset 43 ; CHECK-NEXT: .long 0 44 ; padding 45 ; CHECK-NEXT: .short 0 46 ; NumLiveOuts 47 ; CHECK-NEXT: .short 0 48 49 ; CHECK-NEXT: .p2align 3 50 51 declare void @llvm.experimental.stackmap(i64, i32, ...) 52 53 define void @foo() { 54 tail call void (i64, i32, ...) @llvm.experimental.stackmap(i64 0, i32 0, i64 9223372036854775807) 55 ret void 56 } 57 58 ; Patchpoint ID 59 ; CHECK-NEXT: .quad 0 60 ; Instruction Offset 61 ; CHECK-NEXT: .long L{{.*}}-_bar 62 ; reserved 63 ; CHECK-NEXT: .short 0 64 ; # locations 65 ; CHECK-NEXT: .short 1 66 ; ConstantIndex 67 ; CHECK-NEXT: .byte 5 68 ; reserved 69 ; CHECK-NEXT: .byte 8 70 ; Dwarf RegNum 71 ; CHECK-NEXT: .short 0 72 ; Offset 73 ; CHECK-NEXT: .long 1 74 ; padding 75 ; CHECK-NEXT: .short 0 76 ; NumLiveOuts 77 ; CHECK-NEXT: .short 0 78 79 80 define void @bar() { 81 tail call void (i64, i32, ...) @llvm.experimental.stackmap(i64 0, i32 0, i64 -9223372036854775808) 82 ret void 83 } 84