This is the mail archive of the
mailing list for the binutils project.
Re: Is it normal that ld promote a section size
- From: Alan Modra <amodra at gmail dot com>
- To: Terry Guo <flameroc at gmail dot com>
- Cc: binutils at sourceware dot org
- Date: Mon, 23 Feb 2015 17:47:46 +1030
- Subject: Re: Is it normal that ld promote a section size
- Authentication-results: sourceware.org; auth=none
- References: <CAGbRaL4YH8B-RKMSzTgOe4Steu=G-qw=Tv4aqT0c9aqDSCYgdQ at mail dot gmail dot com> <20150216065447 dot GG4274 at bubble dot grove dot modra dot org> <CAGbRaL6u+RUQPKnKB34zAbQZV3VjKd82OZE1ffgGKaX=Fnx7mg at mail dot gmail dot com> <CAGbRaL7CdCeSADO-XhM1SyMq9WBsHh-JExx9ci1qUMzKzxiTWQ at mail dot gmail dot com>
On Mon, Feb 23, 2015 at 09:47:26AM +0800, Terry Guo wrote:
> 0x800 by gas. I checked SUB_SEGMENT_ALIGN as you suggested, but
> couldn't find more detailed information to help me understand this
> issue. Do you know the background why gas has to promote the size to
> its alignment? Thanks.
What binutils target are you using?
As far as I known, SUB_SEGMENT_ALIGN was needed for compatibility with
older assemblers (AOUT and COFF), and also on ia64 to ensure that code
sections are a multiple of the bundle size. There may be other
targets that have similar code section restrictions.
Australia Development Lab, IBM