[LLVMdev] a pseudo instruction

Seung Jae Lee lee225 at uiuc.edu
Fri Feb 2 08:45:52 PST 2007


I'd like to implement "reg" instruction on my new architecture. This is kinda pseudo instruction do not generate hardware directly but make hardware to be generated indirectly.

If I code a simple function like this:

void sum(int i, int j)
{
    int k;
    k = i + j;
}

On the assembly mnemonics, it should be shown as follows:

Enter sum;
reg k
add i,j;k
Exit sum;

I haven't seen any part dealing with this kind of instruction in the LLVM backend example codes.
Can you give me a tip about how to start with?
Thank you very much.

Seung Jae Lee



More information about the llvm-dev mailing list