<div dir="ltr">It is failing at link time . Examples are what I have given above. There is an compiler option -mllvm --x86-asm-syntax=intel. Is there something similar for linker which I can provide via -plugin-opt ?</div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Mar 27, 2015 at 9:31 PM, Rafael Espíndola <span dir="ltr"><<a href="mailto:rafael.espindola@gmail.com" target="_blank">rafael.espindola@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">At which stage is this failing? Can you provide an example and commands?<br>
<br>
Looks like the information about the use of intel syntax is being<br>
dropped along the way.<br>
<div class="HOEnZb"><div class="h5"><br>
On 27 March 2015 at 11:40, Ashish Saxena <<a href="mailto:ashishcseitbhu@gmail.com">ashishcseitbhu@gmail.com</a>> wrote:<br>
> Ah , I thought that there is issue while parsing inline asm in function<br>
> bodies , here are some of instruction where it cribs . Can you make out<br>
> something of it ?<br>
><br>
> I am going to try out -no-integrated-as option . Not sure if it will help ?<br>
><br>
> LLVM ERROR: Error parsing inline asm<br>
><br>
> 1><inline asm>:1:17 : error 0: unexpected token in argument list<br>
><br>
> 1>        mov ebx, dword ptr 16(%esp)<br>
><br>
> 1>                       ^<br>
><br>
> 1><inline asm>:2:17 : error 0: unexpected token in argument list<br>
><br>
> 1>        mov edi, dword ptr 24(%esp)<br>
><br>
> 1>                       ^<br>
><br>
> 1><inline asm>:3:17 : error 0: unexpected token in argument list<br>
><br>
> 1>        mov esi, dword ptr 28(%esp)<br>
><br>
> 1>                       ^<br>
><br>
> 1><inline asm>:4:21 : error 0: invalid token in expression<br>
><br>
> 1>        movq mm1, [edi+ebx-$8]<br>
><br>
> 1>                           ^<br>
><br>
> 1><inline asm>:5:12 : error 0: invalid operand for instruction<br>
><br>
> 1>        pxor mm0, mm0<br>
><br>
><br>
> Thanks<br>
><br>
> Ashish<br>
><br>
><br>
> On Fri, Mar 27, 2015 at 8:21 PM, Rafael Espíndola<br>
> <<a href="mailto:rafael.espindola@gmail.com">rafael.espindola@gmail.com</a>> wrote:<br>
>><br>
>> If you are getting a parse error it is very likely a different bug. In<br>
>> that bug the issue is that we don't parse the function bodies to find<br>
>> if some inline in them defines (or uses) a given symbol.<br>
>><br>
>> On 26 March 2015 at 13:30, Ashish Saxena <<a href="mailto:ashishcseitbhu@gmail.com">ashishcseitbhu@gmail.com</a>> wrote:<br>
>> > Thanks for response Francois . Do you have any pointers on what can be<br>
>> > the<br>
>> > issue here or something I can try out. I saw similar active bug in llvm<br>
>> > database<br>
>> ><br>
>> > <a href="https://llvm.org/bugs/show_bug.cgi?id=5623" target="_blank">https://llvm.org/bugs/show_bug.cgi?id=5623</a><br>
>> ><br>
>> > Thanks<br>
>> > Ashish<br>
>> ><br>
>> > On Thu, Mar 26, 2015 at 10:52 PM, Francois Pichet <<a href="mailto:pichet2000@gmail.com">pichet2000@gmail.com</a>><br>
>> > wrote:<br>
>> >><br>
>> >><br>
>> >><br>
>> >> On Wed, Mar 25, 2015 at 4:47 PM, Ashish Saxena<br>
>> >> <<a href="mailto:ashishcseitbhu@gmail.com">ashishcseitbhu@gmail.com</a>><br>
>> >> wrote:<br>
>> >>><br>
>> >>> Hi ,<br>
>> >>>     I am trying to enable link time optimization for my projects. Few<br>
>> >>> of<br>
>> >>> them has inline assembly which works perfectly with clang/llvm but on<br>
>> >>> enabling LTO I get following error<br>
>> >>><br>
>> >>> LLVM ERROR: Error parsing inline asm<br>
>> >>><br>
>> >>> <inline asm>:103:2 : error 0: unknown use of instruction mnemonic<br>
>> >>> without<br>
>> >>> a size suffix<br>
>> >>> <inline asm>:104:16 : error 0: invalid operand for instruction<br>
>> >>> <inline asm>:106:17 : error 0: unexpected token in argument list<br>
>> >>><br>
>> >>> & so on<br>
>> >>><br>
>> >>> Is this a known issue ? Any workaround for this ?<br>
>> >><br>
>> >><br>
>> >><br>
>> >> My experience is that LTO doesn't break inline assembly.<br>
>> ><br>
>> ><br>
>> ><br>
>> > _______________________________________________<br>
>> > LLVM Developers mailing list<br>
>> > <a href="mailto:LLVMdev@cs.uiuc.edu">LLVMdev@cs.uiuc.edu</a>         <a href="http://llvm.cs.uiuc.edu" target="_blank">http://llvm.cs.uiuc.edu</a><br>
>> > <a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br>
>> ><br>
><br>
><br>
</div></div></blockquote></div><br></div>