summaryrefslogtreecommitdiff
path: root/libgomp/testsuite/libgomp.graphite/bounds.c
diff options
context:
space:
mode:
Diffstat (limited to 'libgomp/testsuite/libgomp.graphite/bounds.c')
-rw-r--r--libgomp/testsuite/libgomp.graphite/bounds.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/libgomp/testsuite/libgomp.graphite/bounds.c b/libgomp/testsuite/libgomp.graphite/bounds.c
new file mode 100644
index 000000000..bd36c0f8a
--- /dev/null
+++ b/libgomp/testsuite/libgomp.graphite/bounds.c
@@ -0,0 +1,13 @@
+int foo(int *a, int n)
+{
+ int i;
+ for (i = 2; i < n; i++)
+ a[i] += a[i+1];
+}
+
+/* Check that Graphite dependency checking notes the dependency. */
+/* { dg-do compile } */
+/* { dg-final { scan-tree-dump-times "0 loops carried no dependency" 1 "graphite" } } */
+/* { dg-final { cleanup-tree-dump "graphite" } } */
+/* { dg-final { cleanup-tree-dump "parloops" } } */
+/* { dg-final { cleanup-tree-dump "optimized" } } */