backend for intrinsic functions


I have some newly defined intrinsic functions in my llvm IR code, which I want to translate to X86 instruction set. As a first step, I want to be able to generate "nop" for these instructions, so the program at least compiles successfully.

The call to my intrinsic function looks like this in the IR:
call void @llvm.X(i16 %43)

From what I understand it may be possible to pattern match this to the nop instructions in the backend. I did not find an example of intrinsic function translation in the X86 backend. Could you explain how this can be done, or point me to some places to look?


Hey Ali,