Skip to content

Commit

Permalink
Allow setting the amount of warmup values in Runner
Browse files Browse the repository at this point in the history
  • Loading branch information
PiispaH authored Jul 16, 2024
1 parent 7b9a23a commit 168bc95
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pyperf/_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def __init__(self, values=None, processes=None,
loops=0, min_time=0.1, metadata=None,
show_name=True,
program_args=None, add_cmdline_args=None,
_argparser=None):
_argparser=None, warmups=1):

# Reset the stats collection if running a --enable-pystats build
try:
Expand Down Expand Up @@ -165,7 +165,7 @@ def __init__(self, values=None, processes=None,
help='number of values per process (default: %s)'
% values)
parser.add_argument('-w', '--warmups',
type=positive_or_nul,
type=positive_or_nul, default=warmups,
help='number of skipped values per run used '
'to warmup the benchmark')
parser.add_argument('-l', '--loops',
Expand Down

0 comments on commit 168bc95

Please sign in to comment.