]> git.ipfire.org Git - thirdparty/binutils-gdb.git/log
thirdparty/binutils-gdb.git
6 weeks agogas: conditionalize body of create_obj_attrs_section()
Jan Beulich [Fri, 13 Mar 2026 06:50:45 +0000 (07:50 +0100)] 
gas: conditionalize body of create_obj_attrs_section()

This way bfd_elf_obj_attr_size() and bfd_elf_set_obj_attr_contents() will
remain unused for targets not supporting object attributes, which allows
libbfd to not provide them.

Also correct the surrounding #if-s: OBJ_MAYBE_ELF really needs taking into
consideration as well.

6 weeks agoAutomatic date update in version.in
GDB Administrator [Fri, 13 Mar 2026 00:00:08 +0000 (00:00 +0000)] 
Automatic date update in version.in

6 weeks agocheck sframe version in _bfd_elf_parse_sframe
Alan Modra [Thu, 12 Mar 2026 22:25:04 +0000 (08:55 +1030)] 
check sframe version in _bfd_elf_parse_sframe

Currently if you attempt to link an object file with sframe version 2
contents, the linker will complain in _bfd_elf_merge_section_sframe
and fail to produce an output.  This affects anyone who has objects
assembled by binutils-2.45 with .sframe sections.  A work-around is to
pass --discard-sframe to ld.

Ideally the linker would rewrite version 2 sframe input to version 3,
but in the absence of that support it would be nicer if ld just
ignored version 2 (or 1) sframe sections without needing to pass
--discard-sframe.  That is the aim of this patch.

It does so by checking the sframe version in _bfd_elf_parse_sframe
where various failing checks result in an error being printed and the
section not being marked as SEC_INFO_TYPE_SFRAME, but causes no
overall linker failure.  In addition, an sframe version failure now
also marks the sframe section with SEC_EXCLUDE.  This is also done for
other sframe failures.  See the changelog below for other fixes.

bfd/
* elf-sframe.c (_bfd_elf_merge_section_sframe): Don't check
sframe version here.
(_bfd_elf_parse_sframe): Check sframe version here instead.
Do the "already parsed" check first.  Reorder various other
checks.  Do not bother parsing or print errors when
discard_sframe is set.  Free section contents on failure
paths.  Set SEC_EXCLUDE for fails.  Check for NULL bfd_zalloc
return, and only allocate after successfully parsing sframe.
On errors report that the section will be ignored, not "no
.sframe will be created".
binutils/
* testsuite/lib/binutils-common.exp: Ignore sframe version
errors.

6 weeks agoprune_warnings_extra quoting
Alan Modra [Thu, 12 Mar 2026 22:24:05 +0000 (08:54 +1030)] 
prune_warnings_extra quoting

This patch just tidies the code a little.  By using tcl {} quoting
rather than "" we can reduce the need for backslash quoting.

* testsuite/lib/binutils-common.exp (prune_warnings_extra): Use
tcl {} quoting.

6 weeks ago[gdb/testsuite] Handle debuginfod output in gdb.debuginfod/solib-with-dwz.exp
Tom de Vries [Thu, 12 Mar 2026 20:16:59 +0000 (21:16 +0100)] 
[gdb/testsuite] Handle debuginfod output in gdb.debuginfod/solib-with-dwz.exp

I ran into a timeout in test-case gdb.debuginfod/solib-with-dwz.exp.

GDB times out like this:
...
Download failed: Timer expired. \
  Continuing without source file solib-with-dwz-bar.c.
...

My theory is that the download fails because debuginfod becomes unresponsive,
because it's stuck trying to write output into some buffer that is already
full.

Fix this by regularly draining debuginfod output in the test-case, using a new
proc drain_debuginfod.

Debuginfod is run with "-vvvv", which makes it rather verbose, and dropping
that also fixes the timeouts, but it might be useful for debugging, so I went
with the output draining method, and left the "-vvvv" as is.

Reviewed-By: Keith Seitz <keiths@redhat.com>
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=33901

6 weeks agoFix the --disable-libctf build
Tom Tromey [Thu, 12 Mar 2026 17:17:31 +0000 (11:17 -0600)] 
Fix the --disable-libctf build

If you configure with --disable-libctf, currently gdb will fail to
build.  The fix is to rename the stub function elfctf_build_psymtabs
to remove the "p".

6 weeks ago[pre-commit] Bump black to 26.3.1
Tom de Vries [Thu, 12 Mar 2026 15:45:30 +0000 (16:45 +0100)] 
[pre-commit] Bump black to 26.3.1

Ran "pre-commit autoupdate".  No changes in formatting.

6 weeks agogdb/dwarf: change dwarf_block_to_fb_offset to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:48 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf_block_to_fb_offset to return bool

Change-Id: If62adeb3bf302de07e0dab46a1b9fad6050df800
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf_block_to_sp_offset to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:47 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf_block_to_sp_offset to return bool

Change-Id: I7607e0b1cbbbb0c7be0ec309d7d936154a910554
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: use true/false in read_gdb_index_from_buffer
Simon Marchi [Wed, 11 Mar 2026 18:05:46 +0000 (14:05 -0400)] 
gdb/dwarf: use true/false in read_gdb_index_from_buffer

Change-Id: I92ee061796705394c8b305599c10b2c9f953ac82
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_frame_ops to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:45 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_frame_ops to return bool

