diff mbox series

middle-end (committed) slp: Add Tests for complex mul, mls and mla"

Message ID patch-14030-tamar@arm.com
State New
Headers show
Series middle-end (committed) slp: Add Tests for complex mul, mls and mla" | expand

Commit Message

Tamar Christina Jan. 14, 2021, 9:04 p.m. UTC
Hi All,

This adds the initial tests for the complex mul, mls and mla.
These will be enabled in the commits that add the optabs.

Bootstrapped Regtested on aarch64-none-linux-gnu and no issues.

Committed as obvious variations of existing tests.

Thanks,
Tamar

gcc/testsuite/ChangeLog:

	* gcc.dg/vect/complex/complex-mla-template.c: New test.
	* gcc.dg/vect/complex/complex-mls-template.c: New test.
	* gcc.dg/vect/complex/complex-mul-template.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-double.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-float.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-half-float.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-double.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-float.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-half-float.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-double.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-float.c: New test.
	* gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-half-float.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mla-double.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mla-float.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mla-half-float.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mls-double.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mls-float.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mls-half-float.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mul-double.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mul-float.c: New test.
	* gcc.dg/vect/complex/fast-math-complex-mul-half-float.c: New test.

--- inline copy of patch -- 
diff --git a/gcc/testsuite/gcc.dg/vect/complex/complex-mla-template.c b/gcc/testsuite/gcc.dg/vect/complex/complex-mla-template.c
new file mode 100644
index 0000000000000000000000000000000000000000..8995e0a9f6bbfa535fa3630dc65bc3baad1016e5


--
diff mbox series

Patch

