OSDN Git Service

f96eafe15024f717b7da69abf403562ccf98a899
[android-x86/external-llvm.git] / test / CodeGen / Hexagon / hasfp-crash1.ll
1 ; RUN: llc -march=hexagon < %s | FileCheck %s
2 ;
3 ; Check that this testcase does not crash.
4 ; CHECK: jumpr r31
5
6 target triple = "hexagon"
7
8 ; Function Attrs: nounwind
9 declare i32 @foo0(i32*, i32, i64, i32, i8 zeroext, i8 zeroext, i32) local_unnamed_addr #0
10
11 ; Function Attrs: nounwind
12 define i32 @foo1(i32* %a0, i32 %a1, i32 %a2, i32 %a3, i8 zeroext %a4, i8 zeroext %a5, i32 %a6) local_unnamed_addr #0 !dbg !33 {
13 entry:
14   tail call void @llvm.dbg.value(metadata i32 %a6, i64 0, metadata !51, metadata !52), !dbg !53
15   ret i32 undef, !dbg !54
16 }
17
18 ; Function Attrs: nounwind readnone speculatable
19 declare void @llvm.dbg.value(metadata, i64, metadata, metadata) #1
20
21 attributes #0 = { nounwind "disable-tail-calls"="true" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "stack-protector-buffer-size"="8" "target-cpu"="hexagonv5" "target-features"="-hvx,-long-calls" }
22 attributes #1 = { nounwind readnone speculatable }
23
24 !llvm.dbg.cu = !{!0}
25 !llvm.module.flags = !{!26, !27}
26 !llvm.linker.options = !{!29, !30, !31, !32, !29, !30, !31, !32}
27
28 !0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "Clang", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, retainedTypes: !22)
29 !1 = !DIFile(filename: "foo.i", directory: "/path")
30 !2 = !{!3, !16}
31 !3 = !DICompositeType(tag: DW_TAG_enumeration_type, file: !4, line: 122, size: 8, elements: !5)
32 !4 = !DIFile(filename: "foo.h", directory: "/path")
33 !5 = !{!6, !7, !8, !9, !10, !11, !12, !13, !14, !15}
34 !6 = !DIEnumerator(name: "E0", value: 7)
35 !7 = !DIEnumerator(name: "E1", value: 6)
36 !8 = !DIEnumerator(name: "E2", value: 5)
37 !9 = !DIEnumerator(name: "E3", value: 0)
38 !10 = !DIEnumerator(name: "E4", value: 1)
39 !11 = !DIEnumerator(name: "E5", value: 7)
40 !12 = !DIEnumerator(name: "E6", value: 5)
41 !13 = !DIEnumerator(name: "E7", value: 4)
42 !14 = !DIEnumerator(name: "E8", value: 4)
43 !15 = !DIEnumerator(name: "E9", value: 10)
44 !16 = !DICompositeType(tag: DW_TAG_enumeration_type, file: !4, line: 136, size: 8, elements: !17)
45 !17 = !{!18, !19, !20, !21}
46 !18 = !DIEnumerator(name: "F0", value: 1)
47 !19 = !DIEnumerator(name: "F1", value: 2)
48 !20 = !DIEnumerator(name: "F2", value: 4)
49 !21 = !DIEnumerator(name: "F3", value: 7)
50 !22 = !{!23, !24, !25}
51 !23 = !DIBasicType(name: "unsigned int", size: 32, encoding: DW_ATE_unsigned)
52 !24 = !DIBasicType(name: "long long unsigned int", size: 64, encoding: DW_ATE_unsigned)
53 !25 = !DIDerivedType(tag: DW_TAG_typedef, name: "t0_t", file: !4, line: 38, baseType: !24)
54 !26 = !{i32 2, !"Debug Info Version", i32 3}
55 !27 = !{i32 6, !"Linker Options", !28}
56 !28 = !{!29, !30, !31, !32}
57 !29 = !{!"foo0", !".text"}
58 !30 = !{!"foo1", !".text"}
59 !31 = !{!"foo2", !".text"}
60 !32 = !{!"foo3", !".text"}
61 !33 = distinct !DISubprogram(name: "foo1", scope: !34, file: !34, line: 84, type: !35, isLocal: false, isDefinition: true, scopeLine: 85, flags: DIFlagPrototyped, isOptimized: true, unit: !0, variables: !44)
62 !34 = !DIFile(filename: "foo.c", directory: "/path")
63 !35 = !DISubroutineType(types: !36)
64 !36 = !{!37, !38, !39, !40, !41, !42, !43, !37}
65 !37 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
66 !38 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !23, size: 32)
67 !39 = !DIDerivedType(tag: DW_TAG_typedef, name: "t1_t", file: !4, line: 35, baseType: !23)
68 !40 = !DIDerivedType(tag: DW_TAG_typedef, name: "t2_t", file: !4, line: 36, baseType: !23)
69 !41 = !DIDerivedType(tag: DW_TAG_typedef, name: "t3_t", file: !4, line: 43, baseType: !23)
70 !42 = !DIDerivedType(tag: DW_TAG_typedef, name: "t4_t", file: !4, line: 133, baseType: !3)
71 !43 = !DIDerivedType(tag: DW_TAG_typedef, name: "t5_t", file: !4, line: 141, baseType: !16)
72 !44 = !{!45, !46, !47, !48, !49, !50, !51}
73 !45 = !DILocalVariable(name: "a0", arg: 1, scope: !33, file: !34, line: 84, type: !38)
74 !46 = !DILocalVariable(name: "a1", arg: 2, scope: !33, file: !34, line: 84, type: !39)
75 !47 = !DILocalVariable(name: "a2", arg: 3, scope: !33, file: !34, line: 84, type: !40)
76 !48 = !DILocalVariable(name: "a3", arg: 4, scope: !33, file: !34, line: 84, type: !41)
77 !49 = !DILocalVariable(name: "a4", arg: 5, scope: !33, file: !34, line: 84, type: !42)
78 !50 = !DILocalVariable(name: "a5", arg: 6, scope: !33, file: !34, line: 84, type: !43)
79 !51 = !DILocalVariable(name: "a6", arg: 7, scope: !33, file: !34, line: 84, type: !37)
80 !52 = !DIExpression()
81 !53 = !DILocation(line: 84, column: 169, scope: !33)
82 !54 = !DILocation(line: 86, column: 5, scope: !33)