Change-Id: I0531b413823b1edc419be8f4977e9baa9efe3833
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: define type aliases for dwarf2_frame_ops function types
Simon Marchi [Wed, 11 Mar 2026 18:05:44 +0000 (14:05 -0400)] 
gdb/dwarf: define type aliases for dwarf2_frame_ops function types

This makes the code less verbose, and I think more readable.

Change-Id: I715669281d341bd15547e3eba82c716a953f2274
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change piece_end_p to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:43 +0000 (14:05 -0400)] 
gdb/dwarf: change piece_end_p to return bool

Change-Id: Ia8f7f5a88161901f32415f16a0f911aeee50b6a8
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_frame_signal_frame_p to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:42 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_frame_signal_frame_p to return bool

Change-Id: Iaa387e7c3eca9c8a131798442adcf0136e9eb16c
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change base_types_equal_p to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:41 +0000 (14:05 -0400)] 
gdb/dwarf: change base_types_equal_p to return bool

Change-Id: I66f13baf8fe2b15fa2bab9f3dcb60c3ad9e91d6a
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_locexpr_baton_eval to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:40 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_locexpr_baton_eval to return bool

Change-Id: Ib22b4ca4365e9943cc17b0d510bf5590842eb258
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_fetch_cfa_info to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:39 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_fetch_cfa_info to return bool

Change-Id: I4d5dc288c6ade399e62c73dcb21eebfe2ae16bb7
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change call_site_parameter_matches to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:38 +0000 (14:05 -0400)] 
gdb/dwarf: change call_site_parameter_matches to return bool

Change-Id: Ic131c1752151a1b275c06c3dc92d86bcc925d6f7
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change frame_is_tailcall to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:37 +0000 (14:05 -0400)] 
gdb/dwarf: change frame_is_tailcall to return bool

Change-Id: Icc70cb565ece0f04fbd8950cf6ff41f9b3e2c242
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change unavailable_retaddr and undefined_retaddr to bool
Simon Marchi [Wed, 11 Mar 2026 18:05:36 +0000 (14:05 -0400)] 
gdb/dwarf: change unavailable_retaddr and undefined_retaddr to bool

Change-Id: I928e9244aee156501e0c2318f2a58b26ed00add7
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_ranges_read to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:35 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_ranges_read to return bool

Also, do some little cleanups in the function itself.

Change-Id: I83928a31dcdcae34b651828fef27b1fa877241eb
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_ranges_process to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:34 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_ranges_process to return bool

Change-Id: I7472405cf276a336247fd47bf1126eaf21b05b92
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change prototyped_function_p to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:33 +0000 (14:05 -0400)] 
gdb/dwarf: change prototyped_function_p to return bool

Change-Id: I4a6f6c2d063be780c4d740b8bac2d2d92d42001e
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change is_vtable_name to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:32 +0000 (14:05 -0400)] 
gdb/dwarf: change is_vtable_name to return bool

Change-Id: Ib14b18b75ddfc308b9987cd9102f0f721c91a3b1
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_is_constructor to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:31 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_is_constructor to return bool

Change-Id: I207d368269494a4a36884847f4474e2f6c326511
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change attr_to_dynamic_prop to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:30 +0000 (14:05 -0400)] 
gdb/dwarf: change attr_to_dynamic_prop to return bool

Change-Id: I80fc429cd15328c5dfd1f4e7f87ad83368bcb28d
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change need_gnat_info to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:29 +0000 (14:05 -0400)] 
gdb/dwarf: change need_gnat_info to return bool

Change-Id: I0bc5930cc3b30986682d50f5eaad39fb74b2db8e
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change die_is_declaration to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:28 +0000 (14:05 -0400)] 
gdb/dwarf: change die_is_declaration to return bool

Change-Id: I20f9f5b273a2cb8d24b590447a86bf1575d21ddc
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change dwarf2_flag_true_p to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:27 +0000 (14:05 -0400)] 
gdb/dwarf: change dwarf2_flag_true_p to return bool

Change-Id: Ie60d5d715171f7482f77598553e9236c3fe94ab1
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb/dwarf: change die_needs_namespace to return bool
Simon Marchi [Wed, 11 Mar 2026 18:05:26 +0000 (14:05 -0400)] 
gdb/dwarf: change die_needs_namespace to return bool

Change the return type to bool, and do some other trivial refactoring:

 - remove unnecessary `attr` variable, which I don't think helps code
   readability
 - change an `if (cond) return false; return true` pattern to be just
   one return expression.

Change-Id: I647c3ad73af94bb76c4b59f580bbdfd1eef45888
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agogdb: fix build failure on armhf
Matthieu Longo [Thu, 12 Mar 2026 10:18:59 +0000 (10:18 +0000)] 
gdb: fix build failure on armhf

