https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80898
--- Comment #6 from Martin Jambor <jamborm at gcc dot gnu.org> --- Author: jamborm Date: Thu Jun 1 12:14:29 2017 New Revision: 248790 URL: https://gcc.gnu.org/viewcvs?rev=248790&root=gcc&view=rev Log: [PR 80898] Propagate grp_write from disqualified SRA candidates 2017-06-01 Martin Jambor <mjam...@suse.cz> PR tree-optimization/80898 * tree-sra.c (process_subtree_disqualification): Removed. (disqualify_candidate): Do not acll process_subtree_disqualification. (subtree_mark_written_and_enqueue): New function. (propagate_all_subaccesses): Set grp_write of LHS subtree if the RHS has been disqualified and re-queue LHS if necessary. Apart from that, ignore disqualified RHS. testsuite/ * gcc.dg/tree-ssa/pr80898.c: New test. * gcc.dg/tree-ssa/pr80898-2.c: Likewise. Added: trunk/gcc/testsuite/gcc.dg/tree-ssa/pr80898-2.c trunk/gcc/testsuite/gcc.dg/tree-ssa/pr80898.c Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-sra.c