From 95deb6e70ac6680d2640bc9ee72aee5892f599bf Mon Sep 17 00:00:00 2001 From: Ulya Trofimovich Date: Wed, 9 Aug 2017 08:47:51 +0100 Subject: [PATCH] Amended README instructions for benchmarks. --- re2c/benchmarks/README | 53 +++++++++++++++++++++++++++++++----------- 1 file changed, 39 insertions(+), 14 deletions(-) diff --git a/re2c/benchmarks/README b/re2c/benchmarks/README index 74a7cfd5..b18897bf 100644 --- a/re2c/benchmarks/README +++ b/re2c/benchmarks/README @@ -1,22 +1,47 @@ -In order to reproduce benchmark results, one should first generate input data. -Random data can be generated with the following programs (written in haskell): +To run benchmarks: - http/gen/gen_http.hs - uri/gen/gen_uri.hs +1. Create symlink to the RE2C binary (version 1.0 or older) in the current +directory. -Use the following scripts to build generators: +2. Generate input data: files ./http/gen/http.dat and ./uri/gen/uri.dat. + Random data can be generated with the following programs (written in + haskell): - http/gen/mk_gen.sh - uri/gen/mk_gen.sh + http/gen/gen_http.hs + uri/gen/gen_uri.hs -The size of the generated data is hard-coded in the source code of generators -(and can be easily tweaked). + Use the following scripts to build generators: + + http/gen/mk_gen.sh + uri/gen/mk_gen.sh + + The size of the generated data is hard-coded in the source code of + generators (and can be easily tweaked). + + Alternatively, if you don't have haskell compiler or for any other reason + are unable to build generators, use small data samples provided for each + benchmark (one can copy-paste them many times with 'cat' to obtain a large + input file): + + http/gen/sample.dat + uri/gen/sample.dat + +3.Run scripts: + ./http/simple/__bench.sh + ./http/simple/__bench_b.sh + ./http/simple/__bench_unopt.sh + ./http/rfc7230/__bench.sh + ./http/rfc7230/__bench_b.sh + ./http/rfc7230/__bench_unopt.sh + ./uri/simple/__bench.sh + ./uri/simple/__bench_b.sh + ./uri/simple/__bench_unopt.sh + ./uri/rfc3986/__bench.sh + ./uri/rfc3986/__bench_b.sh + ./uri/rfc3986/__bench_unopt.sh + + Alternatively, run ./__run.sh (it will drop logs in each subdirectory). -Alternatively, if you don't have haskell compiler or for any other reason are -unable to build generators, use small data samples provided for each benchmark -(one can copy-paste them many times with 'cat' to obtain a large input file): - http/gen/sample.dat - uri/gen/sample.dat -- 2.40.0