71 lines · plain
1# RUN: llc -start-after=livedebugvalues -mtriple=x86_64-apple-darwin -o - %s -filetype=obj \2# RUN: -emit-call-site-info | llvm-dwarfdump - | FileCheck %s -implicit-check-not=call_site_parameter3 4# CHECK: DW_TAG_subprogram5# CHECK: DW_AT_name ("g")6# CHECK: DW_TAG_formal_parameter7# CHECK-NEXT: DW_AT_location (DW_OP_reg17 XMM0)8# CHECK: DW_TAG_subprogram9# CHECK: DW_AT_name ("f")10 11# struct S {12# float w;13# };14# void f(long w, long b);15# void g(struct S s) {16# int w = s.w;17# f(w, w*4);18# }19 20--- |21 define void @g(float %s.coerce) local_unnamed_addr !dbg !20 {22 entry:23 ret void, !dbg !3124 }25 declare !dbg !14 void @f(i64, i64) local_unnamed_addr26 !llvm.module.flags = !{!6, !7, !8, !9}27 !llvm.dbg.cu = !{!10}28 !6 = !{i32 7, !"Dwarf Version", i32 4}29 !7 = !{i32 2, !"Debug Info Version", i32 3}30 !8 = !{i32 1, !"wchar_size", i32 4}31 !9 = !{i32 7, !"PIC Level", i32 2}32 !10 = distinct !DICompileUnit(language: DW_LANG_ObjC, file: !15, producer: "", isOptimized: true, runtimeVersion: 2, emissionKind: FullDebug, enums: !12, nameTableKind: None, sysroot: "/")33 !12 = !{}34 !14 = !DISubprogram(name: "f", scope: !15, file: !15, line: 4, type: !16, flags: DIFlagPrototyped, spFlags: DISPFlagOptimized, retainedNodes: !12)35 !15 = !DIFile(filename: "test.m", directory: "/")36 !16 = !DISubroutineType(types: !17)37 !17 = !{null, !18, !18}38 !18 = !DIBasicType(name: "long int", size: 64, encoding: DW_ATE_signed)39 !20 = distinct !DISubprogram(name: "g", scope: !15, file: !15, line: 5, type: !21, scopeLine: 5, flags: DIFlagPrototyped | DIFlagAllCallsDescribed, spFlags: DISPFlagDefinition | DISPFlagOptimized, unit: !10, retainedNodes: !27)40 !21 = !DISubroutineType(types: !22)41 !22 = !{null, !23}42 !23 = distinct !DICompositeType(tag: DW_TAG_structure_type, name: "S", file: !15, line: 1, size: 32, elements: !24)43 !24 = !{!25}44 !25 = !DIDerivedType(tag: DW_TAG_member, name: "w", scope: !23, file: !15, line: 2, baseType: !26, size: 32)45 !26 = !DIBasicType(name: "float", size: 32, encoding: DW_ATE_float)46 !27 = !{!28, !29}47 !28 = !DILocalVariable(name: "s", arg: 1, scope: !20, file: !15, line: 5, type: !23)48 !29 = !DILocalVariable(name: "w", scope: !20, file: !15, line: 6, type: !30)49 !30 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)50 !31 = !DILocation(line: 0, scope: !20)51name: g52callSites:53 - { bb: 0, offset: 13, fwdArgRegs: 54 - { arg: 1, reg: '$rsi' } }55body: |56 bb.0.entry:57 DBG_VALUE $xmm0, $noreg, !28, !DIExpression(), debug-location !3158 DBG_VALUE $xmm0, $noreg, !28, !DIExpression(), debug-location !3159 frame-setup PUSH64r killed $rbp, implicit-def $rsp, implicit $rsp60 CFI_INSTRUCTION def_cfa_offset 1661 CFI_INSTRUCTION offset $rbp, -1662 $rbp = frame-setup MOV64rr $rsp63 CFI_INSTRUCTION def_cfa_register $rbp64 renamable $eax = nofpexcept CVTTSS2SIrr killed renamable $xmm0, implicit $mxcsr, debug-location !3165 DBG_VALUE $eax, $noreg, !29, !DIExpression(), debug-location !3166 renamable $rdi = MOVSX64rr32 killed renamable $eax, debug-location !3167 renamable $eax = LEA64_32r $noreg, 4, renamable $rdi, 0, $noreg, debug-location !3168 renamable $rsi = MOVSX64rr32 killed renamable $eax, debug-location !3169 $rbp = frame-destroy POP64r implicit-def $rsp, implicit $rsp, debug-location !3170 TAILJMPd64 @f, csr_64, implicit $rsp, implicit $ssp, implicit $rsp, implicit $ssp, implicit $rdi, implicit $rsi, debug-location !3171