0

Instruction recommender tool Graph

I am trying to create a custom instruction and add it to the riscv-gnu-toolchain and spike. The above link will show the graph that I have generated using rvnewop which is basically an instruction recommender tool. So what the tool does is that it runs through my dump file and then recommends what can be done to basically optimize the code by suggesting instructions in a graphical format.

Is there any way I can model this graph which basically shows the instruction flow into a c code which then can be added to the toolchain and spike?

James Z
  • 12,209
  • 10
  • 24
  • 44
  • The font of your graph is terrible to read, because the letters 'i' and 'l' cannot be distinguished. Could you make it larger? – fsasm Aug 14 '21 at 12:37
  • The bitmanip extension already has an instruction called `sh2add` that combines the addition and shift left by 2. I would recommend to look into the existing extensions first before automatically creating new instructions. Note that the new instructions that are developed in the extensions are carefully selected in a time-consuming process, so there is much thought behind each new instruction. Also you could lookup how the `sh2add` instruction was implemented in spike and the gnu toolchain. – fsasm Aug 14 '21 at 12:53

0 Answers0