From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 3B941386C58A; Thu, 14 Mar 2024 16:39:28 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3B941386C58A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1710434368; bh=eUGOeYTksWhGMcirRraL29jXAwHjC2W5d/Ob6kLPdMk=; h=From:To:Subject:Date:In-Reply-To:References:From; b=OU7Ik+hEDZIW82i5h1N71sLP4PzmsnSt84KktNeNnlqNwVlWbtPW4YvIrQJoPzHef VcsgeNu+BElMteXIggaKFJFdUu3VjcuG2MYX/+w/80mn7M3pxr3zMcFsGMed2MKRUT 7iNKqAf35XqP7ZZ5jUg4JXjUnD3WtyiftIp60Ppg= From: "hubicka at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug ipa/113907] [11/12/13/14 regression] ICU miscompiled since on x86 since r14-5109-ga291237b628f41 Date: Thu, 14 Mar 2024 16:39:27 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ipa X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: hubicka at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: hubicka at gcc dot gnu.org X-Bugzilla-Target-Milestone: 14.0 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=3D113907 --- Comment #59 from Jan Hubicka --- just to explain what happens in the testcase. There is test and testb. They are almost same: int testb(void) { struct bar *fp; test2 ((void *)&fp); fp =3D NULL; (*ptr)++; test3 ((void *)&fp); } the difference is in the alias set of FP. In one case it aliases with the (*ptr)++ while in other it does not. This makes one function to have jump function specifying aggregate value of 0 for *fp, while other does not. Now with LTO both struct bar and foo becomes compatible for TBAA, so the functions gets merged and the winning variant has the jump function specify= ing aggregate 0, which is wrong in the context code is invoked.=