armhf build fails because the implicit conversion operator from
rgb_color to `uint8_t *' introduces an ambiguity.

In ./gdb/tui/tui-io.c, expressions such as:

  init_color (next, rgb[0] * 1000 / 255, rgb[1] * 1000 / 255, ...

become ambiguous between:

  constexpr uint8_t& rgb_color::operator[](std::size_t)’
  operator[](uint8_t* {aka unsigned char*}, int) (built-in)

leading to a build error:

  error: ISO C++ says that these are ambiguous

Fix the issue by removing the unused implicit conversion operator.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
Approved-By: Tom Tromey <tom@tromey.com>
6 weeks agooss-fuzz addr2line mips32_64bit_reloc out-of-bounds accesses
Alan Modra [Thu, 12 Mar 2026 07:53:28 +0000 (18:23 +1030)] 
oss-fuzz addr2line mips32_64bit_reloc out-of-bounds accesses

The code sign extending the low 32 bits into the high 32 bits in this
function does not have any address checking as it ignores the result
from bfd_perform_relocation.  Even if it did take notice that isn't
sufficient.  In little-endian mode a testcase could be crafted with
the low word at the end of a section which would put the high word out
of bounds.

I notice also that mips32_64bit_reloc is called from a rela R_MIPS_64
reloc howto.  Using a rel R_MIPS_32 howto for the lower word can't be
correct as it retrieves the addend from section contents rather than
the reloc.

Fix both of these problems by performing the entire normal 64-bit
relocation first rather than trying to be clever doing it by pieces.
Nowadays config.bfd ensures that mips elf targets always have a 64-bit
bfd.

Also, don't trim addends to 32 bits for relocatable linking or gas.
That doesn't seem necessary and in any case wasn't done properly for
the rela case, where the addend is not in section contents but in the
relocation.  Note that relocatable linking will usually be done by
elfxx-mips.c:_bfd_mips_elf_relocate_section.  The main use of these
howtos is in gas and bfd_simple_get_relocated_section_contents.

* elf32-mips.c (mips32_64bit_reloc): Rewrite.

6 weeks agoAutomatic date update in version.in
GDB Administrator [Thu, 12 Mar 2026 00:00:08 +0000 (00:00 +0000)] 
Automatic date update in version.in

6 weeks agogdb/dwarf: remove unneeded scopes in dwarf2_frame_cache
Simon Marchi [Wed, 11 Mar 2026 20:40:39 +0000 (16:40 -0400)] 
gdb/dwarf: remove unneeded scopes in dwarf2_frame_cache

These scopes exist only to declare locally some loop variables.  Declare
the variables in the for loops and remove the scopes.

Change-Id: I829916cdbfd90d4e0ae5e9054e09a133facd29eb

6 weeks agoMAINTAINERS: Add myself as a PRU maintainer
Dimitar Dimitrov [Wed, 11 Mar 2026 18:24:52 +0000 (20:24 +0200)] 
MAINTAINERS: Add myself as a PRU maintainer

Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
6 weeks agoUse type::safe_name in a couple spots
Tom Tromey [Wed, 11 Mar 2026 15:32:23 +0000 (09:32 -0600)] 
Use type::safe_name in a couple spots

I found a couple of spots that explicitly check the type's name, but
where type::safe_name seems more suitable.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoAvoid use of alloca in read_array_type
Tom Tromey [Wed, 11 Mar 2026 13:50:25 +0000 (07:50 -0600)] 
Avoid use of alloca in read_array_type

I think alloca should generally be avoided, and the use in
dwarf2/read.c:read_array_type is easily replaced with a local storage
object.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoDo not reuse 'attr' in read_array_type
Tom Tromey [Wed, 11 Mar 2026 13:46:11 +0000 (07:46 -0600)] 
Do not reuse 'attr' in read_array_type

I was looking at dwarf2/read.c:read_array_type and I thought it would
be nicer if the 'attr' wasn't reused.  This patch changes it to be
redeclared in every 'if' where it is used, making it clear that its
value is local to just the one block.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoMIPS/BFD: Make `_bfd_mips_elf_sign_extend' static inline
Maciej W. Rozycki [Wed, 11 Mar 2026 16:30:29 +0000 (16:30 +0000)] 
MIPS/BFD: Make `_bfd_mips_elf_sign_extend' static inline

Let the function be inlined from outside elfxx-mips.c as well, avoiding
the call overhead for a simple arithmetic calculation, though we have no
such user at the moment.

6 weeks agoMIPS/BFD: Use branchless code for sign-extension
Maciej W. Rozycki [Wed, 11 Mar 2026 16:30:29 +0000 (16:30 +0000)] 
MIPS/BFD: Use branchless code for sign-extension

Use common branchless code for `_bfd_mips_elf_sign_extend', typically
avoiding the branch penalty and also reducing code size when inlined in
elfxx-mips.c.

6 weeks agoReturn bool from array_type_has_dynamic_stride
Tom Tromey [Wed, 11 Mar 2026 14:43:30 +0000 (08:43 -0600)] 
Return bool from array_type_has_dynamic_stride

This changes array_type_has_dynamic_stride to return bool.
I'm checking this in as obvious.

6 weeks agoUse bool in ada-valprint.c
Tom Tromey [Tue, 10 Mar 2026 14:52:52 +0000 (08:52 -0600)] 
Use bool in ada-valprint.c

This changes some functions in ada-valprint.c to use bool, for both
parameter and return types.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn void from ada-valprint.c:print_optional_low_bound
Tom Tromey [Tue, 10 Mar 2026 14:49:28 +0000 (08:49 -0600)] 
Return void from ada-valprint.c:print_optional_low_bound

This changes ada-valprint.c:print_optional_low_bound to return void.
At first I was going to have it return bool, but then I noticed the
return value is never used.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoUse bool return types in ada-typeprint.c
Tom Tromey [Tue, 10 Mar 2026 14:48:11 +0000 (08:48 -0600)] 
Use bool return types in ada-typeprint.c

