Skip to contentSkip to conversation

hppa-linux-gas binutils patch

PATCH New Helge Deller 1 participant 1 message Nov 23, 2006

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 hppa-linux-gas binutils patch

hppa-linux-gnu-gas only allows one type of ".equ" pseudo-op syntax:
symbol: .equ value

The following patch allows hppa-gas to understand
.equ symbol,value
as well, which seems to be pretty standard for other gas-targets as well.

I didn't found any problems yet with this patch, and it allows even the src/binutils/testsuite/binutils-all/localize-hidden-1.s
gas test to compile.

Comments ?
If OK, would somebody with write-access to binutils submit it upstream ?

Helge

Index: gas/config/tc-hppa.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-hppa.c,v
retrieving revision 1.133

config/tc-hppa.c +6 -3
diff -u -r1.133 tc-hppa.c
@@ -3262,7 +3262,7 @@
       return;
     }
 
-  /* Look up the opcode in the has table.  */
+  /* Look up the opcode in the hash table.  */
   if ((insn = (struct pa_opcode *) hash_find (op_hash, str)) == NULL)
     {
       as_bad ("Unknown opcode: `%s'", str);
@@ -6397,8 +6397,11 @@
     {
       if (reg)
 	as_bad (_(".REG must use a label"));
-      else
-	as_bad (_(".EQU must use a label"));
+      else {
+	/* Try gas' standard ".equ X,Y" pseudo opcode.  */
+      	s_set(0);
+	return;
+      }
     }
 
   pa_undefine_label ();

_______________________________________________
parisc-linux mailing list
[email protected]
http://lists.parisc-linux.org/mailman/listinfo/parisc-linux