From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 21DA6385B532; Mon, 6 May 2024 13:12:45 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 21DA6385B532 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1715001165; bh=L5JbH8AshUoN/1tp4VYKOsEo/YhwX223X0GEVzlSrI4=; h=From:To:Subject:Date:In-Reply-To:References:From; b=TrwYMrkYHvV41H1HMyC8qw2dx8XdnRBsbuFejrXXOwN5tfuvPGt2RG7sdBU1URS2r GyjVzG2AnM4lfTp0erH9G0Nx2MjN7dz1Mvfby1dRU50XdISUVkh2ZvvRThWia7jZYe yT5Gh7FKEIxYrjT181cydfbg86+zmRMbVQT2Wrv0= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/100923] [9 Regression] wrong code at -O2 and above on x86_64-linux-gnu Date: Mon, 06 May 2024 13:12:43 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: alias, wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.4 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D100923 --- Comment #11 from GCC Commits --- The master branch has been updated by Richard Biener : https://gcc.gnu.org/g:7c469a9fc785505dc350aba60311812c2bb0c1b5 commit r15-204-g7c469a9fc785505dc350aba60311812c2bb0c1b5 Author: Richard Biener Date: Wed Feb 28 10:08:31 2024 +0100 tree-optimization/100923 - re-do VN with contextual PTA info fix The following implements the gist of the PR100923 fix in a leaner (and more complete) way by realizing that all ao_ref_init_from_vn_refer= ence uses need to have an SSA name in the base valueized with availability in mind. Instead of re-valueizing the whole chain of operands we can simply only and always valueize the SSA name we put in the base. This handles also two omitted places in vn_reference_lookup_3. PR tree-optimization/100923 * tree-ssa-sccvn.cc (ao_ref_init_from_vn_reference): Valueize base SSA_NAME. (vn_reference_lookup_3): Adjust vn_context_bb around calls to ao_ref_init_from_vn_reference. (vn_reference_lookup_pieces): Revert original PR100923 fix. (vn_reference_lookup): Likewise.=