https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93516
--- Comment #9 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Martin Jambor <jamb...@gcc.gnu.org>: https://gcc.gnu.org/g:4d6bf96b583d77336cf6ca643d92d068a88414fa commit r10-6779-g4d6bf96b583d77336cf6ca643d92d068a88414fa Author: Martin Jambor <mjam...@suse.cz> Date: Fri Feb 21 13:38:22 2020 +0100 sra: Only verify sizes of scalar accesses (PR 93845) the testcase is another example - in addition to recent PR 93516 - where the SRA access verifier is confused by the fact that get_ref_base_extent can return different sizes for the same type, depending whether they are COMPONENT_REF or not. In the previous bug I decided to keep the verifier check for aggregate type even though it is not really important and instead avoid easily detectable type-within-the-same-type situation. This testcase is however a result of a fairly random looking type cast and so cannot be handled in the same way. Because the check is not really important for aggregates, this patch simply disables it for non-register types. 2020-02-21 Martin Jambor <mjam...@suse.cz> PR tree-optimization/93845 * tree-sra.c (verify_sra_access_forest): Only test access size of scalar types. testsuite/ * g++.dg/tree-ssa/pr93845.C: New test.