From: Tsukasa OI <research_trasio@irq.a4lg.com>
To: Tsukasa OI <research_trasio@irq.a4lg.com>
Cc: binutils@sourceware.org
Subject: [RFC PATCH 2/5] RISC-V: Add insn classes for Zfh/Zfhmin extensions
Date: Tue, 11 Jan 2022 19:48:17 +0900 [thread overview]
Message-ID: <3a40c19310810288606061a733581b1b277aec0e.1641898063.git.research_trasio@irq.a4lg.com> (raw)
In-Reply-To: <cover.1641898063.git.research_trasio@irq.a4lg.com>
This commit adds several instruction classes corresponding 'Zfh',
'Zfhmin' and 'Zfhmin'+'D|Q' extensions.
bfd/ChangeLog:
* elfxx-riscv.c (riscv_multi_subset_supports): Add handling for
new instruction classes.
include/ChangeLog:
* opcode/riscv.h (enum riscv_insn_class): Add new instruction
classes INSN_CLASS_ZFH, INSN_CLASS_ZFHMIN,
INSN_CLASS_ZFHMIN_AND_D and INSN_CLASS_ZFHMIN_AND_Q.
---
bfd/elfxx-riscv.c | 10 ++++++++++
include/opcode/riscv.h | 4 ++++
2 files changed, 14 insertions(+)
diff --git a/bfd/elfxx-riscv.c b/bfd/elfxx-riscv.c
index dbe3611304b..4f3705ad396 100644
--- a/bfd/elfxx-riscv.c
+++ b/bfd/elfxx-riscv.c
@@ -2368,6 +2368,16 @@ riscv_multi_subset_supports (riscv_parse_subset_t *rps,
case INSN_CLASS_Q_OR_ZQINX:
return (riscv_subset_supports (rps, "q")
|| riscv_subset_supports (rps, "zqinx"));
+ case INSN_CLASS_ZFH:
+ return riscv_subset_supports (rps, "zfh");
+ case INSN_CLASS_ZFHMIN:
+ return riscv_subset_supports (rps, "zfhmin");
+ case INSN_CLASS_ZFHMIN_AND_D:
+ return (riscv_subset_supports (rps, "zfhmin")
+ && riscv_subset_supports (rps, "d"));
+ case INSN_CLASS_ZFHMIN_AND_Q:
+ return (riscv_subset_supports (rps, "zfhmin")
+ && riscv_subset_supports (rps, "q"));
case INSN_CLASS_ZBA:
return riscv_subset_supports (rps, "zba");
case INSN_CLASS_ZBB:
diff --git a/include/opcode/riscv.h b/include/opcode/riscv.h
index 048ab0a5d68..a5da8d0c4e0 100644
--- a/include/opcode/riscv.h
+++ b/include/opcode/riscv.h
@@ -370,6 +370,10 @@ enum riscv_insn_class
INSN_CLASS_F_OR_ZFINX,
INSN_CLASS_D_OR_ZDINX,
INSN_CLASS_Q_OR_ZQINX,
+ INSN_CLASS_ZFH,
+ INSN_CLASS_ZFHMIN,
+ INSN_CLASS_ZFHMIN_AND_D,
+ INSN_CLASS_ZFHMIN_AND_Q,
INSN_CLASS_ZBA,
INSN_CLASS_ZBB,
INSN_CLASS_ZBC,
--
2.32.0
next prev parent reply other threads:[~2022-01-11 10:48 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-11 10:47 [RFC PATCH 0/5] RISC-V: Add Half-precision floating point extensions Tsukasa OI
2022-01-11 10:48 ` [RFC PATCH 1/5] RISC-V: Add 'Zfh' and 'Zfhmin' extensions Tsukasa OI
2022-01-11 10:48 ` Tsukasa OI [this message]
2022-01-11 10:48 ` [RFC PATCH 3/5] RISC-V: Add 'Zfh' and 'Zfhmin' instructions Tsukasa OI
2022-01-11 10:48 ` [RFC PATCH 4/5] RISC-V: Add 'flh' and 'fsh' macro instructions Tsukasa OI
2022-01-11 10:48 ` [RFC PATCH 5/5] RISC-V: Add 'Zfh'/'Zfhmin' conflict message Tsukasa OI
2022-05-18 1:43 ` [RFC PATCH 0/5] RISC-V: Add Half-precision floating point extensions Kito Cheng
2022-05-18 9:31 ` Tsukasa OI
2022-05-22 5:15 ` [PATCH v2 0/4] RISC-V: Float16 extensions enhancements Tsukasa OI
2022-05-22 5:15 ` [PATCH v2 1/4] RISC-V: Refactor 'Zfh'-related macros Tsukasa OI
2022-05-22 5:15 ` [PATCH v2 2/4] RISC-V: Add instruction declaration for 'Zfh' Tsukasa OI
2022-05-22 5:15 ` [PATCH v2 3/4] RISC-V: Add 'Zfhmin' (and refactor 'Zfh') Tsukasa OI
2022-05-22 5:15 ` [PATCH v2 4/4] RISC-V: Add 'Zfh' / 'Zfhmin' conflict message Tsukasa OI
2022-05-22 9:11 ` [PATCH 0/1] RISC-V: Zfh extension diagnostic addition Tsukasa OI
2022-05-22 9:11 ` [PATCH 1/1] RISC-V: Add extension diagnostics to Zfh Tsukasa OI
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3a40c19310810288606061a733581b1b277aec0e.1641898063.git.research_trasio@irq.a4lg.com \
--to=research_trasio@irq.a4lg.com \
--cc=binutils@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).