From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 29FE73857351; Tue, 18 Jul 2023 15:45:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 29FE73857351 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1689695125; bh=BdEmJH5Wt0yra5oGA2F/hqOr1Zwy1VntAuxQbNEkMNM=; h=From:To:Subject:Date:In-Reply-To:References:From; b=bqNytFLeynIz2T1Ohfz2HHbs+D9gqXP20l76rTbMzhNggSGXm36sNcOGOV4mm+hld 9Kur91zZch4XaRY5IDH9TiKWtqKPA5olMA5+ByDL1iZKMOVWTnydxhcvrQCYLzxKmY lQitekhVq80FFcd30570IQyqgC+VEmrC7Q+1ncQE= From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/102989] Implement C2x's n2763 (_BitInt) Date: Tue, 18 Jul 2023 15:45:24 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: enhancement X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: attachments.isobsolete attachments.created 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=3D102989 Jakub Jelinek changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #55567|0 |1 is obsolete| | --- Comment #85 from Jakub Jelinek --- Created attachment 55572 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D55572&action=3Dedit gcc14-bitint-wip.patch At least the x86-64 _BitInt psABI says that the padding bits are undefined = and the various other psABI proposals do that as well. Though, when looking at RTL expansion, we were doing REDUCE_BIT_FIELD after operations, meaning that that we effectively relied on those bits at least = for small/middle _BitInt to be sign or zero extended. This change tries to force sign/zero extensions when reading _BitInt from memory, parameters etc.=