105 lines · plain
1# Check that subsequent .loc 0 0 directives are collapsed.2 3# RUN: llc -start-before=machine-cp -O2 -filetype=asm -mtriple=x86_64-apple-macosx10.9.0 -o - %s | FileCheck %s4 5# CHECK: Ltmp0:6# CHECK: .loc 1 0 07# CHECK-NOT: .loc 1 0 08# CHECK: .loc 1 37 19 10--- |11 ; ModuleID = '<stdin>'12 source_filename = "<stdin>"13 target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128"14 target triple = "x86_64-apple-macosx10.9.0"15 16 %swift.opaque = type opaque17 %swift.metadata_response = type { ptr, i64 }18 %swift.type = type { i64 }19 20 define hidden swiftcc void @"$S4main1fyyF"() !dbg !5 {21 entry:22 %s1.addr = alloca ptr, align 823 %0 = bitcast ptr %s1.addr to ptr24 store ptr null, ptr %0, align 825 %1 = call swiftcc %swift.metadata_response @"$S16resilient_struct4SizeVMa"(i64 0) #1, !dbg !1026 %2 = extractvalue %swift.metadata_response %1, 0, !dbg !1027 %3 = bitcast ptr %2 to ptr, !dbg !1028 %4 = getelementptr inbounds ptr, ptr %3, i64 -1, !dbg !1029 ret void, !dbg !1230 }31 32 declare swiftcc %swift.metadata_response @"$S16resilient_struct4SizeVMa"(i64)33 34 ; Function Attrs: nounwind35 declare void @llvm.stackprotector(ptr, ptr) #036 37 attributes #0 = { nounwind }38 attributes #1 = { nounwind readnone }39 40 !llvm.dbg.cu = !{!0}41 !llvm.module.flags = !{!3, !4}42 43 !0 = distinct !DICompileUnit(language: DW_LANG_Swift, file: !1, producer: "Swift version 4.2.1-dev effective-3.4.1 (LLVM 4ba03d9389, Clang 78aa734eee, Swift f4134ebef6)", isOptimized: false, runtimeVersion: 4, emissionKind: FullDebug, enums: !2, imports: !2)44 !1 = !DIFile(filename: "struct_resilience.swift", directory: "/Users/jonas/swift")45 !2 = !{}46 !3 = !{i32 2, !"Dwarf Version", i32 4}47 !4 = !{i32 2, !"Debug Info Version", i32 3}48 !5 = distinct !DISubprogram(name: "f", linkageName: "$S4main1fyyF", scope: !0, file: !6, line: 23, type: !7, scopeLine: 23, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !2)49 !6 = !DIFile(filename: "struct_resilience.swift", directory: "/Users/jonas/swift/swift/test/DebugInfo")50 !7 = !DISubroutineType(types: !8)51 !8 = !{!9}52 !9 = !DICompositeType(tag: DW_TAG_structure_type, name: "$SytD", file: !6, elements: !2, runtimeLang: DW_LANG_Swift, identifier: "$SytD")53 !10 = !DILocation(line: 0, scope: !11)54 !11 = distinct !DILexicalBlock(scope: !5, file: !6, line: 23, column: 10)55 !12 = !DILocation(line: 37, column: 1, scope: !11)56 57...58---59name: '$S4main1fyyF'60alignment: 1661exposesReturnsTwice: false62legalized: false63regBankSelected: false64selected: false65failedISel: false66tracksRegLiveness: true67hasWinCFI: false68registers: []69liveins: []70frameInfo:71 isFrameAddressTaken: false72 isReturnAddressTaken: false73 hasStackMap: false74 hasPatchPoint: false75 stackSize: 076 offsetAdjustment: 077 maxAlignment: 878 adjustsStack: true79 hasCalls: true80 stackProtector: ''81 maxCallFrameSize: 429496729582 cvBytesOfCalleeSavedRegisters: 083 hasOpaqueSPAdjustment: false84 hasVAStart: false85 hasMustTailInVarArgFunc: false86 localFrameSize: 087 savePoint: []88 restorePoint: []89fixedStack: []90stack:91 - { id: 0, name: s1.addr, type: default, offset: 0, size: 8, alignment: 8,92 stack-id: default, callee-saved-register: '', callee-saved-restored: true,93 debug-info-variable: '', debug-info-expression: '', debug-info-location: '' }94constants: []95body: |96 bb.0.entry:97 MOV64mi32 %stack.0.s1.addr, 1, $noreg, 0, $noreg, 0 :: (store (s64) into %ir.0)98 ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp, debug-location !1099 dead $edi = MOV32r0 implicit-def dead $eflags, implicit-def $rdi, debug-location !10100 CALL64pcrel32 @"$S16resilient_struct4SizeVMa", csr_64, implicit $rsp, implicit $ssp, implicit killed $rdi, implicit-def $rsp, implicit-def $ssp, implicit-def dead $rax, implicit-def dead $rdx, debug-location !10101 ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp, debug-location !10102 RET 0, debug-location !12103 104...105