diff options
author | Michael Jones <michael_p_jones@apple.com> | 2022-10-12 19:06:06 +0300 |
---|---|---|
committer | Michael Jones <michael_p_jones@apple.com> | 2022-10-12 19:06:50 +0300 |
commit | ba67a383fa3931b95bebd9ce92c9fc71928fb409 (patch) | |
tree | eeadd7d8a622dcd80f70ef64d8a28cb96e421436 /intern/cycles/kernel/types.h | |
parent | d586f8962de4037a3aceb3da9aa13a02862d0d3c (diff) |
Cycles: Enable MNEE on Metal (macOS >= 13)
This patch enables MNEE on macOS >= 13. There was an inefficiency in the calculation of spill requirements, fixed as of macOS 13. This patch also adds a temporary inlining workaround for a Metal compiler bug which causes `mnee_compute_constraint_derivatives` to behave incorrectly.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D16235
Diffstat (limited to 'intern/cycles/kernel/types.h')
-rw-r--r-- | intern/cycles/kernel/types.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/intern/cycles/kernel/types.h b/intern/cycles/kernel/types.h index 1469d915d15..8f7cfd19169 100644 --- a/intern/cycles/kernel/types.h +++ b/intern/cycles/kernel/types.h @@ -85,9 +85,9 @@ CCL_NAMESPACE_BEGIN # define __VOLUME_RECORD_ALL__ #endif /* !__KERNEL_GPU__ */ -/* MNEE currently causes "Compute function exceeds available temporary registers" - * on Metal, disabled for now. */ -#ifndef __KERNEL_METAL__ +/* MNEE caused "Compute function exceeds available temporary registers" in macOS < 13 due to a bug + * in spill buffer allocation sizing. */ +#if !defined(__KERNEL_METAL__) || (__KERNEL_METAL_MACOS__ >= 13) # define __MNEE__ #endif |