public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [google/4.6] Fix DW_OP_GNU_addr_index problem with -gfission. (issue5866047)
@ 2012-03-20 23:33 Cary Coutant
  0 siblings, 0 replies; only message in thread
From: Cary Coutant @ 2012-03-20 23:33 UTC (permalink / raw)
  To: reply, saugustine, gcc-patches

For google/gcc-4_6 branch.

Fix bug where we were outputting a garbage value for the index operand
of DW_OP_GNU_addr_index.

Tested: incremental remake in GCC build directory and hand tested.


2012-03-20   Cary Coutant  <ccoutant@google.com>

	* dwarf2out.c (size_of_loc_descr): Use val_index instead of
	v.val_unsigned.
	(output_loc_operands): Likewise.


Index: dwarf2out.c
===================================================================
--- dwarf2out.c	(revision 185585)
+++ dwarf2out.c	(working copy)
@@ -4902,7 +4902,7 @@ size_of_loc_descr (dw_loc_descr_ref loc)
       size += DWARF2_ADDR_SIZE;
       break;
     case DW_OP_GNU_addr_index:
-      size += size_of_uleb128 (loc->dw_loc_oprnd1.v.val_unsigned);
+      size += size_of_uleb128 (loc->dw_loc_oprnd1.val_index);
       break;
     case DW_OP_const1u:
     case DW_OP_const1s:
@@ -5283,7 +5283,7 @@ output_loc_operands (dw_loc_descr_ref lo
       break;
 
     case DW_OP_GNU_addr_index:
-      dw2_asm_output_data_uleb128 (loc->dw_loc_oprnd1.v.val_unsigned,
+      dw2_asm_output_data_uleb128 (loc->dw_loc_oprnd1.val_index,
                                    "(address index)");
       break;
 

--
This patch is available for review at http://codereview.appspot.com/5866047

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2012-03-20 23:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-20 23:33 [google/4.6] Fix DW_OP_GNU_addr_index problem with -gfission. (issue5866047) Cary Coutant

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).