Import Upstream version 20180207
[hcoop/debian/mlton.git] / doc / guide / src / LLVMCodegen.adoc
CommitLineData
7f918cf1
CE
1LLVMCodegen
2===========
3
4The <:LLVMCodegen:> is a <:Codegen:code generator> that translates the
5<:Machine:> <:IntermediateLanguage:> to <:LLVM:> assembly, which is
6further optimized and compiled to native object code by the <:LLVM:>
7toolchain.
8
9It requires <:LLVM:> version 3.7 or greater to be installed.
10
11In benchmarks performed on the <:RunningOnAMD64:AMD64> architecture,
12code size with this generator is usually slightly smaller than either
13the <:AMD64Codegen:native> or the <:CCodegen:C> code generators. Compile
14time is worse than <:AMD64Codegen:native>, but slightly better than
15<:CCodegen:C>. Run time is often better than either <:AMD64Codegen:native>
16or <:CCodegen:C>.
17
18== Implementation ==
19
20* <!ViewGitFile(mlton,master,mlton/codegen/llvm-codegen/llvm-codegen.sig)>
21* <!ViewGitFile(mlton,master,mlton/codegen/llvm-codegen/llvm-codegen.fun)>
22
23== Details and Notes ==
24
25The <:LLVMCodegen:> was initially developed by Brian Leibig (see
26<!Cite(Leibig13,An LLVM Back-end for MLton)>).