Hi,<br> I am using llvm to convert some C++ code to C. However the C++ code has couple of lines of assembly that is supposed to be inlined.  I am using __asm__ directive. <br>However the resulting C code  has syntax errors:<br>
<br>main.c: In function ‘_Z23atomic_exchange_and_addPii’:<br>main.c:397: error: expected ‘:’ or ‘)’ before string constant<br>main.c: In function ‘_Z16atomic_incrementPi’:<br>main.c:421: error: expected ‘:’ or ‘)’ before string constant<br>
<br>For reference here is the line in the code that is causing the above errors:<br><br>__asm__ volatile ("lock\n\txadd %1, %0"<br>        :"=m"(llvm_cbe_asmtmp)"=r"(llvm_cbe_tmp__5)<br>        :"m"(*(llvm_cbe_tmp__6))"1"(llvm_cbe_tmp__6)"cc""memory");<br>
<br><br>I am new to the llvm so if this is not the right forum do let me know. <br><br>Thanks.<br>Sandeep<br><br>