gem5-gpu includes gem5-style regressions tests to avoid common bugs and maintain simulated system performance consistency across changesets. If you would like to contribute to gem5-gpu, you must ensure that your changes pass the included regression tests.
To run the gem5-gpu regression tester is simple. From your gem5-gpu/gem5 directory, execute:
To see other options for the regression tester, simply pass the –help flag. This command will compile gem5-gpu with each of the working coherence protocols, and it will run various test applications. Each test should result in output like this before you commit your changes:
... **** build/ALPHA/tests/opt/quick/se_gpu/10.backprop/x86/linux/gem5-gpu-ruby-VI_hammer PASSED! ...
If the regressions output differs from a patch that you will be contributing to gem5-gpu, you will need to check in the output file changes (e.g. reasonable statistics changes). The output from your test will look like this:
... **** build/X86_VI_hammer_GPU/tests/opt/quick/se_gpu/10.backprop/x86/linux/gem5-gpu-ruby-VI_hammer CHANGED! ...
You can check the stats that have changed either as they are printed on the command line or by looking at the file the build directory (e.g. build/X86_VI_hammer_GPU/tests/opt/quick/se_gpu/10.backprop/x86/linux/gem5-gpu-ruby-VI_hammer/statsdiff) To update the output files in your gem5-gpu repository, re-run the tester with the flag:
Sometimes your changes will cause existing regressions to fail. The regression tester output will look like this:
... **** build/X86_VI_hammer_GPU/tests/opt/quick/se_gpu/10.backprop/x86/linux/gem5-gpu-ruby-VI_hammer FAILED! ...
In this case, you need to debug the cause of the failure to fix it. Optimally, you can find and fix these bugs before you submit a patch for review, but certainly try to fix any bugs before committing your changes. To check the output of the simulation, you will want to inspect the simout and simerr files in the specified test directory.