LLVM: Customize your Instructions.
For the past few weeks, I was given a task by my supervisor. The task sound simple, whenever there NOP (No operation) instruction will be use, LLVM should change it into XOR R0, R0, R0 which basically doing nothing since in aeMB, register zero (R0) always have zero values. NOP –change to–> XOR R0, R0, R0 So I start digging. First I look into *InstrInfo.td because thats where all target specific instructions were define. And the tablegen will automatically generate Read more