gem5: gem-regression downloads test binaries to a fixed location outside of source tree with the newly added --bin-path option

Otherwise each --gem5-worktree would download its own copy of the test
binaries into its own source tree.
This commit is contained in:
Ciro Santilli 六四事件 法轮功
2020-02-23 00:00:02 +00:00
parent 2f7047024d
commit 0fdd354551
3 changed files with 7 additions and 3 deletions

View File

@@ -12220,6 +12220,8 @@ Note that the command and it's corresponding results don't need to show consecut
==== gem5 regression tests
This section is about running the gem5 in-tree tests.
https://stackoverflow.com/questions/52279971/how-to-run-the-gem5-unit-tests
Running the larger 2019 regression tests is exposed for example with:
@@ -12229,13 +12231,13 @@ Running the larger 2019 regression tests is exposed for example with:
./gem5-regression --arch aarch64 -- --length quick --length long
....
After the first run has downloaded the test binaries for you, you can speed up the process a little bit by skipping an useless scons call:
After the first run has downloaded the test binaries for you, you can speed up the process a little bit by skipping an useless SCons call:
....
./gem5-regression --arch aarch64 -- --length quick --length long --skip-build
....
Note however that `--skip-build` is required at least once per branch to download the test binaries, because the test interface is bad.
Note however that running without `--skip-build` is required at least once to download the test binaries, because the test interface is bad.
List available instead of running them:
@@ -12243,7 +12245,7 @@ List available instead of running them:
./gem5-regression --gem5-worktree master --arch aarch64 --cmd list
....
You can then pick one suite from the list (not tests) and run just it e.g. with:
You can then pick one suite (has to be a suite, not an "individual test") from the list and run just it e.g. with:
....
./gem5-regression --arch aarch64 -- --uid SuiteUID:tests/gem5/cpu_tests/test.py:cpu_test_AtomicSimpleCPU_Bubblesort-ARM-opt

View File

@@ -844,6 +844,7 @@ Incompatible archs are skipped.
# gem5
if not env['_args_given']['gem5_build_dir']:
env['gem5_build_dir'] = join(env['gem5_out_dir'], env['gem5_build_id'])
env['gem5_test_binaries_dir'] = join(env['gem5_out_dir'], 'test_binaries')
env['gem5_m5term'] = join(env['gem5_build_dir'], 'm5term')
env['gem5_build_build_dir'] = join(env['gem5_build_dir'], 'build')
env['gem5_executable_dir'] = join(env['gem5_build_build_dir'], env['gem5_arch'])

View File

@@ -33,6 +33,7 @@ List tests instead of running them.
if self.env['cmd'] == 'run':
extra_args = [
'--base-dir', self.env['gem5_source_dir'], LF,
'--bin-path', self.env['gem5_test_binaries_dir'], LF,
'--build-dir', self.env['gem5_build_build_dir'], LF,
'-j', str(self.env['nproc']), LF,
'-t', str(self.env['nproc']), LF,