summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Verdoolaege <skimo@kotnet.org>2010-03-10 13:40:08 +0100
committerSven Verdoolaege <skimo@kotnet.org>2010-03-10 17:23:02 +0100
commit08232ef0e9687f7daa0e122fbe211df055456b72 (patch)
tree7031f0ccd218200c8850098f001da774ac33bcda
parentc841d8e3476d706c45b9b8f964a4717c417f0f5f (diff)
downloadisl-08232ef0e9687f7daa0e122fbe211df055456b72.tar.gz
isl-08232ef0e9687f7daa0e122fbe211df055456b72.tar.bz2
isl-08232ef0e9687f7daa0e122fbe211df055456b72.zip
add some pip tests from the piplib distribution
-rw-r--r--Makefile.am3
-rwxr-xr-xpip_test.sh21
-rw-r--r--test_inputs/boulet.pip13
-rw-r--r--test_inputs/brisebarre.pip34
-rw-r--r--test_inputs/cg1.pip15
-rw-r--r--test_inputs/esced.pip27
-rw-r--r--test_inputs/ex.pip9
-rw-r--r--test_inputs/ex2.pip9
-rw-r--r--test_inputs/fimmel.pip12
-rw-r--r--test_inputs/max.pip9
-rw-r--r--test_inputs/negative.pip9
-rw-r--r--test_inputs/small.pip9
-rw-r--r--test_inputs/sor1d.pip28
-rw-r--r--test_inputs/square.pip9
-rw-r--r--test_inputs/sven.pip7
15 files changed, 213 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 1688c95e..cac79592 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -8,7 +8,7 @@ noinst_PROGRAMS = isl_test isl_polyhedron_sample isl_pip \
isl_polyhedron_minimize isl_polytope_scan \
isl_polyhedron_detect_equalities isl_cat \
isl_closure
-TESTS = isl_test
+TESTS = isl_test pip_test.sh
if HAVE_PIPLIB
ISL_PIPLIB = \
@@ -173,6 +173,7 @@ EXTRA_DIST = \
doc/mypod2latex \
doc/manual.tex \
doc/user.pod \
+ pip_test.sh \
test_inputs
dist-hook:
diff --git a/pip_test.sh b/pip_test.sh
new file mode 100755
index 00000000..2d97a352
--- /dev/null
+++ b/pip_test.sh
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+PIP_TESTS="\
+ boulet.pip \
+ brisebarre.pip \
+ cg1.pip \
+ esced.pip \
+ ex2.pip \
+ ex.pip \
+ fimmel.pip \
+ max.pip \
+ negative.pip \
+ small.pip \
+ sor1d.pip \
+ square.pip \
+ sven.pip"
+
+for i in $PIP_TESTS; do
+ echo $i;
+ ./isl_pip$EXEEXT -T < $srcdir/test_inputs/$i || exit
+done
diff --git a/test_inputs/boulet.pip b/test_inputs/boulet.pip
new file mode 100644
index 00000000..78e90ddf
--- /dev/null
+++ b/test_inputs/boulet.pip
@@ -0,0 +1,13 @@
+0 3
+
+-1
+
+5 6
+1 1 -1 2 0 0
+1 0 1 1 4 20
+1 0 -1 -1 0 0
+1 0 1 -1 2 10
+1 0 -1 1 2 10
+
+Urs_parms
+Urs_unknowns
diff --git a/test_inputs/brisebarre.pip b/test_inputs/brisebarre.pip
new file mode 100644
index 00000000..5d25dae3
--- /dev/null
+++ b/test_inputs/brisebarre.pip
@@ -0,0 +1,34 @@
+# ---------------------- CONTEXT ----------------------
+1 2
+1 0
+
+-1
+
+# ----------------------- DOMAIN ----------------------
+26 6
+1 3 0 0 0 -98300
+1 -3 0 0 0 98308
+1 432 36 6 1 -14757611
+1 -432 -36 -6 -1 14758510
+1 54 9 3 1 -1923190
+1 -54 -9 -3 -1 1923303
+1 48 12 6 3 -1782238
+1 -48 -12 -6 -3 1782339
+1 27 9 6 4 -1045164
+1 -27 -9 -6 -4 1045221
+1 432 180 150 125 -17434139
+1 -432 -180 -150 -125 17435038
+1 6 3 3 3 -252443
+1 -6 -3 -3 -3 252456
+1 432 252 294 343 -18949275
+1 -432 -252 -294 -343 18950174
+1 27 18 24 32 -1234720
+1 -27 -18 -24 -32 1234777
+1 48 36 54 81 -2288453
+1 -48 -36 -54 -81 2288554
+1 54 45 75 125 -2684050
+1 -54 -45 -75 -125 2684163
+1 432 396 726 1331 -22386005
+1 -432 -396 -726 -1331 22386904
+1 3 3 6 12 -162072
+1 -3 -3 -6 -12 162080
diff --git a/test_inputs/cg1.pip b/test_inputs/cg1.pip
new file mode 100644
index 00000000..78e31f18
--- /dev/null
+++ b/test_inputs/cg1.pip
@@ -0,0 +1,15 @@
+2 4
+ 1 1 0 -1
+ 1 -1 1 0
+
+-1
+
+8 7
+ 1 0 1 0 -1 0 0
+ 1 0 -1 0 1 0 0
+ 1 1 0 0 0 -1 0
+ 1 -1 0 0 0 1 0
+ 1 0 1 0 0 0 -1
+ 1 0 -1 0 0 1 0
+ 1 0 -1 1 0 0 -1
+ 1 0 0 -1 0 1 0
diff --git a/test_inputs/esced.pip b/test_inputs/esced.pip
new file mode 100644
index 00000000..dbf56ffa
--- /dev/null
+++ b/test_inputs/esced.pip
@@ -0,0 +1,27 @@
+0 2
+
+-1
+
+16 18
+1 0 0 0 0 0 0 0 0 -1 0 0 1 0 0 0 0 0
+1 0 0 0 0 0 0 0 0 0 -1 0 0 1 0 0 0 0
+1 0 0 0 0 0 0 0 0 0 0 -1 0 0 1 0 0 0
+1 0 0 0 0 0 0 0 0 0 0 0 0 1 -1 0 0 0
+1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0
+1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0
+
+
+0 0 0 0 -1 0 0 0 0 1 -1 0 0 0 0 0 0 0
+0 0 0 0 0 -1 0 0 0 0 0 1 0 0 0 0 0 0
+
+0 -1 0 0 0 0 0 0 0 0 1 -1 0 0 0 0 0 0
+
+0 0 0 0 0 0 -1 0 0 0 0 0 1 -1 0 -1 0 0
+0 0 0 0 0 0 0 -1 0 0 0 0 0 0 1 0 0 0
+0 0 0 0 0 0 0 0 -1 0 0 0 0 0 0 0 1 0
+
+0 0 0 0 0 0 0 0 0 0 0 0 0 1 -1 0 0 0
+0 0 -1 0 0 0 0 0 0 0 0 0 0 0 0 1 -1 0
+
+1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1
+1 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 -1
diff --git a/test_inputs/ex.pip b/test_inputs/ex.pip
new file mode 100644
index 00000000..a405450b
--- /dev/null
+++ b/test_inputs/ex.pip
@@ -0,0 +1,9 @@
+1 5
+1 -1 1 1 0
+
+-1
+
+3 7
+1 0 -1 0 1 0 0
+1 -1 0 0 0 1 0
+1 1 1 -1 0 0 0
diff --git a/test_inputs/ex2.pip b/test_inputs/ex2.pip
new file mode 100644
index 00000000..bb59848c
--- /dev/null
+++ b/test_inputs/ex2.pip
@@ -0,0 +1,9 @@
+1 5
+1 -1 1 1 0
+
+-1
+
+3 7
+1 0 -1 0 1 0 0
+1 -1 0 0 0 1 0
+1 1 1 -1 0 0 0
diff --git a/test_inputs/fimmel.pip b/test_inputs/fimmel.pip
new file mode 100644
index 00000000..a6dee417
--- /dev/null
+++ b/test_inputs/fimmel.pip
@@ -0,0 +1,12 @@
+0 4
+
+-1
+
+7 6
+1 2 6 0 0 -9
+1 5 -3 0 0 0
+1 2 -10 0 0 15
+1 -2 6 0 0 -3
+1 -2 -6 0 0 17
+1 0 1 -1 0 0
+1 1 0 0 -1 0
diff --git a/test_inputs/max.pip b/test_inputs/max.pip
new file mode 100644
index 00000000..e8af57b9
--- /dev/null
+++ b/test_inputs/max.pip
@@ -0,0 +1,9 @@
+0 3
+
+-1
+
+4 5
+1 -1 0 1 0
+1 0 -1 1 0
+1 -1 3 -2 12
+1 2 -1 -1 3
diff --git a/test_inputs/negative.pip b/test_inputs/negative.pip
new file mode 100644
index 00000000..45090a59
--- /dev/null
+++ b/test_inputs/negative.pip
@@ -0,0 +1,9 @@
+1 3
+# n 1
+1 1 -1 # n >= 1
+-1
+
+2 4
+# i n 1
+1 1 0 1 # i >= -1
+1 -1 1 0 # i <= n
diff --git a/test_inputs/small.pip b/test_inputs/small.pip
new file mode 100644
index 00000000..59557d26
--- /dev/null
+++ b/test_inputs/small.pip
@@ -0,0 +1,9 @@
+0 2
+
+-1
+
+4 4
+1 1 0 0
+1 0 1 0
+1 1 -3 12
+1 -2 1 3
diff --git a/test_inputs/sor1d.pip b/test_inputs/sor1d.pip
new file mode 100644
index 00000000..1bef89e5
--- /dev/null
+++ b/test_inputs/sor1d.pip
@@ -0,0 +1,28 @@
+2 4
+ 1 1 0 0
+ 1 0 1 0
+
+-1
+
+20 8
+
+ 0 -1 0 0 0 0 0 2
+ 0 0 -1 0 0 0 0 1
+ 0 0 0 -1 0 0 0 2
+ 0 0 0 0 -1 0 0 4
+ 1 0 0 0 1 0 0 -2
+ 1 -2 0 2 1 0 0 -4
+ 1 0 0 0 -1 0 1 -1
+ 1 2 0 -2 -1 0 0 5
+ 1 0 0 1 0 0 0 -1
+ 1 0 -2 1 0 0 0 0
+ 1 -2 0 2 0 0 1 -5
+ 1 0 0 -1 0 1 0 0
+ 1 0 2 -1 0 0 0 1
+ 1 2 0 -2 0 0 0 3
+ 1 0 1 0 0 0 0 0
+ 1 -2 4 0 0 0 1 -3
+ 1 0 -2 0 0 1 0 0
+ 1 2 -4 0 0 0 0 3
+ 1 2 0 0 0 0 0 1
+ 1 -2 0 0 0 2 1 -5
diff --git a/test_inputs/square.pip b/test_inputs/square.pip
new file mode 100644
index 00000000..7bb3f0c9
--- /dev/null
+++ b/test_inputs/square.pip
@@ -0,0 +1,9 @@
+0 3
+
+-1
+
+4 5
+1 1 0 0 0
+1 -1 0 1 0
+1 0 1 0 0
+1 0 -1 1 0
diff --git a/test_inputs/sven.pip b/test_inputs/sven.pip
new file mode 100644
index 00000000..86027691
--- /dev/null
+++ b/test_inputs/sven.pip
@@ -0,0 +1,7 @@
+0 3
+
+-1
+
+2 3
+1 1 -4
+1 -1 10