brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.0 KiB · 73848d8 Raw
56 lines · plain
1; RUN: llc < %s -mtriple powerpc64-ibm-aix-xcoff | FileCheck %s --check-prefix=CHECKASM2 3; This is a case copied from test/DebugInfo/Generic/debug-label-mi.ll. This test4; is to explicitly check that fast isel for XCOFF works as expected for debug5; related intrinsics.6 7; CHECKASM: DEBUG_LABEL: foo:top8; CHECKASM: DEBUG_LABEL: foo:done9 10source_filename = "debug-label-mi.c"11 12; Function Attrs: noinline nounwind optnone13define i32 @foo(i32 signext %a, i32 signext %b) #0 !dbg !4 {14entry:15  %a.addr = alloca i32, align 416  %b.addr = alloca i32, align 417  %sum = alloca i32, align 418  store i32 %a, ptr %a.addr, align 419  store i32 %b, ptr %b.addr, align 420  br label %top21 22top:                                              ; preds = %entry23  call void @llvm.dbg.label(metadata !8), !dbg !924  %0 = load i32, ptr %a.addr, align 425  %1 = load i32, ptr %b.addr, align 426  %add = add nsw i32 %0, %127  store i32 %add, ptr %sum, align 428  br label %done29 30done:                                             ; preds = %top31  call void @llvm.dbg.label(metadata !10), !dbg !1132  %2 = load i32, ptr %sum, align 433  ret i32 %234}35 36; Function Attrs: nounwind readnone speculatable37declare void @llvm.dbg.label(metadata)38 39attributes #0 = { noinline nounwind optnone uwtable }40 41!llvm.dbg.cu = !{!0}42!llvm.module.flags = !{!3}43 44!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, isOptimized: false, emissionKind: FullDebug, enums: !2)45!1 = !DIFile(filename: "debug-label-mi.c", directory: "./")46!2 = !{}47!3 = !{i32 2, !"Debug Info Version", i32 3}48!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, unit: !0, retainedNodes: !2)49!5 = !DISubroutineType(types: !6)50!6 = !{!7, !7, !7}51!7 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)52!8 = !DILabel(scope: !4, name: "top", file: !1, line: 4)53!9 = !DILocation(line: 4, column: 1, scope: !4)54!10 = !DILabel(scope: !4, name: "done", file: !1, line: 7)55!11 = !DILocation(line: 7, column: 1, scope: !4)56