Blob Blame History Raw
2005-11-09  Jakub Jelinek  <jakub@redhat.com>

	* dwarf2out.c (multiple_reg_loc_descriptor): Don't assume
	DBX_REGISTER_NUMBER being contiguous.

--- gcc/dwarf2out.c	(revision 106711)
+++ gcc/dwarf2out.c	(revision 106712)
@@ -8411,7 +8411,9 @@
   unsigned reg;
   dw_loc_descr_ref loc_result = NULL;
 
-  reg = dbx_reg_number (rtl);
+  reg = REGNO (rtl);
+  if ((unsigned) DBX_REGISTER_NUMBER (reg) != dbx_reg_number (rtl))
+    abort ();
   nregs = HARD_REGNO_NREGS (REGNO (rtl), GET_MODE (rtl));
 
   /* Simple, contiguous registers.  */
@@ -8424,7 +8426,7 @@
 	{
 	  dw_loc_descr_ref t;
 
-	  t = one_reg_loc_descriptor (reg);
+	  t = one_reg_loc_descriptor (DBX_REGISTER_NUMBER (reg));
 	  add_loc_descr (&loc_result, t);
 	  add_loc_descr_op_piece (&loc_result, size);
 	  ++reg;