diff options
author | Pavel Dovgalyuk <pavel.dovgalyuk@ispras.ru> | 2022-05-27 13:46:23 +0300 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2022-06-06 09:26:53 +0200 |
commit | 3e21408b0596aa2babe1e26996a15e7ad5eee71a (patch) | |
tree | bf75b38196d4954205aecba7bd279abe7d484ce7 /replay/replay.c | |
parent | 60618e2d77691e44bb78e23b2b0cf07b5c405e56 (diff) |
replay: simplify async event processing
This patch joins replay event id and async event id into single byte in the log.
It makes processing a bit faster and log a bit smaller.
Signed-off-by: Pavel Dovgalyuk <Pavel.Dovgalyuk@ispras.ru>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
--
v2: minor enum fixes (suggested by Richard Henderson)
Message-Id: <165364838393.688121.8191379555130516329.stgit@pasha-ThinkPad-X280>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'replay/replay.c')
-rw-r--r-- | replay/replay.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/replay/replay.c b/replay/replay.c index ccd7edec76..4c396bb376 100644 --- a/replay/replay.c +++ b/replay/replay.c @@ -22,7 +22,7 @@ /* Current version of the replay mechanism. Increase it when file format changes. */ -#define REPLAY_VERSION 0xe0200b +#define REPLAY_VERSION 0xe0200c /* Size of replay log header */ #define HEADER_SIZE (sizeof(uint32_t) + sizeof(uint64_t)) @@ -221,7 +221,8 @@ bool replay_has_event(void) replay_account_executed_instructions(); res = EVENT_CHECKPOINT <= replay_state.data_kind && replay_state.data_kind <= EVENT_CHECKPOINT_LAST; - res = res || replay_state.data_kind == EVENT_ASYNC; + res = res || (EVENT_ASYNC <= replay_state.data_kind + && replay_state.data_kind <= EVENT_ASYNC_LAST); } return res; } |