f732f769ef02e910ceeefae77ac9a677cc242521
25
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
a7dd2e846e |
Translator: the binder's plan goes, with everything only it reaches, and the TexelRows and YCbCrInPlace forms
The runtime never made a plan (it binds each draw and dispatch by the pipeline's interface), and since the census digests each pipeline's content alone (two commits back) nothing in the tree calls one. What only the plan reached goes with it: - bind: BindState, BindShape and their shapes, BindingPlan and its instantiation (DispatchCommands, DrawCommands, push, descriptor and root-table templates and writes), plan.rs and plan/ (compute, resources, slots), instantiate.rs, resident.rs, the neutral resources' plan side, the heap's member planning and table bytes, the mesh arguments pass (MeshArguments, MeshArgumentsForm, fold_object_grid, metal_object_grid), ExecutionStatus and StatusBits as public items, TextureShape::Buffer, IndirectRef with the four indirect call variants (Dispatch::ThreadgroupsIndirect, DrawCall::Indirect, PatchesIndirect, MeshThreadgroupsIndirect) and IndexBufferRef::fetch_end. Dispatch, DrawCall and IndexBufferRef stay: validation states its cases' calls with them. - error::BindError leaves the public surface; a crate-private BindError of three variants stays as the error of the heap's view derivation, which lower::texture::slot's storage-read check reads (bind::heap::tier_read_gaps). That check keeps only the storage view's format: the sampled-view branch and ImageViewDesc were reached by the plan alone. - vk::DrawCommand, the plan's draw output. - pipeline: ComputePipeline::plan, RenderPipeline::plan; cache: VariantKey::covers and large_buffer_form. - The TexelRows form (bind::texel_rows, LoweringInputs::texel_rows, RuntimeFact and PushField TexelRows) and the YCbCrInPlace form (bind::ycbcr_in_place, lower/sampler/in_place.rs, LoweringInputs::ycbcr_in_place and ycbcr_planes_sampled, RuntimeFact and PushField YCbCrInPlace, PrecisionNote FloatSampleFilter and HalfSampleFilter, Routine::Quad). Only the binder set those inputs. - The tests of the deleted items, and the plan halves of mixed tests. Of 6810 tests (`#[test]` functions in the workspace) 309 leave and 11 come in their place: the lowering halves of mixed tests, kept without the plan (the heap layout, the stage-in stride and region facts, the emulated-simdgroup and bicubic facts, the iris-xe storage classes), and the kept tests of the two renamed files. 50 others are edited to drop a plan half or a deleted item (the api_surface round trips; the simd_emulated, extended-range, recursion, dynamic-root, handles, heap-storage-read and mesh lowering cases). 6512 remain. engine_graphics_binder.rs and engine_heap_binder.rs keep one and two tests and are renamed engine_unattached_colors.rs and engine_heap_groups.rs. - The runtime guard test's list of files the runtime inputs reach without being inputs drops the seven no input reaches since the cut: cache/digest.rs, lower/simd/divergent.rs, lower/simd/workgroup.rs, pipeline/artifact.rs, pipeline/layout.rs, pipeline/stage_io.rs and pipeline/vertex.rs; three of its reasons that named the plan or the binder say what reaches the file now. 559 public items leave (api_signatures.tsv: 55 structs, 26 enums, 140 variants, 245 fields, 52 methods, 24 associated constants, 7 constants, 5 functions, 5 impls). Consumer search, the consumer's development at 92ffbed817, `git grep -w NAME` of each of the 112 removed names: 0 hits for 105; the others are the consumer's own items: TessellationFactors 4 (its Bound::TessellationFactors), YCbCrMatrix 3 (its own string and doc), texel_rows 2 (its own fn), ThreadgroupsIndirect 6 (its own Dispatch enums and rt::Dispatch::Indirect), DrawIndexed 1 (a doc naming MTLIndirectCommandType values), covers 109 and plan 105 (generic words; the `.covers(` calls are its Extent's, the `.plan(` calls its video encoder's rate.plan). Its one import of metal2vulkan::bind is the argument-buffer layout types, which stay. The forms' audit. A texture over a buffer: the runtime's tests::over::every_device_holds_a_texture_over_a_buffer_in_place. A two-plane YCbCr sample: no runtime test; the runtime makes no texture of a two-plane YCbCr format (Gap::TextureFormat, the runtime README's "A format is made where the translator's format table maps it" row), the conformance cases ycbcr_gathers and ycbcr_textures record Metal's answers, and known-gaps-rt.tsv lists the runtime's refusals (ycbcr-gathers-*, ycbcr-texel-reads-420v). Versions: - RUNTIME_VERSION 2550: it covers plan instantiation and the binder's run-time data. Nothing calls those since step 2: the runtime never used the binder, and the own-context executor is gone. A run of an unchanged artifact does nothing different, so the guard hash (runtime-sources.sha256) moves alone, and the RUNTIME_VERSION doc is rewritten to name what it still covers. - SEMANTICS_VERSION 2273: no output changes for any input that still exists. The TexelRows and YCbCrInPlace forms, their facts, push fields and the two notes were reachable only through LoweringInputs::ycbcr_in_place, ycbcr_planes_sampled and texel_rows. Only the binder set those; the runtime sets none. The function key appended each of them only when set, so every surviving key hashes the same bytes. Two type declarations stay where they were, so module words do not move: bool in the bicubic types, uvec4 in the bicubic routines. Byte-identical modules are expected, not verified here; the 252-row hash probe is the check. - ARTIFACT_FORMAT_VERSION 591: the codec tags enum variants by name. The removed RuntimeFact, PushField and PrecisionNote variants leave their tags unused, which cache/mod.rs's rule says needs no bump: an old entry holding one fails to decode, which is a miss. No codec_struct field is removed. That is why SamplerDesc.ycbcr stays. The guard hash (crates/metal2vulkan-validation/runtime-sources.sha256) moves for the bind/ sources this deletes and edits and for vk/draw.rs, which leaves its list. No run of an unchanged artifact changes: what stays in bind/ computes what it did (the heap's tier check takes the same storage format; its removed sampled branch had no caller). Docs: docs/API.md (section 5 is the interface; the binding and plan sections go), README.md, docs/ARCHITECTURE.md, docs/HOWTO.md, docs/VALIDATION.md, the runtime README's DrawInput and identity-domain rows, docs/REFUSALS.md (regenerated; the binder's section goes), api_reference.md, api_signatures.tsv (blessed: removals only), tests/api_surface.rs, the signatures floor (5000), the bind modules' own docs, and the public field docs of PushField, RuntimeFact and SpecKey that named BindState, BindShape or BindingPlan. AGENTS.md: the project table names pipelines and their interfaces, not binding plans; its "core lives in" line stays true (bind/ still holds what the lowering reads). Verified on 31692939d4, this commit's tree (steelbrain/cutbinder-probe-6): job m3-max-68107, fmt, signatures, refusal surface, clippy -D warnings (workspace plain, --cfg m2v_gpu, --cfg m2v_cpu_icd; the translator with no feature and with each alone; the AIR crate alone), workspace Rustdoc -D warnings, each crate's private intra-doc links at 0, api-docs; job m3-max-68109, the product, validation and conformance suites, doctests, and on lavapipe the validation and runtime suites under --cfg m2v_cpu_icd, the conformance replay and the public cases' qualification. |
||
|
|
2bbf157668 |
DevicePolicy::default() is the identity domains; the resident-table domains become RESIDENT_TABLES
What: DevicePolicy::default() now returns the identity pointer and handle domains, the policy
metal2vulkan-runtime compiles under. DevicePolicy::UNTRUSTED is renamed RESIDENT_TABLES. It stays
for the validation executor's own context (candidate/platform/compute.rs and the engine tests
that build a resident root and a handle table themselves) and for the translator's tests of that
lowering, which name it where they took default() before. The runtime takes default() instead of
setting the two fields itself.
Every tool that took default() now compiles under the runtime's policy:
- the command line's --profile;
- the compile worker;
- the authored compile census, the corpus translation audit and corpus-pipeline;
- acceptance, the tier table and specialization attempts;
- the golden table, whose devices take default() (its policy field goes).
Why: the planner's ruling (b), one policy constructor, so a tool and the runtime agree on the
policy. The description can still differ: --profile takes the profile's description, while the
runtime takes the device's, restricted to the features it enables. repro.rs and README say so.
Docs:
- README's --profile paragraph and the command's help text.
- API.md section 1: the identity domains are listed first, as the default; the resident-table
domains are the validation executor's.
- device/mod.rs, policy.rs and profile.rs.
- api_signatures.tsv renames the const.
- api_preview's buffer carries a device address equal to its gpuAddress, as the runtime makes it.
No SEMANTICS bump. For a given description and policy, the translator's output is unchanged. The
profile fingerprint covers the policy, so every cached artifact and golden cell whose output moves
does so under a changed key; the golden check reads those cells as re-keyed, a bless due. No bless
here.
Consumer search (consumer-uses.sh) at the consumer's development e76e2ffeb4 and 46 lane refs
younger than a day:
- UNTRUSTED, RESIDENT_TABLES, PointerDomain, HandleDomain and from_queries: 0 hits.
- DevicePolicy: 13 lane refs only, all in the deleted runtime's policy struct (fields this tree no
longer has); none on development.
Expected census at this commit, not yet rerun: m3-max-62608's identity column, taken at
|
||
|
|
e149088bd0 |
CLI: --device returns, as the way to compile for a runtime's device
|
||
|
|
06a35ed9e4 |
CLI: the device file a runtime repro bundle held is gone; a bundle holds the profile
`metal2vulkan --device <device.json>` read a ReproDevice (a device description and policy), the device file a runtime's FALLBACK bundle would hold, and repro.rs said "a runtime may write one for a library or pipeline creation it refuses". No runtime writes one: metal2vulkan-runtime has no repro or env_vars use and reads no METAL2VULKAN_* variable (git grep at |
||
|
|
b14c6a7101 |
Emulated tessellation goes: a device without tessellationShader refuses the function
The runtime's floor requires tessellationShader, so on every device the runtime opens a
post-tessellation vertex function runs through the device's tessellation stages. The emulation
was a second form: it ran the function as a plain vertex stage that drew Metal's tessellator's
triangles itself, from the draw's records, which a compute scan wrote before each patch draw. Now a
device without tessellationShader refuses the function (Unsupported{Tessellation}, needing
VkFeature::TessellationShader), and the command line answers FALLBACK there.
Removed:
- lowering: lower/tessellation/{emulated,tessellator,work}.rs, wrap_entry, Emulation, emulates;
EvalPlan's base_instance and emulated; Declared's emulated globals; the emulated
[[base_instance]] source; PushField::TessellationChunk; stage_io::primitive_id_varying.
- pipeline: EmulatedTessellation, GraphicsState::emulated_tessellation, TessellationStage::emulated,
LoweringInputs::tessellation (and InputsFrom::Vertex's tessellation field and its key bytes),
link's emulated_state, RuntimeInput::TessellationDescriptor, SyntheticBinding::TessellationWork
and TessellationRecords; primitive_id_carried_on is primitive_id_varying_on again.
- binder: bind/tessellation_scan (tessellation_scan_module, TessellationScanKernel,
TessellationScanModule), TessellationDispatch, TessellationRecords,
DrawCommands::tessellation_dispatch, WriteSource::TessellationWork and TessellationRecords,
StatusBits::TESSELLATION_RECORDS_OVERFLOW and RECORDS_FAULTS, StatusReport's
tessellation_records_overflow and TessellationRecordsFault. FactorTemplate keeps only the
control stage: FactorSite goes, and its fields are push_offset and factor_binding, with the
patch index binding always present. The mesh scan's first-fault test reads its own bit. Bit 8
of the status word is unreported.
- tests: tests/tessellator (the emulated tessellator against its model), the emulated tests in
engine_tessellation (now asserting the refusal on profiles without the feature), the emulated
fixtures in api_tests and graphics tests, owned_divisions' scan sweep, and api_surface rows.
The key test keeps its native half: a vertex function's key is the same for every
tessellation state.
- validation: build.rs's runtime inputs lose tessellator.rs and work.rs (factors.rs stays: the
binder sizes factor ranges by factor_bytes). The acceptance and coverage tests expect the typed
refusal on roadmap-2022, vk12-floor and swiftshader.
Docs: README and the command's help say a post-tessellation function needs tessellationShader;
API.md's tessellation section states the refusal; the two tessellation precision notes no longer
mention the emulation; docs/REFUSALS.md and api_signatures regenerated (Tessellation now names
VkFeature::TessellationShader instead of MaxStorageBufferRange).
SEMANTICS_VERSION 2220 is in this commit (placeholder; main renumbers): what the translator emits
for a post-tessellation function on a device without tessellationShader changes (a refusal), and
the vertex key loses the tessellation state. ARTIFACT_FORMAT_VERSION 564: the codec loses
EmulatedTessellation, TessellationStage::emulated and three enum variants. RUNTIME_VERSION stays
at this series' 2543. The runtime pin is updated.
Consumer check (consumer-uses.sh):
consumer: development 7ea4edc2fb; 72 refs (development + steelbrain/* younger than a day)
TessellationDispatch: 0 hits (code); link-order lists only
TessellationRecords, TessellationRecordsFault, tessellation_scan_module, TessellationScanKernel,
TessellationScanModule, TESSELLATION_RECORDS_OVERFLOW, RECORDS_FAULTS, tessellation_dispatch,
TessellationWork, EmulatedTessellation, emulated_tessellation, TessellationChunk,
RuntimeInput::TessellationDescriptor, scan_kernel, max_patch_triangles, wrap_entry, FactorSite:
0 hits (code)
tessellation_records_overflow: 0 hits on development. It is USED on consumer lane branches
(steelbrain/quiesce and others), but only as the name of a local function in
reims-vgpu-vulkan/src/gpu/command.rs, which answers the old runtime's
CommandBufferError::TessellationRecordsOverflow. It does not read this field, and this tree's
runtime has no such error.
Verified: nothing yet (a compile job is owed).
|
||
|
|
fce83ac2cf |
Docs: what the runtime does now, where a line named the deleted one
The rename gave metal2vulkan-runtime to the new runtime, so every line written while the name meant the deleted runtime read as a claim about the live one. Each was read against the new runtime's code: - The precision notes no longer say the runtime announces a kind or a code of its own (it announces none; the conformance suite maps notes to codes), nor what a device Device::new made records (only Device::from_queries remains). The notes the runtime carries stay: DepthStencilState::precision_note, RenderCommandEncoder::DEPTH_BIAS_NOTE, BlitCommandEncoder::GENERATE_MIPMAPS_NOTE, RenderPassDescriptor::precision_note, Texture::precision_note. - An inert kernel's dispatch: the runtime records it like any other. - API.md: the runtime takes no unit-axes variant, and runs a partition-oblivious kernel's every direct dispatch in its tiles (from the runtime's pipeline module docs). - The translator's profile docs: no runtime announces mesh draws, reads YCbCr in-place facts, keeps a bind-offset key or runs a view check. - An aliased-import defect: the runtime has no use_host_ram. - derive.rs: no runtime reads the allocation limits. - texel_rows.metal names the test that runs it now (aliased_encoders). - docs/RUNTIME-PORTING.md is deleted with its README row: 216 of its 351 runtime items no longer exist, and each runtime item's rustdoc names its Metal counterpart. - CHANGELOG 0.2.0: no fast-path switches, announced codes or queue-switch check. Not built yet; the gate for the whole pass follows. |
||
|
|
9a1c8fe6dc |
metal2vulkan-rt takes the runtime's name: metal2vulkan-runtime, published
The cutover's last mechanical step. The old runtime is deleted, so its name is free: the crate moves to crates/metal2vulkan-runtime, its package is metal2vulkan-runtime and its library metal2vulkan_runtime, and every reference in the tree follows (sources, tests, scripts, CI, generated tables and docs). It is now a published crate, as AGENTS.md said it would be once it took the name: version 0.2.0 with the other two, the translator pinned exactly (=0.2.0, as the translator pins the AIR front end), documentation, keywords and categories, and copies of the repository's four license files, which the published-crates test now holds equal to the root's for three crates. CI packages it with the others. Prose that said it was unpublished, or counted two published crates, says three. AGENTS.md: facts only. The crate table row, the published-crates and version sentences, and the paragraph on the old runtime, whose name the runtime now carries (listed for the owner). Made by one script run on this tip. Verified by the job named in the landing note. |
||
|
|
aaa3213887 | Translator cutover: first trial-compile fixes (imports, the half pair, push tests, removed routes) | ||
|
|
53f3e522e9 |
API.md: section 9 is the catalogue of the precision notes rt carries
Section 9 was the deleted runtime's notice catalogue: its message sink, announce_each, lowering_refuses, DegradeNotice, exactness(), degraded_objects and the METAL2VULKAN_LOG_*, DUMP, QUEUE_TIMES, PENDING_AUDIT and ENCODER_* diagnostics, none of which rt has. - The intro now states rt's model as its code has it. Each note is fixed per operation (module, pixel format, descriptor or state) and given through six accessors: ComputePipelineState and RenderPipelineState::precision_notes, Texture, SamplerState, DepthStencilState and RenderPassDescriptor::precision_note. Two constants carry notes too: BlitCommandEncoder::GENERATE_MIPMAPS_NOTE and RenderCommandEncoder::DEPTH_BIAS_NOTE. A note is never fatal, and rt prints and sends none (its non-test sources hold no eprintln, log or sink); the consumer reads them. - The 87 entries whose code a PrecisionNote variant backs stay. Their text no longer names the deleted runtime (compressed-texel-decode, bicubic-filter-arithmetic, swizzled-opaque-black-border). Their trigger is rt's where the deleted runtime's stood beside it (device-filtered-mipmaps, shared-exponent-kept, compressed-texel-decode). They no longer say when a deleted runtime announced the note, and they drop the blit, fill and clear parts that only that runtime noted (shared-exponent-kept, device-nan-encoding, device-color-conversion, device-pack-conversion). Their driver-fact text is left for the translator-switch commit. - The 165 entries no note backs go: 59 performance, 104 precision and 2 validity kinds of the deleted runtime. - Section 8's last paragraph names metal2vulkan_rt::Error, REFUSALS.md and rt's README. The guide's opening line and README's row say precision notes. tests::fast_paths reads the catalogue only for the codes of its ledger notes, all PrecisionNote codes, which stay. Section 10 still names some deleted codes; that is a follow-up. |
||
|
|
4d3daeace8 |
Docs: the runtime is metal2vulkan-rt; HOWTO's sections on the deleted runtime give way to rt's README
metal2vulkan-runtime is deleted, so the user-facing docs name metal2vulkan-rt as the runtime:
- README.md: the crate table's runtime row is metal2vulkan-rt (not published yet); two published
crates; the git dependency and both README links name it; the runtime needs a Vulkan 1.3 device
with its README's floor; the sentence on the deleted runtime's repro bundles goes.
- CONTRIBUTING.md: the layout lists metal2vulkan-rt and metal2vulkan-conformance; the gate drops
`-p metal2vulkan-runtime` and gains the conformance suite's line, as AGENTS.md's gate has it;
two published crates for the signatures and the license copies; the refusal check reads the
runtime's refusal enums (the deleted runtime's `Problem` is gone).
- docs/VALIDATION.md: the gate as CONTRIBUTING's; "the new runtime" is the runtime in the matrix
rules and the command replay (the record keys and `harness --runtime new` keep their names).
- docs/HOWTO.md: the sections on the deleted runtime's shader cache, host memory (no-copy
buffers, unmapping, copied host buffers, guest RAM) and exported memory described its API
alone; each is now a pointer to rt's README (The cache directory, Imported blocks, Exported
blocks and Exported surfaces), stating only what that README states. Section 4 loses the
deleted runtime's repro bundles; section 8 loses its pipeline names, its start-up checks, its
suspend-time measurements of its own calls and its exit-handler probe, keeping the driver facts.
- docs/ARCHITECTURE.md and the CI workflow's comment name the runtime as metal2vulkan-rt.
Left for the translator's commit (part 2): FAST-PATHS.md and the DevicePolicy text in README,
CONTRIBUTING and VALIDATION's golden-table paragraph ("The old runtime's translations do not
move"), which follows the matrix's old-path rule.
Verified: the compile job is named in the hand-off.
|
||
|
|
737ccbf81a |
metal: the resource ID word, its spec and test vectors
Under the identity binding domains a guest computes a texture's or sampler's gpuResourceID itself, with no round trip: the index the consumer grants in the low 32 bits and a word in the high 32 bits that is a pure function of the Metal descriptor. The guest's port needs the word specified and a file of vectors both sides check. - metal::resource_word::TextureWord::of(pixel_format, swizzle): bits 0-11 Metal's border texels after the swizzle (the existing border_texels rule), bit 12 the out-of-bounds alpha of a format without alpha, bits 16-31 the MTLPixelFormat raw value, so a texture's word is never 0. None for the placeholders and the formats the translator holds no texture of or only copies. - The sampler word is the existing SamplerWord, unchanged. - docs/RESOURCE-ID.md: the ID's layout, the index classes (0 nil; storage-capable textures 1 to 4,095, valid in both arrays; other textures 4,096 to 65,535; samplers 1 to 3,999), both words' bits and the level rule, and the vectors file. README's documentation table lists it. - crates/metal2vulkan/tests/resource_words.tsv: 392 vectors (every pixel format with a word under the default swizzle, each channel of seven formats from each other source, every sampler field through its values, the level clamps around the points the nearest level turns at, and one descriptor with every field changed). tests/resource_words.rs recomputes every line through the public API and holds the file equal to what the generator writes; an ignored test blesses it. - api_surface lists the new module; api_signatures regenerated. Verified: - msi job 40810 at the same tree: clippy -p metal2vulkan --all-targets --all-features -D warnings, rustdoc -D warnings, nextest 18 of 18 (resource_words, the TextureWord unit test, api_surface, api_signatures). - msi job 40811 at the same tree: clippy under --cfg m2v_gpu and --cfg m2v_cpu_icd. - msi job 40809: the bless test wrote the vectors; the combined sampler line (0x58f6ab53) and the A8Unorm and R8Unorm texture lines checked by hand against the bit tables. |
||
|
|
ab139e4b6e |
RUNTIME 2366: Runtime FALLBACK repro bundle at a creation refusal (default-off diagnostic)
What: metal2vulkan-runtime writes the FALLBACK repro bundle the command line writes for its own failures when it refuses a library or pipeline creation, where METAL2VULKAN_REPRO_DIR names a directory (unset, nothing is written). - The CLI's bundle writer moves into the library as the hidden crate-root module metal2vulkan::repro (feature serde), shared by the binary and the runtime. A bundle's directory is named by its content (metal2vulkan-repro-<16 hex>), written under a temporary name and renamed, so an identical failure is written once, across threads, processes and runs. The CLI's own bundles keep their files (input, profile.json, the descriptor files, repro.sh, repro-command.txt, failure.txt); only the directory's name changed, so a bundle written before still replays. - The CLI takes --device FILE in place of --profile: the JSON of a DeviceDescription and DevicePolicy (ReproDevice), which builds the runtime's own compile device. - The runtime hooks each creation where its refusal returns: a library of a metallib, a function's lookup, every compute and tile state (ComputePipelineState/TileState::create_adding: creations, added binary functions, archive adds) and every render state (GraphicsState::create_reflecting). It bundles Unsupported, NotImplemented and Compile refusals but a cancelled compile and a name the library lacks (Metal's own nil); never Invalid/Nil/MetalError. The bundle holds the library's bytes, device.json, the request as the CLI's options and descriptor files, and failure.txt with the call, the refusal and what the command does not replay. That list comes from a full destructuring of the compute, tile and render descriptors (and the stage functions): a new descriptor field fails to compile in repro.rs until it is replayed or listed. - Bounded: at most 32 bundles and 256 MiB per process; past either nothing more is written and one line says so. Written on the refusing thread; the call returns the same refusal; a write failure is said once. Each bundle is named in one line through the device's message sink (id name metal2vulkan-repro). The runtime's metal2vulkan dependency gains serde. - Not bundled: mesh states (no CLI mesh path), a dispatch's or draw's later variant, driver VkPipeline makings, Metal-source libraries. Docs: env_vars registry, README CLI, docs/HOWTO.md section 4, the runtime README's Errors section, the CLI help. Tests: runtime CPU tests of the bounds (a tally with the seam's limits); a lavapipe/GPU device test (ob3_stage_input with no stage-input descriptor: one bundle with the expected parts and command, device.json rebuilding the runtime's compile device by profile fingerprint and answering the same refusal, none for a second identical refusal or a missing name, none without a directory); CLI tests replaying library-written runtime bundles (compute, and render with a vertex descriptor) through repro.sh to the same FALLBACK, and --device compiling what --profile does. Verified at ae56b195e9 (msi, m3-max-32986): metal2vulkan cli, api_surface and api_signatures 25 passed; runtime repro tests 9 passed; clippy -p metal2vulkan -p metal2vulkan-runtime all targets, all features 0. Lavapipe (m3-max-32978): repro_device writes one bundle that the CLI replays to the same refusal; a second identical refusal writes nothing. |
||
|
|
d6d695d951 |
Link the tests' and the tool's void vertex functions unrasterized, as Metal makes them
m3-max-5121 (the whole metal2vulkan suite at ffc6619794) failed eight tests on the link's RasterizedVoidVertex refusal: - five link tests (render.rs) replaced a vertex stage's io with one that writes no position; they now keep the position (positioned); - engine_link's graphics-state test linked ob3_index_buffer, a void vertex function, rasterizing; it now links it with rasterization disabled, the one form Metal makes of it; - the command line compiled a void vertex function with no fragment as a rasterizing pipeline (cli's ob3_vertex_input test): with no --fragment it now asks whether the vertex function returns a value and compiles a void one with rasterization disabled (README says so); - the new link test ran on vk12-floor, whose vertex stage stores nothing, as the void function does; it runs on lavapipe's profile. (cherry picked from commit 5da2f008274b04019121fe173adb98efa4f3ec26) |
||
|
|
adef203530 |
Describe each driver deviation's route as the code takes it now
One work packet, landed as 10 commits (262093ec48..8e4bfa28b4 on archive/development-linear-2026-10-28), in order: * Describe each driver deviation's route as the code takes it now The DriverDeviation, VkProperty and driver-table docs still named the exact emulations the native-arithmetic change sets deleted (Metal's libm, division, denormal flushing, NaN selection, min/max picks, the emulated sampler, the color, storage and Depth16 write roundings, the depth stand-in). Each variant's doc now says what a profile that takes it gets and what one without it gets: the device's own answer with the precision note recorded, or, where a capability hangs on the answer, its emulation or refusal. - error/mod.rs: DriverDeviation's header and the float-function, NaN, sampler, color-write, FMA, denormal, quantize, min/max, half arithmetic, storage-write, texel-write and Depth16 variants. - device/requirements.rs: the matching VkProperty docs; MetalColorWrites says no module requires it (compile.rs never adds it), and MetalHalfQuantize drops the clamp claim the code does not make. - device/driver_facts.rs: the table preambles and measurement paragraphs (docs and citations only, no row or variant changed); the deleted resolve_rounding::color_resolves_against_metals_rules citation now names the_device_resolve_rounds_as_announced, which holds the row. - runtime_lane/heap_textures.rs: heap_depth_textures_keep_their_bytes, renamed from ..._with_their_twins (no twin exists), with the two driver_facts.rs citations updated. - lower/texture/mod.rs and pipeline/compile.rs: the storage_properties doc and comment list the four properties select_write relies on, dropping the 0x7fc00000 store. Verified by reading each route in lower/ (narrow, fma, denormal, nan, arith, sampler, stage_io/color_write, texture) and pipeline/compile.rs, and by git grep for every cited test and item. * Describe the pixel samplers, routines and color-write inputs as they run now Translator docs that still described the deleted emulated sampler, the cube face fold routine, the compiler-word-bound fit and the shader's own color-write rounding: - pipeline/artifact.rs: PixelSamplerScaling no longer names a linear sample's emulation or a MetalSampler condition; a runtime word's linear pixel sample snaps onto its footprint cell on every device (position::plan plans SnapKind::WordCell with no device test), a word of mixed filters is the device's. ArgumentPixelSamplerScaling says it is recorded on every device for any access but a 2D gather and a sample without a comparison, as select.rs pixel_note does. - lower/sampler/select.rs (pixel_note) and lower/sampler/mod.rs (RuntimeSlot::cells, ::texels): the cell snap holds on every device; the slot's word filter fields are read for a half texel's conversion alone, on a MetalSampler device (half_converts requires !device_texels). - device/profile.rs: FunctionsInlinedAtEveryCall lists the routines that exist (wide-integer divisions, precise fmod, texel conversions, filter sums, sampling routines; no face fold); takes_driver_deviation names the route a deviation's docs give for a driver without it. - error/mod.rs: RuntimeInput::ColorWrites says what the color-write map decides (the conversion that records a note, and NearestEven's half rounding), not a rounding of every output. - bind/color_resolve.rs and its tests: drop the citation of resolve_rounding's cost test, which is deleted. - device/mechanism.rs: drop the trailing comment on the deleted ExactFormsOverCompilerLimit fact. Verified by reading position::plan, select.rs pixel_note and the half_converts branch, spirv/builder/module.rs's routine kinds and every mb.routine site, pipeline/color_writes.rs, and git grep for each cited item. * Describe texel conversion, YCbCr filtering and depth comparison as the device's Translator docs still named the deleted linear-filter emulation, the shader's own depth comparison and the depth twin: - lower/texture/half.rs: off MetalSampler devices the device's sampler filters and the half is its float texel rounded to nearest even (device_texels), not this routine's; the only fetch-computed filter that skips the routine is the in-place YCbCr one. - lower/texture/mod.rs (half_texels): drop the example of a runtime sampler's sRGB raw-code emulation for the `arm` clauses. - metal/format/mod.rs: a two-plane YCbCr texture's linear sample is the device's filter, noted, but where its planes are read in place. - pipeline/artifact.rs (RestrictedDepthRange) and lower/texture/slot.rs (depth_comparison): every comparison is the device's; no shader-made comparison is left to exclude. - lower/sampler/select.rs: a depth comparison reads the texture's own depth image (no twin). - lower/sampler/mod.rs (Sampling::words): list the terms plain_words sums; no linear emulation, level grid or shader comparison term exists. Verified by reading device_texels, half_texels and both its callers, linear.rs filter_note and metal_filtered_ycbcr, depth_comparison's one caller, in_place.rs, and plain_words. * Describe the runtime's YCbCr filter notice and variant kinds as they fire now - degradation.rs: YCbCrFilterNotExact fires on a device that samples through Metal's own sampler alone (linear.rs metal_filtered_ycbcr is None elsewhere), where the stage records HalfSampleFilter or FloatSampleFilter for any two-plane YCbCr format bound; a native sampler announces device-sampling. The module doc drops the exact forms dropped to fit a compiler word bound, whose kind and fit are deleted. - ycbcr.rs: linear filtering of the converted texels is the device sampler's (Metal's own on MoltenVK, announced ycbcr-filter-not-exact); only planes read in place are Metal's filter exactly. Verified by reading lower/sampler/linear.rs, in_place.rs and the runtime's Kinds::of and degrade_bound_formats. * Describe the lanes' and cases' native forms where they named deleted emulations Docs and comments only; no expectation changed. - validation runtime_lane/driver_deviations.rs: the half quantize, min/max, half arithmetic and half widening bullets say what the module does off the deviation (the device's own conversion or quantize, the same NMin/NMax/NClamp noted native-min-max, narrow::from_bits' decode), not the deleted integer rounding, operand picks and exact_answers decode. - validation observation_contract/comparison.rs: HalfSampleFilter and FloatSampleFilter are a YCbCr texture through Metal's own sampler. - validation runtime_lane/pixel_samplers.rs, conformance cases/pixel_samplers.rs: the pixel coordinates reach Metal's texels through the translator's snaps, filtered by the device's sampler. - conformance cases/snorm_tile_store.rs: no exact tile store and no FAST-PATHS row; only extended-range, padded and bfloat attachments take a load pass. Verified by reading the lanes' assertions, select.rs pixel_note, position::plan and narrow.rs. * State the native forms in the doc pages where they promised exact switches - README.md: the promise that every speed-for-accuracy choice has an opt-in exact switch was false for the device's maths, rounding, conversions and sampler, which have none; it now says those are the device's, recorded, and the runtime's choices keep their switches. - docs/API.md: exact_answers selects the runtime's five switches (as policy.rs's exact_answers sets them), not exact forms of the native arithmetic; an unmeasured driver takes each deviation's documented route, not a conservative one; half widening's NaN and denormal are the device's under its own conversion or the float controls; Depth32Float texels are the depth image's, announced where it clamps or flushes; the catalogue intro names the native forms. - docs/ARCHITECTURE.md: the native forms are the device's on every device with no policy choice; the policy's accuracy switches are the runtime's. - docs/FAST-PATHS.md (after the opening section): a YCbCr texture's image form holds Metal's texels exactly and its linear sample is the device's filter; only the in-place form is Metal's filter. Verified against device/policy.rs, lower/arith/narrow.rs, the depth twin's deletion (c11e653acd) and lower/sampler/linear.rs. * Drop the exact golden table from VALIDATION.md's emitter-stability contract 4bf2c22aad deleted golden_hashes_exact.tsv and its table in golden_hashes.rs; VALIDATION.md still described a second table of every sampling fixture under exact_answers. The contract now names the one table. Verified: crates/metal2vulkan/tests/ holds golden_hashes.tsv alone, and golden_hashes.rs names no exact table. * Re-pin the runtime sources after the doc audit The audit's commits edit doc comments and comments only in files the runtime guard hashes (degradation.rs, ycbcr.rs, and translator files the build lists); no run's behaviour changes, so RUNTIME_VERSION stays. Verified: the_runtime_sources_are_the_committed_ones failed with 81ebd500 committed against 8bc0e06b computed, and passes after this pin. * Drop the 0x7fc00000 hand-off from half_write_nans_converted's doc a6e97e7f93 deleted the NaN canonicalization before storage writes (StorageImageClass::SmallFloatQuietNan among it): a half write to a packed small float hands the device the half widened, as to a 16-bit float channel. The doc still said such a write hands it 0x7fc00000, and tied MetalHalfTexelWrites to both kinds, where it states the 16-bit float store alone (lower/texture/mod.rs half_write_nans). Verified by reading half_write_nans and the write emission (lower/texture/emit.rs), which canonicalizes no small-float NaN. * Re-pin the runtime sources after the half-write NaN doc fix metal/format/mod.rs is a runtime guard input; the preceding commit edits a doc comment there alone, so no run's behaviour changes and RUNTIME_VERSION stays. Verified: the_runtime_sources_are_the_committed_ones failed with 8bc0e06b committed against 279b25d4 computed, and passes after this pin. |
||
|
|
48bf2286bd |
Take the test line back out of the README
Content: the tree of `development` at 2839e1fe31, unchanged. |
||
|
|
0cb3502553 |
Sweep every 32-bit integer vertex and attribute format, which needs an integer-declared attribute
The steps this packet landed as, in order: - Name the store actions and resolve filters the pass sweeps already put to Metal - Name the filter sweep's sites after the attachments' own filters, not the row's unrotated ones - Read the function type of a mesh pipeline's own two stages - Read the function type of a visible function, which is a callee rather than a stage - Give the wide stage-in attribute its own entry point, so stage_in_fetch keeps its four - Reflow the import lists the rebase resolution unioned Content: the tree of `development` at be60af4862, unchanged. |
||
|
|
615be46647 |
Mark the README's library sketch as the uncompiled sketch it is
Content: the tree of `development` at 6a35eddd48, unchanged. |
||
|
|
ea89d3f8ed |
Mark the project beta in the README
The README's status notice said alpha; the user moved the project to beta. The rest of the notice (the API, command line, pipeline JSON and SPIR-V may change during 0.x) stands. |
||
|
|
0175289314 |
Batch the development-fast round: tessellation without tessellationShader, primitive ids, mesh tooling, color groups, the vk12 floor, runtime timing and teardown fixes
One commit of the 247 on development-fast (720ef1ce9a..9f46fdf80d), squashed at the user's request. Translator: - Tessellation on a device without tessellationShader: Metal's tessellator emitted as SPIR-V, a one-workgroup scan placing each patch's triangles in Metal's order, and the post-tessellation function as a plain vertex stage (EmulatedTessellationDraws; SEMANTICS 1739, ARTIFACT_FORMAT 419). - [[primitive_id]] on a device without geometry or tessellation shaders, as a flat varying the vertex function writes; indexed lists, lines and points drawn de-indexed (RuntimeGap::PrimitiveIdIndices). - Fragment functions of more colors than the device draws at once, compiled in color groups (PrecisionNote::ColorAttachmentGroups). - Object functions' threadgroup memory from the render encoder; a kernel's mesh draws from an indirect command buffer; mesh payload sizing. - The Vulkan 1.2 floor profile (vk12-floor) and the gates it needs; Metal 27.0.1 answers as the M3 Max. - Overflow tests in the runtime-built modules by the product's high word (NVIDIA's compiler fails the division form), guarded crate-wide by tests::owned_divisions. Runtime: - Color-group passes replayed per group over twin depth/stencil; snapshot and copy-back cost cuts. - Command buffers finish on the queue waiter that saw them; the waiter holds no device handle, so a program's drop after its wait is the device's last. - Every object an encoder was handed held until its command buffer completes; deallocator order and announcements. - Driver defects recorded and announced: ANV counts a visibility sample once per color output (visibility-count-per-color); MoltenVK fails pending work when memory that held a device-address buffer is freed, so freed memory waits for the work in flight (host-deallocator-delayed). - RenderCommandEncoder::set_object_threadgroup_memory_length; Visibility::counting(). Validation: mesh tooling (object, mesh and ICB-mesh cases on both executors), the authoring census closed, the queue storm judged in Metal's unit, load-robust exits and indirect-census bounds, and the golden hashes, printouts, fixture inventory and authored compile census blessed. Docs: FAST-PATHS.md trimmed to a ledger of what is true now; API.md's catalogue and accepted differences, REFUSALS.md and METAL-COVERAGE.md current. Verified on development-fast before the squash: the full suites on the RTX 5080, RTX 3090, RX 7900 XTX, Radeon 780M, Iris Xe, lavapipe and the M3 (MoltenVK and the Metal oracle), lint in every configuration, rustdoc, doc tests, packaging and public case qualification; the timing and teardown lanes x5 on every venue; the authoring-capability census 16656/16656 with 0 unresolved, the vk12-floor translation census at 6139 translated with the slowest row 794 ms and peak 126 MiB. The tree is development-fast's at 9f46fdf80d. |
||
|
|
13b279df1b |
Squash 11203 commits of translator, runtime, and validation work
Rolls up everything since
|
||
|
|
08970cacd2 |
Consolidate translation, linkage, and validation work
Squash 147 commits (2026-08-20 through 2026-08-31) into one change on top of the exact-kernel-grid work. Covers native lowering and pointer/layout construction, AIR intrinsic and funnel-shift coverage, BDA address preservation across aggregate calls, CFG structurization, function-constant and visible-function specialization, the 30-second translation ceiling, the authored-case corpus and linkage validation suite, and refreshed byte-exact MoltenVK evidence. The kernel-grid lowering in this tree supersedes the 324-line variant in the parent commit; that file is reduced to its current 139-line form here. Resulting tree is identical to 7174c7b. Prior history remains reachable at tag pre-squash-backup and branch backup/pre-squash-7174c7b. Claude-Session: https://claude.ai/code/session_01D1u4vU7Mr5QNWrnnRHC8iS |
||
|
|
9ff250502c |
Make exact kernel grids safe by default
Model kernel dispatch geometry as a typed contract shared by lowering, reflection, validation, and the CLI. Cull surplus dispatchThreads invocations using fixed or reflected push-constant grid bounds, make that safe dynamic-grid path the default, and require an explicit whole-workgroup assertion to omit it. Reject unsafe source-barrier kernels before every product emission facade by following the selected AIR entry graph, including quoted LLVM symbols. Exercise the same default contract in authored candidate validation and document the host ABI. Keep corpus audit parent concurrency bounded by feeding isolated translation workers from scratch-backed stdin files instead of creating one feeder thread per row. This removes the scoped-thread exhaustion that aborted late full censuses while retaining child decoding inside the time and memory watchdog. Verified with format checking, warnings-denied workspace clippy and Rustdoc, validation tests at concurrency 16, the unchanged downstream repro, a forced 88,819-row audit completing in one invocation at jobs 16, failure retries, and a zero-read warm pass. |
||
|
|
8b78eaca3b |
Expand macOS 26 AIR translation coverage
Overhaul the validation workflow around sharded authored cases, dependency-exact observations, incremental indexed corpus audits, bounded parallel translation, and native Metal/Vulkan comparison.\n\nExpand native AIR lowering, reflection, linked-function specialization, resource and stage-interface support, and structural CFG/pointer repair across the harvested macOS 26 corpus. Add exact intrinsic inventory, distributed 16x16x16 matrix lowering, explicit opaque tensor linkage, and regression coverage for the newly supported feature classes.\n\nThe final corpus verification accounts for all 88,819 indexed AIR modules under the current product fingerprint: 65,355 translate and validate directly, 23,464 require exact authored linkage, and zero fail or remain unresolved. |
||
|
|
75d3d39d05 | Document Apple trademark notice | ||
|
|
3007485352 | 🆕 Open Source metal2vulkan |