diff options
author | Zoltan Varga <vargaz@gmail.com> | 2015-10-09 21:23:03 +0300 |
---|---|---|
committer | Zoltan Varga <vargaz@gmail.com> | 2015-10-09 21:23:03 +0300 |
commit | 0421c0cff36b33a58c16930d61227b74633c1e99 (patch) | |
tree | c170d0a809df8fc046edd6cc21db34a75144a7d2 | |
parent | d0843960aadcd825c9e63815aac5bd1cefd80cc5 (diff) |
Fix the loaded llvm build.
-rw-r--r-- | mono/mini/mini-exceptions.c | 6 | ||||
-rw-r--r-- | mono/mini/mini-llvm-loaded.c | 6 | ||||
-rw-r--r-- | mono/mini/mini-runtime.c | 2 |
3 files changed, 8 insertions, 6 deletions
diff --git a/mono/mini/mini-exceptions.c b/mono/mini/mini-exceptions.c index 99ed80ee214..5019fe169ce 100644 --- a/mono/mini/mini-exceptions.c +++ b/mono/mini/mini-exceptions.c @@ -125,12 +125,14 @@ mono_exceptions_init (void) cbs.mono_walk_stack_with_ctx = mono_runtime_walk_stack_with_ctx; cbs.mono_walk_stack_with_state = mono_walk_stack_with_state; -#ifdef ENABLE_LLVM +#if defined(ENABLE_LLVM) && !defined(MONO_LLVM_LOADED) if (mono_llvm_only) cbs.mono_raise_exception = mono_llvm_raise_exception; else -#endif cbs.mono_raise_exception = mono_get_throw_exception (); +#else + cbs.mono_raise_exception = mono_get_throw_exception (); +#endif cbs.mono_raise_exception_with_ctx = mono_raise_exception_with_ctx; cbs.mono_exception_walk_trace = mono_exception_walk_trace; cbs.mono_install_handler_block_guard = mono_install_handler_block_guard; diff --git a/mono/mini/mini-llvm-loaded.c b/mono/mini/mini-llvm-loaded.c index c93a8372812..40b44036e4b 100644 --- a/mono/mini/mini-llvm-loaded.c +++ b/mono/mini/mini-llvm-loaded.c @@ -14,7 +14,7 @@ typedef void (*MonoLLVMVoidFunc)(void); typedef void (*MonoLLVMCFGFunc)(MonoCompile *cfg); typedef void (*MonoLLVMEmitCallFunc)(MonoCompile *cfg, MonoCallInst *call); -typedef void (*MonoLLVMCreateAotFunc)(MonoAssembly *assembly, const char *global_prefix, gboolean emit_dwarf, gboolean static_link); +typedef void (*MonoLLVMCreateAotFunc)(MonoAssembly *assembly, const char *global_prefix, gboolean emit_dwarf, gboolean static_link, gboolean llvm_only); typedef void (*MonoLLVMEmitAotFunc)(const char *filename, const char *cu_name); typedef void (*MonoLLVMEmitAotInfoFunc)(MonoAotFileInfo *info, gboolean has_jitted_code); typedef void (*MonoLLVMEmitAotDataFunc)(const char *symbol, guint8 *data, int data_len); @@ -56,10 +56,10 @@ mono_llvm_emit_call (MonoCompile *cfg, MonoCallInst *call) } void -mono_llvm_create_aot_module (MonoAssembly *assembly, const char *global_prefix, gboolean emit_dwarf, gboolean static_link) +mono_llvm_create_aot_module (MonoAssembly *assembly, const char *global_prefix, gboolean emit_dwarf, gboolean static_link, gboolean llvm_only) { g_assert (mono_llvm_create_aot_module_fptr); - mono_llvm_create_aot_module_fptr (assembly, global_prefix, emit_dwarf, static_link); + mono_llvm_create_aot_module_fptr (assembly, global_prefix, emit_dwarf, static_link, llvm_only); } void diff --git a/mono/mini/mini-runtime.c b/mono/mini/mini-runtime.c index e2c3e438b03..5da93436e4c 100644 --- a/mono/mini/mini-runtime.c +++ b/mono/mini/mini-runtime.c @@ -3261,7 +3261,7 @@ register_icalls (void) register_icall (mono_domain_get, "mono_domain_get", "ptr", TRUE); #ifdef MONO_ARCH_LLVM_SUPPORTED -#ifdef ENABLE_LLVM +#if defined(ENABLE_LLVM) && !defined(MONO_LLVM_LOADED) register_icall (mono_llvm_throw_exception, "mono_llvm_throw_exception", "void object", TRUE); register_icall (mono_llvm_rethrow_exception, "mono_llvm_rethrow_exception", "void object", TRUE); register_icall (mono_llvm_resume_exception, "mono_llvm_resume_exception", "void", TRUE); |