Module Opencl_api.Device

type t = {
  1. id : int;
  2. handle : Opencl_types.cl_device_id;
  3. platform : Platform.t;
  4. name : string;
  5. vendor : string;
  6. max_compute_units : int;
  7. max_work_group_size : int;
  8. max_work_item_dims : int;
  9. max_work_item_sizes : int array;
  10. global_mem_size : int64;
  11. local_mem_size : int64;
  12. max_clock_freq : int;
  13. supports_fp64 : bool;
  14. version : int * int;
  15. supports_subgroup_shuffle : bool;
  16. supports_int64 : bool;
  17. is_cpu : bool;
  18. mem_base_addr_align : int;
  19. max_mem_alloc_size : int64;
  20. single_fp_config : int64;
}
val get_info_string : Opencl_types.cl_device_id -> Opencl_types.cl_device_info -> string
val make_device : Platform.t -> int -> Opencl_types.cl_device_id -> t
val subgroup_build_options : t -> string

Build options a SUB-GROUP kernel needs on d. The sub-group built-ins are invisible at the default language level (OpenCL C 1.2) of an OpenCL 2.x/3.0 device, so the level is raised to what the device implements: OpenCL C 3.0 for a 3.0 device (where sub-groups are the optional core feature __opencl_c_subgroups), 2.0 for a 2.x device. Empty on a 1.x device, which has no sub-groups.

val init : unit -> unit
val count : unit -> int
val get : int -> t