summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2015-08-20 21:04:54 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2015-08-21 22:31:16 +0100
commit3abc138d749d2c7c4d5eb9405a6de245d3dcd5ce (patch)
tree8b60ba14fb26faa14d7ed8d3ab89bdbe81f57041
parent1714cd0a68bec16de9e053a05777c2fc088ac1ce (diff)
tests: Wrap luxmark for testing beignet (OpenCL)
-rw-r--r--test_options.sh.sample3
-rw-r--r--tests.d/beignet/luxmark.test21
2 files changed, 24 insertions, 0 deletions
diff --git a/test_options.sh.sample b/test_options.sh.sample
index 89346fa..28d8f94 100644
--- a/test_options.sh.sample
+++ b/test_options.sh.sample
@@ -61,6 +61,9 @@ GLBENCHMARK27_FOLDER=/opt/benchmarks/glbenchmark2.7.0
#GLBENCHMARK27_WIDTH=1920
#GLBENCHMARK27_HEIGHT=1080
+# LuxMark settings
+LUXMARK_FOLDER=/opt/benchmarks/luxmark-v3.0
+
# intel-gpu-tools settings
IGT_BENCHMARKS=/opt/intel-gpu-tools/benchmarks
IGT_TRACES=/opt/intel-gpu-tools/traces
diff --git a/tests.d/beignet/luxmark.test b/tests.d/beignet/luxmark.test
new file mode 100644
index 0000000..eb20fb9
--- /dev/null
+++ b/tests.d/beignet/luxmark.test
@@ -0,0 +1,21 @@
+xdpyinfo >/dev/null 2>&1 || return 1 # LuxMark expects an X connection
+
+__luxmark__() {
+ cd $LUXMARK_FOLDER # set me in test_options.sh!
+ for (( c=0; c<$1; c++ )); do
+ LD_LIBRARY_PATH=./lib:$LD_LIBRARY_PATH \
+ ./luxmark.bin --single-run --mode=BENCHMARK_OCL_GPU --scene=$2 \
+ | awk '{print $2 }' || return 1
+ done
+}
+
+while read name scene; do
+ test_name="$test_name luxmark:$name"
+ eval "luxmark:${name}_run() { __luxmark__ \$1 $scene; }"
+done<<EOF
+ LuxBall LUXBALL_HDR
+ Microphone MICROPHONE
+ Hotel HOTEL
+EOF
+
+test_exec_time=121