43 lines · plain
1# RUN: llc -mtriple=x86_64 -run-pass none -o - %s | FileCheck %s2# This test ensures that the MIR parser parses heap alloc markers correctly.3 4--- |5 declare ptr @f(i32) nounwind6 7 define i32 @test(i32 %x) nounwind {8 entry:9 call ptr @f(i32 %x), !heapallocsite !210 ret i32 poison11 }12 13 !llvm.dbg.cu = !{!0}14 !llvm.module.flags = !{!3, !4}15 16 !0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, nameTableKind: None)17 !1 = !DIFile(filename: "test.ll", directory: "")18 !2 = !{}19 !3 = !{i32 2, !"Debug Info Version", i32 3}20 !4 = !{i32 1, !"wchar_size", i32 2}21 22...23---24name: test25# CHECK-LABEL: name: test26tracksRegLiveness: true27frameInfo:28 hasCalls: true29body: |30 bb.0.entry:31 liveins: $ecx32 33 %0:gr32 = COPY $ecx34 ADJCALLSTACKDOWN64 32, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp35 $ecx = COPY %036 CALL64pcrel32 @f, csr_win64, implicit $rsp, implicit $ssp, implicit $ecx, implicit-def $rsp, implicit-def $ssp, implicit-def dead $rax, heap-alloc-marker !237 ; CHECK: CALL64pcrel32 @f, {{.*}} heap-alloc-marker !238 ADJCALLSTACKUP64 32, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp39 $eax = MOV32r0 implicit-def dead $eflags40 RET 0, killed $eax41 42...43