gcc/testsuite/
authorChristophe Lyon <christophe.lyon@linaro.org>
Wed, 8 Jun 2016 12:23:02 +0000 (14:23 +0200)
committerYvan Roux <yvan.roux@linaro.org>
Tue, 14 Jun 2016 14:14:46 +0000 (16:14 +0200)
Backport from trunk r235926.
2016-05-05  Bin Cheng  <bin.cheng@arm.com>

PR tree-optimization/57206
* gcc.dg/vect/pr57206.c: New test.

Change-Id: Iffbbf81752a011e2eae0bc48007e0f1ac8804e21

gcc/testsuite/gcc.dg/vect/pr57206.c [new file with mode: 0644]

diff --git a/gcc/testsuite/gcc.dg/vect/pr57206.c b/gcc/testsuite/gcc.dg/vect/pr57206.c
new file mode 100644 (file)
index 0000000..009688e
--- /dev/null
@@ -0,0 +1,11 @@
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_float } */
+
+void bad0(float * d, unsigned int n)
+{
+  unsigned int i;
+  for (i=n; i>0; --i) 
+    d[n-i] = 0.0;
+}
+
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */