aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Vesely <jan.vesely@rutgers.edu>2014-09-28 16:30:34 -0400
committerTom Stellard <thomas.stellard@amd.com>2014-10-01 15:25:07 -0400
commit6b4388a2feab656ce3eb18709718e819b5d6376b (patch)
tree3662581d4e1b1b560a813962de5882f89a346255
parent73595a9c580026e7f33853c34b8fe98884990597 (diff)
downloadpiglit-6b4388a2feab656ce3eb18709718e819b5d6376b.tar.gz
cl: Run concurrent on Linux render nodes, or non-Linux
v2: make the flag a module parameter Reviewed-by: Tom Stellard <thomas.stellard@amd.com> Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
-rw-r--r--tests/cl.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/tests/cl.py b/tests/cl.py
index f618f5926..67ed54201 100644
--- a/tests/cl.py
+++ b/tests/cl.py
@@ -7,6 +7,9 @@ __all__ = ['profile']
import os
import os.path as path
+import platform
+import glob
+
from framework.opencv import add_opencv_tests
from framework.profile import TestProfile
@@ -15,14 +18,10 @@ from framework.exectest import PiglitTest
######
# Helper functions
-def add_plain_test(group, name, args):
- group[name] = PiglitTest(args)
+can_do_concurrent = platform.system().lower()[0:5] != 'linux' or glob.glob('/dev/dri/render*')
-# TODO: Use concurrent tests for everything once kernels with render nodes
-# enabled by default (3.16 or newer) are more widely used.
-def add_concurrent_test(group, name, args):
- test = PiglitTest(args, run_concurrent=True)
- group[name] = test
+def add_plain_test(group, name, args):
+ group[name] = PiglitTest(args, run_concurrent=can_do_concurrent)
def add_plain_program_tester_test(group, name, path):
add_plain_test(group, name, ['cl-program-tester', path])