mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 07:08:04 +02:00
gallivm: export target init code for orc-jit to reuse
It doesn't need the wrapper since it already has a singleton Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29869>
This commit is contained in:
parent
1f4268b53e
commit
76e2ceb8f8
2 changed files with 4 additions and 2 deletions
|
|
@ -108,7 +108,7 @@ static LLVMEnsureMultithreaded lLVMEnsureMultithreaded;
|
||||||
|
|
||||||
static once_flag init_native_targets_once_flag = ONCE_FLAG_INIT;
|
static once_flag init_native_targets_once_flag = ONCE_FLAG_INIT;
|
||||||
|
|
||||||
static void init_native_targets()
|
void lp_bld_init_native_targets()
|
||||||
{
|
{
|
||||||
// If we have a native target, initialize it to ensure it is linked in and
|
// If we have a native target, initialize it to ensure it is linked in and
|
||||||
// usable by the JIT.
|
// usable by the JIT.
|
||||||
|
|
@ -150,7 +150,7 @@ lp_set_target_options(void)
|
||||||
* LLVM targets should be initialized before the driver or gallium frontend tries
|
* LLVM targets should be initialized before the driver or gallium frontend tries
|
||||||
* to access the registry.
|
* to access the registry.
|
||||||
*/
|
*/
|
||||||
call_once(&init_native_targets_once_flag, init_native_targets);
|
call_once(&init_native_targets_once_flag, lp_bld_init_native_targets);
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C"
|
extern "C"
|
||||||
|
|
|
||||||
|
|
@ -64,6 +64,8 @@ gallivm_dispose_target_library_info(LLVMTargetLibraryInfoRef library_info);
|
||||||
extern void
|
extern void
|
||||||
lp_set_target_options(void);
|
lp_set_target_options(void);
|
||||||
|
|
||||||
|
extern void
|
||||||
|
lp_bld_init_native_targets();
|
||||||
|
|
||||||
extern int
|
extern int
|
||||||
lp_build_create_jit_compiler_for_module(LLVMExecutionEngineRef *OutJIT,
|
lp_build_create_jit_compiler_for_module(LLVMExecutionEngineRef *OutJIT,
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue