i#7023: Switch drmemtrace replay of idles to use record count #7036
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The drmemtrace replay of idles was using wall-clock time to reproduce the duration. A new idle replay type is added here (and made the default) which uses the idle record count instead, leaving support for the old format under the old type.
Idle during replay now properly returns STATUS_IDLE, rather than STATUS_WAIT.
Tested the new idle type on the existing record-replay tests inside scheduler_unit_tests and in core_sharded_test.
Support for the old format is considered best-effort as its use of wall-clock time makes it not able to reproduce precise timing in any case. Tested manually by generating an old-style record and ensuring the new code handled it:
$ clients/bin64/drmemtrace_launcher -indir ../src/clients/drcachesim/tests/drmemtrace.threadsig.x64.tracedir -core_sharded -cores 4 -replay_file ../build_x64_rel_tests/legacy_record.zip
Fixes #7023