This is the mail archive of the
mailing list for the binutils project.
Re: Free linker hash table from bfd_close
- From: Tom Tromey <tromey at redhat dot com>
- To: binutils at sourceware dot org
- Date: Thu, 19 Jun 2014 07:53:33 -0600
- Subject: Re: Free linker hash table from bfd_close
- Authentication-results: sourceware.org; auth=none
- References: <20140613095201 dot GH7683 at bubble dot grove dot modra dot org> <87k38edjkw dot fsf at fleche dot redhat dot com> <20140619005828 dot GN3462 at bubble dot grove dot modra dot org>
>>>>> "Alan" == Alan Modra <firstname.lastname@example.org> writes:
Alan> On Wed, Jun 18, 2014 at 02:54:55PM -0600, Tom Tromey wrote:
>> After rebasing our branch didn't compile, because
>> bfd_link_hash_table_free and bfd_link_hash_table_create don't exist any
Alan> bfd_link_hash_table_create is still available.
>> I worked around it for now by calling the _bfd_generic variants. This
>> is ugly, though, since presumably those functions are given the leading
>> underscore to indicate that they are private to BFD.
Alan> If you want to continue using bfd_link_hash_table_create, then your
Alan> cleanup should run:
Alan> if (abfd->is_linker_output)
Alan> (*abfd->link.hash->hash_table_free) (abfd);
Alan> However, I think you're going to be sorely disappointed in the
Alan> linker's ability to relocate final linked binaries.
I think we're only relocating .o files.