mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 15:23:53 -06:00
replay: rewrite async event handling
This patch decouples checkpoints and async events. It was a tricky part of replay implementation. Now it becomes much simpler and easier to maintain. Signed-off-by: Pavel Dovgalyuk <Pavel.Dovgalyuk@ispras.ru> Acked-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <165364837856.688121.8785039478408995979.stgit@pasha-ThinkPad-X280> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
75bbe5e5ec
commit
60618e2d77
8 changed files with 54 additions and 76 deletions
|
@ -87,8 +87,6 @@ typedef struct ReplayState {
|
|||
int32_t read_event_kind;
|
||||
/*! Asynchronous event id read from the log */
|
||||
uint64_t read_event_id;
|
||||
/*! Asynchronous event checkpoint id read from the log */
|
||||
int32_t read_event_checkpoint;
|
||||
} ReplayState;
|
||||
extern ReplayState replay_state;
|
||||
|
||||
|
@ -152,9 +150,9 @@ void replay_finish_events(void);
|
|||
/*! Returns true if there are any unsaved events in the queue */
|
||||
bool replay_has_events(void);
|
||||
/*! Saves events from queue into the file */
|
||||
void replay_save_events(int checkpoint);
|
||||
void replay_save_events(void);
|
||||
/*! Read events from the file into the input queue */
|
||||
void replay_read_events(int checkpoint);
|
||||
void replay_read_events(void);
|
||||
/*! Adds specified async event to the queue */
|
||||
void replay_add_event(ReplayAsyncEventKind event_kind, void *opaque,
|
||||
void *opaque2, uint64_t id);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue