This is the mail archive of the binutils@sourceware.cygnus.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: gas bug


On Thu, 6 Apr 2000, Andrew Morton wrote:

> The gas which comes with Mandrake 7.0 is generating bad code for me.

Only because the source is bad :-)

Here's the result of objdump --headers
Sections:
Idx Name          Size      VMA       LMA       File off  Algn
  0 .text         000026ff  00000000  00000000  00000034  2**2
                  CONTENTS, ALLOC, LOAD, RELOC, READONLY, CODE
 .
 .
 .
  5 .text.init    00000d36  00000000  00000000  00003a04  2**2
                  CONTENTS, ALLOC, LOAD, RELOC, DATA

Notice that .text.init is DATA, not CODE.  .align in a data section emits
zeros, not nops.


In the assembly file you had on the web, the first occurence of .text.init
has:

.section	.text.init,"aw",@progbits

The "aw" needs to be "ax".

-- 
Linuxcare.  Support for the Revolution.


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