-
Notifications
You must be signed in to change notification settings - Fork 38
Extend support for Apple Silicon #92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
💪 |
|
I've merged the other PR, hence this one needs a rebase and some Clippy fixes. |
|
@emberian : do you want to get this updated so CI passes? |
|
@rvagg : is this worth getting over the line or just closing for now until this is more interest? |
|
worth getting this over the line |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR extends support for Apple Silicon while also refactoring error handling and streamlining unsafe block usage in both OpenCL and CUDA modules. Additionally, the version upgrades in the toolchain and dependencies ensure compatibility with recent releases.
- Changed error wrapping in OpenCL and CUDA modules from tuple to struct-style.
- Added Apple vendor identifiers and strings to support Apple Silicon.
- Updated toolchain and dependency versions for improved language and library support.
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/opencl/mod.rs | Refactored error returns to use struct-style and streamlined unsafe block style |
| src/error.rs | Updated GPUError::Opencl3 variant to a structured format |
| src/device.rs | Added Apple vendor string and vendor ID along with new Vendor::Apple variant |
| src/cuda/utils.rs | Added attribute to suppress unused warnings in CudaContexts |
| src/cuda/mod.rs | Replaced map_err with inspect_err and streamlined unsafe block usage |
| rust-toolchain | Bumped rust version from 1.70.0 to 1.81.0 |
| Cargo.toml | Upgraded dependency versions and updated rust-version to 1.81.0 |
Apple Silicon GPUs are integrated into the SoC and don't use PCI bus. This change ensures synthetic PCI-ID assignment for Apple devices.
@rvagg : with Claude, I got this updated and passing. Ready for review. |
.github/workflows/ci.yml
Outdated
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Install clippy | ||
| run: rustup component add clippy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the right way to do this is add them both to rust-toolchain.toml
simple update of @brandonros original PR on top of #90 (for after that is merged)
Closes #75