Hi, all
I am trying to write a high performance library by using inline assembler but I have encountered a irritating problem. It seems that VC++ refuses to accept multi-instructions within the inline asm section for the macro. For example, I can write a inline assembler macro with the single instruction “mov eax, 0” but that’s it, VC++ refuses to accept anymore instructions. The following code might give a better understanding:
So what I am trying to do here is to add more then one instruction into the macro, but I don’t know how. Any ideas on how to solve this are highly appreciated.Code:#define TestMacro1(x) _asm{ mov eax, 0 } // This works #define TestMacro2(x) _asm{ mov eax, 0; mov ebx, 0 } // This doesn’t
Thanks in advance.