rusticl: add cl_khr_create_command_queue

Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23055>
This commit is contained in:
norablackcat 2023-06-08 04:16:50 -06:00 committed by Marge Bot
parent c41faeb323
commit be673fdd78
2 changed files with 10 additions and 1 deletions

View file

@ -1268,10 +1268,18 @@ extern "C" fn cl_get_extension_function_address(
return ptr::null_mut();
}
match unsafe { CStr::from_ptr(function_name) }.to_str().unwrap() {
"clCreateProgramWithILKHR" => cl_create_program_with_il as *mut ::std::ffi::c_void,
// cl_khr_create_command_queue
"clCreateCommandQueueWithPropertiesKHR" => {
cl_create_command_queue_with_properties as *mut ::std::ffi::c_void
}
// cl_khr_icd
"clGetPlatformInfo" => cl_get_platform_info as *mut ::std::ffi::c_void,
"clIcdGetPlatformIDsKHR" => cl_icd_get_platform_ids_khr as *mut ::std::ffi::c_void,
// cl_khr_il_program
"clCreateProgramWithILKHR" => cl_create_program_with_il as *mut ::std::ffi::c_void,
// cl_arm_shared_virtual_memory
"clEnqueueSVMFreeARM" => cl_enqueue_svm_free_arm as *mut ::std::ffi::c_void,
"clEnqueueSVMMapARM" => cl_enqueue_svm_map_arm as *mut ::std::ffi::c_void,

View file

@ -43,6 +43,7 @@ macro_rules! gen_cl_exts {
}
gen_cl_exts!([
(1, 0, 0, "cl_khr_byte_addressable_store"),
(1, 0, 0, "cl_khr_create_command_queue"),
(1, 0, 0, "cl_khr_icd"),
(1, 0, 0, "cl_khr_il_program"),
]);