expr.c (store_constructor): Set RTX_UNCHANGING_P if readonly_field_p before clearing.

* expr.c (store_constructor): Set RTX_UNCHANGING_P if readonly_field_p
	before clearing.

From-SVN: r65890
This commit is contained in:
Richard Kenner 2003-04-21 17:50:51 +00:00 committed by Richard Kenner
parent 3819b963dc
commit 337f4314e6
2 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2003-04-21 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
* expr.c (store_constructor): Set RTX_UNCHANGING_P if readonly_field_p
before clearing.
2003-04-21 Mark Mitchell <mark@codesourcery.com>
* config/i386/winnt.c (i386_pe_mark_dllimport): Make the new RTL

View File

@ -4899,7 +4899,15 @@ store_constructor (exp, target, cleared, size)
|| ((HOST_WIDE_INT) GET_MODE_SIZE (GET_MODE (target))
== size)))
{
clear_storage (target, GEN_INT (size));
rtx xtarget = target;
if (readonly_fields_p (type))
{
xtarget = copy_rtx (xtarget);
RTX_UNCHANGING_P (xtarget) = 1;
}
clear_storage (xtarget, GEN_INT (size));
cleared = 1;
}