Fix T103393: Cycles: Undefine __LIGHT_TREE__ on Metal/AMD to fix perf
This patch fixes T103393 by undefining `__LIGHT_TREE__` on Metal/AMD as it has an unexpected & major impact on performance even when light trees are not in use. Patch authored by Prakash Kamliya. Reviewed By: brecht Maniphest Tasks: T103393 Differential Revision: https://developer.blender.org/D17167
This commit is contained in:
parent
6d297c35c8
commit
0a3df611e7
Notes:
blender-bot
2023-02-14 06:05:22 +01:00
Referenced by issue #103393, Cycles render time regression with AMD GPUs on macOS
|
@ -55,6 +55,10 @@ void device_metal_info(vector<DeviceInfo> &devices)
|
|||
info.denoisers = DENOISER_NONE;
|
||||
info.id = id;
|
||||
|
||||
if (MetalInfo::get_device_vendor(device) == METAL_GPU_AMD) {
|
||||
info.has_light_tree = false;
|
||||
}
|
||||
|
||||
devices.push_back(info);
|
||||
device_index++;
|
||||
}
|
||||
|
|
|
@ -74,7 +74,8 @@ CCL_NAMESPACE_BEGIN
|
|||
#define __VOLUME__
|
||||
|
||||
/* TODO: solve internal compiler errors and enable light tree on HIP. */
|
||||
#ifdef __KERNEL_HIP__
|
||||
/* TODO: solve internal compiler perf issue and enable light tree on Metal/AMD. */
|
||||
#if defined(__KERNEL_HIP__) || defined(__KERNEL_METAL_AMD__)
|
||||
# undef __LIGHT_TREE__
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue