1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/patches/binutils/2.15/190-vmx.patch Sun Jan 18 15:08:28 2009 +0000
1.3 @@ -0,0 +1,45 @@
1.4 +Grabbed with
1.5 +wget 'http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/opcodes/ppc-opc.c.diff?r1=1.70&r2=1.71&cvsroot=src'
1.6 +See
1.7 +http://mail.gnu.org/archive/html/bug-binutils/2004-05/msg00071.html
1.8 +and
1.9 +http://sources.redhat.com/ml/binutils-cvs/2004-05/msg00111.html
1.10 +
1.11 +This fixes problems like
1.12 +{standard input}: Assembler messages:
1.13 +{standard input}:1: Error: Unrecognized opcode: `dssall'
1.14 +which show up in binutils-2.15 when building the Linux kernel,
1.15 +or possibly failed compilations when building setjmp/longjmp in glibc.
1.16 +
1.17 +An alternative fix would be to pass -many to the assembler.
1.18 +A patch to do that for glibc is at
1.19 +wget 'http://sources.redhat.com/cgi-bin/get-raw-msg?listname=libc-alpha&date=2004-05&msgid=40B36E8C.9030609%40us.ibm.com'
1.20 +Yet another, better, fix would be for gcc to generate assembly
1.21 +that told the assembler which processor type to use.
1.22 +Presumably the Linux kernel sources would need a fix, too.
1.23 +Probably better to just fix binutils to accept sources that it used to.
1.24 +
1.25 +
1.26 +===================================================================
1.27 +RCS file: /cvs/src/src/opcodes/ppc-opc.c,v
1.28 +retrieving revision 1.70
1.29 +retrieving revision 1.71
1.30 +diff -u -r1.70 -r1.71
1.31 +--- src/opcodes/ppc-opc.c 2004/05/05 13:43:36 1.70
1.32 ++++ src/opcodes/ppc-opc.c 2004/05/19 05:11:48 1.71
1.33 +@@ -1004,8 +1004,13 @@
1.34 +
1.35 + /* If only one bit of the FXM field is set, we can use the new form
1.36 + of the instruction, which is faster. Unlike the Power4 branch hint
1.37 +- encoding, this is not backward compatible. */
1.38 +- else if ((dialect & PPC_OPCODE_POWER4) != 0 && (value & -value) == value)
1.39 ++ encoding, this is not backward compatible. Do not generate the
1.40 ++ new form unless -mpower4 has been given, or -many and the two
1.41 ++ operand form of mfcr was used. */
1.42 ++ else if ((value & -value) == value
1.43 ++ && ((dialect & PPC_OPCODE_POWER4) != 0
1.44 ++ || ((dialect & PPC_OPCODE_ANY) != 0
1.45 ++ && (insn & (0x3ff << 1)) == 19 << 1)))
1.46 + insn |= 1 << 20;
1.47 +
1.48 + /* Any other value on mfcr is an error. */