On 6 January 2017 at 17:35, Wu Zhen <wuz...@jidemail.com> wrote: > From: WuZhen <wuz...@jidemail.com> > > since (cf410574 gallivm: Make MCJIT a runtime optioni.), llvmpipe assume > MCJIT is available on x86(_64). this is not the case for android prior to M. > Wu Zhen, what exactly is the issue you're getting - build or link-time error ?
Looking at the hunk [1] in the offending commit makes me wonder. - Why do we call LLVMLinkInJIT() even if one selects MCJIT via the env var. - Why do we always call LLVMLinkInMCJIT regardless of a) if we've build against old LLVM and b) the env var. Jose, shouldn't we honour the above ? One way that comes to mind is to have USE_MCJIT always as static variable. Then we can guard the debug_get_bool_option() override with the current LLVM_VERSION/ARCH heuristics while preserving original invocation. if (USE_MCJIT) // use lowercase name since it's not a macro ? LLVMLinkInMCJIT(); else LLVMLinkInJIT(); Thanks Emil [1] @@ -385,18 +382,18 @@ lp_build_init(void) if (gallivm_initialized) return TRUE; + LLVMLinkInMCJIT(); +#if !defined(USE_MCJIT) + USE_MCJIT = debug_get_bool_option("GALLIVM_MCJIT", 0); + LLVMLinkInJIT(); +#endif + #ifdef DEBUG gallivm_debug = debug_get_option_gallivm_debug(); #endif lp_set_target_options(); -#if USE_MCJIT - LLVMLinkInMCJIT(); -#else - LLVMLinkInJIT(); -#endif - _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev