From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-sender-0.a4lg.com (mail-sender.a4lg.com [153.120.152.154]) by sourceware.org (Postfix) with ESMTPS id D6A163857C4D for ; Thu, 22 Sep 2022 07:59:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D6A163857C4D Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=irq.a4lg.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=irq.a4lg.com Received: from [127.0.0.1] (localhost [127.0.0.1]) by mail-sender-0.a4lg.com (Postfix) with ESMTPSA id 8EA34300089; Thu, 22 Sep 2022 07:58:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=irq.a4lg.com; s=2017s01; t=1663833538; bh=+KLqjvsYUjOy2vCX5sENQWd/dP0NbxTG701HNOUmOJE=; h=From:To:Cc:Subject:Date:Message-Id:Mime-Version: Content-Transfer-Encoding; b=Ik2h0LmARljcY2wNfzNvU4WpF9eorKyaEfLS3Prr1EciqSsijvQ0PXP5IZH+vplxJ GAHR4qaj1D88D2wc5/FtnOHuFlFEOzcnSJpOBggBRjKU7CzU3yWlPHIgSt/ZAWEr4M dmcrzt0cBm4m7NKWFx4Lp04DghuOsxPliWujkItg= From: Tsukasa OI To: Tsukasa OI , Nelson Chu , Kito Cheng , Palmer Dabbelt , Andrew Waterman Cc: binutils@sourceware.org Subject: [RFC PATCH 0/1] RISC-V: Add privileged extensions without instructions/CSRs Date: Thu, 22 Sep 2022 07:58:55 +0000 Message-Id: Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hello, Tracker on GitHub: Currently, GNU Binutils does not support following privileged extensions: - 'Smepmp' - 'Svnapot' - 'Svpbmt' as they do not provide new CSRs or new instructions ('Smepmp' extends the privileged architecture CSRs but does not define the CSR itself). However, I started considering adding them to GNU Binutils' supported extension list. One of the reason is simple: if we do that, we no longer have to "filter" ISA strings just for toolchains (if full ISA string is given by a vendor, we can straightly use it). And there's a fact that support this theory: there's already an (unprivileged) extension which does not provide CSRs or instructions (not even pseudoinstructions; but only an architectural guarantee): 'Zkt' (constant timing guarantee for certain subset of RISC-V instructions). This simple patchset simply adds three privileged extensions I described above and I want to hear your thoughts. If this is acceptable for GNU Binutils, doing the same (or accepting all privileged extensions) to GCC might be an option. It might not benefit regular C/C++ programs but it absolutely helps compiling .S (assembler file but must pass C preprocessor first). Thanks, Tsukasa Tsukasa OI (1): RISC-V: Add privileged extensions without instructions/CSRs bfd/elfxx-riscv.c | 3 +++ 1 file changed, 3 insertions(+) base-commit: 0383bce6502271455804daa533c9d141e7c3fc98 -- 2.34.1