5f5d3ea4550d650c109f98be4e25eb514e5000ef
8546
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
5f5d3ea455 |
rt test: the declared-copies draw test counts the copy in and back around its declared write
What: every_device_copies_a_texture_over_a_buffer_a_draw_declares now reads Metrics::over_copies around the declared write too: one copy in at the draw (after the command buffer's fill), and at least one more, the copy back, once the command buffer completes; it prints the count. Why: the bytes in the buffer alone do not name the path; the counter shows the copies the declaration caused ran (asked for by main for the evidence). |
||
|
|
8cb8faca88 |
rt: a render encoder's use_resource declarations join the copies of textures over a buffer in an image of their own
What: RenderCommandEncoder::use_resource now lends the texture (as the compute encoder's does) and keeps each declared resource once, with the union of its declared accesses, its texture or its buffer's span (render_encoder.rs Declarations). Every later draw of the encoder reaches the declarations as it reaches its bound slots: slots() chains the declared textures, and the declared buffers where buffers are asked, into the reached set that overs_owed takes before the draw and overs_after takes after it; the per-draw overs condition also holds while a declared texture is over a buffer in an image of its own (Declarations::copied, counted as the tables' copied are). A declared write of a Shared buffer or of a texture the host reads (host_reads) now sets the draw's host fact, so the segment's end barrier reaches the host, as the compute encoder's declared_shared_write does. The unstored-write format moves into Declarations unchanged. Why: a draw that reached such a texture only through an argument buffer or a resource ID took no copy in before it (reading an image older than the buffer's bytes) and no copy back after it (the buffer stale for the host and for later commands), a wrong answer; the compute encoder already chains its declarations (encoder.rs Accesses::overs). Test: every_device_copies_a_texture_over_a_buffer_a_draw_declares (copy_over.rs, device cfgs), over the helper's texture one alignment past the device's own pitch, which asserts the image of its own (copied_over) on every device, lavapipe included. After a fill, a draw before the declaration copies nothing; after use_resource(READ) the next draw, which binds nothing, copies it in once and the draw after copies nothing. After a fill of 0x11 and use_resource(WRITE), a draw whose fragment function writes (1, 0, 1, 1) to texel (0, 0) through an argument buffer's texture2d<float, write> leaves [255, 0, 255, 255] and then 0x11 in the buffer's first row once the command buffer completes. Without the chaining the declared draw copies nothing and the buffer keeps the fill. storage_element.rs's ARGUMENT_FRAGMENT and place_id are shared for it. README: the render encoder's use_resource entry says what a declaration reaches. |
||
|
|
59e7b27df1 |
rt: Error::Translation's functions is a boxed slice, keeping the runtime's Err under clippy's large-error bound
What: `functions` is Box<[String]> rather than Vec<String>; the sites that build a nameless Translation (rt's Error::translation, conformance's Failure::of_rt, validation's make_kernel and replay tests) take Box::default(), and the two name tests compare the slice. Why: with a Vec the Translation variant reached 128 bytes and clippy::result_large_err failed every function returning rt's Error (job m3-max-61807: clippy rc=101 in all three configurations, "the largest variant contains at least 128 bytes"); a boxed slice is 8 bytes smaller and holds the same names. Consumer sites that build one write `functions: Box::default()`. Verified: 61807 ran the previous commit's suites green (host rc=0, lavapipe rc=0, the two name tests among them); this commit's clippy, suites and lavapipe run are in its own job. |
||
|
|
2c5573d598 |
rt: a refused pipeline state's Error::Translation names its functions
What: Error::Translation is now Error::Translation { error, functions }. new_compute_pipeline_state
and new_render_pipeline_state fill `functions` at their public entry with each Function stage's own
name in its library (FunctionInfo::name), in stage order (the vertex function before the fragment
function), and the Display prints them: "the translator made no pipeline of a, b: ...". A compiled
stage has no name; a sampler state, a device and a dispatch's late kernel variant name none, and
then the text is as before. It is a diagnostic for the program's log, documented as the text of
the NSError Metal's failed creation gives; no lowering or decision reads it.
Why: the consumer logged only the first refusal of each kind, which hid 6 of one 3D modelling
app's 8 refused kernels; with the names it logs every refused create.
How: the existing creation bodies moved to private compute_pipeline_state and
render_pipeline_state, whose translator errors name no function (Error::translation, for map_err),
and the public entries map them through Error::of_stages. The one-token map_err edits are in
pipeline.rs, render.rs, sampler.rs:371 and device.rs:1290 and 1294.
Same commit: 10 rt test patterns; validation's candidate/platform/runtime.rs (2),
candidate/tests/engine_compute.rs, replay/new_runtime/mod.rs and replay/new_runtime/tests.rs (3);
conformance's rt_side.rs, rt_side/states.rs and case.rs. Conformance's Failure::of_rt records the
error's text without the names (they are the case's own functions), so the 484 answers in
known-gaps-rt.tsv stay as they are. The rt README's compute and render state entries say what
`functions` holds; REFUSALS.md and api_signatures.tsv are regenerated (one changed signature).
Consumer break to follow: reims-vgpu builds or matches rt::Error::Translation(..) at 17 sites,
all in crates/reims-vgpu-vulkan/src/rt_platform/: unbuilt.rs (7), diag.rs (5), library.rs (3),
pipeline.rs (1), argument.rs (1). Each becomes Translation { error, .. } in a match, or
Translation { error, functions: Vec::new() } where it builds one.
Tests (device cfgs): every_device_names_the_function_of_a_refused_compute_state (translate.rs):
a compute state of the vertex function colored_vertex is Error::Translation with functions
["colored_vertex"], and its text starts "the translator made no pipeline of colored_vertex: ".
every_device_refuses_the_patch_draws_it_does_not_build (patch.rs) now also holds the
control-point index type's Tessellation refusal to functions ["tess_triangle_points",
"tess_fragment"] and to the text that names them in that order. Without the entry mapping both
fail on an empty `functions`.
|
||
|
|
627379eb19 |
rt test: the stage-histogram test asserts the starting calibration once its completions are in
What: every_device_counts_each_command_buffer_once_in_every_stage_histogram asserted `calibrations >= 1` on the metrics it read before its command buffers; it now asserts it on the metrics read after the three completions. Why: the device's first calibration is read by the completion thread as it starts (complete.rs, `run`: `Calibration::read` before its loop), and nothing the test did before `before` waits for that thread to have run: settled() waits for the block maker, not for it. On a loaded node the thread had not run yet and the assertion failed (job m3-max-61782, lavapipe on msi-laptop, command.rs:2033). Each `finished` waits for a completion the completion thread saw, which it sees only after that first read, and the read is counted whether or not the call succeeds, so after three completions the count holds at least one on every device. Verified: its job runs the test on lavapipe; the race is timing-dependent, so no run shows the old form failing on demand. |
||
|
|
046853cc1e |
Re-pin the runtime sources at the landing tip
The landed packet changed a runtime-sources input, so the committed digest no longer described the sources and `the_runtime_sources_are_the_committed_ones` would fail. Recomputed over the same inputs and committed by land-pkt.sh. |
||
|
|
ab8277a560 |
Fix forward of 6ef64ae3ee: the raster-state test's depth bias clamp refusal is below the floor
|
||
|
|
62b3e5a250 |
rt: the render encoder's use_resource, and a draw after a declared write of a texture with no storage element is Gap::StorageElement
What: RenderCommandEncoder::use_resource is useResource:usage:stages:, its plural and their
deprecated forms without stages. The command buffer keeps the buffer or the texture until it
retires and nothing is recorded: every resource is resident to every function, and the pass's
barriers already order its draws. A usage that writes a texture (or a view of one) made for
shader writes with no storage element marks the encoder, and every later draw whose vertex or
fragment function may reach a texture through its storage image beyond its slots
(PipelineInterface::unbound_storage_textures: an argument buffer's write or read_write texture, a
resource ID) is Gap::StorageElement with no slot, as the compute encoder's dispatch already is.
Before this, such a draw ran and Vulkan dropped the writes Metal makes. The declaration
invalidates the encoder's held draw facts, so a draw of an unchanged state and bindings after it
is checked again.
Also: the three redundant explicit links in new_render_pipeline_state's docs (private rustdoc
-D warnings, from
|
||
|
|
bc69c32292 |
Stage io: Metal's own centre varyings, interpolation, vertex fetch and alpha coverage go
DriverDeviation::MetalCenterVaryings, MetalInterpolation, MetalNormalizedVertexFetch and MetalAlphaCoverage were never taken, and neither were their VkProperty twins and codec tags. Device::from_queries enables no Metal* property, and no committed profile carries one. The forms that only they reached go with them: - Centre varyings. A multisampled fragment function no longer reads its centre varyings as they are as their pixel form. The pixel form is InterpolateAtOffset at offset 0 where the device has it, and graphics' link check needs it, as on every real device. StageIoPlan's center_varyings_by_device and its requirement go. - Interpolation: a smooth varying records DeviceInterpolation on every profile. StageIoPlan::interpolation_by_metal and its requirement go. - Normalized vertex fetch: a fixed-function normalized attribute records DeviceVertexConversion on every profile. The measured form goes, along with vertex::rounds_twice_to_half, which only it read. - Alpha coverage: a pipeline that covers by alpha records DeviceAlphaCoverage on every profile. - With no measured property left, vertex::FixedFunctionNotes goes: fixed_function_notes and graphics::coverage_notes return their notes. Linked::vertex_properties and fragment_properties go, and so do their requirements in compile::api. Rule 1: no note stops being raised. DeviceInterpolation, DeviceVertexConversion and DeviceAlphaCoverage were withheld only on a profile that took one of these deviations, so on no real device. Each is now raised wherever its answer is the device's, on every profile. A centre varying took no note: its read as it is was exact on such a device, and it now takes the InterpolateAtOffset form or link's refusal, as on every real device. The catalogue loses no entry, and the notes' docs in artifact.rs lose their deviation clauses. Validation: no validation file names these deviations. Tests: the asserts that no module or pipeline requires one of these properties go: engine_fragment's interpolation test, engine_vertex_variants' fixed-function conversion test and engine_alpha_coverage's. SEMANTICS_VERSION 2243 and ARTIFACT_FORMAT_VERSION 581 are placeholders that main renumbers. SEMANTICS: the profile's fingerprint changes form. ARTIFACT: the codec loses four VkProperty tags. RUNTIME_VERSION stays, because the pinned sources' edits remove forms no profile reached. runtime-sources.sha256 takes the new hash, and api_signatures is blessed. Consumer check (consumer-uses.sh, consumer development a414607f95, 62 refs): MetalCenterVaryings, MetalNormalizedVertexFetch and MetalAlphaCoverage have 0 hits in code. MetalInterpolation has 0 hits on development, whose answer.rs does not name it. It is named in crates/reims-vgpu-vulkan/src/answer.rs on 35 of the consumer's steelbrain/* branches younger than a day. Verified: m3-max-61492 (homelab-gem10-1): fmt, clippy (all features, --cfg m2v_gpu, --cfg m2v_cpu_icd) and Rustdoc green at the old base (m3-max-61489 before it failed on four unused imports and a test's leftover property read, removed). Rebased onto development |
||
|
|
2eb94c3045 |
Texture stores: the stores measured to be Metal's go
DriverDeviation::MetalHalfStorageWrites, MetalHalfStorageNans, MetalHalfTexelWrites, MetalNormStorageWrites, MetalSmallFloatNans, MetalDepth16Stores and MetalDepth16BiasedStores were never taken, and neither were their VkProperty twins and codec tags. Device::from_queries enables no Metal* property, and no committed profile carries one. The forms that only they reached go with them: - A float write to a half-float storage image: its rounding and NaN are the device's, noted (DeviceColorConversion, DeviceNanEncoding), on every profile. half_storage_facts loses its two property arms, and a packed small float image's NaN loses its property arm. - A half texel's NaN (half_write_nans): every float channel's stored NaN is the device's, noted outright or under the bound format's or the heap's families. The Sixteen and Small kinds and NAN_FAMILIES' deviations go, so the table is the four family bits. - A normalized write (norm_storage_facts): every write that may reach a normalized format records DeviceColorConversion. The measured form, with its 1-bit alpha exception, goes, along with metal::format::one_bit_alpha and one_bit_storage, which only it read. Its shape and form arguments go too. - A fragment's float output blended in the shader into a 16-bit float attachment: the store's rounding is the device's, noted. color_write's reliance goes. - TexturePlan::storage_properties and StageIoPlan::color_properties, which held only these properties, go with their requirements in compile.rs. - The depth16 deviations read no module. Only their docs and the depth bias doc's clause go: the runtime announces unorm-depth-rounding and unorm-depth-bias as before. Rule 1: no note stops being raised. DeviceColorConversion and DeviceNanEncoding were withheld only on a profile that took one of these deviations, so on no real device, and they are now raised wherever such a store's answer is the device's. The catalogue loses no entry. Its DeviceColorConversion and DeviceNanEncoding docs in artifact.rs lose their deviation clauses. Validation: no validation file names these deviations. Tests: the asserts that no module requires one of these properties go, along with the measured-profile arms: engine_texture's half texel write, engine_fetch_blend16_narrow, engine_handles' heap write and heap texel write (its float families are the 16-bit and packed small float ones), engine_extended_range's half-float slots and heap half write, and engine_cross_class' integer writes. SEMANTICS_VERSION 2242 and ARTIFACT_FORMAT_VERSION 580 are placeholders that main renumbers. SEMANTICS: the profile's fingerprint changes form. ARTIFACT: the codec loses seven VkProperty tags. RUNTIME_VERSION stays, because the pinned sources' edits remove forms no profile reached. runtime-sources.sha256 takes the new hash, and api_signatures is blessed. Consumer check (consumer-uses.sh, consumer development a414607f95, 63 refs): MetalHalfStorageWrites, MetalHalfStorageNans, MetalHalfTexelWrites, MetalNormStorageWrites and MetalSmallFloatNans have 0 hits in code. MetalDepth16Stores and MetalDepth16BiasedStores have 0 hits on development, whose answer.rs names neither. They are named in crates/reims-vgpu-vulkan/src/answer.rs on 36 of the consumer's steelbrain/* branches younger than a day. Verified: m3-max-61479 (homelab-gem10-1): fmt, clippy (all features, --cfg m2v_gpu, --cfg m2v_cpu_icd) and Rustdoc green at the old base (m3-max-61473 before it failed on four unused imports, removed). Rebased onto development |
||
|
|
a134775713 |
Simd: Metal's own lockstep, fragment and vertex simdgroups, and full quads go
DriverDeviation::SimdgroupLockstep, MetalFragmentSimdgroups, MetalVertexSimdgroups and MetalFullQuads were never taken, and neither were their VkProperty twins and codec tags. Device::from_queries enables no Metal* property, and no committed profile carries one. The forms that only they reached go with them: - Lockstep. Kernel ordering no longer leaves out a barrier that only emulated simdgroups make exact on a device that runs a simdgroup in lockstep. This removes OrderKey's device bit and the Decision's count, air::Lockstep::device in metal2vulkan-air, SimdPlan::device_lockstep, the census name barrier.lockstep.device (simd::DEVICE_LOCKSTEP) and the module's VkProperty::SimdgroupLockstep requirement. Every such place takes its barrier and tier as on every real device. - Fragment simdgroups. SimdPlan::metal_lane and its requirement go. A fragment's [[thread_index_in_simdgroup]] is the device's grouping's lane on every profile, and the SimdWidth refusal no longer offers VkProperty::MetalFragmentSimdgroups as an alternative: it needs the 32-lane width alone, as subgroup::tier's own width refusal does. docs/REFUSALS.md's row and the fixture inventory's 24 refusal cells on the eight gsm2_fragment_lanes rows change with it. - Vertex simdgroups. The prefix lane goes: SimdPlan::prefix_lane, its Private word and entry hook (simd::emit_entry), and SubgroupRequirement::metal_vertex_simdgroups with its swap of SubgroupStage(Vertex). A vertex function's simdgroup operations need the stage listed, as on every real device. - Full quads. SimdPlan::metal_full_quads and its requirement go. A fragment whose group operations count the helpers needs shaderQuadControl, as on every real device. Rule 1: no note stops being raised. FragmentSimdgroupGrouping was withheld only on a MetalFragmentSimdgroups profile, so on no real device, and it is now raised wherever the function's answer reads the simdgroup's members, on every profile. Its catalogue entry already said "on every device", and its doc in artifact.rs now says so too. The other three forms carried no note. Their inputs now take a barrier, a refusal or the device's grouping, as on every real device. The catalogue loses no entry. Validation: c3.rs's FragmentSubgroupUnderTwoQuads doc clause becomes "every device takes that note, so the gap's answer is always announced". That is the one validation file that named one of these deviations. It used the deviation only to explain why the gap's answer is always announced, because the allowance code never reads the deviation. Nothing else in c3.rs changes. The fixture README's gsm2_fragment_lanes row drops the Metal lane and the gone driver_deviations lane, and its gsm2_simd_products and gsm2_vertex_votes_shifts rows drop MoltenVK's measured vertex classes. Tests: the asserts that no module requires one of these properties, or counts barrier.lockstep.device, go with them. This covers engine_simd_lockstep's two emulated-tier tests, its no-barrier lists and LOCKSTEP_NAMES, engine_simd's fragment-lane test (whose narrow refusal now needs the width alone), and engine_matmul2d's tier assert, which held on every profile once no profile had the property. Also going: device/tests/subgroup.rs' a_measured_vertex_stage_states_its_fact_in_place_of_the_stage and the requirement literals' field. engine_fragment's simd_after_discard takes quad control alone. SEMANTICS_VERSION 2241 and ARTIFACT_FORMAT_VERSION 579 are placeholders that main renumbers. SEMANTICS: the profile's fingerprint, the SimdWidth refusal's needs and the census of the same input change form. ARTIFACT: the codec loses four VkProperty tags and the requirement's field. RUNTIME_VERSION stays, because the pinned sources' edits remove forms and fields no profile reached. runtime-sources.sha256 takes the new hash, and api_signatures is blessed. Consumer check (consumer-uses.sh, consumer development a414607f95, 62 refs): SimdgroupLockstep, MetalFragmentSimdgroups, MetalFullQuads, metal_vertex_simdgroups and DEVICE_LOCKSTEP have 0 hits in code. MetalVertexSimdgroups has 0 hits on development. It is used in crates/reims-vgpu-vulkan/src/gpu/encode_render/tests/metal_tests.rs on 36 of the consumer's steelbrain/* branches younger than a day, a file its development does not have. air::Lockstep::device: the consumer's development names no `lockstep` at all. Verified: m3-max-61467 (homelab-gem10-1): fmt, clippy (all features, --cfg m2v_gpu, --cfg m2v_cpu_icd) and Rustdoc green at the old base (m3-max-61463 before it failed on four unused test imports, removed). Rebased onto development |
||
|
|
3a5ce4bdec |
Sampler: the bound format's class read as push data goes
The texel-format specialization that a function read as push data (SpecKey::TexelFormat, carried by PushField::Specialized) served only the half-texel routine, which the previous commit deleted. Only that routine's slots declared the constant: SlotPlan::texel_format's other reason, a raw linear sample, was set nowhere. RuntimeFact::TexelFormat was recorded only beside it. With the routine gone no module declares the key, so the path is dead on every profile and goes whole: - lower/specialized.rs (request, emit_entry), the emission's localized constants with TypedModule::localize_specs, and SlotPlan::texel_format with its declaration; - SpecKey::TexelFormat and SpecKey::read_as_data, and PushField::Specialized with its field shape, its instantiation arm, slots::record_specialized and the plan's TexelFormat answer (ResourcePlanner::texel_format). The interpreter's push of it goes too: specialized_push becomes tail_push, which pushes the tail word alone; - RuntimeFact::TexelFormat with its mechanism, and the test-only PushPlacement::pushed_values. BindingPlan::specialized_value and the template's specialized values stay: the specialized notes' tests (BoundSamplerWord, HeapRawTextures, HeapNanFamilies) read them. No note changes, because nothing raised or read a note through these items. The docs that named the key or the data form now name what is still true: SpecTest's keys, precision_notes_bound, spec_bits, the texel_format module and TexelFormat, the heap handle's class field (metal::texel_format::with_border), lower::texture's half texels (the device's, rounded to nearest even, HalfTexelConversion), bind::graphics' key list and bicubic::flag. Tests: the following go: - engine_specialized.rs (the read-as-data path), the version 377 round trip and texel_format_follows_the_bound_format; - the push fillers' arm for the field, the binder tests' pushed-values loops (engine_cross_class included) and link_and_validate's read-as-data check; - the asserts that a module reads no TexelFormat key or fact (engine_handles, engine_sampler, engine_srgb_decode, engine_texture_interp, cache/tests), which go with the key. StageInterface::reads_key, now equal to declares_spec, goes; its one caller takes declares_spec. The merged-members round trip, api_tests' specialized-notes test and engine_spec_bits take SpecKey::BicubicTexels, another u32 class key, as their key. The mechanism table's fact index 43 passes to HeapStorageReads, over 0..100. The push placement sweep (lower::push's placement_invariants_hold_over_synthetic_field_sets) now picks among however many field kinds it lists: nine without PushField::Specialized, where its fixed ten indexed past them (m3-max-61568, the first rebased tip's tests, found it). SEMANTICS_VERSION 2240 and ARTIFACT_FORMAT_VERSION 578 are placeholders that main renumbers. The codec loses the PushField, SpecKey and RuntimeFact tags, and the key's enum loses its member. RUNTIME_VERSION stays, because no module declared the key, so no run pushes it. runtime-sources.sha256 takes the new hash. api_signatures is blessed, and docs/REFUSALS.md and the coverage are unchanged. Consumer check (consumer-uses.sh, consumer development 8628a2fdd9, 63 refs): TexelFormat, read_as_data, localize_specs and pushed_values have 0 hits in code. Specialized has 0 hits in code and is named only in a link-order list. Verified: m3-max-61453 (homelab-ms01-1): fmt, clippy (all features, --cfg m2v_gpu, --cfg m2v_cpu_icd) and Rustdoc green at the old base. Rebased onto development |
||
|
|
305d85a2a2 |
Sampler: Metal's own sampler and the cube-gradient routes go
DriverDeviation::MetalSampler, CubeGradientRoute and GraphicsCubeGradientTangents, with VkProperty::MetalSampler and its codec tag, were never taken: Device::from_queries enables no Metal* property and always inserts VkProperty::DeviceSampling, and no committed profile carries a Metal* property. ProfileFields::cube_gradients, with CubeGradients and CubeGradientRoute, had one reachable value (Vulkan's rule for both stages), so it goes too. The forms only they reached go with them: - Cube gradients: CubeFootprint::Metal and ::Projected (MoltenVK's gradientcube and its graphics fixup); a cube's explicit gradients take Length, Face or Word by the sampler's anisotropy alone, and CubeGradientFootprint is raised wherever the shader does not take Metal's level and taps itself. - The sampler requirement: SamplerFamily::metal_sampler merges into device_sampling. Every sample, gather and LOD query, the hoisted no-bias samples and BiasReach::Metal's included, requires VkProperty::DeviceSampling and records DeviceSampling, as on every real device. - The half-texel routine (lower/texture/half.rs) and everything only it read: HalfClass, half_class and heap_half_class, TexelLanes and TexelOrigin, the texel argument of texel_value and held_value, sample_lanes and word_reads_one, Sampling::one_texel's word forms (one_texel now answers whether an access may read one texel, which float_texel_notes reads) and half_texel, SamplerSlot::texels, SlotPlan::half_format and unmeasured, TexturePlan::heap_half, the declarations half_format, half_routine and plain_half, the module's table of heap texel classes (AccessPlan::heap_class, declare_heap_classes, heap_texel_class, HEAP_CLASS_WORDS, and texel_format::heap_classes, whose tests now read the layout itself), texel_round::f32_to_half_from_even, NoteOn::Unmeasured, SpecKey::UnmeasuredTexels and PlainHalfTexels with their plan answers, TexelFormat::YCBCR_8192, MEASURED_ON_METAL_SAMPLER, unmeasured_on_metal_sampler and plain_on_metal_sampler, and the identity-domain refusal of a heap half sample that only a Metal-sampler profile met. - The Metal sampler's YCbCr filter note (linear::filter_note and metal_filtered_ycbcr), with NoteOn::HeapYCbCr and ArgumentSamplers, SpecKey::HeapYCbCrTextures and FilteringArgumentSampler, their plan answers and TexelFormat::two_plane_ycbcr. - The anisotropic not-mipmapped clamp [0, 0] (vk_sampler's own_anisotropic) and its note's source (anisotropic::own_not_mipmapped); PrecisionNote::NotMipmappedAnisotropicFilter, its codec tag, conformance Degradation and validation allowance go with its only source. - The rest: device_texels, device_decode's and fragment/color.rs's Metal decode, bind::plan::resources' swizzled_packed profile test, and border_read's metal_sampler (and device_opaque_black's format argument, which nothing then read). Rule 1, per note the commits stop raising: every one is case (b), no difference goes silent. - filter_note's HalfSampleFilter and FloatSampleFilter (slot clauses on a bound two-plane YCbCr format and the bound sampler word, heap clauses on HeapYCbCrTextures and FilteringArgumentSampler): raised only on a profile with VkProperty::MetalSampler, so on no real device. Such a filtered sample goes to the device's own sampler, and every sample, gather and LOD query sets device_sampling, so the stage records DeviceSampling, whose entry covers the device's filter of a two-plane texture. The in-place Y'CbCr model's HalfSampleFilter and FloatSampleFilter stay as they were. - NotMipmappedAnisotropicFilter: raised only under own_not_mipmapped, which needed MetalSampler. An anisotropic sample on a device with samplerAnisotropy goes to the device's sampler (DeviceSampling, its not-mipmapped clamp [0, 0.25] the device's footprint), and one without it keeps AnisotropicFilter or DeviceAnisotropicFilter, as on every real device. - The rest only widen: HalfTexelConversion (now outright at every half read, sample and gather, where the Metal-sampler profile tested the bound class), DeviceTexelConversion, SrgbTexelDecode and CubeGradientFootprint, each withheld only on a Metal-sampler or Metal-route profile. The precision-note catalogue loses NotMipmappedAnisotropicFilter alone; the docs of GradFromBias, HalfTexelConversion, HalfSampleFilter, SrgbTexelDecode, FloatSampleFilter, DeviceSampling and DeviceTexelConversion lose their Metal-sampler clauses (docs/API.md's entries already stated the one rule). Validation: comparison.rs's allowance list loses NotMipmappedAnisotropicFilter (unbounded), which no device raised; its HalfSampleFilter and FloatSampleFilter reasons now name the in-place model, their class unchanged (unbounded). No validation file names a deleted DriverDeviation. Also, from the planner: the citation of VUID-RuntimeSpirv-NonUniform-06274, which spec 1.4.366 no longer has, becomes VUID-RuntimeSpirv-None-10148 and VUID-RuntimeSpirv-subgroupSize-10149 in spirv/builder/ops/memory.rs, spirv/ir/module.rs (twice), spirv/serialize/mod.rs and the doc of non_uniform_elements_are_decorated_through_what_carries_them. Comments only. Tests: each deleted form's tests go with it: lower/arith/tests/half_texel.rs (the routine, its plain arm, and the steps that bounded the Metal-sampler note) with arith/tests.rs' quantize_flush_of, which only it read, f32_to_half_from_even_is_exact_on_every_tie, the projected-footprint test and the swizzle helper of face/tests/anisotropic.rs, texel_format's ycbcr_8192, wide16 and metal_sampler_s_read_bits tests, the format version 326 round trip, and the routes' asserts in engine_handles, engine_heap_binder and engine_sampler_unk. The rest assert the device's sampler on every profile: half_reads_round_their_texel_to_nearest_even (was half_reads_convert_by_the_bound_format), heap_half_texels_round_the_device_s_texel (was heap_half_texels_convert_by_the_handle_s_class), heap_linear_samples_are_the_device_s (no FloatSampleFilter, outright or specialized), engine_sample_coordinates' requires_the_sampler, engine_bias_reach, engine_graphics_binder's border test, engine_srgb_decode, engine_sampler, the routines test, the merged-members round trip, and metal/sampler.rs' and format/tests.rs' opaque-black calls. SEMANTICS_VERSION 2239, ARTIFACT_FORMAT_VERSION 577 (placeholders; main renumbers). SEMANTICS: the profile's fingerprint and the notes of the same input change form. ARTIFACT: the codec loses the VkProperty, the PrecisionNote and four SpecKey tags. RUNTIME_VERSION stays: the pinned sources' edits (device/, bind/plan/resources.rs and slots.rs, metal/sampler.rs, cache/codec.rs) remove forms and keys no profile reached, so no run changes; runtime-sources.sha256 takes the new hash. api_signatures is blessed; docs/REFUSALS.md and the coverage are unchanged. Consumer check (consumer-uses.sh, consumer development 2040502291, 62 refs): CubeGradientRoute, GraphicsCubeGradientTangents, CubeGradients, cube_gradients, FilteringArgumentSampler, HeapYCbCrTextures, PlainHalfTexels and UnmeasuredTexels 0 hits (code). MetalSampler and NotMipmappedAnisotropicFilter: 0 hits on development (its answer.rs names neither, and it has no gpu/rgbx.rs); named in crates/reims-vgpu-vulkan/src/answer.rs and gpu/rgbx.rs on 36 of the consumer's steelbrain/* branches younger than a day. Verified: m3-max-61441 (msi-laptop, this tree): fmt, clippy (all features, --cfg m2v_gpu, --cfg m2v_cpu_icd), Rustdoc green; tests 5861 of 5863 passed. The two failures: golden_hashes_match_the_table, every one of its 29536 cells under a changed profile fingerprint (re-blessed on development at a named pin), and the_old_render_descriptor_key_keeps_its_value, left unpinned until the next named pin. Rebased onto development |
||
|
|
efa911bc00 |
Arith: the Metal arithmetic deviations and the profile's float-function and NaN-encoding fields go
DriverDeviation::MetalFloatFunctions, MetalCanonicalNans, MetalFloatDenormals, MetalUnaryDenormals, MetalMinMax, MetalHalfFma, MetalPackConversions, MetalHalfArithmetic, MetalNanMoves and MetalHalfConversion, with their VkProperty values and codec tags, were never taken: Device::from_queries enables no Metal* property, and no committed profile carries one. Their forms go, and so do the two profile fields each left with one reachable value: - ProfileFields::float_functions and FloatFunctions (only Native was reachable): the device's functions are never Metal's own. Gone with it: pipeline::EntryMath (public), the entry-math argument of PrecisionNote::of_float_operator and of_math_call, libm's Mode and its device_answers and device_near_equivalent, spirv's ProductForm (a product is an OpFMul, its negative-zero Fma form gone), and arith's OpNotes, MetalOwn and metal_functions_in (a call's notes are a BTreeSet<PrecisionNote>). - ProfileFields::nan_encoding and NanEncoding (only Native was reachable): NanAnswer's device_answers and nan::encoding go; every NaN Metal answers is noted NativeNanEncoding. - Denormals: denormal.rs keeps covered() alone (Covered, device_flushes, unary_kept and moves_sign go); every f32 denormal left to the device is noted DeviceDenormals. - MinMax: Metal's minimum and maximum family is the device's NMin, NMax and NClamp, noted NativeMinMax (device_min_max goes). - MetalHalfFma: its arm and test go. - Pack conversions: every air.pack and air.unpack is noted DevicePackConversion (pack::measured and ArithPlan::metal_packs go). - Half arithmetic: the device's 16-bit half + - * is taken only under the 16-bit float controls; F16Basis goes (f16_arithmetic answers a bool), and so do ArithPlan::f16_arith and the FastMathRewrites note of the measured form left to the device's compiler. - NaN moves: a widening's, a negation's and a magnitude's NaN is the device's, noted (moved_nan, moves_nan, nan::moves_answered, FloatFacts::nan_moves and ArithPlan's nan_moves and held_nan_moves go). A half texel's write to a 32-bit float format notes DeviceNanEncoding on every device (texture::half_write_nans' Wide class goes; HeapNanFamilies' NAN_WIDE family now holds no deviation). - Half conversion: every half the module rounds through the device's conversion is noted NativeHalfConversion; texture::half_texels (a sample of a 32-bit float texel) and half_texel_nans (a 32-bit float or packed small float class) lose their MetalHalfConversion exceptions, so both note those classes on every profile. Gone with it, the analyses only the measured facts read: narrow::round_measured (round serves) with the measured roundings the builder and the IR carried, narrow::rounds_unmeasured, narrow::moves_unfolded with the merges module, and the stored texels the texture writes recorded for it. compile.rs's half-rounding block keeps converts, widens, the controlled and fused roundings and their three notes; the MetalNanMoves, MetalHalfConversion, MetalPackConversions and MetalHalfArithmetic requirements go. Notes: the precision-note catalogue loses no entry. Every note the deleted forms withheld is still raised, now on every device (NativeNanEncoding, DeviceDenormals, NativeMinMax, DevicePackConversion, NativeHalfConversion, HalfTexelConversion, DeviceNanEncoding, NativeDot, NativeMix); their docs and docs/HOWTO.md lose the measured exceptions, and the docs of a device whose functions are Metal's own go from math.rs, arith and artifact.rs. Validation: c3/bound.rs asks the product's notes of an operation (AirOp::product_notes), part of how C3 decides a near-equivalent; it passed an EntryMath the product read only for the unreachable form, so it drops the argument and its answers are unchanged. fast_trig_within_apples_bound's doc loses the MoltenVK clause. Tests: each deleted form's tests go with it (the_maths_functions_are_the_device_s, the member format version 486 round trip, a_measured_half_sum_requires_the_arithmetic_fact_alone, a_merge_of_a_select_is_followed_through_struct_members, the device_answers asserts), with the hand-set profile fields only they used (FloatFacts' nans, device_denormals, unary_denormals, native_min_max, nan_moves). The rest assert the note on every profile: engine_arith, engine_float_call_notes (its note class is the fma route alone), engine_native_half, engine_metal_denormals, engine_tiny_products, engine_rate_map, engine_opencl_mode, engine_texture, engine_extended_range's heap test, from_queries, arith's and narrow's tests. SEMANTICS_VERSION 2238, ARTIFACT_FORMAT_VERSION 576 (placeholders; main renumbers). SEMANTICS: the notes and keys of the same input change form. ARTIFACT: the codec loses ten DriverDeviation and eight VkProperty tags and EntryMath. RUNTIME_VERSION stays: the pinned sources' edits (device/profile.rs, device/derive.rs, device/requirements.rs, lower/arith/pack.rs and a doc in bind/heap.rs) remove forms no profile reached, so no run changes; runtime-sources.sha256 takes the new hash. api_signatures is blessed; docs/REFUSALS.md and the coverage are unchanged. Consumer check (consumer-uses.sh, consumer development c8407fb6fc, 58 refs): EntryMath, of_float_operator, of_math_call, MetalCanonicalNans, MetalFloatDenormals, MetalFloatFunctions, MetalHalfArithmetic, MetalHalfFma, MetalMinMax, MetalNanMoves, MetalPackConversions, MetalUnaryDenormals, FloatFunctions and NanEncoding 0 hits (code). MetalHalfConversion: 0 on development; used in crates/reims-vgpu-vulkan/src/gpu/rgbx.rs on three of the consumer's steelbrain/* branches (gaugetick, recnil-r4, refdump), a crate its development no longer has. Verified: m3-max-61298 at this tree (WIP arith 10, msi-laptop): fmt, clippy (all features, --cfg m2v_gpu and --cfg m2v_cpu_icd) and Rustdoc rc 0 (61293, on the tree before, failed clippy on three unused imports, which this tree removes); nextest over metal2vulkan, metal2vulkan-conformance, metal2vulkan-validation and metal2vulkan-runtime, 5876 run, 5874 passed, 25 skipped, 2 failed: the render key test (the_old_render_descriptor_key_keeps_its_value), left unpinned until the next named pin, and golden_hashes_match_the_table, whose 29536 stale cells are all under a changed profile fingerprint (0 new, 0 gone, 0 under a changed fixture source): the profile lost two fields, so every key changed and the table is re-blessed on development. Rebased onto development |
||
|
|
5db3215260 |
Rotated blends: every blend not exact by construction announces its rounding
The planner's ruling on the rotated blend: the note no longer follows a measured table. A blend on an attachment held with its channels rotated (ARGB8Unorm) raises PrecisionNote::RotatedBlendRounding unless it is exact by construction: a minimum or a maximum, which takes no factor, or a blend whose chosen Vulkan factors are all ZERO or ONE, whose result is the source, the destination, zero, or their sum or difference, a whole code half a code from any tie. rotated_blend's MEASURED table and measured() go; unmeasured() becomes inexact(), which reads the state rotated_blend() chooses: a Synthesized state (SRC1 factors) is inexact, and a Direct one is inexact unless its four factors are ZERO or ONE. Newly announced, the nine states of the old table that are not exact by construction, each Metal's color pair and alpha pair under the one operation: - DestinationColor over Zero, DestinationAlpha over Zero, Add; - SourceColor over OneMinusSourceColor, SourceAlpha over OneMinusSourceAlpha, Add; - BlendAlpha over OneMinusBlendAlpha for both, Add; - the two straight-alpha pairs: SourceAlpha over OneMinusSourceAlpha with the alpha the same, and with the alpha One over OneMinusSourceAlpha, Add; - One over OneMinusSourceAlpha for both, Add and Subtract; - SourceAlpha over One with the alpha Zero over One, Add; - SourceAlpha over One for both, ReverseSubtract. One over Zero and One over One (Add) stay unannounced, now as exact by construction. Newly unannounced: blends outside the old table whose Vulkan factors are all ZERO or ONE, which Metal gives with one Zero or One factor for both its color and alpha sources and one for both its destinations, under Add, Subtract or ReverseSubtract (One over One under ReverseSubtract, Zero over One, and the like). Minimum and maximum stay unannounced. StageIo::rotated_blends and LoweringInputs::rotated_blends stay: they are now the attachments whose blend is not exact by construction. The stage raises the note from the latter, and color_writes::check reads the former to refuse a fragment compiled for another set than the pipeline's (NeedsInput(ColorWrites)), so the set still has a reader; its docs lose "measured". The docs/API.md catalogue entry, PrecisionNote::RotatedBlendRounding's doc, LoweringInputs' and StageIo's docs, rotated_blend's module doc, and validation's c3 deferral doc, its bound string and comparison.rs's allowance doc state the one rule. The validation files use the note to defer a row in C3 (c3.rs) and give it an unbounded allowance (comparison.rs); both follow the note, so more rows on rotated attachments are deferred, by the note alone. Tests: rotated_blend's measured-forms test becomes the_lane_s_blends_store_metal_s_rotated, over the old table kept as test data (LANE): every state stores Metal's blend rotated alike on MoltenVK and lavapipe, and all but one over zero and one over one are inexact. inexact_blends_are_announced adds a difference by ones and a held destination, exact. engine_rotated_colors expects the note on its product and its two second-output blends, and not on its minimum or its reverse subtraction of ones. SEMANTICS_VERSION 2237 (placeholder; main renumbers): the rotated blends' set, which the key carries, and the stage's notes change for the same descriptor. ARTIFACT_FORMAT_VERSION and RUNTIME_VERSION stay. api_signatures, docs/REFUSALS.md and the coverage are unchanged. Consumer check: unmeasured and MEASURED were pub(crate); no public name changes. Verified: m3-max-61259 at this tree (a5396ea291 before the colour commit's message was filled, msi-laptop): fmt, clippy (all features, --cfg m2v_gpu and --cfg m2v_cpu_icd) and Rustdoc rc 0; nextest over metal2vulkan and metal2vulkan-validation, 4719 run, 4718 passed, 23 skipped, 1 failed: the render key test (the_old_render_descriptor_key_keeps_its_value), left unpinned until the next named pin. Rebased onto development |
||
|
|
4d17e4593b |
Colour writes: the Metal colour-write deviations and the premultiplied rotated blend go
DriverDeviation::MetalColorWrites, MetalFloatColorNans, MetalSmallFloatColorWrites and MetalNorm16ColorWrites, with their VkProperty values, were never taken. Device::from_queries enables no Metal* property, and no committed profile carries one. Their forms go: - lower/stage_io/color_write.rs: the Metal conversion (Conversion, conversion()), the skip of a half-float channel on a Metal device, and nan_kept's profile read; - pipeline/color_writes.rs: lowered()'s small-float and 16-bit norm arms, metal_color_writes and metal_stored; - the rotated blend's premultiplied form, which only MetalColorWrites reached: rotated_blend::premultiplied, the measured table's premultiplied factors, RotatedBlendForm::Premultiplied, PlannedOutput::premultiplied and stage_io's premultiplied_blue. RotatedBlendForm kept one variant, Unmeasured, so it goes too. LoweringInputs::rotated_blends and StageIo::rotated_blends become a BTreeSet<u32>: the rotated attachments blended in none of the measured forms. rotated_blend::rotated_form becomes unmeasured(). Notes: RotatedBlendRounding stays, since the unmeasured form raises it; its doc and its docs/API.md catalogue entry lose the premultiplied clause. DeviceColorConversion and DeviceNanEncoding stay, since the device's forms raise them. On Apple's own blend the two straight-alpha pairs may round one code apart in the search's form, unannounced; rotated_blend's module doc says so. Tests: color_writes' tests lose their Metal branches; api_surface's with_color_writes loses its device argument; engine_rotated_colors loses the Apple-blend expectations and premultiplies(); rotated_blend's tests read unmeasured(); engine_fragment's profile filter and api_tests follow. SEMANTICS_VERSION 2236, ARTIFACT_FORMAT_VERSION 575 (placeholders; main renumbers). SEMANTICS: the rotated blends' key bytes change form. ARTIFACT: the codec loses RotatedBlendForm and four VkProperty values, and StageIo's field changes type. RUNTIME_VERSION stays; no binder source changes. api_signatures is blessed; docs/REFUSALS.md is regenerated (DualSourceBlending loses rotated_blend's premultiplied site). Consumer check (consumer-uses.sh, consumer development 415d453172, 58 refs): MetalFloatColorNans, MetalSmallFloatColorWrites, MetalNorm16ColorWrites, RotatedBlendForm and rotated_blends 0 hits (code). MetalColorWrites: 0 on development; used in crates/reims-vgpu-vulkan/src/gpu/encode_render.rs (ties_as_metals) on 36 of the consumer's steelbrain/* branches, a crate its development no longer has. Premultiplied and Unmeasured: the consumer's hits are its own (a comment in display.rs, its RefusedWait::Unmeasured), not these items. Verified: m3-max-61229 at this commit (homelab-um790-xtx-1): fmt, clippy (all features, --cfg m2v_gpu and --cfg m2v_cpu_icd) and Rustdoc rc 0. m3-max-61208 on the same change before its rebase onto |
||
|
|
e149088bd0 |
CLI: --device returns, as the way to compile for a runtime's device
|
||
|
|
d10a14d5af |
Fix forward of b0e351ffbc: the multisample test checks contents its fixture fixes per sample
each_sample_of_a_multisampled_target_holds_its_own_invocation read
samples (2, 3, 2, 3) on lavapipe through the runtime too (focus
m3-max-61748), the same words as the executor's own context. Its
premise was wrong, not either context: sample_rate_mask_in reads
[[sample_mask]] beside [[sample_id]], so the translator compiles it
without sample shading, its body looped over the coverage's set bits,
each written sample taking the last pass's outputs
(PrecisionNote::LoopedSampleOutputs, docs/API.md). Vulkan lets the
device run more than one invocation per pixel there: lavapipe ran two,
over samples {0, 2} and {1, 3}, whose last passes are samples 2 and 3.
Both contexts gave what the note allows; neither gives Metal's per-sample
index, which is the note's recorded difference.
The test is now
each_sample_of_a_multisampled_target_keeps_its_own_contents: one pixel
of 4 samples authored apart (sample s holds 10+s, 20+s, 30+s, 40+s as
RGBA32Float), drawn by sample_rate_mask_out, whose sample mask 0x5
writes (1, 0, 1, 1) to samples 0 and 2. Samples 1 and 3 keep their own
authored words, so the per-sample fill and the per-sample read-back are
both checked, through the runtime on Linux and on the executor's own
context, against one expected byte string. The fixture's output carries
no precision note.
Verified: cargo fmt. The focused run follows as a potluck job.
|
||
|
|
20622957ce |
Fix forward of ec7d482ed0: the multisampled fill takes no error map it no longer uses
|
||
|
|
ec7d482ed0 |
Validation: a multisampled color fill's view takes a texture index
The family H commit ("multisampled passes and textures run through the
runtime") gated red (m3-max-61599) in three ways.
- Its fill made the unsigned-integer view of a multisampled color
texture at no texture index. The runtime gives a view an index exactly
where shaders reach it, as Device::new_texture does, and a view of a
color render target that shaders read is reached
(Refusal::TextureIndex, "takes an index, and none was given"). Every
multisampled color fill failed:
depth_and_multisampled_textures_read_their_authored_texels at the
fill. The view is now made once at an index of the run's grant
(runtime_multisample::color_view). The fill renders through it and the
read-back reads it, so Fill carries the view and read_back takes it in
place of an index. A pass's color target takes its view's index as
before, and a bound multisampled color texture now takes one beside its
own (runtime_textures counts them into the grant).
- Clippy: a manual is_multiple_of in runtime_multisample.rs, and two
chunks_exact(4) of a constant size in the test, now as_chunks.
- each_sample_of_a_multisampled_target_holds_its_own_invocation's
check on the executor's own context read samples (2, 3, 2, 3) on
lavapipe where Metal's row holds (0, 1, 2, 3). That path is not this
commit's. The test now checks the runtime first, then the executor's
own context, each against Metal's answer, so a red names its context.
The depth/stencil attachment of one sample takes no index, as the fix
forward of family G made it, and a multisampled one keeps its index:
a kernel reads it back.
Verified: cargo fmt. The gate and a focused run of the multisample tests
follow as potluck jobs.
|
||
|
|
b0e351ffbc |
Validation: multisampled passes and textures run through the runtime
Family H of the executor's move onto metal2vulkan-runtime: a render case of more samples (raster_sample_count), and any case binding a multisampled texture, now runs on the runtime's public API, filled and read back as executor_contract::multisample states for both executors. Metal uploads and copies no multisampled texture, and neither does the runtime. So runtime_multisample fills each slice with one draw of the owned sample_fill fixture (fixtures/public/engine/sample_fill.metal, compiled by scripts/regen-air-fixtures), whose fragment runs once per sample (sample_id) and writes that sample's texel from a buffer: a color texel through an unsigned-integer view of its texel size (the texture made with PixelFormatView usage), so its bits cross unconverted, a Depth32Float one as depth(any) under an always-passing depth test that writes (a depth outside [0, 1] refused as depth_outside_unit_range, as runtime_depth refuses it). A multisampled stencil aspect holds one value in every sample (uniform_stencil), which the case's pass clears it to. After the draw a dispatch of the fixture's sample_read kernels reads every sample, one threadgroup each, as whole words in the attachment layout (unpack_words), unresolved, as the oracle's sample_readback does. runtime_textures makes a multisampled texture Private (Metal keeps none Shared), for rendering and, if color, for views of another format, and fills it by those draws. runtime_render makes each attachment of a multisampled pass a Private Type2DMultisample texture of the pass's samples, with a texture index for its read's view, and reads every sample back for the comparison. engine::runtime_texture no longer keeps a multisampled texture off the runtime, and runs_render_through_runtime takes any sample count. An attachment of both aspects still carries separate_depth_stencil. What moves: of the committed cases, 49 multisampled passes (all public; 2 with both aspects keep the requirement) and 8 cases with a multisampled input texture (7 public kernel cases, 1 private fragment case). ENGINE_EXECUTOR_ABI to vulkan-engine-v197. The new owned fixture adds rows to the golden tables, re-blessed on development. Tests: engine/tests.rs routes a multisampled pass, multisampled depth and stencil attachments and a kernel's multisampled texture through the runtime; engine_render.rs's each_sample_of_a_multisampled_target_holds_its_own_invocation draws sample_rate_mask_in into 4 samples and checks each sample's index, on Linux through the runtime too, bytes equal to the executor's own; engine_textures.rs's depth_and_multisampled_textures_read_their_authored_texels runs through the runtime on Linux. Built and run in the lane's compile job (ids sent with the sha); not yet built when committed. |
||
|
|
6593e998d1 |
Validation: tessellation cases draw their patches through the runtime
Family I of the executor's move onto metal2vulkan-runtime. A post-tessellation vertex case's patch draw, which the Metal oracle encodes as setTessellationFactorBuffer: at executor_contract:: tessellation's offset and instance stride and drawPatches: with no patch index buffer, now draws through the runtime's public API the same way: the factors a Shared buffer bound by set_tessellation_factor_buffer at FACTOR_OFFSET and FACTOR_INSTANCE_STRIDE, then draw_patches with the case's control points, patch start, patch count, instance count and base instance and no index buffer. engine::runs_render_through_runtime takes an Assembly::Patches case whose draw is DrawCall::Patches with neither a patch index buffer nor a control-point index buffer (the runtime's patch index buffer is Gap::Draw of PatchIndexBuffer); the authored TessellationDraw spells neither, so every committed tessellation case meets the structure. runtime_render's drawn() encodes the patch draw; a patch draw that reached it with an index buffer fails the run, never draws other patches. What moves: the 25 committed tessellation cases (23 public, 2 private), one of them with attribute-buffer out-of-bounds targets of control-point form, whose facts runtime_bounds::drawn reads as before. ENGINE_EXECUTOR_ABI to vulkan-engine-v196: these rows' executor changes. Tests: engine/tests.rs a_plain_draw_and_only_one_runs_through_the_runtime routes a patch draw without an index buffer and keeps one through a patch index buffer, and a patch draw of a primitive assembly, on the executor's own context; engine_render.rs's a_back_culled_patch_and_its_mirror_leave_exactly_one_drawn draws each of its patch draws through the runtime on Linux and compares the executor's own bytes. Built and run in the lane's compile job (ids sent with the sha); not yet built when committed. |
||
|
|
36e763e80e |
rt README: the Iris Xe lays a linear image's rows at the row itself
The known gap on textures over buffers named NVIDIA's (128 bytes) and AMD's (256) linear row rounding. bugcheck measured the Iris Xe (ms01, ANV, not exclusive): a raw LINEAR R8G8B8A8_UNORM image of SAMPLED|STORAGE has rowPitch 9792 at 2448x3264 and 15536 at 3884x2576, the row itself (m3-max-61686), and the runtime's own linear image, under each usage the answer tries (read, read+render target, read+write), pitches at the row at every width from 1 to 8192 (m3-max-61688), so minimum_linear_texture_alignment(RGBA8Unorm) answers 4 there. A pitch rounded past the row is copied on that device; the sentence says so. Doc only. |
||
|
|
06a35ed9e4 |
CLI: the device file a runtime repro bundle held is gone; a bundle holds the profile
`metal2vulkan --device <device.json>` read a ReproDevice (a device description and policy), the device file a runtime's FALLBACK bundle would hold, and repro.rs said "a runtime may write one for a library or pipeline creation it refuses". No runtime writes one: metal2vulkan-runtime has no repro or env_vars use and reads no METAL2VULKAN_* variable (git grep at |
||
|
|
d6d56b8a7c |
rt test: a state without an attribute only a gated-off varying reads is made and draws
What: every_device_makes_and_draws_a_state_without_an_attribute_only_a_gated_off_varying_reads.
The owned fixture engine/fca_vertex_unread_attribute with has_color false, a vertex descriptor
of attribute 0 alone, one draw covering the target: the state is made through the runtime, with
no VertexAttribute { attribute: 1 } refusal, and every texel is the fragment function's shade,
(64, 128, 191, 255) within one code.
Why: a guest's 3D file preview drew magenta because a pipeline was refused
InvalidDescriptor(VertexAttribute { attribute: 1 }) where Metal's specialized vertex function
marks the attribute inactive. The translator fix (
|
||
|
|
3ddbc85f73 |
Golden table: it records its bless's SEMANTICS_VERSION, and a cell changed under its key at that number is a missing bump
What: golden_hashes.tsv gains a `semantics` line, cache::SEMANTICS_VERSION as it was at the
table's bless (2234, the bless at
|
||
|
|
bcc417bc08 |
Translator: SparseResidency's text names a footprint of the border alone
PrecisionNote::SparseResidency said the device's OpImageSparse* residency may count a texel of zero weight Metal does not. Public case fd292944c2 (a 256x128 r32_float sparse texture with x 128-255 mapped) found a second way the device's word differs: lavapipe answers not resident for a clamp_to_border access whose footprint is the border alone (nearest at u -0.5 and 1.5, linear at u -0.5, -1/256 and -1/512, gather at u -0.5 and 1.5), where Metal answers resident, beside a mapped edge too. Every value word was equal; 7 of 200 residency words differ (valexec2's proof m3-max-61595, decoded against the committed Metal rows). Vulkan states only "whether any texels accessed by the instruction are sparse unbound texels" (vkspec 20.2.6), so the word is the device's, which the note's first clause already says; its text now names this case beside the zero-weight texel, in the doc comment and in docs/API.md's catalogue. Doc only: no emission, key or version change. |
||
|
|
55e5dcfd98 |
Fix forward of 4e3a6a3555: the translator's floor tests take shaderOutputLayer as the floor's
|
||
|
|
f3418eacb9 |
rt: shaderResourceMinLod is enabled where the device reports it
A sample's min_lod_clamp other than 0 has one form in the translator, SPIR-V's MinLod image operand, which needs shaderResourceMinLod; without it the translator refuses the function (Feature::MinLodClamp). rt enabled the feature on no device, so every such function was refused at creation. floor: MIN_LOD_CLAMPS holds shaderResourceMinLod, in the step rates' shape: device creation enables it where the device reports it, the translator's profile gets it through shader_enables, and a device without it keeps the typed refusal. No answer chooses a second form. Venues (vulkaninfo): every dumped venue reports it but the UHD 630's Windows driver (m3-max-48736): RADV on the RX 7900 XTX, the three 780Ms and the RX 550, NVIDIA's driver on the RTX 2080, RTX 3090 and RTX 5080 Laptop, ANV on the Iris Xe, lavapipe and KosmicKrisp on the M3 Max (m3-max-48727 to 48731, 48737 and 61508). Docs: the runtime README's Min-LOD clamps section with its feature table, and the render pipeline states' known gap for a device without it. docs/REFUSALS.md regenerated: no change (the refusal is the translator's and did not move). Tests: floor's host test the_min_lod_clamp_is_enabled_where_reported (unreported, reported), the README tables, and the device test min_lod.rs: engine sampling's sample_min_lod draws over a 16-texel texture of five levels, one colour each, under a linear mip filter; its derivatives make the level of detail 0, so the clamp of 1.5 alone makes every pixel read levels 1 and 2 half and half (green and blue within two codes of 128), or the state is refused naming MinLodClamp where the profile lacks the feature. |
||
|
|
2977599dab |
rt: the missing-feature test's array holds its 54 cases
The case added for depthBiasClamp (the commit before last) made 54 cases in an array declared of 53, so the runtime's lib test did not compile (E0308 at tests/floor.rs:373, suite m3-max-61653 on msi). The declared length is 54, REQUIRED's count. Verified by the rerun, named in the report. |
||
|
|
d6d7d43f7f |
Validation: the runtime-floor contexts' opened chains with depthBiasClamp
The runtime-floor profile states depthBiasClamp (the commit before), and validation's enables open it where a profile states it, so each of the profile's four contexts enables one member more (42 to 43, 40 to 41, 50 to 51, 47 to 48); every other profile's chains are unchanged. Verified: bless_opened_chains at 50ace64a2d, job m3-max-61650 (msi), rewrote exactly these four lines. |
||
|
|
a529fb658e |
rt: the floor's depthBiasClamp has its missing-feature case, and the runtime-floor profile states it
The floor requires depthBiasClamp (the first commit of this change). The runtime's each_missing_feature_is_named gains its case, as its count of cases is held to REQUIRED's. The regeneration's RUNTIME_FLOOR and runtime-floor.json's m2v_runtime_floor block state it, in the generator's order (the block the runtime's the_floor_profile_states_exactly_the_floor holds equal to floor.rs; check_device_profiles: 0 findings over 17 profiles; the JSON line is written as the regeneration writes it, without refetching its pinned sources). CONFORMANCE-COVERAGE is regenerated for the ledger row render-state-depth-bias left (7688 rows to 7687). The runtime-floor contexts' opened chains move with the profile; their bless is the next commit. Verified: suite m3-max-61635 at 406f39dc90 (msi; the workspace suite and the lavapipe device tests) failed exactly these three, each_missing_feature_is_named (52 cases against 53), the_floor_profile_states_exactly_the_floor (depthBiasClamp) and the coverage document; the rerun follows. |
||
|
|
7dc3840095 |
conformance: the device's depth bias is among the suite's native notes
render-state-depth-bias compares on rt now that a clamp is built. On the RTX 3090 every value matched Metal's recording, and the case was divergent at the notices site alone (m3-max-61583): its biased draws announce metal2vulkan-degrade-device-depth-bias (RenderCommandEncoder::DEPTH_BIAS_NOTE), which no case declares. The note is the device's own answer, its slope measure and unit, the class replay::NATIVE_NOTES holds for every case (owner rule 1), so it joins that list; it loosens no value, and the case's depths still compare field by field. |
||
|
|
84821b1f00 |
rt: the floor test's device at the floor reports depthBiasClamp
depthBiasClamp joined REQUIRED in the commit before; at_the_floor, the device every floor host test starts from, sets each required feature by hand, so without it every such test met a device below the floor. |
||
|
|
6ef64ae3ee |
rt: a depth bias's clamp is the device's own
setDepthBias:slopeScale:clamp: bounds the bias by its clamp: "Pass a positive or negative value to limit the largest magnitude of a positive or negative bias, respectively. You can disable the bias clamping functionality by passing 0.0" (Apple's page for the method, as fetched). Vulkan's depthBiasClamp is the same bound (dbclamp: x for 0, min(x, clamp) above 0, max(x, clamp) below). rt refused every clamp but 0 (DrawKind::DepthBiasClamp), where the deleted runtime passed it. floor: depthBiasClamp joins REQUIRED. Every dumped venue reports it (vulkaninfo m3-max-48727 to 48731, 48736, 48737 and 61508 for the RX 550: RX 7900 XTX, the three 780Ms, RTX 2080, RTX 3090, Iris Xe, RTX 5080 Laptop, llvmpipe, the UHD 630's Windows driver, KosmicKrisp on the M3 Max, RX 550), and Vulkan 1.4 and Roadmap 2022 require it. render encoder: set_depth_bias keeps the clamp beside the bias and slope scale and records it in vkCmdSetDepthBias, as dynamic state (no pipeline). It returns nothing now, as Metal's call does: its only error was the clamp. DrawKind::DepthBiasClamp is deleted. The consumer's checkout names both: rt_platform/render.rs:380 (`e.set_depth_bias(...)?`) and rt_platform/unbuilt.rs:873 (a test's sample refusal of DepthBiasClamp); each needs a one-line change at its next pin. AGENTS.md: the Scope sentence on features no guest has used is replaced with the planner's wording: a feature a program can ask about is answered from the Vulkan query; one Metal gives every Mac device with no way to ask is built, a typed refusal in the known gaps until it is. Docs: the README's floor table, its depth bias paragraph and its render encoder known gaps; docs/REFUSALS.md regenerated (Draw's basis and sites); api_signatures.tsv blessed (the setter's signature, the variant gone). The conformance ledger drops render-state-depth-bias's refusal row. Tests: every_device_tests_writes_and_biases_a_depth_attachment's first draw is biased by 2^23 (0.25 or 0.125 in the device's unit at depth 0.25) clamped to 0.0625, and the depth read back is 0.3125 on every device; the later draws' answers are unchanged in kind. The conformance case render-state-depth-bias (a slope-scaled bias under the clamp -0.0125) now compares against Metal's recording. |
||
|
|
5a7c262577 |
Fix forward of 6af76cf309 and 1d16171943: the tests of both aspects and of a ulong row take the runtime's limits
The compile gate of the lane (m3-max-61592) failed five validation tests that these two commits left stale. SeparateDepthStencil ( |
||
|
|
e7c92ed005 |
Fix forward of cca476549f: a one-sample depth/stencil attachment takes no texture index
Family G made a one-sample depth or stencil attachment through the
runtime at a texture index of the run's grant. The runtime gives an index
exactly where shaders reach a texture (Device::new_texture): a depth or
stencil target of RenderTarget usage alone is not reached, and an index
given to one is refused (Refusal::TextureIndex, "a texture no shader
reaches takes no index"). Every routed case with such an attachment
failed at the make: public c5749a970e (match before) and one private
case (mismatch before) in the family G proofs (m3-max-61598, 61611). The
attachment is now made at no index, and the grant counts the color
targets alone.
Correction of cca476549f's message. It expected 18 one-aspect cases to
run through the runtime. 2 do, the depth-only ones. The 16 stencil-only
cases' fragment functions all write [[stencil]], which the runtime
refuses at creation (its README's known gaps of render pipeline states,
"a fragment function's stencil output"), so they are recorded as
not_supported{device_capability_missing:StencilExport}.
The device test a_fragment_case_writes_its_depth_and_stencil_attachment
drew both aspects through the runtime under fragment_depth_stencil,
whose stencil output the runtime refuses, and so could not pass on
Linux. Its runtime arm now draws each aspect alone as the executor's own
context draws it: depth under sample_rate_depth (0.125 at one sample) and
stencil under fragment_no_writes (the state's reference replaces it),
equal to the executor's own run. It also checks that
fragment_depth_stencil through the runtime is a typed StencilExport
refusal. Without the fix, both drawn arms fail at the make.
Verified: cargo fmt. The compile gate and the device test on lavapipe
follow as potluck jobs.
|
||
|
|
6af76cf309 |
Validation: separate depth and stencil attachments are the runtime's limit
A fragment case whose depth/stencil attachment holds both aspects is
drawn by the Metal oracle into Metal's separate Depth32Float and
Stencil8 textures, attached to one pass: plain Metal on every Mac. The
runtime does not build that form yet. It renders into no separate depth
and stencil textures in one pass (Gap::RenderPass of DepthStencilViews,
and its pipeline state Gap::RenderPipeline of DepthStencilFormats), both
among the known gaps its README states. The planner's ruling: record
these rows as the runtime's limit with that typed gap, by the
function-table mechanism; the doc comment states the gap as unbuilt in
the runtime, not as Metal's.
ToolingRequirement::SeparateDepthStencil ("separate_depth_stencil"):
Limit::Runtime, it stops the engine's candidate and keeps its cases
Metal-qualified (qualifies_on_metal). The case checker raises it from
the case's literals (executor_contract::case_requirements: a vertex or
fragment case's depth/stencil attachment with both initial aspects),
never from a source's structure, so no census row carries it.
executor_contract.rs is a classifier input, so every cached triage
recomputes. If the runtime builds the form, the requirement goes in the
same commit.
What lost execution: of the committed cases, 5 fragment cases hold
both aspects: the 3 of family G (one sample, observing stencil) and 2
multisampled ones (family H), all of which ran on the old executor
until now.
Tests: requirement.rs's
a_separate_depth_stencil_attachment_stops_only_the_candidate and both
requirement lists; executor_contract's case test (a fragment case's
attachment of one aspect raises nothing, of both raises it alone).
Verified: cargo fmt; the compile gate follows as a potluck job.
|
||
|
|
cca476549f |
Validation: a draw's depth/stencil attachment of one aspect runs through the runtime
Family G. A render case with a depth/stencil attachment stayed on the executor's own context. A vertex or fragment case whose attachment has one sample and one aspect now draws through the runtime (engine::runs_render_through_runtime), observing a buffer, a texture, a color target, the attachment's aspect or nothing; a fragment case with the attachment and no color target renders, as the attachment is the pass's. The attachment is made as the oracle makes it (Metal's separate Depth32Float and Stencil8, Shared, of RenderTarget usage): - a Depth32Float is filled by a draw of its depths (runtime_depth), as a 32-bit float depth texture is, since the runtime takes no upload of one (Gap::FloatDepthUpload); a depth outside [0, 1] stays DepthOutsideUnitRange; - a Stencil8 is written from its bytes with replace_region. The pass loads and stores it; the draw's depth-stencil state, stencil references and pipeline depth and stencil formats were already the oracle's. The final aspect is read back with get_bytes into the run's RenderFinals, from which the depth or stencil output is selected. An attachment of both aspects is the oracle's two textures, which the runtime renders into in no one pass (Gap::RenderPass of DepthStencilViews; its pipeline Gap::RenderPipeline of DepthStencilFormats): such a case, and one of more samples (family H), stays on the executor's own context. Rows: of the committed cases, 21 fragment cases are family G's (one sample, the rest of E/F's structure): 16 stencil-only observing stencil, 2 depth-only (one observing depth, one, private, a color target), and 3 of both aspects observing stencil, which stay where they were. Expected: the 18 one-aspect cases run through the runtime; the family G proof reads them. ENGINE_EXECUTOR_ABI to vulkan-engine-v195. Tests: a_plain_draw_and_only_one_runs_through_the_runtime (a depth or a stencil attachment, observed or not, routes; one of both aspects or of 4 samples does not); the device test a_fragment_case_writes_its_depth_and_stencil_attachment draws each aspect alone through the runtime on Linux (depth 0.5 over 1.0, stencil 7 over 0xab). Verified: cargo fmt; the compile gate and the family G proof follow as potluck jobs. |
||
|
|
1d16171943 |
Validation: a 64-bit texture atomic is the runtime's limit
The translator lowers an atomic_min or atomic_max on a Metal ulong
texture to a 64-bit image atomic, which needs shaderImageInt64Atomics.
The runtime's floor enables no 64-bit image atomic on any device
(floor::Features has no such structure, and shader_enables tells the
translator only of the floor's features), so a pipeline that calls one
is Error::Translation of Unsupported{ImageAtomics} on every device.
Metal's feature set tables give the form to the Apple8 family and later
("GPU devices in the Apple8 family support 64-bit atomic minimum and
maximum using ulong, on both buffers and textures, only on macOS"). The
planner's ruling: the consumer's device claims no Apple family on any
host, so no guest following documented Metal reaches the form, as with
render function tables; the rows close as the runtime's limit with their
typed refusal, by the mechanism of the fence and function-table rows. It
re-opens if the consumer's family claim gains every Apple7 piece and
this is what holds Apple8 back, or when a guest meets it in a walk. The
requirement's doc comment and the README's gap line state the feature
set tables' basis.
Cherry-picked from cf3b11c0a8 (steelbrain/valexec2-ulong) onto
|
||
|
|
9a28de4736 |
Validation: an indexed draw past its index buffer is the runtime's limit
The runtime refuses an indexed draw whose indices leave its index buffer
as Refusal::IndexBufferOffset, as Metal's validation stops the draw
(render_encoder's draw path checks offset + count * size against the
buffer's length; the runtime's README states the refusal among those
Metal's validation makes). A case that declares a draw's index buffer an
out-of-bounds target is such a draw, so no run through the runtime draws
it. The planner's ruling: record these rows as the runtime's limit with
that typed refusal, by the function-table precedent.
ToolingRequirement::IndexBufferPastEnd ("index_buffer_past_end"):
Limit::Runtime, it stops the engine's candidate and keeps its cases
Metal-qualified (qualifies_on_metal). The case checker raises it from the
case's literals (executor_contract::case_requirements: an out-of-bounds
target of OutOfBoundsResource::IndexBuffer), never from a source's
structure, so no census row carries it. executor_contract.rs is a
classifier input, so every cached triage recomputes.
What lost execution: of the committed cases, the 2 public index-buffer
cases d900a10225 and da4185d2a2, which ran on the old executor's padded
copy until now. The old executor's padded index copy is now reached by
no committed case; it goes with the old executor's tables.
Tests: requirement.rs's an_index_buffer_past_its_end_stops_only_the_candidate
and both requirement lists; executor_contract's case test (a vertex
case's index-buffer target raises it alone, an attribute-buffer target
raises nothing).
Verified: cargo fmt; the compile gate follows as a potluck job.
|
||
|
|
67b55af6ff |
Fix forward of 00e254ac29: the identity-domain containment test borrows what it builds
Gate m3-max-61407 at 34d8eb4826 (an earlier form of
|
||
|
|
4e465d811a |
Validation: a draw's attribute-buffer out-of-bounds target runs through the runtime
A render case with an out-of-bounds target stayed on the executor's own
context. A vertex or fragment case whose every out-of-bounds target is
an attribute buffer now draws through the runtime
(engine::runs_render_through_runtime), and its facts are read before the
state is made (runtime_bounds::drawn): the translator's compile of the
state's descriptor on the runtime device's own translator
(Device::compile_render_pipeline, whose stage inputs are the ones the
runtime lowers each stage under, render_pipeline_key of the variant key
its state takes), read by engine::draw_out_of_bounds_run, which now takes
the translator Device for its policy.
The runtime's floor enables no buffer robustness: its README states that
a vertex fetch outside its buffer returns what the device gives. So
fixed-function vertex input on a profile without buffer robustness is
contained as vertex-input:unchecked (Check::Unchecked; it was an Err,
"which contains nothing"), and the case is refused before the make as
not_supported{uncontained:unchecked vertex_input}. A contained target of
such a draw would need guards around its vertex buffers, which the draw
does not place, so it is refused as executor_not_implemented; no routed
case reaches that.
Rows: of the 4 render out-of-bounds cases, 01b45f7c10 (a vertex
attribute fetched past its vertex buffer) is expected to move from the
old executor to not_supported{uncontained:unchecked vertex_input}. The 2
index-buffer cases (d900a10225, da4185d2a2) stay on the executor's own
context: the runtime refuses indices past the buffer
(Refusal::IndexBufferOffset), as Metal's validation does, which the
facts do not state yet. The control-point case a95f41be73 is a
tessellation draw, which stays there too. On the old executor, the
robustness-off leg's fixed-function attribute target is now the same
refusal instead of a failure.
ENGINE_EXECUTOR_ABI to vulkan-engine-v194.
Tests: a_draws_targets_are_contained_by_their_fetch (every committed
profile contains the fixed-function attribute, unchecked exactly where it
checks buffers in the shader, which a committed profile does);
a_plain_draw_and_only_one_runs_through_the_runtime (an attribute target
routes, an index-buffer target does not).
Verified: cargo fmt; the compile gate and the family D proof follow as
potluck jobs.
|
||
|
|
00e254ac29 |
validation: an out-of-bounds target is contained as its module's domains decide
containment read a module's facts as if every device took the resident
table and the handle table. The runtime's device takes the identity
domains (DevicePolicy), so a kernel case through the runtime whose target
is a buffer an argument buffer points to, or an argument buffer's texture
array, failed: the module has no resident roots and no handle table.
ModuleFacts now carries the policy of the device the module was compiled
for (Device::policy: the runtime's translator, the executor's own device,
and DevicePolicy::default() for the committed tier profiles, which are
made with it).
- Under the identity pointer domain a pointer loaded from memory is the
address it holds, used as given: the runtime's README states that an
access through a pointer loaded from memory is not checked. Such a
target is contained as device-address with the new Check::Unchecked,
and out_of_bounds_run refuses every case with an unchecked target
before the make, as NotSupported::Uncontained with the new `unchecked`
forms (serde default):
not_supported{uncontained:unchecked loaded_pointer}.
- Under the identity handle domain an argument buffer's texture-array
index is the resource id's index masked onto the descriptor arrays
(the new Medium::ResourceId, resource-id:shader), whose elements no
live texture owns are null descriptors: its read rule is
ResidentTexels, as the handle table's.
ENGINE_EXECUTOR_ABI to vulkan-engine-v193.
Rows: the family D proof at
|
||
|
|
2e4495e8ae |
Fix forward of 47f804e943: the rt variant test reads each placement's fields
A stage's PushPlacement lists its fields (PlacedField); the test read a field of the placement itself (E0609 under --cfg m2v_gpu and m2v_cpu_icd in gate m3-max-61250). Verified: cargo fmt; the gate follows. |
||
|
|
fc168d0173 |
Validation: a render function's visible function table is the runtime's limit
The runtime's render pipeline state reads no function table: its make refuses a vertex or
fragment function that calls through one as Gap::RenderPipeline{DrawInput}, a known gap its
README states. Function pointers from a render pipeline are an Apple6-family feature, which Metal
lets a program ask for through supportsFunctionPointersFromRender; the planner's ruling is that
the consumer's device answers no to it and to supportsFunctionPointers, so the refusal is Metal's
own and the rows close as the runtime's limit with their typed refusal, by the mechanism of the
fence and mesh rows.
ToolingRequirement::RenderFunctionTable ("render_function_table"): Limit::Runtime, it stops the
engine's candidate and keeps its cases Metal-qualified (qualifies_on_metal). It is raised from the
source's structure, a vertex, post-tessellation vertex or fragment function's
visible-function-table argument (executor_contract::engine_source_requirements), and from a
vertex or fragment case's bound function table (case_requirements). executor_contract.rs is a
classifier input, so every cached triage recomputes.
What lost execution: of the committed cases, 22 vertex cases bind a function table, all with
private sources and none public: the 2 of family E/F's private selection that failed through
the runtime (vertex.function_tables, DrawInput), and 20 that ran on the old executor. No
fragment case binds one; a kernel's still runs.
Tests: requirement.rs's a_render_function_table_stops_only_the_candidate and both requirement
lists; executor_contract's source test (a vertex function's visible_function_table argument
raises it, a kernel's or a mesh function's does not) and case test (a vertex or fragment case's
table raises it, a kernel case's does not).
Verified: cargo fmt; the compile gate follows as a potluck job.
|
||
|
|
34c8f0e67c |
Validation: a kernel out-of-bounds case runs through the runtime, its facts every lowered variant's
A kernel case with out-of-bounds targets now routes through the runtime like any other kernel
case of its structure (engine::runs_through_runtime no longer excludes one). Before the state is
made, platform::runtime_bounds lowers each KernelVariant of the case's kernel on the runtime
device's own translator (rt::Device::translator), under LoweringInputs::kernel_variant of the
inputs kernel_inputs_read gives the descriptor's: the inputs the state lowers each of its modules
under, which the runtime's own test pins. A variant the translator refuses is one no dispatch runs.
Each lowered module's facts (its slots, fetches, resident roots, handle table and strategy
census) give the run's out-of-bounds facts through engine::out_of_bounds_run, as the executor's
own context reads its module's. Where two variants give different facts, which module a dispatch
runs would decide the case, so it is refused before anything is made:
NotSupported::Uncontained now carries the variant that differs (None for the device's robust
forms, as before), "not_supported{uncontained:variant PartialThreadgroups}".
Each guarded target (a buffer, or an argument buffer's) is a buffer at the runtime's placement
alignment inside a Shared block of its own, between guards of its declared reach (at least
MIN_GUARD), every guard byte GUARD_FILL, read back through a buffer over the whole block after
the dispatch: GuardCount::escaped, and past_end 0 (the buffer is all its bound memory). The
row's census records the facts with the counts.
Texture-buffer cases stay on the executor's own context (the runtime makes no texture buffer),
and so do the render out-of-bounds cases (vertex fetches); stage inputs do not route.
Tests: the routing test asserts an out-of-bounds kernel case routes; the device test
a_device_buffer_accessed_past_its_end_is_contained_through_the_runtime runs the public
ob1_storage_buffer case through the runtime (loads past the source read zero, stores past the
output do nothing, no guard byte changes, each target DeviceAddress / Shader). ENGINE_EXECUTOR_ABI
vulkan-engine-v192. docs/VALIDATION.md says how the facts are read.
Verified: cargo fmt; the compile gate and lavapipe suites, then the family's proof, follow as
potluck jobs.
|
||
|
|
47f804e943 |
Translator: a kernel variant's lowering inputs come from LoweringInputs::kernel_variant; rt answers its translator
rt's kernel state lowered its partial-threadgroups and emulated-SIMD-group variants under inputs it assembled by hand: a clone of the plain module's inputs with one flag set. Validation's executor is to lower the same variants on the same device to read each module's containment of an out-of-bounds target, so the assembly moves into the translator as the one constructor both call: KernelVariant (Plain, PartialThreadgroups, EmulatedSimdgroups; ALL) and LoweringInputs::kernel_variant, applied to the inputs kernel_inputs_read gives. rt's Compiled::of and its translate tests' helpers call it. metal2vulkan-runtime's Device::translator returns the translator device creation built, the one every state lowers on. It retains nothing new (it borrows Core::translator) and has no Metal counterpart. One rt device test pins the agreement: for icb_replay_grid_template (its plain module checks the store at a computed index, SlotBounds of buffer 1, and leaves the two constant-offset loads of buffer 0 unchecked) and gsm2_simd_products' simd_float_products, every lowering a first device kept in its cache directory is found under the key of one variant's public inputs, byte-equal to Device::translator's compile_function of that variant, and at least as many are found as the states made modules. Surface: api_surface names KernelVariant (N); api_signatures blessed (8 records added, none changed or removed); docs/API.md and the runtime README's compute-state section say how a consumer lowers a variant. No public item is removed, so no consumer search applies. Verified: cargo fmt; the compile gate and the runtime's device tests on lavapipe follow as a potluck job. |
||
|
|
0dc56519c9 |
translator: the identity domains push a render pass's length to a vertex function that writes its slice
Under the identity domains a vertex function that writes [[render_target_array_index]] was refused as IdentityDomains (an encoder value the function reads as RenderTargetArrayLength): the field was not among the encoder values those domains push. The runtime now fills it (the pass's length, at least 1, rt's FieldValue::RenderTargetArrayLength), so the field joins the admitted pushed values, beside AlphaTestReference and FetchedColor; nothing else of the form changes. Found by the runtime's layered device test, which refused rt6_layered on every GPU leg at 912548d4db (m3-max-61476, 61477, 61478, 61480, 61481, 61486, 61490) and on lavapipe (61482). SEMANTICS_VERSION 2235, one above development's 2234 (placeholder): such a vertex function now compiles where it was refused. lower/select.rs and cache/mod.rs are not among validation's runtime inputs, so runtime-sources.sha256 and RUNTIME_VERSION stay. A test pins the form on lavapipe's profile (engine_identity_render), and docs/API.md names the pushed length. |
||
|
|
aba05588dd |
rt: the runtime floor's opened chains with shaderOutputLayer, and the README's uniform index
The runtime-floor profile's four contexts each enable one more member, shaderOutputLayer (bless_opened_chains at feea4e88ac, job m3-max-61470; the other profiles' chains are unchanged). The README's layered-rendering gap line states which indices the translator shows the same at every vertex of a primitive (StageIo::uniform_outputs): constant memory and the draw's instance, never a per-vertex input, and that the vertex-function refusal is at creation, whatever pass. |