build and use an easy ./bench binary

This commit is contained in:
Simon Michael 2008-12-10 20:46:18 +00:00
parent ff6d3f40c1
commit e5035ed42a

View File

@ -1,3 +1,4 @@
# executables for "make bench". prepend ./ to these if not in $PATH
BENCHEXES=hledger ledger BENCHEXES=hledger ledger
BUILD=ghc --make hledger.hs -o hledger -O BUILD=ghc --make hledger.hs -o hledger -O
@ -34,11 +35,13 @@ profile:
cp simple.prof profs/$(TIME).prof cp simple.prof profs/$(TIME).prof
cat simple.prof cat simple.prof
BENCHITERATIONS=2
# run performance benchmarks and save results in profs # run performance benchmarks and save results in profs
# prepend ./ to executables if not in $PATH bench: buildbench
bench: ./bench $(BENCHEXES) | tee profs/`date +%Y%m%d%H%M%S`.bench
tools/bench.hs bench.tests $(BENCHITERATIONS) $(BENCHEXES) | tee profs/`date +%Y%m%d%H%M%S`.bench
buildbench:
ghc --make tools/bench.hs
rm -f bench; ln -s tools/bench
VERSION=`grep 'versionno =' Options.hs | perl -pe 's/.*"(.*?)"/\1/'` VERSION=`grep 'versionno =' Options.hs | perl -pe 's/.*"(.*?)"/\1/'`
release: release: