On 4/7/26 21:56, Richard Henderson wrote:
On 7/3/26 09:37, Philippe Mathieu-Daudé wrote:
--- a/include/exec/breakpoint.h
+++ b/include/exec/breakpoint.h
@@ -12,6 +12,7 @@
#include "exec/vaddr.h"
#include "exec/memattrs.h"
+typedef int BreakpointFlags;
/* Breakpoint/watchpoint flags */
#define BP_MEM_READ 0x01
#define BP_MEM_WRITE 0x02
@@ -28,7 +29,7 @@
typedef struct CPUBreakpoint {
vaddr pc;
- int flags; /* BP_* */
+ BreakpointFlags flags;
QTAILQ_ENTRY(CPUBreakpoint) entry;
} CPUBreakpoint;
Missing the replacement in CPUWatchpoint.
-void cpu_watchpoint_remove_all(CPUState *cpu, int mask);
+void cpu_watchpoint_remove_all(CPUState *cpu, BreakpointFlags flags);
Please don't rename mask to flags. Several instances.
The arguments that are 'flags' are installed/compared exactly (==), and
the arguments that are 'mask' are used as bitmasks (&).
Indeed.