Fix build on Intel Mac (AMD GPU crash + LLVM 21+ patches compat)#1
Open
wendlinga wants to merge 5 commits into
Open
Fix build on Intel Mac (AMD GPU crash + LLVM 21+ patches compat)#1wendlinga wants to merge 5 commits into
wendlinga wants to merge 5 commits into
Conversation
added 2 commits
April 15, 2026 12:54
Points rt64 to wendlinga/rt64:fix/apple-clang which updates plume to call setArgumentBuffer() before setBuffer() on Tier2/non-Metal3 hardware.
Clang 21+ promotes -Wincompatible-pointer-types to a hard error in C mode. Several patch files pass Mtx*/float(*)[4] and similar type-mismatched pointers that the original MIPS compiler accepted silently. Add -Wno-incompatible-pointer-types to keep the existing implicit-cast patterns building with newer LLVM/Clang. This mirrors the existing -Wno-cast-function-type-mismatch flag already present.
a46c129 to
10c0cc6
Compare
Texture and sampler descriptors were bound via gpuResourceID() direct writes (the Metal3 bindless path). Intel AMD GPUs (AMDMTLBronzeDriver) report Argument Buffers Tier2 but do not support the bindless pattern, causing black output after the crash fix. Updated plume (abb241f) now gates all three resource types on useDirectBufferAddresses and uses the argument encoder for textures and samplers on non-Metal3 hardware. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two fixes needed to build and run on Intel Mac with AMD GPU using Apple Clang:
1. Metal crash fix (via rt64 submodule update)
Updates
lib/rt64to pick up a fix for a SIGSEGV at launch on Intel Mac AMDGPUs (AMDMTLBronzeDriver). See wendlinga/plume#1 for the root cause —
setBuffer()was called on a Metal argument encoder without a backing buffer.2.
patches/Makefile: suppress-Wincompatible-pointer-typesClang 21+ promotes
-Wincompatible-pointer-typesto a hard error in C mode.Several patch files contain implicit pointer type conversions (e.g.
Mtx*tofloat(*)[4]) that older compilers silently accepted. Adding-Wno-incompatible-pointer-typesto CFLAGS keeps these building with LLVM 22+.This is consistent with the existing
-Wno-cast-function-type-mismatchalreadyin the Makefile — same pattern, same rationale.
Testing
Verified on Intel MacBook Pro (x86_64, AMD Radeon 555X, macOS 15.7.4) with
Apple Clang 16 (host) and Homebrew LLVM 22 (MIPS cross-compiler for patches).
App builds cleanly and runs without crashing.