This changes some functions in ada-typeprint.c to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada-lang.c:scan_discrim_bound
Tom Tromey [Tue, 10 Mar 2026 14:25:47 +0000 (08:25 -0600)] 
Return bool from ada-lang.c:scan_discrim_bound

This changes ada-lang.c:scan_discrim_bound to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from valid_task_id
Tom Tromey [Tue, 10 Mar 2026 14:15:24 +0000 (08:15 -0600)] 
Return bool from valid_task_id

This changes valid_task_id to return bool and updates some callers.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from two Ada exception-related functions
Tom Tromey [Tue, 10 Mar 2026 14:12:12 +0000 (08:12 -0600)] 
Return bool from two Ada exception-related functions

This changes a couple of exception-related functions in ada-lang.c to
return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada-lang.c:is_known_support_routine
Tom Tromey [Tue, 10 Mar 2026 14:11:12 +0000 (08:11 -0600)] 
Return bool from ada-lang.c:is_known_support_routine

This changes ada-lang.c:is_known_support_routine to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada_has_this_exception_support
Tom Tromey [Tue, 10 Mar 2026 14:10:27 +0000 (08:10 -0600)] 
Return bool from ada_has_this_exception_support

This changes ada_has_this_exception_support to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from two Ada "redundancy" predicates
Tom Tromey [Tue, 10 Mar 2026 14:06:07 +0000 (08:06 -0600)] 
Return bool from two Ada "redundancy" predicates

This changes a couple more Ada type predicates to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada-lang.c:is_dynamic_field
Tom Tromey [Tue, 10 Mar 2026 14:04:37 +0000 (08:04 -0600)] 
Return bool from ada-lang.c:is_dynamic_field

This changes ada-lang.c:is_dynamic_field to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada_prefer_type
Tom Tromey [Tue, 10 Mar 2026 14:03:43 +0000 (08:03 -0600)] 
Return bool from ada_prefer_type

This changes ada_prefer_type to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada-lang.c:find_struct_field
Tom Tromey [Tue, 10 Mar 2026 14:02:05 +0000 (08:02 -0600)] 
Return bool from ada-lang.c:find_struct_field

This changes ada-lang.c:find_struct_field to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada_scan_number
Tom Tromey [Tue, 10 Mar 2026 14:00:49 +0000 (08:00 -0600)] 
Return bool from ada_scan_number

This changes ada_scan_number to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada_in_variant
Tom Tromey [Tue, 10 Mar 2026 13:59:50 +0000 (07:59 -0600)] 
Return bool from ada_in_variant

This changes ada_in_variant to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from more Ada type predicates
Tom Tromey [Tue, 10 Mar 2026 13:58:37 +0000 (07:58 -0600)] 
Return bool from more Ada type predicates

This changes various Ada type predicates to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoUse bool in ada_is_tagged_type
Tom Tromey [Tue, 10 Mar 2026 13:55:47 +0000 (07:55 -0600)] 
Use bool in ada_is_tagged_type

This changes ada_is_tagged_type to use 'bool' for its return and
parameter type, and then also changes ada_lookup_struct_elt_type to
propagate the boolean-ness.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agoReturn bool from ada_is_ignored_field
Tom Tromey [Tue, 10 Mar 2026 13:52:06 +0000 (07:52 -0600)] 
Return bool from ada_is_ignored_field

This changes ada_is_ignored_field to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
6 weeks agogprofng: fix display gmon option error handling
Claudiu Zissulescu [Fri, 6 Mar 2026 10:20:52 +0000 (12:20 +0200)] 
gprofng: fix display gmon option error handling

Parse display gmon options only once so invalid arguments are not
reported twice and exit status is set to failure for invalid usage.

Also add tests in gp-gmon.exp to verify unknown options and missing
-o argument fail as expected and produce a single diagnostic.

gprofng/
* src/gp-gmon.cc (usage_and_exit): New function.
(check_mods): Change number of parameters.
(checkflagterm): Fix error text, update to use new functions.
* testsuite/gprofng.display/gp-gmon.exp: Add new test.

7 weeks agogdb/testsuite: Skip rwatch in watchpoint-unaligned.exp on s390x
Kevin Buettner [Wed, 11 Mar 2026 00:14:10 +0000 (17:14 -0700)] 
gdb/testsuite: Skip rwatch in watchpoint-unaligned.exp on s390x

The watchpoint-unaligned.exp test requires both read and write
hardware watchpoints.  s390x only supports write watchpoints, causing
one test failure when the rwatch command fails with "Target does not
support this type of hardware watchpoint."

This commit causes the test using the rwatch command in this file to
be skipped when allow_hw_watchpoint_access_tests is false.

Co-Authored-By: Tom de Vries <tdevries@suse.de>
Approved-By: Tom de Vries <tdevries@suse.de>
7 weeks agoAutomatic date update in version.in
GDB Administrator [Wed, 11 Mar 2026 00:00:08 +0000 (00:00 +0000)] 
Automatic date update in version.in

7 weeks ago[gdb] Minor refactoring of is_dynamic_type_internal
Tom de Vries [Tue, 10 Mar 2026 20:44:01 +0000 (21:44 +0100)] 
[gdb] Minor refactoring of is_dynamic_type_internal

