This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
powerpc parse_cpu
- From: Ryan Mansfield <rmansfield at qnx dot com>
- To: binutils at sourceware dot org
- Date: Mon, 17 Dec 2007 20:55:24 -0500
- Subject: powerpc parse_cpu
Is it an intentional requirement that -maltivec or -mspe be specified
after the cpu type? If one specifies -mspe or -maltivec (or equivalent
pseudo opt) before the cpu type, the altivec/spe opcode flag will be
overridden.
For example:
$ cat foo.s
dssall
rfid
$ ntoppc-as-2.18 -mppc64 -maltivec foo.s
$ ntoppc-as-2.18 -maltivec -mppc64 foo.s
foo.s: Assembler messages:
foo.s:1: Error: Unrecognized opcode: `dssall'
In parse_cpu:
867 else if (strcmp (arg, "altivec") == 0)
868 {
869 if (ppc_cpu == 0)
870 ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC |
PPC_OPCODE_ALTIVEC;
871 else
872 ppc_cpu |= PPC_OPCODE_ALTIVEC;
873 }
...
890 else if (strcmp (arg, "ppc64") == 0 || strcmp (arg, "620") == 0)
891 {
892 ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC |
PPC_OPCODE_64;
893 }
If this is the expected behavior, is it documented anywhere?
Regards,
Ryan Mansfield