diff options
author | Mike Frysinger <vapier@gentoo.org> | 2024-01-01 16:32:48 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2024-01-01 16:32:48 -0500 |
commit | a243f0a5a184d571ce3bb73b1f11f64b6ebfdcfd (patch) | |
tree | afb6cd44043e75b07aa5ebf29ac88a31907452fe /sim/ppc/debug.h | |
parent | 5817b1f52f5f51cddadd3a982b0d34035d188648 (diff) | |
download | gdb-a243f0a5a184d571ce3bb73b1f11f64b6ebfdcfd.zip gdb-a243f0a5a184d571ce3bb73b1f11f64b6ebfdcfd.tar.gz gdb-a243f0a5a184d571ce3bb73b1f11f64b6ebfdcfd.tar.bz2 |
sim: ppc: replace filter_filename with lbasename
The lbasename function from libiberty provides the same API as this
custom function. The common/ code already made the switch, so make
the same change to the ppc code to avoid target duplication.
Diffstat (limited to 'sim/ppc/debug.h')
-rw-r--r-- | sim/ppc/debug.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sim/ppc/debug.h b/sim/ppc/debug.h index 28e42c7..e221ce5 100644 --- a/sim/ppc/debug.h +++ b/sim/ppc/debug.h @@ -21,7 +21,7 @@ #ifndef _DEBUG_H_ #define _DEBUG_H_ -#include "filter_filename.h" +#include "libiberty.h" typedef enum { trace_invalid, @@ -87,7 +87,7 @@ extern int ppc_trace[nr_trace_options]; do { \ if (WITH_TRACE) { \ if (ppc_trace[OBJECT]) { \ - sim_io_printf_filtered("%s:%d: ", filter_filename(__FILE__), __LINE__); \ + sim_io_printf_filtered("%s:%d: ", lbasename(__FILE__), __LINE__); \ sim_io_printf_filtered ARGS; \ } \ } \ @@ -113,7 +113,7 @@ do { \ || ppc_trace[trace_##OBJECT##_device] \ || trace_device) { \ sim_io_printf_filtered("%s:%d:%s:%s%s ", \ - filter_filename(__FILE__), __LINE__, #OBJECT, \ + lbasename(__FILE__), __LINE__, #OBJECT, \ trace_device ? device_path(me) : "", \ trace_device ? ":" : ""); \ sim_io_printf_filtered ARGS; \ @@ -131,7 +131,7 @@ do { \ || ppc_trace[trace_##OBJECT##_device] \ || trace_device) { \ sim_io_printf_filtered("%s:%d:%s:%s%s ", \ - filter_filename(__FILE__), __LINE__, #OBJECT, \ + lbasename(__FILE__), __LINE__, #OBJECT, \ trace_device ? device_path(_me) : "", \ trace_device ? ":" : ""); \ sim_io_printf_filtered ARGS; \ @@ -144,7 +144,7 @@ do { \ do { \ if (WITH_TRACE) { \ if (ppc_trace[trace_##OBJECT##_package]) { \ - sim_io_printf_filtered("%s:%d:%s: ", filter_filename(__FILE__), __LINE__, #OBJECT); \ + sim_io_printf_filtered("%s:%d:%s: ", lbasename(__FILE__), __LINE__, #OBJECT); \ sim_io_printf_filtered ARGS; \ } \ } \ @@ -156,7 +156,7 @@ do { \ if (WITH_ASSERT) { \ if (!(EXPRESSION)) { \ error("%s:%d: assertion failed - %s\n", \ - filter_filename(__FILE__), __LINE__, #EXPRESSION); \ + lbasename(__FILE__), __LINE__, #EXPRESSION); \ } \ } \ } while (0) |