This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: Make bfd.link_next field a union
- From: Michael Eager <eager at eagerm dot com>
- To: Alan Modra <amodra at gmail dot com>
- Cc: binutils at sourceware dot org
- Date: Fri, 13 Jun 2014 09:33:25 -0700
- Subject: Re: Make bfd.link_next field a union
- Authentication-results: sourceware.org; auth=none
- References: <20140613094841 dot GE7683 at bubble dot grove dot modra dot org>
On 06/13/14 02:48, Alan Modra wrote:
This is the first of four patches aimed at fixing PR17047, a problem
that arose from people fussing over the linker not freeing the main
hash table before exit. In hindsight, I probably should have just
reverted the original patch and HP's more recent fix..
The link_next field of struct bfd is currently only used to chain
together linker input files. This patch prepares to use the field to
stash the linker hash table, which is always created on the linker
output file.
Is there a reason not to create a link_hash field, rather than
overload/reuse link_next? I've never been fond of using unions
to store unrelated data.
--
Michael Eager eager@eagercon.com
1960 Park Blvd., Palo Alto, CA 94306 650-325-8077