Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Apple runtime crashes on Macs with non-Apple-Silicon GPUs
This removes some legacy code that prevented the correct factory from being initialized when used on Macs with non-Apple-Silicon GPUs. Additionally, it removes explicitly setting the storage mode, which was causing Metal API validation to fail on non-Apple-Silicon GPU Macs. ## Storage Mode Explicitly setting the storage mode to shared has been removed. This has no impact on iOS. For macOS, this defaults to managed, which should be appropriately handled by the C++ runtime, per Chris. Per the docs for `MTLTextureDescriptor.storageMode`: > In iOS and tvOS, the default value is MTLStorageMode.shared. In macOS, the default value is MTLStorageMode.managed. ## Testing These changes were tested on an i9 Intel Mac against a file that was reproducibly causing crashes. Post-changes, the file no longer crashes. Diffs= 56d95d200 Fix Apple runtime crashes on Macs with non-Apple-Silicon GPUs (#8301) Co-authored-by: David Skuza <[email protected]>
- Loading branch information