From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 4C75E3857004; Thu, 20 Jul 2023 17:13:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4C75E3857004 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1689873207; bh=MV0CuDnzx9NJWuDwt2lInWTCfRe22Pgli4ztUadHNWc=; h=From:To:Subject:Date:In-Reply-To:References:From; b=TtozrVelTy3ZlttFPg3Wrk6POBtN6NJYlX8dPS6+2S9mS00Y4M89ov95Incls1Su5 HMU0lwBiCVDwKoVwYrmfD4zdvD3vifieyq4esvPzbCVbrbA1leaSFICE4Bi3u400o5 En/+N57/KEwhs1YcW4NzA/vpHkLxjzqignGDPWKs= From: "palmer at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/110748] RISC-V: optimize store of DF 0.0 Date: Thu, 20 Jul 2023 17:13:26 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 13.0 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: palmer at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: vineetg at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc 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=3D110748 palmer at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |palmer at gcc dot gnu.org --- Comment #6 from palmer at gcc dot gnu.org --- (In reply to Jeffrey A. Law from comment #5) > I'd bet it's const_0_operand not allowing CONST_DOUBLE. >=20 > The question is what unintended side effects we'd have if we allowed > CONST_DOUBLE 0.0 in const_0_operand. We don't have a architectural 0 register, so we'd probably end up needing to refactor some stuff. It's probably smoother to add some sort of "reg_or_0_or_0f_operand" type predicate, and then convert the floating-point stuff that takes X registers over to that (at least stores and integer->flo= at conversions, but maybe some comparisons too?).=