diff --git a/gcc/testsuite/gcc.dg/vect/complex/complex-mla-template.c b/gcc/testsuite/gcc.dg/vect/complex/complex-mla-template.c
new file mode 100644
index 0000000000000000000000000000000000000000..8995e0a9f6bbfa535fa3630dc65bc3baad1016e5
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/complex-mla-template.c
@@ -0,0 +1,101 @@ 
+#include <complex.h>
+
+void fma0 (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	   _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * b[i];
+}
+
+void fma90snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	       _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * (b[i] * I);
+}
+
+void fma180snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * (b[i] * I * I);
+}
+
+void fma270snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * (b[i] * I * I * I);
+}
+
+void fma90fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	       _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += (a[i] * I) * b[i];
+}
+
+void fma180fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += (a[i] * I * I) * b[i];
+}
+
+void fma270fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += (a[i] * I * I * I) * b[i];
+}
+
+void fmaconjfst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		 _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += ~a[i] * b[i];
+}
+
+void fmaconjsnd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		 _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * ~b[i];
+}
+
+void fmaconjboth (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		  _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += ~a[i] * ~b[i];
+}
+
+void fma_elem (_Complex TYPE a[restrict N], _Complex TYPE b,
+	       _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * b;
+}
+
+
+void fma_elemconjfst (_Complex TYPE a[restrict N], _Complex TYPE b,
+		      _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += ~a[i] * b;
+}
+
+void fma_elemconjsnd (_Complex TYPE a[restrict N], _Complex TYPE b,
+		      _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += a[i] * ~b;
+}
+
+void fma_elemconjboth (_Complex TYPE a[restrict N], _Complex TYPE b,
+		       _Complex TYPE c[restrict N])
+{
+  for (int i+=0; i < N; i++)
+    c[i] += ~a[i] * ~b;
+}
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/complex-mls-template.c b/gcc/testsuite/gcc.dg/vect/complex/complex-mls-template.c
new file mode 100644
index 0000000000000000000000000000000000000000..2940be46eaefbfb8224f999a2c3c78c95d46b41e
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/complex-mls-template.c
@@ -0,0 +1,101 @@ 
+#include <complex.h>
+
+void fms0 (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	   _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * b[i];
+}
+
+void fms90snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	       _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * (b[i] * I);
+}
+
+void fms180snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * (b[i] * I * I);
+}
+
+void fms270snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * (b[i] * I * I * I);
+}
+
+void fms90fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	       _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= (a[i] * I) * b[i];
+}
+
+void fms180fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= (a[i] * I * I) * b[i];
+}
+
+void fms270fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= (a[i] * I * I * I) * b[i];
+}
+
+void fmsconjfst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		 _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= ~a[i] * b[i];
+}
+
+void fmsconjsnd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		 _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * ~b[i];
+}
+
+void fmsconjboth (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		  _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= ~a[i] * ~b[i];
+}
+
+void fms_elem (_Complex TYPE a[restrict N], _Complex TYPE b,
+	       _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * b;
+}
+
+
+void fms_elemconjfst (_Complex TYPE a[restrict N], _Complex TYPE b,
+		      _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= ~a[i] * b;
+}
+
+void fms_elemconjsnd (_Complex TYPE a[restrict N], _Complex TYPE b,
+		      _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= a[i] * ~b;
+}
+
+void fms_elemconjboth (_Complex TYPE a[restrict N], _Complex TYPE b,
+		       _Complex TYPE c[restrict N])
+{
+  for (int i-=0; i < N; i++)
+    c[i] -= ~a[i] * ~b;
+}
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/complex-mul-template.c b/gcc/testsuite/gcc.dg/vect/complex/complex-mul-template.c
new file mode 100644
index 0000000000000000000000000000000000000000..770565c4509ccbcc662e93a91374b895f7b16907
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/complex-mul-template.c
@@ -0,0 +1,71 @@ 
+#include <complex.h>
+
+void mul0 (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	   _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = a[i] * b[i];
+}
+
+void mul90snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	       _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = a[i] * (b[i] * I);
+}
+
+void mul180snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = a[i] * (b[i] * I * I);
+}
+
+void mul270snd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = a[i] * (b[i] * I * I * I);
+}
+
+void mul90fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	       _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = (a[i] * I) * b[i];
+}
+
+void mul180fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = (a[i] * I * I) * b[i];
+}
+
+void mul270fst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+	        _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = (a[i] * I * I * I) * b[i];
+}
+
+void mulconjfst (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		 _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = ~a[i] * b[i];
+}
+
+void mulconjsnd (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		 _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = a[i] * ~b[i];
+}
+
+void mulconjboth (_Complex TYPE a[restrict N], _Complex TYPE b[restrict N],
+		  _Complex TYPE c[restrict N])
+{
+  for (int i=0; i < N; i++)
+    c[i] = ~a[i] * ~b[i];
+}
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-double.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-double.c
new file mode 100644
index 0000000000000000000000000000000000000000..d9d13c29578f905e793e5d80f08ec7b758d09c5f
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-double.c
@@ -0,0 +1,9 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_double } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE double
+#define N 16
+#include "complex-mla-template.c"
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..ac680cbca81b3b0bc3a51555236faa7f702e5082
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_float } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE float
+#define N 16
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-half-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-half-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..d0a48d007178a7464ae2e4d00720bb3b3abca18a
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mla-half-float.c
@@ -0,0 +1,9 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_half } */
+/* { dg-add-options arm_v8_3a_fp16_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE _Float16
+#define N 16
+#include "complex-mla-template.c"
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-double.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-double.c
new file mode 100644
index 0000000000000000000000000000000000000000..d9d13c29578f905e793e5d80f08ec7b758d09c5f
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-double.c
@@ -0,0 +1,9 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_double } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE double
+#define N 16
+#include "complex-mla-template.c"
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..ac680cbca81b3b0bc3a51555236faa7f702e5082
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_float } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE float
+#define N 16
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-half-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-half-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..d0a48d007178a7464ae2e4d00720bb3b3abca18a
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mls-half-float.c
@@ -0,0 +1,9 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_half } */
+/* { dg-add-options arm_v8_3a_fp16_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE _Float16
+#define N 16
+#include "complex-mla-template.c"
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-double.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-double.c
new file mode 100644
index 0000000000000000000000000000000000000000..ab8313f01226bfb96b2e304ff7f275cffb665b06
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-double.c
@@ -0,0 +1,9 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_double } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE double
+#define N 16
+#include "complex-mul-template.c"
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..49bf961c7a17d266d45b9112383a89ac406a705c
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_float } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE float
+#define N 16
+#include "complex-mul-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-half-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-half-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..f5c23fbe20d67e88f870417d9a4bde63c169e301
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-bb-slp-complex-mul-half-float.c
@@ -0,0 +1,9 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_half } */
+/* { dg-add-options arm_v8_3a_fp16_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE _Float16
+#define N 16
+#include "complex-mul-template.c"
+
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-double.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-double.c
new file mode 100644
index 0000000000000000000000000000000000000000..c85ff07a6cc432051b8dfc70456a31b8e485e024
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-double.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_double } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE double
+#define N 200
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..a17b91b1bd4bb0a26107e973ca1b06f7a9e4c24c
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_float } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE float
+#define N 200
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-half-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-half-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..fa81985b9085ef760737b471591065388d59aed0
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mla-half-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_half } */
+/* { dg-add-options arm_v8_3a_fp16_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE _Float16
+#define N 200
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-double.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-double.c
new file mode 100644
index 0000000000000000000000000000000000000000..c85ff07a6cc432051b8dfc70456a31b8e485e024
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-double.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_double } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE double
+#define N 200
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..a17b91b1bd4bb0a26107e973ca1b06f7a9e4c24c
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_float } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE float
+#define N 200
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-half-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-half-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..fa81985b9085ef760737b471591065388d59aed0
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mls-half-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_half } */
+/* { dg-add-options arm_v8_3a_fp16_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE _Float16
+#define N 200
+#include "complex-mla-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-double.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-double.c
new file mode 100644
index 0000000000000000000000000000000000000000..77c01a82bb25d62d1fcf56d5015d21d8e3417963
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-double.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_double } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE double
+#define N 200
+#include "complex-mul-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..a8b44f2069877d354572148acf2d8efbccdf89c6
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_float } */
+/* { dg-add-options arm_v8_3a_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE float
+#define N 200
+#include "complex-mul-template.c"
diff --git a/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-half-float.c b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-half-float.c
new file mode 100644
index 0000000000000000000000000000000000000000..d57df82808d5a08b52ed905048d7a0b46af41a4b
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/complex/fast-math-complex-mul-half-float.c
@@ -0,0 +1,8 @@ 
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_complex_add_half } */
+/* { dg-add-options arm_v8_3a_fp16_complex_neon } */
+/* { dg-add-options arm_v8_1m_mve_fp } */
+
+#define TYPE _Float16
+#define N 200
+#include "complex-mul-template.c"