summaryrefslogtreecommitdiffstats
path: root/gcc/dwarf2out.c
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2011-09-07 07:32:46 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2011-09-07 07:32:46 +0000
commitce9870772c788b5567900011a9b8de905131c572 (patch)
treed037890424ed98467b076d3cbfb4d95937c261ce /gcc/dwarf2out.c
parent0a7acbab7e68f24d519d0300d4ae9b7d84331fb2 (diff)
downloadppe42-gcc-ce9870772c788b5567900011a9b8de905131c572.tar.gz
ppe42-gcc-ce9870772c788b5567900011a9b8de905131c572.zip
PR debug/50191
* dwarf2out.c (mem_loc_descriptor) <case MEM>: Try avoid_constant_pool_reference first instead of last. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@178625 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/dwarf2out.c')
-rw-r--r--gcc/dwarf2out.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
index a38bcf8f21c..c11f666bfbf 100644
--- a/gcc/dwarf2out.c
+++ b/gcc/dwarf2out.c
@@ -11695,12 +11695,22 @@ mem_loc_descriptor (rtx rtl, enum machine_mode mode,
break;
case MEM:
+ {
+ rtx new_rtl = avoid_constant_pool_reference (rtl);
+ if (new_rtl != rtl)
+ {
+ mem_loc_result = mem_loc_descriptor (new_rtl, mode, mem_mode,
+ initialized);
+ if (mem_loc_result != NULL)
+ return mem_loc_result;
+ }
+ }
mem_loc_result = mem_loc_descriptor (XEXP (rtl, 0),
get_address_mode (rtl), mode,
VAR_INIT_STATUS_INITIALIZED);
if (mem_loc_result == NULL)
mem_loc_result = tls_mem_loc_descriptor (rtl);
- if (mem_loc_result != 0)
+ if (mem_loc_result != NULL)
{
if (GET_MODE_SIZE (mode) > DWARF2_ADDR_SIZE
|| GET_MODE_CLASS (mode) != MODE_INT)
@@ -11728,12 +11738,6 @@ mem_loc_descriptor (rtx rtl, enum machine_mode mode,
new_loc_descr (DW_OP_deref_size,
GET_MODE_SIZE (mode), 0));
}
- else
- {
- rtx new_rtl = avoid_constant_pool_reference (rtl);
- if (new_rtl != rtl)
- return mem_loc_descriptor (new_rtl, mode, mem_mode, initialized);
- }
break;
case LO_SUM:
OpenPOWER on IntegriCloud