From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 20DE83858401; Sat, 22 Apr 2023 00:16:49 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 20DE83858401 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1682122609; bh=EWCDLrI1gkUjcmzwafks0dMu12ITC+TO86r+TObic9Q=; h=From:To:Subject:Date:In-Reply-To:References:From; b=v4S+X4zkRVtxtBtS+kGNF8Wj7iTmMaS5rPguT2c8wqP+pzC/lYqgwhNkrERdKP9Xk b75rIo9ybNGPuj36VBGiKffa3wHPZL4yCYDX3uMErcyctV6oJYQdPl2GvKtjFxuK/c IeliZOi+KQWh95RoOAUquKPaudjIWINqx+3zOGNY= From: "law at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/106888] [RISCV] Negative optimization that excess andi instructions are generated in gcc.dg/pr90838.c Date: Sat, 22 Apr 2023 00:16:45 +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: 13.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: law 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: 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=3D106888 --- Comment #10 from Jeffrey A. Law --- The sign_extend later gets turned into zero_extend. Presumably because we = know the value is never negative. That in and of itself wouldn't be a big deal = as it should be easily recognizable using any_extend. But combine steps in and scrambles the RTL in various unhelpful ways.=