Simplify is_dynamic_type_internal by:
- factoring out type->field (i) for the TYPE_CODE_STRUCT/UNION case.
- merging a loop iteration variable declaration into a for statement

Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agoRemove note about C++ demangler from Rust documentation
Tom Tromey [Tue, 10 Mar 2026 18:00:43 +0000 (12:00 -0600)] 
Remove note about C++ demangler from Rust documentation

A note about the C++ demangler in the Rust documentation hasn't been
accurate for a while.  Also, it probably isn't clear to users how this
related to the next bit of text in the same bullet point.  This patch
removes the obsolete comment.

Approved-By: Eli Zaretskii <eliz@gnu.org>
7 weeks agogdb/dwarf: implement section_and_offset comparison using operator==
Simon Marchi [Tue, 10 Mar 2026 17:44:57 +0000 (13:44 -0400)] 
gdb/dwarf: implement section_and_offset comparison using operator==

This was suggested during review.

Change-Id: Iabe893f5b7ee1c4dce9655cbc323e3640e061aa3
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: use gdb::unordered_map for line headers
Simon Marchi [Sat, 21 Feb 2026 20:07:34 +0000 (15:07 -0500)] 
gdb/dwarf: use gdb::unordered_map for line headers

Change htab_t for gdb::unordered_map, more specifically the
unordered_section_and_offset_map specialization.

It is no longer necessary to keep the section and offset inside the
line_header structure itself, because it's just used for the map key, so
remove that.

I tried my best to preserve the logic in decode_line_header_for_cu, but
I don't fully understand it.

Change-Id: I512652e6da8b25db77ac9974135f9a06ce3d831e
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: use (section, offset-in-section) as key for line_header hash
Simon Marchi [Sat, 21 Feb 2026 20:07:33 +0000 (15:07 -0500)] 
gdb/dwarf: use (section, offset-in-section) as key for line_header hash

Similar to the previous patch, use the (section, offset-in-section)
tuple as the key to uniquely identify a line table header.  Currently,
line_header objects are hashed based on the (offset-in-section, is-dwz)
tuple.

This removes the last instances of "offset_in_dwz" parameters, which I
never really liked, as they were oddly specific.  Specifying the section
does the same job in a more generic way.

Change-Id: Ia4666f68111ce2210dc58f716eff37cf913eeeb9
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: use (section, offset) as stmt_list key
Simon Marchi [Sat, 21 Feb 2026 20:07:32 +0000 (15:07 -0500)] 
gdb/dwarf: use (section, offset) as stmt_list key

It occurred to me that we could use (section, offset-in-section) tuples
as the key for a line table, replacing stmt_list_hash, just like we use
(section, offset-in-section) as the sort key in the
dwarf2_per_bfd::all_units vector.  This is functionally the same, the
goal is to uniquely identify a line table, but I think it's clearer this
way.  The tuple (section, offset-in-section) precisely and unambiguously
specifies a spot in an object file.

This allows deleting some specialized code, and eventually share code
with other places that would want to use section_and_offset as a key.

Change-Id: I1b45c7f653d71656b964c3f3789d8bb459774340
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: store dwarf2_cus in expansion queue
Simon Marchi [Sat, 21 Feb 2026 20:07:31 +0000 (15:07 -0500)] 
gdb/dwarf: store dwarf2_cus in expansion queue

The CU expansion queue currently holds dwarf2_per_cu items (see
dwarf2_queue_item).  But there is this invariant that if a per_cu is
queued for expansion, then its DIEs are loaded in memory and a matching
dwarf2_cu object exists in dwarf2_per_objfile.

When a caller calls maybe_queue_comp_unit, a return value of `true`
indicates "the per_cu was enqueued, but its DIEs are not currently
loaded (a dwarf2_cu does not exist for it yet), so you must do it".  The
caller is then responsible for calling some function to make it happen
and ensure the invariant is respected.

This feels backwards to me, I think it would be simpler if it was the
other way around.  The queue should hold dwarf2_cu objects directly.  To
enqueue a CU for expansion, a caller would therefore have to make sure
that a dwarf2_cu exists in the first place (i.e. that the unit's DIEs
are loaded), to pass it to queue_comp_unit.  Often, the caller wants to
use the dwarf2_cu anyway, so it's not lost.

 - Change dwarf2_queue_item to hold dwarf2_cu pointers.  No need to have
   a dwarf2_per_objfile anymore, since a dwarf2_cu provides it.

 - Change queue_comp_unit and maybe_queue_comp_unit to take a dwarf2_cu.

 - Change the order of operation in the spots that call
   maybe_queue_comp_unit.  Make sure the target unit is loaded first, by
   calling one of the new ensure_loaded_* functions.  Then, if the
   return value is not nullptr (which happens if the unit is dummy),
   then call maybe_queue_comp_unit.

 - process_queue does not need to deal with possible dummy units, since
   that is now filtered earlier.  It is not possible to have a dwarf2_cu
   for a dummy unit.

 - Move the queued flag from dwarf2_per_cu to dwarf2_cu.

 - Remove this assert from fill_in_sig_entry_from_dwo_entry, since the
   queued flag is not longer in dwarf2_per_cu:

     gdb_assert (! sig_entry->queued);

   I think that the assert just below does the same job:

     gdb_assert (per_objfile->get_cu (sig_entry) == NULL);

   Now that the queue holds dwarf2_cus, if there is no dwarf2_cu
   associated to a sig_entry, then necessarily that sig_entry is not
   enqueued.

