17 inline namespace _V1 {
18 namespace ext::oneapi::level_zero {
19 using namespace detail;
31 const auto &Plugin = pi::getPlugin<backend::ext_oneapi_level_zero>();
36 NativeHandle, PlatformImpl->getHandleRef(), &
PiDevice);
38 return detail::createSyclObjFromImpl<device>(
39 PlatformImpl->getOrMakeDeviceImpl(
PiDevice, PlatformImpl));
47 const auto &Plugin = pi::getPlugin<backend::ext_oneapi_level_zero>();
50 std::vector<pi_device> DeviceHandles;
51 for (
auto Dev : DeviceList) {
55 NativeHandle, DeviceHandles.size(), DeviceHandles.data(), !KeepOwnership,
58 return detail::createSyclObjFromImpl<context>(
60 Plugin, DeviceList, !KeepOwnership));
71 NativeHandle, IsImmCmdList, Context, &Device, KeepOwnership, Properties,
The context class represents a SYCL context on which kernel functions may be executed.
The SYCL device class encapsulates a single SYCL device on which kernels may be executed.
Objects of the property_list class are containers for the SYCL properties.
Encapsulates a single SYCL queue which schedules kernels on a SYCL device.
void defaultAsyncHandler(exception_list Exceptions)
queue make_queue(pi_native_handle NativeHandle, int32_t nativeHandleDesc, const context &TargetContext, const device *TargetDevice, bool KeepOwnership, const property_list &PropList, const async_handler &Handler, backend Backend)
platform make_platform(pi_native_handle NativeHandle, backend Backend)
decltype(Obj::impl) getSyclObjImpl(const Obj &SyclObject)
event make_event(pi_native_handle NativeHandle, const context &TargetContext, backend Backend)
platform make_platform(pi_native_handle NativeHandle)
context make_context(const std::vector< device > &DeviceList, pi_native_handle NativeHandle, bool keep_ownership=false)
event make_event(const context &Context, pi_native_handle InteropHandle, bool keep_ownership=false)
device make_device(const platform &Platform, pi_native_handle NativeHandle)
queue make_queue(const context &Context, const device &Device, pi_native_handle InteropHandle, bool IsImmCmdList, bool keep_ownership, const property_list &Properties)
uintptr_t pi_native_handle
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.
pi_result piextDeviceCreateWithNativeHandle(pi_native_handle nativeHandle, pi_platform platform, pi_device *device)
Creates PI device object from a native handle.