From b575fc861bd5a574d0f72a64a7f20d7ba0982de7 Mon Sep 17 00:00:00 2001 From: Vasileios Karakasis Date: Sun, 9 Jun 2019 00:24:04 +0200 Subject: [PATCH] Make GPU burn test generic --- .../microbenchmarks/gpu_burn/gpu_burn_test.py | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/cscs-checks/microbenchmarks/gpu_burn/gpu_burn_test.py b/cscs-checks/microbenchmarks/gpu_burn/gpu_burn_test.py index 6596a0a12e..ae3f076b34 100644 --- a/cscs-checks/microbenchmarks/gpu_burn/gpu_burn_test.py +++ b/cscs-checks/microbenchmarks/gpu_burn/gpu_burn_test.py @@ -22,18 +22,22 @@ def __init__(self): self.executable_opts = ['-d', '40'] self.num_gpus_per_node = 16 gpu_arch = '37' - else: + elif self.current_system.name in {'daint', 'dom'}: self.modules = ['craype-accel-nvidia60'] self.executable_opts = ['-d', '20'] self.num_gpus_per_node = 1 gpu_arch = '60' + else: + self.num_gpus_per_node = 1 + gpu_arch = None self.sourcepath = 'gpu_burn.cu' self.build_system = 'SingleSource' - self.build_system.cxxflags = ['-arch=compute_%s' % gpu_arch, - '-code=sm_%s' % gpu_arch] - self.build_system.ldflags = ['-lcuda', '-lcublas', '-lnvidia-ml'] + if gpu_arch: + self.build_system.cxxflags = ['-arch=compute_%s' % gpu_arch, + '-code=sm_%s' % gpu_arch] + self.build_system.ldflags = ['-lcuda', '-lcublas', '-lnvidia-ml'] self.sanity_patterns = sn.assert_eq( sn.count(sn.findall('OK', self.stdout)), self.num_tasks_assigned) @@ -45,13 +49,16 @@ def __init__(self): self.reference = { 'dom:gpu': { - 'perf': (4115, -0.10, None) + 'perf': (4115, -0.10, None, 'Gflop/s') }, 'daint:gpu': { - 'perf': (4115, -0.10, None) + 'perf': (4115, -0.10, None, 'Gflop/s') }, 'kesch:cn': { - 'perf': (950, -0.10, None) + 'perf': (950, -0.10, None, 'Gflop/s') + }, + '*': { + 'perf': (0, None, None, 'Gflop/s') } }