public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Linker Sections and OBJDUMP
@ 2000-01-06 16:06 Rudy Folden
  2000-01-07  6:07 ` Eric DeVolder
  2000-04-01  0:00 ` Rudy Folden
  0 siblings, 2 replies; 4+ messages in thread
From: Rudy Folden @ 2000-01-06 16:06 UTC (permalink / raw)
  To: help-gcc

Hi,

I am converting a proprietary operating system for the PowerPC from the Diab
and Metaware tools sets to GNU and have identified a new section called
".vect" which contains instructions and vectors and which must be loaded at
a specific address.  This was the process used under Diab and Metaware.

I use the following directive in the appropriate assembly files:

    .section .vect

and it appeared to work since the map shows the section loaded to the
correct address.

However, since I am converting existing startup code from the Diab tools to
the GNU tools,  I wanted to insure that the object generated was correct.
So, I tried disassembling the objects that contain the .vect sections using
the "objdump -D" option but I do not get a disassembly...it is blank.

Also, when I dump the object using "objdump -h" it shows attributes for the
.text and .data sections such as LOAD, READONLY, CODE or DATA, but the new
.vect section does NOT show up as CODE. This leads me to believe that the
object modules may not be relocatable and externals defined therein may not
be resolved correctly.

The following is the output of the "objdump -h" command:

VBD60\PP6ra.o:     file format elf32-powerpc

Sections:
Idx Name          Size      VMA       LMA       File off  Algn
  0 .text         001c2dc8  ff800000  ff800000  00040000  2**4
                  CONTENTS, ALLOC, LOAD, READONLY, CODE
  1 .data         000294b0  10000000  10000000  00010000  2**4
                  CONTENTS, ALLOC, LOAD, DATA
  2 .vxworks      00000308  100e0000  100e0000  00202dc8  2**0
                  CONTENTS
  3 .vect         00002250  fff00000  fff00000  00203100  2**8
                  CONTENTS, READONLY
  4 .comment      00004de0  100294b0  100294b0  00205350  2**0
                  CONTENTS, READONLY
  5 .stab         00004788  1002e290  1002e290  0020a130  2**2
                  CONTENTS, READONLY, DEBUGGING
  6 .debug        00045c90  1003748c  1003748c  0020e8b8  2**2
                  CONTENTS, READONLY, DEBUGGING
  7 .debug_srcinfo0000012c  1007d11c  1007d11c  00254548  2**0
                  CONTENTS, READONLY, DEBUGGING
  8 .debug_aranges000001bc  1007d248  1007d248  00254674  2**0
                  CONTENTS, READONLY, DEBUGGING
  9 .debug_pubnames000008cb  1007d404  1007d404  00254830  2**0
                  CONTENTS, READONLY, DEBUGGING
 10 .debug_sfnames00000255  1007dccf  1007dccf  002550fb  2**0
                  CONTENTS, READONLY, DEBUGGING
 11 .line         00002d6a  1007df24  1007df24  00255350  2**0
                  CONTENTS, READONLY, DEBUGGING
 12 .stabstr      00004a73  10032a18  10032a18  002580ba  2**0
                  CONTENTS, READONLY, DEBUGGING


Does anyone have insight into this situation? I would really like to
disassemble the objects to insure that the code is being generated
correctly.
I am hoping that there might be an option on the .section directive that
would cause it to be treated as an "executable" section with a unique name
(as with Diab), but there is not one documented.

Thanks,
Rudy L. Folden



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2000-04-01  0:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-01-06 16:06 Linker Sections and OBJDUMP Rudy Folden
2000-01-07  6:07 ` Eric DeVolder
2000-04-01  0:00   ` Eric DeVolder
2000-04-01  0:00 ` Rudy Folden

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).