aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2025-03-06 18:58:53 -0800
committerRichard Henderson <richard.henderson@linaro.org>2025-03-08 07:55:50 -0800
commit5469933810b00589d5db36408dd4e0236eec95ac (patch)
tree790e6eeb235471db09e5166c3f2ecc812e252f17
parentb9e3bf884aaa2d243fa3554c4dafea293187aa02 (diff)
downloadqemu-5469933810b00589d5db36408dd4e0236eec95ac.zip
qemu-5469933810b00589d5db36408dd4e0236eec95ac.tar.gz
qemu-5469933810b00589d5db36408dd4e0236eec95ac.tar.bz2
accel/tcg: Compile watchpoint.c once
Move tb_check_watchpoint declaration from tb-internal.h, which is still target-specific, to internal-common.h, which isn't. Otherwise, all that is required to build watchpoint.c once is to include the new exec/cpu-interrupt.h instead of exec/exec-all.h. Tested-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
-rw-r--r--accel/tcg/internal-common.h2
-rw-r--r--accel/tcg/meson.build2
-rw-r--r--accel/tcg/tb-internal.h2
-rw-r--r--accel/tcg/watchpoint.c5
4 files changed, 5 insertions, 6 deletions
diff --git a/accel/tcg/internal-common.h b/accel/tcg/internal-common.h
index 7ef620d..9b6ab3a 100644
--- a/accel/tcg/internal-common.h
+++ b/accel/tcg/internal-common.h
@@ -72,4 +72,6 @@ void tcg_exec_unrealizefn(CPUState *cpu);
/* current cflags for hashing/comparison */
uint32_t curr_cflags(CPUState *cpu);
+void tb_check_watchpoint(CPUState *cpu, uintptr_t retaddr);
+
#endif
diff --git a/accel/tcg/meson.build b/accel/tcg/meson.build
index 69f4808..979ce90 100644
--- a/accel/tcg/meson.build
+++ b/accel/tcg/meson.build
@@ -20,7 +20,6 @@ specific_ss.add_all(when: 'CONFIG_TCG', if_true: tcg_specific_ss)
specific_ss.add(when: ['CONFIG_SYSTEM_ONLY', 'CONFIG_TCG'], if_true: files(
'cputlb.c',
- 'watchpoint.c',
'tcg-accel-ops.c',
'tcg-accel-ops-mttcg.c',
'tcg-accel-ops-icount.c',
@@ -30,4 +29,5 @@ specific_ss.add(when: ['CONFIG_SYSTEM_ONLY', 'CONFIG_TCG'], if_true: files(
system_ss.add(when: ['CONFIG_TCG'], if_true: files(
'icount-common.c',
'monitor.c',
+ 'watchpoint.c',
))
diff --git a/accel/tcg/tb-internal.h b/accel/tcg/tb-internal.h
index abd423f..62a59a5 100644
--- a/accel/tcg/tb-internal.h
+++ b/accel/tcg/tb-internal.h
@@ -75,6 +75,4 @@ void tb_invalidate_phys_range_fast(ram_addr_t ram_addr,
bool tb_invalidate_phys_page_unwind(tb_page_addr_t addr, uintptr_t pc);
-void tb_check_watchpoint(CPUState *cpu, uintptr_t retaddr);
-
#endif
diff --git a/accel/tcg/watchpoint.c b/accel/tcg/watchpoint.c
index 40112b2..ba8c985 100644
--- a/accel/tcg/watchpoint.c
+++ b/accel/tcg/watchpoint.c
@@ -19,11 +19,10 @@
#include "qemu/osdep.h"
#include "qemu/main-loop.h"
-#include "qemu/error-report.h"
-#include "exec/exec-all.h"
+#include "exec/breakpoint.h"
+#include "exec/cpu-interrupt.h"
#include "exec/page-protection.h"
#include "exec/translation-block.h"
-#include "tb-internal.h"
#include "system/tcg.h"
#include "system/replay.h"
#include "accel/tcg/cpu-ops.h"