[OpenCL] Add device enqueue guards for DSE builtins

Align guards of these builtins with opencl-c.h.
This commit is contained in:
Sven van Haastregt 2022-04-11 11:27:51 +01:00
parent 058a33d3c9
commit bb6f8d9a93
2 changed files with 3 additions and 1 deletions

View file

@ -104,6 +104,7 @@ def FuncExtKhrMipmapImageWrites : FunctionExtension<"cl_khr_mipmap_imag
def FuncExtKhrGlMsaaSharing : FunctionExtension<"cl_khr_gl_msaa_sharing">;
def FuncExtKhrGlMsaaSharingReadWrite : FunctionExtension<"cl_khr_gl_msaa_sharing __opencl_c_read_write_images">;
def FuncExtOpenCLCDeviceEnqueue : FunctionExtension<"__opencl_c_device_enqueue">;
def FuncExtOpenCLCGenericAddressSpace : FunctionExtension<"__opencl_c_generic_address_space">;
def FuncExtOpenCLCNamedAddressSpaceBuiltins : FunctionExtension<"__opencl_c_named_address_space_builtins">;
def FuncExtOpenCLCPipes : FunctionExtension<"__opencl_c_pipes">;
@ -1454,7 +1455,7 @@ let Extension = FuncExtOpenCLCPipes in {
// Defined in Builtins.def
// --- Table 33 ---
let MinVersion = CL20 in {
let Extension = FuncExtOpenCLCDeviceEnqueue in {
def : Builtin<"enqueue_marker",
[Int, Queue, UInt, PointerType<ConstType<ClkEvent>, GenericAS>, PointerType<ClkEvent, GenericAS>]>;

View file

@ -73,6 +73,7 @@ typedef struct {int a;} ndrange_t;
// Enable extensions that are enabled in opencl-c-base.h.
#if (defined(__OPENCL_CPP_VERSION__) || __OPENCL_C_VERSION__ >= 200)
#define __opencl_c_device_enqueue 1
#define __opencl_c_generic_address_space 1
#define cl_khr_subgroup_extended_types 1
#define cl_khr_subgroup_ballot 1