gpu-allocator icon indicating copy to clipboard operation
gpu-allocator copied to clipboard

⚠️ NOTICE for `metal` users on `gpu-allocator 0.26` ⚠️

Open MarijnS95 opened this issue 1 year ago • 1 comments

gpu-allocator 0.26 was just published with metal support! Unfortunately the metal-rs crate that is used is heavily unmaintained, and some functions used by gpu-allocator are not yet available in the upstream metal-rs release. Attempts to contribute have thus far gone unnoticed.

This was worked around by a patch in Cargo.toml which does not translate to the crates.io release, so anyone turning on the not-default metal feature will get a compilation failure in gpu-allocator.

The workaround is to adopt the same [patch.crates-io] into your workspace root, while we work to resolve this issue upstream:

https://github.com/Traverse-Research/gpu-allocator/blob/cbf52992b972c6cba6b1ba0530197642614b4154/Cargo.toml#L100-L101

MarijnS95 avatar Apr 30 '24 14:04 MarijnS95

A planned upgrade to objc2 and objc2-metal is happening in https://github.com/Traverse-Research/gpu-allocator/pull/225 :tada:

MarijnS95 avatar May 01 '24 15:05 MarijnS95

This was fixed by using stable metal 0.29 complete will all necessary changes in the published gpu-allocator 0.27 release.

MarijnS95 avatar Oct 03 '24 09:10 MarijnS95

For any users upgrading that are still on metal-rs, it's relatively trivial to unsafely transmute the structures back and forth as a stopgap solution.

Jasper-Bekkers avatar Oct 03 '24 09:10 Jasper-Bekkers

Note that the metal-rs -> objc2 conversion will only come in the gpu-allocator 0.28 release, so you can also stick around on the older version for a little bit while still benefiting from the fix for this issue in the current-latest 0.27 release.

MarijnS95 avatar Oct 03 '24 10:10 MarijnS95