diff options
Diffstat (limited to 'gdb/arch')
-rw-r--r-- | gdb/arch/aarch64-insn.c | 9 | ||||
-rw-r--r-- | gdb/arch/aarch64-insn.h | 5 |
2 files changed, 8 insertions, 6 deletions
diff --git a/gdb/arch/aarch64-insn.c b/gdb/arch/aarch64-insn.c index 1252889..6a5abf7 100644 --- a/gdb/arch/aarch64-insn.c +++ b/gdb/arch/aarch64-insn.c @@ -69,12 +69,9 @@ aarch64_decode_adr (CORE_ADDR addr, uint32_t insn, int *is_adrp, else *offset = (immhi | immlo); - if (aarch64_debug) - { - debug_printf ("decode: 0x%s 0x%x %s x%u, #?\n", - core_addr_to_string_nz (addr), insn, - *is_adrp ? "adrp" : "adr", *rd); - } + aarch64_debug_printf ("decode: 0x%s 0x%x %s x%u, #?", + core_addr_to_string_nz (addr), insn, + *is_adrp ? "adrp" : "adr", *rd); return 1; } return 0; diff --git a/gdb/arch/aarch64-insn.h b/gdb/arch/aarch64-insn.h index 57aeb23..1e8c5ea 100644 --- a/gdb/arch/aarch64-insn.h +++ b/gdb/arch/aarch64-insn.h @@ -21,6 +21,11 @@ extern bool aarch64_debug; +/* Print an "aarch64" debug statement. */ + +#define aarch64_debug_printf(fmt, ...) \ + debug_prefixed_printf_cond (aarch64_debug, "aarch64", fmt, ##__VA_ARGS__) + /* Support routines for instruction parsing. */ /* Create a mask of X bits. */ |