[RFC] RISC-V: Support Zibi extension.
Jeffrey Law
jeffrey.law@oss.qualcomm.com
Sun Mar 15 21:04:34 GMT 2026
On 3/13/2026 6:30 AM, Jiawei wrote:
> This patch supports Zibi extension(Branch with immediate) instructions.
>
> https://github.com/riscv/zibi
>
> bfd/ChangeLog:
>
> * elfxx-riscv.c (riscv_multi_subset_supports): New ext.
> (riscv_multi_subset_supports_ext): Ditto.
>
> gas/ChangeLog:
>
> * NEWS: Support Zibi extension.
> * testsuite/gas/riscv/march-help.l: New ext.
> * testsuite/gas/riscv/zibi.d: New test.
> * testsuite/gas/riscv/zibi.s: New test.
>
> include/ChangeLog:
>
> * opcode/riscv-opc.h (MATCH_BEQI): New match opcode.
> (MASK_BEQI): New mask opcode.
> (MATCH_BNEI): New match opcode.
> (MASK_BNEI): New mask opcode.
> (DECLARE_INSN): New insn declare.
> * opcode/riscv.h (enum riscv_insn_class): New ext.
>
> opcodes/ChangeLog:
>
> * riscv-opc.c: New instructions def.
THanks Jaiwei. What's the current state of this extension? Policy
to-date has been to not include things into the GNU tools until spec
hits the frozen state. It looks like this one is still at 0.1, which I
don't think is frozen.
Definitely looking forward to more expressive conditional branches
though :-) We generate some truly silly code because the ISA is so
limited in its conditional branch capabilities.
jeff
More information about the Binutils
mailing list