Skip to content

Commit c360e99

Browse files
committed
[Benchmarks] add SubmitKernel run with MeasureCompletion=1
1 parent 2628c2e commit c360e99

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

scripts/benchmarks/benches/compute.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ def benchmarks(self) -> list[Benchmark]:
7878

7979
if options.ur is not None:
8080
benches += [
81-
SubmitKernelUR(self, 0),
82-
SubmitKernelUR(self, 1),
81+
SubmitKernelUR(self, 0, 0),
82+
SubmitKernelUR(self, 1, 0),
83+
SubmitKernelUR(self, 1, 1),
8384
]
8485

8586
return benches
@@ -180,13 +181,14 @@ def bin_args(self) -> list[str]:
180181
]
181182

182183
class SubmitKernelUR(ComputeBenchmark):
183-
def __init__(self, bench, ioq):
184+
def __init__(self, bench, ioq, measureCompletion):
184185
self.ioq = ioq
186+
self.measureCompletion = measureCompletion
185187
super().__init__(bench, "api_overhead_benchmark_ur", "SubmitKernel")
186188

187189
def name(self):
188190
order = "in order" if self.ioq else "out of order"
189-
return f"api_overhead_benchmark_ur SubmitKernel {order}"
191+
return f"api_overhead_benchmark_ur SubmitKernel {order}" + (" with measure completion" if self.measureCompletion else "")
190192

191193
def explicit_group(self):
192194
return "SubmitKernel"
@@ -195,7 +197,7 @@ def bin_args(self) -> list[str]:
195197
return [
196198
f"--Ioq={self.ioq}",
197199
"--DiscardEvents=0",
198-
"--MeasureCompletion=0",
200+
f"--MeasureCompletion={self.measureCompletion}",
199201
"--iterations=100000",
200202
"--Profiling=0",
201203
"--NumKernels=10",

0 commit comments

Comments
 (0)