From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 652B0386F41D; Fri, 22 Jan 2021 23:25:55 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 652B0386F41D From: "ebotcazou at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug ada/98228] [11 Regression] ICE: Assert_Failure atree.adb:931: Error detected at s-gearop.adb:382:34 [a-ngrear.adb:313:7 [a-nllrar.ads:18:1]] on s390x-linux-gnu Date: Fri, 22 Jan 2021 23:25:55 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ada X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: build, ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: ebotcazou at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: ebotcazou at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: assigned_to bug_status cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Jan 2021 23:25:55 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98228 Eric Botcazou changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|unassigned at gcc dot gnu.org |ebotcazou at gcc do= t gnu.org Status|NEW |ASSIGNED CC|ebotcazou at gcc dot gnu.org | --- Comment #16 from Eric Botcazou --- > # High-level flow of the resulting crashes: >=20 > - the procedure sem_type__get_next_interp has an output parameter of > record type sem_type__interp and overwrites that completely. > - in locations that call sem_type__get_next_interp, local variables of > type sem_type__interp get wrapped by maybe_pad_type in an outer > padding record for proper alignment. the padding record has a single > field "F" for the inner record. > - on s390x, that field gets falsely flagged as nonaddressable (see > zoom-in below). > - as a consequence of that flag, type based alias analysis does not > relate the padded record to the alias set of the inner record. > - modref_may_conflict disambiguates references to the local variables > (padded record) from sem_type__get_next_interp actually overwriting > the (inner) record -- "correct" decision based on the data, but > clearly the wrong result. > - as a result, loops that iterate via sem_type__get_next_interp are > "optimized" into endless loops, because their abort condition is > never checked against the updated data. > - these loops overrun All_Interp.Table and trigger assertions or > segfault (i've seen both). Thanks for the detailed investigation. The effect of nonaddressability on alias sets is as expected, but it is invalid to take the address of a nonaddressable field of course.=