[pr 69666] No SRA default_def replacements for unscalarizable
Martin Jambor
mjambor@suse.cz
Wed Feb 24 16:23:00 GMT 2016
On Tue, Feb 23, 2016 at 06:45:08AM -0800, H.J. Lu wrote:
> On Fri, Feb 19, 2016 at 8:21 AM, Martin Jambor <mjambor@suse.cz> wrote:
> > Hi,
> >
> > in PR 69666, SRA attempts to turn a load from an aggregate that is
> > uninitialized into a load from a default definition SSA name (which
> > something it does to generate an appropriate warning later) but
> > unfortunately it does so using an access structure which is
> > representable with __int128 when the load in question is smaller. It
> > then attempts to fix it up only to create an invalid V_C_E. In this
> > case, the correct thing to do is not to attempt the transformation,
> > when there are smaller accesses, which can be figured out by looking
> > at the unscalarizable_region flag of the access.
> >
> > Bootstrapped and tested on x86_64, OK for trunk and later for the 5
> > branch?
> >
>
> This may have caused:
>
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69920
>
I have reverted the patch on the gcc-5 branch as Jakub asked me to. I
do have a fix for the issue but I'd like to investigate one aspect of
this problem a bit more tomorrow (see below) before testing it and
formally proposing it here.
Sorry for the breakage,
Martin
--- a/gcc/tree-sra.c
+++ b/gcc/tree-sra.c
@@ -3504,7 +3504,8 @@ sra_modify_assign (gimple *stmt, gimple_stmt_iterator *gsi)
else
{
if (access_has_children_p (racc)
- && !racc->grp_unscalarized_data)
+ && !racc->grp_unscalarized_data
+ && TREE_CODE (lhs) != SSA_NAME)
{
if (dump_file)
{
More information about the Gcc-patches
mailing list