75c3e49bd6bcc0be3f079c32b6f4ce8d8cea85bb
2127
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
75c3e49bd6 |
Conformance coverage: regenerated for the overlapping-copies row's new refusal
docs/CONFORMANCE-COVERAGE.md quotes each ledger row's reason; the row's words moved with its refusal (python3 -I scripts/conformance-coverage/coverage.py). |
||
|
|
c358d9afd7 |
Runtime: a copy between buffers takes any offsets and size, as plain Metal copies them
A guest's blit copy of 62,302 bytes at offsets 0 and 0 met Refusal::BufferCopyUnaligned. Apple's page for copyFromBuffer:sourceOffset:toBuffer:destinationOffset:size: asks for multiples of 4 on macOS, but plain Metal does not stop or round such a copy: it copies every byte of the range and no other. vkCmdCopyBuffer has no alignment rule for its regions, so the copy is its one region at the offsets and size the call names, and the refusal is gone. Measured with probe crates/metal2vulkan-conformance/probes/blit_buffer_copy_unaligned.m, one universal binary (built in m3-max-69612), copies (source offset, destination offset, size) = (0,0,62302) (0,0,1) (0,0,3) (1,0,8) (0,2,8) (3,5,4097) and the controls (0,0,64) (4,8,4096), each between two Shared, two Managed and two Private buffers, every destination byte read back: - Apple M3 Max, macOS 27.0.1 (26A434), job m3-max-69613: 24 of 24 exact with validation off (AGXG15CDevice), 24 of 24 exact under MTL_DEBUG_LAYER=1 (MTLDebugDevice), which printed only its banner and took every copy. - AMD Radeon Pro 5300M and Intel UHD Graphics 630, macOS 26.7.1 (25G241), job m3-max-69614: 24 of 24 exact on each, validation off. Every command buffer completed with no error. The variant, its basis line, its REFUSALS.md rows and its api_signatures.tsv line go; the runtime README says what Metal measured. The conformance ledger's overlapping-copies row now holds the overlap refusal its first copy meets (the alignment check ran before it). The consumer's checkout names the variant nowhere (git grep BufferCopyUnaligned at reims-vgpu 6d83a5d4f8: 0 hits). Test: every_device_copies_between_buffers_at_any_offset_and_size copies the six ranges between two Shared buffers and reads every byte back; it fails without the change (the refusal). |
||
|
|
da020e5d7b |
Runtime: a compute kernel that reaches an explicit imageblock gets its state; its dispatch is refused
A compute pipeline state whose kernel reaches an explicit imageblock was refused at its make as
Gap::KernelInput of KernelInputKind::RuntimeFact naming ImageblockSize, which every arm64 macOS
guest boot meets once. The state is now made, and what stays refused is the dispatch, where Metal
reads the extent setImageblockWidth:height: set, which the compute encoder does not have:
- interface() takes RuntimeFact::ImageblockSize, keeping its cell bytes as Interface::imageblock,
and leaves SpecKey::ImageblockWidth and ImageblockHeight at the module's default (0 by 0)
instead of refusing them as a specialization it does not set.
- encoder::decide, which the dispatch, prepare_dispatch, dispatch_variant and the main pipeline's
key all go through, refuses a kernel with an imageblock first, as Gap::KernelInput of
RuntimeFact naming the fact (RuntimeFact::name). So no VkPipeline of such a kernel is made:
finish_pipeline has no main key, and a pre-pass gets no key. A dispatch of such a kernel that
writes no memory records nothing and is not refused, as for any kernel without effects.
- imageblock_memory_length_for_dimensions keeps its typed answer, Gap::ImageblockLength, for a
kernel that declares an imageblock: the one recording of Metal's answer for such a kernel
(conformance pipeline-facts-compute-imageblock, M3 Max, 256 bytes at 8 by 4 by 3) settles no rule.
The translator is untouched. Gap and KernelInputKind keep their variants; the docs of
Gap::KernelInput, KernelInputKind::RuntimeFact and Specialization, Gap::ImageblockLength (and its
basis line), the dispatch and the state's make say where the refusal now is. docs/REFUSALS.md,
docs/METAL-COVERAGE.md (setImageblockWidth:height:'s note) and docs/CONFORMANCE-COVERAGE.md are
regenerated. The runtime README's state facts and its known gap are re-worded, with the counts and
jobs kept. The conformance ledger's pipeline-facts-compute-imageblock row moves from case/state to
the facts' label and device (the consumer's own, as for every state) and imageblock_memory_length
(Gap::ImageblockLength). Validation's KernelImageblock requirement doc and its acceptance test's doc
name the dispatch's refusal and the renamed device test.
Test: tests::kernel_input::an_explicit_imageblock_kernel_is_made_and_its_dispatch_refused_as_its_named_runtime_fact
(replacing an_explicit_imageblock_kernel_is_refused_as_its_named_runtime_fact) makes a4_imageblock_extent's
state, reads its imageblock length as Gap::ImageblockLength, gets no dispatch_variant key, and has
one 4 by 2 threadgroup's dispatch refused as Gap::KernelInput of RuntimeFact { fact: "ImageblockSize" }.
|
||
|
|
6adfe028d8 |
Translator: a half vector joined from read lanes keeps their bits; 20 NaN ledger rows
The RTX 5080 Laptop's replay at |
||
|
|
58e9267b6c |
Conformance coverage: the ledger rows the three cards' NaN answers added
docs/CONFORMANCE-COVERAGE.md regenerated by scripts/conformance-coverage/coverage.py after edb361410a added fifteen ledger rows: the ledger count reads 7968 and the gaps table lists the fifteen. Job m3-max-68716 at edb361410a failed only its coverage check on this document (the conformance crate ran 1024 tests, and 1023 passed); its replay on lavapipe read 0 ledger drift. |
||
|
|
41b5038342 |
Player: a commit waits on the CPU for the backend's own surface fill before it goes
What: the replay player's surface backend keeps its last command buffer on its own queue, a fill at a shape's making or the refill a picture owes at its first use (Surfaces::unwaited). The stream's next commit waits for it on the CPU, once, before committing, counted as surface_host_waits (an executed counter, and in the report's surfaces line). New test a_surface_picture_fills_before_its_use_behind_another_queues_long_work plays the same picture behind 256 dispatches over 4 MiB committed first on another queue, and checks the second picture, one refill and one host wait. The runtime README's queue rule now says what Metal and the code do: a command buffer sharing a tracked resource with an earlier-committed one of another queue goes after it only once that one is submitted (the M3 Max rows of that section, jobs m3-max-52432 and m3-max-52415), a cut command buffer that has begun counting as submitted until its next piece waits for an event; an event wait holds only its own queue; the fence sentence says what the code does, Metal's side measured only by jobs m3-max-52186 and m3-max-52188. Its known gaps name a program that relies on commit order between queues for a shared resource with no event or fence. docs/REPLAY-STREAM.md gives the wait and its counter. Why: a_surface_picture_fills_its_shapes_at_their_first_use read the first picture's inverse on the RX 550, the 780M, the Iris Xe and lavapipe at |
||
|
|
f21db0934c |
Conformance: the stage-in cases' lavapipe answers, and StageInKind's doc no longer opens a list
The first replay of the stage-in cases through the runtime on lavapipe (llvmpipe, Mesa 26.2.4, job m3-max-68623) compared every row the old refusal had hidden. stage-in-region-clamps was refused at its one indirect row alone (its 27 other rows Metal's), attribute-format-class-crossings exact, and twelve sites differed, each now a ledger row or a declaration: - The three cases over stage_in_fetch_wide declare simdgroup-access-order, as the other cases whose kernels store at an index of the grid's width do: the runtime's pipelines note the store's SIMD-group access pairs on every device. It loosens the notices site alone. - attribute-format-fetches, five normalized 8-bit formats, on every venue: the pulled fetch's own product of the code and its maximum's reciprocal, which DeviceVertexConversion's recorded bound computes one f32 ulp high of Metal's quotient at 126 of the 256 unsigned codes (127 reads 0x3efeff00 where Metal reads 0x3efefeff). - attribute-format-fetches, the half and RG11B10 formats, on llvmpipe: the device's widening keeps a NaN's payload (0x7fc02000, 0x7ffe0000) where Metal reads 0x7fc00000, under DeviceNanEncoding. Each GPU's rows follow from its own replay. clippy refused StageInKind::IndexedStepRate's doc, whose second line began "1. ", a list item (doc_lazy_continuation, the same job); it is reworded. |
||
|
|
a916e61185 |
Runtime: a kernel's [[stage_in]] is fetched; the three forms not built are Gap::StageIn by kind
A compute pipeline state whose kernel reads [[stage_in]] attributes was refused at its creation as Gap::KernelInput of KernelInputKind::StageIn, which a guest met (a descriptor-form compute state, the app's context closed right after). The translator already fetches every attribute in the shader from the buffer slot at its layout's bufferIndex, through that slot's pushed address, by the stage-in and dispatch regions the encoder already pushes. Two things stood in the way, both in the runtime: - interface() refused any kernel whose PipelineInterface::stage_in is non-empty. The line goes. - The thread-position fetch's reach check reads SpecKey::StageInReach, which the runtime's constant loop refused as a specialization it does not set. The runtime now leaves it at the module's default (true): one pipeline, the check kept for every dispatch. What stays refused is a typed refusal naming its own form, Gap::StageIn of a new StageInKind: - IndirectRegion: setStageInRegionWithIndirectBuffer:indirectBufferOffset:, now the method ComputeCommandEncoder::set_stage_in_region_with_indirect_buffer, which always refuses (the conformance rt side calls it in place of its own Unavailable); - DynamicStride: an attribute the kernel reads through a thread-position layout of MTLBufferLayoutStrideDynamic (the compute encoder has no attributeStride setter), at the state's creation, before the translator's IdentityDomains refusal of StageInStride; - IndexedStepRate: an attribute it reads through an indexed step at a step rate past 1, at the state's creation. Both creation checks read the descriptor narrowed to the attributes the kernel reads (kernel_inputs_read), so an attribute it never reads, and a constant step of a dynamic layout, refuse nothing. KernelInputKind::StageIn is deleted. Consumer search: `git grep -n 'KernelInputKind'` in the reims-vgpu checkout at c8201ec2ba: 0 hits (nor any for `StageIn` as a refusal kind). Tests: the device test every_device_fetches_stage_in_by_each_step_function dispatches engine/kernel_stage_in's stage_in_fetch under ThreadPositionInGridX at rates 1 and 2, ThreadPositionInGridXIndexed and Constant, and checks every thread's four attributes (threads past the region read its last element); without the change the state is Gap::KernelInput. every_device_refuses_each_unbuilt_stage_in_form_by_its_kind holds the three kinds and the two states that are made. kernel_input's refusal test of StageIn goes; lowered and the harness's gap test take Slot. The conformance case stage-in-region-clamps carries on past a refused row (probe, as attribute_formats does), so its 27 other rows compare where the indirect one is refused. The ledger drops the 82 rows of the old refusal (stage-in-region-clamps 1, attribute-format-fetches 29, attribute-format-class-crossings 16, stage-in-unread-attributes 36), takes the indirect row's new refusal, and the four compute attribute-stride rows' DynamicStride refusal. The validation requirement KernelStageInput stays: the engine's run through the runtime passes no stage-input descriptor or region. README, REFUSALS.md, METAL-COVERAGE.md, CONFORMANCE-COVERAGE.md and the signatures table regenerated. |
||
|
|
a1ca99880a |
Stage bound: a subgroup instruction weighs 64, the re-plan takes the lighter module, and a subgroup multiply-add's steps are one loop of paired shuffles
What:
- spirv::roll::bound_weight beside entry_weight: entry_weight with each subgroup instruction
(OpGroupNonUniform*) counted as SUBGROUP_WEIGHT, 64. Only the stage bound reads it
(stage_bound::emit); the roll keeps entry_weight as its trigger. ModuleStats::entry_weight
carries it, so the runtime's in-process or helper choice reads it.
- The re-plan holds both plans and compares them. A kernel past the bound only as the widest pin's
emulation is planned again keeping the pin: the re-plan takes the pinned module where it weighs
less than the emulated one by the stage weight; otherwise the emulated one goes on. The other
plan and module are dropped and their ledger share released.
- tile_mad on a subgroup tier: one vec2 shuffle carries a step's two b cells, one the a cells of
steps 2m and 2m + 1 (one owner lane: owner_bits keeps bit 0 of k out of the a owner), and the
dim / 2 step pairs are a DontUnroll loop, the sums in Function variables. Each step reads the
same cells and accumulates in the same Fma order. The emulated tier is unchanged.
- SEMANTICS_VERSION 2273 -> 2274.
Why: a driver's compile grows with a subgroup instruction far faster than with any other. A
kernel of entry weight 24,814 holding 3,772 subgroup instructions passed 6 GiB compiling on an
RTX 3090 (NVIDIA 620.70.06; job m3-max-67936), where the bound's 39,014 kernel grew 148 MiB. Under
the term it leaves the process; with the cut its module (22,238 instructions, 644 subgroup
instructions, bound weight 62,810) filled in the helper at 2,699 MiB of the consumer's 3,072 MiB
cap in 59 s (m3-max-67936): a thin margin. On the Iris Xe of RPL-P its pinned module, which the
re-plan took whatever it weighed, met the helper's memory (killed at 6,144 MiB, m3-max-67973);
now the emulated module (46,491, no subgroup instruction) goes on, against the pinned one's 56,163
with the cut, and filled at 792 MiB in 18.8 s (m3-max-67863).
Verified:
- Census, states-only (each play's MODE line read): the nine standard streams on the RTX 3090's
and the Iris Xe's profiles (m3-max-68045, 68047, 68087, 68100, 68101, 68132): 259 distinct
kernel modules a card, none holding a subgroup instruction, no re-plan, and no pass, render
stages included, that holds one; a recorded pass on the RX 7900 XTX (m3-max-68146): 819
compute states, none. The weigh tables of four staged kernels and a 63-kernel library on both
profiles, no driver compile (m3-max-68033, 68034): on the RTX 3090 two kernels cross, that of
24,814 and one of 7,470 (615 subgroup instructions, 46,215), which fills in the helper at
1,011 MiB (m3-max-67690); on the Iris Xe only the kernel of 24,814 re-plans. The library's ten
kernels past the bound today hold no subgroup instruction.
- Bit-equal and run time: the owned stage-bound fixture (512 multiply-adds a simdgroup, compiled
by Apple's metal) through the harness, before (development
|
||
|
|
10f83b636d |
Re-derive the generated documents at the landing tip
They are generated from the whole case set, and the set grew on `development` while this branch was in flight, so the copy committed here counted a smaller one. Verified: regenerating at this tip leaves no change beyond the `Generated at` stamp. |
||
|
|
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. |
||
|
|
d9077dfa0d |
Push window: each device's maxPushConstantsSize sizes it, up to 256 bytes (rule 2's ninth form)
What: the push window is one value per device, `DeviceProfile::push_window`, the description's
maxPushConstantsSize up to 256 bytes, decided in the profile `Device::from_queries` derives
(device/profile.rs:115). Every window reads it: push placement (`lower::push::window`, `place`,
`spills` and `check_floor` take its bytes; lower/select.rs, lower/access/mod.rs and
lower/access/table.rs pass it), and in the runtime the one pipeline layout's push range
(device.rs:688), the kernel and render pipelines' push checks (pipeline.rs:2119, render.rs:1043)
and the encoder's push bound (encoder.rs:1759). With W that value, a kernel pushes in [0, W), a
vertex function in [base, W - 8) and a fragment function in [base, W); object and mesh functions
keep 0..32 and 32..64. A stage's fields past its window spill to its parameter block, whose
address the window holds, as they did past 256. `from_queries` refuses a maxPushConstantsSize
below 128, Vulkan's least, only (`Unsupported{PushWindow}`, required 128), and the runtime's
floor no longer lists maxPushConstantsSize (floor.rs: its row and PUSH_CONSTANT_BYTES go; the
layout's range was a constant 256). There is no constant 128 path, no switch and no environment
gate: the limit query is the only input. Ported from the held branch steelbrain/amdfloor-window
(d6880ca16b) onto today's development, every line reference confirmed against this tree.
Why: the owner's word choosing option B. A device reporting 128 bytes was refused by the floor;
it now runs with a window of 128.
AGENTS.md rule 2 takes the owner's authorized text: "for eight only" becomes "for nine only",
and the push window joins the list after run-time texel offsets.
Known gap (runtime README, Known gaps of indirect command buffers): in a window of 128 bytes a
command reaches 9 vertex slots, and 8 where the vertex function spills, against 25 and 24 at 256
((W - 8 - 16 - 28) / 8; from code: lower::push's
an_indirect_draw_s_vertex_function_pushes_25_or_9_slot_words). A kernel pushes 8 buffer
addresses beside its dispatch region at 128 bytes against 24 at 256, the rest from its ring.
Caches: a device of 128 and one of 256 share no cached artifact and no pipeline. The profile's
fingerprint hashes every ProfileFields field by Debug (device/profile.rs:312, :327), the limits
included (:346, maxPushConstantsSize at :625); `function_key` hashes the fingerprint
(pipeline/compile/key.rs:182, :189; passed at pipeline/compile.rs:2973), as does
`queried_render_descriptor_key` (key.rs:546); a cached artifact or pipeline loads only under an
equal fingerprint (cache/artifacts.rs:71, :204, :238; cache/envelope.rs:142); and the runtime's
enables digest, which the stage keys check, hashes it (metal2vulkan-runtime/src/device.rs:1533).
SEMANTICS_VERSION stays 2273: no module changes under an unchanged key. Every device
`from_queries` accepted before reports 256 bytes or more (it refused below 256), so its window is
256 as before and its modules are the same bytes; a device of fewer bytes was refused, so it
holds no artifact to go stale, and its modules are new under its own fingerprint. The golden
test at this tree found 0 cells changed under an unchanged key over the 15 committed profiles,
and 1855 under a changed profile fingerprint, runtime-floor's column alone (m3-max-68089; the rows
whose assembler Linux lacks are not observed there).
Golden table: runtime-floor.json and its generator drop the floor block's maxPushConstantsSize
of 256, so the profile reads Vulkan 1.3's least, 128, and its fingerprint moves. Its cells are
re-blessed on development (the bless needs macOS's assembler).
Validation: runtime-sources.sha256 is rewritten (d4a8dbf2...), since device/derive.rs and
device/profile.rs are runtime inputs the guard hashes.
Docs: the runtime README (the floor's limits note and table, compute Parameters, the render push
range, the indirect command buffers' known gaps), docs/API.md section 5 and the from_queries
paragraph, PushWindow's doc, reach.tsv and docs/REFUSALS.md (regenerated; the PushWindow row
only), the device profiles' README, and api_signatures.tsv (DeviceProfile::push_window). The
api_surface table is unchanged: no public type is added.
Tests: lower::push's placement at 256 and 128; from_queries (each committed profile's window is
its limit up to 256, runtime-floor's 128; 128 derives, 64 is refused with required 128); the
tessellation control range, the engine identity and spill tests in each profile's window; and
the runtime's push_window, patch and indirect token tests in two arms each, the device's own
limit and the limit held at 128 by the tests' device shim (tests/command.rs push_window_128,
DeviceOptions::described).
Verified:
- m3-max-68088 (this tree): fmt, the signatures table, the refusal surface, clippy -D warnings
plain, --cfg m2v_gpu and --cfg m2v_cpu_icd, workspace Rustdoc -D warnings: each exit 0. The
runtime suite on lavapipe (--cfg m2v_cpu_icd): 647 passed, 3 skipped. Its push lines read
"push_window: the push window is 256 bytes", "push_window_128: the push window is 128 bytes",
"window 128, 12 buffers: 3 ring writes and 3 pushes over 3 dispatches", "icb_tokens: ... the
push window 256 bytes, 25 slot words", "icb_tokens_128: ... the push window 128 bytes, 9 slot
words", and draw_patches_full_range at 256 and _128 at 128.
- m3-max-68089 (this tree): the core crates 3881 of 3882 passed, 24 skipped; the one failure
is the golden table, stale under runtime-floor's moved fingerprint (1855 cells, one per row
observed on Linux, 0 new, 0 gone, 0 under a changed source, 0 changed under an unchanged key).
Validation 1314 passed, 3 skipped. The translator's push tests print each committed profile's
window: runtime-floor 128, the vertex function ending at 120, 9 inputs; the 14 others 256.
- m3-max-68067: the whole runtime suite on lavapipe at an earlier tree of this change
(a98af765ad, before the rebase onto
|
||
|
|
c87452da05 |
Validation: the device tests the own-context executor ran assert what the runtime route does
The own-context executor's deletion pointed six device tests at the runtime route, and on
lavapipe (m3-max-67674) they failed: the route draws one library's stages with a generated
companion, and the runtime compiles under the identity domains. Each now asserts what the runtime
route does, or goes where the route cannot express it:
- a_loaded_pointers_buffer_written_past_its_end_is_refused_uncontained (was ..._is_guarded):
under the identity domains a loaded pointer is used as given and no check bounds it
(docs/API.md, section 1), so the run refuses the target, Uncontained naming LoadedPointer.
- cube_and_cube_array_face_reads_are_refused_under_the_identity_domains (was
cube_and_cube_array_faces_read_the_authored_layers): the translator refuses texture_ops.ll's
cube_faces under the identity domains (Unsupported{IdentityDomains}, NotImplemented, for the
cube argument read by face).
- an_index_past_a_one_layer_pass_renders_the_pass_s_slice: the same slice, with no withheld
validation message (the runtime route withholds none).
- a_constant_fragment_colors_the_quadrant_metal_draws, a_vertex_varying_reaches_the_fragment_stage
and a_looping_fragment_draws_as_compiled go, with their helpers: each draws a vertex and a
fragment function of two owned libraries with no companion, which only the deleted executor
drew. Metal's y-up quadrant stays asserted by
an_observed_vertex_case_draws_into_its_generated_observer (QUADRANT, top_right); a pipeline of
two libraries' stages is compared with Metal by the conformance case shader_stencil. A varying
across two libraries by its user key, and a looping fragment drawn as compiled, have no
runtime-route test now.
docs/CONFORMANCE-COVERAGE.md is regenerated (python3 -I scripts/conformance-coverage/coverage.py):
the rate-map modules no longer declare the notice, 44 modules to 41.
Verified: the coverage script's output; the device tests are not yet rerun (the check job follows).
|
||
|
|
b5916b2f7b |
Translator: four public items nothing produces or names go: the replay fault report, the rate-map note, two rate-map errors and the rate-map axis
Four of the eight findings on the binder's public surface, the ones no plan reaches: - (3) `bind::ReplayFaults`, with `StatusReport::replay_fault` and `replay_faults`, `StatusBits::REPLAY_FAULT` and `StatusWord::ReplayFaults`: no module writes the word or the bit. `StatusWord::SeqCstFences` keeps index 3, so no module changes; word 2 is now one nothing writes. - (5) `PrecisionNote::RasterizationRateMap`: no module or runtime path records it (the decoder is Apple's arithmetic, and the runtime draws no rate-mapped pass). Its API.md catalogue entry goes, and so does conformance's `Degradation::RasterizationRateMap` with the notice allowances of the three rate-map families, whose runtime side refuses every rate-map call (`Unavailable`, known-gaps-rt.tsv), so the allowance never applied. Validation's c3 list of deferred near-equivalents drops it, and its tests use `SparseResidency` instead. The translator's rate-map tests drop their assertions that the note is absent. - (6) `RateMapError::NoLayers` and `LayerCount`: only the test support `from_layers` made them; it now panics on a count no test passes. - (7) `RateMapAxis`: in no public signature; now crate-private. The codec encodes a precision note by its name, so no other note's encoding moves. No refusal in docs/REFUSALS.md changes (refusal_surface.py --check passes as is). Consumer search at reims-vgpu development cae6d420df, `git -C ~/Projects/steelbrain/reims-vgpu grep -n -w ITEM development -- '*.rs'`: ReplayFaults 0, replay_faults 0, replay_fault 0, REPLAY_FAULT 0, StatusWord 0, RasterizationRateMap 0, Degradation 0, RateMapError 0, NoLayers 0, LayerCount 0, RateMapAxis 0. Left for later, with the census's re-record: two authored cases' rationales (shard_013, lines 33 and 34) still say the decoder's answers carry the note. (cherry picked from commit b68324630b4c8446d7fe730b3877b31727546d1c) |
||
|
|
b92c74e489 |
Translator: a render or mesh pipeline compiles only as the runtime compiles it; validation stops compiling for a bind shape
`Device::compile_render_variant` and `Device::compile_mesh_variant` leave the public API. The runtime renders under `VariantKey::new()` alone, and since the census compiles as the runtime does, the only callers left were validation's bind-shape compiles: the `PipelineRequest::BoundCompute` request, the `shape` of `VertexDraw` and `Draw`, and corpus-pipeline's `--pulled` sweep (its `Projection`). Those go with them. `compile_render_pipeline` and `compile_mesh_pipeline` compile under `VariantKey::new()` as before, and `compile_render_pipeline`'s doc now carries the call-stack sentence the variant's doc held. The crate's own tests keep a test-only `compile_render_variant`. In validation the kernel compile the census and L4 share (`variants::compile_kernel`) stays, with its partial-simdgroup test now comparing against explicit plain and emulated compiles. The binder's shape-compile loop moves under `#[cfg(test)]` (`variants::bound`) for the binder tests that still plan a kernel until the binder goes. The draw test helpers compile as the runtime does. The worker's bound-compute exchange test goes, and its linking test sends a `Kernel` request. Nothing here changes what plan_for is given or returns: the census's artifact digest still plans the same pipeline for the same shape. Consumer search at reims-vgpu development cae6d420df: git -C ~/Projects/steelbrain/reims-vgpu grep -n -w compile_render_variant development -- '*.rs': 0 git -C ~/Projects/steelbrain/reims-vgpu grep -n -w compile_mesh_variant development -- '*.rs': 0 api_signatures.tsv drops the two records. (cherry picked from commit 15766b53448bafc7cd16d9acd335dd3d4c45d734) |
||
|
|
cd5d336782 |
Validation: the own-context executor goes; a case runs through the runtime or is refused before it runs
After the profiles layer moved onto the runtime route, kernel rows went through the runtime, and the
layered cases moved too, nothing called validation's own Vulkan executor. This deletes it:
candidate/platform's compute, render (and its multisampled half), plan_resources, buffers and
multisample modules, the own-context device's clamped-layer, extended-dynamic-state, restriction
and environment machinery, the engine's compile_case / compile_render(_case) / compute_request
plumbing, the bind refusal and status verdict it read, the synthetic guest addresses, the attempt's
creation ceiling, and coverage's module census of its own compiles. corpus-pipeline's Vulkan
context for its render rows, and the runtime probe's, stay.
A render case the runtime route does not draw (a depth/stencil attachment of both aspects, a patch
draw through a patch or control-point index buffer, an out-of-bounds target other than an attribute
buffer) is refused not_supported{executor_not_implemented} before it runs, as run_prepared already
did once the gates were gone. The comments and docs/VALIDATION.md that compared with the own
context now say what the runtime route does.
Test-only items move beside their tests: Mechanism's label into the out-of-bounds tests,
Containment::of_compile, its label, Declared and ExecutionClass::of_description into the tier
table. The linked-functions integration test compiles through kernel_request, as the census does.
Deleted tests and what covers their Metal claim:
- a_kernel_runs_with_its_linked_visible_functions: a_kernel_runs_through_the_runtime_with_its_
linked_visible_functions (engine_compute.rs), kept.
- a_draw_restarts_exactly_its_strips_within_its_class: the conformance case
primitive_type_crossings compares strip restart with Metal.
- a_combined_depth_stencil_format_moves_both_aspects_together, a_draw_covers_the_whole_target,
a_guarded_buffer_counts_each_changed_guard_byte, a_target_is_bound_for_its_fetch_form,
every_state_a_render_pipeline_makes_dynamic_is_recorded,
multisample_initializers_are_vulkan_legal_for_each_component_class,
addressed_allocations_take_metal_addresses, the_status_starts_zero_and_stops_non_evidence,
the_clamped_layer_warning_fails_no_row_of_a_clamped_store_alone,
a_context_has_the_extended_dynamic_states_where_the_product_reads_them,
a_store_runs_through_the_binder_under_the_validation_layer,
a_tessellation_pipeline_census_is_its_functions: the deleted executor's own mechanics, no Metal
answer of their own.
metal2vulkan-validation is not published, so no consumer can reach a deleted item:
git grep -n -E 'metal2vulkan[-_]validation' development -- '*.rs' '*.toml' in the consumer's
checkout at a11528a7e2: 0 hits.
Verified: cargo check of the validation crate, all targets and features, plain, --cfg m2v_gpu and
--cfg m2v_cpu_icd, clean (m3-max-67506, on the probe branch's identical diff); the dead-code pass
against the base finds only items whose users are macOS-only or tests the binder's deletion takes.
The compile job and the suites follow on this commit.
(cherry picked from commit 5808aaa769e3f44b1bd76dea486b2b150b15e92b)
|
||
|
|
d15ab4501c |
Validation: command-replay play --states-only yes plays the state records and presents alone, and the report's first line names the mode
A states-only play was a probe's environment variable (M2V_PROBE_STATES_ONLY, on a probe branch that never lands): a tree without the probe played the streams in full and said nothing, so two states-only plays of a translator change read as plays of nothing they were meant to check. The mode is now an option of the validation player itself, --states-only yes|no (no by default), and every report's first line names it: `mode full: every call` or `mode states-only: the device, library, function and pipeline state records and the presents alone (--states-only yes)`. A bad value is a bad command line (exit 2, `error states-only: ...` as that first line). Player::states_only passes over every call but MTLCreateSystemDefaultDevice, m2v.deviceIdentity, the newLibrary*, newFunction*, newDynamicLibrary*, newRenderPipelineState* and newComputePipelineState* calls and m2v.present, the probe's set unchanged, so frames and the recording range end where a full play's do and the pipeline states are made cold as a full play makes them. A states-only play writes none of the matrix's judged metrics, since it runs none of the work they count. The completion-fix line keeps its place by itself, now after the mode line; its test reads it there, and a new test reads the mode line for yes, no and a bad value. docs/REPLAY-STREAM.md section 10 and the player's module doc and usage name the option and the line. |
||
|
|
0702b43baf |
Translator: a kernel's partial-threadgroups variant that cannot be made is refused as PartialThreadgroups
Every refusal of the partial-threadgroups variant (LoweringInputs::partial_threadgroups) named Feature::GpuEncodedIndirectCommands, the feature of indirect command buffers a kernel encodes, which none of them is. A new feature, Feature::PartialThreadgroups (NotImplemented), names them all: - lower/select.rs (finish): the kernel's simdgroups run on the emulated tier (its profile's subgroups, its lockstep order or its pinned widest mode give it that tier), whose exchanges are not walked past the grid. This is the one a SIMD-group or quad-group kernel meets on a device whose subgroups are narrower than 32 (lavapipe, and the Iris Xe in the equality test). - lower/simd/divergent.rs (barriers): a kernel whose uniform barriers need a vote word its stage's workgroup memory cannot hold beside its static arena. - lower/mesh/mod.rs (plan_partial_groups): a tile function, a kernel that reads a stage-input region, one with compute derivatives or a cooperative imageblock slice write. - pipeline/compile.rs (analyze_one): the input beside flat_grid, folded_groups, replay_bindings or emulated_simdgroups. Its condition was one with the folded and call-threadgroups combinations, which stay GpuEncodedIndirectCommands; it is split in two. Today the four sites build the same refusal with no symbol, so no text tells the causes apart, and none is added. The flat variant's refusal at lower/select.rs:1715 (flat_grid with call_threadgroups, on the emulated tier or with a workgroup synchronization) stays GpuEncodedIndirectCommands: it refuses the flat variant, not the partial-threadgroups one, with the flat variant's other refusals (lower/access/mod.rs plan_replay, pipeline/compile.rs analyze_one); the runtime never sets flat_grid (no hit in crates/metal2vulkan-runtime/src). The runtime's test of a refused variant (pipeline.rs, the non-observer's lowering) matches the new feature, so a variant refused now is still kept as a refusal and its state runs the plain module. A refusal kept in a device's cache directory before this commit still reads: the marker (cache.rs REFUSED) holds no feature, and it is found by the variant's key (function_compile_key), which this commit does not move. No version moves. No persisted outcome records the moved refusals' class: - the runtime's cache directory: the marker above, under an unchanged key; - the golden tables (golden_hashes.tsv, 77 GpuEncodedIndirectCommands cells; public_fixture_expectations_engine.tsv, 96): every subject compiles under no inputs, where partial_threadgroups is false, and every moved site is reached only under it; - the authored compile census (corpus/authored-compile.tsv): no GpuEncodedIndirectCommands cell; - the committed observations, cutover lists and conformance recordings: no hit (git grep -c over corpus/, cutover/ and crates/metal2vulkan-conformance). The runtime guard's inputs do not change: every file edited here is outside them or on the guard's list of compile-time files. The consumer: git grep -n 'GpuEncodedIndirectCommands' cae6d420df in its checkout gives 0 lines (and 0 for PartialThreadgroups). docs/REFUSALS.md is regenerated (scripts/refusal-surface/refusal_surface.py), with the new row's reach mark in reach.tsv (app: a dispatchThreads grid that is not whole threadgroups), and the signatures table (api_signatures.tsv) has the new variant (signatures.py --bless); the api_surface table lists Feature as an enum, not its variants, so it does not change. docs/API.md section 5 and the partial_threadgroups input's doc name the new feature. The translator's partial-threadgroups tests assert it. |
||
|
|
9675b50e75 |
Validation: corpus-pipeline makes every kernel row on one runtime device per sweep
At f11d6455e0 each kernel row opened its own runtime instance and device under the validation layer. A sweep of about 900 kernel rows made about 900 instances and devices. Each instance's layer also opened its own log file and kept it open after the instance was destroyed: one file descriptor a row (the 3090, job 67374: 5 descriptors to 24 over 20 rows). The form the 1b brief asks for is one runtime device of the sweep's kind, with each row's ComputePipelineState and its dispatch made on it. candidate::RuntimeKernels is that device: - open makes the instance (restricted where the process is) and the device. The validation layer's variables are set only while the instance is made (runtime::under_validation_variables), and the layer logs to the process's one log for the device's life; - accept makes one row's state and encodes its dispatch, as before. The row's messages are what the log gained during the row, so a message still makes that row INVALID_USAGE; - finish drops the device and waits for its teardown. A message logged at the teardown fails the sweep. A message logged while the device opens stops the sweep before any row, because no row on that device would be evidence. corpus-pipeline opens it at the sweep's first kernel row, so a render-only sweep opens none, and finishes it after the last row. Render rows keep their own context. runtime::opened is split into made_device and torn_down for the held device; the per-row executors keep opened. create_runtime_kernel is removed. The device tests make two kernel rows on one device. |
||
|
|
71f93243d9 |
Validation: an L4 kernel row is made through the runtime, its pipeline state and one encoded dispatch
corpus-pipeline asked the driver for a kernel row's compute pipeline at
the region the binder planned for one representative dispatch
(acceptance::dispatch), and tallied the binder's answer (BIND_REFUSED,
BIND_ERROR). That is not the pipeline a guest's kernel gets. A kernel row
is now made as a guest's kernel is made (platform::runtime_acceptance):
- the row's AIR becomes a runtime library, and its function is
specialized with the row's function-constant values;
- one ComputePipelineState is made on the sweep's device, restricted to
--profiles-layer's profile where one is given;
- one dispatch of one threadgroup of the state's thread execution width
(or its maxTotalThreadsPerThreadgroup where that is fewer) is encoded
into a command buffer that is dropped uncommitted, so the runtime picks
the module that threadgroup runs on, asks the driver for its pipeline,
and nothing executes.
The verdicts:
- The creation time is the runtime's own count of it
(pipeline_creation_nanos).
- A message from the validation layer is INVALID_USAGE.
- A Vulkan error is REFUSED.
- The runtime's typed refusal (the translator's, a known gap, a limit) is
RUNTIME_REFUSED, counted.
- A kernel the runtime runs as Metal's without effects, and makes no
pipeline for, is NO_EFFECT, counted.
The row still compiles in its compile worker first, for its words, its
outcome, --compile-only and --keep-modules. The make runs in the sweep's
process, held to the per-attempt ceilings (runtime::within_ceilings).
Removed:
- acceptance::dispatch (plan_compute_row, ComputeCreation, NoCreation,
BinderAnswer);
- RowCompile::Binder and UnmodelledKind::Dispatch;
- the tally's bind_refused and bind_errors, and the detail's
imageblock=WxH;
- the own context's compute arm of create_acceptance_pipeline, which now
takes a render pipeline, with its region test.
The summary line's bind_refused= and bind_errors= become
runtime_refused= and no_effect=.
What is lost: L4 kernel acceptance on Mesa's drm-shim drivers (RADV, ANV
and NVK), which stood for hardware we do not own. The runtime does not
open those devices, so the rung runs on lavapipe and the real cards
only. NVK is lost entirely: the shim was its only venue, and it never
ran here.
Committed rows removed: none. No L4 row is committed. Counted by
environment over corpus/observations/vulkan and observations/refusals at
|
||
|
|
9a01f1e8ee |
rt: an observer's dispatch runs its partial-threadgroups variant only where the variant's threadgroup memory, its vote word included, is within the device's limit
|
||
|
|
f090d99c9a |
rt: an observing kernel's indirect dispatches run its partial-threadgroups variant too
decide() moved an observer's whole grids and threadgroup dispatches onto the partial-threadgroups variant but left its indirect dispatches on the plain module, so a state dispatched both ways made a second VkPipeline of the same size on the first indirect dispatch. By the translator's dispatch regions (lower::dispatch), an indirect dispatch states region[1].xyz = 0 and takes the single-region form, and the variant's partial answers sit only under region[1].w NONUNIFORM, which the encoder's indirect region never sets. So the variant runs it unflagged, every invocation live, as it runs a whole grid. decide() now drops the direct-only condition: one module and one VkPipeline a size run every dispatch of an observing kernel where the variant takes the threadgroup. Metrics::partial_variant_whole_grids counts the indirect ones with the whole grids. No key, version or translator file changes. Tests: the observing kernel's run table expects its indirect dispatch on the variant (one first-use wait fewer where it shares a size with a direct dispatch, and one more count); prepare_dispatch's table gains an indirect dispatch at the whole grid's size that finds the variant made (0 makes; 1 before this change); the variant-key table groups the indirect dispatch with the direct ones. The conformance case compute-indirect-threadgroup-grid dispatches region_k, an observer, indirectly; its dispatch-forms line is the check that the replay ran it on the variant. Checks to run on this commit: tests::translate and the conformance replay on a card per vendor. |
||
|
|
6453edbea7 |
rt: an observing kernel runs its whole grids on its partial-threadgroups variant, one VkPipeline a size for every direct dispatch
A kernel that observes its threadgroup partition made two VkPipelines for one threadgroup size: the plain module's for whole grids and threadgroup dispatches, and the partial-threadgroups variant's for ragged grids. The variant already runs a whole grid as the same regions unflagged (lower/dispatch.rs), so decide() now sends every direct dispatch the whole module would run to the variant where the variant is lowered and takes the threadgroup whole SIMD groups. Indirect dispatches, a refused or failed variant, and a threadgroup that is not whole SIMD groups of a kernel that runs only whole ones (the emulated route) keep today's module. A state with a declared bound or a required size makes one VkPipeline ahead instead of two. Metrics::partial_variant_whole_grids counts the whole grids that ran the variant; the player's executed counters and the conformance runner print it. Nothing re-keys: the translations are unchanged (the plain module is still lowered: its interface numbers the samplers, answers Metal's state and runs indirect dispatches), and no version moves (metal2vulkan-runtime is outside RUNTIME_VERSION's inputs). |
||
|
|
bcc88a43cf |
Re-derive the generated documents at the landing tip
They are generated from the whole case set, and the set grew on `development` while this branch was in flight, so the copy committed here counted a smaller one. Verified: regenerating at this tip leaves no change beyond the `Generated at` stamp. |
||
|
|
bda5ed08e9 |
rt: a resolve into a texture in place over a buffer whose linear image cannot render goes through a resolve image
For the consumer: a pass that resolves into a texture in place over a buffer of the runtime's
own memory, whose linear image takes no colour attachment usage, is no longer refused with
Gap::RenderPass{ResolveUsage}. It resolves into the texture's resolve image, and the pass's end
copies the render area into the buffer at the texture's pitch. This is the guest's 600 x 600
BGRA8Unorm_sRGB ShaderRead texture over a Managed buffer, on every NVIDIA host and on KosmicKrisp:
their linear tiling features hold COLOR_ATTACHMENT for no format (count jobs m3-max-67031 and
m3-max-67032), and a pitch of the row rounded up to the alignment answer (128 and 16) lies in place.
It also covers a texture whose subresource reaches past its own rows or its buffer (the render-reach
rule), on every device. Additive public items: Metrics::resolve_copies and resolve_copy_bytes (in
bytes_copied too), Gauges::resolve_images and resolve_image_bytes. Still refused: a texture in place
over a dma-buf's import (an imported surface's memory) and a view of a texture in place.
Why this form: owner's rule 3 allows "where a format query offers no linear image for the format and
usage, a counted copy", the sentence OverCause::LinearFeatures and RenderReach already rest on for a
render target over a buffer. This is the smallest such copy: one per resolve, of the render area
only, and nothing on later uses. The texture stays in place, so shaders keep reading the buffer's
bytes through its linear image. The planner chose it over moving the texture to the copy form at
its first resolve (2,880,000 bytes per resolving pass, then a copy in every submission that uses
it).
How:
- texture.rs: the in-place texture's Image keeps a Resolving where it lies in the runtime's own
memory (Laid::Own), its linear image took no attachment usage, and its plan's optimal image does
(Plan::resolves, the image format query that already made it with COLOR_ATTACHMENT). The first
resolve makes the resolve image from the texture's plan (Plan::resolved, Bind::Pooled) and a 2D
identity view of it. Every later resolve reuses them, and they are freed with the texture
(Free::Resolved, the resolve images gauges). resolve_attachment returns the attachment and, for a
resolve image, a ResolveCopy: the VkBuffer of the bytes shaders reach and the region at the
texture's pitch. That is Named::region, the region copied_over already built, now shared. A level,
slice or layer count past the texture's one is Refusal::AttachmentPlace, as attachment_view
refuses it.
- pass.rs: Resolve carries the copy. Its image's home is TRANSFER_SRC_OPTIMAL and it renders in
ATTACHMENT_OPTIMAL. Resolve::from moves it away from UNDEFINED: the pass resolves every texel of
its render area and copies only those, so nothing it held earlier is kept.
- render_encoder.rs: after the pass's back barrier (which moves the image to TRANSFER_SRC_OPTIMAL),
end() records vkCmdCopyImageToBuffer of the render area (Pass::reach) into the buffer at the
texture's pitch. It counts the copy and owes the pass's barrier, so the next command, or the
segment's end, orders the copy before later work. bufferOffset is a whole number of texels, which
check_over already requires (VUID-vkCmdCopyImageToBuffer-srcImage-07975; the multiple-of-4 rule,
07978, is depth and stencil only). The block's buffer has TRANSFER_DST.
Readable through the linear image: the copy writes the buffer, and a later pass reads the same
memory through the texture's linear image. Vulkan 12.11 Memory Aliasing says "If two aliases are
both host-accessible, then they interpret the contents of the memory in consistent ways, and data
written to one alias can be read by the other alias". Buffers, and linear image subresources in
GENERAL or PREINITIALIZED, are host-accessible. The in-place form already rests on that sentence:
its linear image starts preinitialized and stays GENERAL through every use, copies included
(Image::copy_layout, "so that it and the buffer are aliases that interpret their bytes alike
(Vulkan's memory aliasing)"). The order between the copy and the read is the owed barrier, a memory
barrier from every command to every command.
Docs: RenderPassKind::ResolveUsage, the resolve texture's doc, resolve_attachment's and resolve()'s
docs, and the pass module say what resolves through the resolve image and what is still refused.
The runtime README's two Render encoders paragraphs and its counters list are updated, the card
names under "measured on". docs/REFUSALS.md is regenerated (two more AttachmentPlace sites, in
resolve_attachment), and so is the signatures table (the four new fields).
Test: every_device_resolves_a_loaded_pass_into_a_shader_read_texture_over_a_buffer runs the
guest's shape over a Managed and over a Shared buffer, at 2,400, at the row rounded to the alignment
answer, and at 2,560. On an in-place row whose linear image took no attachment usage, it asserts:
- the first resolve makes exactly one image;
- one resolve copy of 1,440,000 bytes, and bytes_copied equal to it;
- the buffer reads the clear within one code, with 0 bytes past the texels changed;
- a pass after it in the same command buffer reads the texture at each pixel (own_pixel_fragment
into a 600 x 600 target), its centre texel (299, 300) the clear within one code;
- a second resolve, in a command buffer of its own, makes no image and no allocation
(image_creates, consumer_allocations), and the resolve images gauge does not grow.
The other rows are unchanged: in place with the usage, 0 copies; copied, counted copies. Every
gauge is zero at device drop (each_device). Without this change, the RTX 3090's in-place row at
2,432 is refused with ResolveUsage (job m3-max-67081 on the resolve fix's tree).
|
||
|
|
0aab6200fb |
rt: a Managed buffer's device copy placed in an exported block is refused
Device::new_managed_buffer took a device copy in any Private block the consumer held, an
exported block included. The copy's zero fill and its copy-ins at Managed events write the block
through the runtime's own commands, and nothing marks those writes for the textures over the
block (over::ExportedOvers), so they wrote the block unseen. Metal has no way to ask for that
placement: it places a Managed buffer's second copy itself, so no Metal program puts it in memory
another API shares.
The consumer at reims-vgpu 0ec951ecaf makes no such placement.
- `git grep -n 'new_managed_buffer' 0ec951ecaf -- '*.rs'` gives 2 calls, both in
rt_platform/buffer.rs:
- At :1463 (own_managed) the copy is in a Private block taken for it.
- At :1625 (range_of) the copy is in a block taken the same way, or at the `copy` known_at()
found: a known block of class Private that holds the pin.
- `git grep -n -F '.know(' 0ec951ecaf -- '*.rs'` gives 7 lines. The known blocks come from
take_block (pool/rt_blocks.rs:121, rt_platform/heap.rs:648 and :907), from page imports
(rt_platform/buffer.rs:2429) and from tests (buffer.rs:3082, :3083 and :3635).
- None of these is an exported block. The one exported make (rt_platform/export.rs:208) is never
made known.
The placement is now Refusal::ManagedCopyExported { block }, checked after
ManagedCopyNotPrivate, on a device that keeps a device copy. No existing kind fit:
ManagedCopyNotPrivate says the block is not Private, and an exported block is. Wiring the copy's
writes into ExportedOvers would need a mark at its zero fill and at each copy-in; one check is
smaller. The refusal is a public call's own
check of its arguments, so it holds on every device; on a device with unified memory the copy is
refused before it as ManagedCopyOnUnified.
With the placement gone, a Managed buffer's device copy is no longer one of the routes by which an
exported block's address goes out. The runtime README's exported block rule and the ExportedOvers
doc drop it. The README's Managed buffer paragraph and new_managed_buffer's Err list name the new
refusal. docs/REFUSALS.md, error/basis.rs and the signatures table are regenerated.
Test: every_device_places_a_managed_buffer_s_device_copy_where_the_consumer_says. On a device that
keeps a device copy, it also places one in an exported block of the first handle the device
exports, and asserts ManagedCopyExported naming that block. Before this commit that call returned
a buffer, so the test fails without the change (read from code: no check stood between the Private
class test and the buffer's make).
Verified (tree 3b87fced96, the same tree as this commit):
- Compile job m3-max-66867: signatures and refusal-surface checks, fmt, clippy (plain,
--cfg m2v_gpu, --cfg m2v_cpu_icd), workspace Rustdoc -D warnings and scripts/api-docs all exit 0.
The runtime suite on lavapipe: 642 tests run, 642 passed, 3 skipped. Lavapipe is a CPU device,
so it keeps no device copy and does not reach the new check.
- The m2v_gpu archive is from job m3-max-66876. Each card ran the test, then the runtime suite:
- RX 550, job m3-max-66896 (a rerun of m3-max-66891, whose log filter dropped the printed line):
"managed placed: ...: a copy in a OpaqueFd exported block refused"; 644 passed, 3 skipped.
- RTX 3090, job m3-max-66922: "managed placed: ...: a copy in a OpaqueFd exported block
refused"; 644 passed (1 slow), 3 skipped.
|
||
|
|
48d7ded3aa |
Validation: the authored compile census compiles as the runtime does, through no binding plan's variant
The census compiled each case's pipeline through the binder's variant route: a kernel under the
key its plan, and its plan's dispatch_variant, asked for (BindingPlan::variant), a draw through
compile_render_variant, a mesh draw through compile_mesh_variant, each with the storage-format
loop. It now compiles through the translator's public pipeline API the way the runtime does:
- a kernel through the new PipelineRequest::Kernel, compile_kernel: its plain module, or its
emulated-simdgroups variant (LoweringInputs::kernel_variant) where the dispatch's threadgroup
is not a multiple of a LocalSizeConstraint the plain module states, the runtime encoder's
rule (encoder::decide);
- a draw with no shape (Device::compile_render_pipeline);
- a mesh draw through Device::compile_mesh_pipeline. The census was MeshDraw's only builder, so
its shape field and compile_mesh_for_shape go.
The own-context executor (a profiles-layer run, a render case off the runtime) keeps its
requests (BoundCompute, a draw with its shape) under the resident-table domains, where its plan
asks for variants the runtime route does not compile.
The artifact still digests the plan of the compiled pipeline for the run's bind shape, as the
own-context executor records it (artifact::CaseArtifact::record).
Why: on the probe branch (m3-max-66743, 9 profiles, 20,997 cells), the only variant field the
plan ever set was emulated_simdgroups. Yet the census's old route kept the plain module for 33
kernel cases (174 cells on the six real-GPU profiles) whose threadgroups (1, 4, 8, 16, 40 or 42
threads) are no multiple of the plain module's LocalSizeConstraint { multiple: 32 }. The binder
refuses to plan each of them under the runtime's identity domains, so the old route's variant
step never ran. Every one of the 33 observes its threadgroup partition, so the runtime's whole
module is the plain one and its encoder runs the emulated-simdgroups module for those
dispatches. The new route compiles exactly that module (route probe 8468646957, census
m3-max-66936, every cell compiled: the 174 differ only in stage, dependencies and requirements).
So the census's cells for those 33 described a module no guest gets.
AUTHORED_COMPILE_CENSUS_VERSION 7 -> 8: the compiles a cell is made of changed route.
Verified:
- compile m3-max-66813 and suites m3-max-66814 at the lane's base
|
||
|
|
85aa6c8dee |
rt: an exported block's BlockInfo states no device address, so its make hands none out
API change for the consumer: BlockInfo::gpu_address becomes Option<u64>. It is Some for every taken, imported and sparse block, as before, and None for an exported block (Device::new_exported_block). BlockInfo stays Clone + Copy. The only way to an address of an exported block's memory is now Buffer::gpu_address of a buffer in it, which marks the block and counts it in Metrics::exported_blocks_addressed as |
||
|
|
53dd17e008 |
Translator: delete VkFeature's RobustBufferAccess and RobustBufferAccess2, which nothing reads
The batch deleted the translator's choice between the driver's buffer robustness and the in-shader check: every buffer access is checked in the shader, and no lowering reads robustBufferAccess or robustBufferAccess2. The runtime enables neither (its floor table names neither; robustImageAccess, robustImageAccess2 and nullDescriptor are its robustness features, and robustImageAccess2 stays: memory::contain reads it for images). What still named the two was the enable-set vocabulary around them, so it goes with them: - VkFeature::RobustBufferAccess and VkFeature::RobustBufferAccess2, from the enum, its codec, the exposure table (Vulkan 1.0 core; VK_EXT_robustness2 keeps robustImageAccess2 and nullDescriptor), the Khronos reader's member table, the ash query's feature sources, and required_features (whose Vulkan 1.0 tier held robustBufferAccess alone and goes). - The co-enable rules only they took part in: robustBufferAccess2 needs robustBufferAccess (VUID-...-robustBufferAccess2-04000, a FEATURE_NEEDS row), and the update-after-bind features of buffer descriptor types beside robustBufferAccess without robustBufferAccessUpdateAfterBind (VUID-VkDeviceCreateInfo-robustBufferAccess-10247: device::enables' crate-private BUFFER_UPDATE_AFTER_BIND and BUFFER_UPDATE_AFTER_BIND_VUID, and its branches in co_enable_violation and co_enabled). The multiview rules stay. - DeviceDescription::robust_buffer_access_update_after_bind, which only that rule read, with its Khronos and ash readers and the Device's copy. So a recommendation now keeps every update-after-bind feature a device lists: runtime-floor's, which used to leave its two texel-buffer ones out beside robustBufferAccess, holds them, and a device made from it compiles texture buffers. docs/API.md's section 2 and the enable-set docs say that the recommendation names neither robustness feature, and that a consumer who enables robustBufferAccess itself keeps VUID 10247. The consumer's checkout (reims-vgpu development d80a432f3a, `git grep -n -w ITEM development -- '*.rs'`) names none of the deleted public items: RobustBufferAccess 0, RobustBufferAccess2 0, robust_buffer_access_update_after_bind 0 (BUFFER_UPDATE_AFTER_BIND 0 and BUFFER_UPDATE_AFTER_BIND_VUID 0, both crate-private). It names no VkFeature and no DeviceDescription at all, so no glob import or re-export hides a hit. No module changes: no lowering read either feature. Every committed profile's fingerprint moves (each listed robustBufferAccess, a Vulkan 1.0 requirement), so every golden cell and every key under one moves with it: bless-class, a changed fingerprint, no SEMANTICS bump. The codec names a variant by its tag, so no other feature's encoding moves; an artifact naming a deleted feature would sit under a fingerprint that no longer exists. The tests follow: those of the deleted rules go (recommendations_keep_robust_buffer_access_and_ vuid_10247, a_recommendation_keeps_vuid_10247, both robust_buffer_access_update_after_bind readers' tests); tests that ran every profile "with robustness and without" lose the leg that was the same profile (engine_access, _atomics, _binder, _buffer_table, _copy, _dynamic_roots, _gep_index, _index_words, _kernel_stage_in, _link, _pointer_memory, _pointer_values, _rate_map, _skeleton), and the out-of-bounds cases those tests ran only on the bare leg (short stage-in buffers, far rate-map coordinates, huge copy lengths, 8- and 16-byte leaves past the end) now run on every profile; image robustness lists keep their two image features. Validation maps the two members to no feature (registry names kept), its tier table's robustness-off leg removes the image features alone, and its tests check the two members unset in the chain. The runtime's tests stop naming them. profiles_both_encodings' second leg is now the profile unchanged; the next commit removes it. api_signatures.tsv re-blessed (3 records gone); refusal surface unchanged. |
||
|
|
8ed044f2e8 |
Translator: a replay variant under the identity domains is refused, typed
The commit before this one placed the RootTableAddress a device-replay variant
(VariantKey::replay_bindings) reads its buffer slots' addresses from, so under the identity
domains the variant no longer ends in the internal error "a strategy reads the unplaced push field
RootTableAddress". Its message said the variant then compiles there; it does not. With the field
placed, the plan reaches select::identity_admits, whose admitted push fields hold no
RootTableAddress: the identity domains read no root table, and the variant is refused,
Unsupported{IdentityDomains} (NotImplemented) naming "an encoder value the function reads as
RootTableAddress". That refusal is the true answer: only the binder (bind/replay, bind/dispatch,
bind/graphics) asks for a replay variant, and the runtime, the one consumer of the identity
domains, never sets replay_bindings (no hit in crates/metal2vulkan-runtime/src). The refusal
site and its row are the existing ones, so docs/REFUSALS.md does not change.
So the tests say the refusal:
- pipeline::compile::tests::a_replay_variant_under_the_identity_domains_is_refused_typed (was
..._reads_its_root_entries): icb_render_replay_template, icb_render_stride_template under the
pulled-vertex-buffer variant and icb_replay_template under the identity domains with replay
bindings are each refused, typed, with that feature, need and symbol.
- tests::engine_device_replay::
a_replay_variant_under_the_identity_domains_reads_its_slots_from_their_root_entries goes, with
its module-doc paragraph: no such module is made.
docs/API.md section 5 now says the variant is refused there, and slot_address_field's comment
names the admission that refuses it.
Verified: before this commit, on m3-max-66628 (the product suite at 84c6726dd8, a
card-free host build), both item tests failed with exactly this refusal at the three compile
calls and the engine kernel; without the placement, m3-max-66629 (probe branch
steelbrain/halfmoves-probe-nofix2) failed both with the internal error, so the new test fails
without the placement. This commit's own run is the next compile job.
|
||
|
|
46a9a57522 |
Docs: the runtime binds through no stage table; the validation executor sets its buffer ranges
docs/API.md section 5 said of StageTable::buffer_ranges "The runtime sets it on every table it reads." The runtime builds no StageTable and reads no BindState: crates/metal2vulkan-runtime names no StageTable, BindState, BufferRanges or buffer_ranges, and of the binder it takes only alpha_test_code, SamplerDescriptor and AstcDecode. The tables that set it are the validation executor's: every table its candidate engine builds for a compute, render or mesh case passes through candidate::engine::lengths_classed with BufferRanges::of its profile's limits. The sentence now says so. Verified: grep over crates/metal2vulkan-runtime/src for those four names (no hit) and for metal2vulkan::bind (the three items above); the validation builders read at candidate/engine.rs, engine/graphics.rs and engine/mesh.rs, the one other StageTable there (engine/variants.rs) inside a #[test]. Docs only. |
||
|
|
9df6908e36 |
Translator: a replay variant under the identity domains pushes the root table its slots are read from
Under the identity domains a device-replay variant (VariantKey::replay_bindings) ended in an internal error, "a strategy reads the unplaced push field RootTableAddress": a vertex function's buffer arguments, the attribute of the pulled-vertex-buffer variant and a kernel's buffers alike. The variant reads each buffer slot's address from its replayed command's root entry (access::replay_guest_base, which a replay variant's SlotGuestBase reads route to), and the translator already holds it so: the address is not biased in a replay variant (pointer::biased), and its accesses take no SlotBounds (access::identity_contained). But place_slots pushed every device-address slot's SlotGuestBase under the identity domains, whatever the variant, after plan_replay had replaced the selection's SlotGuestBase fields by RootTableAddress. So nothing pushed the root table's address the derived reads load. The field is placed: a device-address slot's push field is its own address only under the identity domains outside a replay variant (slot_address_field), in place_slots and in the census its spill decision reads, and the root table otherwise. No refusal changes, and no module of a compile that succeeded before changes: the combination never compiled. The branch's one SEMANTICS bump (2273, the half-move commit before this one) covers it. docs/API.md section 5 states where a replay variant's slot addresses come from under the identity domains. Verification: - pipeline::compile::tests::a_replay_variant_under_the_identity_domains_reads_its_root_entries, new: icb_render_replay_template, icb_render_stride_template under the pulled-vertex-buffer variant, and icb_replay_template compile under the identity domains with replay bindings, every buffer slot at its device address, RootTableAddress pushed and no SlotGuestBase or SlotBounds, every stage through L3. - tests::engine_device_replay:: a_replay_variant_under_the_identity_domains_reads_its_slots_from_their_root_entries, new: a kernel compiled so on every committed profile under the identity domains pushes RootTableAddress alone, and on the CPU interpreter reads and writes at the addresses its root entries name (guest plus bind_offset, 16 bytes into one buffer), above 4 GiB. |
||
|
|
4892518700 |
Translator: a half the lowering moves through a containment select or a candidate switch keeps its bits
A half moved without arithmetic must keep its 16 bits, a NaN's payload included: a move is not
the device's arithmetic, so no precision note covers it. bb44847705 fixed the contained load of
device memory. Four more moves the lowering makes itself lost the bits:
- the contained loads of the arenas (lower/access/local.rs) and of the constant blob (blob.rs)
selected the decoded f32 with no bits note;
- the switch-at-use over a pointer's candidate buffers (emit.rs: the device buffers' switch and
the blob-or-buffer switch) merged the arms' decoded f32 by a phi with no note.
A store of the moved half then re-encoded it by the device's narrowing. On the CPU interpreter
2045 of the 2048 all-ones-exponent patterns came back 0x7e00 (0x7c01 to 0x7e00, for example) at
each of the four, on every committed profile under the resident-table domains (job m3-max-66591,
the new test without this change).
One form for every move the lowering makes: the bits move beside the value and are noted for the
result, so a later narrow::to_bits returns them.
- A containment select is leaf::contained (bb44847705's narrow::select_zero) at every
containment select of a leaf: device views and addresses as before, the arenas, the constant
blob, and the pulled fetch's source read. The pulled fetch reads raw integer components and
decodes a half after the select, so its output does not change.
- A switch merge: each arm carries its value's parts and their bits (leaf::carried, the bits
from narrow::moved_bits: the bits noted for the value, else its to_bits), the merge's phis
carry both, and leaf::merged notes each part's bits phi for its value phi
(narrow::note_moved), chunk by chunk for a chunked vector.
Where the moved value is stored unchanged, the f32 select or phi and the decodes are dead and
leave the module; where it is computed with, the bits ones are.
Not changed: a leaf that is no narrow float (carried and merged pass its value alone); the
program's own select and phi of a half, which stay the device's moves under
PrecisionNote::NativeNanEncoding; typed objects, which hold a half widened.
SEMANTICS_VERSION 2272 to 2273 (2272 is lane irisvsimd's, landed first): a module that
stores a half moved through one of these paths changes.
Verification:
- tests::engine_half_moves::our_own_moves_keep_every_half_patterns_bits, new: four kernels move
the patterns through a contained private-arena load, a contained constant-blob load, the switch
over two device buffers (an eight-lane half vector, so chunked) and the switch over a constant
buffer or the blob, each module's path asserted (its census key, or its switch-at-use), on every
committed profile under the resident tables. Without this change it fails at all four (job
m3-max-66591: 2045 of 2048 changed, 5 distinct modules each); with it every pattern keeps its
bits (job m3-max-66584, 2 distinct modules each).
- Compile job m3-max-66584 at this tree: fmt, signatures, refusal surface, clippy plain,
--cfg m2v_gpu and --cfg m2v_cpu_icd, workspace rustdoc -D warnings, api-docs.
- The 252-row hash probe over the two app libraries on validation's runtime description: 252 ok,
0 of 252 module hashes move (job m3-max-66587 against m3-max-66590 at
|
||
|
|
4c21ead93c |
bind: the items nothing outside bind/'s own tests reached go, with the tests of them alone
What goes: every item of the translator's bind/ that no product code, no other crate of the
workspace and no consumer reaches, by rustc's own dead-code answer with bind/'s items made
crate-private (no table is trusted), and the tests that test only them. Six files go whole
(acceleration, chroma_decode, rate_map/regions, replay/rules, sample_interleave, tile_map), and
with them replay/draws, replay/generated, fan_out's tests, the device replay's preprocess and the
host replay (replay.rs keeps the merged draw's reads), the heap element and raw-form readers, the
resident set, the mesh arguments module, the rate-map regions, the sparse tile map, the chroma
decoders and the sample interleave modules. Also the empty `impl Device {}`, and the three Device
calls nothing in the tree made: render_descriptor_key, mesh_descriptor_key and
compile_function_with_report (compile_function keeps its body). The old-key test
(the_old_render_descriptor_key_keeps_its_value) goes with render_descriptor_key: one bless item
fewer at every pin.
What stays: what anything reaches. The consumer-reached ArgumentBufferLayout family, the merged
draw's reads (replay/merged and the helpers replay.rs keeps), ycbcr_convert's and
mesh_arguments' reached items, and every bind item validation, conformance, the runtime, the
harness or the examples name. A CPU oracle, accessor or constructor that only tests call, and
whose tests check kept behaviour, becomes #[cfg(test)] test support where it is (812 lines: the
argument layout's `argument`, the YCbCr read model, YCbCrPlanes and YCbCrInPlace's constructors
and accessors, the rate map's accessors and constructors, FunctionTableWords and the snapshot's
bytes, the ASTC and ETC texel formats and block values, heap_classes and image_classes). The
public types without a constructor (TexelRows, YCbCrInPlace, IndirectRef, ViewMapping,
TileThreadgroupMemory, TileThreadgroupArgument, ArgumentFunctionTable, ResidentRange,
BoundAccelerationStructure) stay: a public field or parameter of the library takes each.
Lines (from the batch's tip): product 9,219 removed and 728 added; test 7,758 removed and 381
added. 137 test functions or helpers outside the deleted ones are edited off a deleted item, the
largest by 22 lines. Validation, conformance, the harness and the runtime change only in doc
comments that named a deleted item.
Docs: docs/API.md says what is true now (no replay, no heap element reader, no has_shape, the
texel-buffer parts rule stated inline), docs/REFUSALS.md regenerated, api_signatures.tsv blessed
(522 records out), the api_surface table drops 79 bind names.
Consumer hits at its development (git grep -n -w ITEM development -- '*.rs'). The consumer
imports from metal2vulkan::bind only ArgumentBufferLayout, ArgumentDescriptor,
ArgumentLayoutError and ArgumentType, with no glob, and the runtime re-exports only
bind::SamplerDescriptor; every non-zero count below is a generic word whose hits are the
consumer's own items (none of their lines names metal2vulkan; its 22 `.argument(`/`.place(`
calls are on its own types).
Device::render_descriptor_key 0, Device::mesh_descriptor_key 0,
Device::compile_function_with_report 0.
Deleted public top-level items (93):
ARGUMENT_BYTES 0, bit_index 0, bit_set 0, ChromaDecode 0, draw_merge_module 0, draw_replay_draw 0,
draw_replay_indexed 0, draw_replay_merges 0, draw_replay_module 0, draw_replay_preprocess 0,
draw_replay_primitive_type 0, draw_replay_slots 0, draw_replay_state 0, draw_replay_vertex_layouts
0, DRAW_REPLAY_WRITES 0, DrawMergeModule 0, DrawReplay 0, DrawReplayLayout 0, DrawReplayModule 0,
DrawReplayPreprocess 0, DrawReplayRule 0, extent_of 0, FORMAT 5, GeneratedLayout 0, GeneratedReplay
0, GeneratedVariant 0, geometry_flags 0, GEOMETRY_NO_DUPLICATE_ANY_HIT_INVOCATION 0, GEOMETRY_OPAQUE
0, geometry_table_offset 0, handle_entry_flags 0, HANDLE_TABLE_CAPACITY 0, heap_element 0,
heap_raw_form 0, HeapElement 0, HeapElements 0, InheritedBytes 0, instance_record 0, InstanceRecord
0, interleave_merge_modules 0, interleave_split_module 0, InterleaveMergeModules 0,
InterleaveSplitModule 0, level_extent 0, MAX_DRAW_REPLAY_TYPES 0, MAX_REPLAY_DISPATCHES 0,
MAX_REPLAY_REGIONS 0, MAX_REPLAY_SLOTS 0, MAX_REPLAY_VARIANTS 0, MAX_SEGMENT_COMMANDS 0,
merge_fragment_typed_module 0, MERGED_CHUNK 0, MERGED_HEADER_BYTES 0, MergedLayout 0, MergePhase 0,
mesh_arguments_module 0, MeshArgumentsModule 0, MeshGridRule 0, MetalInstance 0,
NEUTRAL_HEAP_ELEMENT 0, NO_HOLE 0, PARAMS_BYTES 0, PlanesCopy 0, primitive_wrap 0, RateMapRegion 0,
RateMapRegions 0, REGION_BYTES 0, RegionError 0, RegionLimits 0, replay_preprocess 0,
replay_preprocess_generated 0, replay_preprocess_module 0, ReplayExecution 0, ReplayLayout 0,
ReplayPreprocess 0, ReplayPreprocessModule 0, ReplayVariant 0, resident_view 0, ResidentSet 0,
ResidentView 0, resolve 179, SCRATCH 0, SLOT_TABLE_BYTES 0, SOURCE 7, SparseTileMap 0,
split_typed_module 0, STATUS 42, TEMPLATE_HEAD_BYTES 0, texel_buffer_parts 0, TileMapError 0,
TileMapping 0, typed_module 0, VARIANT_BYTES 0
Deleted public methods and associated items (126; the count is of the member's name):
ArgumentFunctionTable::at_address 0, BindingPlan::heap_elements 0, BindingPlan::instantiate_replay
0, BindingPlan::relisted_sampler_tables 0, BindingPlan::sampler_tables 0,
BindingPlan::unit_axes_variant 0, BindState::has_shape 0, BindState::has_shape_beside_used 0,
BoundBuffer::same_shape 0, ChromaDecode::ALL 62, ChromaDecode::BLOCK_BYTES 0,
ChromaDecode::block_extent 0, ChromaDecode::decode 2087, ChromaDecode::decode_into 26,
ChromaDecode::of 20774, ChromaDecode::TEXEL_BYTES 0, ChromaDecode::texel_format 0,
DrawMergeModule::HEADER_PUSH 0, DrawMergeModule::LOCAL_SIZE 0, DrawMergeModule::PUSH_BYTES 0,
DrawMergeModule::push_constants 0, DrawMergeModule::STATUS_PUSH 0, DrawReplay::new 9170,
DrawReplayLayout::argument_offset 0, DrawReplayLayout::fragment_table_offset 0,
DrawReplayLayout::params_offset 0, DrawReplayLayout::vertex_table_offset 0,
DrawReplayModule::LOCAL_SIZE 0, DrawReplayModule::PUSH_BYTES 0, DrawReplayModule::RECORDS_PUSH 0,
DrawReplayModule::RESIDENT_PUSH 0, DrawReplayModule::STATUS_PUSH 0, EtcDecode::block_extent 0,
ExecutionStatus::WORDS 7, GeneratedLayout::count_offset 0, GeneratedLayout::dispatch_offset 0,
GeneratedLayout::INDEX_OFFSET 0, GeneratedLayout::max_sequences 0, GeneratedLayout::PUSH_OFFSET 0,
GeneratedLayout::sequence_offset 0, GeneratedVariant::new 9170, HeapElements::element 103,
ImageViewDesc::new 9170, InstanceRecord::bytes 7067, InstanceRecord::BYTES 29,
InterleaveMergeModules::SET 43, InterleaveMergeModules::WIDE_BINDING 0,
InterleaveSplitModule::LOCAL_SIZE 0, InterleaveSplitModule::SET 43,
InterleaveSplitModule::SOURCE_BINDING 0, InterleaveSplitModule::WIDE_BINDING 0,
MergedLayout::draw_offset 0, MergedLayout::group_count 0, MeshArguments::ARGUMENT_BYTES 0,
MeshArguments::new 9170, MeshArguments::OBJECT_RECORD 0, MeshArguments::scratch_bytes 0,
MeshArgumentsModule::PUSH_BYTES 0, MeshArgumentsModule::SCRATCH_BINDING 0, MeshArgumentsModule::SET
43, MeshArgumentsModule::SOURCE_BINDING 0, MeshArgumentsModule::STATUS_BINDING 0, MeshGridRule::of
20774, MetalInstance::new 9170, ObjectFold::bytes 7067, PlanesCopy::ALL 62, PlanesCopy::format 3896,
PvrtcDecode::BLOCK_BYTES 0, PvrtcDecode::block_extent 0, PvrtcDecode::decode 2087,
PvrtcDecode::decode_rows 0, PvrtcDecode::level_bytes 0, PvrtcDecode::linear 144,
PvrtcDecode::TEXEL_BYTES 0, PvrtcDecode::texel_format 0, RasterizationRateMap::regions 39,
RateMapRegion::scissor_extent 0, RateMapRegion::scissor_offset 0, RateMapRegion::viewport 45,
RateMapRegions::admits 17, RateMapRegions::admits_planned_layers 0, RateMapRegions::MAX_REGIONS 0,
RateMapRegions::physical_size 4, RateMapRegions::precision 24, RateMapRegions::regions 39,
RegionLimits::new 9170, ReplayExecution::new 9170, ReplayFaults::ACTION 4, ReplayFaults::BARRIER 2,
ReplayFaults::BUFFERS 0, ReplayFaults::ENCODING 0, ReplayFaults::GROUP_COUNT 0,
ReplayFaults::PIPELINE 11, ReplayFaults::RANGE 0, ReplayFaults::RECORD 15, ReplayFaults::REGIONS 0,
ReplayFaults::VARIANT 0, ReplayFaults::VERTICES 0, ReplayLayout::argument_offset 0,
ReplayLayout::params_offset 0, ReplayLayout::region_offset 83, ReplayLayout::table_offset 0,
ReplayPreprocessModule::PUSH_BYTES 0, ReplayPreprocessModule::RECORDS_PUSH 0,
ReplayPreprocessModule::RESIDENT_PUSH 0, ReplayPreprocessModule::STATUS_PUSH 0, ReplayVariant::flat
30, ReplayVariant::new 9170, ReplayVariant::with_imageblock_size 0, ResidentSet::bytes 7067,
ResidentSet::holds 3097, ResidentSet::is_empty 1066, ResidentSet::len 4763, ResidentSet::with 6328,
RootTable::resident_ranges 0, SparseTileMap::byte_len 0, SparseTileMap::is_mapped 4,
SparseTileMap::new 9170, SparseTileMap::tile 141, SparseTileMap::to_bytes 6, SparseTileMap::update
185, StatusWord::ALL 62, TexelRows::elements 50, TexelRows::new 9170, TexelRows::size 3417,
TypedModule::requirements 11
Out of the public API into #[cfg(test)] test support (41; the count is of the last name):
ArgumentBufferLayout::argument 298, ArgumentPlace 0, AstcDecode::block_values 0,
AstcDecode::texel_format 0, EtcDecode::ALL 62, EtcDecode::texel_format 0,
FunctionTableSnapshot::byte_len 0, FunctionTableSnapshot::bytes 7067, FunctionTableWords 0,
FunctionTableWords::byte_len 0, FunctionTableWords::new 9170, heap_classes 0, image_classes 0,
RasterizationRateMap::from_layers 0, RasterizationRateMap::layer 325,
RasterizationRateMap::parameter_data_size 0, RasterizationRateMap::physical_granularity 4,
RasterizationRateMap::physical_to_screen 4, RasterizationRateMap::shader_physical_to_screen 0,
RasterizationRateMap::shader_screen_to_physical 0, RasterizationRateMap::vertical 19,
RateMapAxis::from_tiles 0, RateMapAxis::granularity 24, RateMapAxis::screen_extent 0,
RateMapAxis::tiles 148, ycbcr_read 0, ycbcr_texel 0, YCbCrCodes::units 507, YCbCrInPlace::bits 940,
YCbCrInPlace::element_bytes 0, YCbCrInPlace::elements 50, YCbCrInPlace::format 3896,
YCbCrInPlace::of 20774, YCbCrInPlace::view_bytes 3, YCbCrInPlace::with_planes_image 0, YCbCrPlanes
0, YCbCrPlanes::new 9170, YCbCrPlanesSampler::bits 940, YCbCrPlanesSampler::format 3896,
YCbCrPlanesSampler::matrix 122, YCbCrPlanesSampler::range 1784
|
||
|
|
9f3ff1aa75 |
Re-derive the generated documents at the landing tip
They are generated from the whole case set, and the set grew on `development` while this branch was in flight, so the copy committed here counted a smaller one. Verified: regenerating at this tip leaves no change beyond the `Generated at` stamp. |
||
|
|
03e13a12c9 |
Docs: object and mesh SIMD-group functions are a recorded refusal; the vertex quad row says shuffles
- docs/API.md, "Mesh pipelines": an object or mesh function that calls a SIMD-group, quad-group or SIMD-group matrix function is refused on every device, including a device that lists the task and mesh stages in subgroupSupportedStages. The translator models no subgroup facts for those stages (device/subgroup.rs, UNMODELED_STAGE). [[thread_index_in_simdgroup]] alone compiles there (the Linear tier). Until now no doc recorded this open gap where a user reads it. Of the corpus index's 14 object and 32 mesh functions, none calls an air.simd* or air.quad* intrinsic. - fixtures/public/engine/README.md, gsm2_vertex_quad_permutes' row: it said the translation emits Vulkan's quad instructions where the vertex stage takes them. It lowers each one to a subgroup shuffle through the ballot of the live lanes, on every device: a group plan takes quad instructions only in a kernel, as tests::engine_simd's vertex_quad_permutes_shuffle_through_the_live_lanes asserts. The runtime-sources.sha256 move from 032b641117 (device/derive.rs and device/subgroup.rs are runtime inputs) is a hash-only re-pin at landing, with no RUNTIME_VERSION bump. A run's behaviour does not change: the device's enables and caps are the same, and only the translator's subgroup model loses a field. |
||
|
|
8db6d705da |
Vertex quads ask nothing of subgroupQuadOperationsInAllStages: their modules hold no quad instruction
A vertex function's quad broadcasts and shuffle-xors lower to subgroup shuffles on every device: quad instructions are emitted only in kernels (lower/simd/mod.rs, GroupPlan::quad_instructions), and Vulkan exempts the compute and fragment stages from subgroupQuadOperationsInAllStages. So no module this translator emits needs that property. The tier still refused a vertex function with quad operations on a device without it (QuadOperations). That refusal was false: the function runs there as it runs on any other device. What changed: - SubgroupModel::quad_all_stages is deleted, with the tier's refusal and quad_instructions' vertex clause. - The requirement derived from a module (spirv/requirements) adds SubgroupQuadOperationsInAllStages for a quad instruction in every execution model except Fragment and GLCompute. Before, it was added for Vertex alone, so a TessellationEvaluation, task or mesh module that held a quad instruction would have missed it. No emitter writes one today; the derivation follows Vulkan's rule for any module. - The description's quad_operations_in_all_stages and VkProperty::SubgroupQuadOperationsInAllStages stay. Enabled caps and that requirement read them. Consumer check: `git -C reims-vgpu grep -n -w quad_all_stages development -- '*.rs'` has 0 hits. The removed field is the only public item that goes; api_signatures is blessed and loses that one record. docs/REFUSALS.md is regenerated: the QuadOperations row no longer names the property, and it has one site. Test: tests::engine_simd::vertex_quads_need_no_quad_operations_in_all_stages. It compiles gsm2_vertex_quad_permutes' three vertex functions on the Iris Xe (RPL-P) description with the property cleared, and each is a valid module that holds no quad instruction or capability. Without the change, each is refused with QuadOperations. No committed profile has vertex subgroups without the property, so the tier table is unchanged. The vertex quad cases on the measured cards read as before: every one of them lists the property. SEMANTICS: this is a refusal turned into a translation on such a profile. It shares the bump to 2272 with PrecisionNote::VertexSimdgroupGrouping on this branch, since the two land together. |
||
|
|
e3fbf2ca99 |
PrecisionNote::VertexSimdgroupGrouping: a vertex function's simdgroup and quad operations run over the device's grouping
A vertex function that runs a simdgroup or quad operation (any group operation or AGX multiply-add: the simd plan's observes_lanes) records PrecisionNote::VertexSimdgroupGrouping on every device (lower::simd::finish). Metal's shading language defines its SIMD-group and quad-group functions for kernel and fragment functions (MSL 4.1 sections 6.10.2 and 6.10.3) and names no lane among a vertex function's inputs (Table 5.2), so in a vertex function the groups are the device's own, as FragmentSimdgroupGrouping already says of fragment functions. Validation takes the note as unbounded (a difference is a noted difference) and C3 defers its rows (DEFERRED_NEAR_EQUIVALENTS), as it does the fragment note; conformance names it metal2vulkan-degrade-vertex-simdgroup-grouping; docs/API.md's catalogue states it. SEMANTICS 2272. Why: on the Iris Xe (RPL-P, Mesa 26.2.6) 8 authored vertex cases mismatched the M3 Max while the Radeon 780M and the RTX 3090 matched. A raw Vulkan probe outside the runtime (a SPIR-V 1.5 vertex shader over 64 rasterizer-discarded points, validation layer on, 0 messages; Iris Xe job m3-max-66302, Radeon 780M m3-max-66303, RTX 3090 m3-max-66304) read SubgroupSize 32 in every Iris vertex invocation with lane ids 0 to 7 only: 8 subgroups of 8, in each run of 16 vertices the even ones in one and the odd ones in another, every vote, sum, shuffle and quad broadcast exact over the driver's own groups. The 780M runs one 64-lane group in vertex order, the 3090 two 32-lane groups. Vulkan holds SubgroupSize to subgroupSize for a SPIR-V 1.5 module and promises full subgroups only to stages with workgroups, so the driver answers per its properties, and the translator's tier follows the stage's queries (Iris: vertex not in requiredSubgroupSizeStages, Direct at the API size 32). The 8 cases' outputs on the Iris (m3-max-66342) equal, word for word, Metal's semantics over the Iris's own groups with the partly-live rule's own-value read for a lane that takes no part (0 differing words in each of the 8; the grouping of the 40- and 42-point draws is inferred from the 64-point rule). |
||
|
|
54cd974bae |
Translator: a signalling float NaN constant records NativeNanEncoding
Observation: the RTX 3090 run of the authored case b315adcc (float-operations-decided-by-a-bound-constant-fast, fixture sfold_fast.ll, job m3-max-66255) differs from Metal at words 16-19 and 68-71. That is f[4] = fma(float4(k_snan), x, x) with k_snan bound to the signalling NaN 0x7f800321: Metal stores 0x7f800321 and the 3090 stores 0x7fc00321. The module recorded no precision note, so validation counted it as a mismatch. Cause: no fma reaches the module. canon::sccp's float_fold folds an fadd, fsub, fmul, fdiv or air.fma with a NaN operand beside operands only the run knows to that operand, unquieted, as Metal's compiler does once the constants are bound. So the module stores a float4 constant 0x7f800321, and the device's move of it as a float quiets it. No Vulkan rule forbids that, so the stored NaN's bits are the device's. AGENTS rule 1 counts a NaN's bits among the device's own answers and asks for a static note. Fix: nan::holds_signalling_float, called from the arith family's finish(), records PrecisionNote::NativeNanEncoding where the entry's module holds an f32 constant whose bits are a signalling NaN: every exponent bit set, the quiet bit clear and a nonzero payload (nan::signalling_f32). - The rule is decided from the constant's bits alone, never from a name or a case. - An entry's module holds exactly the constants its function reaches (canon::prune), so the note follows the entry, not its library. - It covers every operation of the fold family, because it keys on the stored constant, not on the operation, and it covers a signalling NaN the program wrote itself. - f32 only. A half constant moves as its bits (narrow::constant_bits): h[2] of the same case matches Metal. double is not measured and not claimed. - The scan ticks the meter once for the table's length. Validation reads the note from the module: the candidate takes the pipeline state's precision notes (candidate/platform/runtime.rs), and the comparison class is derived from them (observation_contract::comparison: NativeNanEncoding is Allowance::Unbounded). b315adcc's difference is therefore expected to count as a noted difference instead of a mismatch. That is expected, not yet run. Docs: docs/API.md's NativeNanEncoding entry and the note's doc comment gain the case. They claim only what was seen: the 3090 quiets an f32 constant on the move, the other cards in the runs so far kept its bits, half constants move as bits, and double is not measured. Test: engine_float_call_notes::a_signalling_float_nan_constant_records_the_devices_nan_encoding. A kernel storing the f32 constant 0x7f800321 records the note. One storing the quiet 0x7fc00321 does not, and neither does one storing the half 0x7c01. Without the finish() call the first assert fails. Bless class at the next pin, expected and not audited: authored compile-census rows of cases whose module keeps a bound signalling f32 NaN beside a run value (the sfold cases binding k_snan, b315adcc among them) gain NativeNanEncoding. The golden tables compile with function constants unbound and hold no NaN literal (no public fixture spells one), so they are expected unchanged. No SEMANTICS bump: the batch's last commit carries it. |
||
|
|
556707ed79 |
Translator: containment is the in-shader check on every profile; Robustness goes
The translator chose a containment form from the device's buffer robustness: with robustBufferAccess or robustBufferAccess2 enabled, a descriptor view's access carried no check and the device bounded it. The runtime enables neither feature (its floor's feature table names only nullDescriptor, robustImageAccess and robustImageAccess2), so that form never ran there; it ran only on validation's committed descriptions, as stated. It goes, with the choice: - Robustness (None, Rba, Rba2), DeviceProfile::robustness() and DeviceProfile::checks_buffers_in_shader(), and contain::encoding. A descriptor view's access is the in-shader check on every profile; Check::None remains only for a device-address access that nothing bounds (AccessPlan::psb_contained false). - A texel buffer is checked in the shader on every profile (it was the device's under robustBufferAccess2). Images keep their device form: device_reads_texels and device_drops_texel_writes still read robustImageAccess2 and robustImageAccess, which the runtime's floor requires. - Vertex input: outside the identity domains every attribute is pulled through a checked view; before, a device with robustBufferAccess fetched in fixed function. Under the identity domains nothing changes: fixed function, or the refusal of what it needs. - The loop hoist loses its robustness parameter and the speculative path only Rba and Rba2 reached: a load in the loop's entry run still moves, other loads stay. - Validation: of_compile states buffers as Unused or Checked, the out-of-bounds contract states Check::Shader for a descriptor view and a texel buffer and Unchecked for a fixed-function attribute. BufferEncoding::Robust and Check::Robust stay as stored vocabulary: committed observations hold them, and no compile states them now. Removed public items, each with 0 hits in the consumer's checkout at bd9d6ae85a and at ad28ebd881 (git grep -w -F over *.rs, *.toml, *.md): Robustness, Rba, Rba2, robustness, checks_buffers_in_shader (DeviceProfile, their owner, has 0 hits too). api_signatures.tsv and api_surface.rs are blessed here; docs/API.md (the bounds bullet, the profile facts list, vertex_input) and the runtime README's not-enabled row for robustBufferAccess change in this commit; docs/REFUSALS.md is regenerated and unchanged. No version moves: the batch's SEMANTICS and ARTIFACT_FORMAT_VERSION bumps are applied last, once for the batch. Tests: the hoist's a_guarded_uniform_load_at_a_fixed_word_leaves_its_loop goes with the speculative path; without_robust_access_only_a_load_every_entry_runs_leaves becomes only_a_load_every_entry_runs_leaves; robustness2_selects_the_rba2_encoding keeps its MoltenVK asserts as moltenvk_m3_derives_its_stride_and_format_usages; engine_texture_interp's contains_texel_buffers helper goes, its tests always running N+3 threads. Rewritten to the one form: engine_texture_oob's texel-buffer classes ([Class::Shader]), engine_texture_ulong, engine_graphics_binder's per-device assert, the coverage tier-table and containment tests, and the out-of-bounds contract's fixed-function test. None was the sole proof of a kept behaviour. Golden: the table's columns are validation's committed descriptions as stated, all with robustBufferAccess and 13 with robustBufferAccess2; no column is the runtime's. Every column's fingerprint moves (ProfileFields loses its robustness field). Bless items: 24 rows, 312 cells, 24 in each of the 13 columns that state robustBufferAccess2 and 0 in moltenvk-m3 and runtime-floor, every one hash to hash, in the 14 texel-buffer fixtures now checked in the shader. The .air.ll half (567 typed-pointer fixtures, which need metal-as) is unchecked per commit; the batch's golden bless on the M3 covers it. Verified: - On unshipped's tip before this rebase (96d953bb0b), the same change: compile job m3-max-66123 green (fmt, signatures, refusals, clippy plain, m2v_gpu and m2v_cpu_icd, workspace Rustdoc, api-docs). - At the batch's top on that base (all four commits, probe job m3-max-66130): the hash probe's 252 rows equal unshipped's arm at 4861c9863d (m3-max-65976); the golden probe's set without buffer robustness (the runtime's state) equals the base arm 96d953bb0b (m3-max-66128), 1855 of 1855 rows; the stated set moves exactly the 312 cells above. - Here: cargo fmt; signatures check; refusal surface regenerated. The compile job follows on the branch tip. |
||
|
|
5e3477e60a |
Translator: a buffer slot takes the storage view on every profile; the uniform view goes
A buffer slot took a uniform view only where containment was the device's (contain::encoding gave Check::None, under robustBufferAccess or robustBufferAccess2): the uniform arm of the slot's view choice and Profile F's per-stage storage-buffer fallback. The runtime enables neither feature, so no runtime module took one. The next commit deletes the robustness choice; memory, lower and spirv are crate-private, so its dead_code would fail that commit on its own. The uniform view goes first, with everything that only it reached: - the uniform forms of a view (UniformWords and UniformVec4) and their reads, and Profile F's fallback (fallback_view, fallback_rank). Profile F (runtime-floor without device addresses, below the runtime's floor) now refuses a stage past maxPerStageDescriptorStorageBuffers as DescriptorCount, where before it read its read-only slots through uniform views, under robust descriptors only; - SlotPlan::lane_read and its planner pass, and Uniformity::among_active_lanes, which only that pass ran; - the storage-view variant: LoweringInputs and VariantKey storage_view_slots, the binder's storage_view_variant and large_view_candidates; - RuntimeFact::UniformViewAliasing and UniformViewRange with UniformViewChoice, and the binder's aliasing check with its refusal BindError::UniformViewAliased (docs/REFUSALS.md regenerated: binder refusals 9 to 8); - SpecKey::RangeAtBindOffset (only uniform views declared it), BindState::view_base_alignment and uniform_views_at_residual, StageTable.at_bind_views and StageTable::class_alignment; BoundBuffer::shape, BoundBuffer::same_shape and StageTable::shape lose their view_base_alignment parameter; - BufferRanges.uniform: BufferRanges::length_class and the binder's offset alignment now read maxStorageBufferRange and minStorageBufferOffsetAlignment alone. Nothing in the runtime crate reads BufferRanges, BindState, BoundBuffer, StageTable or BindShape (git grep: 0 hits); it reaches validation's candidate engine only; - AccessClass::Uniform, DescriptorView (Storage, UniformWords, UniformVec4) and BufferForm::uniform_view; BufferForm::Descriptor loses its DescriptorView field. The loop hoist stays: the argument table's Uniform block (lower::access::table, the spilled push fields) still feeds it. Its docs no longer name a buffer slot's uniform view. Removed or changed public items and the types that own them, each with 0 hits in the consumer's checkout at bd9d6ae85a and at ad28ebd881 (git grep -w -F over *.rs, *.toml, *.md): DescriptorView, UniformWords, UniformVec4, UniformViewChoice, UniformViewRange, UniformViewAliasing, UniformViewAliased, RangeAtBindOffset, storage_view_slots, view_base_alignment, uniform_views_at_residual, at_bind_views, class_alignment, uniform_view, same_shape, AccessClass, BufferRanges, buffer_ranges, BufferForm, StageTable, BoundBuffer, BindState, VariantKey, LoweringInputs, RuntimeFact, SpecKey, BindError. crates/metal2vulkan/tests/api_signatures.tsv and api_surface.rs are blessed in this commit, and docs/API.md (the uniform-view form, the bind-offset key, BufferRanges) changes with it. Stored: VariantKey's storage_view_slots, and the codec tags of BufferForm::Descriptor (no field), SpecKey (RangeAtBindOffset gone), RuntimeFact (two variants gone) and DescriptorView (gone). The batch's ARTIFACT_FORMAT_VERSION bump (590 to 591), applied last once for the batch, covers them; no version moves here. Tests deleted whole, neither a containment proof: engine_storage_view_variant.rs (the variant's fixed point) and engine_lane_reads.rs (the uniform view's lane choice). Deleted with the forms they tested: the uniform-view cases of engine_access.rs and engine_binder.rs, the slots tests of the large-view candidates and the bind-offset range, the variant's cache round trip, and the active-lanes tests of lower/simd/uniform. The kept containment proof, a constant buffer shorter than its window, runs on the storage form (a_constant_buffer_shorter_than_its_window_is_contained_in_shader). Profile F's new refusal has its test (a_stage_past_the_storage_buffer_limit_without_device_addresses_is_refused). Golden: at the batch's top only the stated set's 24 texel-buffer rows moved, the 312 cells commit 2 alone moved before the rebase; no other row moved on either set. The .air.ll half (567 typed-pointer fixtures, which need metal-as) is unchecked per commit; the batch's golden bless on the M3 covers it. Verified: - On unshipped's tip before this rebase (96d953bb0b), the same change: compile job m3-max-66120 green (fmt, signatures, refusals, clippy plain, m2v_gpu and m2v_cpu_icd, workspace Rustdoc, api-docs). Before that rebase, this commit alone (hash probe job m3-max-65979) read 252 rows equal to its base's arm. - At the batch's top on 96d953bb0b (all four commits, probe job m3-max-66130): the hash probe's 252 rows equal unshipped's arm at 4861c9863d (m3-max-65976); the golden probe's set without buffer robustness (the runtime's state) equals the base arm 96d953bb0b (m3-max-66128), 1855 of 1855 rows. - The states-only play at the batch's top (render and compute states made and refused, pipelines_created, made_ahead_variants) is the coordinator's, run on the branch; it is not evidence here. - Here: cargo fmt; signatures check; refusal surface regenerated. The compile job follows on the branch tip. |
||
|
|
3a59474e2c |
Docs: CONFORMANCE-COVERAGE.md derives the ordered fetch's 22 every-venue ledger rows
The ordered fetch's deletion (36cc1319c8) replaced 39 venue rows of the conformance ledger with 22 every-venue rows, but left the generated coverage document as it was. The suites job m3-max-65974 (at 4861c9863d) failed the_conformance_coverage_document_is_what_the_sources_derive on it. Regenerated with python3 -I scripts/conformance-coverage/coverage.py: the ledger row count goes from 8041 to 8024, and the padded-blend, extended-range and rotated rows each list once. Verified: the script's output only; the conformance suite runs on the branch. |
||
|
|
4aee2fa9f1 |
Translator: the ordered fetch form goes; its computed writes are refused on every device
The framebuffer fetch had a second form chosen by rasterizationOrderColorAttachmentAccess: over
a rasterization-order input attachment, a fragment function computed writes no Vulkan blend,
write mask or logic operation gives. No runtime enables that feature, so the form ran on no
guest's device. It goes (rule 2: a second form chosen by a query outside the named list; rule 4).
What changes:
- A fetch reads its input attachment ordered between draws alone on every device, noted
UnorderedFetchWithinDraw. Under the identity domains it reads the pushed texture
(PushField::FetchedColor).
- These states are refused on every device: a padded extended-range attachment's blend; a write
of some of the codes one word of an extended-range attachment holds; and a blend no Vulkan
state gives on a rotated (ARGB8Unorm) attachment. Each refusal is FramebufferFetch, not
implemented (lower::fragment::fetch::computed_write_refused).
- A word attachment under a partial mask takes its format's own attachment, and is refused where
the device lacks that format.
- A private logic operation on a device without logicOp is refused naming
PrivateRenderState(LogicOperation) and logicOp.
- Deleted: lower/fragment/input_blend.rs, word_input.rs, the shader logic operation in logic.rs,
lower/arith/extended_range/blend.rs, pipeline/link/fetch.rs, and the arithmetic only they used
(the fma emulation cluster, div_exact, encode_keeping).
- Deleted public items:
- LoweringInputs.framebuffer_fetch and .logic_operation;
- FramebufferFetchInputs, FetchedAttachment, BlendEquation;
- GraphicsState.rasterization_order_attachment_access and
FragmentCaps.rasterization_order_color_access;
- metal::format::extended_range_blend, Feature::ExtendedRangeBlend and the ExtendedRangeBlend
enum;
- RuntimeInput::FramebufferFetch and ::LogicOperation;
- RuntimeFact::ExtendedRangeInputBlend, ::RotatedInputBlend and ::WordInputMerge;
- PrecisionNote::ExtendedRangeBlendSource and ::ExtendedRangeFloatBlendSource.
- The enable-set facts class VK_EXT_rasterization_order_attachment_access as described and never
enabled.
Docs, in this commit:
- rt README: Known gaps of render encoders gets one line per refused state, each built on the
runtime's own fetch form if a guest meets it. The Not-enabled row of
rasterizationOrderColorAttachmentAccess goes, and so does logicOp's mention of the shader form.
- docs/API.md loses the two blend-source notes from the precision-note catalogue, the
rasterization-order form and the word merge.
- REFUSALS.md is regenerated (reach row of ExtendedRangeBlend removed), along with
api_signatures.tsv and the api_surface table.
- The conformance ledger: the 39 rows refused naming rasterization-order access (on llvmpipe and
the UHD 630; on other venues the case read as lacks-feature) become 22 every-venue rows,
refused, needs NotImplemented. The matrix replay on development confirms the scope.
Lines: product sources (crates/metal2vulkan, -air, -runtime src, tests excluded) +238 -4647;
product tests +277 -2279; validation and conformance +61 -182; docs +48 -67.
Consumer search (reims-vgpu at 71573a84c8, git grep -w over *.rs, *.toml and *.md):
- 0 hits: ExtendedRangeBlend, rasterization_order_color_access, BlendEquation,
FramebufferFetchInputs, rasterization_order_attachment_access, framebuffer_fetch,
extended_range_blend, ExtendedRangeBlendSource, ExtendedRangeFloatBlendSource,
ExtendedRangeInputBlend, RotatedInputBlend, WordInputMerge, DualSource.
- Hits that are not these items: FetchedAttachment 2 (rt's DrawKind); logic_operation 8 (its
own structs and rt's private state).
- RuntimeInput: only LinkedFunction is used.
- No glob import or re-export of a metal2vulkan module (only `use metal2vulkan_runtime as rt`).
Verified: cargo fmt; refusal surface and signatures regenerated locally. The compile job and the
host suites follow on the branch.
|
||
|
|
e10fa7ba23 |
Docs: the mesh lowering is only compiled and validated, never compared with Metal on a GPU
The rule keeps the mesh lowering (a sole lowering a supported device could run, and large) with an honest known-gap line. The runtime README's mesh gap said "The translator compiles mesh pipelines"; it now says the lowering is only compiled and validated and has never been compared with Metal on a GPU. docs/API.md's Mesh pipelines section says so before it describes what the lowering emits, and its "Every device runs a grid of up to 2^29 threadgroups" becomes what the lowering takes. Validation's README says a compiled cell of an object or mesh case in the authored compile census means it compiles, not that it draws as Metal does. Searched README.md, docs/*.md (METAL-COVERAGE and CONFORMANCE-COVERAGE included), the runtime, validation and conformance READMEs: METAL-COVERAGE lists mesh render pipelines as missing, and CONFORMANCE-COVERAGE counts Metal-side cases only, so neither reads as mesh working. Docs only. |
||
|
|
c78ff4022c |
Translator: a ulong texture's atomics are refused on every device; the 64-bit image form goes
The rule: a sole lowering under 150 lines that nothing executes is
deleted to a typed refusal. Metal's atomic_min and atomic_max on a ulong
texture lowered to OpAtomicUMin/UMax on an R64ui image, which needs
shaderImageInt64Atomics; no runtime enables it, so nothing ran the form.
texture::atomic::select now refuses the pair as
Unsupported{ImageAtomics} not implemented, on every device. Gone with
the form: TexAtomic.ulong, the R64ui slot declaration and its reads and
writes in the emitter, RuntimeFact::UlongAtomicView with its codec, name
and mechanism rows, the binder's R64_UINT view and neutral,
DeviceProfile::ulong_atomic_gaps, LeafCaps.image_int64_atomics, and
R64_UINT in the queried formats. VK_EXT_shader_image_atomic_int64 is
described and never enabled. Product lines +34 -142.
Tests: the four tests of the 64-bit form and the fact's round trip go;
ulong_atomics_are_refused_on_every_device asserts the refusal on every
committed profile; the legacy-offset test takes the refusal as a gap;
the mechanism table renumbers; the recommendations test lists
shaderImageInt64Atomics as unread. The runtime README's known gap says
the atomics are refused, and its Not enabled row for
shaderImageInt64Atomics goes (the profile reads it no more).
docs/REFUSALS.md and api_signatures.tsv regenerate.
Consumer search (reims-vgpu ad28ebd881): ulong_atomic_gaps 0,
UlongAtomicView 0, image_int64_atomics 0.
|
||
|
|
90b3171413 |
Translator: a multisampled storage image is refused on every device; the enabled arm goes
Where a profile enabled shaderStorageImageMultisample a multisampled storage slot was declared, and a heap held multisampled storage classes; elsewhere both were refused as needing the feature. The runtime never enables it (its README: a multisampled texture has no storage element on any device, as Metal's shaders only read one), and no test executes the declared form. The enabled arm goes: the slot and the heap group are refused Unsupported::not_implemented( Feature::StorageImageMultisample) on every device, the heap's image classes hold no multisampled storage class, and the public ImageCaps.storage_multisample goes with its derivation. docs/REFUSALS.md is regenerated (the refusal is ours now, at both sites). The VkFeature vocabulary and the requirement derivation of a multisampled storage image type stay. The runtime README's "Not enabled" row for shaderStorageImageMultisample goes (tests::feature_enables fails on a row the profile no longer reads). Tests: the heap class test asserts no multisampled storage class on any profile. Class 3 of the planner's rule (a sole lowering under 150 lines that nothing executes). Public item removed: ImageCaps.storage_multisample (api_signatures.tsv blessed); the consumer's checkout (reims-vgpu at bd9d6ae85a) holds 0 uses of it. Product lines: +14 -16. No module that compiles changes; no SEMANTICS bump. |
||
|
|
317613d939 |
Translator: an 8-bit float widens by the integer decode on every device; the native form goes
Where a profile enabled shaderFloat8 an 8-bit float of an OCP encoding (f8e4m3fn, f8e5m2, a tensor's e4m3 and e5m2) widened through the device's own type (OpTypeFloat 8 with its FPEncoding, Float8EXT, SPV_EXT_float8), and a tensor's element recorded PrecisionNote::NativeFloat8. The runtime never enables shaderFloat8 (its README listed it under Not enabled), so on its devices every 8-bit float already widened by integer arithmetic on its fields, as Metal reads them; once validation enables what the runtime enables nothing runs the native form. It goes with what only it reached: Fp8Layout's native field and Fp8Layout::on (every caller takes Fp8Layout::of), fp8_native, native_float8, the crate-private LeafCaps.float8 and its derivation, the IR's Type::Float8 with its type facts, builder, serializer, requirement and interpreter arms (the interpreter's OCP decode with it), and the public PrecisionNote::NativeFloat8 with its cache codec entry (the batch bumps ARTIFACT_FORMAT_VERSION once), conformance's Degradation::NativeFloat8 and validation's allowance arm. The enable-set facts class VK_EXT_shader_float8 as described and never enabled (the matmul2d refusal its comment named is not in the tree). The VkFeature, VkExtension and SPIR-V vocabulary stays. Docs: docs/API.md's precision-note catalogue loses the native-float8 entry; the AIR front end's matmul2d docs and the vocabulary docs say the integer decode; the runtime README's "Not enabled" row for shaderFloat8 goes (tests::feature_enables fails on a row the profile no longer reads). Tests: the widening, matmul2d and SIMD-group matrix 8-bit float tests take the integer decode on every profile, the RTX 50 profile (which lists shaderFloat8) included: no module declares Float8EXT, and the matmul2d sums hold no NaN. Class 1 of the planner's rule (an alternative to what the runtime runs). Public item removed: PrecisionNote::NativeFloat8, here and as the runtime re-exports it (api_signatures.tsv blessed); a consumer that matched it no longer compiles. The consumer's checkout (reims-vgpu at bd9d6ae85a) holds 0 uses of it. Product lines: +23 -190. Modules change only on profiles that enabled shaderFloat8 (their golden rows move, re-stamped at the pin); no SEMANTICS bump (the profile fingerprint changes with the field and is in every cache key). |
||
|
|
3d8e01d2c2 |
Translator: the coverage after the depth tests is refused on every device; its lowering goes
[[sample_mask, post_depth_coverage]] read SampleMask under the PostDepthCoverage execution mode where a profile enabled VK_EXT_post_depth_coverage, and was refused as needing the extension elsewhere. The runtime never enables the extension, so it refused every such function all along, and nothing ever executed the lowering: no test runs it, and the golden tables only compile it. It goes to a typed refusal, Unsupported::not_implemented(Feature::PostDepthCoverage), at the parameter's plan; the IR's ExecMode::PostDepthCoverage goes with its builder, serializer and requirement arms, and the enable-set facts class the extension as described and never enabled. The AIR decode of the parameter (Builtin::PostDepthCoverage) and the SPIR-V and Vulkan vocabulary stay, the decode being what the refusal reads. The refusal moves from a device's to ours: Feature::PostDepthCoverage's doc, its reach mark and docs/REFUSALS.md (regenerated) say every device. The runtime README's known gaps of render pipeline states gain its line: refused on every device, built on the extension with its tests if a guest meets it. Class 3 of the planner's rule (a sole lowering under 150 lines that nothing executes). No public item goes (signatures.py --check clean). The consumer's checkout (reims-vgpu at bd9d6ae85a) names it once, Metal's supportsPostDepthCoverage in a guest test's protocol member list, not an item of ours. Product lines: +15 -34. The golden tables' pdc_after rows move from compiled to refused on the profiles that enabled the extension (re-stamped at the pin); no SEMANTICS bump (the refusal changes no module that compiles). |
||
|
|
22d32fc372 |
Translator: a raster order group takes the pixel interlock alone; the sample interlock goes
A raster order group of a function that runs at sample rate took SampleInterlockOrderedEXT where a profile enabled fragmentShaderSampleInterlock and not the pixel interlock. The runtime never enables the sample interlock (floor.rs: the pixel interlock where reported, the sample interlock left off), so on its devices every group already took the pixel interlock or was refused; once validation enables what the runtime enables nothing runs the sample arm. It goes with the public FragmentCaps.sample_interlock and its derivation, the IR's ExecMode::SampleInterlockOrdered with its builder, serializer and requirement arms, and lower::fragment::rog's sample-rate test of the stage interface. The refusal on a device without the pixel interlock names that feature alone, at the site and in the device's unsupported-feature list (docs/REFUSALS.md regenerated). The VkFeature, SPIR-V capability and execution-mode vocabulary stays. The runtime README's "Not enabled" row for fragmentShaderSampleInterlock goes (tests::feature_enables fails on a row the profile no longer reads). Tests: the sample-interlock test becomes a test that a device with the sample interlock and without the pixel interlock refuses a sample-rate group; the builder and serializer tests take the pixel interlock. Class 1 of the planner's rule (an alternative to what the runtime runs). Public item removed: FragmentCaps.sample_interlock (api_signatures.tsv blessed); the consumer's checkout (reims-vgpu at bd9d6ae85a) holds 0 uses of it. Product lines: +15 -58. Modules change only on profiles that enabled the sample interlock without the pixel interlock (none of the committed profiles); no SEMANTICS bump. |
||
|
|
58b5fad7f3 |
Translator: reads no VK_EXT_depth_range_unrestricted; a depth comparison notes the range everywhere
Where a profile enabled VK_EXT_depth_range_unrestricted the translator clamped a fragment function's depth output to [0, 1] itself (Vulkan then stores it unclamped) and recorded no PrecisionNote::RestrictedDepthRange for a depth comparison. The runtime never enables the extension (its README: the floor does not require it, and replace_region refuses a float depth upload as Gap::FloatDepthUpload), so on its devices the depth was already Vulkan's own clamp and every depth comparison already recorded the note; once validation enables what the runtime enables nothing runs either arm. Both go: DepthClamp::clamps and clamps_fragment_depth (the [0, 1] selects now run under the depth clamp range input alone, as they did on every profile without the extension), and depth_comparison records the note unconditionally. The enable-set facts class the extension as described and never enabled (the core reads none of it), so recommended_enables no longer names it. The VkExtension vocabulary stays. Docs: PrecisionNote::RestrictedDepthRange's doc and docs/API.md's catalogue entry say the note is recorded on every device, the runtime enabling no VK_EXT_depth_range_unrestricted. Tests: the test that compared a depth output with and without the extension and the test that the extension is read from a description go; the comparison test records the note on every profile, RADV's (which lists the extension) included; the kill and depth-clamp-range tests stay. Class 1 of the planner's rule (an alternative to what the runtime runs). No public item goes (signatures.py --check clean); the consumer's checkout (reims-vgpu at bd9d6ae85a) calls no recommended_enables and names the extension nowhere. Product lines: +34 -57 (most of both are doc lines). Modules change only on profiles that enabled the extension (RADV, lavapipe, NVIDIA golden rows move, re-stamped at the pin); no SEMANTICS bump (the profile's enabled set is in every cache key). |