*Assembler* Error: unrecognized option `-marm920t'
Richard Earnshaw
rearnsha@arm.com
Mon Feb 17 14:51:00 GMT 2003
> I have the most recent releases: binutils 2.13.2.1and gcc 3.2.2.
> I now tried with 'arm920', which is accepted by the assembler.
> Unfortunately I have little idea, of how different each of these
> processors are...
>
> facit: 'arm920t' is a valid flag to gcc, but doesn't seem to be accepted
> even by the newest assembler, - this leaves one to speculate, how it was
> possible to test this flag in the first place? or am I wrong?
>
> So, do you think, -mcpu=arm920 -mtune=arm920t would be the best
> combination for an ARM920T?
>
The arm920 processor is not available without thumb, so the T in the name
can be considered optional -- in later processors it is dropped altogether.
Ok, you asked for it, here's the full gory story about the -m options in
the ARM assembler...
Traditionally, the assembler supported a cpu name with options of the form
-m<cpuname> or -m<cpunumber>
It also recognized some ARM Architecture versions with options of the form
-marmv<N> or -mv<N>
And recognized a limited number of cpu variants and architectures. The
support for this was done in a hand-crafted parser that was full of nasty
corner cases, and even then would allow some strings that weren't legal
processors. Extending the option parser was becoming difficult since it
wasn't clear what processors existed and what didn't.
Additionally, gcc had to know how to map options of the form -mcpu=XXX etc
into the assembler synax -mXXX, and how to handle certain combinations --
the result, as you have seen is that a lot of CPUS aren't recognized
correctly.
In order to clean this up I've deprecated all of the above assembler
options and replaced them with a much cleaner table-driven version that
supports options that are nearly identical to those that GCC accepts (for
example, GCC's -mcpu=XXX option can now be passed directly to the
assembler).
However, all released versions of GCC are still trying to do the mapping
to the old syntax, and we can't go back and change them now (time travel
would be so handy at times :-).
So to continue supporting old versions of GCC there is a legacy table of
all the reasonable expansions that the old assembler interface supported,
but this is now table-driven.
I've included a list of all the CPUs that the legacy interface supports
below. The list for the new interface is much more comprehensive, but
there seems to be little point in extending the old list since older GCC
releases can't really handle those processors that aren't in the existing
list.
Future releases of the assembler may turn on a warning if you try to use
the old options (all the code to do this is in place, but it's disabled);
that won't happen until a release or two of GCC using the new interface
has been out for a while. Eventually the old options will disappear
entirely.
So, to answer your question: -mcpu=arm920 will be quite sufficient for
your needs.
R.
CPU names recognized by the assembler using the old -m<cpuname> option:
arm1
arm2
arm250
arm3
arm6
arm600
arm610
arm620
arm7
arm70
arm700
arm700i
arm710
arm710c
arm720
arm7d
arm7di
arm7m
arm7dm
arm7dmi
arm7100
arm7500
arm7500fe
arm7t
arm7tdmi
arm710t
arm720t
arm740t
arm8
arm810
arm9
arm9tdmi
arm920
arm940
strongarm
strongarm110
strongarm1100
strongarm1110
xscale
------
Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com
More information about the crossgcc
mailing list