diff options
author | Brecht Van Lommel <brecht@blender.org> | 2022-07-25 22:16:34 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2022-07-26 01:17:37 +0300 |
commit | 4cf6524731c0856bfc6d6c0b7bcb2df0ad28b97a (patch) | |
tree | 8eec2e3f32155310e1605a4205102709341c0267 /intern/cycles/util/types_float8.h | |
parent | f76a2c0d1895a43b932eb5e458732e54b6aa17c7 (diff) |
Fix Cycles Metal build errors after recent changes
float8 is a reserved type in Metal, but is not implemented. So rename to
float8_t for now.
Also move back intersection handlers to kernel.metal, they can't be in the
class that encapsulates the other Metal kernel functions.
Diffstat (limited to 'intern/cycles/util/types_float8.h')
-rw-r--r-- | intern/cycles/util/types_float8.h | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/intern/cycles/util/types_float8.h b/intern/cycles/util/types_float8.h index f04dc675c84..bb9798932ac 100644 --- a/intern/cycles/util/types_float8.h +++ b/intern/cycles/util/types_float8.h @@ -11,10 +11,13 @@ CCL_NAMESPACE_BEGIN +/* float8 is a reserved type in Metal that has not been implemented. For + * that reason this is named float8_t. */ + #ifdef __KERNEL_GPU__ -struct float8 +struct float8_t #else -struct ccl_try_align(32) float8 +struct ccl_try_align(32) float8_t #endif { #ifdef __KERNEL_AVX2__ @@ -25,14 +28,14 @@ struct ccl_try_align(32) float8 }; }; - __forceinline float8(); - __forceinline float8(const float8 &a); - __forceinline explicit float8(const __m256 &a); + __forceinline float8_t(); + __forceinline float8_t(const float8_t &a); + __forceinline explicit float8_t(const __m256 &a); __forceinline operator const __m256 &() const; __forceinline operator __m256 &(); - __forceinline float8 &operator=(const float8 &a); + __forceinline float8_t &operator=(const float8_t &a); #else /* __KERNEL_AVX2__ */ float a, b, c, d, e, f, g, h; @@ -44,9 +47,9 @@ struct ccl_try_align(32) float8 #endif }; -ccl_device_inline float8 make_float8(float f); -ccl_device_inline float8 -make_float8(float a, float b, float c, float d, float e, float f, float g, float h); +ccl_device_inline float8_t make_float8_t(float f); +ccl_device_inline float8_t +make_float8_t(float a, float b, float c, float d, float e, float f, float g, float h); CCL_NAMESPACE_END |