Change-Id: I8ef0eb5f45f04b4cb45c3804627084d94bc6c4fd
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: inline queue_and_load_dwo_tu
Simon Marchi [Sat, 21 Feb 2026 20:07:30 +0000 (15:07 -0500)] 
gdb/dwarf: inline queue_and_load_dwo_tu

I noticed that queue_and_load_dwo_tu unnecessarily returned an integer
value, so I started by removing that.  Then, I thought that it didn't
really need to be a separate function anymore, it would be clear enough
if the code was inlined into queue_and_load_all_dwo_tus.

Change-Id: Ibc5a83e87a10e6c0bf67ca955fcabbc90d9ac2ef
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: return dwarf2_cu from load_full_{comp,type}_unit
Simon Marchi [Sat, 21 Feb 2026 20:07:29 +0000 (15:07 -0500)] 
gdb/dwarf: return dwarf2_cu from load_full_{comp,type}_unit

Make load_full_{comp,type}_unit return a non-owning reference to the
created dwarf2_cu.  The functions still install the dwarf2_cu in
dwarf2_per_objfile::m_dwarf2_cus with dwarf2_per_objfile::set_cu.

Make dwarf2_per_objfile::set_cu return a non-owning reference as well,
for convenience.  This makes things easier to follow, and reduces the
number of calls of unnecessary dwarf2_per_objfile::get_cu calls (i.e.
map lookups).

Change-Id: I51ed32585521cad0b89a4ca398915d7e0c1141e1
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: remove read_signatured_type
Simon Marchi [Sat, 21 Feb 2026 20:07:28 +0000 (15:07 -0500)] 
gdb/dwarf: remove read_signatured_type

load_full_type_unit is a thin wrapper around read_signatured_type, with
two asserts:

    static void
    load_full_type_unit (signatured_type *sig_type, dwarf2_per_objfile *per_objfile)
    {
      gdb_assert (per_objfile->get_cu (sig_type) == nullptr);
      read_signatured_type (sig_type, per_objfile);
      gdb_assert (per_objfile->get_cu (sig_type) != nullptr);
    }

The first one is unnecessary, since the same assert is in
read_signatured_type.

The second one might be wrong, since read_signatured_type could in
theory not set the cu, if it is dummy.

Remove the existing load_full_type_unit and rename read_signatured_type
to load_full_type_unit.  I prefer the latter name, for the parallel with
load_full_comp_unit, but also because I think it's clearer.
read_signatured_type makes it sound like it will read the type and build
the symbols, which is not the case.  It only loads the DIEs in memory.

Change-Id: Ia411ccdaeae091298986b18e26d5583b896b2aa5
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: remove unnecessary compunit_symtab_set_p check in process_queue
Simon Marchi [Sat, 21 Feb 2026 20:07:27 +0000 (15:07 -0500)] 
gdb/dwarf: remove unnecessary compunit_symtab_set_p check in process_queue

We know that enqueued per_cu objects never have a matching
compunit_symtab object set.

The two places where per_cus are enqueued are:

 - maybe_queue_comp_unit, which has its own compunit_symtab_set_p check
 - dw2_do_instantiate_symtab, which is only called if per_cu does not
   have a compunit_symtab yet

process_queue therefore does not need to consider the possibility of
the compunit_symtab being set already.

Change-Id: Id8565d7f659813047ee15603598f9abd39993adc
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: remove unnecessary compunit_symtab_set_p check in dw2_do_instantiate_symtab
Simon Marchi [Sat, 21 Feb 2026 20:07:26 +0000 (15:07 -0500)] 
gdb/dwarf: remove unnecessary compunit_symtab_set_p check in dw2_do_instantiate_symtab

dw2_do_instantiate_symtab is called by dw2_instantiate_symtab, only if
per_cu does not have a matching compunit_symtab yet.
dw2_do_instantiate_symtab therefore does not need this
compunit_symtab_set_p itself.

Change-Id: Ie665980bb65016b56206c4aac36f4c2fc13c61de
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: remove just_read_cus from dwarf2_per_bfd
Simon Marchi [Sat, 21 Feb 2026 20:07:25 +0000 (15:07 -0500)] 
gdb/dwarf: remove just_read_cus from dwarf2_per_bfd

It is not necessary to keep the just_read_cus vector inside
dwarf2_per_bfd.  This vector is only needed shortly, while we process
the CU expansion queue.

Instead of appending expanded comp units in process_full_comp_unit,
instantiate a local vector in process_queue, populate it with the
expanded comp units, and call process_cu_includes from there.

Remove the `if (!iter->is_debug_types ())` check in process_cu_includes:
we know that we only append comp units to this vector, no type units.

In compute_compunit_symtab_includes, remove the `if (cust == NULL)`
check: in process_queue, we only append the per_cus for which a
compunit_symtab was indeed created, no need to check it again here.

Change-Id: Ia50b703f379ae9dc90c9abc1d5269d4932f16e2d
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: make process_full_{comp,type}_unit return a compunit_symtab
Simon Marchi [Sat, 21 Feb 2026 20:07:24 +0000 (15:07 -0500)] 
gdb/dwarf: make process_full_{comp,type}_unit return a compunit_symtab

This change makes it so that there is a single point in the code where
compunit symtabs are set (where dwarf2_per_objfile::set_compunit_symtab
is called), which I think helps understand how things work.

