@@ -37,68 +37,83 @@ fn square(x: f32) -> f32 {
3737
3838// CHECK: ; abi_handling::f1
3939// CHECK-NEXT: ; Function Attrs: {{.*}}noinline{{.*}}
40- // debug-NEXT: define internal float @_ZN12abi_handling2f117h536ac8081c1e4101E(ptr align 4 %x)
41- // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f117h536ac8081c1e4101E(float %x.0.val, float %x.4.val)
40+ // debug-NEXT: define internal float @_ZN12abi_handling2f117h536ac8081c1e4101E
41+ // debug-SAME: (ptr align 4 %x)
42+ // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f117h536ac8081c1e4101E
43+ // release-SAME: (float %x.0.val, float %x.4.val)
4244#[ autodiff_forward( df1, Dual , Dual ) ]
4345fn f1 ( x : & [ f32 ; 2 ] ) -> f32 {
4446 x[ 0 ] + x[ 1 ]
4547}
4648
4749// CHECK: ; abi_handling::f2
4850// CHECK-NEXT: ; Function Attrs: {{.*}}noinline{{.*}}
49- // debug-NEXT: define internal float @_ZN12abi_handling2f217h33732e9f83c91bc9E(ptr %f, float %x)
50- // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f217h33732e9f83c91bc9E(float noundef %x)
51+ // debug-NEXT: define internal float @_ZN12abi_handling2f217h33732e9f83c91bc9E
52+ // debug-SAME: (ptr %f, float %x)
53+ // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f217h33732e9f83c91bc9E
54+ // release-SAME: (float noundef %x)
5155#[ autodiff_reverse( df2, Const , Active , Active ) ]
5256fn f2 ( f : fn ( f32 ) -> f32 , x : f32 ) -> f32 {
5357 f ( x)
5458}
5559
5660// CHECK: ; abi_handling::f3
5761// CHECK-NEXT: ; Function Attrs: {{.*}}noinline{{.*}}
58- // debug-NEXT: define internal float @_ZN12abi_handling2f317h9cd1fc602b0815a4E(ptr align 4 %x, ptr align 4 %y)
59- // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f317h9cd1fc602b0815a4E(float %x.0.val)
62+ // debug-NEXT: define internal float @_ZN12abi_handling2f317h9cd1fc602b0815a4E
63+ // debug-SAME: (ptr align 4 %x, ptr align 4 %y)
64+ // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f317h9cd1fc602b0815a4E
65+ // release-SAME: (float %x.0.val)
6066#[ autodiff_forward( df3, Dual , Dual , Dual ) ]
6167fn f3 < ' a > ( x : & ' a f32 , y : & ' a f32 ) -> f32 {
6268 * x * * y
6369}
6470
6571// CHECK: ; abi_handling::f4
6672// CHECK-NEXT: ; Function Attrs: {{.*}}noinline{{.*}}
67- // debug-NEXT: define internal float @_ZN12abi_handling2f417h2f4a9a7492d91e9fE(float %x.0, float %x.1)
68- // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f417h2f4a9a7492d91e9fE(float noundef %x.0, float noundef %x.1)
73+ // debug-NEXT: define internal float @_ZN12abi_handling2f417h2f4a9a7492d91e9fE
74+ // debug-SAME: (float %x.0, float %x.1)
75+ // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f417h2f4a9a7492d91e9fE
76+ // release-SAME: (float noundef %x.0, float noundef %x.1)
6977#[ autodiff_forward( df4, Dual , Dual ) ]
7078fn f4 ( x : ( f32 , f32 ) ) -> f32 {
7179 x. 0 * x. 1
7280}
7381
7482// CHECK: ; abi_handling::f5
7583// CHECK-NEXT: ; Function Attrs: {{.*}}noinline{{.*}}
76- // debug-NEXT: define internal float @_ZN12abi_handling2f517hf8d4ac4d2c2a3976E(float %i.0, float %i.1)
77- // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f517hf8d4ac4d2c2a3976E(float noundef %i.0, float noundef %i.1)
84+ // debug-NEXT: define internal float @_ZN12abi_handling2f517hf8d4ac4d2c2a3976E
85+ // debug-SAME: (float %i.0, float %i.1)
86+ // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f517hf8d4ac4d2c2a3976E
87+ // release-SAME: (float noundef %i.0, float noundef %i.1)
7888#[ autodiff_forward( df5, Dual , Dual ) ]
7989fn f5 ( i : Input ) -> f32 {
8090 i. x + i. y
8191}
8292
8393// CHECK: ; abi_handling::f6
8494// CHECK-NEXT: ; Function Attrs: {{.*}}noinline{{.*}}
85- // debug-NEXT: define internal float @_ZN12abi_handling2f617h5784b207bbb2483eE(float %i.0, float %i.1)
86- // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f617h5784b207bbb2483eE(float noundef %i.0, float noundef %i.1)
95+ // debug-NEXT: define internal float @_ZN12abi_handling2f617h5784b207bbb2483eE
96+ // debug-SAME: (float %i.0, float %i.1)
97+ // release-NEXT: define internal fastcc noundef float @_ZN12abi_handling2f617h5784b207bbb2483eE
98+ // release-SAME: (float noundef %i.0, float noundef %i.1)
8799#[ autodiff_forward( df6, Dual , Dual ) ]
88100fn f6 ( i : NestedInput ) -> f32 {
89101 i. x + i. y . z * i. y . z
90102}
91103
92104// df1
93- // release: define internal fastcc { float, float } @fwddiffe_ZN12abi_handling2f117h536ac8081c1e4101E(float %x.0.val, float %x.4.val)
105+ // release: define internal fastcc { float, float }
106+ // release-SAME: @fwddiffe_ZN12abi_handling2f117h536ac8081c1e4101E
107+ // release-SAME: (float %x.0.val, float %x.4.val)
94108// release-NEXT: start:
95109// release-NEXT: %_0 = fadd float %x.0.val, %x.4.val
96110// release-NEXT: %0 = insertvalue { float, float } undef, float %_0, 0
97111// release-NEXT: %1 = insertvalue { float, float } %0, float 1.000000e+00, 1
98112// release-NEXT: ret { float, float } %1
99113// release-NEXT: }
100114
101- // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f117h536ac8081c1e4101E(ptr align 4 %x, ptr align 4 %"x'")
115+ // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f117h536ac8081c1e4101E
116+ // debug-SAME: (ptr align 4 %x, ptr align 4 %"x'")
102117// debug-NEXT: start:
103118// debug-NEXT: %"'ipg" = getelementptr inbounds float, ptr %"x'", i64 0
104119// debug-NEXT: %0 = getelementptr inbounds nuw float, ptr %x, i64 0
@@ -116,15 +131,18 @@ fn f6(i: NestedInput) -> f32 {
116131// debug-NEXT: }
117132
118133// df2
119- // release: define internal fastcc { float, float } @diffe_ZN12abi_handling2f217h33732e9f83c91bc9E(float noundef %x)
134+ // release: define internal fastcc { float, float }
135+ // release-SAME: @diffe_ZN12abi_handling2f217h33732e9f83c91bc9E
136+ // release-SAME: (float noundef %x)
120137// release-NEXT: invertstart:
121138// release-NEXT: %_0.i = fmul float %x, %x
122139// release-NEXT: %0 = insertvalue { float, float } undef, float %_0.i, 0
123140// release-NEXT: %1 = insertvalue { float, float } %0, float 0.000000e+00, 1
124141// release-NEXT: ret { float, float } %1
125142// release-NEXT: }
126143
127- // debug: define internal { float, float } @diffe_ZN12abi_handling2f217h33732e9f83c91bc9E(ptr %f, float %x, float %differeturn)
144+ // debug: define internal { float, float } @diffe_ZN12abi_handling2f217h33732e9f83c91bc9E
145+ // debug-SAME: (ptr %f, float %x, float %differeturn)
128146// debug-NEXT: start:
129147// debug-NEXT: %"x'de" = alloca float, align 4
130148// debug-NEXT: store float 0.000000e+00, ptr %"x'de", align 4
@@ -142,14 +160,17 @@ fn f6(i: NestedInput) -> f32 {
142160// debug-NEXT: }
143161
144162// df3
145- // release: define internal fastcc { float, float } @fwddiffe_ZN12abi_handling2f317h9cd1fc602b0815a4E(float %x.0.val)
163+ // release: define internal fastcc { float, float }
164+ // release-SAME: @fwddiffe_ZN12abi_handling2f317h9cd1fc602b0815a4E
165+ // release-SAME: (float %x.0.val)
146166// release-NEXT: start:
147167// release-NEXT: %0 = insertvalue { float, float } undef, float %x.0.val, 0
148168// release-NEXT: %1 = insertvalue { float, float } %0, float 0x40099999A0000000, 1
149169// release-NEXT: ret { float, float } %1
150170// release-NEXT: }
151171
152- // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f317h9cd1fc602b0815a4E(ptr align 4 %x, ptr align 4 %"x'", ptr align 4 %y, ptr align 4 %"y'")
172+ // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f317h9cd1fc602b0815a4E
173+ // debug-SAME: (ptr align 4 %x, ptr align 4 %"x'", ptr align 4 %y, ptr align 4 %"y'")
153174// debug-NEXT: start:
154175// debug-NEXT: %"_3'ipl" = load float, ptr %"x'", align 4, !alias.scope !9, !noalias !12
155176// debug-NEXT: %_3 = load float, ptr %x, align 4, !alias.scope !12, !noalias !9
@@ -165,14 +186,17 @@ fn f6(i: NestedInput) -> f32 {
165186// debug-NEXT: }
166187
167188// df4
168- // release: define internal fastcc { float, float } @fwddiffe_ZN12abi_handling2f417h2f4a9a7492d91e9fE(float noundef %x.0, float %"x.0'")
189+ // release: define internal fastcc { float, float }
190+ // release-SAME: @fwddiffe_ZN12abi_handling2f417h2f4a9a7492d91e9fE
191+ // release-SAME: (float noundef %x.0, float %"x.0'")
169192// release-NEXT: start:
170193// release-NEXT: %0 = insertvalue { float, float } undef, float %x.0, 0
171194// release-NEXT: %1 = insertvalue { float, float } %0, float %"x.0'", 1
172195// release-NEXT: ret { float, float } %1
173196// release-NEXT: }
174197
175- // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f417h2f4a9a7492d91e9fE(float %x.0, float %"x.0'", float %x.1, float %"x.1'")
198+ // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f417h2f4a9a7492d91e9fE
199+ // debug-SAME: (float %x.0, float %"x.0'", float %x.1, float %"x.1'")
176200// debug-NEXT: start:
177201// debug-NEXT: %_0 = fmul float %x.0, %x.1
178202// debug-NEXT: %0 = fmul fast float %"x.0'", %x.1
@@ -184,15 +208,18 @@ fn f6(i: NestedInput) -> f32 {
184208// debug-NEXT: }
185209
186210// df5
187- // release: define internal fastcc { float, float } @fwddiffe_ZN12abi_handling2f517hf8d4ac4d2c2a3976E(float noundef %i.0, float %"i.0'")
211+ // release: define internal fastcc { float, float }
212+ // release-SAME: @fwddiffe_ZN12abi_handling2f517hf8d4ac4d2c2a3976E
213+ // release-SAME: (float noundef %i.0, float %"i.0'")
188214// release-NEXT: start:
189215// release-NEXT: %_0 = fadd float %i.0, 1.000000e+00
190216// release-NEXT: %0 = insertvalue { float, float } undef, float %_0, 0
191217// release-NEXT: %1 = insertvalue { float, float } %0, float %"i.0'", 1
192218// release-NEXT: ret { float, float } %1
193219// release-NEXT: }
194220
195- // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f517hf8d4ac4d2c2a3976E(float %i.0, float %"i.0'", float %i.1, float %"i.1'")
221+ // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f517hf8d4ac4d2c2a3976E
222+ // debug-SAME: (float %i.0, float %"i.0'", float %i.1, float %"i.1'")
196223// debug-NEXT: start:
197224// debug-NEXT: %_0 = fadd float %i.0, %i.1
198225// debug-NEXT: %0 = fadd fast float %"i.0'", %"i.1'"
@@ -202,7 +229,9 @@ fn f6(i: NestedInput) -> f32 {
202229// debug-NEXT: }
203230
204231// df6
205- // release: define internal fastcc { float, float } @fwddiffe_ZN12abi_handling2f617h5784b207bbb2483eE(float noundef %i.0, float %"i.0'", float noundef %i.1, float %"i.1'")
232+ // release: define internal fastcc { float, float }
233+ // release-SAME: @fwddiffe_ZN12abi_handling2f617h5784b207bbb2483eE
234+ // release-SAME: (float noundef %i.0, float %"i.0'", float noundef %i.1, float %"i.1'")
206235// release-NEXT: start:
207236// release-NEXT: %_3 = fmul float %i.1, %i.1
208237// release-NEXT: %0 = fadd fast float %"i.1'", %"i.1'"
@@ -214,7 +243,8 @@ fn f6(i: NestedInput) -> f32 {
214243// release-NEXT: ret { float, float } %4
215244// release-NEXT: }
216245
217- // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f617h5784b207bbb2483eE(float %i.0, float %"i.0'", float %i.1, float %"i.1'")
246+ // debug: define internal { float, float } @fwddiffe_ZN12abi_handling2f617h5784b207bbb2483eE
247+ // debug-SAME: (float %i.0, float %"i.0'", float %i.1, float %"i.1'")
218248// debug-NEXT: start:
219249// debug-NEXT: %_3 = fmul float %i.1, %i.1
220250// debug-NEXT: %0 = fmul fast float %"i.1'", %i.1
0 commit comments