This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Allow (mem:BLK (pre_modify:P )) in var-tracking


Hi!

As discussed on IRC and in PR43399, there is a pasto in adjust_mems.
For {PRE,POST}_MODIFY we want just assert that mem_mode is not VOIDmode
(which means that {PRE,POST}_MODIFY is inside some MEM), as
{PRE,POST}_MODIFY can be inside of MEM:BLK.  Only {PRE,POST}_{INC,DEC}
require non-BLK containing MEM, as in that case the adjustment is done
by the size of MEM, and for BLKmode the size is not known.

Ok for trunk?

2010-03-18  Jakub Jelinek  <jakub@redhat.com>

	PR bootstrap/43399
	* var-tracking.c (adjust_mems) <case POST_MODIFY>: Allow BLKmode
	mem_mode.

--- gcc/var-tracking.c.jj	2010-03-18 09:35:52.000000000 +0100
+++ gcc/var-tracking.c	2010-03-18 11:18:08.000000000 +0100
@@ -804,7 +804,7 @@ adjust_mems (rtx loc, const_rtx old_rtx,
     case POST_MODIFY:
       if (addr == loc)
 	addr = XEXP (loc, 0);
-      gcc_assert (amd->mem_mode != VOIDmode && amd->mem_mode != BLKmode);
+      gcc_assert (amd->mem_mode != VOIDmode);
       addr = simplify_replace_fn_rtx (addr, old_rtx, adjust_mems, data);
       amd->side_effects = alloc_EXPR_LIST (0,
 					   gen_rtx_SET (VOIDmode,

	Jakub


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