brintos

brintos / llvm-project-archived public Read only

0
0
Text · 5.6 KiB · 7960b79 Raw
116 lines · plain
1; RUN: llc < %s -verify-machineinstrs2; PR161103;4; This test case contains a value that is split into two connected components5; by rematerialization during coalescing. It also contains a DBG_VALUE6; instruction which must be updated during7; ConnectedVNInfoEqClasses::Distribute().8 9source_filename = "test/CodeGen/ARM/coalesce-dbgvalue.ll"10target datalayout = "e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:32:64-v128:32:128-a0:0:32-n32-S32"11target triple = "thumbv7-apple-ios3.0.0"12 13@c = common global i32 0, align 4, !dbg !014@b = common global i32 0, align 4, !dbg !415@a = common global i64 0, align 8, !dbg !616@d = common global i32 0, align 4, !dbg !917 18; Function Attrs: nounwind ssp19define i32 @pr16110() #0 !dbg !15 {20for.cond1.preheader:21  store i32 0, ptr @c, align 4, !dbg !2422  br label %for.cond1.outer, !dbg !2623 24for.cond1:                                        ; preds = %for.end9, %for.cond1.outer25  %storemerge11 = phi i32 [ 0, %for.end9 ], [ %storemerge11.ph, %for.cond1.outer ]26  %cmp = icmp slt i32 %storemerge11, 1, !dbg !2627  br i1 %cmp, label %for.body2, label %for.end9, !dbg !2628 29for.body2:                                        ; preds = %for.cond130  store i32 %storemerge11, ptr @b, align 4, !dbg !2631  tail call void @llvm.dbg.value(metadata ptr null, metadata !20, metadata !27), !dbg !2832  %0 = load i64, ptr @a, align 8, !dbg !2933  %xor = xor i64 %0, %e.1.ph, !dbg !2934  %conv3 = trunc i64 %xor to i32, !dbg !2935  tail call void @llvm.dbg.value(metadata i32 %conv3, metadata !19, metadata !27), !dbg !2936  %tobool4 = icmp eq i32 %conv3, 0, !dbg !2937  br i1 %tobool4, label %land.end, label %land.rhs, !dbg !2938 39land.rhs:                                         ; preds = %for.body240  %call = tail call i32 @fn3() #3, !dbg !2941  %tobool5 = icmp ne i32 %call, 0, !dbg !2942  br label %land.end43 44land.end:                                         ; preds = %land.rhs, %for.body245  %1 = phi i1 [ false, %for.body2 ], [ %tobool5, %land.rhs ]46  %land.ext = zext i1 %1 to i3247  %call6 = tail call i32 @fn2(i32 %land.ext, ptr null) #348  %2 = load i32, ptr @b, align 4, !dbg !2649  %inc8 = add nsw i32 %2, 1, !dbg !2650  %phitmp = and i64 %xor, 4294967295, !dbg !2651  br label %for.cond1.outer, !dbg !2652 53for.cond1.outer:                                  ; preds = %land.end, %for.cond1.preheader54  %storemerge11.ph = phi i32 [ %inc8, %land.end ], [ 0, %for.cond1.preheader ]55  %e.1.ph = phi i64 [ %phitmp, %land.end ], [ 0, %for.cond1.preheader ]56  %3 = load i32, ptr @d, align 4, !dbg !3057  %tobool10 = icmp eq i32 %3, 0, !dbg !3058  br label %for.cond159 60for.end9:                                         ; preds = %for.cond161  br i1 %tobool10, label %if.end, label %for.cond1, !dbg !3062 63if.end:                                           ; preds = %for.end964  store i32 %storemerge11, ptr @b, align 4, !dbg !2665  ret i32 0, !dbg !3166}67 68declare i32 @fn2(...) #169 70declare i32 @fn3(...) #171 72; Function Attrs: nounwind readnone73declare void @llvm.dbg.value(metadata, metadata, metadata) #274 75attributes #0 = { nounwind ssp "less-precise-fpmad"="false" "frame-pointer"="all" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "use-soft-float"="false" }76attributes #1 = { "less-precise-fpmad"="false" "frame-pointer"="all" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "use-soft-float"="false" }77attributes #2 = { nounwind readnone }78attributes #3 = { nounwind }79 80!llvm.dbg.cu = !{!11}81!llvm.module.flags = !{!14}82 83!0 = !DIGlobalVariableExpression(var: !1, expr: !DIExpression())84!1 = !DIGlobalVariable(name: "c", scope: null, file: !2, line: 3, type: !3, isLocal: false, isDefinition: true)85!2 = !DIFile(filename: "pr16110.c", directory: "/d/b")86!3 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)87!4 = !DIGlobalVariableExpression(var: !5, expr: !DIExpression())88!5 = !DIGlobalVariable(name: "b", scope: null, file: !2, line: 2, type: !3, isLocal: false, isDefinition: true)89!6 = !DIGlobalVariableExpression(var: !7, expr: !DIExpression())90!7 = !DIGlobalVariable(name: "a", scope: null, file: !2, line: 1, type: !8, isLocal: false, isDefinition: true)91!8 = !DIBasicType(name: "long long int", size: 64, align: 32, encoding: DW_ATE_signed)92!9 = !DIGlobalVariableExpression(var: !10, expr: !DIExpression())93!10 = !DIGlobalVariable(name: "d", scope: null, file: !2, line: 4, type: !3, isLocal: false, isDefinition: true)94!11 = distinct !DICompileUnit(language: DW_LANG_C99, file: !2, producer: "clang version 3.4 (trunk 182024) (llvm/trunk 182023)", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !12, retainedTypes: !12, globals: !13, imports: !12)95!12 = !{}96!13 = !{!6, !4, !0, !9}97!14 = !{i32 1, !"Debug Info Version", i32 3}98!15 = distinct !DISubprogram(name: "pr16110", scope: !2, file: !2, line: 7, type: !16, isLocal: false, isDefinition: true, scopeLine: 7, virtualIndex: 6, isOptimized: true, unit: !11, retainedNodes: !18)99!16 = !DISubroutineType(types: !17)100!17 = !{!3}101!18 = !{!19, !20}102!19 = !DILocalVariable(name: "e", scope: !15, file: !2, line: 8, type: !3)103!20 = !DILocalVariable(name: "f", scope: !21, file: !2, line: 13, type: !23)104!21 = distinct !DILexicalBlock(scope: !22, file: !2, line: 12)105!22 = distinct !DILexicalBlock(scope: !15, file: !2, line: 12)106!23 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !3, size: 32, align: 32)107!24 = !DILocation(line: 10, scope: !25)108!25 = distinct !DILexicalBlock(scope: !15, file: !2, line: 10)109!26 = !DILocation(line: 12, scope: !22)110!27 = !DIExpression()111!28 = !DILocation(line: 13, scope: !21)112!29 = !DILocation(line: 14, scope: !21)113!30 = !DILocation(line: 16, scope: !15)114!31 = !DILocation(line: 18, scope: !15)115 116