Update of /cvsroot/gc-linux/binutils/gas/config
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4543/gas/config
Modified Files:
tc-ppc.c
Log Message:
From: Anders M Montonen <amm...@cc...>
To: gc-...@li...
Subject: [Gc-linux-devel] Gekko binutils patch
Date: Sun, 2 May 2004 19:11:02 +0300 (EET DST)
Hi, this is a in-progress patch for adding support for the Gekko
instructions to binutils (as and objdump). It's not well-tested at all,
and it's incomplete because the load and store instructions are still
missing because I don't really understand their encoding (eg. what do the
W and I fields represent?)
The patch is against current CVS, and any help testing/fixing/whatever is
appreciated.
To assemble Gekko instructions, pass "-mgekko" to as, and to disassemble
them pass "-Mgekko" to objdump.
-Anders
Index: tc-ppc.c
===================================================================
RCS file: /cvsroot/gc-linux/binutils/gas/config/tc-ppc.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -d -r1.1.1.1 -r1.2
--- tc-ppc.c 16 Jul 2005 22:22:01 -0000 1.1.1.1
+++ tc-ppc.c 17 Jul 2005 00:14:50 -0000 1.2
@@ -914,6 +914,9 @@
/* -many means to assemble for any architecture (PWR/PWRX/PPC). */
else if (strcmp (arg, "any") == 0)
ppc_cpu |= PPC_OPCODE_ANY;
+ else if (strcmp (arg, "gekko") == 0)
+ ppc_cpu = (PPC_OPCODE_CLASSIC | PPC_OPCODE_PPC
+ | PPC_OPCODE_32 | PPC_OPCODE_GEKKO);
else
return 0;
@@ -1106,6 +1109,7 @@
-maltivec generate code for AltiVec\n\
-me500, -me500x2 generate code for Motorola e500 core complex\n\
-mspe generate code for Motorola SPE instructions\n\
+-mgekko generate code for Gamecube Gekko\n\
-mregnames Allow symbolic names for registers\n\
-mno-regnames Do not allow symbolic names for registers\n"));
#ifdef OBJ_ELF
@@ -1150,6 +1154,9 @@
else
ppc_cpu |= PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_32;
}
+ else if (strcmp (default_cpu, "gekko") == 0)
+ ppc_cpu |= (PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_32
+ | PPC_OPCODE_GEKKO);
else
as_fatal (_("Unknown default cpu = %s, os = %s"),
default_cpu, default_os);
|