[PATCH] Fix PR optimization/12544
Mark Mitchell
mark@codesourcery.com
Sat Oct 11 18:50:00 GMT 2003
On Sat, 2003-10-11 at 10:05, Eric Botcazou wrote:
> Hi,
>
> This is a regression from GCC 3.2.3 present on the 3.3 branch and mainline
> that shows up on SPARC (and more generally on targets that pass structures
> by invisible references), caused by my patch that has instructed the
> compiler to set the DECL_NONLOCAL flag on variables used by nested functions
> during the parsing of their parent, instead of during the RTL generation of
> the child functions.
>
> It turns out that put_var_into_stack implicitly thinks that DECL_NONLOCAL can
> only be seen from within nested functions, which is of course not true
> anymore. More precisely, it applies a first transformation reserved to
> special DECL_NONLOCAL decls then a second one reserved to non-DECL_NONLOCAL
> decls, because it doesn't test the DECL_NONLOCAL flag in the second case. So
> we end up putting a DECL_NONLOCAL argument in an ADDRESSOF with a bogus mode
> and ICE when attempting to generate a SImode to BLKmode move.
>
> Bootstrapped/regtested on sparc-sun-solaris2.8 (3.3 branch except Ada). Ok
> for mainline and 3.3 branch?
Yes, please put this on the 3.3 branch as well.
Thanks,
--
Mark Mitchell <mark@codesourcery.com>
CodeSourcery, LLC
More information about the Gcc-patches
mailing list