Skip to content

Commit

Permalink
Add support to prevent execution
Browse files Browse the repository at this point in the history
This is essentially a dry-run, and allows to check whether the loads configuration.

Signed-off-by: Stefan Marr <git@stefan-marr.de>
  • Loading branch information
smarr committed Aug 2, 2018
1 parent 43a1d15 commit 4611f38
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
11 changes: 11 additions & 0 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,17 @@ For this purpose we use *schedulers* to determine the execution order.
random [default: batch]
```

#### Prevent Execution to Verify Configuration

To check whether a configuration is correct, it can be useful to avoid
execution altogether. For such *testing* or *dry run*, we have the following
option:

```text
-E, --no-execution Disables execution. It allows to verify the
configuration file and other parameters.
```

#### Continuous Performance Tracking

ReBench supports [Codespeed][1] as platform for continuous performance
Expand Down
11 changes: 10 additions & 1 deletion rebench/rebench.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,11 @@ def shell_options(self):
default='batch',
help='execution order of benchmarks: '
'batch, round-robin, random [default: %(default)s]')
execution.add_argument(
'-E', '--no-execution', action='store_true', dest='no_execution',
default=False,
help='Disables execution.'
' It allows to verify the configuration file and other parameters.')

data = parser.add_argument_group(
'Data and Reporting',
Expand Down Expand Up @@ -220,7 +225,11 @@ def execute_experiment(self, runs):
self._config.options.debug,
scheduler_class,
self._config.build_log)
return executor.execute()

if self._config.options.no_execution:
return True
else:
return executor.execute()


def main_func():
Expand Down

0 comments on commit 4611f38

Please sign in to comment.