From: Alan Modra <amodra@bigpond.net.au>
Cc: binutils@sourceware.org
Subject: Re: Omit output section from executable
Date: Thu, 03 Aug 2006 00:44:00 -0000 [thread overview]
Message-ID: <20060803004355.GA18882@bubble.grove.modra.org> (raw)
In-Reply-To: <20060802212907.GA32160@nevyn.them.org>
On Wed, Aug 02, 2006 at 05:29:07PM -0400, Daniel Jacobowitz wrote:
> On Wed, Aug 02, 2006 at 11:20:18PM +0200, Udo A. Steinberg wrote:
> > But how can I achieve the same for C sources? When I write:
> >
> > unsigned foo __attribute__((section (".cpulocal")));
> >
> > I get
> > .cpulocal 00000004 00000000 00000000 00000034 2**2
> > CONTENTS, ALLOC, LOAD, DATA
>
> I don't think you can do this from GCC.
Try this evil hack.
unsigned foo __attribute__((section (".cpulocal,\"aw\",@nobits#")));
The '#' might need to be different for targets that start gas comments
with another character.
--
Alan Modra
IBM OzLabs - Linux Technology Centre
next prev parent reply other threads:[~2006-08-03 0:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-02 20:43 Udo A. Steinberg
2006-08-02 20:50 ` Daniel Jacobowitz
2006-08-02 21:20 ` Udo A. Steinberg
2006-08-02 21:29 ` Daniel Jacobowitz
2006-08-03 0:44 ` Alan Modra [this message]
2006-08-03 1:02 ` Udo A. Steinberg
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=20060803004355.GA18882@bubble.grove.modra.org \
--to=amodra@bigpond.net.au \
--cc=binutils@sourceware.org \
/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).