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]

Re: RFC: PowerPC GAS changes



> There is support for doing this kind of thing already.  For instance,
> try using the POWER instruction 'mfmq' with -mppc:
> 
> [geoffk@envy geoffk]$ cat > t.s
>         mfmq %r3
> [geoffk@envy geoffk]$ as -m601 t.s -o t.o
> [geoffk@envy geoffk]$ as -mpwr t.s -o t.o
> [geoffk@envy geoffk]$ as -mppc t.s -o t.o
> t.s: Assembler messages:
> t.s:1: Error: Unrecognized opcode: `mfmq'
> 
> it's just a question of getting the flag arrangement right.

That is correct, however if you specify -m603, -m604, -m750, -m403,
-m405, -m860 you get exactly the same assembly info.  The biggest
problem is we only have 32 bits of space in "flags".  I can fill all 32
bits quickly with what is already there and add in CPU types of 603,
604, 620, 750, 7400, 8xx, 4xx, 403, 405, etc..  (you get the point)

For instance the "dcba" instruction is defined as an option instruction
for the PPC architecture.  So the "PPC" flag is set.  However, (if I
remember right) only the 405 and 7400 actually implement that
instruction.  If I assemble w/o -m (or passing -mppc) I want to be able
to use that instruction, but if I assemble w/ -m604 that instruction
should be illegal.

Again, what you have above are the only true (working) -m
configuruations, ppc, pwr and 601.

--Mark

> --
> - Geoffrey Keating <geoffk@cygnus.com>

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