<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"><base href="x-msg://4285/"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Amit,<div><br></div><div>You're not doing anything wrong. This is an error in 'lli' not properly initializing the native target libraries. Fixed in SVN trunk r167392.</div><div><br></div><div>-Jim</div><div><br><div><div>On Nov 4, 2012, at 4:09 PM, Amit Arya <<a href="mailto:aarya@cs.stonybrook.edu">aarya@cs.stonybrook.edu</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div bgcolor="#FFFFFF" fpstyle="1" ocsi="0" style="font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="direction: ltr; font-family: Tahoma; font-size: 10pt; ">Hi,<div><br></div><div>I am first year PhD student at Stony Brook University. For one of my projects I am trying to JIT compile and run a C program containing inline assembly using MCJIT but I am not able to.</div><div><br></div><div>I have cloned and build LLVM-3.1. Below are more details.</div><div><br></div><div>Arch : x86 </div><div>OS :  Linux ubuntu 2.6.35-22-generic</div><div><br></div><div>Sample program : test_inline_asm.c</div><div>-------------------</div><div><div>#include <stdio.h></div><div>int main(){</div><div>    int a=0;</div><div>    __asm __volatile("movl $5,%%eax\t"</div><div>    "\n movl %%eax,%0":"=r"(a)::"cc","memory"</div><div>    );</div><div>    printf("a= %d\n",a);</div><div>}</div></div><div><br></div><div>Commands </div><div>-------------</div><div><b>clang -emit-llvm -S test_inline_asm.c</b></div><div><b>lli -use-mcjit test_inline_asm.s</b></div><div><br></div><div>throws,</div><div><br></div><div><div><b>LLVM ERROR: Inline asm not supported by this streamer because we don't have an asm parser for this target</b></div><div><br></div></div><div>Any pointers to what mistake I have been doing.Any help would be much appreciated.</div><div><br></div><div>Thanks & Regards,</div><div>Amit Arya</div></div><span id="skype_highlighting_settings" display="none" autoextractnumbers="1"></span>_______________________________________________<br>LLVM Developers mailing list<br><a href="mailto:LLVMdev@cs.uiuc.edu">LLVMdev@cs.uiuc.edu</a><span class="Apple-converted-space"> </span>        <a href="http://llvm.cs.uiuc.edu">http://llvm.cs.uiuc.edu</a><br><a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br></div></blockquote></div><br></div></body></html>