Repository navigation
fix: align Metal runtime controls with the built backend - #1990
Merged
Merged
Conversation
Resolve the macOS Metal backend once and use that decision for both the MLX CMake build and its C++ runtime-control bridge. Preserve both exactness probe verdicts so failed and skipped QMV retries report what actually ran. Add build-policy coverage, a live runtime-switch probe, and installation guidance for plain Cargo builds and affected older binaries. Validation: - cargo fmt --all -- --check - Plain release Metal runtime-switch probe passed for QMV and buffer budget - Gemma 4 31B QAT auto retry and pinned narrow runs produced identical output - Qwen 3.8 auto retry and pinned narrow runs produced identical output Refs #1988
Make the exactness retry tests honor ambient QMV operator settings and verify that backend-unavailable diagnostics never claim an unmeasured narrow arm. Add English and Korean technical reports for the Metal bridge mismatch, its runtime behavior, real-model evidence, and remaining host coverage limits. Validation: - Full make verify passed before the test-only isolation adjustment - Focused suite passed 16/16 with QMV unset, pinned to 0, and pinned to 1 - cargo fmt --all -- --check Refs #1988
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.
Summary
A plain macOS Cargo build enabled MLX Metal but compiled the runtime QMV setter as a no-op because its bridge used the optional Cargo feature instead of the actual backend setting. This explains the reported automatic-retry failure despite a fresh
MLXCEL_QMV_WIDE=0process passing.Test plan
make verify: passed; after the final test-only adjustment, the affected 16-test suite passed with QMV unset, pinned to 0, and pinned to 1.--features metal,accelerate: real QMV false/true and command-buffer control assertions pass.Runtime validation used M5 Max. The user's original failure and fresh-narrow pass were on M5 Ultra; the corrected binary has not been run there. Cross-host compilation and physical Metal-OFF/CUDA execution remain unvalidated. This changes build wiring and diagnostics, not attention arithmetic.
GB10-only CI remains unverified because its runner is unavailable; merge follows the user-approved exception for this investigation.
Closes #1988
Refs #1987.