This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Aligment of data in .text and .data section (Intel/Linux)


On Tue, Jul 31, 2001 at 05:16:06PM +0200, Frank Klemm wrote:
> 
> How can I EXPLICITELY select an section alignment without patching the *.o
> files? Automatics are fine, I only need a switch to turn them of.

As far as I know, you can't decrease the alignment of an input section.

Your options are:
a) Use different section names.  Note that the end of a section
   is padded out according to the alignment, so this may not work very
   well if you're trying to tack things on to the end of compiler
   generated code in .text.  Also, you might need to set section
   attributes (ie. mark your sections executable) for this to work,
   or play with linker scripts.
b) Patch the assembler.  Hint: grep for record_alignment.

Alan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]