xref: /aosp_15_r20/external/llvm/test/DebugInfo/Generic/2010-05-03-OriginDIE.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker
2*9880d681SAndroid Build Coastguard Worker;RUN: llc < %s -o /dev/null
3*9880d681SAndroid Build Coastguard Worker;Radar 7937109
4*9880d681SAndroid Build Coastguard Worker
5*9880d681SAndroid Build Coastguard Worker%struct.anon = type { i64, i32, i32, i32, [1 x i32] }
6*9880d681SAndroid Build Coastguard Worker%struct.gpm_t = type { i32, i8*, [16 x i8], i32, i64, i64, i64, i64, i64, i64, i32, i16, i16, [8 x %struct.gpmr_t] }
7*9880d681SAndroid Build Coastguard Worker%struct.gpmr_t = type { [48 x i8], [48 x i8], [16 x i8], i64, i64, i64, i64, i16 }
8*9880d681SAndroid Build Coastguard Worker%struct.gpt_t = type { [8 x i8], i32, i32, i32, i32, i64, i64, i64, i64, [16 x i8], %struct.anon }
9*9880d681SAndroid Build Coastguard Worker
10*9880d681SAndroid Build Coastguard Worker@llvm.used = appending global [1 x i8*] [i8* bitcast (void (%struct.gpm_t*, %struct.gpt_t*)* @gpt2gpm to i8*)], section "llvm.metadata" ; <[1 x i8*]*> [#uses=0]
11*9880d681SAndroid Build Coastguard Worker
12*9880d681SAndroid Build Coastguard Workerdefine fastcc void @gpt2gpm(%struct.gpm_t* %gpm, %struct.gpt_t* %gpt) nounwind optsize ssp {
13*9880d681SAndroid Build Coastguard Workerentry:
14*9880d681SAndroid Build Coastguard Worker  %data_addr.i18 = alloca i64, align 8            ; <i64*> [#uses=1]
15*9880d681SAndroid Build Coastguard Worker  %data_addr.i17 = alloca i64, align 8            ; <i64*> [#uses=2]
16*9880d681SAndroid Build Coastguard Worker  %data_addr.i16 = alloca i64, align 8            ; <i64*> [#uses=0]
17*9880d681SAndroid Build Coastguard Worker  %data_addr.i15 = alloca i32, align 4            ; <i32*> [#uses=0]
18*9880d681SAndroid Build Coastguard Worker  %data_addr.i = alloca i64, align 8              ; <i64*> [#uses=0]
19*9880d681SAndroid Build Coastguard Worker  %0 = getelementptr inbounds %struct.gpm_t, %struct.gpm_t* %gpm, i32 0, i32 2, i32 0 ; <i8*> [#uses=1]
20*9880d681SAndroid Build Coastguard Worker  %1 = getelementptr inbounds %struct.gpt_t, %struct.gpt_t* %gpt, i32 0, i32 9, i32 0 ; <i8*> [#uses=1]
21*9880d681SAndroid Build Coastguard Worker  call void @uuid_LtoB(i8* %0, i8* %1) nounwind, !dbg !0
22*9880d681SAndroid Build Coastguard Worker  %a9 = load volatile i64, i64* %data_addr.i18, align 8 ; <i64> [#uses=1]
23*9880d681SAndroid Build Coastguard Worker  %a10 = call i64 @llvm.bswap.i64(i64 %a9) nounwind ; <i64> [#uses=1]
24*9880d681SAndroid Build Coastguard Worker  %a11 = getelementptr inbounds %struct.gpt_t, %struct.gpt_t* %gpt, i32 0, i32 8, !dbg !7 ; <i64*> [#uses=1]
25*9880d681SAndroid Build Coastguard Worker  %a12 = load i64, i64* %a11, align 4, !dbg !7         ; <i64> [#uses=1]
26*9880d681SAndroid Build Coastguard Worker  call void @llvm.dbg.declare(metadata i64* %data_addr.i17, metadata !8, metadata !DIExpression()) nounwind, !dbg !14
27*9880d681SAndroid Build Coastguard Worker  store i64 %a12, i64* %data_addr.i17, align 8
28*9880d681SAndroid Build Coastguard Worker  call void @llvm.dbg.value(metadata !6, i64 0, metadata !15, metadata !DIExpression()) nounwind, !dbg !DILocation(scope: !16)
29*9880d681SAndroid Build Coastguard Worker  call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !19, metadata !DIExpression()) nounwind, !dbg !DILocation(scope: !16)
30*9880d681SAndroid Build Coastguard Worker  call void @llvm.dbg.declare(metadata !6, metadata !23, metadata !DIExpression()) nounwind, !dbg !DILocation(scope: !24)
31*9880d681SAndroid Build Coastguard Worker  call void @llvm.dbg.value(metadata i64* %data_addr.i17, i64 0, metadata !34, metadata !DIExpression(DW_OP_deref)) nounwind, !dbg !DILocation(scope: !24)
32*9880d681SAndroid Build Coastguard Worker  %a13 = load volatile i64, i64* %data_addr.i17, align 8 ; <i64> [#uses=1]
33*9880d681SAndroid Build Coastguard Worker  %a14 = call i64 @llvm.bswap.i64(i64 %a13) nounwind ; <i64> [#uses=2]
34*9880d681SAndroid Build Coastguard Worker  %a15 = add i64 %a10, %a14, !dbg !7              ; <i64> [#uses=1]
35*9880d681SAndroid Build Coastguard Worker  %a16 = sub i64 %a15, %a14                       ; <i64> [#uses=1]
36*9880d681SAndroid Build Coastguard Worker  %a17 = getelementptr inbounds %struct.gpm_t, %struct.gpm_t* %gpm, i32 0, i32 5, !dbg !7 ; <i64*> [#uses=1]
37*9880d681SAndroid Build Coastguard Worker  store i64 %a16, i64* %a17, align 4, !dbg !7
38*9880d681SAndroid Build Coastguard Worker  ret void, !dbg !7
39*9880d681SAndroid Build Coastguard Worker}
40*9880d681SAndroid Build Coastguard Worker
41*9880d681SAndroid Build Coastguard Workerdeclare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
42*9880d681SAndroid Build Coastguard Worker
43*9880d681SAndroid Build Coastguard Workerdeclare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone
44*9880d681SAndroid Build Coastguard Worker
45*9880d681SAndroid Build Coastguard Workerdeclare i32 @llvm.bswap.i32(i32) nounwind readnone
46*9880d681SAndroid Build Coastguard Worker
47*9880d681SAndroid Build Coastguard Workerdeclare i64 @llvm.bswap.i64(i64) nounwind readnone
48*9880d681SAndroid Build Coastguard Worker
49*9880d681SAndroid Build Coastguard Workerdeclare void @uuid_LtoB(i8*, i8*)
50*9880d681SAndroid Build Coastguard Worker
51*9880d681SAndroid Build Coastguard Worker!llvm.dbg.cu = !{!4}
52*9880d681SAndroid Build Coastguard Worker!llvm.module.flags = !{!41}
53*9880d681SAndroid Build Coastguard Worker!0 = !DILocation(line: 808, scope: !1)
54*9880d681SAndroid Build Coastguard Worker!1 = distinct !DILexicalBlock(line: 807, column: 0, file: !39, scope: !2)
55*9880d681SAndroid Build Coastguard Worker!2 = distinct !DISubprogram(name: "gpt2gpm", linkageName: "gpt2gpm", line: 807, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, unit: !4, file: !39, scope: null, type: !5)
56*9880d681SAndroid Build Coastguard Worker!3 = !DIFile(filename: "G.c", directory: "/tmp")
57*9880d681SAndroid Build Coastguard Worker!4 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "llvm-gcc", isOptimized: true, emissionKind: FullDebug, file: !39, enums: !18, retainedTypes: !18)
58*9880d681SAndroid Build Coastguard Worker!5 = !DISubroutineType(types: !6)
59*9880d681SAndroid Build Coastguard Worker!6 = !{null}
60*9880d681SAndroid Build Coastguard Worker!7 = !DILocation(line: 810, scope: !1)
61*9880d681SAndroid Build Coastguard Worker!8 = !DILocalVariable(name: "data", line: 201, arg: 1, scope: !9, file: !10, type: !11)
62*9880d681SAndroid Build Coastguard Worker!9 = distinct !DISubprogram(name: "_OSSwapInt64", linkageName: "_OSSwapInt64", line: 202, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, unit: !4, file: !10, scope: null, type: !5)
63*9880d681SAndroid Build Coastguard Worker!10 = !DIFile(filename: "OSByteOrder.h", directory: "/usr/include/libkern/ppc")
64*9880d681SAndroid Build Coastguard Worker!11 = !DIDerivedType(tag: DW_TAG_typedef, name: "uint64_t", line: 59, file: !36, scope: !3, baseType: !13)
65*9880d681SAndroid Build Coastguard Worker!12 = !DIFile(filename: "stdint.h", directory: "/usr/4.2.1/include")
66*9880d681SAndroid Build Coastguard Worker!13 = !DIBasicType(tag: DW_TAG_base_type, name: "long long unsigned int", size: 64, align: 64, encoding: DW_ATE_unsigned)
67*9880d681SAndroid Build Coastguard Worker!14 = !DILocation(line: 202, scope: !9, inlinedAt: !7)
68*9880d681SAndroid Build Coastguard Worker!15 = !DILocalVariable(name: "base", line: 92, arg: 2, scope: !16, file: !10, type: !17)
69*9880d681SAndroid Build Coastguard Worker!16 = distinct !DISubprogram(name: "OSReadSwapInt64", linkageName: "OSReadSwapInt64", line: 95, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, unit: !4, file: !38, scope: null, type: !5)
70*9880d681SAndroid Build Coastguard Worker!17 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !39, scope: !3, baseType: null)
71*9880d681SAndroid Build Coastguard Worker!18 = !{}
72*9880d681SAndroid Build Coastguard Worker!19 = !DILocalVariable(name: "byteOffset", line: 94, arg: 3, scope: !16, file: !10, type: !20)
73*9880d681SAndroid Build Coastguard Worker!20 = !DIDerivedType(tag: DW_TAG_typedef, name: "uintptr_t", line: 114, file: !37, scope: !3, baseType: !22)
74*9880d681SAndroid Build Coastguard Worker!21 = !DIFile(filename: "types.h", directory: "/usr/include/ppc")
75*9880d681SAndroid Build Coastguard Worker!22 = !DIBasicType(tag: DW_TAG_base_type, name: "long unsigned int", size: 32, align: 32, encoding: DW_ATE_unsigned)
76*9880d681SAndroid Build Coastguard Worker!23 = !DILocalVariable(name: "u", line: 100, scope: !24, file: !10, type: !25)
77*9880d681SAndroid Build Coastguard Worker!24 = distinct !DILexicalBlock(line: 95, column: 0, file: !38, scope: !16)
78*9880d681SAndroid Build Coastguard Worker!25 = !DICompositeType(tag: DW_TAG_union_type, line: 97, size: 64, align: 64, file: !38, scope: !16, elements: !26)
79*9880d681SAndroid Build Coastguard Worker!26 = !{!27, !28}
80*9880d681SAndroid Build Coastguard Worker!27 = !DIDerivedType(tag: DW_TAG_member, name: "u64", line: 98, size: 64, align: 64, file: !38, scope: !25, baseType: !11)
81*9880d681SAndroid Build Coastguard Worker!28 = !DIDerivedType(tag: DW_TAG_member, name: "u32", line: 99, size: 64, align: 32, file: !38, scope: !25, baseType: !29)
82*9880d681SAndroid Build Coastguard Worker!29 = !DICompositeType(tag: DW_TAG_array_type, size: 64, align: 32, file: !39, scope: !3, baseType: !30, elements: !32)
83*9880d681SAndroid Build Coastguard Worker!30 = !DIDerivedType(tag: DW_TAG_typedef, name: "uint32_t", line: 55, file: !36, scope: !3, baseType: !31)
84*9880d681SAndroid Build Coastguard Worker!31 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned int", size: 32, align: 32, encoding: DW_ATE_unsigned)
85*9880d681SAndroid Build Coastguard Worker!32 = !{!33}
86*9880d681SAndroid Build Coastguard Worker!33 = !DISubrange(count: 2)
87*9880d681SAndroid Build Coastguard Worker!34 = !DILocalVariable(name: "addr", line: 96, scope: !24, file: !10, type: !35)
88*9880d681SAndroid Build Coastguard Worker!35 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !39, scope: !3, baseType: !11)
89*9880d681SAndroid Build Coastguard Worker!36 = !DIFile(filename: "stdint.h", directory: "/usr/4.2.1/include")
90*9880d681SAndroid Build Coastguard Worker!37 = !DIFile(filename: "types.h", directory: "/usr/include/ppc")
91*9880d681SAndroid Build Coastguard Worker!38 = !DIFile(filename: "OSByteOrder.h", directory: "/usr/include/libkern/ppc")
92*9880d681SAndroid Build Coastguard Worker!39 = !DIFile(filename: "G.c", directory: "/tmp")
93*9880d681SAndroid Build Coastguard Worker!41 = !{i32 1, !"Debug Info Version", i32 3}
94