aboutsummaryrefslogtreecommitdiffstats
path: root/test/monniaux/csmith
diff options
context:
space:
mode:
authorDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-03-20 18:26:04 +0100
committerDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-03-20 18:26:04 +0100
commitc4661a0181e6db3aa4a36939bdbea5948eadb6c9 (patch)
tree4c06dc0e51ef4208d668bb72db8bb1006efe008c /test/monniaux/csmith
parent4f17ea42b77c02f8632906cfc33f29fc62a43123 (diff)
downloadcompcert-kvx-c4661a0181e6db3aa4a36939bdbea5948eadb6c9.tar.gz
compcert-kvx-c4661a0181e6db3aa4a36939bdbea5948eadb6c9.zip
csmith for testing
Diffstat (limited to 'test/monniaux/csmith')
-rw-r--r--test/monniaux/csmith/Makefile23
1 files changed, 23 insertions, 0 deletions
diff --git a/test/monniaux/csmith/Makefile b/test/monniaux/csmith/Makefile
new file mode 100644
index 00000000..b094e425
--- /dev/null
+++ b/test/monniaux/csmith/Makefile
@@ -0,0 +1,23 @@
+CSMITH=csmith
+MAX=100
+
+include ../rules.mk
+K1C_CCOMPFLAGS+=-I/usr/include/csmith -fstruct-passing -fbitfields
+
+TARGETS_S=$(shell seq --format src%06.f.ccomp.k1c.s 0 $(MAX))
+TARGETS_C=$(shell seq --format src%06.f.c 0 $(MAX))
+TARGETS_O=$(shell seq --format src%06.f.ccomp.k1c.o 0 $(MAX))
+
+all: c s o
+
+s: $(TARGETS_S)
+c: $(TARGETS_C)
+o: $(TARGETS_O)
+
+src%.c :
+ $(CSMITH) --output $@ --seed $*
+
+clean:
+ -rm -f $(TARGETS_C) $(TARGETS_S) $(TARGETS_O)
+
+.PHONY: s c o clean