67 lines · plain
1; NOTE: To be able to use this file as an input, the string SRC_COMPDIR needs2; replacing with a directory path by using sed or similar.3 4; ModuleID = 'source-interleave-x86_64.bc'5source_filename = "source-interleave-x86_64.c"6target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"7target triple = "x86_64-unknown-linux-gnu"8 9@a = global i32 1, align 4, !dbg !410 11; Function Attrs: nounwind uwtable12define i32 @foo() #0 !dbg !9 {13entry:14 %0 = load i32, ptr @a, align 4, !dbg !1215 ret i32 %0, !dbg !1316}17 18; Function Attrs: nounwind uwtable19define i32 @main() #0 !dbg !14 {20entry:21 %retval = alloca i32, align 422 %b = alloca ptr, align 823 store i32 0, ptr %retval, align 424 call void @llvm.dbg.declare(metadata ptr %b, metadata !15, metadata !17), !dbg !1825 store ptr @a, ptr %b, align 8, !dbg !1826 %0 = load ptr, ptr %b, align 8, !dbg !1927 %1 = load i32, ptr %0, align 4, !dbg !2028 %call = call i32 @foo(), !dbg !2129 %add = add nsw i32 %1, %call, !dbg !2230 ret i32 %add, !dbg !2331}32 33; Function Attrs: nounwind readnone34declare void @llvm.dbg.declare(metadata, metadata, metadata) #135 36attributes #0 = { nounwind uwtable "disable-tail-calls"="false" "less-precise-fpmad"="false" "frame-pointer"="all" "no-infs-fp-math"="false" "no-jump-tables"="false" "no-nans-fp-math"="false" "no-signed-zeros-fp-math"="false" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+fxsr,+mmx,+sse,+sse2,+x87" "unsafe-fp-math"="false" "use-soft-float"="false" }37attributes #1 = { nounwind readnone }38 39!llvm.dbg.cu = !{!0}40!llvm.module.flags = !{!6, !7}41!llvm.ident = !{!8}42 43!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 4.0.0", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, globals: !3)44!1 = !DIFile(filename: "source-interleave-x86_64.c", directory: "SRC_COMPDIR")45!2 = !{}46!3 = !{!4}47!4 = !DIGlobalVariableExpression(var: !DIGlobalVariable(name: "a", scope: !0, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true), expr: !DIExpression())48!5 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)49!6 = !{i32 2, !"Dwarf Version", i32 4}50!7 = !{i32 2, !"Debug Info Version", i32 3}51!8 = !{!"clang version 4.0.0"}52!9 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 2, type: !10, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, unit: !0, retainedNodes: !2)53!10 = !DISubroutineType(types: !11)54!11 = !{!5}55!12 = !DILocation(line: 3, column: 10, scope: !9)56!13 = !DILocation(line: 3, column: 3, scope: !9)57!14 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 6, type: !10, isLocal: false, isDefinition: true, scopeLine: 6, isOptimized: false, unit: !0, retainedNodes: !2)58!15 = !DILocalVariable(name: "b", scope: !14, file: !1, line: 7, type: !16)59!16 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !5, size: 64, align: 64)60!17 = !DIExpression()61!18 = !DILocation(line: 7, column: 8, scope: !14)62!19 = !DILocation(line: 8, column: 11, scope: !14)63!20 = !DILocation(line: 8, column: 10, scope: !14)64!21 = !DILocation(line: 8, column: 15, scope: !14)65!22 = !DILocation(line: 8, column: 13, scope: !14)66!23 = !DILocation(line: 8, column: 3, scope: !14)67