public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Ian Lance Taylor <iant@google.com>
To: John Farmer <news02@lavabit.com>
Cc: gcc-help@gcc.gnu.org
Subject: Re: .gnu.linkonce.? and .gcc_except_table
Date: Tue, 24 Mar 2009 23:18:00 -0000	[thread overview]
Message-ID: <m38wmu8q8w.fsf@google.com> (raw)
In-Reply-To: <22691863.post@talk.nabble.com> (John Farmer's message of "Tue\, 24 Mar 2009 16\:08\:40 -0700 \(PDT\)")

John Farmer <news02@lavabit.com> writes:

> What pray tell may does .gnu.linkonce.r, .gnu.linkonce.b etc and
> gcc_except_table all mean when applied to input sections? Are any of these
> actually documented, presumably there are other such options too?

Those are the names of input section names.  The names beginning with
.gnu.linkonce are used by gcc for vague linking.  See the docs in the
gcc manual for why vague linking exists.  When the GNU linker sees two
input sections with the same name, and the name starts with
".gnu.linkonce.", the linker will only keep one copy and discard the
other.  .gcc_except_table is also an input section name, which gcc uses
for information used to unwind the stack when an exception occurs.


> Perhaps there is a good book available on the ins and outs of linker scripts
> or maybe a pdf hidden away in some dark corner. Any ideas?

Unfortunately I don't know of anything better than the linker
documentation.  I wrote the docs on linker scripts--they aren't so great
now but you should have seen what they looked like before.


> One last question if I may. In my trawling about I came across the term SysV
> in terms of linker scripts. What is this?

The GNU ld linker script language was originally based on the linker
script language used in the SVR3 linker.  It's changed a lot since then,
though.  (At some point the GNU linker also got support for the MRI
linker script language, but it is not widely used.  I hope.)

Ian

  reply	other threads:[~2009-03-24 23:18 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-24 23:08 John Farmer
2009-03-24 23:18 ` Ian Lance Taylor [this message]
2009-03-24 23:26   ` John Farmer
2009-03-26 18:27     ` John Farmer
2009-03-27 16:26       ` Ian Lance Taylor
2009-03-28  9:46         ` John Farmer
2009-03-28 11:29           ` John (Eljay) Love-Jensen
2009-03-28 15:07             ` John Farmer
2009-03-28 15:43               ` 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=m38wmu8q8w.fsf@google.com \
    --to=iant@google.com \
    --cc=gcc-help@gcc.gnu.org \
    --cc=news02@lavabit.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).