Fix the LLVMCreateJITCompiler C binding.
[oota-llvm.git] / bindings / ocaml / executionengine / executionengine_ocaml.c
index 4af771123c0c096229f7045bd3441928c421871e..fc3848a1eb1428dc2bbe70483fcc1be78d74a81e 100644 (file)
@@ -181,7 +181,17 @@ CAMLprim LLVMExecutionEngineRef
 llvm_ee_create_jit(LLVMModuleProviderRef MP) {
   LLVMExecutionEngineRef JIT;
   char *Error;
-  if (LLVMCreateJITCompiler(&JIT, MP, &Error))
+  if (LLVMCreateJITCompiler(&JIT, MP, 0, &Error))
+    llvm_raise(llvm_ee_error_exn, Error);
+  return JIT;
+}
+
+/* llmoduleprovider -> ExecutionEngine.t */
+CAMLprim LLVMExecutionEngineRef
+llvm_ee_create_fast_jit(LLVMModuleProviderRef MP) {
+  LLVMExecutionEngineRef JIT;
+  char *Error;
+  if (LLVMCreateJITCompiler(&JIT, MP, 1, &Error))
     llvm_raise(llvm_ee_error_exn, Error);
   return JIT;
 }