From: Nick Clifton <nickc@cygnus.com>
To: binutils@sourceware.cygnus.com
Subject: Where to put per-target global BFD data ?
Date: Thu, 01 Jul 1999 00:00:00 -0000 [thread overview]
Message-ID: <199906180941.KAA12938@pathia.cygnus.co.uk> (raw)
Hi Guys,
I have come across a problem with storing target specific global
data in BFD. Currently targets like the ARM ports create an
extended version of the link hash table, override the default
link_hash_table_create function with their own version, and then
store their data in the new fields now available.
This fails however, when the output format is not the same as the
input format. For example linking together a coff-arm object file
with the command line:
ld -oformat srec foo.o
will fail with a segmentation fault because the hash in the
link_info structure gets created based on the output format (srec)
not the input format (coff-arm). The srec format does not create an
extended structure on the end of the hash table, and so the coff-arm
routines that get called later, and which assume that the coff-arm
version of link_hash_table_create has been called, try to use data
which is not there.
I am not sure how this can be fixed. I think using the hash table
may not be the best way to store global information, because of this
problem, and that another solution needs to be found.
Any suggestions ?
Cheers
Nick
next reply other threads:[~1999-07-01 0:00 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-07-01 0:00 Nick Clifton [this message]
1999-07-01 0:00 ` Ian Lance Taylor
1999-07-01 0:00 ` Richard Henderson
1999-07-01 0:00 ` Jeffrey A Law
1999-07-01 0:00 ` Ian Lance Taylor
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=199906180941.KAA12938@pathia.cygnus.co.uk \
--to=nickc@cygnus.com \
--cc=binutils@sourceware.cygnus.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).