@@ -36,8 +36,8 @@ define <4 x double> @fadd_v4f64_poison_idx(<4 x double> %a, <4 x double> %b) {
36
36
ret <4 x double > %post
37
37
}
38
38
39
- define <4 x double > @fadd_mixed_types (<4 x double > %a , <2 x double > %b ) {
40
- ; CHECK-LABEL: define <4 x double> @fadd_mixed_types (
39
+ define <4 x double > @fadd_v4f64_mixed_types (<4 x double > %a , <2 x double > %b ) {
40
+ ; CHECK-LABEL: define <4 x double> @fadd_v4f64_mixed_types (
41
41
; CHECK-SAME: <4 x double> [[A:%.*]], <2 x double> [[B:%.*]]) #[[ATTR0]] {
42
42
; CHECK-NEXT: [[TMP1:%.*]] = shufflevector <4 x double> [[A]], <4 x double> poison, <4 x i32> <i32 2, i32 3, i32 0, i32 1>
43
43
; CHECK-NEXT: [[TMP2:%.*]] = shufflevector <2 x double> [[B]], <2 x double> poison, <4 x i32> <i32 0, i32 1, i32 0, i32 1>
@@ -51,6 +51,19 @@ define <4 x double> @fadd_mixed_types(<4 x double> %a, <2 x double> %b) {
51
51
ret <4 x double > %post
52
52
}
53
53
54
+ define <4 x float > @fadd_v4f32_mixed_types (<4 x float > %a0 ) {
55
+ ; CHECK-LABEL: define <4 x float> @fadd_v4f32_mixed_types(
56
+ ; CHECK-SAME: <4 x float> [[A0:%.*]]) #[[ATTR0]] {
57
+ ; CHECK-NEXT: [[TMP1:%.*]] = shufflevector <4 x float> [[A0]], <4 x float> zeroinitializer, <4 x i32> <i32 1, i32 5, i32 poison, i32 poison>
58
+ ; CHECK-NEXT: [[POST:%.*]] = fmul <4 x float> [[TMP1]], <float 0.000000e+00, float 0.000000e+00, float undef, float undef>
59
+ ; CHECK-NEXT: ret <4 x float> [[POST]]
60
+ ;
61
+ %pre = shufflevector <4 x float > %a0 , <4 x float > zeroinitializer , <2 x i32 > <i32 1 , i32 5 >
62
+ %op = fmul <2 x float > %pre , zeroinitializer
63
+ %post = shufflevector <2 x float > %op , <2 x float > poison, <4 x i32 > <i32 0 , i32 1 , i32 poison, i32 poison>
64
+ ret <4 x float > %post
65
+ }
66
+
54
67
; Negative test - multiple use of fadd
55
68
define <4 x double > @fadd_v4f64_multiuse_op (<4 x double > %a , <4 x double > %b ) {
56
69
; CHECK-LABEL: define <4 x double> @fadd_v4f64_multiuse_op(
0 commit comments