From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 51D2E3858C52; Fri, 21 Apr 2023 17:16:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 51D2E3858C52 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1682097376; bh=4cvJeSc+fn+hhTASXmxJK7A4MVCIjsJLZvaWfalOEiE=; h=From:To:Subject:Date:In-Reply-To:References:From; b=X9LjQM1qFoMOTiQx7O8ctwkPQcRBgadhAGmD1goQn8Tb3XqiPmUfmoHi/OQ2gchId z9zWoVP+fnMvTwVJXGvxmocCGWsatkMwFCeysmalsjofTqst4MftY3N2e8ziwj459Q IkWTSevif6JQWwBWe5E4kdBY5AVRRNczmG3Vp0ug= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/109585] Carla/sord miscompiled with -O2 on ARM64 with flexible array member Date: Fri, 21 Apr 2023 17:16:16 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end X-Bugzilla-Version: 12.1.0 X-Bugzilla-Keywords: alias, wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: short_desc 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=3D109585 Andrew Pinski changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Carla/sord miscompiled with |Carla/sord miscompiled with |-O2 on ARM64 (inlining |-O2 on ARM64 with flexible |issue) |array member --- Comment #12 from Andrew Pinski --- Looks like the aliasing code is getting the flexible array member aliasing wrong. Replacing: ZixBTreeIterFrame stack[]; With: ZixBTreeIterFrame stack[1]; Fixes the issue ...=