2013-11-19 21:21:00 +00:00
|
|
|
#!/bin/bash
|
2013-11-15 07:11:21 +00:00
|
|
|
|
|
|
|
cd "$( dirname "${BASH_SOURCE[0]}" )"
|
|
|
|
cd ../
|
2013-11-22 20:01:02 +00:00
|
|
|
source ./localize.sh
|
|
|
|
|
2013-11-15 07:11:21 +00:00
|
|
|
BASE=./benchmark/out
|
|
|
|
function run {
|
2016-02-27 21:19:08 +00:00
|
|
|
local runner="$BASE/$1 --log=none"
|
|
|
|
local threads="$2"
|
|
|
|
local iters="$3"
|
|
|
|
shift 3
|
2018-07-11 13:10:00 +00:00
|
|
|
$runner --threads 0 --iterations $iters "$@"
|
2016-02-27 21:19:08 +00:00
|
|
|
if test $threads -gt 0; then
|
|
|
|
$runner --threads $threads --iterations $((iters/threads)) "$@"
|
|
|
|
fi
|
2013-11-15 07:11:21 +00:00
|
|
|
}
|
2015-10-01 22:08:49 +00:00
|
|
|
run test_getline 30 10000000
|
2014-08-14 00:21:22 +00:00
|
|
|
#run test_array_allocation 20 100000
|
|
|
|
#run test_png_encoding1 10 1000
|
|
|
|
#run test_png_encoding2 10 50
|
|
|
|
#run test_to_string1 10 100000
|
|
|
|
#run test_to_string2 10 100000
|
|
|
|
#run test_polygon_clipping 10 1000
|
|
|
|
#run test_polygon_clipping_rendering 10 100
|
2013-11-15 07:11:21 +00:00
|
|
|
run test_proj_transform1 10 100
|
2016-08-26 09:09:22 +00:00
|
|
|
run test_expression_parse 10 10000
|
2015-06-08 22:13:02 +00:00
|
|
|
run test_face_ptr_creation 10 1000
|
|
|
|
run test_font_registration 10 100
|
|
|
|
run test_offset_converter 10 1000
|
2016-03-01 16:09:37 +00:00
|
|
|
#run normalize_angle 0 1000000 --min-duration=0.2
|
2013-11-22 06:47:55 +00:00
|
|
|
|
2016-03-04 20:36:57 +00:00
|
|
|
# commented since this is really slow on travis
|
|
|
|
: '
|
2013-11-22 06:47:55 +00:00
|
|
|
./benchmark/out/test_rendering \
|
|
|
|
--name "text rendering" \
|
|
|
|
--map benchmark/data/roads.xml \
|
|
|
|
--extent 1477001.12245,6890242.37746,1480004.49012,6892244.62256 \
|
|
|
|
--width 600 \
|
|
|
|
--height 600 \
|
|
|
|
--iterations 20 \
|
2014-12-11 20:01:17 +00:00
|
|
|
--threads 10
|
2016-03-04 20:36:57 +00:00
|
|
|
'
|
2014-12-11 20:01:17 +00:00
|
|
|
|
|
|
|
./benchmark/out/test_rendering \
|
|
|
|
--name "gdal tiff rendering" \
|
|
|
|
--map benchmark/data/gdal-wgs.xml \
|
|
|
|
--extent -180.0,-120.0,180.0,120.0 \
|
|
|
|
--width 600 \
|
|
|
|
--height 600 \
|
|
|
|
--iterations 20 \
|
|
|
|
--threads 10
|
|
|
|
|
|
|
|
./benchmark/out/test_rendering \
|
|
|
|
--name "raster tiff rendering" \
|
|
|
|
--map benchmark/data/raster-wgs.xml \
|
|
|
|
--extent -180.0,-120.0,180.0,120.0 \
|
|
|
|
--width 600 \
|
|
|
|
--height 600 \
|
|
|
|
--iterations 20 \
|
|
|
|
--threads 10
|
2015-06-19 12:19:04 +00:00
|
|
|
|
|
|
|
./benchmark/out/test_quad_tree \
|
2015-06-19 15:08:19 +00:00
|
|
|
--iterations 10000 \
|
2015-06-19 12:19:04 +00:00
|
|
|
--threads 1
|
|
|
|
|
|
|
|
./benchmark/out/test_quad_tree \
|
2015-07-29 14:49:23 +00:00
|
|
|
--iterations 1000 \
|
2015-06-19 15:08:19 +00:00
|
|
|
--threads 10
|