File: bench

package info (click to toggle)
node-bluebird 3.5.1%2Bdfsg2-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,796 kB
  • sloc: makefile: 90; sh: 38
file content (37 lines) | stat: -rwxr-xr-x 1,032 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/usr/bin/env bash
./build --release --no-debug
benchmark=$1
nodepath=${2:-node}
shift 2;
cwd=${PWD}

trap 'cd "$cwd"' EXIT

if [ "$benchmark" = "doxbee" ]; then
    cd "$cwd/benchmark"
    npm install
    echo "Doxbee sequential"
    $nodepath performance.js --n 10000 --t 1 ./doxbee-sequential/*.js --harmony "$@"
    exit 0
elif [ "$benchmark" = "doxbee-errors" ]; then
    cd "$cwd/benchmark"
    npm install
    echo "Doxbee sequential with 10% errors"
    $nodepath performance.js --n 10000 --t 1 --e 0.1 ./doxbee-sequential-errors/*.js --harmony "$@"
    exit 0
elif [ "$benchmark" = "parallel" ]; then
    cd "$cwd/benchmark"
    npm install
    echo "Madeup parallel"
    $nodepath performance.js --n 10000 --t 1 --p 25 ./madeup-parallel/*.js --harmony "$@"
    exit 0
elif [ "$benchmark" = "analysis" ]; then
    cd "$cwd/benchmark"
    npm install
    echo "analysis"
    $nodepath performance.js --n 10000 --t 1 ./analysis/*.js --harmony "$@"
    exit 0
else
    echo "Invalid benchmark name $benchmark"
    exit -1
fi