bench_command "nitmd" "markdown" "./nitmd.$title.bin" markdown/benches/out/mixed.md 80
run_command "$@" ../contrib/jwrapper/src/jwrapper.nit -o "jwrapper.$title.bin"
bench_command "jwrapper" "jwrapper ant.jar" "./jwrapper.$title.bin" /usr/share/java/ant.jar -o out/ant_jar.nit
+ rm -r tmp 2> /dev/null # remove jwrapper output directory
fi
rm -r *.bin out 2> /dev/null
bench_nitc_options "misc" "" --log --typing-test-metrics --invocation-metrics --isset-checks-metrics --tables-metrics --no-stacktrace --release --debug #FIXME add --sloppy
+# sanitary just run the default configuration, this is used to check that `run_compiler` works.
+bench_nitc_options "sanitary" ""
+
function bench_nitc-e_gc()
{
name="$FUNCNAME"
# See the License for the specific language governing permissions and
# limitations under the License.
-all: nitmd/nitmd txtmark/Txtmark.class markdown4j/Markdown4j.class pandoc/pandoc
+all: nitmd/nitmd txtmark/Txtmark.class markdown4j/Markdown4j.class
nitmd/nitmd:
make -C nitmd
./bench_strings.sh index 10000000 50 25 200
check: basic
+ ./bench_strings.sh concat 10000 15 10 2 20
+ ./bench_strings.sh substring 25000 50 25 200
+ ./bench_strings.sh iteration 10000 10 10 100
+ ./bench_strings.sh index 100000 50 25 200
basic:
./bench_strings.sh basic
fi
echo "Generating executable chain_concat for variant $variant"
- ../../bin/nitc chain_concat.nit -D maxlen=$curr_maxlen
+ ../../bin/nitc chain_concat.nit -D maxlen=$curr_maxln
bench_concat_variant "string" $1 $2 $3 $4 $5
bench_concat_variant "buffer" $1 $2 $3 $4 $5
exit
fi
echo "Generating executable iteration_bench for variant $variant"
- ../../bin/nitc --global iteration_bench.nit -D maxlen=$curr_maxlen
+ ../../bin/nitc --global iteration_bench.nit -D maxlen=$curr_maxln
bench_iterate_variant "iterator" "string" $1 $2 $3 $4
bench_iterate_variant "index" "string" $1 $2 $3 $4
exit
fi
echo "Generating executable substr_bench for variant $variant"
- ../../bin/nitc --global substr_bench.nit -D maxlen=$curr_maxlen
+ ../../bin/nitc --global substr_bench.nit -D maxlen=$curr_maxln
bench_substring_variant "string" $1 $2 $3 $4
bench_substring_variant "buffer" $1 $2 $3 $4
../../bin/nitc ../../src/nitc.nit -o ../../bin/nitc
echo "nitc (2/2)"
- bench_command nitc nitc_$variant ../../bin/nitc ../../src/nitc.nit -D maxlen=$curr_maxlen
+ bench_command nitc nitc_$variant ../../bin/nitc ../../src/nitc.nit -D maxlen=$curr_maxln
rm nitc
}
function bench_basic()
{
- ../../bin/nitc ../../examples/hello_world.nit -D maxlen=$curr_maxlen
+ echo ../../bin/nitc ../../examples/hello_world.nit -D maxlen=$curr_maxln
+ ../../bin/nitc ../../examples/hello_world.nit -D maxlen=$curr_maxln
./hello_world
rm hello_world
}