summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJohn MacFarlane <fiddlosopher@gmail.com>2014-11-17 11:50:23 -0800
committerJohn MacFarlane <fiddlosopher@gmail.com>2014-11-17 11:50:23 -0800
commit01954cef95435ec78d12e2e62defe25d5032a087 (patch)
tree336c29aa560ad65e946d28258a46f6b05d496a59 /Makefile
parent83ef1391dca33815c18965e585cf30335bf23e6f (diff)
More 'make bench' improvements.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 5 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 0f227ee..ad08e28 100644
--- a/Makefile
+++ b/Makefile
@@ -10,7 +10,8 @@ PKGDIR?=cmark-$(SPECVERSION)
TARBALL?=cmark-$(SPECVERSION).tar.gz
ZIPARCHIVE?=cmark-$(SPECVERSION).zip
FUZZCHARS?=2000000 # for fuzztest
-BENCHPATT?="processing lines" # for bench
+BENCHDIR=bench
+BENCHFILE=$(BENCHDIR)/benchinput.md
PROG?=$(BUILDDIR)/src/cmark
BENCHINP?=README.md
JSMODULES=$(wildcard js/lib/*.js)
@@ -115,7 +116,7 @@ fuzztest:
done } 2>&1 | grep 'user\|abnormally'
# for benchmarking
-benchmark.md: progit/progit.md
+$(BENCHFILE): progit/progit.md
-rm $@; for x in `seq 1 40` ; do cat $< >> $@; done
progit:
@@ -124,7 +125,7 @@ progit:
progit/progit.md: progit
cat progit/en/*/*.markdown > $@
-bench: benchmark.md
+bench: $(BENCHFILE)
{ sudo renice 99 $$$$; \
for x in `seq 1 10` ; do \
/usr/bin/env time -p ${PROG} $< >/dev/null ; \
@@ -141,7 +142,7 @@ distclean: clean
-rm -rf *.dSYM
-rm -f README.html
-rm -f spec.md fuzz.txt spec.html
- -rm -rf benchmark.md progit
+ -rm -rf $(BENCHFILE) progit
### JavaScript ###