This is the mail archive of the mailing list for the crossgcc project.

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

Re: using relax with ld on i960 wrote:

> >To test this, I wrote a simple C program that calls a simple procedure
> >and
> >returns.  I compile this using the i960-wrs-vxworks5.3.1-gcc with the
> >-mleaf-procedures and -O3 options, and look at the assembly code.  Sure
> >enough, my little procedure is treated as a leaf (.lf).  When I link it
> >with --relax though, the 'calx' (it's actually a callx in the code) is
> >not changed to 'cal' or 'bal'.
> Unfortunately, the linker i960 relaxation only works when using the
> b.out object file format, and VxWorks 5.1 and beyond use COFF.  It
> would be possible to copy the relaxation code from bfd/bout.c into
> bfd/coff-i960.c and convert it to use COFF relocations, but nobody has
> done that.
> Ian

I don't know if I have the time (and definately not the expertice) to do
this.  I had thought a solution would be to have the link create relaxed
b.out format, and convert it to COFF using objcopy.  But someone told be
this would lose the symbols, thus rendering the file hard to debug.

Thanks for the feedback though Ian.  Is anyone else out there having the
same problem/working on a rewrite/found a different solution?