26#if !defined(WITH_ONEAPI)
39 if (getenv(
"SYCL_CACHE_PERSISTENT") ==
nullptr) {
40 _putenv_s(
"SYCL_CACHE_PERSISTENT",
"1");
42 if (getenv(
"SYCL_CACHE_TRESHOLD") ==
nullptr) {
43 _putenv_s(
"SYCL_CACHE_THRESHOLD",
"0");
45 if (getenv(
"ONEAPI_DEVICE_SELECTOR") ==
nullptr) {
46 if (getenv(
"CYCLES_ONEAPI_ALL_DEVICES") ==
nullptr) {
47 _putenv_s(
"ONEAPI_DEVICE_SELECTOR",
"level_zero:*");
50 _putenv_s(
"ONEAPI_DEVICE_SELECTOR",
"!opencl:*");
54 if (getenv(
"ZES_ENABLE_SYSMAN") ==
nullptr) {
55 _putenv_s(
"ZES_ENABLE_SYSMAN",
"1");
57 if (getenv(
"SYCL_PI_LEVEL_ZERO_USE_COPY_ENGINE") ==
nullptr) {
58 _putenv_s(
"SYCL_PI_LEVEL_ZERO_USE_COPY_ENGINE",
"0");
61 setenv(
"SYCL_CACHE_PERSISTENT",
"1",
false);
62 setenv(
"SYCL_CACHE_THRESHOLD",
"0",
false);
63 if (getenv(
"CYCLES_ONEAPI_ALL_DEVICES") ==
nullptr) {
64 setenv(
"ONEAPI_DEVICE_SELECTOR",
"level_zero:*",
false);
67 setenv(
"ONEAPI_DEVICE_SELECTOR",
"!opencl:*",
false);
71 setenv(
"ZES_ENABLE_SYSMAN",
"0",
false);
72 setenv(
"SYCL_PI_LEVEL_ZERO_USE_COPY_ENGINE",
"0",
false);
85 return new OneapiDevice(info, stats, profiler, headless);
91 LOG(FATAL) <<
"Requested to create oneAPI device while not enabled for this build.";
98static void device_iterator_cb(
const char *
id,
117# if defined(WITH_OPENIMAGEDENOISE)
118# if OIDN_VERSION >= 20300
121 if (OIDNDenoiserGPU::is_device_supported(info)) {
137# ifdef WITH_EMBREE_GPU
148 VLOG_INFO <<
"Device with id \"" << info.
id <<
"\" supports "
156 OneapiDevice::iterate_devices(device_iterator_cb, &devices);
166 char *c_capabilities = OneapiDevice::device_capabilities();
167 if (c_capabilities) {
168 capabilities = c_capabilities;
169 free(c_capabilities);
void BLI_kdtree_nd_ free(KDTree *tree)
DenoiserTypeMask denoisers
bool use_hardware_raytracing
CCL_NAMESPACE_BEGIN const char * denoiserTypeToHumanReadable(DenoiserType type)
@ DENOISER_OPENIMAGEDENOISE
#define CCL_NAMESPACE_END
void device_oneapi_info(vector< DeviceInfo > &devices)
CCL_NAMESPACE_BEGIN bool device_oneapi_init()
Device * device_oneapi_create(const DeviceInfo &info, Stats &stats, Profiler &profiler, bool headless)
string device_oneapi_capabilities()
Vector< CPUDevice > devices
list of all CPUDevices. for every hardware thread an instance of CPUDevice is created