From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 8143 invoked from network); 31 May 2023 14:16:14 -0000 Received: from second.openwall.net (193.110.157.125) by inbox.vuxu.org with ESMTPUTF8; 31 May 2023 14:16:14 -0000 Received: (qmail 13594 invoked by uid 550); 31 May 2023 14:16:05 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 13533 invoked from network); 31 May 2023 14:16:05 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inria.fr; s=dc; h=from:to:subject:date:message-id:mime-version: content-transfer-encoding; bh=85p7XWEcIHyuu5Roibis1UWC0JL8mK7ff7wK1PVDAio=; b=PHlZqbTaRwghFI/76gWg8qUbPqmFqsv0LlUHbqaxWaI7o8aMIpMafSXj NHG/WkcHcj+k2amGl3xYm57foYEQcEI1Ed4Ez1kvBdfGBtseVwzWoPSw+ ftCw5IxKzFD89Li2XhWyLY6NwosrzfpE6IDW2UXOPE364ZmBRaK7est0j 8=; Authentication-Results: mail3-relais-sop.national.inria.fr; dkim=none (message not signed) header.i=none; spf=SoftFail smtp.mailfrom=Jens.Gustedt@inria.fr; dmarc=fail (p=none dis=none) d=inria.fr X-IronPort-AV: E=Sophos;i="6.00,207,1681164000"; d="scan'208";a="57463837" From: Jens Gustedt To: musl@lists.openwall.com Date: Wed, 31 May 2023 16:15:46 +0200 Message-Id: X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [musl] [C23 128 bit 0/4] implement the library part of 128 bit support This does not implement full featured support for 128 bit types or functions. It only enables the support that is necessary, such that compilers can claim [u]int128_t types and their functionality. All 128 types and arithmetic has to be provided by the compilers. Jens Gustedt (4): add an emulation for 128 bit arithmetic as needed for C library support C23: implement w128 and wf128 support for printf C23: implement w128 and wf128 for scanf and similar C23: implement proper support for int128_t and uint128_t include/inttypes.h | 55 ++++++++ include/stdint.h | 37 +++++ src/internal/intscan.c | 105 +++++++++++--- src/internal/intscan.h | 4 +- src/internal/uwide128.c | 213 +++++++++++++++++++++++++++++ src/internal/uwide128.h | 57 ++++++++ src/internal/x86_64/uwide128_pop.s | 27 ++++ src/stdio/vfprintf.c | 113 +++++++++------ src/stdio/vfscanf.c | 25 ++-- src/stdio/vfwprintf.c | 45 +++--- src/stdio/vfwscanf.c | 19 ++- src/stdlib/strtol.c | 12 +- src/stdlib/wcstol.c | 12 +- 13 files changed, 611 insertions(+), 113 deletions(-) create mode 100644 src/internal/uwide128.c create mode 100644 src/internal/uwide128.h create mode 100644 src/internal/x86_64/uwide128_pop.s -- 2.34.1