@@ -60,23 +60,44 @@ void test_builtin_elementwise_acos(float f, double d, vfloat4 vf4,
60
60
61
61
void test_builtin_elementwise_asin (float f , double d , vfloat4 vf4 ,
62
62
vdouble4 vd4 ) {
63
- // CIR-LABEL: test_builtin_elementwise_asin
64
- // LLVM-LABEL: test_builtin_elementwise_asin
65
- // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.float
66
- // LLVM: {{%.*}} = call float @llvm.asin.f32(float {{%.*}})
67
- f = __builtin_elementwise_asin (f );
68
-
69
- // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.double
70
- // LLVM: {{%.*}} = call double @llvm.asin.f64(double {{%.*}})
71
- d = __builtin_elementwise_asin (d );
72
-
73
- // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.vector<!cir.float x 4>
74
- // LLVM: {{%.*}} = call <4 x float> @llvm.asin.v4f32(<4 x float> {{%.*}})
75
- vf4 = __builtin_elementwise_asin (vf4 );
76
-
77
- // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.vector<!cir.double x 4>
78
- // LLVM: {{%.*}} = call <4 x double> @llvm.asin.v4f64(<4 x double> {{%.*}})
79
- vd4 = __builtin_elementwise_asin (vd4 );
63
+ // CIR-LABEL: test_builtin_elementwise_asin
64
+ // LLVM-LABEL: test_builtin_elementwise_asin
65
+ // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.float
66
+ // LLVM: {{%.*}} = call float @llvm.asin.f32(float {{%.*}})
67
+ f = __builtin_elementwise_asin (f );
68
+
69
+ // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.double
70
+ // LLVM: {{%.*}} = call double @llvm.asin.f64(double {{%.*}})
71
+ d = __builtin_elementwise_asin (d );
72
+
73
+ // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.vector<!cir.float x 4>
74
+ // LLVM: {{%.*}} = call <4 x float> @llvm.asin.v4f32(<4 x float> {{%.*}})
75
+ vf4 = __builtin_elementwise_asin (vf4 );
76
+
77
+ // CIR: {{%.*}} = cir.asin {{%.*}} : !cir.vector<!cir.double x 4>
78
+ // LLVM: {{%.*}} = call <4 x double> @llvm.asin.v4f64(<4 x double> {{%.*}})
79
+ vd4 = __builtin_elementwise_asin (vd4 );
80
+ }
81
+
82
+ void test_builtin_elementwise_atan (float f , double d , vfloat4 vf4 ,
83
+ vdouble4 vd4 ) {
84
+ // CIR-LABEL: test_builtin_elementwise_atan
85
+ // LLVM-LABEL: test_builtin_elementwise_atan
86
+ // CIR: {{%.*}} = cir.atan {{%.*}} : !cir.float
87
+ // LLVM: {{%.*}} = call float @llvm.atan.f32(float {{%.*}})
88
+ f = __builtin_elementwise_atan (f );
89
+
90
+ // CIR: {{%.*}} = cir.atan {{%.*}} : !cir.double
91
+ // LLVM: {{%.*}} = call double @llvm.atan.f64(double {{%.*}})
92
+ d = __builtin_elementwise_atan (d );
93
+
94
+ // CIR: {{%.*}} = cir.atan {{%.*}} : !cir.vector<!cir.float x 4>
95
+ // LLVM: {{%.*}} = call <4 x float> @llvm.atan.v4f32(<4 x float> {{%.*}})
96
+ vf4 = __builtin_elementwise_atan (vf4 );
97
+
98
+ // CIR: {{%.*}} = cir.atan {{%.*}} : !cir.vector<!cir.double x 4>
99
+ // LLVM: {{%.*}} = call <4 x double> @llvm.atan.v4f64(<4 x double> {{%.*}})
100
+ vd4 = __builtin_elementwise_atan (vd4 );
80
101
}
81
102
82
103
void test_builtin_elementwise_exp (float f , double d , vfloat4 vf4 ,
0 commit comments