Thanks Chung-Ju. That's what I needed. Regards Abdul On Fri, Aug 2, 2013 at 4:48 PM, Chung-Ju Wu <jasonwucj@xxxxxxxxx> wrote: > 2013/8/2 Abdul Wahid Memon <engrwahidmemon@xxxxxxxxx>: >> Considering the following rtx >> >> (insn 123 122 125 3 (set (reg:DI 531 [ pretmp.143 ]) >> (sign_extend:DI (reg/v:SI 594 [ stride ]))) sum.c:19 126 >> {*extendsidi2_rex64} >> (nil)) >> >> Is there any function available in RTL API which could extract the >> instruction name i.e. extendsidi2_rex64? >> > > AFAIK the API you require is get_insn_name() in insn-output.c, > which is generated automatically by the program 'genoutput' from > your machine description design during the building process. > > You can refer to print_rtx() function in gcc/print-rtl.c for more > implementation detail. > > > Best regards, > jasonwucj