Change-Id: Ie84aa5141ebe1e2c7a990f59a62d95401a4b3e4a
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: make dw2_search_one a method of dwarf2_base_index_functions
Simon Marchi [Sat, 21 Feb 2026 20:07:23 +0000 (15:07 -0500)] 
gdb/dwarf: make dw2_search_one a method of dwarf2_base_index_functions

This function is used as a helper for readnow_functions::search and
cooked_index_functions::search.  Just to better organize things, make it
a protected static method in the base class,
dwarf2_base_index_functions.

Change-Id: I0273c92379bf2337df16d28e21586125716e7de6
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/dwarf: rename symtab -> compunit_symtab
Simon Marchi [Sat, 21 Feb 2026 20:07:22 +0000 (15:07 -0500)] 
gdb/dwarf: rename symtab -> compunit_symtab

In dwarf2_per_objfile, rename:

 - m_symtabs -> m_compunit_symtabs
 - get_symtab -> get_compunit_symtab
 - set_symtab -> set_compunit_symtab

In GDB, symtabs and compunit_symtabs are different things, so this
rename should make things clearer.

Change-Id: Iff3cdba68b72ec78ffd87f0b035b3367d7c03cf3
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agoReturn bool from some Ada wild-match functions
Tom Tromey [Tue, 3 Mar 2026 17:54:01 +0000 (10:54 -0700)] 
Return bool from some Ada wild-match functions

This changes a few wild-match-related functions to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoReturn bool from ada-lang.c:is_name_suffix
Tom Tromey [Tue, 3 Mar 2026 17:53:26 +0000 (10:53 -0700)] 
Return bool from ada-lang.c:is_name_suffix

This changes ada-lang.c:is_name_suffix to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoMore Ada boolean-ization
Tom Tromey [Tue, 3 Mar 2026 17:52:33 +0000 (10:52 -0700)] 
More Ada boolean-ization

This changes a few more Ada functions to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoReturn bool from iterate_over_objfiles_in_search_order callbacks
Tom Tromey [Tue, 3 Mar 2026 17:50:39 +0000 (10:50 -0700)] 
Return bool from iterate_over_objfiles_in_search_order callbacks

I noticed that many callbacks passed to
iterate_over_objfiles_in_search_order were still returning 0/1 rather
than false/true.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoReturn bool from lookup_cached_symbol
Tom Tromey [Tue, 3 Mar 2026 17:46:15 +0000 (10:46 -0700)] 
Return bool from lookup_cached_symbol

This changes ada-lang.c:lookup_cached_symbol to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoReturn bool from various Ada type predicates
Tom Tromey [Tue, 3 Mar 2026 17:45:56 +0000 (10:45 -0700)] 
Return bool from various Ada type predicates

This changes a few more Ada type predicates to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoReturn bool from array-related Ada predicates
Tom Tromey [Tue, 3 Mar 2026 17:39:51 +0000 (10:39 -0700)] 
Return bool from array-related Ada predicates

This changes various array-related predicate functions in ada-lang.c
to return bool type.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoReturn bool from ada-lang.c:is_suffix
Tom Tromey [Tue, 3 Mar 2026 17:36:14 +0000 (10:36 -0700)] 
Return bool from ada-lang.c:is_suffix

Change ada-lang.c:is_suffix to return bool.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agogdb/testsuite: fix gdb.python/py-selected-context.exp with glibc debuginfo but no...
Jan Vrany [Tue, 10 Mar 2026 13:13:42 +0000 (13:13 +0000)] 
gdb/testsuite: fix gdb.python/py-selected-context.exp with glibc debuginfo but no source

When running gdb.python/py-selected-context.exp I get:

    thread 1
    [Switching to thread 1.1 (Thread 0x7ffff7da4740 (LWP 480841))]
    #0  __syscall_cancel_arch () at ../sysdeps/unix/sysv/linux/x86_64/syscall_cancel.S:56
    warning: 56     ../sysdeps/unix/sysv/linux/x86_64/syscall_cancel.S: No such file or directory
    Python Exception <class 'gdb.GdbError'>: error from gdb_selected_context_handler
    (gdb) FAIL: gdb.python/py-selected-context.exp: switch thread, handler raises an error

The problem is that glibc debug info is present but sources are not,
hence the warning.

Fix this by updating the regexp. Tested on x86_64 Linux with and without
glibc sources.

Approved-By: Tom de Vries <tdevries@suse.de>
7 weeks agogdb/python: add gdbpy_dict_wrapper:allocate_dict helper
Matthieu Longo [Fri, 27 Feb 2026 10:30:36 +0000 (10:30 +0000)] 
gdb/python: add gdbpy_dict_wrapper:allocate_dict helper

Python extension objects that support __dict__ must inherit from
gdbpy_dict_wrapper, a wrapper class that stores the PyObject
corresponding to the __dict__ attribute.

Currently, management of this dictionary is not centralized, and
each Python extension object implements its own logic to create,
access, and destroy it.

This patch focuses on the allocation of the dictionary, introduces
a new method, gdbpy_dict_wrapper::allocate_dict(), and
adapts the existing code to use this method.

Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/python: flatten functions calling PyObject_New and use gdbpy_ref
Matthieu Longo [Thu, 26 Feb 2026 16:08:27 +0000 (16:08 +0000)] 
gdb/python: flatten functions calling PyObject_New and use gdbpy_ref

