DPC++ Runtime
Runtime libraries for oneAPI DPC++
pi.h
Go to the documentation of this file.
1 //==---------- pi.h - Plugin Interface -------------------------------------==//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
10 // TODO: link to sphinx page
11 
21 
22 #ifndef _PI_H_
23 #define _PI_H_
24 
25 // Every single change in PI API should be accompanied with the minor
26 // version increase (+1). In the cases where backward compatibility is not
27 // maintained there should be a (+1) change to the major version in
28 // addition to the increase of the minor.
29 //
30 // PI version changes log:
31 // -- Version 1.2:
32 // 1. (Binary backward compatibility breaks) Two fields added to the
33 // pi_device_binary_struct structure:
34 // pi_device_binary_property_set PropertySetsBegin;
35 // pi_device_binary_property_set PropertySetsEnd;
36 // 2. A number of types needed to define pi_device_binary_property_set added.
37 // 3. Added new ownership argument to piextContextCreateWithNativeHandle.
38 // 4. Add interoperability interfaces for kernel.
39 // 4.6 Added new ownership argument to piextQueueCreateWithNativeHandle which
40 // changes the API version from 3.5 to 4.6.
41 // 5.7 Added new context and ownership arguments to
42 // piextEventCreateWithNativeHandle
43 // 6.8 Added new ownership argument to piextProgramCreateWithNativeHandle. Added
44 // piQueueFlush function.
45 // 7.9 Added new context and ownership arguments to
46 // piextMemCreateWithNativeHandle.
47 // 8.10 Added new optional device argument to piextQueueCreateWithNativeHandle
48 // 9.11 Use values of OpenCL enums directly, rather than including `<CL/cl.h>`;
49 // NOTE that this results in a changed API for `piProgramGetBuildInfo`.
50 // 10.12 Change enum value PI_MEM_ADVICE_UNKNOWN from 0 to 999, and set enum
51 // PI_MEM_ADVISE_RESET to 0.
52 // 10.13 Added new PI_EXT_ONEAPI_QUEUE_DISCARD_EVENTS queue property.
53 // 10.14 Add PI_EXT_INTEL_DEVICE_INFO_FREE_MEMORY as an extension for
54 // piDeviceGetInfo.
55 // 11.15 piEventCreate creates even in the signalled state now.
56 // 11.16 Add PI_EXT_INTEL_DEVICE_INFO_MEMORY_CLOCK_RATE and
57 // PI_EXT_INTEL_DEVICE_INFO_MEMORY_BUS_WIDTH as an extension for
58 // piDeviceGetInfo.
59 // 11.17 Added new PI_EXT_ONEAPI_QUEUE_PRIORITY_LOW and
60 // PI_EXT_ONEAPI_QUEUE_PRIORITY_HIGH queue properties.
61 // 11.18 Add new parameter name PI_EXT_ONEAPI_QUEUE_INFO_EMPTY to
62 // _pi_queue_info.
63 // 12.19 Add new PI_EXT_INTEL_DEVICE_PARTITION_BY_CSLICE piDevicePartition
64 // scheme. Sub-sub-devices (representing compute slice) creation via
65 // partitioning by affinity domain is disabled by default and can be temporarily
66 // restored via SYCL_PI_LEVEL_ZERO_EXPOSE_CSLICE_IN_AFFINITY_PARTITIONING
67 // environment variable.
68 // 12.20 Added piextQueueCreate API to be used instead of piQueueCreate, also
69 // added PI_EXT_INTEL_DEVICE_INFO_MAX_COMPUTE_QUEUE_INDICES for piDeviceGetInfo.
70 // Both are needed to support sycl_ext_intel_queue_index extension.
71 // 12.21 Added new piextUSMEnqueueFill2D, piextUSMEnqueueMemset2D, and
72 // piextUSMEnqueueMemcpy2D functions. Added new
73 // PI_EXT_ONEAPI_CONTEXT_INFO_USM_FILL2D_SUPPORT,
74 // PI_EXT_ONEAPI_CONTEXT_INFO_USM_MEMSET2D_SUPPORT, and
75 // PI_EXT_ONEAPI_CONTEXT_INFO_USM_MEMCPY2D_SUPPORT context info query
76 // descriptors.
77 // 12.22 Add piGetDeviceAndHostTimer to query device wall-clock timestamp
78 // 12.23 Added new piextEnqueueDeviceGlobalVariableWrite and
79 // piextEnqueueDeviceGlobalVariableRead functions.
80 // 12.24 Added new PI_EXT_KERNEL_EXEC_INFO_CACHE_CONFIG property to the
81 // _pi_kernel_exec_info. Defined _pi_kernel_cache_config enum with values of
82 // the new PI_EXT_KERNEL_EXEC_INFO_CACHE_CONFIG property.
83 // 12.25 Added PI_EXT_DEVICE_INFO_ATOMIC_FENCE_ORDER_CAPABILITIES and
84 // PI_EXT_DEVICE_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES for piDeviceGetInfo.
85 // 12.26 Added piextEnqueueReadHostPipe and piextEnqueueWriteHostPipe functions.
86 // 12.27 Added properties parameter to piextQueueCreateWithNativeHandle and
87 // changed native handle type of piextQueueCreateWithNativeHandle and
88 // piextQueueGetNativeHandle
89 // 12.28 Added piextMemImageCreateWithNativeHandle for creating images from
90 // native handles.
91 // 12.29 Support PI_EXT_PLATFORM_INFO_BACKEND query in piPlatformGetInfo
92 // 12.30 Added PI_EXT_INTEL_DEVICE_INFO_MEM_CHANNEL_SUPPORT device info query.
93 // 12.31 Added PI_EXT_CODEPLAY_DEVICE_INFO_MAX_REGISTERS_PER_WORK_GROUP device
94 // info query.
95 // 13.32 Removed backwards compatibility of piextQueueCreateWithNativeHandle and
96 // piextQueueGetNativeHandle
97 // 14.33 Added new parameter (memory object properties) to
98 // piextKernelSetArgMemObj
99 // 14.34 Added command-buffer extension methods
100 // 14.35 Added piextEnablePeerAccess, piextDisablePeerAccess,
101 // piextPeerAccessGetInfo, and pi_peer_attr enum.
102 // 14.36 Adding support for experimental bindless images. This includes:
103 // - Added device info queries
104 // - Device queries for bindless image support
105 // - PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_SUPPORT
106 // - PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_SHARED_USM_SUPPORT
107 // - PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_1D_USM_SUPPORT
108 // - PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_2D_USM_SUPPORT
109 // - Device queries for pitched USM allocations
110 // - PI_EXT_ONEAPI_DEVICE_INFO_IMAGE_PITCH_ALIGN
111 // - PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_WIDTH
112 // - PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_HEIGHT
113 // - PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_PITCH
114 // - Device queries for mipmap image support
115 // - PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_SUPPORT
116 // - PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_ANISOTROPY_SUPPORT
117 // - PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_MAX_ANISOTROPY
118 // - PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_LEVEL_REFERENCE_SUPPORT
119 // - Device queries for interop memory support
120 // - PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_MEMORY_IMPORT_SUPPORT
121 // - PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_MEMORY_EXPORT_SUPPORT
122 // - PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_SEMAPHORE_IMPORT_SUPPORT
123 // - PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_SEMAPHORE_EXPORT_SUPPORT
124 // - Added PI_IMAGE_INFO_DEPTH to _pi_image_info
125 // - Added _pi_image_copy_flags enum to determine direction of copy
126 // - Added new extension functions
127 // - piextBindlessImageSamplerCreate
128 // - piextUSMPitchedAlloc
129 // - piextMemUnsampledImageHandleDestroy
130 // - piextMemSampledImageHandleDestroy
131 // - piextMemImageAllocate
132 // - piextMemImageFree
133 // - piextMemUnsampledImageCreate
134 // - piextMemSampledImageCreate
135 // - piextMemImageCopy
136 // - piextMemImageGetInfo
137 // - piextMemMipmapGetLevel
138 // - piextMemMipmapFree
139 // - piextMemImportOpaqueFD
140 // - piextMemMapExternalArray
141 // - piextMemReleaseInterop
142 // - piextImportExternalSemaphoreOpaqueFD
143 // - piextDestroyExternalSemaphore
144 // - piextWaitExternalSemaphore
145 // - piextSignalExternalSemaphore
146 // 14.37 Added piextUSMImportExternalPointer and piextUSMReleaseImportedPointer.
147 // 14.38 Change PI_MEM_ADVICE_* values to flags for use in bitwise operations.
148 // 14.39 Added PI_EXT_INTEL_DEVICE_INFO_ESIMD_SUPPORT device info query.
149 
150 #define _PI_H_VERSION_MAJOR 14
151 #define _PI_H_VERSION_MINOR 39
152 
153 #define _PI_STRING_HELPER(a) #a
154 #define _PI_CONCAT(a, b) _PI_STRING_HELPER(a.b)
155 #define _PI_TRIPLE_CONCAT(a, b, c) _PI_STRING_HELPER(a.b.c)
156 
157 // This is the macro that plugins should all use to define their version.
158 // _PI_PLUGIN_VERSION_STRING will be printed when environment variable
159 // SYCL_PI_TRACE is set to 1. PluginVersion should be defined for each plugin
160 // in plugins/*/pi_*.hpp. PluginVersion should be incremented with each change
161 // to the plugin.
162 #define _PI_PLUGIN_VERSION_STRING(PluginVersion) \
163  _PI_TRIPLE_CONCAT(_PI_H_VERSION_MAJOR, _PI_H_VERSION_MINOR, PluginVersion)
164 
165 #define _PI_H_VERSION_STRING \
166  _PI_CONCAT(_PI_H_VERSION_MAJOR, _PI_H_VERSION_MINOR)
167 
168 // This will be used to check the major versions of plugins versus the major
169 // versions of PI.
170 #define _PI_STRING_SUBSTITUTE(X) _PI_STRING_HELPER(X)
171 #define _PI_PLUGIN_VERSION_CHECK(PI_API_VERSION, PI_PLUGIN_VERSION) \
172  if (strncmp(PI_API_VERSION, PI_PLUGIN_VERSION, \
173  sizeof(_PI_STRING_SUBSTITUTE(_PI_H_VERSION_MAJOR))) < 0) { \
174  return PI_ERROR_INVALID_OPERATION; \
175  }
176 
177 // NOTE: This file presents a maping of OpenCL to PI enums, constants and
178 // typedefs. The general approach taken was to replace `CL_` prefix with `PI_`.
179 // Please consider this when adding or modifying values, as the strict value
180 // match is required.
181 // TODO: We should consider re-implementing PI enums and constants and only
182 // perform a mapping of PI to OpenCL in the pi_opencl backend.
183 #include <sycl/detail/export.hpp>
184 
185 #include <cstddef>
186 #include <cstdint>
187 #include <variant>
188 
189 #ifdef __cplusplus
190 extern "C" {
191 #endif // __cplusplus
192 
193 using pi_int32 = int32_t;
194 using pi_uint32 = uint32_t;
195 using pi_uint64 = uint64_t;
198 using pi_native_handle = uintptr_t;
199 
200 //
201 // NOTE: prefer to map 1:1 to OpenCL so that no translation is needed
202 // for PI <-> OpenCL ways. The PI <-> to other BE translation is almost
203 // always needed anyway.
204 //
205 typedef enum {
206 #define _PI_ERRC(NAME, VAL) NAME = VAL,
207 #define _PI_ERRC_WITH_MSG(NAME, VAL, MSG) NAME = VAL,
208 #include <sycl/detail/pi_error.def>
209 #undef _PI_ERRC
210 #undef _PI_ERRC_WITH_MSG
211 } _pi_result;
212 
213 typedef enum {
219 
220 typedef enum {
226  PI_EXT_PLATFORM_INFO_BACKEND = 0x21000 // returns pi_platform_backend
228 
229 typedef enum {
235 
236 typedef enum {
242 
243 typedef enum {
249 
250 // NOTE: this is made 64-bit to match the size of cl_device_type to
251 // make the translation to OpenCL transparent.
252 //
253 typedef enum : pi_uint64 {
255  (1 << 0),
256  PI_DEVICE_TYPE_ALL = 0xFFFFFFFF,
257  PI_DEVICE_TYPE_CPU = (1 << 1),
258  PI_DEVICE_TYPE_GPU = (1 << 2),
259  PI_DEVICE_TYPE_ACC = (1 << 3),
260  PI_DEVICE_TYPE_CUSTOM = (1 << 4)
263 
264 typedef enum {
273 
274 typedef enum {
279 
280 typedef enum {
284 
285 typedef enum {
370  // Intel UUID extension.
372  // These are Intel-specific extensions.
383  // Return true if sub-device should do its own program build
386  // Return 0 if device doesn't have any memory modules. Return the minimum of
387  // the clock rate values if there are several memory modules on the device.
389  // Return 0 if device doesn't have any memory modules. Return the minimum of
390  // the bus width values if there are several memory modules on the device.
392  // Return 1 if the device doesn't have a notion of a "queue index". Otherwise,
393  // return the number of queue indices that are available for this device.
400  // Return whether bfloat16 math functions are supported by device
411  // The number of max registers per block (device specific)
414 
415  // Bindless images, mipmaps, interop
432 
435 
436 typedef enum {
447 
448 typedef enum {
454  // Atomics capabilities extensions
459  // Native 2D USM memory operation support
464 
465 typedef enum {
472  // Return 'true' if all commands previously submitted to the queue have
473  // completed, otherwise return 'false'.
476 
477 typedef enum {
485 
486 typedef enum {
493  // The number of registers used by the compiled kernel (device specific)
496 
497 typedef enum {
506 
507 typedef enum {
513 
514 typedef enum {
521 
522 typedef enum {
556 
557 typedef enum {
565 } _pi_mem_type;
566 
567 typedef enum {
568  // Device-specific value opaque in PI API.
580  PI_MEM_ADVICE_UNKNOWN = 0x7FFFFFFF,
582 
583 typedef enum {
600 
601 typedef enum {
618 
619 typedef enum {
624 
626 
627 const pi_bool PI_TRUE = 1;
628 const pi_bool PI_FALSE = 0;
629 
630 typedef enum {
640 
641 typedef enum {
648 
649 typedef enum {
653 
654 using pi_context_properties = intptr_t;
655 
658  (1 << 0);
661 
664  0x1152;
668 
675 
682 
683 typedef enum {
689 
690 // NOTE: this is made 64-bit to match the size of cl_mem_flags to
691 // make the translation to OpenCL transparent.
692 // TODO: populate
693 //
695 // Access
698 // Host pointer
702 
703 // flags passed to Map operations
705 constexpr pi_map_flags PI_MAP_READ = (1 << 0);
706 constexpr pi_map_flags PI_MAP_WRITE = (1 << 1);
708 // NOTE: this is made 64-bit to match the size of cl_mem_properties_intel to
709 // make the translation to OpenCL transparent.
713 
714 // NOTE: this is made 64-bit to match the size of cl_mem_properties_intel to
715 // make the translation to OpenCL transparent.
720  (1 << 1);
722 // Hints that the device/shared allocation will not be written on device.
724 
726 
727 // NOTE: queue properties are implemented this way to better support bit
728 // manipulations
732 // clang-format off
742 // clang-format on
743 
744 typedef enum {
745  // No preference for SLM or data cache.
747  // Large SLM size.
749  // Large General Data size.
752 
784 
786 
787 // For compatibility with OpenCL define this not as enum.
790  0x1086;
792  0x1087;
793 static constexpr pi_device_partition_property
795 static constexpr pi_device_partition_property
797 static constexpr pi_device_partition_property
799 
800 // For compatibility with OpenCL define this not as enum.
803  (1 << 0);
805  (1 << 1);
807  (1 << 2);
809  (1 << 3);
811  (1 << 4);
812 static constexpr pi_device_affinity_domain
814 
815 // For compatibility with OpenCL define this not as enum.
817 static constexpr pi_device_fp_config PI_FP_DENORM = (1 << 0);
818 static constexpr pi_device_fp_config PI_FP_INF_NAN = (1 << 1);
819 static constexpr pi_device_fp_config PI_FP_ROUND_TO_NEAREST = (1 << 2);
820 static constexpr pi_device_fp_config PI_FP_ROUND_TO_ZERO = (1 << 3);
821 static constexpr pi_device_fp_config PI_FP_ROUND_TO_INF = (1 << 4);
822 static constexpr pi_device_fp_config PI_FP_FMA = (1 << 5);
823 static constexpr pi_device_fp_config PI_FP_SOFT_FLOAT = (1 << 6);
825  (1 << 7);
826 
827 // For compatibility with OpenCL define this not as enum.
829 static constexpr pi_device_exec_capabilities PI_EXEC_KERNEL = (1 << 0);
831 
832 // Entry type, matches OpenMP for compatibility
834  void *addr;
835  char *name;
836  size_t size;
837  int32_t flags;
838  int32_t reserved;
839 };
840 
842 
843 // A type of a binary image property.
844 typedef enum {
846  PI_PROPERTY_TYPE_UINT32, // 32-bit integer
848  PI_PROPERTY_TYPE_STRING // null-terminated string
850 
851 // Device binary image property.
852 // If the type size of the property value is fixed and is no greater than
853 // 64 bits, then ValAddr is 0 and the value is stored in the ValSize field.
854 // Example - PI_PROPERTY_TYPE_UINT32, which is 32-bit
856  char *Name; // null-terminated property name
857  void *ValAddr; // address of property value
858  uint32_t Type; // _pi_property_type
859  uint64_t ValSize; // size of property value in bytes
860 };
861 
863 
864 // Named array of properties.
866  char *Name; // the name
869 };
870 
872 
874 using pi_device_binary_type = uint8_t;
875 // format is not determined
877 // specific to a device
879 // portable binary types go next
880 // SPIR-V
882 // LLVM bitcode
884 
885 // Device binary descriptor version supported by this library.
886 static const uint16_t PI_DEVICE_BINARY_VERSION = 1;
887 
888 // The kind of offload model the binary employs; must be 4 for SYCL
889 static const uint8_t PI_DEVICE_BINARY_OFFLOAD_KIND_SYCL = 4;
890 
898 #define __SYCL_PI_DEVICE_BINARY_TARGET_UNKNOWN "<unknown>"
899 #define __SYCL_PI_DEVICE_BINARY_TARGET_SPIRV32 "spir"
901 #define __SYCL_PI_DEVICE_BINARY_TARGET_SPIRV64 "spir64"
903 #define __SYCL_PI_DEVICE_BINARY_TARGET_SPIRV64_X86_64 "spir64_x86_64"
906 #define __SYCL_PI_DEVICE_BINARY_TARGET_SPIRV64_GEN "spir64_gen"
907 #define __SYCL_PI_DEVICE_BINARY_TARGET_SPIRV64_FPGA "spir64_fpga"
908 #define __SYCL_PI_DEVICE_BINARY_TARGET_NVPTX64 "nvptx64"
910 #define __SYCL_PI_DEVICE_BINARY_TARGET_AMDGCN "amdgcn"
911 #define __SYCL_PI_DEVICE_BINARY_TARGET_NATIVE_CPU "native_cpu"
912 
916 #define PI_DEVICE_INFO_EXTENSION_DEVICELIB_ASSERT \
917  "pi_ext_intel_devicelib_assert"
918 
923 #define __SYCL_PI_PROPERTY_SET_SPEC_CONST_MAP "SYCL/specialization constants"
924 #define __SYCL_PI_PROPERTY_SET_SPEC_CONST_DEFAULT_VALUES_MAP \
927  "SYCL/specialization constants default values"
928 #define __SYCL_PI_PROPERTY_SET_DEVICELIB_REQ_MASK "SYCL/devicelib req mask"
930 #define __SYCL_PI_PROPERTY_SET_KERNEL_PARAM_OPT_INFO "SYCL/kernel param opt"
932 #define __SYCL_PI_PROPERTY_SET_PROGRAM_METADATA "SYCL/program metadata"
934 #define __SYCL_PI_PROPERTY_SET_SYCL_MISC_PROP "SYCL/misc properties"
936 #define __SYCL_PI_PROPERTY_SET_SYCL_ASSERT_USED "SYCL/assert used"
938 #define __SYCL_PI_PROPERTY_SET_SYCL_EXPORTED_SYMBOLS "SYCL/exported symbols"
940 #define __SYCL_PI_PROPERTY_SET_SYCL_DEVICE_GLOBALS "SYCL/device globals"
942 #define __SYCL_PI_PROPERTY_SET_SYCL_DEVICE_REQUIREMENTS \
944  "SYCL/device requirements"
945 #define __SYCL_PI_PROPERTY_SET_SYCL_HOST_PIPES "SYCL/host pipes"
947 
950 #define __SYCL_PI_PROGRAM_METADATA_TAG_REQD_WORK_GROUP_SIZE \
951  "@reqd_work_group_size"
952 #define __SYCL_PI_PROGRAM_METADATA_GLOBAL_ID_MAPPING "@global_id_mapping"
953 
954 #define __SYCL_PI_PROGRAM_METADATA_TAG_NEED_FINALIZATION "Requires finalization"
955 
965  uint16_t Version;
967  uint8_t Kind;
969  uint8_t Format;
981  const char *DeviceTargetSpec;
984  const char *CompileOptions;
987  const char *LinkOptions;
989  const char *ManifestStart;
991  const char *ManifestEnd;
993  const unsigned char *BinaryStart;
995  const unsigned char *BinaryEnd;
999  // Array of preperty sets; e.g. specialization constants symbol-int ID map is
1000  // propagated to runtime with this mechanism.
1003  // TODO Other fields like entries, link options can be propagated using
1004  // the property set infrastructure. This will improve binary compatibility and
1005  // add flexibility.
1006 };
1008 
1009 // pi_buffer_region structure repeats cl_buffer_region, used for sub buffers.
1011  size_t origin;
1012  size_t size;
1013 };
1015 
1016 // pi_buff_rect_offset structure is 3D offset argument passed to buffer rect
1017 // operations (piEnqueueMemBufferCopyRect, etc).
1019  size_t x_bytes;
1020  size_t y_scalar;
1021  size_t z_scalar;
1022 };
1024 
1025 // pi_buff_rect_region structure represents size of 3D region passed to buffer
1026 // rect operations (piEnqueueMemBufferCopyRect, etc).
1028  size_t width_bytes;
1031 };
1033 
1034 // pi_image_offset structure is 3D offset argument passed to image operations
1035 // (piEnqueueMemImageRead, etc).
1037  size_t x;
1038  size_t y;
1039  size_t z;
1040 };
1042 
1043 // pi_image_region structure represents size of 3D region passed to image
1044 // operations (piEnqueueMemImageRead, etc).
1046  size_t width;
1047  size_t height;
1048  size_t depth;
1049 };
1051 
1052 // Offload binaries descriptor version supported by this library.
1053 static const uint16_t PI_DEVICE_BINARIES_VERSION = 1;
1054 
1062  uint16_t Version;
1070 };
1072 
1073 // Opaque types that make reading build log errors easier.
1074 struct _pi_platform;
1075 struct _pi_device;
1076 struct _pi_context;
1077 struct _pi_queue;
1078 struct _pi_mem;
1079 struct _pi_program;
1080 struct _pi_kernel;
1081 struct _pi_event;
1082 struct _pi_sampler;
1083 
1088 using pi_mem = _pi_mem *;
1094 using pi_image_mem_handle = void *;
1097 
1098 typedef struct {
1102 
1103 typedef struct {
1105  size_t image_width;
1107  size_t image_depth;
1114 } _pi_image_desc;
1115 
1118 
1119 typedef enum { PI_MEM_CONTEXT = 0x1106, PI_MEM_SIZE = 0x1102 } _pi_mem_info;
1120 
1121 typedef enum {
1123  0x0,
1126  0x1
1127 } _pi_peer_attr;
1129 
1132 
1133 //
1134 // Following section contains SYCL RT Plugin Interface (PI) functions.
1135 // They are 3 distinct categories:
1136 //
1137 // 1) Ones having direct analogy in OpenCL and needed for the core SYCL
1138 // functionality are started with just "pi" prefix in their names.
1139 // 2) Those having direct analogy in OpenCL but only needed for SYCL
1140 // interoperability with OpenCL are started with "picl" prefix.
1141 // 3) Functions having no direct analogy in OpenCL, started with "piext".
1142 //
1143 // TODO: describe interfaces in Doxygen format
1144 //
1145 
1146 struct _pi_plugin;
1148 
1149 // PI Plugin Initialise.
1150 // Plugin will check the PI version of Plugin Interface,
1151 // populate the PI Version it supports, update targets field and populate
1152 // PiFunctionTable with Supported APIs. The pointers are in a predetermined
1153 // order in pi.def file.
1154 __SYCL_EXPORT pi_result piPluginInit(pi_plugin *plugin_info);
1155 
1156 //
1157 // Platform
1158 //
1159 __SYCL_EXPORT pi_result piPlatformsGet(pi_uint32 num_entries,
1160  pi_platform *platforms,
1161  pi_uint32 *num_platforms);
1162 
1163 __SYCL_EXPORT pi_result piPlatformGetInfo(pi_platform platform,
1164  pi_platform_info param_name,
1165  size_t param_value_size,
1166  void *param_value,
1167  size_t *param_value_size_ret);
1168 
1174  pi_platform platform, pi_native_handle *nativeHandle);
1175 
1182  pi_native_handle nativeHandle, pi_platform *platform);
1183 
1184 __SYCL_EXPORT pi_result piDevicesGet(pi_platform platform,
1186  pi_uint32 num_entries, pi_device *devices,
1187  pi_uint32 *num_devices);
1188 
1189 __SYCL_EXPORT pi_result piextEnablePeerAccess(pi_device command_device,
1190  pi_device peer_device);
1191 __SYCL_EXPORT pi_result piextDisablePeerAccess(pi_device command_device,
1192  pi_device peer_device);
1193 __SYCL_EXPORT pi_result piextPeerAccessGetInfo(
1194  pi_device command_device, pi_device peer_device, pi_peer_attr attr,
1195  size_t param_value_size, void *param_value, size_t *param_value_size_ret);
1196 
1200 __SYCL_EXPORT pi_result piDeviceGetInfo(pi_device device,
1201  pi_device_info param_name,
1202  size_t param_value_size,
1203  void *param_value,
1204  size_t *param_value_size_ret);
1205 
1206 __SYCL_EXPORT pi_result piDeviceRetain(pi_device device);
1207 
1208 __SYCL_EXPORT pi_result piDeviceRelease(pi_device device);
1209 
1210 __SYCL_EXPORT pi_result piDevicePartition(
1211  pi_device device, const pi_device_partition_property *properties,
1212  pi_uint32 num_devices, pi_device *out_devices, pi_uint32 *out_num_devices);
1213 
1218 __SYCL_EXPORT pi_result
1220 
1228  pi_native_handle nativeHandle, pi_platform platform, pi_device *device);
1229 
1233 __SYCL_EXPORT pi_result piextDeviceSelectBinary(pi_device device,
1234  pi_device_binary *binaries,
1235  pi_uint32 num_binaries,
1236  pi_uint32 *selected_binary_ind);
1237 
1250  pi_device device, pi_program program, const char *function_name,
1251  pi_uint64 *function_pointer_ret);
1252 
1253 //
1254 // Context
1255 //
1256 __SYCL_EXPORT pi_result piContextCreate(
1257  const pi_context_properties *properties, pi_uint32 num_devices,
1258  const pi_device *devices,
1259  void (*pfn_notify)(const char *errinfo, const void *private_info, size_t cb,
1260  void *user_data),
1261  void *user_data, pi_context *ret_context);
1262 
1263 __SYCL_EXPORT pi_result piContextGetInfo(pi_context context,
1264  pi_context_info param_name,
1265  size_t param_value_size,
1266  void *param_value,
1267  size_t *param_value_size_ret);
1268 
1269 __SYCL_EXPORT pi_result piContextRetain(pi_context context);
1270 
1271 __SYCL_EXPORT pi_result piContextRelease(pi_context context);
1272 
1273 typedef void (*pi_context_extended_deleter)(void *user_data);
1274 
1276  pi_context context, pi_context_extended_deleter func, void *user_data);
1277 
1282 __SYCL_EXPORT pi_result
1284 
1309  pi_native_handle nativeHandle, pi_uint32 numDevices,
1310  const pi_device *devices, bool pluginOwnsNativeHandle, pi_context *context);
1311 
1312 //
1313 // Queue
1314 //
1315 
1316 // TODO: Remove during next ABI break and rename piextQueueCreate to
1317 // piQueueCreate.
1318 __SYCL_EXPORT pi_result piQueueCreate(pi_context context, pi_device device,
1319  pi_queue_properties properties,
1320  pi_queue *queue);
1324 __SYCL_EXPORT pi_result piextQueueCreate(pi_context context, pi_device device,
1325  pi_queue_properties *properties,
1326  pi_queue *queue);
1327 
1328 __SYCL_EXPORT pi_result piQueueGetInfo(pi_queue command_queue,
1329  pi_queue_info param_name,
1330  size_t param_value_size,
1331  void *param_value,
1332  size_t *param_value_size_ret);
1333 
1334 __SYCL_EXPORT pi_result piQueueRetain(pi_queue command_queue);
1335 
1336 __SYCL_EXPORT pi_result piQueueRelease(pi_queue command_queue);
1337 
1338 __SYCL_EXPORT pi_result piQueueFinish(pi_queue command_queue);
1339 
1340 __SYCL_EXPORT pi_result piQueueFlush(pi_queue command_queue);
1341 
1347 __SYCL_EXPORT pi_result piextQueueGetNativeHandle(
1348  pi_queue queue, pi_native_handle *nativeHandle, int32_t *nativeHandleDesc);
1349 
1364  pi_native_handle nativeHandle, int32_t nativeHandleDesc, pi_context context,
1365  pi_device device, bool pluginOwnsNativeHandle,
1366  pi_queue_properties *Properties, pi_queue *queue);
1367 
1368 //
1369 // Memory
1370 //
1371 __SYCL_EXPORT pi_result piMemBufferCreate(
1372  pi_context context, pi_mem_flags flags, size_t size, void *host_ptr,
1373  pi_mem *ret_mem, const pi_mem_properties *properties = nullptr);
1374 
1375 __SYCL_EXPORT pi_result piMemImageCreate(pi_context context, pi_mem_flags flags,
1377  const pi_image_desc *image_desc,
1378  void *host_ptr, pi_mem *ret_mem);
1379 
1380 __SYCL_EXPORT pi_result piMemGetInfo(pi_mem mem, pi_mem_info param_name,
1381  size_t param_value_size, void *param_value,
1382  size_t *param_value_size_ret);
1383 
1384 __SYCL_EXPORT pi_result piMemImageGetInfo(pi_mem image,
1385  pi_image_info param_name,
1386  size_t param_value_size,
1387  void *param_value,
1388  size_t *param_value_size_ret);
1389 
1390 __SYCL_EXPORT pi_result piMemRetain(pi_mem mem);
1391 
1392 __SYCL_EXPORT pi_result piMemRelease(pi_mem mem);
1393 
1394 __SYCL_EXPORT pi_result piMemBufferPartition(
1395  pi_mem buffer, pi_mem_flags flags, pi_buffer_create_type buffer_create_type,
1396  void *buffer_create_info, pi_mem *ret_mem);
1397 
1402 __SYCL_EXPORT pi_result piextMemGetNativeHandle(pi_mem mem,
1403  pi_native_handle *nativeHandle);
1404 
1414  pi_native_handle nativeHandle, pi_context context, bool ownNativeHandle,
1415  pi_mem *mem);
1416 
1431  pi_native_handle nativeHandle, pi_context context, bool ownNativeHandle,
1432  const pi_image_format *ImageFormat, const pi_image_desc *ImageDesc,
1433  pi_mem *img);
1434 
1435 //
1436 // Program
1437 //
1438 
1439 __SYCL_EXPORT pi_result piProgramCreate(pi_context context, const void *il,
1440  size_t length, pi_program *res_program);
1441 
1458 __SYCL_EXPORT pi_result piProgramCreateWithBinary(
1459  pi_context context, pi_uint32 num_devices, const pi_device *device_list,
1460  const size_t *lengths, const unsigned char **binaries,
1461  size_t num_metadata_entries, const pi_device_binary_property *metadata,
1462  pi_int32 *binary_status, pi_program *ret_program);
1463 
1464 __SYCL_EXPORT pi_result piProgramGetInfo(pi_program program,
1465  pi_program_info param_name,
1466  size_t param_value_size,
1467  void *param_value,
1468  size_t *param_value_size_ret);
1469 
1470 __SYCL_EXPORT pi_result
1471 piProgramLink(pi_context context, pi_uint32 num_devices,
1472  const pi_device *device_list, const char *options,
1473  pi_uint32 num_input_programs, const pi_program *input_programs,
1474  void (*pfn_notify)(pi_program program, void *user_data),
1475  void *user_data, pi_program *ret_program);
1476 
1477 __SYCL_EXPORT pi_result piProgramCompile(
1478  pi_program program, pi_uint32 num_devices, const pi_device *device_list,
1479  const char *options, pi_uint32 num_input_headers,
1480  const pi_program *input_headers, const char **header_include_names,
1481  void (*pfn_notify)(pi_program program, void *user_data), void *user_data);
1482 
1483 __SYCL_EXPORT pi_result piProgramBuild(
1484  pi_program program, pi_uint32 num_devices, const pi_device *device_list,
1485  const char *options,
1486  void (*pfn_notify)(pi_program program, void *user_data), void *user_data);
1487 
1488 __SYCL_EXPORT pi_result piProgramGetBuildInfo(
1489  pi_program program, pi_device device, _pi_program_build_info param_name,
1490  size_t param_value_size, void *param_value, size_t *param_value_size_ret);
1491 
1492 __SYCL_EXPORT pi_result piProgramRetain(pi_program program);
1493 
1494 __SYCL_EXPORT pi_result piProgramRelease(pi_program program);
1495 
1505 __SYCL_EXPORT pi_result
1507  size_t spec_size, const void *spec_value);
1508 
1513 __SYCL_EXPORT pi_result
1515 
1525  pi_native_handle nativeHandle, pi_context context,
1526  bool pluginOwnsNativeHandle, pi_program *program);
1527 
1528 //
1529 // Kernel
1530 //
1531 
1532 typedef enum {
1536  PI_USM_PTRS = 0x4203,
1540 
1542 
1543 __SYCL_EXPORT pi_result piKernelCreate(pi_program program,
1544  const char *kernel_name,
1545  pi_kernel *ret_kernel);
1546 
1547 __SYCL_EXPORT pi_result piKernelSetArg(pi_kernel kernel, pi_uint32 arg_index,
1548  size_t arg_size, const void *arg_value);
1549 
1550 __SYCL_EXPORT pi_result piKernelGetInfo(pi_kernel kernel,
1551  pi_kernel_info param_name,
1552  size_t param_value_size,
1553  void *param_value,
1554  size_t *param_value_size_ret);
1555 
1556 __SYCL_EXPORT pi_result piKernelGetGroupInfo(pi_kernel kernel, pi_device device,
1557  pi_kernel_group_info param_name,
1558  size_t param_value_size,
1559  void *param_value,
1560  size_t *param_value_size_ret);
1561 
1580 __SYCL_EXPORT pi_result piKernelGetSubGroupInfo(
1581  pi_kernel kernel, pi_device device, pi_kernel_sub_group_info param_name,
1582  size_t input_value_size, const void *input_value, size_t param_value_size,
1583  void *param_value, size_t *param_value_size_ret);
1584 
1585 __SYCL_EXPORT pi_result piKernelRetain(pi_kernel kernel);
1586 
1587 __SYCL_EXPORT pi_result piKernelRelease(pi_kernel kernel);
1588 
1596 __SYCL_EXPORT pi_result piextKernelSetArgPointer(pi_kernel kernel,
1597  pi_uint32 arg_index,
1598  size_t arg_size,
1599  const void *arg_value);
1600 
1612 __SYCL_EXPORT pi_result piKernelSetExecInfo(pi_kernel kernel,
1613  pi_kernel_exec_info value_name,
1614  size_t param_value_size,
1615  const void *param_value);
1616 
1627  pi_native_handle nativeHandle, pi_context context, pi_program program,
1628  bool pluginOwnsNativeHandle, pi_kernel *kernel);
1629 
1634 __SYCL_EXPORT pi_result
1636 
1637 //
1638 // Events
1639 //
1640 
1645 __SYCL_EXPORT pi_result piEventCreate(pi_context context, pi_event *ret_event);
1646 
1647 __SYCL_EXPORT pi_result piEventGetInfo(pi_event event, pi_event_info param_name,
1648  size_t param_value_size,
1649  void *param_value,
1650  size_t *param_value_size_ret);
1651 
1652 __SYCL_EXPORT pi_result piEventGetProfilingInfo(pi_event event,
1653  pi_profiling_info param_name,
1654  size_t param_value_size,
1655  void *param_value,
1656  size_t *param_value_size_ret);
1657 
1658 __SYCL_EXPORT pi_result piEventsWait(pi_uint32 num_events,
1659  const pi_event *event_list);
1660 
1661 __SYCL_EXPORT pi_result piEventSetCallback(
1662  pi_event event, pi_int32 command_exec_callback_type,
1663  void (*pfn_notify)(pi_event event, pi_int32 event_command_status,
1664  void *user_data),
1665  void *user_data);
1666 
1667 __SYCL_EXPORT pi_result piEventSetStatus(pi_event event,
1668  pi_int32 execution_status);
1669 
1670 __SYCL_EXPORT pi_result piEventRetain(pi_event event);
1671 
1672 __SYCL_EXPORT pi_result piEventRelease(pi_event event);
1673 
1678 __SYCL_EXPORT pi_result
1680 
1690  pi_native_handle nativeHandle, pi_context context, bool ownNativeHandle,
1691  pi_event *event);
1692 
1693 //
1694 // Sampler
1695 //
1696 __SYCL_EXPORT pi_result piSamplerCreate(
1697  pi_context context, const pi_sampler_properties *sampler_properties,
1698  pi_sampler *result_sampler);
1699 
1700 __SYCL_EXPORT pi_result piSamplerGetInfo(pi_sampler sampler,
1701  pi_sampler_info param_name,
1702  size_t param_value_size,
1703  void *param_value,
1704  size_t *param_value_size_ret);
1705 
1706 __SYCL_EXPORT pi_result piSamplerRetain(pi_sampler sampler);
1707 
1708 __SYCL_EXPORT pi_result piSamplerRelease(pi_sampler sampler);
1709 
1710 //
1711 // Queue Commands
1712 //
1713 __SYCL_EXPORT pi_result piEnqueueKernelLaunch(
1714  pi_queue queue, pi_kernel kernel, pi_uint32 work_dim,
1715  const size_t *global_work_offset, const size_t *global_work_size,
1716  const size_t *local_work_size, pi_uint32 num_events_in_wait_list,
1717  const pi_event *event_wait_list, pi_event *event);
1718 
1719 __SYCL_EXPORT pi_result piEnqueueEventsWait(pi_queue command_queue,
1720  pi_uint32 num_events_in_wait_list,
1721  const pi_event *event_wait_list,
1722  pi_event *event);
1723 
1725  pi_queue command_queue, pi_uint32 num_events_in_wait_list,
1726  const pi_event *event_wait_list, pi_event *event);
1727 
1728 __SYCL_EXPORT pi_result piEnqueueMemBufferRead(
1729  pi_queue queue, pi_mem buffer, pi_bool blocking_read, size_t offset,
1730  size_t size, void *ptr, pi_uint32 num_events_in_wait_list,
1731  const pi_event *event_wait_list, pi_event *event);
1732 
1734  pi_queue command_queue, pi_mem buffer, pi_bool blocking_read,
1735  pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset,
1736  pi_buff_rect_region region, size_t buffer_row_pitch,
1737  size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch,
1738  void *ptr, pi_uint32 num_events_in_wait_list,
1739  const pi_event *event_wait_list, pi_event *event);
1740 
1741 __SYCL_EXPORT pi_result
1742 piEnqueueMemBufferWrite(pi_queue command_queue, pi_mem buffer,
1743  pi_bool blocking_write, size_t offset, size_t size,
1744  const void *ptr, pi_uint32 num_events_in_wait_list,
1745  const pi_event *event_wait_list, pi_event *event);
1746 
1748  pi_queue command_queue, pi_mem buffer, pi_bool blocking_write,
1749  pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset,
1750  pi_buff_rect_region region, size_t buffer_row_pitch,
1751  size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch,
1752  const void *ptr, pi_uint32 num_events_in_wait_list,
1753  const pi_event *event_wait_list, pi_event *event);
1754 
1755 __SYCL_EXPORT pi_result
1756 piEnqueueMemBufferCopy(pi_queue command_queue, pi_mem src_buffer,
1757  pi_mem dst_buffer, size_t src_offset, size_t dst_offset,
1758  size_t size, pi_uint32 num_events_in_wait_list,
1759  const pi_event *event_wait_list, pi_event *event);
1760 
1762  pi_queue command_queue, pi_mem src_buffer, pi_mem dst_buffer,
1763  pi_buff_rect_offset src_origin, pi_buff_rect_offset dst_origin,
1764  pi_buff_rect_region region, size_t src_row_pitch, size_t src_slice_pitch,
1765  size_t dst_row_pitch, size_t dst_slice_pitch,
1766  pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list,
1767  pi_event *event);
1768 
1769 __SYCL_EXPORT pi_result
1770 piEnqueueMemBufferFill(pi_queue command_queue, pi_mem buffer,
1771  const void *pattern, size_t pattern_size, size_t offset,
1772  size_t size, pi_uint32 num_events_in_wait_list,
1773  const pi_event *event_wait_list, pi_event *event);
1774 
1775 __SYCL_EXPORT pi_result piEnqueueMemImageRead(
1776  pi_queue command_queue, pi_mem image, pi_bool blocking_read,
1777  pi_image_offset origin, pi_image_region region, size_t row_pitch,
1778  size_t slice_pitch, void *ptr, pi_uint32 num_events_in_wait_list,
1779  const pi_event *event_wait_list, pi_event *event);
1780 
1781 __SYCL_EXPORT pi_result piEnqueueMemImageWrite(
1782  pi_queue command_queue, pi_mem image, pi_bool blocking_write,
1783  pi_image_offset origin, pi_image_region region, size_t input_row_pitch,
1784  size_t input_slice_pitch, const void *ptr,
1785  pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list,
1786  pi_event *event);
1787 
1788 __SYCL_EXPORT pi_result piEnqueueMemImageCopy(
1789  pi_queue command_queue, pi_mem src_image, pi_mem dst_image,
1790  pi_image_offset src_origin, pi_image_offset dst_origin,
1791  pi_image_region region, pi_uint32 num_events_in_wait_list,
1792  const pi_event *event_wait_list, pi_event *event);
1793 
1794 __SYCL_EXPORT pi_result
1795 piEnqueueMemImageFill(pi_queue command_queue, pi_mem image,
1796  const void *fill_color, const size_t *origin,
1797  const size_t *region, pi_uint32 num_events_in_wait_list,
1798  const pi_event *event_wait_list, pi_event *event);
1799 
1800 __SYCL_EXPORT pi_result piEnqueueMemBufferMap(
1801  pi_queue command_queue, pi_mem buffer, pi_bool blocking_map,
1802  pi_map_flags map_flags, size_t offset, size_t size,
1803  pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list,
1804  pi_event *event, void **ret_map);
1805 
1806 __SYCL_EXPORT pi_result piEnqueueMemUnmap(pi_queue command_queue, pi_mem memobj,
1807  void *mapped_ptr,
1808  pi_uint32 num_events_in_wait_list,
1809  const pi_event *event_wait_list,
1810  pi_event *event);
1811 
1812 #ifndef PI_BIT
1813 #define PI_BIT(_i) (1 << _i)
1814 #endif // PI_BIT
1815 
1816 typedef enum {
1822 typedef uint32_t pi_mem_access_flag;
1823 
1824 typedef enum {
1829 
1830 typedef struct {
1832  void *pNext;
1836 
1837 // Extension to allow backends to process a PI memory object before adding it
1838 // as an argument for a kernel.
1839 // Note: This is needed by the CUDA backend to extract the device pointer to
1840 // the memory as the kernels uses it rather than the PI object itself.
1841 __SYCL_EXPORT pi_result piextKernelSetArgMemObj(
1842  pi_kernel kernel, pi_uint32 arg_index,
1843  const pi_mem_obj_property *arg_properties, const pi_mem *arg_value);
1844 
1845 // Extension to allow backends to process a PI sampler object before adding it
1846 // as an argument for a kernel.
1847 // Note: This is needed by the CUDA backend to extract the properties of the
1848 // sampler as the kernels uses it rather than the PI object itself.
1849 __SYCL_EXPORT pi_result piextKernelSetArgSampler(pi_kernel kernel,
1850  pi_uint32 arg_index,
1851  const pi_sampler *arg_value);
1852 
1854 // USM
1856 typedef enum {
1863 
1864 typedef enum : pi_bitfield {
1865  PI_USM_ACCESS = (1 << 0),
1870 
1871 typedef enum {
1877 
1878 typedef enum {
1883 } _pi_usm_type;
1884 
1885 // Flag is used for piProgramUSMEnqueuePrefetch. PI_USM_MIGRATION_TBD0 is a
1886 // placeholder for future developments and should not change the behaviour of
1887 // piProgramUSMEnqueuePrefetch
1888 typedef enum : pi_bitfield {
1891 
1897 
1905 __SYCL_EXPORT pi_result piextUSMHostAlloc(void **result_ptr, pi_context context,
1906  pi_usm_mem_properties *properties,
1907  size_t size, pi_uint32 alignment);
1908 
1917 __SYCL_EXPORT pi_result piextUSMDeviceAlloc(void **result_ptr,
1918  pi_context context,
1919  pi_device device,
1920  pi_usm_mem_properties *properties,
1921  size_t size, pi_uint32 alignment);
1922 
1931 __SYCL_EXPORT pi_result piextUSMSharedAlloc(void **result_ptr,
1932  pi_context context,
1933  pi_device device,
1934  pi_usm_mem_properties *properties,
1935  size_t size, pi_uint32 alignment);
1936 
1948 __SYCL_EXPORT pi_result piextUSMPitchedAlloc(
1949  void **result_ptr, size_t *result_pitch, pi_context context,
1950  pi_device device, pi_usm_mem_properties *properties, size_t width_in_bytes,
1951  size_t height, unsigned int element_size_bytes);
1952 
1959 __SYCL_EXPORT pi_result piextUSMFree(pi_context context, void *ptr);
1960 
1972 __SYCL_EXPORT pi_result piextUSMEnqueueMemset(pi_queue queue, void *ptr,
1973  pi_int32 value, size_t count,
1974  pi_uint32 num_events_in_waitlist,
1975  const pi_event *events_waitlist,
1976  pi_event *event);
1977 
1988 __SYCL_EXPORT pi_result piextUSMEnqueueMemcpy(pi_queue queue, pi_bool blocking,
1989  void *dst_ptr,
1990  const void *src_ptr, size_t size,
1991  pi_uint32 num_events_in_waitlist,
1992  const pi_event *events_waitlist,
1993  pi_event *event);
1994 
2004 __SYCL_EXPORT pi_result piextUSMEnqueuePrefetch(
2005  pi_queue queue, const void *ptr, size_t size, pi_usm_migration_flags flags,
2006  pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist,
2007  pi_event *event);
2008 
2016 // USM memadvise API to govern behavior of automatic migration mechanisms
2017 __SYCL_EXPORT pi_result piextUSMEnqueueMemAdvise(pi_queue queue,
2018  const void *ptr, size_t length,
2019  pi_mem_advice advice,
2020  pi_event *event);
2021 
2038 __SYCL_EXPORT pi_result piextUSMGetMemAllocInfo(
2039  pi_context context, const void *ptr, pi_mem_alloc_info param_name,
2040  size_t param_value_size, void *param_value, size_t *param_value_size_ret);
2041 
2054 __SYCL_EXPORT pi_result piextUSMEnqueueFill2D(pi_queue queue, void *ptr,
2055  size_t pitch, size_t pattern_size,
2056  const void *pattern, size_t width,
2057  size_t height,
2058  pi_uint32 num_events_in_waitlist,
2059  const pi_event *events_waitlist,
2060  pi_event *event);
2061 
2073 __SYCL_EXPORT pi_result piextUSMEnqueueMemset2D(
2074  pi_queue queue, void *ptr, size_t pitch, int value, size_t width,
2075  size_t height, pi_uint32 num_events_in_waitlist,
2076  const pi_event *events_waitlist, pi_event *event);
2077 
2092 __SYCL_EXPORT pi_result piextUSMEnqueueMemcpy2D(
2093  pi_queue queue, pi_bool blocking, void *dst_ptr, size_t dst_pitch,
2094  const void *src_ptr, size_t src_pitch, size_t width, size_t height,
2095  pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist,
2096  pi_event *event);
2097 
2103 __SYCL_EXPORT pi_result piextUSMImport(const void *ptr, size_t size,
2104  pi_context context);
2105 
2110 __SYCL_EXPORT pi_result piextUSMRelease(const void *ptr, pi_context context);
2111 
2115 
2130  pi_queue queue, pi_program program, const char *name,
2131  pi_bool blocking_write, size_t count, size_t offset, const void *src,
2132  pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list,
2133  pi_event *event);
2134 
2149  pi_queue queue, pi_program program, const char *name, pi_bool blocking_read,
2150  size_t count, size_t offset, void *dst, pi_uint32 num_events_in_wait_list,
2151  const pi_event *event_wait_list, pi_event *event);
2152 
2157 // Host Pipes
2159 
2178 __SYCL_EXPORT pi_result piextEnqueueReadHostPipe(
2179  pi_queue queue, pi_program program, const char *pipe_symbol,
2180  pi_bool blocking, void *ptr, size_t size, pi_uint32 num_events_in_waitlist,
2181  const pi_event *events_waitlist, pi_event *event);
2182 
2201 __SYCL_EXPORT pi_result piextEnqueueWriteHostPipe(
2202  pi_queue queue, pi_program program, const char *pipe_symbol,
2203  pi_bool blocking, void *ptr, size_t size, pi_uint32 num_events_in_waitlist,
2204  const pi_event *events_waitlist, pi_event *event);
2205 
2212 __SYCL_EXPORT pi_result piextPluginGetOpaqueData(void *opaque_data_param,
2213  void **opaque_data_return);
2214 
2218 __SYCL_EXPORT pi_result piTearDown(void *PluginParameter);
2219 
2231 __SYCL_EXPORT pi_result piPluginGetLastError(char **message);
2232 
2240 __SYCL_EXPORT pi_result piPluginGetBackendOption(pi_platform platform,
2241  const char *frontend_option,
2242  const char **backend_option);
2243 
2254 __SYCL_EXPORT pi_result piGetDeviceAndHostTimer(pi_device Device,
2255  uint64_t *DeviceTime,
2256  uint64_t *HostTime);
2257 
2259 struct _pi_ext_command_buffer;
2260 struct _pi_ext_sync_point;
2263 
2264 typedef enum {
2267 
2270  const void *pNext;
2272 };
2273 
2280 __SYCL_EXPORT pi_result
2282  const pi_ext_command_buffer_desc *desc,
2283  pi_ext_command_buffer *ret_command_buffer);
2284 
2287 __SYCL_EXPORT pi_result
2289 
2294 __SYCL_EXPORT pi_result
2296 
2300 __SYCL_EXPORT pi_result
2302 
2316  pi_ext_command_buffer command_buffer, pi_kernel kernel, pi_uint32 work_dim,
2317  const size_t *global_work_offset, const size_t *global_work_size,
2318  const size_t *local_work_size, pi_uint32 num_sync_points_in_wait_list,
2319  const pi_ext_sync_point *sync_point_wait_list,
2320  pi_ext_sync_point *sync_point);
2321 
2333  pi_ext_command_buffer command_buffer, void *dst_ptr, const void *src_ptr,
2334  size_t size, pi_uint32 num_sync_points_in_wait_list,
2335  const pi_ext_sync_point *sync_point_wait_list,
2336  pi_ext_sync_point *sync_point);
2337 
2351  pi_ext_command_buffer command_buffer, pi_mem src_buffer, pi_mem dst_buffer,
2352  size_t src_offset, size_t dst_offset, size_t size,
2353  pi_uint32 num_sync_points_in_wait_list,
2354  const pi_ext_sync_point *sync_point_wait_list,
2355  pi_ext_sync_point *sync_point);
2356 
2374  pi_ext_command_buffer command_buffer, pi_mem src_buffer, pi_mem dst_buffer,
2375  pi_buff_rect_offset src_origin, pi_buff_rect_offset dst_origin,
2376  pi_buff_rect_region region, size_t src_row_pitch, size_t src_slice_pitch,
2377  size_t dst_row_pitch, size_t dst_slice_pitch,
2378  pi_uint32 num_sync_points_in_wait_list,
2379  const pi_ext_sync_point *sync_point_wait_list,
2380  pi_ext_sync_point *sync_point);
2381 
2394  pi_ext_command_buffer command_buffer, pi_mem buffer, size_t offset,
2395  size_t size, void *dst, pi_uint32 num_sync_points_in_wait_list,
2396  const pi_ext_sync_point *sync_point_wait_list,
2397  pi_ext_sync_point *sync_point);
2398 
2416  pi_ext_command_buffer command_buffer, pi_mem buffer,
2417  pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset,
2418  pi_buff_rect_region region, size_t buffer_row_pitch,
2419  size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch,
2420  void *ptr, pi_uint32 num_events_in_wait_list,
2421  const pi_ext_sync_point *sync_point_wait_list,
2422  pi_ext_sync_point *sync_point);
2423 
2436  pi_ext_command_buffer command_buffer, pi_mem buffer, size_t offset,
2437  size_t size, const void *ptr, pi_uint32 num_events_in_wait_list,
2438  const pi_ext_sync_point *sync_point_wait_list,
2439  pi_ext_sync_point *sync_point);
2440 
2458  pi_ext_command_buffer command_buffer, pi_mem buffer,
2459  pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset,
2460  pi_buff_rect_region region, size_t buffer_row_pitch,
2461  size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch,
2462  const void *ptr, pi_uint32 num_events_in_wait_list,
2463  const pi_ext_sync_point *sync_point_wait_list,
2464  pi_ext_sync_point *sync_point);
2465 
2475 __SYCL_EXPORT pi_result
2477  pi_uint32 num_events_in_wait_list,
2478  const pi_event *event_wait_list, pi_event *event);
2479 
2486  pi_context context, pi_device device, pi_image_handle handle);
2487 
2493  pi_context context, pi_device device, pi_image_handle handle);
2494 
2503 __SYCL_EXPORT pi_result piextMemImageAllocate(pi_context context,
2504  pi_device device,
2506  pi_image_desc *image_desc,
2507  pi_image_mem_handle *ret_mem);
2508 
2516 __SYCL_EXPORT pi_result piextMemMipmapGetLevel(pi_context context,
2517  pi_device device,
2518  pi_image_mem_handle mip_mem,
2519  unsigned int level,
2520  pi_image_mem_handle *ret_mem);
2521 
2527 __SYCL_EXPORT pi_result piextMemImageFree(pi_context context, pi_device device,
2528  pi_image_mem_handle memory_handle);
2529 
2535 __SYCL_EXPORT pi_result piextMemMipmapFree(pi_context context, pi_device device,
2536  pi_image_mem_handle memory_handle);
2537 
2548  pi_context context, pi_device device, pi_image_mem_handle img_mem,
2549  pi_image_format *image_format, pi_image_desc *image_desc, pi_mem *ret_mem,
2550  pi_image_handle *ret_handle);
2551 
2563  pi_context context, pi_device device, pi_image_mem_handle img_mem,
2565  pi_sampler sampler, pi_mem *ret_mem, pi_image_handle *ret_handle);
2566 
2577  pi_context context, const pi_sampler_properties *sampler_properties,
2578  float min_mipmap_level_clamp, float max_mipmap_level_clamp,
2579  float max_anisotropy, pi_sampler *result_sampler);
2580 
2596 __SYCL_EXPORT pi_result piextMemImageCopy(
2597  pi_queue command_queue, void *dst_ptr, void *src_ptr,
2598  const pi_image_format *image_format, const pi_image_desc *image_desc,
2599  const pi_image_copy_flags flags, pi_image_offset src_offset,
2600  pi_image_offset dst_offset, pi_image_region copy_extent,
2601  pi_image_region host_extent, pi_uint32 num_events_in_wait_list,
2602  const pi_event *event_wait_list, pi_event *event);
2603 
2610 __SYCL_EXPORT pi_result piextMemImageGetInfo(
2611  const pi_image_mem_handle mem_handle, pi_image_info param_name,
2612  void *param_value, size_t *param_value_size_ret);
2613 
2622 __SYCL_EXPORT pi_result
2623 piextMemImportOpaqueFD(pi_context context, pi_device device, size_t size,
2624  int file_descriptor, pi_interop_mem_handle *ret_handle);
2625 
2635 __SYCL_EXPORT pi_result piextMemMapExternalArray(
2637  pi_image_desc *image_desc, pi_interop_mem_handle mem_handle,
2638  pi_image_mem_handle *ret_mem);
2639 
2645 __SYCL_EXPORT pi_result piextMemReleaseInterop(
2646  pi_context context, pi_device device, pi_interop_mem_handle memory_handle);
2647 
2656  pi_context context, pi_device device, int file_descriptor,
2657  pi_interop_semaphore_handle *ret_handle);
2658 
2665 __SYCL_EXPORT pi_result
2667  pi_interop_semaphore_handle sem_handle);
2668 
2678  pi_queue command_queue, pi_interop_semaphore_handle sem_handle,
2679  pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list,
2680  pi_event *event);
2681 
2692  pi_queue command_queue, pi_interop_semaphore_handle sem_handle,
2693  pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list,
2694  pi_event *event);
2695 
2696 typedef enum {
2702 
2703 struct _pi_plugin {
2704  // PI version supported by host passed to the plugin. The Plugin
2705  // checks and writes the appropriate Function Pointers in
2706  // PiFunctionTable.
2707  // TODO: Work on version fields and their handshaking mechanism.
2708  // Some choices are:
2709  // - Use of integers to keep major and minor version.
2710  // - Keeping char* Versions.
2711  char PiVersion[20];
2712  // Plugin edits this.
2713  char PluginVersion[20];
2714  char *Targets;
2716 #define _PI_API(api) decltype(::api) *api;
2717 #include <sycl/detail/pi.def>
2718  } PiFunctionTable;
2719 
2721 };
2722 
2723 #ifdef __cplusplus
2724 } // extern "C"
2725 #endif // __cplusplus
2726 
2727 #endif // _PI_H_
PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_WIDTH
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_WIDTH
Definition: pi.h:421
PI_COMMAND_TYPE_USER
@ PI_COMMAND_TYPE_USER
Definition: pi.h:532
PI_PROFILING_INFO_COMMAND_START
@ PI_PROFILING_INFO_COMMAND_START
Definition: pi.h:686
piEventGetProfilingInfo
pi_result piEventGetProfilingInfo(pi_event event, pi_profiling_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:567
PI_DEVICE_INFO_HOST_UNIFIED_MEMORY
@ PI_DEVICE_INFO_HOST_UNIFIED_MEMORY
Definition: pi.h:335
_pi_image_desc::num_samples
pi_uint32 num_samples
Definition: pi.h:1112
PI_IMAGE_INFO_ROW_PITCH
@ PI_IMAGE_INFO_ROW_PITCH
Definition: pi.h:500
PI_DEVICE_BINARY_TYPE_NONE
static constexpr pi_device_binary_type PI_DEVICE_BINARY_TYPE_NONE
Definition: pi.h:876
piKernelCreate
pi_result piKernelCreate(pi_program program, const char *kernel_name, pi_kernel *ret_kernel)
Definition: pi_cuda.cpp:335
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_CHAR
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_CHAR
Definition: pi.h:296
piextEnqueueDeviceGlobalVariableRead
pi_result piextEnqueueDeviceGlobalVariableRead(pi_queue queue, pi_program program, const char *name, pi_bool blocking_read, size_t count, size_t offset, void *dst, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
API reading data from a device global variable to host.
Definition: pi_cuda.cpp:970
PI_DEVICE_INFO_OPENCL_C_VERSION
@ PI_DEVICE_INFO_OPENCL_C_VERSION
Definition: pi.h:353
pi_image_region_struct::height
size_t height
Definition: pi.h:1047
_pi_mem
Definition: pi_cuda.hpp:56
PI_DEVICE_PARTITION_EQUALLY
static constexpr pi_device_partition_property PI_DEVICE_PARTITION_EQUALLY
Definition: pi.h:789
PI_SAMPLER_ADDRESSING_MODE_MIRRORED_REPEAT
@ PI_SAMPLER_ADDRESSING_MODE_MIRRORED_REPEAT
Definition: pi.h:642
pi_buff_rect_region_struct::depth_scalar
size_t depth_scalar
Definition: pi.h:1030
_pi_mem_obj_property::pNext
void * pNext
Definition: pi.h:1832
piEventRelease
pi_result piEventRelease(pi_event event)
Definition: pi_cuda.cpp:594
PI_MAP_WRITE
constexpr pi_map_flags PI_MAP_WRITE
Definition: pi.h:706
PI_EXT_INTEL_DEVICE_INFO_FREE_MEMORY
@ PI_EXT_INTEL_DEVICE_INFO_FREE_MEMORY
Definition: pi.h:385
PI_USM_ACCESS
@ PI_USM_ACCESS
Definition: pi.h:1865
PI_DEVICE_INFO_PROFILE
@ PI_DEVICE_INFO_PROFILE
Definition: pi.h:351
piEnqueueKernelLaunch
pi_result piEnqueueKernelLaunch(pi_queue queue, pi_kernel kernel, pi_uint32 work_dim, const size_t *global_work_offset, const size_t *global_work_size, const size_t *local_work_size, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:531
PI_QUEUE_COMPUTE_INDEX
constexpr pi_queue_properties PI_QUEUE_COMPUTE_INDEX
Definition: pi.h:731
piMemGetInfo
pi_result piMemGetInfo(pi_mem mem, pi_mem_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:212
_pi_mem_type
_pi_mem_type
Definition: pi.h:557
_pi_image_desc::image_array_size
size_t image_array_size
Definition: pi.h:1108
_pi_offload_entry_struct
Definition: pi.h:833
PI_KERNEL_INFO_REFERENCE_COUNT
@ PI_KERNEL_INFO_REFERENCE_COUNT
Definition: pi.h:480
PI_DEVICE_INFO_IMAGE3D_MAX_WIDTH
@ PI_DEVICE_INFO_IMAGE3D_MAX_WIDTH
Definition: pi.h:318
PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_SHARED_USM_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_SHARED_USM_SUPPORT
Definition: pi.h:417
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_CHAR
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_CHAR
Definition: pi.h:303
PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_PITCH
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_PITCH
Definition: pi.h:423
PI_EXT_CONTEXT_INFO_ATOMIC_MEMORY_ORDER_CAPABILITIES
@ PI_EXT_CONTEXT_INFO_ATOMIC_MEMORY_ORDER_CAPABILITIES
Definition: pi.h:455
PI_DEVICE_AFFINITY_DOMAIN_L4_CACHE
static constexpr pi_device_affinity_domain PI_DEVICE_AFFINITY_DOMAIN_L4_CACHE
Definition: pi.h:804
PI_DEVICE_INFO_DOUBLE_FP_CONFIG
@ PI_DEVICE_INFO_DOUBLE_FP_CONFIG
Definition: pi.h:294
_pi_context_info
_pi_context_info
Definition: pi.h:448
PI_EXT_INTEL_DEVICE_INFO_MEMORY_BUS_WIDTH
@ PI_EXT_INTEL_DEVICE_INFO_MEMORY_BUS_WIDTH
Definition: pi.h:391
pi_buff_rect_region_struct::height_scalar
size_t height_scalar
Definition: pi.h:1029
PI_MEM_TYPE_IMAGE1D
@ PI_MEM_TYPE_IMAGE1D
Definition: pi.h:562
pi_buff_rect_offset_struct
Definition: pi.h:1018
PI_EXT_KERNEL_EXEC_INFO_CACHE_LARGE_SLM
@ PI_EXT_KERNEL_EXEC_INFO_CACHE_LARGE_SLM
Definition: pi.h:748
_pi_offload_entry_struct::reserved
int32_t reserved
Definition: pi.h:838
_pi_platform_backend
_pi_platform_backend
Definition: pi.h:264
piextUSMFree
pi_result piextUSMFree(pi_context context, void *ptr)
Indicates that the allocated USM memory is no longer needed on the runtime side.
Definition: pi_cuda.cpp:863
piKernelSetArg
pi_result piKernelSetArg(pi_kernel kernel, pi_uint32 arg_index, size_t arg_size, const void *arg_value)
Definition: pi_cuda.cpp:341
_pi_mem_obj_property::mem_access
pi_mem_access_flag mem_access
Definition: pi.h:1833
PI_KERNEL_INFO_ATTRIBUTES
@ PI_KERNEL_INFO_ATTRIBUTES
Definition: pi.h:483
PI_DEVICE_BINARY_VERSION
static const uint16_t PI_DEVICE_BINARY_VERSION
Definition: pi.h:886
PI_DEVICE_INFO_DRIVER_VERSION
@ PI_DEVICE_INFO_DRIVER_VERSION
Definition: pi.h:350
_pi_usm_capabilities
_pi_usm_capabilities
Definition: pi.h:1864
PI_DEVICE_INFO_GPU_EU_COUNT
@ PI_DEVICE_INFO_GPU_EU_COUNT
Definition: pi.h:376
PI_IMAGE_CHANNEL_ORDER_A
@ PI_IMAGE_CHANNEL_ORDER_A
Definition: pi.h:584
_pi_device_binary_property_struct::Name
char * Name
Definition: pi.h:856
pi_bool
pi_uint32 pi_bool
Definition: pi.h:196
PI_IMAGE_CHANNEL_TYPE_UNORM_SHORT_565
@ PI_IMAGE_CHANNEL_TYPE_UNORM_SHORT_565
Definition: pi.h:606
PI_IMAGE_CHANNEL_TYPE_HALF_FLOAT
@ PI_IMAGE_CHANNEL_TYPE_HALF_FLOAT
Definition: pi.h:615
PI_DEVICE_INFO_PREFERRED_INTEROP_USER_SYNC
@ PI_DEVICE_INFO_PREFERRED_INTEROP_USER_SYNC
Definition: pi.h:356
_pi_image_format::image_channel_data_type
pi_image_channel_type image_channel_data_type
Definition: pi.h:1100
piPluginGetLastError
pi_result piPluginGetLastError(char **message)
API to get Plugin specific warning and error messages.
Definition: pi_cuda.cpp:47
piextCommandBufferMemBufferCopyRect
pi_result piextCommandBufferMemBufferCopyRect(pi_ext_command_buffer command_buffer, pi_mem src_buffer, pi_mem dst_buffer, pi_buff_rect_offset src_origin, pi_buff_rect_offset dst_origin, pi_buff_rect_region region, size_t src_row_pitch, size_t src_slice_pitch, size_t dst_row_pitch, size_t dst_slice_pitch, pi_uint32 num_sync_points_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a rectangular mem buffer copy command to the command-buffer.
Definition: pi_cuda.cpp:1084
PI_QUEUE_INFO_CONTEXT
@ PI_QUEUE_INFO_CONTEXT
Definition: pi.h:466
pi_device_binaries_struct::DeviceBinaries
pi_device_binary DeviceBinaries
Device binaries data.
Definition: pi.h:1066
PI_DEVICE_BINARY_TYPE_SPIRV
static constexpr pi_device_binary_type PI_DEVICE_BINARY_TYPE_SPIRV
Definition: pi.h:881
PI_DEVICE_INFO_NAME
@ PI_DEVICE_INFO_NAME
Definition: pi.h:348
pi_device_binaries_struct::Version
uint16_t Version
version of this structure - for backward compatibility; all modifications which change order/type/off...
Definition: pi.h:1062
_pi_device_binary_property_set_struct
Definition: pi.h:865
piextKernelGetNativeHandle
pi_result piextKernelGetNativeHandle(pi_kernel kernel, pi_native_handle *nativeHandle)
Gets the native handle of a PI kernel object.
Definition: pi_cuda.cpp:551
pi_ext_command_buffer_desc::properties
pi_queue_properties * properties
Definition: pi.h:2271
PI_DEVICE_INFO_IL_VERSION
@ PI_DEVICE_INFO_IL_VERSION
Definition: pi.h:347
PI_DEVICE_EXEC_CAPABILITIES_NATIVE_KERNEL
constexpr pi_device_exec_capabilities PI_DEVICE_EXEC_CAPABILITIES_NATIVE_KERNEL
Definition: pi.h:660
PI_EXT_INTEL_DEVICE_INFO_ESIMD_SUPPORT
@ PI_EXT_INTEL_DEVICE_INFO_ESIMD_SUPPORT
Definition: pi.h:413
PI_QUEUE_FLAG_ON_DEVICE
constexpr pi_queue_properties PI_QUEUE_FLAG_ON_DEVICE
Definition: pi.h:735
pi_device_binary_struct::DeviceTargetSpec
const char * DeviceTargetSpec
null-terminated string representation of the device's target architecture which holds one of: __SYCL_...
Definition: pi.h:981
piextQueueGetNativeHandle
pi_result piextQueueGetNativeHandle(pi_queue queue, pi_native_handle *nativeHandle, int32_t *nativeHandleDesc)
Gets the native handle of a PI queue object.
Definition: pi_cuda.cpp:185
piProgramLink
pi_result piProgramLink(pi_context context, pi_uint32 num_devices, const pi_device *device_list, const char *options, pi_uint32 num_input_programs, const pi_program *input_programs, void(*pfn_notify)(pi_program program, void *user_data), void *user_data, pi_program *ret_program)
PI_IMAGE_CHANNEL_TYPE_UNORM_INT8
@ PI_IMAGE_CHANNEL_TYPE_UNORM_INT8
Definition: pi.h:604
PI_PROFILING_INFO_COMMAND_SUBMIT
@ PI_PROFILING_INFO_COMMAND_SUBMIT
Definition: pi.h:685
PI_MEMORY_ORDER_ACQUIRE
constexpr pi_memory_order_capabilities PI_MEMORY_ORDER_ACQUIRE
Definition: pi.h:671
piextCommandBufferFinalize
pi_result piextCommandBufferFinalize(pi_ext_command_buffer command_buffer)
API to stop command-buffer recording such that no more commands can be appended, and makes the comman...
Definition: pi_cuda.cpp:1051
PI_PROGRAM_INFO_BINARY_SIZES
@ PI_PROGRAM_INFO_BINARY_SIZES
Definition: pi.h:442
PI_DEVICE_BINARY_TYPE_LLVMIR_BITCODE
static constexpr pi_device_binary_type PI_DEVICE_BINARY_TYPE_LLVMIR_BITCODE
Definition: pi.h:883
_pi_plugin::FunctionPointers
Definition: pi.h:2715
PI_IMAGE_CHANNEL_ORDER_INTENSITY
@ PI_IMAGE_CHANNEL_ORDER_INTENSITY
Definition: pi.h:593
PI_MEM_FLAGS_HOST_PTR_COPY
constexpr pi_mem_flags PI_MEM_FLAGS_HOST_PTR_COPY
Definition: pi.h:700
PI_SAMPLER_ADDRESSING_MODE_REPEAT
@ PI_SAMPLER_ADDRESSING_MODE_REPEAT
Definition: pi.h:643
_pi_usm_type
_pi_usm_type
Definition: pi.h:1878
PI_SAMPLER_INFO_LOD_MIN
@ PI_SAMPLER_INFO_LOD_MIN
Definition: pi.h:637
piextMemUnsampledImageCreate
pi_result piextMemUnsampledImageCreate(pi_context context, pi_device device, pi_image_mem_handle img_mem, pi_image_format *image_format, pi_image_desc *image_desc, pi_mem *ret_mem, pi_image_handle *ret_handle)
API to create bindless image handles.
Definition: pi_cuda.cpp:377
_pi_image_format::image_channel_order
pi_image_channel_order image_channel_order
Definition: pi.h:1099
PI_PROPERTY_TYPE_STRING
@ PI_PROPERTY_TYPE_STRING
Definition: pi.h:848
piextCommandBufferMemBufferRead
pi_result piextCommandBufferMemBufferRead(pi_ext_command_buffer command_buffer, pi_mem buffer, size_t offset, size_t size, void *dst, pi_uint32 num_sync_points_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a mem buffer read command to the command-buffer.
Definition: pi_cuda.cpp:1096
PI_EXT_ONEAPI_CONTEXT_INFO_USM_MEMSET2D_SUPPORT
@ PI_EXT_ONEAPI_CONTEXT_INFO_USM_MEMSET2D_SUPPORT
Definition: pi.h:461
PI_MEM_ALLOC_SIZE
@ PI_MEM_ALLOC_SIZE
Definition: pi.h:1874
PI_DEVICE_INFO_PARTITION_AFFINITY_DOMAIN
@ PI_DEVICE_INFO_PARTITION_AFFINITY_DOMAIN
Definition: pi.h:360
piextProgramGetNativeHandle
pi_result piextProgramGetNativeHandle(pi_program program, pi_native_handle *nativeHandle)
Gets the native handle of a PI program object.
Definition: pi_cuda.cpp:322
PI_DEVICE_INFO_IMAGE_SRGB
@ PI_DEVICE_INFO_IMAGE_SRGB
Definition: pi.h:382
PI_EXT_PLATFORM_BACKEND_NATIVE_CPU
@ PI_EXT_PLATFORM_BACKEND_NATIVE_CPU
The backend is NATIVE_CPU.
Definition: pi.h:271
_pi_image_desc::image_type
pi_mem_type image_type
Definition: pi.h:1104
piProgramRetain
pi_result piProgramRetain(pi_program program)
Definition: pi_cuda.cpp:314
piextUSMEnqueueMemcpy2D
pi_result piextUSMEnqueueMemcpy2D(pi_queue queue, pi_bool blocking, void *dst_ptr, size_t dst_pitch, const void *src_ptr, size_t src_pitch, size_t width, size_t height, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
USM 2D Memcpy API.
Definition: pi_cuda.cpp:934
_pi_plugin
Definition: pi.h:2703
_pi_offload_entry_struct::addr
void * addr
Definition: pi.h:834
PI_PROGRAM_INFO_SOURCE
@ PI_PROGRAM_INFO_SOURCE
Definition: pi.h:441
PI_IMAGE_INFO_FORMAT
@ PI_IMAGE_INFO_FORMAT
Definition: pi.h:498
_pi_image_copy_flags
_pi_image_copy_flags
Definition: pi.h:619
_pi_device_local_mem_type
_pi_device_local_mem_type
Definition: pi.h:280
PI_DEVICE_INFO_GLOBAL_MEM_CACHE_TYPE
@ PI_DEVICE_INFO_GLOBAL_MEM_CACHE_TYPE
Definition: pi.h:326
piDevicePartition
pi_result piDevicePartition(pi_device device, const pi_device_partition_property *properties, pi_uint32 num_devices, pi_device *out_devices, pi_uint32 *out_num_devices)
Definition: pi_cuda.cpp:80
PI_KERNEL_COMPILE_NUM_SUB_GROUPS
@ PI_KERNEL_COMPILE_NUM_SUB_GROUPS
Definition: pi.h:510
_pi_device_mem_cache_type
_pi_device_mem_cache_type
Definition: pi.h:274
_pi_mem_advice
_pi_mem_advice
Definition: pi.h:567
PI_COMMAND_TYPE_SVM_UNMAP
@ PI_COMMAND_TYPE_SVM_UNMAP
Definition: pi.h:551
PI_DEVICE_INFO_MAX_WORK_ITEM_SIZES
@ PI_DEVICE_INFO_MAX_WORK_ITEM_SIZES
Definition: pi.h:290
piEnqueueMemBufferCopy
pi_result piEnqueueMemBufferCopy(pi_queue command_queue, pi_mem src_buffer, pi_mem dst_buffer, size_t src_offset, size_t dst_offset, size_t size, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:703
_pi_device_binary_property_set_struct::Name
char * Name
Definition: pi.h:866
PI_EXT_KERNEL_EXEC_INFO_CACHE_LARGE_DATA
@ PI_EXT_KERNEL_EXEC_INFO_CACHE_LARGE_DATA
Definition: pi.h:750
PI_DEVICE_INFO_MAX_COMPUTE_UNITS
@ PI_DEVICE_INFO_MAX_COMPUTE_UNITS
Definition: pi.h:288
_pi_device_binary_property_struct::Type
uint32_t Type
Definition: pi.h:858
sycl::_V1::info::event_command_status
event_command_status
Definition: info_desc.hpp:143
PI_MEM_ADVICE_CUDA_UNSET_PREFERRED_LOCATION
@ PI_MEM_ADVICE_CUDA_UNSET_PREFERRED_LOCATION
Definition: pi.h:573
pi_device_binary_struct::PropertySetsEnd
pi_device_binary_property_set PropertySetsEnd
Definition: pi.h:1002
PI_EVENT_INFO_CONTEXT
@ PI_EVENT_INFO_CONTEXT
Definition: pi.h:516
_pi_plugin::PluginVersion
char PluginVersion[20]
Definition: pi.h:2713
PI_DEVICE_INFO_GPU_HW_THREADS_PER_EU
@ PI_DEVICE_INFO_GPU_HW_THREADS_PER_EU
Definition: pi.h:398
pi_device_binary_struct::BinaryStart
const unsigned char * BinaryStart
Pointer to the target code start.
Definition: pi.h:993
piextUSMPitchedAlloc
pi_result piextUSMPitchedAlloc(void **result_ptr, size_t *result_pitch, pi_context context, pi_device device, pi_usm_mem_properties *properties, size_t width_in_bytes, size_t height, unsigned int element_size_bytes)
Allocates memory accessible on device.
Definition: pi_cuda.cpp:846
_pi_result
_pi_result
Definition: pi.h:205
PI_MEM_ADVICE_CUDA_UNSET_READ_MOSTLY
@ PI_MEM_ADVICE_CUDA_UNSET_READ_MOSTLY
Definition: pi.h:571
PI_PROFILING_INFO_COMMAND_QUEUED
@ PI_PROFILING_INFO_COMMAND_QUEUED
Definition: pi.h:684
pi_device_binary_struct::ManifestStart
const char * ManifestStart
Pointer to the manifest data start.
Definition: pi.h:989
piTearDown
pi_result piTearDown(void *PluginParameter)
API to notify that the plugin should clean up its resources.
Definition: pi_cuda.cpp:1154
PI_MEM_ADVICE_CUDA_UNSET_ACCESSED_BY_HOST
@ PI_MEM_ADVICE_CUDA_UNSET_ACCESSED_BY_HOST
Definition: pi.h:579
PI_MEM_ALLOC_INITIAL_PLACEMENT_DEVICE
constexpr pi_usm_mem_properties PI_MEM_ALLOC_INITIAL_PLACEMENT_DEVICE
Definition: pi.h:719
piextDestroyExternalSemaphore
pi_result piextDestroyExternalSemaphore(pi_context context, pi_device device, pi_interop_semaphore_handle sem_handle)
API to destroy the external semaphore handle.
Definition: pi_cuda.cpp:481
pi_context_properties
intptr_t pi_context_properties
Definition: pi.h:654
piEnqueueMemUnmap
pi_result piEnqueueMemUnmap(pi_queue command_queue, pi_mem memobj, void *mapped_ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:750
PI_IMAGE_COPY_DEVICE_TO_HOST
@ PI_IMAGE_COPY_DEVICE_TO_HOST
Definition: pi.h:621
PI_PROGRAM_BUILD_STATUS_IN_PROGRESS
@ PI_PROGRAM_BUILD_STATUS_IN_PROGRESS
Definition: pi.h:240
PI_SAMPLER_INFO_FILTER_MODE
@ PI_SAMPLER_INFO_FILTER_MODE
Definition: pi.h:635
PI_KERNEL_GROUP_INFO_WORK_GROUP_SIZE
@ PI_KERNEL_GROUP_INFO_WORK_GROUP_SIZE
Definition: pi.h:488
PI_IMAGE_CHANNEL_TYPE_SIGNED_INT8
@ PI_IMAGE_CHANNEL_TYPE_SIGNED_INT8
Definition: pi.h:609
PI_EXT_ONEAPI_QUEUE_FLAG_PRIORITY_HIGH
constexpr pi_queue_properties PI_EXT_ONEAPI_QUEUE_FLAG_PRIORITY_HIGH
Definition: pi.h:739
piPluginInit
pi_result piPluginInit(pi_plugin *plugin_info)
Definition: pi_cuda.cpp:1186
PI_MEM_ADVICE_CUDA_SET_PREFERRED_LOCATION_HOST
@ PI_MEM_ADVICE_CUDA_SET_PREFERRED_LOCATION_HOST
Definition: pi.h:576
piSamplerGetInfo
pi_result piSamplerGetInfo(pi_sampler sampler, pi_sampler_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:618
piPlatformGetInfo
pi_result piPlatformGetInfo(pi_platform platform, pi_platform_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:30
PI_DEVICE_INFO_GPU_SLICES
@ PI_DEVICE_INFO_GPU_SLICES
Definition: pi.h:378
PI_IMAGE_CHANNEL_ORDER_RG
@ PI_IMAGE_CHANNEL_ORDER_RG
Definition: pi.h:586
piDeviceRetain
pi_result piDeviceRetain(pi_device device)
Definition: pi_cuda.cpp:65
PI_IMAGE_INFO_SLICE_PITCH
@ PI_IMAGE_INFO_SLICE_PITCH
Definition: pi.h:501
PI_DEVICE_INFO_MAX_MEM_ALLOC_SIZE
@ PI_DEVICE_INFO_MAX_MEM_ALLOC_SIZE
Definition: pi.h:312
piProgramCompile
pi_result piProgramCompile(pi_program program, pi_uint32 num_devices, const pi_device *device_list, const char *options, pi_uint32 num_input_headers, const pi_program *input_headers, const char **header_include_names, void(*pfn_notify)(pi_program program, void *user_data), void *user_data)
_pi_device_type
_pi_device_type
Definition: pi.h:253
piContextGetInfo
pi_result piContextGetInfo(pi_context context, pi_context_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:119
piQueueRelease
pi_result piQueueRelease(pi_queue command_queue)
Definition: pi_cuda.cpp:177
PI_EXT_INTEL_DEVICE_INFO_MEMORY_CLOCK_RATE
@ PI_EXT_INTEL_DEVICE_INFO_MEMORY_CLOCK_RATE
Definition: pi.h:388
PI_DEVICE_INFO_REFERENCE_COUNT
@ PI_DEVICE_INFO_REFERENCE_COUNT
Definition: pi.h:346
PI_MEMORY_SCOPE_WORK_ITEM
constexpr pi_memory_scope_capabilities PI_MEMORY_SCOPE_WORK_ITEM
Definition: pi.h:677
PI_MEM_ADVICE_UNKNOWN
@ PI_MEM_ADVICE_UNKNOWN
Definition: pi.h:580
PI_DEVICE_INFO_USM_CROSS_SHARED_SUPPORT
@ PI_DEVICE_INFO_USM_CROSS_SHARED_SUPPORT
Definition: pi.h:368
pi_device_binaries_struct
This struct is a record of all the device code that may be offloaded.
Definition: pi.h:1058
pi_device_binary_struct::BinaryEnd
const unsigned char * BinaryEnd
Pointer to the target code end.
Definition: pi.h:995
PI_DEVICE_INFO_PLATFORM
@ PI_DEVICE_INFO_PLATFORM
Definition: pi.h:345
PI_COMMAND_TYPE_SVM_MAP
@ PI_COMMAND_TYPE_SVM_MAP
Definition: pi.h:550
PI_DEVICE_INFO_GPU_EU_COUNT_PER_SUBSLICE
@ PI_DEVICE_INFO_GPU_EU_COUNT_PER_SUBSLICE
Definition: pi.h:380
PI_MEM_SIZE
@ PI_MEM_SIZE
Definition: pi.h:1119
PI_PROPERTY_TYPE_UNKNOWN
@ PI_PROPERTY_TYPE_UNKNOWN
Definition: pi.h:845
PI_ACCESS_READ_ONLY
@ PI_ACCESS_READ_ONLY
Definition: pi.h:1819
PI_IMAGE_CHANNEL_ORDER_RGBx
@ PI_IMAGE_CHANNEL_ORDER_RGBx
Definition: pi.h:597
PI_DEVICE_LOCAL_MEM_TYPE_LOCAL
@ PI_DEVICE_LOCAL_MEM_TYPE_LOCAL
Definition: pi.h:281
PI_PROGRAM_BUILD_INFO_OPTIONS
@ PI_PROGRAM_BUILD_INFO_OPTIONS
Definition: pi.h:231
piextCommandBufferMemBufferWriteRect
pi_result piextCommandBufferMemBufferWriteRect(pi_ext_command_buffer command_buffer, pi_mem buffer, pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset, pi_buff_rect_region region, size_t buffer_row_pitch, size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch, const void *ptr, pi_uint32 num_events_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a rectangular mem buffer write command to the command-buffer.
Definition: pi_cuda.cpp:1127
PI_PROGRAM_BUILD_STATUS_SUCCESS
@ PI_PROGRAM_BUILD_STATUS_SUCCESS
Definition: pi.h:239
PI_EXT_CONTEXT_INFO_ATOMIC_MEMORY_SCOPE_CAPABILITIES
@ PI_EXT_CONTEXT_INFO_ATOMIC_MEMORY_SCOPE_CAPABILITIES
Definition: pi.h:456
PI_COMMAND_TYPE_NATIVE_KERNEL
@ PI_COMMAND_TYPE_NATIVE_KERNEL
Definition: pi.h:537
sycl::_V1::ext::intel::esimd::alignment
constexpr alignment_key::value_t< K > alignment
Definition: memory_properties.hpp:53
piextDeviceCreateWithNativeHandle
pi_result piextDeviceCreateWithNativeHandle(pi_native_handle nativeHandle, pi_platform platform, pi_device *device)
Creates PI device object from a native handle.
Definition: pi_cuda.cpp:101
PI_DEVICE_INFO_DEVICE_ID
@ PI_DEVICE_INFO_DEVICE_ID
Definition: pi.h:374
PI_CONTEXT_INFO_PLATFORM
@ PI_CONTEXT_INFO_PLATFORM
Definition: pi.h:450
piextWaitExternalSemaphore
pi_result piextWaitExternalSemaphore(pi_queue command_queue, pi_interop_semaphore_handle sem_handle, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
API to instruct the queue with a non-blocking wait on an external semaphore.
Definition: pi_cuda.cpp:486
piKernelGetSubGroupInfo
pi_result piKernelGetSubGroupInfo(pi_kernel kernel, pi_device device, pi_kernel_sub_group_info param_name, size_t input_value_size, const void *input_value, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
API to query information from the sub-group from a kernel.
Definition: pi_cuda.cpp:510
piextMemSampledImageCreate
pi_result piextMemSampledImageCreate(pi_context context, pi_device device, pi_image_mem_handle img_mem, pi_image_format *image_format, pi_image_desc *image_desc, pi_sampler sampler, pi_mem *ret_mem, pi_image_handle *ret_handle)
API to create sampled bindless image handles.
Definition: pi_cuda.cpp:385
PI_USM_INDIRECT_ACCESS
@ PI_USM_INDIRECT_ACCESS
indicates that the kernel might access data through USM ptrs
Definition: pi.h:1534
PI_IMAGE_CHANNEL_TYPE_SNORM_INT16
@ PI_IMAGE_CHANNEL_TYPE_SNORM_INT16
Definition: pi.h:603
PI_DEVICE_INFO_ADDRESS_BITS
@ PI_DEVICE_INFO_ADDRESS_BITS
Definition: pi.h:311
_PI_SANITIZE_TYPE_THREAD
@ _PI_SANITIZE_TYPE_THREAD
Definition: pi.h:2700
PI_EVENT_RUNNING
@ PI_EVENT_RUNNING
Definition: pi.h:215
_pi_image_desc::image_height
size_t image_height
Definition: pi.h:1106
_pi_platform
Definition: pi_cuda.hpp:44
PI_CONTEXT_INFO_NUM_DEVICES
@ PI_CONTEXT_INFO_NUM_DEVICES
Definition: pi.h:451
PI_DEVICE_TYPE_DEFAULT
@ PI_DEVICE_TYPE_DEFAULT
The default device available in the PI plugin.
Definition: pi.h:254
pi_ext_command_buffer_desc
Definition: pi.h:2268
PI_IMAGE_CHANNEL_ORDER_BGRA
@ PI_IMAGE_CHANNEL_ORDER_BGRA
Definition: pi.h:590
PI_KERNEL_GROUP_INFO_PREFERRED_WORK_GROUP_SIZE_MULTIPLE
@ PI_KERNEL_GROUP_INFO_PREFERRED_WORK_GROUP_SIZE_MULTIPLE
Definition: pi.h:491
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_DOUBLE
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_DOUBLE
Definition: pi.h:301
piextUSMEnqueueMemset2D
pi_result piextUSMEnqueueMemset2D(pi_queue queue, void *ptr, size_t pitch, int value, size_t width, size_t height, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
USM 2D Memset API.
Definition: pi_cuda.cpp:922
PI_DEVICE_INFO_MAX_SAMPLERS
@ PI_DEVICE_INFO_MAX_SAMPLERS
Definition: pi.h:323
pi_image_offset_struct::y
size_t y
Definition: pi.h:1038
PI_BIT
#define PI_BIT(_i)
Definition: pi.h:1813
PI_KERNEL_GROUP_INFO_LOCAL_MEM_SIZE
@ PI_KERNEL_GROUP_INFO_LOCAL_MEM_SIZE
Definition: pi.h:490
piEnqueueMemImageFill
pi_result piEnqueueMemImageFill(pi_queue command_queue, pi_mem image, const void *fill_color, const size_t *origin, const size_t *region, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:801
PI_DEVICE_INFO_MAX_NUM_SUB_GROUPS
@ PI_DEVICE_INFO_MAX_NUM_SUB_GROUPS
Definition: pi.h:362
_pi_usm_capability_query
_pi_usm_capability_query
Definition: pi.h:1856
PI_DEVICE_INFO_MEM_BASE_ADDR_ALIGN
@ PI_DEVICE_INFO_MEM_BASE_ADDR_ALIGN
Definition: pi.h:325
piSamplerCreate
pi_result piSamplerCreate(pi_context context, const pi_sampler_properties *sampler_properties, pi_sampler *result_sampler)
Definition: pi_cuda.cpp:612
piextEventCreateWithNativeHandle
pi_result piextEventCreateWithNativeHandle(pi_native_handle nativeHandle, pi_context context, bool ownNativeHandle, pi_event *event)
Creates PI event object from a native handle.
Definition: pi_cuda.cpp:604
PI_DEVICE_INFO_BUILT_IN_KERNELS
@ PI_DEVICE_INFO_BUILT_IN_KERNELS
Definition: pi.h:344
PI_PEER_ATOMICS_SUPPORTED
@ PI_PEER_ATOMICS_SUPPORTED
returns a uint32_t: 1 if Atomic operations are supported over the P2P link, otherwise such operations...
Definition: pi.h:1125
_pi_offload_entry_struct::size
size_t size
Definition: pi.h:836
_pi_sampler_addressing_mode
_pi_sampler_addressing_mode
Definition: pi.h:641
piKernelRelease
pi_result piKernelRelease(pi_kernel kernel)
Definition: pi_cuda.cpp:525
PI_DEVICE_INFO_USM_DEVICE_SUPPORT
@ PI_DEVICE_INFO_USM_DEVICE_SUPPORT
Definition: pi.h:366
PI_KERNEL_INFO_PROGRAM
@ PI_KERNEL_INFO_PROGRAM
Definition: pi.h:482
PI_COMMAND_TYPE_MAP_IMAGE
@ PI_COMMAND_TYPE_MAP_IMAGE
Definition: pi.h:540
PI_PLATFORM_INFO_NAME
@ PI_PLATFORM_INFO_NAME
Definition: pi.h:222
PI_FP_ROUND_TO_NEAREST
static constexpr pi_device_fp_config PI_FP_ROUND_TO_NEAREST
Definition: pi.h:819
piextUSMSharedAlloc
pi_result piextUSMSharedAlloc(void **result_ptr, pi_context context, pi_device device, pi_usm_mem_properties *properties, size_t size, pi_uint32 alignment)
Allocates memory accessible on both host and device.
Definition: pi_cuda.cpp:837
PI_DEVICE_INFO_IMAGE_MAX_ARRAY_SIZE
@ PI_DEVICE_INFO_IMAGE_MAX_ARRAY_SIZE
Definition: pi.h:322
_pi_image_desc::image_slice_pitch
size_t image_slice_pitch
Definition: pi.h:1110
_pi_plugin::SanitizeType
_pi_sanitize_type SanitizeType
Definition: pi.h:2720
_pi_device_info
_pi_device_info
Definition: pi.h:285
PI_MEM_TYPE_DEVICE
@ PI_MEM_TYPE_DEVICE
Definition: pi.h:1881
PI_USM_ATOMIC_ACCESS
@ PI_USM_ATOMIC_ACCESS
Definition: pi.h:1866
pi_image_region_struct::width
size_t width
Definition: pi.h:1046
PI_DEVICE_INFO_MAX_CONSTANT_BUFFER_SIZE
@ PI_DEVICE_INFO_MAX_CONSTANT_BUFFER_SIZE
Definition: pi.h:330
pi_image_offset_struct::x
size_t x
Definition: pi.h:1037
_pi_image_info
_pi_image_info
Definition: pi.h:497
piEventSetStatus
pi_result piEventSetStatus(pi_event event, pi_int32 execution_status)
Definition: pi_cuda.cpp:588
piextMemReleaseInterop
pi_result piextMemReleaseInterop(pi_context context, pi_device device, pi_interop_mem_handle memory_handle)
API to destroy interop memory.
Definition: pi_cuda.cpp:467
piextImportExternalSemaphoreOpaqueFD
pi_result piextImportExternalSemaphoreOpaqueFD(pi_context context, pi_device device, int file_descriptor, pi_interop_semaphore_handle *ret_handle)
API to import an external semaphore in the form of a file descriptor.
Definition: pi_cuda.cpp:473
PI_IMAGE_COPY_DEVICE_TO_DEVICE
@ PI_IMAGE_COPY_DEVICE_TO_DEVICE
Definition: pi.h:622
piextUSMDeviceAlloc
pi_result piextUSMDeviceAlloc(void **result_ptr, pi_context context, pi_device device, pi_usm_mem_properties *properties, size_t size, pi_uint32 alignment)
Allocates device memory.
Definition: pi_cuda.cpp:828
sycl::_V1::ext::intel::host_ptr
multi_ptr< ElementType, access::address_space::ext_intel_global_host_space, IsDecorated > host_ptr
Definition: usm_pointers.hpp:33
PI_SAMPLER_PROPERTIES_ADDRESSING_MODE
constexpr pi_sampler_properties PI_SAMPLER_PROPERTIES_ADDRESSING_MODE
Definition: pi.h:665
PI_COMMAND_TYPE_DEVICE_GLOBAL_VARIABLE_WRITE
@ PI_COMMAND_TYPE_DEVICE_GLOBAL_VARIABLE_WRITE
Definition: pi.h:554
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_INT
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_INT
Definition: pi.h:298
PI_SAMPLER_FILTER_MODE_NEAREST
@ PI_SAMPLER_FILTER_MODE_NEAREST
Definition: pi.h:650
_pi_kernel
Definition: pi_cuda.hpp:72
PI_DEVICE_INFO_ERROR_CORRECTION_SUPPORT
@ PI_DEVICE_INFO_ERROR_CORRECTION_SUPPORT
Definition: pi.h:334
PI_DEVICE_MEM_CACHE_TYPE_NONE
@ PI_DEVICE_MEM_CACHE_TYPE_NONE
Definition: pi.h:275
piextDeviceGetNativeHandle
pi_result piextDeviceGetNativeHandle(pi_device device, pi_native_handle *nativeHandle)
Gets the native handle of a PI device object.
Definition: pi_cuda.cpp:95
PI_DEVICE_INFO_IMAGE2D_MAX_HEIGHT
@ PI_DEVICE_INFO_IMAGE2D_MAX_HEIGHT
Definition: pi.h:317
PI_PROGRAM_BINARY_TYPE_NONE
@ PI_PROGRAM_BINARY_TYPE_NONE
Definition: pi.h:244
piextCommandBufferCreate
pi_result piextCommandBufferCreate(pi_context context, pi_device device, const pi_ext_command_buffer_desc *desc, pi_ext_command_buffer *ret_command_buffer)
API to create a command-buffer.
Definition: pi_cuda.cpp:1036
pi_buff_rect_offset_struct::y_scalar
size_t y_scalar
Definition: pi.h:1020
PI_EVENT_INFO_COMMAND_TYPE
@ PI_EVENT_INFO_COMMAND_TYPE
Definition: pi.h:517
piextContextCreateWithNativeHandle
pi_result piextContextCreateWithNativeHandle(pi_native_handle nativeHandle, pi_uint32 numDevices, const pi_device *devices, bool pluginOwnsNativeHandle, pi_context *context)
Creates PI context object from a native handle.
Definition: pi_cuda.cpp:138
PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_SUPPORT
Definition: pi.h:416
piProgramGetInfo
pi_result piProgramGetInfo(pi_program program, pi_program_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:266
_pi_plugin::PiVersion
char PiVersion[20]
Definition: pi.h:2711
PI_DEVICE_INFO_GLOBAL_MEM_CACHE_SIZE
@ PI_DEVICE_INFO_GLOBAL_MEM_CACHE_SIZE
Definition: pi.h:328
PI_DEVICE_EXEC_CAPABILITIES_KERNEL
constexpr pi_device_exec_capabilities PI_DEVICE_EXEC_CAPABILITIES_KERNEL
Definition: pi.h:657
piextEnqueueWriteHostPipe
pi_result piextEnqueueWriteHostPipe(pi_queue queue, pi_program program, const char *pipe_symbol, pi_bool blocking, void *ptr, size_t size, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
Write to pipe of a given name.
Definition: pi_cuda.cpp:1001
PI_COMMAND_TYPE_BARRIER
@ PI_COMMAND_TYPE_BARRIER
Definition: pi.h:544
PI_EXT_ONEAPI_CONTEXT_INFO_USM_MEMCPY2D_SUPPORT
@ PI_EXT_ONEAPI_CONTEXT_INFO_USM_MEMCPY2D_SUPPORT
Definition: pi.h:462
piextMemSampledImageHandleDestroy
pi_result piextMemSampledImageHandleDestroy(pi_context context, pi_device device, pi_image_handle handle)
API to destroy bindless sampled image handles.
Definition: pi_cuda.cpp:439
_pi_ext_command_buffer
Definition: pi_cuda.hpp:80
PI_CONTEXT_INFO_DEVICES
@ PI_CONTEXT_INFO_DEVICES
Definition: pi.h:449
_pi_device_binary_property_set_struct::PropertiesBegin
pi_device_binary_property PropertiesBegin
Definition: pi.h:867
_pi_sampler_filter_mode
_pi_sampler_filter_mode
Definition: pi.h:649
piextSignalExternalSemaphore
pi_result piextSignalExternalSemaphore(pi_queue command_queue, pi_interop_semaphore_handle sem_handle, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
API to instruct the queue to signal the external semaphore handle once all previous commands have com...
Definition: pi_cuda.cpp:494
PI_EXT_DEVICE_INFO_ATOMIC_MEMORY_SCOPE_CAPABILITIES
@ PI_EXT_DEVICE_INFO_ATOMIC_MEMORY_SCOPE_CAPABILITIES
Definition: pi.h:397
_pi_queue_info
_pi_queue_info
Definition: pi.h:465
piextCommandBufferRetain
pi_result piextCommandBufferRetain(pi_ext_command_buffer command_buffer)
API to increment the reference count of the command-buffer.
Definition: pi_cuda.cpp:1043
pi_buff_rect_region_struct::width_bytes
size_t width_bytes
Definition: pi.h:1028
_pi_buffer_create_type
_pi_buffer_create_type
Definition: pi.h:625
piextMemUnsampledImageHandleDestroy
pi_result piextMemUnsampledImageHandleDestroy(pi_context context, pi_device device, pi_image_handle handle)
API to destroy bindless unsampled image handles.
Definition: pi_cuda.cpp:434
piextQueueCreateWithNativeHandle
pi_result piextQueueCreateWithNativeHandle(pi_native_handle nativeHandle, int32_t nativeHandleDesc, pi_context context, pi_device device, bool pluginOwnsNativeHandle, pi_queue_properties *Properties, pi_queue *queue)
Creates PI queue object from a native handle.
Definition: pi_cuda.cpp:193
PI_MEM_ACCESS_READ_ONLY
constexpr pi_mem_flags PI_MEM_ACCESS_READ_ONLY
Definition: pi.h:697
piextUSMEnqueueMemcpy
pi_result piextUSMEnqueueMemcpy(pi_queue queue, pi_bool blocking, void *dst_ptr, const void *src_ptr, size_t size, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
USM Memcpy API.
Definition: pi_cuda.cpp:881
piMemBufferPartition
pi_result piMemBufferPartition(pi_mem buffer, pi_mem_flags flags, pi_buffer_create_type buffer_create_type, void *buffer_create_info, pi_mem *ret_mem)
Definition: pi_cuda.cpp:813
PI_MEM_ALLOC_DEVICE_READ_ONLY
constexpr pi_usm_mem_properties PI_MEM_ALLOC_DEVICE_READ_ONLY
Definition: pi.h:723
PI_PROGRAM_BINARY_TYPE_EXECUTABLE
@ PI_PROGRAM_BINARY_TYPE_EXECUTABLE
Definition: pi.h:247
PI_EXT_QUEUE_FLAG_SUBMISSION_NO_IMMEDIATE
constexpr pi_queue_properties PI_EXT_QUEUE_FLAG_SUBMISSION_NO_IMMEDIATE
Definition: pi.h:740
export.hpp
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_HALF
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_HALF
Definition: pi.h:309
piextUSMEnqueueMemAdvise
pi_result piextUSMEnqueueMemAdvise(pi_queue queue, const void *ptr, size_t length, pi_mem_advice advice, pi_event *event)
USM Memadvise API.
Definition: pi_cuda.cpp:902
piextMemImportOpaqueFD
pi_result piextMemImportOpaqueFD(pi_context context, pi_device device, size_t size, int file_descriptor, pi_interop_mem_handle *ret_handle)
API to import external memory in the form of a file descriptor.
Definition: pi_cuda.cpp:453
pi_device_binary_type
uint8_t pi_device_binary_type
Types of device binary.
Definition: pi.h:874
PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_SEMAPHORE_EXPORT_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_SEMAPHORE_EXPORT_SUPPORT
Definition: pi.h:431
PI_DEVICE_BINARY_OFFLOAD_KIND_SYCL
static const uint8_t PI_DEVICE_BINARY_OFFLOAD_KIND_SYCL
Definition: pi.h:889
piQueueCreate
pi_result piQueueCreate(pi_context context, pi_device device, pi_queue_properties properties, pi_queue *queue)
Definition: pi_cuda.cpp:156
PI_DEVICE_INFO_IMAGE_MAX_BUFFER_SIZE
@ PI_DEVICE_INFO_IMAGE_MAX_BUFFER_SIZE
Definition: pi.h:321
PI_DEVICE_INFO_LOCAL_MEM_SIZE
@ PI_DEVICE_INFO_LOCAL_MEM_SIZE
Definition: pi.h:333
PI_MEMORY_ORDER_RELAXED
constexpr pi_memory_order_capabilities PI_MEMORY_ORDER_RELAXED
Definition: pi.h:670
piextCommandBufferMemBufferWrite
pi_result piextCommandBufferMemBufferWrite(pi_ext_command_buffer command_buffer, pi_mem buffer, size_t offset, size_t size, const void *ptr, pi_uint32 num_events_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a mem buffer write command to the command-buffer.
Definition: pi_cuda.cpp:1118
PI_DEVICE_AFFINITY_DOMAIN_L3_CACHE
static constexpr pi_device_affinity_domain PI_DEVICE_AFFINITY_DOMAIN_L3_CACHE
Definition: pi.h:806
PI_IMAGE_CHANNEL_ORDER_LUMINANCE
@ PI_IMAGE_CHANNEL_ORDER_LUMINANCE
Definition: pi.h:594
piextProgramCreateWithNativeHandle
pi_result piextProgramCreateWithNativeHandle(pi_native_handle nativeHandle, pi_context context, bool pluginOwnsNativeHandle, pi_program *program)
Creates PI program object from a native handle.
Definition: pi_cuda.cpp:327
PI_DEVICE_LOCAL_MEM_TYPE_GLOBAL
@ PI_DEVICE_LOCAL_MEM_TYPE_GLOBAL
Definition: pi.h:282
piEventsWait
pi_result piEventsWait(pi_uint32 num_events, const pi_event *event_list)
Definition: pi_cuda.cpp:575
PI_EXT_ONEAPI_DEVICE_INFO_BFLOAT16_MATH_FUNCTIONS
@ PI_EXT_ONEAPI_DEVICE_INFO_BFLOAT16_MATH_FUNCTIONS
Definition: pi.h:401
piContextRelease
pi_result piContextRelease(pi_context context)
Definition: pi_cuda.cpp:152
PI_USM_MIGRATION_TBD0
@ PI_USM_MIGRATION_TBD0
Definition: pi.h:1889
_pi_queue
Definition: pi_cuda.hpp:60
PI_MEM_ADVICE_CUDA_SET_ACCESSED_BY
@ PI_MEM_ADVICE_CUDA_SET_ACCESSED_BY
Definition: pi.h:574
PI_MEM_ALLOC_INITIAL_PLACEMENT_HOST
constexpr pi_usm_mem_properties PI_MEM_ALLOC_INITIAL_PLACEMENT_HOST
Definition: pi.h:721
piProgramRelease
pi_result piProgramRelease(pi_program program)
Definition: pi_cuda.cpp:318
PI_MEM_ADVICE_CUDA_SET_PREFERRED_LOCATION
@ PI_MEM_ADVICE_CUDA_SET_PREFERRED_LOCATION
Definition: pi.h:572
PI_IMAGE_CHANNEL_TYPE_SIGNED_INT16
@ PI_IMAGE_CHANNEL_TYPE_SIGNED_INT16
Definition: pi.h:610
_pi_device_binary_property_struct::ValAddr
void * ValAddr
Definition: pi.h:857
PI_IMAGE_CHANNEL_TYPE_SIGNED_INT32
@ PI_IMAGE_CHANNEL_TYPE_SIGNED_INT32
Definition: pi.h:611
pi_image_region_struct::depth
size_t depth
Definition: pi.h:1048
pi_device_binaries_struct::HostEntriesBegin
_pi_offload_entry * HostEntriesBegin
the offload entry table (not used, for compatibility with OpenMP)
Definition: pi.h:1068
PI_EXEC_KERNEL
static constexpr pi_device_exec_capabilities PI_EXEC_KERNEL
Definition: pi.h:829
PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_SEMAPHORE_IMPORT_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_SEMAPHORE_IMPORT_SUPPORT
Definition: pi.h:430
PI_EXT_QUEUE_FLAG_SUBMISSION_IMMEDIATE
constexpr pi_queue_properties PI_EXT_QUEUE_FLAG_SUBMISSION_IMMEDIATE
Definition: pi.h:741
PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_MAX_ANISOTROPY
@ PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_MAX_ANISOTROPY
Definition: pi.h:426
PI_FALSE
const pi_bool PI_FALSE
Definition: pi.h:628
PI_ACCESS_READ_WRITE
@ PI_ACCESS_READ_WRITE
Definition: pi.h:1817
PI_MAP_READ
constexpr pi_map_flags PI_MAP_READ
Definition: pi.h:705
PI_DEVICE_TYPE_GPU
@ PI_DEVICE_TYPE_GPU
A PI device that is a GPU.
Definition: pi.h:258
pi_uint32
uint32_t pi_uint32
Definition: pi.h:194
_pi_image_desc::image_depth
size_t image_depth
Definition: pi.h:1107
PI_COMMAND_TYPE_MEM_BUFFER_READ_RECT
@ PI_COMMAND_TYPE_MEM_BUFFER_READ_RECT
Definition: pi.h:529
piEnqueueMemBufferReadRect
pi_result piEnqueueMemBufferReadRect(pi_queue command_queue, pi_mem buffer, pi_bool blocking_read, pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset, pi_buff_rect_region region, size_t buffer_row_pitch, size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch, void *ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:663
pi_buff_rect_region_struct
Definition: pi.h:1027
piMemRelease
pi_result piMemRelease(pi_mem mem)
Definition: pi_cuda.cpp:220
pi_device_binary_struct
This struct is a record of the device binary information.
Definition: pi.h:961
piEnqueueMemBufferCopyRect
pi_result piEnqueueMemBufferCopyRect(pi_queue command_queue, pi_mem src_buffer, pi_mem dst_buffer, pi_buff_rect_offset src_origin, pi_buff_rect_offset dst_origin, pi_buff_rect_region region, size_t src_row_pitch, size_t src_slice_pitch, size_t dst_row_pitch, size_t dst_slice_pitch, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:714
piextContextSetExtendedDeleter
pi_result piextContextSetExtendedDeleter(pi_context context, pi_context_extended_deleter func, void *user_data)
Definition: pi_cuda.cpp:127
pi_interop_mem_handle
pi_uint64 pi_interop_mem_handle
Definition: pi.h:1095
PI_DEVICE_INFO_LINKER_AVAILABLE
@ PI_DEVICE_INFO_LINKER_AVAILABLE
Definition: pi.h:340
PI_DEVICE_INFO_EXECUTION_CAPABILITIES
@ PI_DEVICE_INFO_EXECUTION_CAPABILITIES
Definition: pi.h:341
_pi_mem_obj_property::type
pi_mem_obj_property_type type
Definition: pi.h:1831
PI_DEVICE_INFO_PROFILING_TIMER_RESOLUTION
@ PI_DEVICE_INFO_PROFILING_TIMER_RESOLUTION
Definition: pi.h:336
pi_device_binary_struct::LinkOptions
const char * LinkOptions
a null-terminated string; target- and compiler-specific options which are suggested to use to "link" ...
Definition: pi.h:987
_pi_kernel_exec_info
_pi_kernel_exec_info
Definition: pi.h:1532
PI_EXT_ONEAPI_QUEUE_FLAG_DISCARD_EVENTS
constexpr pi_queue_properties PI_EXT_ONEAPI_QUEUE_FLAG_DISCARD_EVENTS
Definition: pi.h:737
PI_PEER_ACCESS_SUPPORTED
@ PI_PEER_ACCESS_SUPPORTED
returns a uint32_t: 1 if P2P Access is supported otherwise P2P Access is not supported.
Definition: pi.h:1122
PI_MEM_TYPE_IMAGE2D
@ PI_MEM_TYPE_IMAGE2D
Definition: pi.h:559
PI_EXT_KERNEL_EXEC_INFO_CACHE_CONFIG
@ PI_EXT_KERNEL_EXEC_INFO_CACHE_CONFIG
provides the preferred cache configuration (large slm or large data)
Definition: pi.h:1538
PI_COMMAND_TYPE_IMAGE_COPY
@ PI_COMMAND_TYPE_IMAGE_COPY
Definition: pi.h:536
PI_FP_SOFT_FLOAT
static constexpr pi_device_fp_config PI_FP_SOFT_FLOAT
Definition: pi.h:823
piextPeerAccessGetInfo
pi_result piextPeerAccessGetInfo(pi_device command_device, pi_device peer_device, pi_peer_attr attr, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:1175
PI_KERNEL_INFO_CONTEXT
@ PI_KERNEL_INFO_CONTEXT
Definition: pi.h:481
piEnqueueMemBufferWrite
pi_result piEnqueueMemBufferWrite(pi_queue command_queue, pi_mem buffer, pi_bool blocking_write, size_t offset, size_t size, const void *ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:677
PI_PROGRAM_BUILD_INFO_STATUS
@ PI_PROGRAM_BUILD_INFO_STATUS
Definition: pi.h:230
PI_DEVICE_MEM_CACHE_TYPE_READ_ONLY_CACHE
@ PI_DEVICE_MEM_CACHE_TYPE_READ_ONLY_CACHE
Definition: pi.h:276
pi_device_binaries_struct::NumDeviceBinaries
uint16_t NumDeviceBinaries
Number of device binaries in this descriptor.
Definition: pi.h:1064
piProgramCreateWithBinary
pi_result piProgramCreateWithBinary(pi_context context, pi_uint32 num_devices, const pi_device *device_list, const size_t *lengths, const unsigned char **binaries, size_t num_metadata_entries, const pi_device_binary_property *metadata, pi_int32 *binary_status, pi_program *ret_program)
Creates a PI program for a context and loads the given binary into it.
Definition: pi_cuda.cpp:247
piKernelSetExecInfo
pi_result piKernelSetExecInfo(pi_kernel kernel, pi_kernel_exec_info value_name, size_t param_value_size, const void *param_value)
API to set attributes controlling kernel execution.
Definition: pi_cuda.cpp:1021
PI_DEVICE_INFO_HALF_FP_CONFIG
@ PI_DEVICE_INFO_HALF_FP_CONFIG
Definition: pi.h:293
PI_EXT_PLATFORM_BACKEND_UNKNOWN
@ PI_EXT_PLATFORM_BACKEND_UNKNOWN
The backend is not a recognized one.
Definition: pi.h:265
PI_MEMORY_SCOPE_DEVICE
constexpr pi_memory_scope_capabilities PI_MEMORY_SCOPE_DEVICE
Definition: pi.h:680
PI_DEVICE_BINARY_TYPE_NATIVE
static constexpr pi_device_binary_type PI_DEVICE_BINARY_TYPE_NATIVE
Definition: pi.h:878
PI_IMAGE_CHANNEL_ORDER_R
@ PI_IMAGE_CHANNEL_ORDER_R
Definition: pi.h:585
PI_FP_DENORM
static constexpr pi_device_fp_config PI_FP_DENORM
Definition: pi.h:817
piextCommandBufferRelease
pi_result piextCommandBufferRelease(pi_ext_command_buffer command_buffer)
API to decrement the reference count of the command-buffer.
Definition: pi_cuda.cpp:1047
pi_mem_flags
pi_bitfield pi_mem_flags
Definition: pi.h:694
PI_MEMORY_SCOPE_SYSTEM
constexpr pi_memory_scope_capabilities PI_MEMORY_SCOPE_SYSTEM
Definition: pi.h:681
_pi_event_status
_pi_event_status
Definition: pi.h:213
piKernelGetGroupInfo
pi_result piKernelGetGroupInfo(pi_kernel kernel, pi_device device, pi_kernel_group_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:502
_pi_image_channel_order
_pi_image_channel_order
Definition: pi.h:583
PI_IMAGE_CHANNEL_TYPE_FLOAT
@ PI_IMAGE_CHANNEL_TYPE_FLOAT
Definition: pi.h:616
piEnqueueMemImageRead
pi_result piEnqueueMemImageRead(pi_queue command_queue, pi_mem image, pi_bool blocking_read, pi_image_offset origin, pi_image_region region, size_t row_pitch, size_t slice_pitch, void *ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:766
PI_USM_CONCURRENT_ACCESS
@ PI_USM_CONCURRENT_ACCESS
Definition: pi.h:1867
PI_COMMAND_TYPE_SVM_MEMCPY
@ PI_COMMAND_TYPE_SVM_MEMCPY
Definition: pi.h:548
pi_property_type
pi_property_type
Definition: pi.h:844
PI_MEM_TYPE_SHARED
@ PI_MEM_TYPE_SHARED
Definition: pi.h:1882
PI_DEVICE_INFO_VENDOR
@ PI_DEVICE_INFO_VENDOR
Definition: pi.h:349
pi_context_extended_deleter
void(* pi_context_extended_deleter)(void *user_data)
Definition: pi.h:1273
PI_MEM_TYPE_IMAGE1D_ARRAY
@ PI_MEM_TYPE_IMAGE1D_ARRAY
Definition: pi.h:563
PI_EXT_CODEPLAY_DEVICE_INFO_MAX_REGISTERS_PER_WORK_GROUP
@ PI_EXT_CODEPLAY_DEVICE_INFO_MAX_REGISTERS_PER_WORK_GROUP
Definition: pi.h:412
pi_device_binary_struct::Format
uint8_t Format
format of the binary data - SPIR-V, LLVM IR bitcode,...
Definition: pi.h:969
PI_KERNEL_ARG_MEM_OBJ_ACCESS
@ PI_KERNEL_ARG_MEM_OBJ_ACCESS
Definition: pi.h:1825
PI_DEVICE_INFO_QUEUE_ON_DEVICE_PROPERTIES
@ PI_DEVICE_INFO_QUEUE_ON_DEVICE_PROPERTIES
Definition: pi.h:342
PI_PROPERTY_TYPE_BYTE_ARRAY
@ PI_PROPERTY_TYPE_BYTE_ARRAY
Definition: pi.h:847
PI_DEVICE_TYPE_ACC
@ PI_DEVICE_TYPE_ACC
A PI device that is a dedicated accelerator.
Definition: pi.h:259
PI_KERNEL_GROUP_INFO_NUM_REGS
@ PI_KERNEL_GROUP_INFO_NUM_REGS
Definition: pi.h:494
PI_MEMORY_SCOPE_SUB_GROUP
constexpr pi_memory_scope_capabilities PI_MEMORY_SCOPE_SUB_GROUP
Definition: pi.h:678
PI_KERNEL_MAX_SUB_GROUP_SIZE
@ PI_KERNEL_MAX_SUB_GROUP_SIZE
Definition: pi.h:508
PI_IMAGE_INFO_DEPTH
@ PI_IMAGE_INFO_DEPTH
Definition: pi.h:504
piQueueRetain
pi_result piQueueRetain(pi_queue command_queue)
Definition: pi_cuda.cpp:175
_pi_mem_obj_property_type
_pi_mem_obj_property_type
Definition: pi.h:1824
PI_DEVICE_INFO_USM_SYSTEM_SHARED_SUPPORT
@ PI_DEVICE_INFO_USM_SYSTEM_SHARED_SUPPORT
Definition: pi.h:369
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_SHORT
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_SHORT
Definition: pi.h:297
PI_MEMORY_ORDER_SEQ_CST
constexpr pi_memory_order_capabilities PI_MEMORY_ORDER_SEQ_CST
Definition: pi.h:674
PI_MEM_TYPE_BUFFER
@ PI_MEM_TYPE_BUFFER
Definition: pi.h:558
piEnqueueEventsWaitWithBarrier
pi_result piEnqueueEventsWaitWithBarrier(pi_queue command_queue, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:642
PI_EXT_ONEAPI_DEVICE_INFO_MATRIX_COMBINATIONS
@ PI_EXT_ONEAPI_DEVICE_INFO_MATRIX_COMBINATIONS
Definition: pi.h:433
PI_SAMPLER_INFO_CONTEXT
@ PI_SAMPLER_INFO_CONTEXT
Definition: pi.h:632
_pi_program_binary_type
_pi_program_binary_type
Definition: pi.h:243
piKernelRetain
pi_result piKernelRetain(pi_kernel kernel)
Definition: pi_cuda.cpp:520
piDeviceGetInfo
pi_result piDeviceGetInfo(pi_device device, pi_device_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Returns requested info for provided native device Return PI_DEVICE_INFO_EXTENSION_DEVICELIB_ASSERT fo...
Definition: pi_cuda.cpp:73
piEventSetCallback
pi_result piEventSetCallback(pi_event event, pi_int32 command_exec_callback_type, void(*pfn_notify)(pi_event event, pi_int32 event_command_status, void *user_data), void *user_data)
PI_EXT_CODEPLAY_DEVICE_INFO_SUPPORTS_FUSION
@ PI_EXT_CODEPLAY_DEVICE_INFO_SUPPORTS_FUSION
Definition: pi.h:407
PI_DEVICE_INFO_GLOBAL_MEM_CACHELINE_SIZE
@ PI_DEVICE_INFO_GLOBAL_MEM_CACHELINE_SIZE
Definition: pi.h:327
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_LONG
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_LONG
Definition: pi.h:306
pi_device_binary_struct::Kind
uint8_t Kind
the type of offload model the binary employs; must be 4 for SYCL
Definition: pi.h:967
PI_MEMORY_ORDER_RELEASE
constexpr pi_memory_order_capabilities PI_MEMORY_ORDER_RELEASE
Definition: pi.h:672
piEnqueueMemBufferFill
pi_result piEnqueueMemBufferFill(pi_queue command_queue, pi_mem buffer, const void *pattern, size_t pattern_size, size_t offset, size_t size, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:727
piextMemImageAllocate
pi_result piextMemImageAllocate(pi_context context, pi_device device, pi_image_format *image_format, pi_image_desc *image_desc, pi_image_mem_handle *ret_mem)
API to allocate memory for bindless images.
Definition: pi_cuda.cpp:368
pi_ext_sync_point
pi_uint32 pi_ext_sync_point
Definition: pi.h:2262
PI_DEVICE_INFO_USM_HOST_SUPPORT
@ PI_DEVICE_INFO_USM_HOST_SUPPORT
Definition: pi.h:365
piSamplerRetain
pi_result piSamplerRetain(pi_sampler sampler)
Definition: pi_cuda.cpp:626
PI_EXT_INTEL_DEVICE_PARTITION_BY_CSLICE
static constexpr pi_device_partition_property PI_EXT_INTEL_DEVICE_PARTITION_BY_CSLICE
Definition: pi.h:798
piextPluginGetOpaqueData
pi_result piextPluginGetOpaqueData(void *opaque_data_param, void **opaque_data_return)
API to get Plugin internal data, opaque to SYCL RT.
Definition: pi_cuda.cpp:1149
PI_EXT_CONTEXT_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES
@ PI_EXT_CONTEXT_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES
Definition: pi.h:458
piMemImageGetInfo
pi_result piMemImageGetInfo(pi_mem image, pi_image_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:758
piextDisablePeerAccess
pi_result piextDisablePeerAccess(pi_device command_device, pi_device peer_device)
Definition: pi_cuda.cpp:1169
pi_device_binary_property_set
_pi_device_binary_property_set_struct * pi_device_binary_property_set
Definition: pi.h:871
PI_MEM_ADVICE_CUDA_SET_READ_MOSTLY
@ PI_MEM_ADVICE_CUDA_SET_READ_MOSTLY
Definition: pi.h:570
PI_MEM_FLAGS_HOST_PTR_USE
constexpr pi_mem_flags PI_MEM_FLAGS_HOST_PTR_USE
Definition: pi.h:699
PI_SAMPLER_PROPERTIES_MIP_FILTER_MODE
constexpr pi_sampler_properties PI_SAMPLER_PROPERTIES_MIP_FILTER_MODE
Definition: pi.h:667
piextEventGetNativeHandle
pi_result piextEventGetNativeHandle(pi_event event, pi_native_handle *nativeHandle)
Gets the native handle of a PI event object.
Definition: pi_cuda.cpp:598
PI_EXT_KERNEL_EXEC_INFO_CACHE_DEFAULT
@ PI_EXT_KERNEL_EXEC_INFO_CACHE_DEFAULT
Definition: pi.h:746
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_FLOAT
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_FLOAT
Definition: pi.h:307
PI_PROGRAM_INFO_REFERENCE_COUNT
@ PI_PROGRAM_INFO_REFERENCE_COUNT
Definition: pi.h:437
PI_IMAGE_CHANNEL_ORDER_sRGBA
@ PI_IMAGE_CHANNEL_ORDER_sRGBA
Definition: pi.h:598
PI_EXT_ONEAPI_DEVICE_INFO_IMAGE_PITCH_ALIGN
@ PI_EXT_ONEAPI_DEVICE_INFO_IMAGE_PITCH_ALIGN
Definition: pi.h:420
PI_DEVICE_PARTITION_BY_AFFINITY_DOMAIN
static constexpr pi_device_partition_property PI_DEVICE_PARTITION_BY_AFFINITY_DOMAIN
Definition: pi.h:796
piextPlatformCreateWithNativeHandle
pi_result piextPlatformCreateWithNativeHandle(pi_native_handle nativeHandle, pi_platform *platform)
Creates PI platform object from a native handle.
Definition: pi_cuda.cpp:42
PI_MEM_TYPE_UNKNOWN
@ PI_MEM_TYPE_UNKNOWN
Definition: pi.h:1879
PI_DEVICE_INFO_PARENT_DEVICE
@ PI_DEVICE_INFO_PARENT_DEVICE
Definition: pi.h:357
PI_PLATFORM_INFO_VERSION
@ PI_PLATFORM_INFO_VERSION
Definition: pi.h:225
_pi_image_desc::buffer
pi_mem buffer
Definition: pi.h:1113
PI_IMAGE_CHANNEL_TYPE_UNSIGNED_INT16
@ PI_IMAGE_CHANNEL_TYPE_UNSIGNED_INT16
Definition: pi.h:613
PI_FP_ROUND_TO_INF
static constexpr pi_device_fp_config PI_FP_ROUND_TO_INF
Definition: pi.h:821
pi_uint64
uint64_t pi_uint64
Definition: pi.h:195
piextMemMipmapGetLevel
pi_result piextMemMipmapGetLevel(pi_context context, pi_device device, pi_image_mem_handle mip_mem, unsigned int level, pi_image_mem_handle *ret_mem)
API to retrieve individual image from mipmap.
Definition: pi_cuda.cpp:403
PI_COMMAND_TYPE_MEM_BUFFER_WRITE
@ PI_COMMAND_TYPE_MEM_BUFFER_WRITE
Definition: pi.h:525
PI_DEVICE_INFO_PARTITION_TYPE
@ PI_DEVICE_INFO_PARTITION_TYPE
Definition: pi.h:361
PI_COMMAND_TYPE_MEM_BUFFER_COPY
@ PI_COMMAND_TYPE_MEM_BUFFER_COPY
Definition: pi.h:526
_pi_event_info
_pi_event_info
Definition: pi.h:514
PI_MEM_PROPERTIES_ALLOC_BUFFER_LOCATION
constexpr pi_mem_properties PI_MEM_PROPERTIES_ALLOC_BUFFER_LOCATION
Definition: pi.h:712
pi_memory_scope_capabilities
pi_bitfield pi_memory_scope_capabilities
Definition: pi.h:676
piextUSMHostAlloc
pi_result piextUSMHostAlloc(void **result_ptr, pi_context context, pi_usm_mem_properties *properties, size_t size, pi_uint32 alignment)
Allocates host memory accessible by the device.
Definition: pi_cuda.cpp:856
PI_IMAGE_INFO_WIDTH
@ PI_IMAGE_INFO_WIDTH
Definition: pi.h:502
_pi_sampler_info
_pi_sampler_info
Definition: pi.h:630
PI_EXT_PLATFORM_BACKEND_CUDA
@ PI_EXT_PLATFORM_BACKEND_CUDA
The backend is CUDA.
Definition: pi.h:268
_pi_device_binary_property_struct
Definition: pi.h:855
pi_mem_properties
pi_bitfield pi_mem_properties
Definition: pi.h:710
pi_device_exec_capabilities
pi_bitfield pi_device_exec_capabilities
Definition: pi.h:656
_pi_program
Definition: pi_cuda.hpp:68
PI_QUEUE_INFO_DEVICE
@ PI_QUEUE_INFO_DEVICE
Definition: pi.h:467
PI_PROGRAM_BUILD_STATUS_ERROR
@ PI_PROGRAM_BUILD_STATUS_ERROR
Definition: pi.h:238
_pi_sampler
Definition: pi_cuda.hpp:76
PI_IMAGE_COPY_HOST_TO_DEVICE
@ PI_IMAGE_COPY_HOST_TO_DEVICE
Definition: pi.h:620
PI_COMMAND_TYPE_EXT_COMMAND_BUFFER
@ PI_COMMAND_TYPE_EXT_COMMAND_BUFFER
Definition: pi.h:552
PI_EXT_PLATFORM_BACKEND_LEVEL_ZERO
@ PI_EXT_PLATFORM_BACKEND_LEVEL_ZERO
The backend is Level Zero.
Definition: pi.h:266
PI_DEVICE_INFO_PRINTF_BUFFER_SIZE
@ PI_DEVICE_INFO_PRINTF_BUFFER_SIZE
Definition: pi.h:355
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_DOUBLE
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_DOUBLE
Definition: pi.h:308
PI_EXT_ONEAPI_QUEUE_INFO_EMPTY
@ PI_EXT_ONEAPI_QUEUE_INFO_EMPTY
Definition: pi.h:474
PI_QUEUE_FLAG_ON_DEVICE_DEFAULT
constexpr pi_queue_properties PI_QUEUE_FLAG_ON_DEVICE_DEFAULT
Definition: pi.h:736
PI_COMMAND_TYPE_IMAGE_READ
@ PI_COMMAND_TYPE_IMAGE_READ
Definition: pi.h:534
sycl::_V1::info::device_type
device_type
Definition: info_desc.hpp:53
piGetDeviceAndHostTimer
pi_result piGetDeviceAndHostTimer(pi_device Device, uint64_t *DeviceTime, uint64_t *HostTime)
Queries device for it's global timestamp in nanoseconds, and updates HostTime with the value of the h...
Definition: pi_cuda.cpp:1158
piextUSMGetMemAllocInfo
pi_result piextUSMGetMemAllocInfo(pi_context context, const void *ptr, pi_mem_alloc_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
API to query information about USM allocated pointers Valid Queries: PI_MEM_ALLOC_TYPE returns host/d...
Definition: pi_cuda.cpp:945
pi_device_binary_struct::CompileOptions
const char * CompileOptions
a null-terminated string; target- and compiler-specific options which are suggested to use to "compil...
Definition: pi.h:984
PI_USM_PTRS
@ PI_USM_PTRS
provides an explicit list of pointers that the kernel will access
Definition: pi.h:1536
piDeviceRelease
pi_result piDeviceRelease(pi_device device)
Definition: pi_cuda.cpp:69
PI_DEVICE_INFO_UUID
@ PI_DEVICE_INFO_UUID
Definition: pi.h:371
piextBindlessImageSamplerCreate
pi_result piextBindlessImageSamplerCreate(pi_context context, const pi_sampler_properties *sampler_properties, float min_mipmap_level_clamp, float max_mipmap_level_clamp, float max_anisotropy, pi_sampler *result_sampler)
API to create samplers for bindless images.
Definition: pi_cuda.cpp:394
PI_PLATFORM_INFO_PROFILE
@ PI_PLATFORM_INFO_PROFILE
Definition: pi.h:223
PI_MEM_ADVICE_CUDA_UNSET_PREFERRED_LOCATION_HOST
@ PI_MEM_ADVICE_CUDA_UNSET_PREFERRED_LOCATION_HOST
Definition: pi.h:577
PI_KERNEL_MAX_NUM_SUB_GROUPS
@ PI_KERNEL_MAX_NUM_SUB_GROUPS
Definition: pi.h:509
piextUSMEnqueueMemset
pi_result piextUSMEnqueueMemset(pi_queue queue, void *ptr, pi_int32 value, size_t count, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
USM Memset API.
Definition: pi_cuda.cpp:873
_pi_device_binary_property_struct::ValSize
uint64_t ValSize
Definition: pi.h:859
PI_DEVICE_INFO_MAX_CONSTANT_ARGS
@ PI_DEVICE_INFO_MAX_CONSTANT_ARGS
Definition: pi.h:331
PI_DEVICE_INFO_PCI_ADDRESS
@ PI_DEVICE_INFO_PCI_ADDRESS
Definition: pi.h:375
PI_PROPERTY_TYPE_UINT32
@ PI_PROPERTY_TYPE_UINT32
Definition: pi.h:846
pi_native_handle
uintptr_t pi_native_handle
Definition: pi.h:198
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_SHORT
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_SHORT
Definition: pi.h:304
PI_DEVICE_INFO_GLOBAL_MEM_SIZE
@ PI_DEVICE_INFO_GLOBAL_MEM_SIZE
Definition: pi.h:329
piQueueFinish
pi_result piQueueFinish(pi_queue command_queue)
Definition: pi_cuda.cpp:181
piContextRetain
pi_result piContextRetain(pi_context context)
Definition: pi_cuda.cpp:147
PI_MEM_ADVICE_RESET
@ PI_MEM_ADVICE_RESET
Definition: pi.h:569
pi_sampler_properties
pi_bitfield pi_sampler_properties
Definition: pi.h:662
piextKernelSetArgSampler
pi_result piextKernelSetArgSampler(pi_kernel kernel, pi_uint32 arg_index, const pi_sampler *arg_value)
Definition: pi_cuda.cpp:354
PI_KERNEL_INFO_FUNCTION_NAME
@ PI_KERNEL_INFO_FUNCTION_NAME
Definition: pi.h:478
PI_DEVICE_MEM_CACHE_TYPE_READ_WRITE_CACHE
@ PI_DEVICE_MEM_CACHE_TYPE_READ_WRITE_CACHE
Definition: pi.h:277
PI_MEM_FLAGS_ACCESS_RW
constexpr pi_mem_flags PI_MEM_FLAGS_ACCESS_RW
Definition: pi.h:696
piextCommandBufferMemBufferReadRect
pi_result piextCommandBufferMemBufferReadRect(pi_ext_command_buffer command_buffer, pi_mem buffer, pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset, pi_buff_rect_region region, size_t buffer_row_pitch, size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch, void *ptr, pi_uint32 num_events_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a rectangular mem buffer read command to the command-buffer.
Definition: pi_cuda.cpp:1105
PI_IMAGE_CHANNEL_ORDER_RGx
@ PI_IMAGE_CHANNEL_ORDER_RGx
Definition: pi.h:596
PI_QUEUE_INFO_DEVICE_DEFAULT
@ PI_QUEUE_INFO_DEVICE_DEFAULT
Definition: pi.h:468
piMemImageCreate
pi_result piMemImageCreate(pi_context context, pi_mem_flags flags, const pi_image_format *image_format, const pi_image_desc *image_desc, void *host_ptr, pi_mem *ret_mem)
Definition: pi_cuda.cpp:222
_pi_image_format
Definition: pi.h:1098
PI_EVENT_COMPLETE
@ PI_EVENT_COMPLETE
Definition: pi.h:214
sycl::_V1::ext::oneapi::experimental::level
const CoordT const float level
Definition: bindless_images.hpp:959
PI_IMAGE_CHANNEL_TYPE_UNORM_INT_101010
@ PI_IMAGE_CHANNEL_TYPE_UNORM_INT_101010
Definition: pi.h:608
PI_COMMAND_TYPE_NDRANGE_KERNEL
@ PI_COMMAND_TYPE_NDRANGE_KERNEL
Definition: pi.h:523
_pi_plugin::Targets
char * Targets
Definition: pi.h:2714
PI_PLATFORM_INFO_VENDOR
@ PI_PLATFORM_INFO_VENDOR
Definition: pi.h:224
_pi_kernel_info
_pi_kernel_info
Definition: pi.h:477
PI_MEM_ALLOC_FLAGS
constexpr pi_usm_mem_properties PI_MEM_ALLOC_FLAGS
Definition: pi.h:717
PI_DEVICE_INFO_USM_SINGLE_SHARED_SUPPORT
@ PI_DEVICE_INFO_USM_SINGLE_SHARED_SUPPORT
Definition: pi.h:367
piPlatformsGet
pi_result piPlatformsGet(pi_uint32 num_entries, pi_platform *platforms, pi_uint32 *num_platforms)
Definition: pi_cuda.cpp:25
pi_ext_structure_type
pi_ext_structure_type
Definition: pi.h:2264
PI_IMAGE_CHANNEL_ORDER_RGBA
@ PI_IMAGE_CHANNEL_ORDER_RGBA
Definition: pi.h:589
PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_MEMORY_IMPORT_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_MEMORY_IMPORT_SUPPORT
Definition: pi.h:428
PI_MEMORY_SCOPE_WORK_GROUP
constexpr pi_memory_scope_capabilities PI_MEMORY_SCOPE_WORK_GROUP
Definition: pi.h:679
PI_DEVICE_TYPE_CPU
@ PI_DEVICE_TYPE_CPU
A PI device that is the host processor.
Definition: pi.h:257
PI_MEM_ALLOC_BASE_PTR
@ PI_MEM_ALLOC_BASE_PTR
Definition: pi.h:1873
PI_DEVICE_INFO_QUEUE_PROPERTIES
@ PI_DEVICE_INFO_QUEUE_PROPERTIES
Definition: pi.h:295
PI_DEVICE_INFO_PARTITION_MAX_SUB_DEVICES
@ PI_DEVICE_INFO_PARTITION_MAX_SUB_DEVICES
Definition: pi.h:359
PI_SAMPLER_INFO_MIP_FILTER_MODE
@ PI_SAMPLER_INFO_MIP_FILTER_MODE
Definition: pi.h:636
PI_SAMPLER_ADDRESSING_MODE_CLAMP_TO_EDGE
@ PI_SAMPLER_ADDRESSING_MODE_CLAMP_TO_EDGE
Definition: pi.h:644
PI_EXT_ONEAPI_DEVICE_INFO_MAX_WORK_GROUPS_3D
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_WORK_GROUPS_3D
Definition: pi.h:405
_PI_SANITIZE_TYPE_MEMORY
@ _PI_SANITIZE_TYPE_MEMORY
Definition: pi.h:2699
PI_PROGRAM_INFO_KERNEL_NAMES
@ PI_PROGRAM_INFO_KERNEL_NAMES
Definition: pi.h:445
piextKernelSetArgMemObj
pi_result piextKernelSetArgMemObj(pi_kernel kernel, pi_uint32 arg_index, const pi_mem_obj_property *arg_properties, const pi_mem *arg_value)
Definition: pi_cuda.cpp:347
PI_KERNEL_GROUP_INFO_GLOBAL_WORK_SIZE
@ PI_KERNEL_GROUP_INFO_GLOBAL_WORK_SIZE
Definition: pi.h:487
PI_QUEUE_INFO_SIZE
@ PI_QUEUE_INFO_SIZE
Definition: pi.h:471
_PI_SANITIZE_TYPE_ADDRESS
@ _PI_SANITIZE_TYPE_ADDRESS
Definition: pi.h:2698
PI_MEM_TYPE_IMAGE1D_BUFFER
@ PI_MEM_TYPE_IMAGE1D_BUFFER
Definition: pi.h:564
piEnqueueMemBufferMap
pi_result piEnqueueMemBufferMap(pi_queue command_queue, pi_mem buffer, pi_bool blocking_map, pi_map_flags map_flags, size_t offset, size_t size, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event, void **ret_map)
Definition: pi_cuda.cpp:739
PI_SAMPLER_ADDRESSING_MODE_NONE
@ PI_SAMPLER_ADDRESSING_MODE_NONE
Definition: pi.h:646
PI_IMAGE_CHANNEL_ORDER_ABGR
@ PI_IMAGE_CHANNEL_ORDER_ABGR
Definition: pi.h:592
pi_image_mem_handle
void * pi_image_mem_handle
Definition: pi.h:1094
PI_MEM_CONTEXT
@ PI_MEM_CONTEXT
Definition: pi.h:1119
pi_image_handle
pi_uint64 pi_image_handle
Definition: pi.h:1093
PI_EVENT_QUEUED
@ PI_EVENT_QUEUED
Definition: pi.h:217
PI_PROGRAM_BINARY_TYPE_COMPILED_OBJECT
@ PI_PROGRAM_BINARY_TYPE_COMPILED_OBJECT
Definition: pi.h:245
piextMemGetNativeHandle
pi_result piextMemGetNativeHandle(pi_mem mem, pi_native_handle *nativeHandle)
Gets the native handle of a PI mem object.
Definition: pi_cuda.cpp:231
PI_ENUM_FORCE_UINT32
@ PI_ENUM_FORCE_UINT32
Definition: pi.h:1826
PI_EXT_ONEAPI_QUEUE_FLAG_PRIORITY_LOW
constexpr pi_queue_properties PI_EXT_ONEAPI_QUEUE_FLAG_PRIORITY_LOW
Definition: pi.h:738
PI_DEVICE_TYPE_CUSTOM
@ PI_DEVICE_TYPE_CUSTOM
A PI device that is a custom device.
Definition: pi.h:261
pi_buffer_region_struct::size
size_t size
Definition: pi.h:1012
_pi_image_desc::image_width
size_t image_width
Definition: pi.h:1105
PI_DEVICE_INFO_SINGLE_FP_CONFIG
@ PI_DEVICE_INFO_SINGLE_FP_CONFIG
Definition: pi.h:292
PI_COMMAND_TYPE_MEM_BUFFER_WRITE_RECT
@ PI_COMMAND_TYPE_MEM_BUFFER_WRITE_RECT
Definition: pi.h:530
pi_device_fp_config
pi_bitfield pi_device_fp_config
Definition: pi.h:816
piEnqueueMemBufferRead
pi_result piEnqueueMemBufferRead(pi_queue queue, pi_mem buffer, pi_bool blocking_read, size_t offset, size_t size, void *ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:651
PI_COMMAND_TYPE_DEVICE_GLOBAL_VARIABLE_READ
@ PI_COMMAND_TYPE_DEVICE_GLOBAL_VARIABLE_READ
Definition: pi.h:553
pi_ext_command_buffer_desc::pNext
const void * pNext
Definition: pi.h:2270
sycl::_V1::length
float length(T p)
Definition: builtins_legacy_marray_vec.hpp:921
_pi_image_channel_type
_pi_image_channel_type
Definition: pi.h:601
PI_DEVICE_INFO_BUILD_ON_SUBDEVICE
@ PI_DEVICE_INFO_BUILD_ON_SUBDEVICE
Definition: pi.h:384
PI_USM_SYSTEM_SHARED_SUPPORT
@ PI_USM_SYSTEM_SHARED_SUPPORT
Definition: pi.h:1861
PI_DEVICE_INFO_MAX_WORK_ITEM_DIMENSIONS
@ PI_DEVICE_INFO_MAX_WORK_ITEM_DIMENSIONS
Definition: pi.h:289
piKernelGetInfo
pi_result piKernelGetInfo(pi_kernel kernel, pi_kernel_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:360
PI_DEVICE_INFO_LOCAL_MEM_TYPE
@ PI_DEVICE_INFO_LOCAL_MEM_TYPE
Definition: pi.h:332
PI_DEVICE_INFO_IMAGE3D_MAX_DEPTH
@ PI_DEVICE_INFO_IMAGE3D_MAX_DEPTH
Definition: pi.h:320
PI_DEVICE_INFO_COMPILER_AVAILABLE
@ PI_DEVICE_INFO_COMPILER_AVAILABLE
Definition: pi.h:339
PI_EXT_ONEAPI_DEVICE_INFO_CUDA_ASYNC_BARRIER
@ PI_EXT_ONEAPI_DEVICE_INFO_CUDA_ASYNC_BARRIER
Definition: pi.h:406
piEventGetInfo
pi_result piEventGetInfo(pi_event event, pi_event_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:560
piEnqueueEventsWait
pi_result piEnqueueEventsWait(pi_queue command_queue, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:634
PI_FP_FMA
static constexpr pi_device_fp_config PI_FP_FMA
Definition: pi.h:822
piMemRetain
pi_result piMemRetain(pi_mem mem)
Definition: pi_cuda.cpp:218
_PI_SANITIZE_TYPE_NONE
@ _PI_SANITIZE_TYPE_NONE
Definition: pi.h:2697
pi_image_offset_struct::z
size_t z
Definition: pi.h:1039
PI_DEVICE_INFO_VERSION
@ PI_DEVICE_INFO_VERSION
Definition: pi.h:352
pi_buffer_region_struct::origin
size_t origin
Definition: pi.h:1011
PI_EXT_PLATFORM_BACKEND_ESIMD
@ PI_EXT_PLATFORM_BACKEND_ESIMD
The backend is ESIMD.
Definition: pi.h:270
PI_DEVICE_INFO_MAX_MEM_BANDWIDTH
@ PI_DEVICE_INFO_MAX_MEM_BANDWIDTH
Definition: pi.h:381
PI_IMAGE_CHANNEL_TYPE_UNSIGNED_INT8
@ PI_IMAGE_CHANNEL_TYPE_UNSIGNED_INT8
Definition: pi.h:612
piextUSMEnqueuePrefetch
pi_result piextUSMEnqueuePrefetch(pi_queue queue, const void *ptr, size_t size, pi_usm_migration_flags flags, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
Hint to migrate memory to the device.
Definition: pi_cuda.cpp:892
PI_IMAGE_CHANNEL_TYPE_UNSIGNED_INT32
@ PI_IMAGE_CHANNEL_TYPE_UNSIGNED_INT32
Definition: pi.h:614
PI_MEMORY_ORDER_ACQ_REL
constexpr pi_memory_order_capabilities PI_MEMORY_ORDER_ACQ_REL
Definition: pi.h:673
piextEnqueueReadHostPipe
pi_result piextEnqueueReadHostPipe(pi_queue queue, pi_program program, const char *pipe_symbol, pi_bool blocking, void *ptr, size_t size, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
Plugin.
Definition: pi_cuda.cpp:981
pi_queue_properties
pi_bitfield pi_queue_properties
Definition: pi.h:729
PI_EXT_ONEAPI_DEVICE_INFO_MAX_WORK_GROUPS_2D
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_WORK_GROUPS_2D
Definition: pi.h:404
PI_DEVICE_INFO_ATOMIC_64
@ PI_DEVICE_INFO_ATOMIC_64
Definition: pi.h:395
_pi_image_desc::image_row_pitch
size_t image_row_pitch
Definition: pi.h:1109
PI_DEVICE_INFO_MAX_WRITE_IMAGE_ARGS
@ PI_DEVICE_INFO_MAX_WRITE_IMAGE_ARGS
Definition: pi.h:315
_pi_platform_info
_pi_platform_info
Definition: pi.h:220
PI_DEVICE_AFFINITY_DOMAIN_NUMA
static constexpr pi_device_affinity_domain PI_DEVICE_AFFINITY_DOMAIN_NUMA
Definition: pi.h:802
PI_DEVICE_INFO_BACKEND_VERSION
@ PI_DEVICE_INFO_BACKEND_VERSION
Definition: pi.h:399
PI_MEM_FLAGS_HOST_PTR_ALLOC
constexpr pi_mem_flags PI_MEM_FLAGS_HOST_PTR_ALLOC
Definition: pi.h:701
piEventCreate
pi_result piEventCreate(pi_context context, pi_event *ret_event)
Create PI event object in a signalled/completed state.
Definition: pi_cuda.cpp:556
PI_MEM_PROPERTIES_CHANNEL
constexpr pi_mem_properties PI_MEM_PROPERTIES_CHANNEL
Definition: pi.h:711
pi_buffer_region_struct
Definition: pi.h:1010
PI_IMAGE_CHANNEL_TYPE_UNORM_SHORT_555
@ PI_IMAGE_CHANNEL_TYPE_UNORM_SHORT_555
Definition: pi.h:607
piContextCreate
pi_result piContextCreate(const pi_context_properties *properties, pi_uint32 num_devices, const pi_device *devices, void(*pfn_notify)(const char *errinfo, const void *private_info, size_t cb, void *user_data), void *user_data, pi_context *ret_context)
PI_IMAGE_CHANNEL_ORDER_ARGB
@ PI_IMAGE_CHANNEL_ORDER_ARGB
Definition: pi.h:591
piEventRetain
pi_result piEventRetain(pi_event event)
Definition: pi_cuda.cpp:592
_pi_image_desc
Definition: pi.h:1103
PI_COMMAND_TYPE_MEM_BUFFER_FILL
@ PI_COMMAND_TYPE_MEM_BUFFER_FILL
Definition: pi.h:533
piextPlatformGetNativeHandle
pi_result piextPlatformGetNativeHandle(pi_platform platform, pi_native_handle *nativeHandle)
Gets the native handle of a PI platform object.
Definition: pi_cuda.cpp:37
PI_DEVICE_INFO_ENDIAN_LITTLE
@ PI_DEVICE_INFO_ENDIAN_LITTLE
Definition: pi.h:337
PI_EXT_PLATFORM_INFO_BACKEND
@ PI_EXT_PLATFORM_INFO_BACKEND
Definition: pi.h:226
PI_PROGRAM_BUILD_STATUS_NONE
@ PI_PROGRAM_BUILD_STATUS_NONE
Definition: pi.h:237
piQueueGetInfo
pi_result piQueueGetInfo(pi_queue command_queue, pi_queue_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:167
PI_USM_DEVICE_SUPPORT
@ PI_USM_DEVICE_SUPPORT
Definition: pi.h:1858
piextEnqueueCommandBuffer
pi_result piextEnqueueCommandBuffer(pi_ext_command_buffer command_buffer, pi_queue queue, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
API to submit the command-buffer to queue for execution, returns an error if the command-buffer is no...
Definition: pi_cuda.cpp:1140
_pi_event
Definition: pi_cuda.hpp:64
PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_INT
@ PI_DEVICE_INFO_NATIVE_VECTOR_WIDTH_INT
Definition: pi.h:305
PI_DEVICE_INFO_MAX_READ_IMAGE_ARGS
@ PI_DEVICE_INFO_MAX_READ_IMAGE_ARGS
Definition: pi.h:314
pi_device_binary_property
_pi_device_binary_property_struct * pi_device_binary_property
Definition: pi.h:862
PI_FP_INF_NAN
static constexpr pi_device_fp_config PI_FP_INF_NAN
Definition: pi.h:818
piextCommandBufferMemcpyUSM
pi_result piextCommandBufferMemcpyUSM(pi_ext_command_buffer command_buffer, void *dst_ptr, const void *src_ptr, size_t size, pi_uint32 num_sync_points_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a USM memcpy command to the command-buffer.
Definition: pi_cuda.cpp:1065
PI_DEVICE_INFO_GPU_SUBSLICES_PER_SLICE
@ PI_DEVICE_INFO_GPU_SUBSLICES_PER_SLICE
Definition: pi.h:379
PI_COMMAND_TYPE_MIGRATE_MEM_OBJECTS
@ PI_COMMAND_TYPE_MIGRATE_MEM_OBJECTS
Definition: pi.h:545
piMemBufferCreate
pi_result piMemBufferCreate(pi_context context, pi_mem_flags flags, size_t size, void *host_ptr, pi_mem *ret_mem, const pi_mem_properties *properties=nullptr)
Definition: pi_cuda.cpp:205
PI_COMMAND_TYPE_RELEASE_GL_OBJECTS
@ PI_COMMAND_TYPE_RELEASE_GL_OBJECTS
Definition: pi.h:543
PI_EXEC_NATIVE_KERNEL
static constexpr pi_device_exec_capabilities PI_EXEC_NATIVE_KERNEL
Definition: pi.h:830
PI_MAP_WRITE_INVALIDATE_REGION
constexpr pi_map_flags PI_MAP_WRITE_INVALIDATE_REGION
Definition: pi.h:707
PI_SAMPLER_INFO_REFERENCE_COUNT
@ PI_SAMPLER_INFO_REFERENCE_COUNT
Definition: pi.h:631
PI_MEM_TYPE_IMAGE2D_ARRAY
@ PI_MEM_TYPE_IMAGE2D_ARRAY
Definition: pi.h:561
PI_BUFFER_CREATE_TYPE_REGION
@ PI_BUFFER_CREATE_TYPE_REGION
Definition: pi.h:625
PI_DEVICE_AFFINITY_DOMAIN_L1_CACHE
static constexpr pi_device_affinity_domain PI_DEVICE_AFFINITY_DOMAIN_L1_CACHE
Definition: pi.h:810
PI_EXT_PLATFORM_BACKEND_OPENCL
@ PI_EXT_PLATFORM_BACKEND_OPENCL
The backend is OpenCL.
Definition: pi.h:267
piEnqueueMemBufferWriteRect
pi_result piEnqueueMemBufferWriteRect(pi_queue command_queue, pi_mem buffer, pi_bool blocking_write, pi_buff_rect_offset buffer_offset, pi_buff_rect_offset host_offset, pi_buff_rect_region region, size_t buffer_row_pitch, size_t buffer_slice_pitch, size_t host_row_pitch, size_t host_slice_pitch, const void *ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:689
piextGetDeviceFunctionPointer
pi_result piextGetDeviceFunctionPointer(pi_device device, pi_program program, const char *function_name, pi_uint64 *function_pointer_ret)
Retrieves a device function pointer to a user-defined function.
Definition: pi_cuda.cpp:821
PI_EXT_INTEL_DEVICE_INFO_MAX_COMPUTE_QUEUE_INDICES
@ PI_EXT_INTEL_DEVICE_INFO_MAX_COMPUTE_QUEUE_INDICES
Definition: pi.h:394
PI_DEVICE_AFFINITY_DOMAIN_L2_CACHE
static constexpr pi_device_affinity_domain PI_DEVICE_AFFINITY_DOMAIN_L2_CACHE
Definition: pi.h:808
PI_EVENT_INFO_COMMAND_QUEUE
@ PI_EVENT_INFO_COMMAND_QUEUE
Definition: pi.h:515
piDevicesGet
pi_result piDevicesGet(pi_platform platform, pi_device_type device_type, pi_uint32 num_entries, pi_device *devices, pi_uint32 *num_devices)
Definition: pi_cuda.cpp:58
pi_device_binary_struct::Version
uint16_t Version
version of this structure - for backward compatibility; all modifications which change order/type/off...
Definition: pi.h:965
piextEnqueueDeviceGlobalVariableWrite
pi_result piextEnqueueDeviceGlobalVariableWrite(pi_queue queue, pi_program program, const char *name, pi_bool blocking_write, size_t count, size_t offset, const void *src, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Device global variable.
Definition: pi_cuda.cpp:961
PI_IMAGE_CHANNEL_ORDER_RA
@ PI_IMAGE_CHANNEL_ORDER_RA
Definition: pi.h:587
PI_IMAGE_INFO_ELEMENT_SIZE
@ PI_IMAGE_INFO_ELEMENT_SIZE
Definition: pi.h:499
PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_MEMORY_EXPORT_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_INTEROP_MEMORY_EXPORT_SUPPORT
Definition: pi.h:429
piProgramCreate
pi_result piProgramCreate(pi_context context, const void *il, size_t length, pi_program *res_program)
Definition: pi_cuda.cpp:242
_pi_mem_info
_pi_mem_info
Definition: pi.h:1119
PI_DEVICE_PARTITION_BY_COUNTS_LIST_END
static constexpr pi_device_partition_property PI_DEVICE_PARTITION_BY_COUNTS_LIST_END
Definition: pi.h:794
_pi_mem_obj_access
_pi_mem_obj_access
Definition: pi.h:1816
pi_image_offset_struct
Definition: pi.h:1036
PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_ANISOTROPY_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_ANISOTROPY_SUPPORT
Definition: pi.h:425
piProgramGetBuildInfo
pi_result piProgramGetBuildInfo(pi_program program, pi_device device, _pi_program_build_info param_name, size_t param_value_size, void *param_value, size_t *param_value_size_ret)
Definition: pi_cuda.cpp:304
PI_DEVICE_PARTITION_BY_COUNTS
static constexpr pi_device_partition_property PI_DEVICE_PARTITION_BY_COUNTS
Definition: pi.h:791
PI_USM_CROSS_SHARED_SUPPORT
@ PI_USM_CROSS_SHARED_SUPPORT
Definition: pi.h:1860
_pi_sanitize_type
_pi_sanitize_type
Definition: pi.h:2696
pi_buff_rect_offset_struct::z_scalar
size_t z_scalar
Definition: pi.h:1021
piextMemCreateWithNativeHandle
pi_result piextMemCreateWithNativeHandle(pi_native_handle nativeHandle, pi_context context, bool ownNativeHandle, pi_mem *mem)
Creates PI mem object from a native handle.
Definition: pi_cuda.cpp:235
PI_EXT_ONEAPI_DEVICE_INFO_MAX_WORK_GROUPS_1D
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_WORK_GROUPS_1D
Definition: pi.h:403
PI_COMMAND_TYPE_SVM_MEMFILL
@ PI_COMMAND_TYPE_SVM_MEMFILL
Definition: pi.h:549
PI_SAMPLER_PROPERTIES_FILTER_MODE
constexpr pi_sampler_properties PI_SAMPLER_PROPERTIES_FILTER_MODE
Definition: pi.h:666
piPluginGetBackendOption
pi_result piPluginGetBackendOption(pi_platform platform, const char *frontend_option, const char **backend_option)
API to get backend specific option.
Definition: pi_cuda.cpp:51
PI_DEVICE_INFO_VENDOR_ID
@ PI_DEVICE_INFO_VENDOR_ID
Definition: pi.h:287
pi_ext_command_buffer_desc::stype
pi_ext_structure_type stype
Definition: pi.h:2269
PI_MEM_ALLOC_DEVICE
@ PI_MEM_ALLOC_DEVICE
Definition: pi.h:1875
piextKernelSetArgPointer
pi_result piextKernelSetArgPointer(pi_kernel kernel, pi_uint32 arg_index, size_t arg_size, const void *arg_value)
Sets up pointer arguments for CL kernels.
Definition: pi_cuda.cpp:868
PI_COMMAND_TYPE_MARKER
@ PI_COMMAND_TYPE_MARKER
Definition: pi.h:541
PI_COMMAND_TYPE_MEM_BUFFER_READ
@ PI_COMMAND_TYPE_MEM_BUFFER_READ
Definition: pi.h:524
pi_image_region_struct
Definition: pi.h:1045
PI_DEVICE_INFO_EXTENSIONS
@ PI_DEVICE_INFO_EXTENSIONS
Definition: pi.h:354
PI_COMMAND_TYPE_SVM_FREE
@ PI_COMMAND_TYPE_SVM_FREE
Definition: pi.h:547
PI_COMMAND_TYPE_ACQUIRE_GL_OBJECTS
@ PI_COMMAND_TYPE_ACQUIRE_GL_OBJECTS
Definition: pi.h:542
PI_EXT_STRUCTURE_TYPE_COMMAND_BUFFER_DESC
@ PI_EXT_STRUCTURE_TYPE_COMMAND_BUFFER_DESC
Definition: pi.h:2265
sycl::_V1::image_format
image_format
Definition: image.hpp:94
PI_COMMAND_TYPE_COPY_BUFFER_TO_IMAGE
@ PI_COMMAND_TYPE_COPY_BUFFER_TO_IMAGE
Definition: pi.h:538
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_FLOAT
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_FLOAT
Definition: pi.h:300
piQueueFlush
pi_result piQueueFlush(pi_queue command_queue)
Definition: pi_cuda.cpp:183
PI_DEVICE_TYPE_ALL
@ PI_DEVICE_TYPE_ALL
All devices available in the PI plugin.
Definition: pi.h:256
PI_SAMPLER_PROPERTIES_NORMALIZED_COORDS
constexpr pi_sampler_properties PI_SAMPLER_PROPERTIES_NORMALIZED_COORDS
Definition: pi.h:663
piextDeviceSelectBinary
pi_result piextDeviceSelectBinary(pi_device device, pi_device_binary *binaries, pi_uint32 num_binaries, pi_uint32 *selected_binary_ind)
Selects the most appropriate device binary based on runtime information and the IR characteristics.
Definition: pi_cuda.cpp:88
_pi_mem_obj_property
Definition: pi.h:1830
_pi_usm_migration_flags
_pi_usm_migration_flags
Definition: pi.h:1888
PI_CONTEXT_INFO_PROPERTIES
@ PI_CONTEXT_INFO_PROPERTIES
Definition: pi.h:452
PI_QUEUE_FLAG_PROFILING_ENABLE
constexpr pi_queue_properties PI_QUEUE_FLAG_PROFILING_ENABLE
Definition: pi.h:734
PI_QUEUE_FLAG_OUT_OF_ORDER_EXEC_MODE_ENABLE
constexpr pi_queue_properties PI_QUEUE_FLAG_OUT_OF_ORDER_EXEC_MODE_ENABLE
Definition: pi.h:733
PI_FP_CORRECTLY_ROUNDED_DIVIDE_SQRT
static constexpr pi_device_fp_config PI_FP_CORRECTLY_ROUNDED_DIVIDE_SQRT
Definition: pi.h:824
piextUSMRelease
pi_result piextUSMRelease(const void *ptr, pi_context context)
Release host system memory from USM.
Definition: pi_cuda.cpp:957
PI_IMAGE_CHANNEL_ORDER_RGB
@ PI_IMAGE_CHANNEL_ORDER_RGB
Definition: pi.h:588
_pi_device_binary_property_set_struct::PropertiesEnd
pi_device_binary_property PropertiesEnd
Definition: pi.h:868
_pi_program_build_status
_pi_program_build_status
Definition: pi.h:236
PI_DEVICE_INFO_QUEUE_ON_HOST_PROPERTIES
@ PI_DEVICE_INFO_QUEUE_ON_HOST_PROPERTIES
Definition: pi.h:343
_pi_offload_entry_struct::flags
int32_t flags
Definition: pi.h:837
PI_PROGRAM_INFO_NUM_KERNELS
@ PI_PROGRAM_INFO_NUM_KERNELS
Definition: pi.h:444
piextContextGetNativeHandle
pi_result piextContextGetNativeHandle(pi_context context, pi_native_handle *nativeHandle)
Gets the native handle of a PI context object.
Definition: pi_cuda.cpp:133
PI_DEVICE_INFO_TYPE
@ PI_DEVICE_INFO_TYPE
Definition: pi.h:286
PI_DEVICE_INFO_MAX_WORK_GROUP_SIZE
@ PI_DEVICE_INFO_MAX_WORK_GROUP_SIZE
Definition: pi.h:291
PI_CONTEXT_INFO_REFERENCE_COUNT
@ PI_CONTEXT_INFO_REFERENCE_COUNT
Definition: pi.h:453
_pi_program_info
_pi_program_info
Definition: pi.h:436
_pi_profiling_info
_pi_profiling_info
Definition: pi.h:683
_pi_plugin::PiFunctionTable
struct _pi_plugin::FunctionPointers PiFunctionTable
pi_device_affinity_domain
pi_bitfield pi_device_affinity_domain
Definition: pi.h:801
PI_DEVICE_INFO_IMAGE_SUPPORT
@ PI_DEVICE_INFO_IMAGE_SUPPORT
Definition: pi.h:313
pi_interop_semaphore_handle
pi_uint64 pi_interop_semaphore_handle
Definition: pi.h:1096
PI_COMMAND_TYPE_COPY_IMAGE_TO_BUFFER
@ PI_COMMAND_TYPE_COPY_IMAGE_TO_BUFFER
Definition: pi.h:539
PI_MEM_ADVICE_CUDA_UNSET_ACCESSED_BY
@ PI_MEM_ADVICE_CUDA_UNSET_ACCESSED_BY
Definition: pi.h:575
pi_device_binary_struct::EntriesEnd
_pi_offload_entry EntriesEnd
Definition: pi.h:998
PI_EXT_DEVICE_INFO_ATOMIC_FENCE_ORDER_CAPABILITIES
@ PI_EXT_DEVICE_INFO_ATOMIC_FENCE_ORDER_CAPABILITIES
Definition: pi.h:408
PI_EXT_INTEL_DEVICE_INFO_MEM_CHANNEL_SUPPORT
@ PI_EXT_INTEL_DEVICE_INFO_MEM_CHANNEL_SUPPORT
Definition: pi.h:410
PI_DEVICE_INFO_MAX_PARAMETER_SIZE
@ PI_DEVICE_INFO_MAX_PARAMETER_SIZE
Definition: pi.h:324
PI_MEM_ADVICE_CUDA_SET_ACCESSED_BY_HOST
@ PI_MEM_ADVICE_CUDA_SET_ACCESSED_BY_HOST
Definition: pi.h:578
PI_EVENT_INFO_COMMAND_EXECUTION_STATUS
@ PI_EVENT_INFO_COMMAND_EXECUTION_STATUS
Definition: pi.h:518
PI_PROGRAM_INFO_DEVICES
@ PI_PROGRAM_INFO_DEVICES
Definition: pi.h:440
PI_EXT_ONEAPI_DEVICE_INFO_IP_VERSION
@ PI_EXT_ONEAPI_DEVICE_INFO_IP_VERSION
Definition: pi.h:373
PI_MEM_ALLOC_WRTITE_COMBINED
constexpr pi_usm_mem_properties PI_MEM_ALLOC_WRTITE_COMBINED
Definition: pi.h:718
piextUSMEnqueueFill2D
pi_result piextUSMEnqueueFill2D(pi_queue queue, void *ptr, size_t pitch, size_t pattern_size, const void *pattern, size_t width, size_t height, pi_uint32 num_events_in_waitlist, const pi_event *events_waitlist, pi_event *event)
USM 2D fill API.
Definition: pi_cuda.cpp:909
PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_1D_USM_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_1D_USM_SUPPORT
Definition: pi.h:418
PI_SAMPLER_FILTER_MODE_LINEAR
@ PI_SAMPLER_FILTER_MODE_LINEAR
Definition: pi.h:651
piEnqueueMemImageCopy
pi_result piEnqueueMemImageCopy(pi_queue command_queue, pi_mem src_image, pi_mem dst_image, pi_image_offset src_origin, pi_image_offset dst_origin, pi_image_region region, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:792
_pi_kernel_group_info
_pi_kernel_group_info
Definition: pi.h:486
PI_DEVICE_INFO_SUB_GROUP_SIZES_INTEL
@ PI_DEVICE_INFO_SUB_GROUP_SIZES_INTEL
Definition: pi.h:364
piextUSMImport
pi_result piextUSMImport(const void *ptr, size_t size, pi_context context)
Import host system memory into USM.
Definition: pi_cuda.cpp:953
PI_QUEUE_INFO_REFERENCE_COUNT
@ PI_QUEUE_INFO_REFERENCE_COUNT
Definition: pi.h:470
PI_PROGRAM_INFO_NUM_DEVICES
@ PI_PROGRAM_INFO_NUM_DEVICES
Definition: pi.h:439
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_HALF
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_HALF
Definition: pi.h:302
PI_EXT_DEVICE_INFO_ATOMIC_MEMORY_ORDER_CAPABILITIES
@ PI_EXT_DEVICE_INFO_ATOMIC_MEMORY_ORDER_CAPABILITIES
Definition: pi.h:396
piextProgramSetSpecializationConstant
pi_result piextProgramSetSpecializationConstant(pi_program prog, pi_uint32 spec_id, size_t spec_size, const void *spec_value)
Sets a specialization constant to a specific value.
Definition: pi_cuda.cpp:1028
pi_buff_rect_offset_struct::x_bytes
size_t x_bytes
Definition: pi.h:1019
pi_device_binary_struct::ManifestEnd
const char * ManifestEnd
Pointer to the manifest data end.
Definition: pi.h:991
piextMemImageCreateWithNativeHandle
pi_result piextMemImageCreateWithNativeHandle(pi_native_handle nativeHandle, pi_context context, bool ownNativeHandle, const pi_image_format *ImageFormat, const pi_image_desc *ImageDesc, pi_mem *img)
Creates PI image object from a native handle.
Definition: pi_cuda.cpp:258
_pi_peer_attr
_pi_peer_attr
Definition: pi.h:1121
PI_PROGRAM_BINARY_TYPE_LIBRARY
@ PI_PROGRAM_BINARY_TYPE_LIBRARY
Definition: pi.h:246
PI_IMAGE_INFO_HEIGHT
@ PI_IMAGE_INFO_HEIGHT
Definition: pi.h:503
PI_EXT_CONTEXT_INFO_ATOMIC_FENCE_ORDER_CAPABILITIES
@ PI_EXT_CONTEXT_INFO_ATOMIC_FENCE_ORDER_CAPABILITIES
Definition: pi.h:457
piextMemImageGetInfo
pi_result piextMemImageGetInfo(const pi_image_mem_handle mem_handle, pi_image_info param_name, void *param_value, size_t *param_value_size_ret)
API to query an image memory handle for specific properties.
Definition: pi_cuda.cpp:444
PI_MEM_TYPE_HOST
@ PI_MEM_TYPE_HOST
Definition: pi.h:1880
_pi_command_type
_pi_command_type
Definition: pi.h:522
piSamplerRelease
pi_result piSamplerRelease(pi_sampler sampler)
Definition: pi_cuda.cpp:630
piextKernelCreateWithNativeHandle
pi_result piextKernelCreateWithNativeHandle(pi_native_handle nativeHandle, pi_context context, pi_program program, bool pluginOwnsNativeHandle, pi_kernel *kernel)
Creates PI kernel object from a native handle.
Definition: pi_cuda.cpp:541
PI_MEM_USM_ALLOC_BUFFER_LOCATION
constexpr pi_usm_mem_properties PI_MEM_USM_ALLOC_BUFFER_LOCATION
Definition: pi.h:725
PI_ACCESS_WRITE_ONLY
@ PI_ACCESS_WRITE_ONLY
Definition: pi.h:1818
pi_memory_order_capabilities
pi_bitfield pi_memory_order_capabilities
Definition: pi.h:669
piextMemImageFree
pi_result piextMemImageFree(pi_context context, pi_device device, pi_image_mem_handle memory_handle)
API to free memory for bindless images.
Definition: pi_cuda.cpp:411
_pi_offload_entry_struct::name
char * name
Definition: pi.h:835
PI_PROFILING_INFO_COMMAND_END
@ PI_PROFILING_INFO_COMMAND_END
Definition: pi.h:687
PI_SAMPLER_INFO_NORMALIZED_COORDS
@ PI_SAMPLER_INFO_NORMALIZED_COORDS
Definition: pi.h:633
_pi_mem_alloc_info
_pi_mem_alloc_info
Definition: pi.h:1871
PI_DEVICE_INFO_MAX_CLOCK_FREQUENCY
@ PI_DEVICE_INFO_MAX_CLOCK_FREQUENCY
Definition: pi.h:310
PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_HEIGHT
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_IMAGE_LINEAR_HEIGHT
Definition: pi.h:422
PI_DEVICE_INFO_IMAGE2D_MAX_WIDTH
@ PI_DEVICE_INFO_IMAGE2D_MAX_WIDTH
Definition: pi.h:316
PI_TRUE
const pi_bool PI_TRUE
Definition: pi.h:627
PI_DEVICE_INFO_AVAILABLE
@ PI_DEVICE_INFO_AVAILABLE
Definition: pi.h:338
piEnqueueMemImageWrite
pi_result piEnqueueMemImageWrite(pi_queue command_queue, pi_mem image, pi_bool blocking_write, pi_image_offset origin, pi_image_region region, size_t input_row_pitch, size_t input_slice_pitch, const void *ptr, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
Definition: pi_cuda.cpp:778
_pi_image_desc::num_mip_levels
pi_uint32 num_mip_levels
Definition: pi.h:1111
PI_PROGRAM_INFO_CONTEXT
@ PI_PROGRAM_INFO_CONTEXT
Definition: pi.h:438
PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_LEVEL_REFERENCE_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_LEVEL_REFERENCE_SUPPORT
Definition: pi.h:427
_pi_kernel_cache_config
_pi_kernel_cache_config
Definition: pi.h:744
pi_usm_mem_properties
pi_bitfield pi_usm_mem_properties
Definition: pi.h:716
piextCommandBufferMemBufferCopy
pi_result piextCommandBufferMemBufferCopy(pi_ext_command_buffer command_buffer, pi_mem src_buffer, pi_mem dst_buffer, size_t src_offset, size_t dst_offset, size_t size, pi_uint32 num_sync_points_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a mem buffer copy command to the command-buffer.
Definition: pi_cuda.cpp:1074
piextMemImageCopy
pi_result piextMemImageCopy(pi_queue command_queue, void *dst_ptr, void *src_ptr, const pi_image_format *image_format, const pi_image_desc *image_desc, const pi_image_copy_flags flags, pi_image_offset src_offset, pi_image_offset dst_offset, pi_image_region copy_extent, pi_image_region host_extent, pi_uint32 num_events_in_wait_list, const pi_event *event_wait_list, pi_event *event)
API to copy image data Host to Device or Device to Host.
Definition: pi_cuda.cpp:421
pi_map_flags
pi_bitfield pi_map_flags
Definition: pi.h:704
piProgramBuild
pi_result piProgramBuild(pi_program program, pi_uint32 num_devices, const pi_device *device_list, const char *options, void(*pfn_notify)(pi_program program, void *user_data), void *user_data)
pi_device_binaries_struct::HostEntriesEnd
_pi_offload_entry * HostEntriesEnd
Definition: pi.h:1069
PI_DEVICE_INFO_IMAGE3D_MAX_HEIGHT
@ PI_DEVICE_INFO_IMAGE3D_MAX_HEIGHT
Definition: pi.h:319
PI_DEVICE_INFO_GPU_EU_SIMD_WIDTH
@ PI_DEVICE_INFO_GPU_EU_SIMD_WIDTH
Definition: pi.h:377
_pi_program_build_info
_pi_program_build_info
Definition: pi.h:229
PI_COMMAND_TYPE_FILL_IMAGE
@ PI_COMMAND_TYPE_FILL_IMAGE
Definition: pi.h:546
PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_2D_USM_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_BINDLESS_IMAGES_2D_USM_SUPPORT
Definition: pi.h:419
PI_MEM_TYPE_IMAGE3D
@ PI_MEM_TYPE_IMAGE3D
Definition: pi.h:560
pi_bitfield
pi_uint64 pi_bitfield
Definition: pi.h:197
PI_PROGRAM_BUILD_INFO_BINARY_TYPE
@ PI_PROGRAM_BUILD_INFO_BINARY_TYPE
Definition: pi.h:233
piextQueueCreate
pi_result piextQueueCreate(pi_context context, pi_device device, pi_queue_properties *properties, pi_queue *queue)
Definition: pi_cuda.cpp:162
piextEnablePeerAccess
pi_result piextEnablePeerAccess(pi_device command_device, pi_device peer_device)
Definition: pi_cuda.cpp:1163
PI_USM_CONCURRENT_ATOMIC_ACCESS
@ PI_USM_CONCURRENT_ATOMIC_ACCESS
Definition: pi.h:1868
PI_EXT_PLATFORM_BACKEND_HIP
@ PI_EXT_PLATFORM_BACKEND_HIP
The backend is HIP.
Definition: pi.h:269
PI_EVENT_INFO_REFERENCE_COUNT
@ PI_EVENT_INFO_REFERENCE_COUNT
Definition: pi.h:519
piextMemMapExternalArray
pi_result piextMemMapExternalArray(pi_context context, pi_device device, pi_image_format *image_format, pi_image_desc *image_desc, pi_interop_mem_handle mem_handle, pi_image_mem_handle *ret_mem)
API to map an interop memory handle to an image memory handle.
Definition: pi_cuda.cpp:459
PI_MEM_ALLOC_TYPE
@ PI_MEM_ALLOC_TYPE
Definition: pi.h:1872
PI_IMAGE_CHANNEL_TYPE_SNORM_INT8
@ PI_IMAGE_CHANNEL_TYPE_SNORM_INT8
Definition: pi.h:602
piextCommandBufferNDRangeKernel
pi_result piextCommandBufferNDRangeKernel(pi_ext_command_buffer command_buffer, pi_kernel kernel, pi_uint32 work_dim, const size_t *global_work_offset, const size_t *global_work_size, const size_t *local_work_size, pi_uint32 num_sync_points_in_wait_list, const pi_ext_sync_point *sync_point_wait_list, pi_ext_sync_point *sync_point)
API to append a kernel execution command to the command-buffer.
Definition: pi_cuda.cpp:1055
PI_COMMAND_TYPE_MEM_BUFFER_MAP
@ PI_COMMAND_TYPE_MEM_BUFFER_MAP
Definition: pi.h:527
pi_mem_access_flag
uint32_t pi_mem_access_flag
Definition: pi.h:1822
pi_device_partition_property
intptr_t pi_device_partition_property
Definition: pi.h:788
PI_FP_ROUND_TO_ZERO
static constexpr pi_device_fp_config PI_FP_ROUND_TO_ZERO
Definition: pi.h:820
PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_LONG
@ PI_DEVICE_INFO_PREFERRED_VECTOR_WIDTH_LONG
Definition: pi.h:299
PI_PROGRAM_BUILD_INFO_LOG
@ PI_PROGRAM_BUILD_INFO_LOG
Definition: pi.h:232
PI_KERNEL_COMPILE_SUB_GROUP_SIZE_INTEL
@ PI_KERNEL_COMPILE_SUB_GROUP_SIZE_INTEL
Definition: pi.h:511
PI_COMMAND_TYPE_MEM_BUFFER_COPY_RECT
@ PI_COMMAND_TYPE_MEM_BUFFER_COPY_RECT
Definition: pi.h:531
PI_COMMAND_TYPE_IMAGE_WRITE
@ PI_COMMAND_TYPE_IMAGE_WRITE
Definition: pi.h:535
PI_SAMPLER_INFO_LOD_MAX
@ PI_SAMPLER_INFO_LOD_MAX
Definition: pi.h:638
PI_EVENT_SUBMITTED
@ PI_EVENT_SUBMITTED
Definition: pi.h:216
PI_PROGRAM_INFO_BINARIES
@ PI_PROGRAM_INFO_BINARIES
Definition: pi.h:443
PI_EXT_ONEAPI_CONTEXT_INFO_USM_FILL2D_SUPPORT
@ PI_EXT_ONEAPI_CONTEXT_INFO_USM_FILL2D_SUPPORT
Definition: pi.h:460
PI_KERNEL_GROUP_INFO_PRIVATE_MEM_SIZE
@ PI_KERNEL_GROUP_INFO_PRIVATE_MEM_SIZE
Definition: pi.h:492
piextMemMipmapFree
pi_result piextMemMipmapFree(pi_context context, pi_device device, pi_image_mem_handle memory_handle)
API to free mipmap memory for bindless images.
Definition: pi_cuda.cpp:416
PI_KERNEL_GROUP_INFO_COMPILE_WORK_GROUP_SIZE
@ PI_KERNEL_GROUP_INFO_COMPILE_WORK_GROUP_SIZE
Definition: pi.h:489
PI_USM_HOST_SUPPORT
@ PI_USM_HOST_SUPPORT
Definition: pi.h:1857
pi_int32
int32_t pi_int32
Definition: pi.h:193
PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_SUPPORT
@ PI_EXT_ONEAPI_DEVICE_INFO_MIPMAP_SUPPORT
Definition: pi.h:424
_pi_context
Definition: pi_cuda.hpp:52
PI_DEVICE_BINARIES_VERSION
static const uint16_t PI_DEVICE_BINARIES_VERSION
Definition: pi.h:1053
PI_IMAGE_CHANNEL_TYPE_UNORM_INT16
@ PI_IMAGE_CHANNEL_TYPE_UNORM_INT16
Definition: pi.h:605
PI_DEVICE_AFFINITY_DOMAIN_NEXT_PARTITIONABLE
static constexpr pi_device_affinity_domain PI_DEVICE_AFFINITY_DOMAIN_NEXT_PARTITIONABLE
Definition: pi.h:813
PI_QUEUE_INFO_PROPERTIES
@ PI_QUEUE_INFO_PROPERTIES
Definition: pi.h:469
PI_QUEUE_FLAGS
constexpr pi_queue_properties PI_QUEUE_FLAGS
Definition: pi.h:730
_pi_device
Definition: pi_cuda.hpp:48
PI_DEVICE_INFO_PARTITION_PROPERTIES
@ PI_DEVICE_INFO_PARTITION_PROPERTIES
Definition: pi.h:358
PI_IMAGE_CHANNEL_ORDER_Rx
@ PI_IMAGE_CHANNEL_ORDER_Rx
Definition: pi.h:595
PI_USM_SINGLE_SHARED_SUPPORT
@ PI_USM_SINGLE_SHARED_SUPPORT
Definition: pi.h:1859
_pi_kernel_sub_group_info
_pi_kernel_sub_group_info
Definition: pi.h:507
PI_PLATFORM_INFO_EXTENSIONS
@ PI_PLATFORM_INFO_EXTENSIONS
Definition: pi.h:221
PI_COMMAND_TYPE_MEM_BUFFER_UNMAP
@ PI_COMMAND_TYPE_MEM_BUFFER_UNMAP
Definition: pi.h:528
PI_KERNEL_INFO_NUM_ARGS
@ PI_KERNEL_INFO_NUM_ARGS
Definition: pi.h:479
PI_EXT_DEVICE_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES
@ PI_EXT_DEVICE_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES
Definition: pi.h:409
PI_DEVICE_INFO_SUB_GROUP_INDEPENDENT_FORWARD_PROGRESS
@ PI_DEVICE_INFO_SUB_GROUP_INDEPENDENT_FORWARD_PROGRESS
Definition: pi.h:363
PI_SAMPLER_INFO_ADDRESSING_MODE
@ PI_SAMPLER_INFO_ADDRESSING_MODE
Definition: pi.h:634
PI_SAMPLER_ADDRESSING_MODE_CLAMP
@ PI_SAMPLER_ADDRESSING_MODE_CLAMP
Definition: pi.h:645
pi_device_binary_struct::PropertySetsBegin
pi_device_binary_property_set PropertySetsBegin
Definition: pi.h:1001
PI_EXT_ONEAPI_DEVICE_INFO_MAX_GLOBAL_WORK_GROUPS
@ PI_EXT_ONEAPI_DEVICE_INFO_MAX_GLOBAL_WORK_GROUPS
Definition: pi.h:402
pi_device_binary_struct::EntriesBegin
_pi_offload_entry EntriesBegin
the offload entry table
Definition: pi.h:997