[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v4 02/15] replay: provide an accessor for rr filename
From: |
Pavel Dovgalyuk |
Subject: |
[PATCH v4 02/15] replay: provide an accessor for rr filename |
Date: |
Mon, 14 Sep 2020 09:06:37 +0300 |
User-agent: |
StGit/0.17.1-dirty |
From: Pavel Dovgalyuk <Pavel.Dovgaluk@ispras.ru>
This patch adds an accessor function for the name of the record/replay
log file. Adding an accessor instead of making variable global,
prevents accidental modification of this variable by other modules.
Signed-off-by: Pavel Dovgalyuk <Pavel.Dovgalyuk@ispras.ru>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
---
include/sysemu/replay.h | 2 ++
replay/replay.c | 5 +++++
2 files changed, 7 insertions(+)
diff --git a/include/sysemu/replay.h b/include/sysemu/replay.h
index 5471bb514d..c9c896ae8d 100644
--- a/include/sysemu/replay.h
+++ b/include/sysemu/replay.h
@@ -72,6 +72,8 @@ void replay_start(void);
void replay_finish(void);
/*! Adds replay blocker with the specified error description */
void replay_add_blocker(Error *reason);
+/* Returns name of the replay log file */
+const char *replay_get_filename(void);
/* Processing the instructions */
diff --git a/replay/replay.c b/replay/replay.c
index 83ed9e0e24..42e82f7bc7 100644
--- a/replay/replay.c
+++ b/replay/replay.c
@@ -399,3 +399,8 @@ void replay_add_blocker(Error *reason)
{
replay_blockers = g_slist_prepend(replay_blockers, reason);
}
+
+const char *replay_get_filename(void)
+{
+ return replay_filename;
+}
- [PATCH v4 00/15] Reverse debugging, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 01/15] replay: don't record interrupt poll, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 02/15] replay: provide an accessor for rr filename,
Pavel Dovgalyuk <=
- [PATCH v4 03/15] qcow2: introduce icount field for snapshots, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 04/15] migration: introduce icount field for snapshots, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 05/15] qapi: introduce replay.json for record/replay-related stuff, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 06/15] replay: introduce info hmp/qmp command, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 07/15] replay: introduce breakpoint at the specified step, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 08/15] replay: implement replay-seek command, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 09/15] replay: flush rr queue before loading the vmstate, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 10/15] gdbstub: add reverse step support in replay mode, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 11/15] gdbstub: add reverse continue support in replay mode, Pavel Dovgalyuk, 2020/09/14
- [PATCH v4 12/15] replay: describe reverse debugging in docs/replay.txt, Pavel Dovgalyuk, 2020/09/14