1; RUN: llc < %s -mtriple=armv7-linux-gnueabihf -O1 -stop-after=finalize-isel | FileCheck %s 2 3define dso_local i32 @h(i64 %j) local_unnamed_addr !dbg !8 { 4entry: 5 call void @llvm.dbg.value(metadata i64 %j, metadata !14, metadata !DIExpression()), !dbg !29 6 call void @llvm.dbg.value(metadata i64 %j, metadata !15, metadata !DIExpression(DW_OP_LLVM_convert, 64, DW_ATE_unsigned, DW_OP_LLVM_convert, 32, DW_ATE_unsigned, DW_OP_stack_value, DW_OP_LLVM_fragment, 0, 32)), !dbg !29 7 call void @llvm.dbg.value(metadata i64 %j, metadata !15, metadata !DIExpression(DW_OP_constu, 32, DW_OP_shr, DW_OP_LLVM_convert, 64, DW_ATE_unsigned, DW_OP_LLVM_convert, 32, DW_ATE_unsigned, DW_OP_stack_value, DW_OP_LLVM_fragment, 32, 32)), !dbg !29 8 %tobool = icmp ult i64 %j, 4294967296, !dbg !30 9 br i1 %tobool, label %cleanup, label %if.then, !dbg !31 10 11if.then: ; preds = %entry 12 call void @llvm.dbg.value(metadata i64 %j, metadata !15, metadata !DIExpression(DW_OP_LLVM_convert, 64, DW_ATE_unsigned, DW_OP_LLVM_convert, 32, DW_ATE_unsigned, DW_OP_stack_value, DW_OP_LLVM_fragment, 0, 32)), !dbg !29 13 %conv = sitofp i64 %j to double, !dbg !32 14 %add = fadd double %conv, 0x43F0000000000000, !dbg !33 15 call void @llvm.dbg.value(metadata double %add, metadata !25, metadata !DIExpression()), !dbg !34 16 %conv2 = fptosi double %add to i32, !dbg !35 17 br label %cleanup 18 19cleanup: ; preds = %entry, %if.then 20 %retval.0 = phi i32 [ %conv2, %if.then ], [ undef, %entry ] 21 ret i32 %retval.0, !dbg !36 22} 23 24; CHECK-LABEL: bb.0.entry: 25; CHECK: DBG_VALUE [[REG1:%[0-9]+]], $noreg, !14, !DIExpression(DW_OP_LLVM_fragment, 32, 32 26; CHECK: DBG_VALUE [[REG2:%[0-9]+]], $noreg, !14, !DIExpression(DW_OP_LLVM_fragment, 0, 32 27; CHECK: DBG_VALUE [[REG2]], $noreg, !15, !DIExpression({{.+}}DW_OP_LLVM_fragment, 0, 32 28; CHECK: DBG_VALUE $noreg, $noreg, !15, !DIExpression({{.+}}DW_OP_LLVM_fragment, 32, 32 29 30declare void @llvm.dbg.value(metadata, metadata, metadata) 31 32!llvm.dbg.cu = !{!0} 33!llvm.module.flags = !{!3, !4, !5, !6} 34!llvm.ident = !{!7} 35 36!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 10.0.0 ", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, nameTableKind: None) 37!1 = !DIFile(filename: "tif_aux.c", directory: "/tmp") 38!2 = !{} 39!3 = !{i32 2, !"Dwarf Version", i32 4} 40!4 = !{i32 2, !"Debug Info Version", i32 3} 41!5 = !{i32 1, !"wchar_size", i32 4} 42!6 = !{i32 1, !"min_enum_size", i32 4} 43!7 = !{!"clang version 10.0.0 "} 44!8 = distinct !DISubprogram(name: "h", scope: !1, file: !1, line: 10, type: !9, scopeLine: 10, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition | DISPFlagOptimized, unit: !0, retainedNodes: !13) 45!9 = !DISubroutineType(types: !10) 46!10 = !{!11, !12} 47!11 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed) 48!12 = !DIBasicType(name: "long long int", size: 64, encoding: DW_ATE_signed) 49!13 = !{!14, !15, !25} 50!14 = !DILocalVariable(name: "j", arg: 1, scope: !8, file: !1, line: 10, type: !12) 51!15 = !DILocalVariable(name: "i", scope: !8, file: !1, line: 11, type: !16) 52!16 = !DIDerivedType(tag: DW_TAG_typedef, name: "g", file: !1, line: 8, baseType: !17) 53!17 = distinct !DICompositeType(tag: DW_TAG_union_type, file: !1, line: 5, size: 64, elements: !18) 54!18 = !{!19, !24} 55!19 = !DIDerivedType(tag: DW_TAG_member, name: "e", scope: !17, file: !1, line: 6, baseType: !20, size: 64) 56!20 = distinct !DICompositeType(tag: DW_TAG_structure_type, name: "b", file: !1, line: 1, size: 64, elements: !21) 57!21 = !{!22, !23} 58!22 = !DIDerivedType(tag: DW_TAG_member, name: "c", scope: !20, file: !1, line: 2, baseType: !11, size: 32) 59!23 = !DIDerivedType(tag: DW_TAG_member, name: "d", scope: !20, file: !1, line: 2, baseType: !11, size: 32, offset: 32) 60!24 = !DIDerivedType(tag: DW_TAG_member, name: "f", scope: !17, file: !1, line: 7, baseType: !12, size: 64) 61!25 = !DILocalVariable(name: "a", scope: !26, file: !1, line: 14, type: !28) 62!26 = distinct !DILexicalBlock(scope: !27, file: !1, line: 13, column: 14) 63!27 = distinct !DILexicalBlock(scope: !8, file: !1, line: 13, column: 7) 64!28 = !DIBasicType(name: "double", size: 64, encoding: DW_ATE_float) 65!29 = !DILocation(line: 0, scope: !8) 66!30 = !DILocation(line: 13, column: 7, scope: !27) 67!31 = !DILocation(line: 13, column: 7, scope: !8) 68!32 = !DILocation(line: 14, column: 16, scope: !26) 69!33 = !DILocation(line: 14, column: 20, scope: !26) 70!34 = !DILocation(line: 0, scope: !26) 71!35 = !DILocation(line: 15, column: 12, scope: !26) 72!36 = !DILocation(line: 17, column: 1, scope: !8) 73