summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAníbal Limón <anibal.limon@linaro.org>2018-06-27 15:56:43 -0500
committerAníbal Limón <anibal.limon@linaro.org>2018-06-29 10:13:19 -0500
commit4c2922e9a412d2267ce3272a5667b6d0f6c7bad9 (patch)
tree6052143df515bc883f20453e44708c6fa6d0a56a
parent08fb5d99b9a338f2067085698b973439b0c50da8 (diff)
automated/linux: Add glmark2 test definition
Change-Id: I98be001eeeb8c6cede0692738541e877dd01b176 Signed-off-by: Aníbal Limón <anibal.limon@linaro.org>
-rw-r--r--automated/linux/glmark2/glmark2.yaml25
-rwxr-xr-xautomated/linux/glmark2/glmark2_lava_parse.py50
2 files changed, 75 insertions, 0 deletions
diff --git a/automated/linux/glmark2/glmark2.yaml b/automated/linux/glmark2/glmark2.yaml
new file mode 100644
index 0000000..02c0e8b
--- /dev/null
+++ b/automated/linux/glmark2/glmark2.yaml
@@ -0,0 +1,25 @@
+metadata:
+ format: "Lava-Test Test Definition 1.0"
+ name: glmark2
+ description: "Glmark2 test for Linux is an OpenGL 2.0 and ES 2.0 benchmark. The Glmark2 test suite is used to
+ measure different aspects of OpenGL (ES) 2.0 performance like video, graphics and display."
+ maintainer:
+ - anibal.limon@linaro.org
+ os:
+ - openembedded
+ scope:
+ - performance
+ devices:
+ - dragonboard410c
+ - dragonboard820c
+
+params:
+ DISPLAY: ":0"
+
+run:
+ steps:
+ - export DISPLAY=${DISPLAY}
+ - cd ./automated/linux/glmark2
+ - glmark2 | tee glmark2.log
+ - ./glmark2_lava_parse.py glmark2.log > ./result.txt
+ - ../../utils/send-to-lava.sh ./result.txt
diff --git a/automated/linux/glmark2/glmark2_lava_parse.py b/automated/linux/glmark2/glmark2_lava_parse.py
new file mode 100755
index 0000000..9a918ce
--- /dev/null
+++ b/automated/linux/glmark2/glmark2_lava_parse.py
@@ -0,0 +1,50 @@
+#!/usr/bin/env python3
+
+# LAVA/OE glmark2 results parse script
+#
+# Copyright (C) 2018, Linaro Limited.
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#
+# Author: Aníbal Limón <anibal.limon@linaro.org>
+#
+
+import sys
+import re
+
+if __name__ == '__main__':
+ if len(sys.argv) < 2:
+ print("Usage: %s <result_file>" % sys.argv[0])
+ sys.exit(1)
+
+ rex = re.compile("(?P<test_case_id>.*): (?P<units>FPS): (?P<measurement>\\d+)")
+ score_rex = re.compile("(?P<test_case_id>glmark2 Score): (?P<measurement>\\d+)")
+ with open(sys.argv[1], 'r') as f:
+ for line in f.readlines():
+ m = rex.search(line)
+ if m:
+ case_id = m.group('test_case_id').replace(' ', '_').replace('=', '-')
+ result = 'pass'
+ measurement = m.group('measurement')
+ units = m.group('units')
+
+ print("%s %s %s %s" % (case_id, result, measurement, units))
+
+ m = score_rex.search(line)
+ if m:
+ case_id = m.group('test_case_id').replace(' ', '_').replace('=', '-')
+ result = 'pass'
+ measurement = m.group('measurement')
+ print("%s %s %s" % (case_id, result, measurement))