Commit 174c209f authored by Chenggang Zhao's avatar Chenggang Zhao
Browse files

Fix bench warmup counts

parent c18eabde
...@@ -162,7 +162,7 @@ def bench_kineto(fn, kernel_names: Union[str, tuple], num_tests: int = 30, suppr ...@@ -162,7 +162,7 @@ def bench_kineto(fn, kernel_names: Union[str, tuple], num_tests: int = 30, suppr
# Profile # Profile
suppress = suppress_stdout_stderr if suppress_kineto_output else empty_suppress suppress = suppress_stdout_stderr if suppress_kineto_output else empty_suppress
with suppress(): with suppress():
schedule = torch.profiler.schedule(wait=0, warmup=1, active=1, repeat=1) schedule = torch.profiler.schedule(wait=1, warmup=0, active=1, repeat=1)
with torch.profiler.profile(activities=[torch.profiler.ProfilerActivity.CUDA], schedule=schedule) as prof: with torch.profiler.profile(activities=[torch.profiler.ProfilerActivity.CUDA], schedule=schedule) as prof:
for i in range(2): for i in range(2):
# NOTES: use a large kernel and a barrier to eliminate the unbalanced CPU launch overhead # NOTES: use a large kernel and a barrier to eliminate the unbalanced CPU launch overhead
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment