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]

mn10300 gas: `mov pc,aN' adds `pc' to symbol table


Assembling `mov pc,a[0-3]' after `.am33' would get `pc' added to the
symbol table, even though the insn is correctly assembled as copying
the program counter to one of the address registers.  That was because
other variants of the `mov' insn are tried first, and `pc' wasn't
recognized as a register name, so we ended up reading it as an
expression, which causes symbol_find_or_make() to be called on the
given name.  This patch fixes this problem.  Ok to install?

Index: gas/ChangeLog
from  Alexandre Oliva  <aoliva@redhat.com>

	* config/tc-mn10300.c (xr_registers): Added `pc'.

Index: gas/config/tc-mn10300.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-mn10300.c,v
retrieving revision 1.19
diff -u -p -r1.19 tc-mn10300.c
--- gas/config/tc-mn10300.c 2001/03/30 00:06:10 1.19
+++ gas/config/tc-mn10300.c 2001/04/06 07:14:04
@@ -212,6 +212,7 @@ static const struct reg_name xr_register
   { "mcrl", 3 },
   { "mcvf", 4 },
   { "mdrq", 1 },
+  { "pc", 0 },
   { "sp", 0 },
   { "xr0", 0 },
   { "xr1", 1 },

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist    *Please* write to mailing lists, not to me

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