This patch aims at systematically using gdbpy_ref<> at all call sites
of PyObject_New(). This prepares for future patches that expect
gdbby_ref<> parameters and affect return handling.
As part of this change, flattening the affected functions so that the
return logic becomes clearer and more flexible to adjust.

Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/python: allow ref_ptr<T, Policy>::new_reference to accept subclasses of T
Matthieu Longo [Thu, 26 Feb 2026 17:20:20 +0000 (17:20 +0000)] 
gdb/python: allow ref_ptr<T, Policy>::new_reference to accept subclasses of T

When ref_ptr<T,Policy>::new_reference() is specialized for 'PyObject'
(i.e. gdbpy_ref<>), it currently requires the argument type to be exactly
'PyObject *'. As a result, pointers to subclasses of 'PyObject' must be
explicitly cast before being passed, making call sites unnecessarily
verbose.

This patch makes ref_ptr<T,Policy>::new_reference() a template method
that accepts both T and subclasses of T, performing the cast to 'T *'
internally when needed. This removes redundant casts at call sites
without changing behavior.

Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb: introduce rgb_color type to simplify existing code
Matthieu Longo [Fri, 20 Feb 2026 10:45:27 +0000 (10:45 +0000)] 
gdb: introduce rgb_color type to simplify existing code

This patch replaces the raw uint8[3] buffer used to represent RGB values
with a more convenient wrapper, rgb_color, around std::array<uint8_t, 3>.
It also changes the return type of ui_file_style::color::get_rgb to
rgb_color instead of filling a caller-provided buffer, and updates all
callers accordingly.

This expected benefit of this change consists in:
- removing the manual size handling.
- proving accessors without using hard-coded indexes.
- making the API safer.
- simplifying call sites.

This refactoring does not introduce any functional change.

Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agoAutomatic date update in version.in
GDB Administrator [Tue, 10 Mar 2026 00:00:07 +0000 (00:00 +0000)] 
Automatic date update in version.in

7 weeks agogas: don't duplicate include of config.h
Alan Modra [Mon, 9 Mar 2026 23:16:56 +0000 (09:46 +1030)] 
gas: don't duplicate include of config.h

The header is included by as.h, don't include it again.

7 weeks agoRemove POISON_BFD_BOOLEAN
Alan Modra [Mon, 9 Mar 2026 23:12:23 +0000 (09:42 +1030)] 
Remove POISON_BFD_BOOLEAN

We don't need this definition any more.  Incidentally, the poisoning
wasn't effective in gas since the define came after bfd.h was
included.

7 weeks agoUse store_unsigned_integer in findcmd.c
Tom Tromey [Sat, 7 Mar 2026 16:55:03 +0000 (09:55 -0700)] 
Use store_unsigned_integer in findcmd.c

This rewrites findcmd.c:put_bits to use store_unsigned_integer, and to
directly use the byte order.

Approved-By: Andrew Burgess <aburgess@redhat.com>
Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agoUse boolean constants in ft32-tdep.c
Tom Tromey [Sat, 7 Mar 2026 16:49:18 +0000 (09:49 -0700)] 
Use boolean constants in ft32-tdep.c

A couple of spots in ft32-tdep.c are using integer literals where
booleans are more appropriate.

Approved-By: Andrew Burgess <aburgess@redhat.com>
Approved-By: Simon Marchi <simon.marchi@efficios.com>
7 weeks agogdb/target: remove async_callback_ftype
Simon Marchi [Mon, 2 Mar 2026 05:39:16 +0000 (00:39 -0500)] 
gdb/target: remove async_callback_ftype

It is unused.

Change-Id: I067dab91bac1707d2effa271d22c3a4bbf935a8f

7 weeks agogdb/gdbtypes: replace TYPE_IS_OPAQUE macro with method
Simon Marchi [Tue, 17 Feb 2026 19:13:58 +0000 (14:13 -0500)] 
gdb/gdbtypes: replace TYPE_IS_OPAQUE macro with method

Replace the TYPE_IS_OPAQUE macro with the method type::is_opaque.

Change-Id: I9d8875d9fedca5681f7b4a9a56e8e5cb0bf0ad78
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/gdbtypes: replace TYPE_ERROR_NAME macro with method
Simon Marchi [Tue, 17 Feb 2026 19:13:57 +0000 (14:13 -0500)] 
gdb/gdbtypes: replace TYPE_ERROR_NAME macro with method

Replace the TYPE_ERROR_NAME macro with the method type::error_name.

Change-Id: I59afa6a8ced9c3bb53f3961965479a11deb41407
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb/gdbtypes: replace TYPE_SAFE_NAME macro with method
Simon Marchi [Tue, 17 Feb 2026 19:13:56 +0000 (14:13 -0500)] 
gdb/gdbtypes: replace TYPE_SAFE_NAME macro with method

Replace the TYPE_SAFE_NAME macro with the method type::safe_name.

Change-Id: I7ecaa6e5f88383821d2f227474c1c146ff731ff6
Approved-By: Tom Tromey <tom@tromey.com>
7 weeks agogdb: change gdbarch_adjust_dwarf2_line parameter to bool
Simon Marchi [Mon, 9 Mar 2026 18:31:44 +0000 (14:31 -0400)] 
gdb: change gdbarch_adjust_dwarf2_line parameter to bool

Straightforward int to bool conversion.

Change-Id: I40b69ed4da58a375e5359d58768e58ad5afdf3be
Approved-By: Tom Tromey <tom@tromey.com>