File pr42429.diff of Package gcc43

2009-12-21  Jakub Jelinek  <jakub@redhat.com>

	PR rtl-optimization/42429
	* reload.c (find_reloads_subreg_address): When adjusting mode of
	MEM, update also MEM_SIZE if it is set.

Index: gcc/reload.c
===================================================================
--- gcc/reload.c	(revision 155374)
+++ gcc/reload.c	(revision 155375)
@@ -6096,6 +6096,9 @@ find_reloads_subreg_address (rtx x, int
 	      PUT_MODE (tem, GET_MODE (x));
 	      if (MEM_OFFSET (tem))
 		set_mem_offset (tem, plus_constant (MEM_OFFSET (tem), offset));
+	      if (MEM_SIZE (tem)
+		  && INTVAL (MEM_SIZE (tem)) != (HOST_WIDE_INT) outer_size)
+		set_mem_size (tem, GEN_INT (outer_size));
 
 	      /* If this was a paradoxical subreg that we replaced, the
 		 resulting memory must be sufficiently aligned to allow

openSUSE Build Service is sponsored by