GBE_EXPORT_SYMBOL gbe_kernel_get_compile_wg_size_cb *gbe_kernel_get_compile_wg_size = NULL;
GBE_EXPORT_SYMBOL gbe_kernel_get_image_size_cb *gbe_kernel_get_image_size = NULL;
GBE_EXPORT_SYMBOL gbe_kernel_get_image_data_cb *gbe_kernel_get_image_data = NULL;
-GBE_EXPORT_SYMBOL gbe_set_image_base_index_cb *gbe_set_image_base_index_compiler = NULL;
-GBE_EXPORT_SYMBOL gbe_set_image_base_index_cb *gbe_set_image_base_index_interp = NULL;
+GBE_EXPORT_SYMBOL gbe_set_image_base_index_cb *gbe_set_image_base_index = NULL;
GBE_EXPORT_SYMBOL gbe_get_image_base_index_cb *gbe_get_image_base_index = NULL;
#ifdef GBE_COMPILER_AVAILABLE
gbe_kernel_get_image_size = gbe::kernelGetImageSize;
gbe_kernel_get_image_data = gbe::kernelGetImageData;
gbe_get_image_base_index = gbe::getImageBaseIndex;
- gbe_set_image_base_index_compiler = gbe::setImageBaseIndex;
+ gbe_set_image_base_index = gbe::setImageBaseIndex;
genSetupCallBacks();
llvm::llvm_start_multithreaded();
}
} ImageInfo;
typedef void (gbe_set_image_base_index_cb)(uint32_t base_idx);
-extern gbe_set_image_base_index_cb *gbe_set_image_base_index_compiler;
-extern gbe_set_image_base_index_cb *gbe_set_image_base_index_interp;
+extern gbe_set_image_base_index_cb *gbe_set_image_base_index;
typedef uint32_t (gbe_get_image_base_index_cb)();
extern gbe_get_image_base_index_cb *gbe_get_image_base_index;
used_index[optind-1] = 1;
// We must set the image base index here, as we invoke the backend in a non-standard way.
- gbe_set_image_base_index_compiler(3);
+ gbe_set_image_base_index(3);
break;
}
gbe_kernel_get_sampler_data = gbe::kernelGetSamplerData;
gbe_kernel_get_image_data = gbe::kernelGetImageData;
gbe_get_image_base_index = gbe::getImageBaseIndex;
- gbe_set_image_base_index_interp = gbe::setImageBaseIndex;
+ gbe_set_image_base_index = gbe::setImageBaseIndex;
}
~BinInterpCallBackInitializer() {
gbe_program_serialize_to_binary_cb *compiler_program_serialize_to_binary = NULL;
gbe_program_new_from_llvm_cb *compiler_program_new_from_llvm = NULL;
gbe_kernel_set_const_buffer_size_cb *compiler_kernel_set_const_buffer_size = NULL;
-gbe_set_image_base_index_cb *compiler_set_image_base_index_compiler = NULL;
+gbe_set_image_base_index_cb *compiler_set_image_base_index = NULL;
//function pointer from libgbeinterp.so
gbe_program_new_from_binary_cb *gbe_program_new_from_binary = NULL;
if (gbe_kernel_get_image_data == NULL)
return false;
- gbe_set_image_base_index_interp = *(gbe_set_image_base_index_cb**)dlsym(dlhInterp, "gbe_set_image_base_index_interp");
+ gbe_set_image_base_index_interp = *(gbe_set_image_base_index_cb**)dlsym(dlhInterp, "gbe_set_image_base_index");
if (gbe_set_image_base_index_interp == NULL)
return false;
if (compiler_kernel_set_const_buffer_size == NULL)
return;
- compiler_set_image_base_index_compiler = *(gbe_set_image_base_index_cb **)dlsym(dlhCompiler, "gbe_set_image_base_index_compiler");
- if (compiler_set_image_base_index_compiler == NULL)
+ compiler_set_image_base_index = *(gbe_set_image_base_index_cb **)dlsym(dlhCompiler, "gbe_set_image_base_index");
+ if (compiler_set_image_base_index == NULL)
return;
compilerLoaded = true;
extern gbe_program_serialize_to_binary_cb *compiler_program_serialize_to_binary;
extern gbe_program_new_from_llvm_cb *compiler_program_new_from_llvm;
extern gbe_kernel_set_const_buffer_size_cb *compiler_kernel_set_const_buffer_size;
-extern gbe_set_image_base_index_cb *compiler_set_image_base_index_compiler;
+extern gbe_set_image_base_index_cb *compiler_set_image_base_index;
+extern gbe_set_image_base_index_cb *gbe_set_image_base_index_interp;
int CompilerSupported();
#ifdef __cplusplus
}
* Notify the gbe this base index, thus gbe can avoid conflicts
* when it allocates slots for images*/
if (CompilerSupported())
- compiler_set_image_base_index_compiler(3);
+ compiler_set_image_base_index(3);
gbe_set_image_base_index_interp(3);
exit:
return driver;