Metal: fix simulator regression due to arg buffers (#6181)

This commit is contained in:
Ben Doherty
2022-10-13 14:34:33 -04:00
committed by GitHub
parent affc5be840
commit 6b461b2d89
+5
View File
@@ -106,7 +106,12 @@ public:
// address space. Constant buffers have specific alignment requirements when specifying an
// offset.
#if defined(IOS)
#if TARGET_OS_SIMULATOR
// The iOS simulator has differing alignment requirements.
static constexpr auto METAL_CONSTANT_BUFFER_OFFSET_ALIGNMENT = 256;
#else
static constexpr auto METAL_CONSTANT_BUFFER_OFFSET_ALIGNMENT = 4;
#endif // TARGET_OS_SIMULATOR
#else
static constexpr auto METAL_CONSTANT_BUFFER_OFFSET_ALIGNMENT = 32;
#endif