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]
Other format: [Raw text]

Re: EP9312, Maverick Crunch fixes


On Wed, 25 Feb 2004, Paul Brook wrote:

> On Wednesday 25 February 2004 3:28 pm, Richard Earnshaw wrote:
> > > This way both "-mcpu=ep9312" and "-Wa,-mfpu=maverick" (from gcc
> > > point of view) will do the same thing.  However, i am not sure if this
> > > will break some gas/gcc convention(s) i don't know about.
>
> It already does. -mcpu=9312 defaults to FPU_ARCH_MAVERICK, and sets the
> corresponding flags in the object file.

Indeed.  By looking at the code it seems that the default fpu for ep9312
is FPU_MAVERICK, however the "Maverick float format" flag does not get set
for the resulting object file.

Probably for some reason the flag is omitted in 'cpu_variant' variable.
How can i check this quickly (i am afraid i am a bit lazy :-) ?

> > The reason for trying to split up the floating point from the cpu option
> > is that -mcpu must not change the ABI used by the compiler (it can change
> > the instructions available to use, but not the layout of data).
> > Regrettably, because the FPA uses a different floating point word order
> > from the VFP and Maverick the -mfpu option must have some effect on the
> > ABI, hence the split.  Consider the case where Linux (or some other OS is
> > being used on the ep9312 -- it should still use the same ABI as other ARM
> > boards so that you can take a generic ARM/<some-os> application and run it
> > on your machine.
>
> I agree.

Well, as of now -mcpu=ep9312 will allow gas to recognize Maverick Crunch
instructions, but it will not set the corresponding flag in the elf header
of its output, which will prevent ld to link it against other Crunch
object files.  I don't think this makes much sense.  If one is not going
to use the Crunch extension one can use -mcpu=arm920t and comply with the
rest of the world.

I added Crunch support in the linux kernel.  It didn't introduce any
incompatibility with the existing applications.  In fact i'm using mixed
set of 'standard' and Crunch powered applications just fine, however the
latter must be staticly built.  Of course this imply the use of Crunch
version of glibc, which we also had to port, but that's a different story.

I don't think there is a graceful way to have Crunch and non-crunch
application on a single OS (unless you recompile all user level apps), but
this shouldn't matter for the tools.


thanks,
Petko


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