Maple 18 has incorporated the LLVM compiler infrastructure to provide an out-of-the-box solution for the native code compilation feature of the Compiler:-Compile command. The addition of LLVM offers many advantages over previous releases.
LLVM is built directly into the Maple kernel rather than existing as a separate process that is called from Maple to perform the compilation task. This tight integration of the compiler provides the primary advantage over previous releases. Specifically, this streamlines calls to Compile since the overhead of creating a secondary process is eliminated. When compiling a procedure the resulting machine code is generated directly into main memory where it can be executed. In prior releases, Maple created a dynamically linked library which was then loaded prior to execution. The integration of LLVM reduces the number of costly disk accesses.
Furthermore, LLVM was designed to be used in this situation and is therefore capable of producing efficient machine code in a quicker, more lightweight manner.
The following figure displays the improvements in both compile and run time of Maple 18 in comparison to Maple 17 (64-bit Windows).