From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 4C578388E821; Wed, 6 May 2020 15:12:46 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4C578388E821 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1588777966; bh=MnGZ4+RPtd4EE1k6XFT7WmLvsZrtyJ5vylOTnzMLffA=; h=From:To:Subject:Date:In-Reply-To:References:From; b=q+G8LE7rXfEFZuEFoRD+uvaedo4RPLh9jLSIf1WU+hbZSdWvR/Fw2uGsMY3ynAZcv KHe0BXUKxs9gJ+tjQ0qT3K9xAo3d5H5StcfAJInkc+opkW6dK2wTO5cXT4OXf6ScA0 XKf7c+J15x1pi2X8cfMR2k5DEN7BsA1lMFpGEYg0= From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/94779] Bad optimization of simple switch Date: Wed, 06 May 2020 15:12:46 +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: 10.0 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: marxin at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: marxin at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: assigned_to bug_status 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: Wed, 06 May 2020 15:12:46 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D94779 Martin Li=C5=A1ka changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|unassigned at gcc dot gnu.org |marxin at gcc dot g= nu.org Status|NEW |ASSIGNED --- Comment #10 from Martin Li=C5=A1ka --- (In reply to Jakub Jelinek from comment #9) > Martin, I think switchconv pass should use get_range_info and completely > ignore labels with values outside of the range of the switch SSA_NAME ran= ge > (including the default label if all values in the SSA_NAME range have > explicit case labels). > That wouldn't change everything in this report, e.g. the #c0 one I think > doesn't even make switchconv as it is lowered earlier. Good point, I'll work on that!=