From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id F2D023858C41; Fri, 19 May 2023 17:31:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F2D023858C41 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1684517504; bh=0N9psFo2iH6unxhzKqOAbSYUOCq8lVP25vYCmB8oMM4=; h=From:To:Subject:Date:In-Reply-To:References:From; b=yh4BSy9BLturYpDIhSAGS9UeYWhndKlTsddRaA6BP8GfrF8MdU6Cv1hjaILxqkZy+ Pa6hjANifUYYaVYMkEK74Ddkx4jzcPcXCPug4F4hgIh5fBT4bu2QXOJin+HYDZvXOb 5Ks7YkOjTMsDchalZYrldlt2Nj8q50AfZ/u9HOfg= From: "vineetg at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/109279] RISC-V: complex constants synthesized should be improved Date: Fri, 19 May 2023 17:31:43 +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: unknown X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: vineetg at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED 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: cc 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D109279 Vineet Gupta changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |vineetg at gcc dot gnu.org Status|NEW |ASSIGNED --- Comment #15 from Vineet Gupta --- (In reply to Andrew Pinski from comment #6) > Take: > long long f(void) > { > return 0x0101010101010101ull; > } >=20 > ---- CUT ---- > This should be done as: > li a0,16842752 > addi a0,a0,257 > slli a1,a0,32 > or a0,a0,a1 I committed a fix today which gets us to exactly that [1] [1] https://gcc.gnu.org/pipermail/gcc-patches/2023-May/618948.html=