added benchmarks and scripts to run, parse and plot them

moved benchmark/run-slow-benchmarks.sh's content to Makefile
This commit is contained in:
Manuel Carmona
2017-06-28 13:01:36 +02:00
parent 2045abfa41
commit 8d91dc7be8
11 changed files with 872 additions and 18 deletions

View File

@ -32,6 +32,16 @@ code-generate: $(LINGUIST_PATH)
mkdir -p data
go run internal/code-generator/main.go
benchmarks: $(LINGUIST_PATH)
go test -run=NONE -bench=. && benchmark/linguist-total.sh
benchmarks-samples: $(LINGUIST_PATH)
go test -run=NONE -bench=. -benchtime=5us && benchmark/linguist-samples.rb
benchmarks-slow: $(LINGUST_PATH)
go test -run=NONE -bench=. -slow -benchtime=100ms -timeout=100h >benchmark/output/enry_samples.bench && \
benchmark/linguist-samples.rb 5 >benchmark/output/linguist_samples.bench
clean:
rm -rf $(LINGUIST_PATH)