[LLVMdev] addPassesToEmitFile and Intel syntax

Reid Kleckner rnk at google.com
Mon Jul 27 09:32:11 PDT 2015


llc does support -x86-asm-syntax=intel, and Clang maps that to -masm=intel.
I don't think there is an API for it other than the command line. The
output will still use GAS style directives, so it won't assemble with masm.

It may not have as high fidelity as the AT&T asm printer, since we've never
relied on it as much. Before MC, feeding AT&T style assembly to GAS was the
only way to produce object files, so it had to be reliable in a way that
was never required of the Intel syntax.

On Mon, Jul 27, 2015 at 8:50 AM, Frank Winter <fwinter at jlab.org> wrote:

> Hi,
>
> I am using TargetMachine::addPassesToEmitFile to write out x86-64
> assembly. However, the generated assembly uses the AT&T syntax. Is there a
> way to switch to the Intel syntax?
>
> Thanks,
> Frank
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150727/0446bc38/attachment.html>


More information about the llvm-dev mailing list