aboutsummaryrefslogtreecommitdiffstats
path: root/test/mppa
diff options
context:
space:
mode:
authorCyril SIX <cyril.six@kalray.eu>2018-04-18 14:27:44 +0200
committerCyril SIX <cyril.six@kalray.eu>2018-04-18 14:27:44 +0200
commitb7021853e651ddde91450cc83d3c77c5377efc06 (patch)
tree08921a86a644505574b0f8315d14648e4e7e15ec /test/mppa
parent511acb8102b26ec0460f1d3c7ce21a9941f095ff (diff)
downloadcompcert-kvx-b7021853e651ddde91450cc83d3c77c5377efc06.tar.gz
compcert-kvx-b7021853e651ddde91450cc83d3c77c5377efc06.zip
MPPA - added Oaddrsymbol -> now able to run the matrix mult test
Diffstat (limited to 'test/mppa')
-rw-r--r--test/mppa/mmult/.gitignore3
-rw-r--r--test/mppa/mmult/Makefile74
-rw-r--r--test/mppa/mmult/mmult.c2
3 files changed, 42 insertions, 37 deletions
diff --git a/test/mppa/mmult/.gitignore b/test/mppa/mmult/.gitignore
new file mode 100644
index 00000000..5883d367
--- /dev/null
+++ b/test/mppa/mmult/.gitignore
@@ -0,0 +1,3 @@
+mmult-test-k1c
+mmult-test-x86
+test-ccomp
diff --git a/test/mppa/mmult/Makefile b/test/mppa/mmult/Makefile
index 9cb5b9e7..bb4506bf 100644
--- a/test/mppa/mmult/Makefile
+++ b/test/mppa/mmult/Makefile
@@ -10,47 +10,47 @@ all: $(ALL)
%-test-k1c: %.c $(PRNG)
k1-gcc -D__UNIT_TEST_$$(echo $(basename $<) | tr a-z A-Z)__ -O2 -std=c99 $^ -o $@
-#test-x86: selection.c merge.c insertion.c test.c $(PRNG)
-# gcc -g -O2 -std=c99 $^ -o $@
-#
-#test-k1c: selection.c merge.c insertion.c test.c $(PRNG)
-# k1-gcc -g -O2 -std=c99 $^ -o $@
-#
-#%.s: %.c
-# ccomp -O2 -S $< -o $@
-#
-#test-ccomp: selection.s merge.s insertion.s test.s $(subst .c,.s,$(PRNG))
-# k1-gcc $^ -o $@
+test-x86: mmult.c $(PRNG)
+ gcc -g -O2 -std=c99 $^ -o $@
+
+test-k1c: mmult.c $(PRNG)
+ k1-gcc -g -O2 -std=c99 $^ -o $@
+
+%.s: %.c
+ ccomp -O2 -S $< -o $@
+
+test-ccomp: mmult.s $(subst .c,.s,$(PRNG))
+ k1-gcc $^ -o $@
.PHONY:
unittest: unittest-x86 unittest-k1c
-#.PHONY:
-#check: check-x86 check-k1c
-
-#.PHONY:
-#compc-check: test-ccomp
-# @if ! k1-cluster -- ./$<; then\
-# >&2 echo "ERROR k1c: sort $< failed";\
-# else\
-# echo "k1c: Test sort $< succeeded";\
-# fi
-#
-#.PHONY:
-#check-x86: test-x86
-# @if ! ./$<; then\
-# >&2 echo "ERROR x86: $< failed";\
-# else\
-# echo "x86: Test $< succeeded";\
-# fi
-#
-#.PHONY:
-#check-k1c: test-k1c
-# @if ! k1-cluster -- ./$<; then\
-# >&2 echo "ERROR k1c: $< failed";\
-# else\
-# echo "k1c: Test $< succeeded";\
-# fi
+.PHONY:
+check: check-x86 check-k1c
+
+.PHONY:
+compc-check: test-ccomp
+ @if ! k1-cluster -- ./$<; then\
+ >&2 echo "ERROR k1c: sort $< failed";\
+ else\
+ echo "k1c: Test sort $< succeeded";\
+ fi
+
+.PHONY:
+check-x86: test-x86
+ @if ! ./$<; then\
+ >&2 echo "ERROR x86: $< failed";\
+ else\
+ echo "x86: Test $< succeeded";\
+ fi
+
+.PHONY:
+check-k1c: test-k1c
+ @if ! k1-cluster -- ./$<; then\
+ >&2 echo "ERROR k1c: $< failed";\
+ else\
+ echo "k1c: Test $< succeeded";\
+ fi
.PHONY:
unittest-x86: mmult-test-x86
diff --git a/test/mppa/mmult/mmult.c b/test/mppa/mmult/mmult.c
index 04ac4605..16dcf34c 100644
--- a/test/mppa/mmult/mmult.c
+++ b/test/mppa/mmult/mmult.c
@@ -1,6 +1,8 @@
#include "../lib/types.h"
#include "../lib/prng.h"
+#define __UNIT_TEST_MMULT__
+
#ifdef __UNIT_TEST_MMULT__
#define SIZE 50
#else