This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 2/4] Handle copy relocations
- From: Tom Tromey <tromey at adacore dot com>
- To: Tom Tromey <tromey at adacore dot com>
- Cc: Pedro Alves <palves at redhat dot com>, gdb-patches at sourceware dot org
- Date: Tue, 30 Jul 2019 15:28:47 -0600
- Subject: Re: [PATCH 2/4] Handle copy relocations
- References: <20190627145235.21222-1-tromey@adacore.com> <20190627145235.21222-3-tromey@adacore.com> <a0801bf5-7c0a-2e55-92b9-35ae70f1a716@redhat.com> <87d0hrkzl3.fsf@tromey.com>
Tom> I haven't investigated the other failures yet, but I think this one in
Tom> particular is an existing bug in c-exp.y. What happens is that this
Tom> does not actually look up the symbol from that source file! Instead it
Tom> finds the symbol in print-file-var-lib1.c.
Digging a bit deeper, the culprit seems to be lookup_global_symbol.
I think this function should respect a block that's passed in.
However, this code also calls
gdbarch_iterate_over_objfiles_in_search_order and solib_global_lookup,
and now I wonder if one or both of these needs to be changed
as well.
For example, if stopped in the library, "print this_version_id" should
probably follow the expected-by-the-library-author lookup, but currently
I think will not.
Maybe windows_iterate_over_objfiles_in_search_order should just be the
default. I am not sure.
Tom