From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 71ED23858D37; Tue, 21 Nov 2023 21:59:37 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 71ED23858D37 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1700603977; bh=PWCR29Pbfn0JcOQmvx/sJFGUrHmfXURwJnNO23mbIAc=; h=From:To:Subject:Date:In-Reply-To:References:From; b=EGP7nx2+Hq2Qk3MB9MeuPucrhw958Qn45JyapzPJDt+My/m2/L6jGsdjosJpY7NwL eZK0527JvE1bY9wc7QNL0Y14R9mnvfthaxSzXu2NsbcfnmfvZk56O07TIRJEDn41EE e4Z8SDpxpFD/MSjmSFKx+WF4OWsvAugFadFPMB/4= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/112657] [13/14 Regression] missed optimization: cmove not used with multiple returns Date: Tue, 21 Nov 2023 21:59:37 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: rtl-optimization X-Bugzilla-Version: 13.2.1 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 13.3 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: component cf_known_to_fail cf_known_to_work short_desc target_milestone 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=3D112657 Andrew Pinski changed: What |Removed |Added ---------------------------------------------------------------------------- Component|target |rtl-optimization Known to fail| |13.1.0 Known to work| |12.3.0 Summary|missed optimization: cmove |[13/14 Regression] missed |not used with multiple |optimization: cmove not |returns |used with multiple returns Target Milestone|--- |13.3 --- Comment #2 from Andrew Pinski --- The difference between GCC 12 and GCC 13 is: GCC 13: ``` IF-THEN-JOIN block found, pass 1, test 2, then 3, join 4 ``` GCC 12 and before: ``` IF-THEN-ELSE-JOIN block found, pass 1, test 2, then 3, else 4, join 5 ``` Someone will have to debug ifcvt.cc to see why it fails on x86_64 but works= on aarch64. Note there are some new changes to ifcvt.cc in review which might improve this, though I am not sure.=