Hi,
I am very new to the elf-toolchain process , however I have build one following the instructions in riscv-gnu-tool-chain github. Now I want to add custom instruction and I am planning to go by the examples of mod instruction which is easily accessible in internet to get familiar with the whole flow. Can you please suggest that after adding the custom instruction in the riscv-opc.c and riscv-opc.h file do I need to follow the whole build process again? I mean the step below:
./configure --prefix=/opt/riscv
make
The tool-chain has already been built but as per my very little understanding tool-chain again needs to be built to make the toolc-hain recognize the new instruction so when I disassemble it shows me the new instruction. Please correct me if I am wrong. Also please tell me the correct process.
My second doubt is that there are 2 riscv-opc.c and riscv-opc.h files in 2 different folders in the tool-chain. Do we need to modify the files in both the folder to make the custom instructions work. Please suggest.