I am new to RISC-V and compared to other ISA’s from what I have seen there are not as widespread of forums and online discussions. I recently learned how to add a new custom instruction into the RISC-V ISA but I wanted to know how could I modify already existing ones? For example if I have the sub instruction if I did:
a1 = 5
a0 = 10
sub a0, a0, a1
Instead of returning 5, I want to change sub to instead add and return 15 (yes I am aware of the add instruction, I want to know how to modify the instruction of sub)
I have tried following along this guide:
How to add a new custom instruction in the RISCV instruction set
but this is for creating a new instruction not creating a custom one.
altfake34 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.