2 ; RUN: llc -mtriple=mips-linux-gnu -emit-call-site-info %s -stop-after=finalize-isel -o -| FileCheck %s
4 ; RUN: llc -mtriple=mipsel-linux-gnu -emit-call-site-info %s -stop-after=finalize-isel -o -| FileCheck %s
6 ;; Verify that call site info is not emitted for parameter passed through 64-bit register $d
7 ;; which splits into two 32-bit physical regs.
9 ;; extern double bar(double,int);
10 ;; double foo(double self){
12 ;; double a = bar(self,b);
16 ;; Test mips and mipsel:
19 ; CHECK-NEXT: bb: {{.*}}, offset: {{.*}}, fwdArgRegs:
20 ; CHECK-NOT: arg: 0, reg: '$a0'
21 ; CHECK-NOT: arg: 0, reg: '$d6'
22 ; CHECK-NEXT: arg: 1, reg: '$a2'
25 source_filename = "m.c"
26 target datalayout = "E-m:m-p:32:32-i8:8:32-i16:16:32-i64:64-n32-S64"
27 target triple = "mips-unknown-linux-gnu"
29 ; Function Attrs: nounwind
30 define dso_local double @foo(double %self) local_unnamed_addr !dbg !13 {
32 call void @llvm.dbg.value(metadata double %self, metadata !17, metadata !DIExpression()), !dbg !20
33 call void @llvm.dbg.value(metadata i32 1, metadata !18, metadata !DIExpression()), !dbg !20
34 %call = tail call double @bar(double %self, i32 signext 1), !dbg !20
35 call void @llvm.dbg.value(metadata double %call, metadata !19, metadata !DIExpression()), !dbg !20
36 ret double %call, !dbg !20
39 declare !dbg !4 dso_local double @bar(double, i32 signext) local_unnamed_addr
41 ; Function Attrs: nounwind readnone speculatable willreturn
42 declare void @llvm.dbg.value(metadata, metadata, metadata)
45 !llvm.module.flags = !{!9, !10, !11}
48 !0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 11.0.0", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, retainedTypes: !3, splitDebugInlining: false, nameTableKind: None)
49 !1 = !DIFile(filename: "m.c", directory: "/dir")
52 !4 = !DISubprogram(name: "bar", scope: !1, file: !1, line: 1, type: !5, flags: DIFlagPrototyped, spFlags: DISPFlagOptimized, retainedNodes: !2)
53 !5 = !DISubroutineType(types: !6)
55 !7 = !DIBasicType(name: "double", size: 64, encoding: DW_ATE_float)
56 !8 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
57 !9 = !{i32 7, !"Dwarf Version", i32 4}
58 !10 = !{i32 2, !"Debug Info Version", i32 3}
59 !11 = !{i32 1, !"wchar_size", i32 4}
60 !12 = !{!"clang version 11.0.0"}
61 !13 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 3, type: !14, scopeLine: 3, flags: DIFlagPrototyped | DIFlagAllCallsDescribed, spFlags: DISPFlagDefinition | DISPFlagOptimized, unit: !0, retainedNodes: !16)
62 !14 = !DISubroutineType(types: !15)
64 !16 = !{!17, !18, !19}
65 !17 = !DILocalVariable(name: "self", arg: 1, scope: !13, file: !1, line: 3, type: !7)
66 !18 = !DILocalVariable(name: "b", scope: !13, file: !1, line: 4, type: !8)
67 !19 = !DILocalVariable(name: "a", scope: !13, file: !1, line: 5, type: !7)
68 !20 = !DILocation(line: 0, scope: !13)