The validation executor's Vulkan side runs on Linux through native ICDs
and the runtime. No lane records MoltenVK rows any more, and no MoltenVK
venue is wanted. This commit deletes the MoltenVK backend from the
store up.
Before the deletion, git grep at e35d9098c0 showed these readers of
Backend::Moltenvk rows outside tests:
- C3's input (c3.rs: C3Input::moltenvk, the baseline, the old-mismatch
ledger), its venue kind (venues.rs), the evidence census
(index.rs: the index's candidate table and evidence_status);
- the store's own layout check, shard rewrite and rekey;
- the batch's worker store, which linked the other backend's rows;
- the corpus-moltenvk binary, the host and driver checks
(candidate.rs, platform/compute.rs) and candidate_batch's CPU refusal.
Every one goes or loses its MoltenVK arm here. No reader is left.
What goes:
- The corpus-moltenvk binary (Cargo.toml entry included), and
Backend::Moltenvk and BatchBackend::Moltenvk. Backend keeps one
variant, Vulkan. Collapsing it is a follow-up commit.
- corpus/observations/moltenvk: 64 shards, 4,809 rows. 4,802 of them
are old-engine rows in about 60 slots: apple-m3-max-moltenvk 1,137,
the byte-exact-* and local-* runs, and probe slots. The other 7 are
engine rows of apple-m3-max-moltenvk@engine.
corpus/observations/refusals/moltenvk: 16 shards, 6 refusals.
- The store's MoltenVK shards: its layout check, the aligned rewrite,
the refusal follow and the rekey now read the Vulkan backend alone.
The batch's worker store links only the Metal rows. The index stores
the Vulkan candidates alone, and evidence_status's rows have no
moltenvk column (corpus-status's evidence line loses it too).
- C3's MoltenVK venue (VenueKind::Moltenvk, c3-venues.json's
apple-m3-max-moltenvk entry) and with it the old engine's baseline:
- Population::OldEngineMatched, the baseline closure and the "new
mismatch" count (SlotReport::new_mismatches);
- the old-mismatch ledger (LedgerRow, C3Report::ledger, stale_causes,
unexplained);
- the reviewed list's old_mismatches part (OldMismatch,
ListPart, EntryRow::part), and Venues::baseline and by_environment.
The venue list's MoltenVK-driver check goes too. VenueDevice's
metal_environment_id, which only an Apple GPU's venue device set,
goes with Venue::identities_compared_with: a venue run is held to
all of its devices' identities.
- c3-reviewed.json: the 12 old_mismatches entries (all signed off),
and the 10 fast_math_regrouping readings whose only observation was
the apple-m3-max-moltenvk@engine slot. These are the linked-single
radix 5/7/11/13/15 zero-write cases, two each, all signed off. A
reading must list an observation, and theirs named a slot that no
longer exists. A regrouping mismatch of those cases on another venue
now reads unreviewed until a reading lists that venue's row. The 12
apple_reading entries are untouched; none named a MoltenVK slot.
- corpus/authored-compile.tsv: the moltenvk-m3 column keeps its cells
but drops their artifact digests (2,255 cells). Only a C3 venue's
profile keeps a digest, and moltenvk-m3 is no venue's now. This is
what a bless writes; the profile itself stays, since the translator's
tests read it.
- scripts/rerecord-venue's moltenvk kind (and its Homebrew validation
layer path), and scripts/rerecord-commit's MoltenVK build, install
and shard paths. docs/VALIDATION.md loses corpus-moltenvk, and its
venue list names what each venue covers.
- In the docs, the robustness leg's "profile-leg" (validation README,
corpus README) is now "profile", which 79d95a2887 missed.
What C3 still decides: per venue of c3-venues.json, lavapipe on arm64
and x86 (the public cases) and the 780M, the Iris Xe RPL-P and the RTX
5080 Laptop (every Metal-qualified case), each case's verdict in the
venue's engine slot by the same rules as before (match, reviewed,
device_gap, out_of_scope, reference_gap, mismatch, refused, stale,
missing). It holds when every slot holds, every reviewed observation
holds, every listed reference gap is recorded, every entry and recorded
reference gap is signed off, and no sign-off is refused. It no longer
holds anything to an old-engine population, counts new mismatches
against one, or keeps a ledger of old-engine mismatch causes.
Tests:
- c3/tests.rs: the synthetic MoltenVK venue becomes a native GPU venue
(GPU, Metal-qualified, still described by the moltenvk-m3 capture).
Deleted: the baseline test (moltenvk_must_cover_every_case...), the
ledger test, and the Apple-GPU Metal-environment test.
Rewritten: the population tests (two populations now) and the
reference-gap test (on lavapipe's public population). The schema test
checks its review fields on a reading. The venue checks lose the
baseline and driver cases.
- index.rs and store.rs tests run their toy rows as Vulkan's. The
cross-backend checks have no second backend and go.
- vulkan_batch/tests.rs: the MoltenVK batch test goes. The install test
refuses a Metal batch's record in place of a MoltenVK one.
- tests/integration: the store-layout and worker tests drop
corpus-moltenvk. fast_trig_within_apples_bound reads the Vulkan store
and wants one row per venue (5). It wanted 10, which the robustness-off
and MoltenVK rows made up.
Device-level MoltenVK accommodations stay for the follow-up commit with
the MSL helper, once a grep shows no Vulkan run on macOS: the loader
word, MoltenVK's withheld diagnostics, coverage's robust-buffer host
class and the pipeline flag.
Verified: cargo fmt; no committed observation path, C3 list entry, venue
or script names the MoltenVK backend (git grep). The compile gate of the
Q3 commits follows as a potluck job.
The ruling Q3: the validation executor runs each case in one context,
which enables every robustness feature its device states. Its second
leg (every robustness feature off, the ID@engine+robustness-off slots)
measured an encoding that metal2vulkan-runtime never runs, since the
runtime's floor fixes the robustness it enables. The tier table keeps
both of its compiles: they are translator coverage of what the runtime
ships, so coverage::Leg stays as the tier table's type alone.
Deleted:
- the executor's leg: corpus-vulkan's and corpus-moltenvk's
--robustness-off, the device worker's leg, engine_slot's leg (an engine
slot is ID@engine or ID@engine@P; an ID@engine+robustness-off is no
engine slot), the enable lists' leg (engine_list enables what the
description states), and the leg in a row's environment and census
(ExecutedCensus.leg, environment.robustness.leg) with its validation;
- the batch's legs: corpus-vulkan-batch takes no --leg. Its passes are
Pass::Engine and Pass::Metal, so a done-list line names "engine" where
it named "stated", and a log is CASE.engine.txt. Its report lines carry
no leg= field, and batch-slowest names pass=engine;
- the authored compile census's robustness-off profiles: a profile is
its committed stem (ProfileStem, which was ProfileLeg); a label with a
"+" names no profile. corpus/authored-compile.tsv loses its 9
+robustness-off columns mechanically. Every other cell stays, and the
reader takes the new layout in this commit. The rows are re-blessed
at the next named pin. the_committed_expectations_parse holds the file
to what a bless renders. No test is expected to read red until the
bless, since no kept cell changed (unaudited until development's census
runs);
- C3's legs: a venue lists no legs and has one slot (c3-venues.json
drops its legs fields). c3-reviewed.json drops the 12 observations
recorded in robustness-off slots;
- the committed rows of the +robustness-off slots: 193 rows and
refusals out of corpus/observations, which empties and removes 44
shards. "leg":"stated" is stripped from the remaining rows' census and
environment;
- scripts/qualify-public-cases' second run per case, and
scripts/rerecord-venue's --leg; docs/VALIDATION.md's robustness legs.
corpus-triage's usage, corpus-status' --c3 help and the census's file
comment say "profile" where they said "profile-leg".
Verified: cargo fmt. The compile gate follows as a potluck job.
What: Device::from_queries refuses a description whose maxPushConstantsSize is below the 256
bytes every stage's push window is lowered for, with a typed Unsupported{PushWindow} naming the
MaxPushConstantsSize limit (crates/metal2vulkan/src/device/derive.rs, the floor checks of
from_queries). The runtime's floor (metal2vulkan-runtime's floor list) requires
maxFragmentOutputAttachments >= 8. All 15 committed device profiles report 8, and so does every
matrix card.
The committed profile set keeps only devices at or above the floor:
- roadmap-2022 and lunarg-desktop-baseline-2023 are deleted;
- vk12-floor and swiftshader move to profiles/below-floor/, inputs of the from_queries refusal
test only;
- runtime-floor, derived from the runtime's floor by scripts/regen-device-profiles and held
equal to it by a test, is the floor every test compiles on.
A test of a below-floor form now runs on runtime-floor without the feature that form stands in
for, labelled "below the runtime's floor" (pipeline::testing::profile_without, PROFILE_F,
device_f, FORMATLESS_FLOOR). The validation tests name runtime-floor, or derive the device they
need from it (no tessellation, no formatless writes, robustImageAccess alone, no device
addresses).
Why: the runtime refuses every device below its floor, so translating for those profiles tested
forms no device the runtime opens can ask for. A push window below 256 bytes cannot hold what
the lowering puts there.
Consumer check: no public item of a published crate is deleted. The one removed constant,
FORMATLESS_FLOOR's old value, is in the crate-private pipeline::testing.
Not in this change, re-blessed on development: the golden hashes table
(tests::golden_hashes) and the public fixture expectations (tests::public_fixtures_engine). The
runtime-sources pin (candidate::engine::artifact) follows from the test run at this tree.
Verified: cargo fmt. The suites, clippy and the CPU-ICD run are potluck jobs on this tree, named
when the branch is handed over.
The macOS 27 work packet: the M3 Max moved to macOS 27.0.1, where MoltenVK gives it the M4's
deviceID. Its measurements, its MoltenVK profile, its Metal rows (now the C3 reference) and its
MoltenVK venue rows are taken again, and the tests follow.
Read Metal's NotMipmapped anisotropic footprint through MoltenVK at level 0:
On macOS 27 Metal's anisotropic filter reads a sampler without a mip filter
differently once its level clamp reaches 1/64: the runtime's NotMipmapped form
(nearest mip, lod [0, 0.25]) handed MoltenVK an anisotropic footprint that
was not Metal's NotMipmapped one, and the anisotropic lane failed on the M3
Max under macOS 27.0.1. Through Metal's own sampler (VkProperty::MetalSampler)
with anisotropy and equal min and mag filters the sampler now clamps to
[0, 0]: with equal filters the level has no filter left to choose, and Metal
answers that sampler as NotMipmapped bit for bit. With filters that differ no
clamp reads Metal's answer at maxAnisotropy 2 to 16; that stays a known gap in
docs/FAST-PATHS.md.
RUNTIME_VERSION moves (renumbered once for the composed batch): a run of an unchanged
artifact samples differently.
Verified: metal::sampler unit tests (24, including the new
metals_own_anisotropic_sampler_reads_not_mipmapped_at_level_zero) at a release
build; runtime_lane::anisotropic_filter::anisotropic_samples_answer_within_
their_bounds_of_metals passes on the M3 Max, macOS 27.0.1, MoltenVK 1.4.1
(it failed at the round's first composed tree and at 61a2efc7d3).
Take the M3 Max's macOS 27 measurements on MoltenVK's shared Apple identity:
MoltenVK's deviceID on an Apple GPU is the macOS release and the GPU's
highest families (MVKPhysicalDevice::getHighestGPUCapability), so under
macOS 27.0.1 the M3 Max reports 0x1B000209, the M4's identity, and takes the
M4's driver facts. The owner's rule: an answer fact holds on the shared
identity only where measured on both GPUs; a cost fact follows the M3 Max.
- MetalNormStorageWrites and DepthTestKeepsDenormals, measured on the M4:
re-measured on the M3 Max under macOS 27.0.1 with the fact taken, every
channel and texel Metal's; kept, the evidence in their docs.
- GraphicsCubeGradientRoute stays measured on the macOS 26.7 identity alone;
the shared identity's graphics route stays unmeasured.
- The interlocked pass: on the M3 Max under macOS 27.0.1 split ran about a
quarter faster than whole (wall 721-769 us against 974-1045, GPU 671-719
against 914-964, two runs of three rounds of 30 frames at 1920x1080
RGBA16Float), so the shared identity's row moves from
InterlockedPassWholeFaster to InterlockedPassSplitNoSlower. The M4's own
measurement (whole faster) is in the row's doc and in docs/FAST-PATHS.md's
known gaps. RUNTIME_VERSION 1190 on this branch covers it.
- APPLE_M3_MAX and APPLE_M4 say what the deviceID is.
Verified: the facts and timings on the M3 Max (macOS 27.0.1, MoltenVK 1.4.1)
through runtime-lane tests at the round's first composed tree with these facts; the
device::tests::driver_facts unit tests run at the rebased tip before landing.
Hold the degrade-notice lane to the resolves the device actually makes:
passes_degrade_once_per_kind expected the exact resolve and the device's
rounded one to be announced wherever the driver's RGBA8Unorm average at 4
samples is measured as Metal's, assuming a texture of 8 samples exists. The
M3 Max (macOS 27.0.1, MoltenVK 1.4.1) makes none at 8 samples, so neither
is announced there, and the lane failed. The filter now expects those two
where the average is not measured as Metal's or where the device makes an
8-sample texture.
Verified: runtime_lane::degrade_notices::passes_degrade_once_per_kind passes
on the M3 Max (it failed at 61a2efc7d3 and the round's first composed tree).
Write the tessellation test's vertex output as Metal's compiler does:
authored_tessellation_executes_native_patch_inputs hand-writes its AIR, and
its post-tessellation output carried metadata Metal's compiler does not
write (Xcode 27, every macOS target 13 to 27 checked): air.location_index on
a vertex output. Our AIR reader refused it (Abi(UnknownKey) for
air.location_index on a vertex output), as it should for a key the compiler
never writes there. The output now carries air.vertex_output with its
user(locn0) name, its type name and its argument name, as the compiler emits
it.
Verified: metal::tests::graphics::authored_tessellation_executes_native_
patch_inputs passes on the M3 Max, macOS 27.0.1 (it failed at 61a2efc7d3 and
the round's first composed tree).
Wrap the driver-facts claims test's doc at the line width:
The interlocked-pass sentence the shared-identity commit rewrote ran past
the 100-column doc width. No other change.
Hold the unmeasured-identity test to the macOS 27 identity's split form:
an_unmeasured_identity_takes_its_drivers_defects_alone still expected the
moltenvk-m4 capture to take InterlockedPassWholeFaster, which the shared
macOS 27 identity no longer does (it takes InterlockedPassSplitNoSlower, the
M3 Max's measurement). Found by the device::tests::driver_facts run at the
rebased tip.
Name the format where the formats capture and the product's query differ:
the_formats_capture_is_the_product_queried_formats_of_the_venue_device
compared every format's masks without naming the format, so a failure on
the M3 Max showed two masks and no format. Each assert now names it.
Test-only.
Capture the M3 Max's MoltenVK profile under macOS 27.0.1:
The reference Mac runs macOS 27.0.1 (26A434) now. Its moltenvk-m3 capture
(vulkaninfo --json and corpus-vulkan --capture-formats, Homebrew MoltenVK
1.4.1, vulkan-tools 1.4.350.1) is regenerated through
scripts/regen-device-profiles. Only the identity moved: MoltenVK's deviceID
on an Apple GPU is the macOS release and the GPU family, so the M3 Max now
reports 0x1B000209 (452985353), the M4's identity, and every capability,
limit and format mask is as before. c3-venues.json declares the new
identity.
The two captures now differ only in allocation sizes, which no translation
reads, so they derive one translation key:
- candidate::platform::profiles: a run on the M4 held to the M3 Max venue
stops on the device name alone (the venue's identity guard, not product
behaviour), and proceeds where the venue allows the M4.
- c3::tests: the M4's capture passes check_profiles as a second device of
the venue; the list still refuses it for naming the M3 Max's Metal
environment.
- device::tests::driver_facts: moltenvk-m3 takes the shared identity's facts;
the macOS 26.7 identity (APPLE_M3_MAX), measured but with no committed
capture now, moves to MEASURED_WITHOUT_PROFILE and keeps its coverage
through a description at that deviceID, graphics cube route included.
- tests::engine_sampler_unk: the graphics cube route's test builds the
M3 Max under macOS 26.7 the same way.
Docs: API.md and profiles/README.md say what MoltenVK's deviceID is.
Golden hashes and expectation rows that hold moltenvk-m3's translation key
are left for the round's bless. Verified: the capture on the M3 Max
(regen_device_profiles.py --only moltenvk-m3, check_device_profiles.py);
the unit tests above run at a build of this branch before landing.
Record the Metal rows of the M3 Max under macOS 27.0.1:
The reference Mac's Metal answers, apple-m3-max-macos27.0.1 (Apple M3 Max,
40 GPU cores, macOS 27.0.1 26A434, Xcode 27A266a, Metal toolchain 32023.921,
ORACLE_ABI metal-literal-resources-v48): corpus-metal --batch over every
case the 26.7 environment holds, in three maclock holds of about 6.5
minutes, then --batch-install. 2227 cases ran: 2223 qualified, 4 reference
gaps (the simdgroup_matrix 16x16 cases, GPUFamily10, as on 26.7), no
failure. The 26.7 rows stay.
Against the 26.7 rows: no status changed and 8 outputs moved, every one a
cube-gradient case with identical AIR and inputs (a54af728, 315ca8b0,
391fac4d, 6ce71712, ae7aa91b, b3e5b4ef, dd39e2e5, 649c204a). Those 8 ran a
second time identically. Every other case answers as on 26.7.
Expect the M3 Max's and the M4's MoltenVK captures to share a fingerprint:
fingerprints_distinguish_committed_profiles listed only the two Intel
captures as sharing a fingerprint, kept apart for the Apple GPUs by the
graphics cube route measured on the M3 Max's macOS 26.7 deviceID. Under
macOS 27 MoltenVK gives the M3 Max and the M4 one deviceID, and the captures
differ only in allocation sizes, so moltenvk-m3 and moltenvk-m4 now derive
one fingerprint; the test lists the pair.
Found by device::tests at a build of this branch; device:: (104) and
tests::engine_sampler_unk (8) pass with it on the release build.
Make the M3 Max under macOS 27.0.1 the C3 reference Metal environment:
The reference Mac runs macOS 27.0.1 (26A434), and its Metal rows are
committed (apple-m3-max-macos27.0.1). The switch:
- c3-references.json: the primary is apple-m3-max-macos27.0.1 (Apple M3 Max,
40 cores, 27.0.1, 26A434, Xcode 27A266a, Metal toolchain 32023.921).
- c3-venues.json: the MoltenVK venue's device compares with it.
- runtime_lane::METAL_ENVIRONMENT, the reference and venue tests, and
scripts/rerecord-venue's default name it.
- The parity lines: record_metal and the sequences' record_metal on the M3
Max under macOS 27.0.1. The four scenarios recorded 68, 240, 95 and 36
records; the 64 sequence seeds 8534 records, 0 differences from the model
and no Metal-side gap (seeds 32, 51 and 62 crashed Metal's driver under
26.7; they run under 27.0.1). The 26.7 lines and rows stay.
Verified on the M3 Max (release, --cfg m2v_gpu, the validation layer on):
runtime_lane::driver_deviations::cube_gradients_through_an_anisotropic_
sampler_answer_as_metal passes against the 27 rows (MoltenVK answers Metal
27's cube gradients; it failed against the 26.7 rows); parity::tests::
committed_records_are_current and the 14 parity and sequence lanes pass (their
2 recorders are ignored); the
c3::, candidate::platform::profiles::, candidate::engine::guards:: and
parity::tests:: modules pass (98 tests).
Record the M3 Max's MoltenVK venue under macOS 27.0.1 at product 15b6df4e2bd0:
Rows and refusals recorded by one build (executor vulkan-engine-v181, product
15b6df4e2bd0cb440724ffe07ba95f1ccf6d0a5dd7fb5055598e70c877596734, semantics 1698, oracle
metal-literal-resources-v48) at this commit's product, on the Apple M3 Max under macOS 27.0.1 (MoltenVK
1.4.1, deviceID 0x1B000209). They are judged against the apple-m3-max-macos27.0.1 Metal rows and
were installed by scripts/rerecord-commit --no-commit. No later commit changes the product, so every row installed here stays current.
- apple-m3-max-moltenvk (moltenvk): 4389 rows, 56 refusals, over 2223 cases in two legs
- stated: 2168 match, 23 mismatch, 31 refused, 1 failed
- robustness-off: 2175 match, 23 mismatch, 25 refused
Against the macOS 26.7 rows, per case and leg:
- Of the earlier matches, 2965 still match, none mismatches, and 1 failed (below).
- 13 earlier mismatches and 13 earlier refusals now match; 38 mismatches and 42 refusals remain.
- 1374 runs had no 26.7 row: 1352 match, 14 refused, 8 mismatch. The 8 are the robustness-off
leg of four linked-single radix13 and radix15 zero-write cases whose stated leg was already a
mismatch, and both legs of the two new cases quad-broadcast-first-in-an-arm-metal-speculates
and quad-broadcast-first-in-a-fragment-arm-metal-speculates.
The failed run is authored-four-iteration-loop (3cf0a3f024a5), stated leg. Metal's compiler
connection was interrupted while it compiled the compute pipeline (XPC_ERROR_CONNECTION_INTERRUPTED
after MoltenVK's retries), on both the first try and the --retry-failed run. Its robustness-off leg
matches, and under 26.7 it matched in both legs. Its stated slot keeps the 26.7 row, which C3 reads
as stale. Two msl-4-1 cases the venue's selection did not include also keep 26.7 rows that read
stale.
Verified:
- corpus-moltenvk --batch-report reads this_build=yes for the out directory at the recording tree and at the round's
final tree (the table bless after this commit), which adds only tests, test tables and docs.
- corpus-status --c3 prints the same report at both trees. The MoltenVK slots (stated, then
robustness-off) read: match 2168 and 2175, reviewed 10 and 10, mismatch 13 and 13, refused 25
and 19, ray tracing out of scope 6 and 6, stale 3 and 1.
Versions: RUNTIME_VERSION 1205 -> 1211. RUNTIME_VERSION moves: MoltenVK's NotMipmapped anisotropic
footprint is read at level 0, and the macOS 27 Apple identity takes InterlockedPassSplitNoSlower.
crates/metal2vulkan-validation/runtime-sources.sha256 holds
e74792b15fd66114fb4efcc8e281318bfe1e16a3b8532e90d737834ea5a2add3, the hash of this tree's runtime
inputs (runtime-pin.py, which reproduces build.rs's). Version numbers quoted above are the values
the work's branch built with. Each part's Verified lines name the tree it ran at.
Rolls up everything since 43c46ac8 into a single commit. Its tree is
identical to the tree of private master at
b3c77f2d2b20a432be10591a2129547c10b1c24b.
- A Cargo workspace of five crates under crates/: metal2vulkan (the
translator and the metal2vulkan command), metal2vulkan-runtime (the
Metal API on Vulkan), metal2vulkan-air (the AIR front end),
metal2vulkan-validation and metal2vulkan-devtools.
- Dual license: GPL-2.0-or-later OR LGPL-3.0-or-later.
- docs/: API, architecture, fast paths, how-to, Metal coverage,
refusals, runtime porting and validation guides.
Private-Commit: b3c77f2d2b20a432be10591a2129547c10b1c24b