diff --git a/crates/metal2vulkan-runtime/src/error.rs b/crates/metal2vulkan-runtime/src/error.rs index d695bddce..fb3a0569d 100644 --- a/crates/metal2vulkan-runtime/src/error.rs +++ b/crates/metal2vulkan-runtime/src/error.rs @@ -1090,7 +1090,13 @@ pub enum Refusal { /// slice, or the last of the slices a layered pass renders from it /// (`renderTargetArrayLength`); or a 3D texture's depth plane past its level's depth. /// - /// Basis: ours (no texel of the texture is there to render into). + /// Basis: metal-measured (an Apple M3 Max, macOS 27.0.1, probe `resolve_depth_planes.m` in the + /// conformance crate, job m3-max-73495: Metal's validation layer ends the process at the + /// encoder for a resolve into slice 3 of a 2D texture, `Slice is 3, but the texture has only 1 + /// slices`, and for a resolve at depth plane 3 of one, `depth plane is 3, but the texture has + /// a depth of 1 at mip level 0`; with the layer off, plain Metal writes slice and plane 0 + /// instead. A level past the texture's was not run: that part is ours, as no texel of the + /// texture is there to render into). AttachmentPlace { /// The level asked for. level: u32, diff --git a/crates/metal2vulkan-runtime/src/error/basis.rs b/crates/metal2vulkan-runtime/src/error/basis.rs index 29c85575e..e67d15b4c 100644 --- a/crates/metal2vulkan-runtime/src/error/basis.rs +++ b/crates/metal2vulkan-runtime/src/error/basis.rs @@ -88,7 +88,7 @@ impl Refusal { Refusal::AttachmentUsage { .. } => RefusalBasis::MetalDocumented, Refusal::ResolveTexture => RefusalBasis::MetalDocumented, Refusal::ResolveFormat { .. } => RefusalBasis::MetalDocumented, - Refusal::AttachmentPlace { .. } => RefusalBasis::Ours, + Refusal::AttachmentPlace { .. } => RefusalBasis::MetalMeasured, Refusal::AttachmentFormat { .. } => RefusalBasis::MetalDocumented, Refusal::NoAttachmentPass { .. } => RefusalBasis::MetalMeasured, Refusal::SamplePositions { .. } => RefusalBasis::MetalDocumented, diff --git a/docs/REFUSALS.md b/docs/REFUSALS.md index ae3dda6bd..2d528d7f1 100644 --- a/docs/REFUSALS.md +++ b/docs/REFUSALS.md @@ -44,7 +44,7 @@ Columns: | Rate maps the compile layer does not compile | 0 | 0 | 0 | 0 | 5 | 0 | 0 | 0 | | The translation deadline | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | | Devices below the runtime's floor | 0 | 0 | 0 | 8 | 0 | 0 | 0 | 0 | -| The runtime's `Refusal` | 30 | 27 | 0 | 0 | 39 | 0 | 0 | 0 | +| The runtime's `Refusal` | 31 | 27 | 0 | 0 | 38 | 0 | 0 | 0 | | The runtime's `Limit` | 0 | 0 | 0 | 15 | 6 | 0 | 0 | 0 | | The runtime's `Gap` | 0 | 0 | 0 | 2 | 29 | 0 | 0 | 0 | @@ -306,7 +306,7 @@ Columns: | `AttachmentUsage` | A render pass attachment (`CommandBuffer::render_command_encoder`) whose texture was made without `RenderTarget` usage | every device (a public call's own check of its arguments) | `metal-documented`: a texture a render pass renders into needs `MTLTextureUsageRenderTarget`; Metal's validation stops the descriptor | 1: `crates/metal2vulkan-runtime/src/texture.rs (attachment)` | `-` | | `ResolveTexture` | A store action that resolves (`MultisampleResolve` or `StoreAndMultisampleResolve`), on a render pass attachment or set by its encoder, for an... | every device (a public call's own check of its arguments) | `metal-documented`: `MTLRenderPass.h`: `resolveTexture` is "Only used (and required) if the store action is set to MTLStoreActionMultisampleResolve" | 2: `crates/metal2vulkan-runtime/src/pass.rs (resolving)`, `crates/metal2vulkan-runtime/src/render_encoder.rs (later_store)` | `-` | | `ResolveFormat` | A resolve of a render pass color attachment of an integer pixel format | every device (a public call's own check of its arguments) | `metal-documented`: Metal's validation asserts that an integer color format "cannot be a MSAA resolve target", and plain Metal writes values no sample holds | 1: `crates/metal2vulkan-runtime/src/pass.rs (check)` | `-` | -| `AttachmentPlace` | A render pass attachment or resolve texture of a level or slice past its texture's | every device (a public call's own check of its arguments) | `ours`: no texel of the texture is there to render into | 4: `crates/metal2vulkan-runtime/src/texture.rs (attachment_view, 3 sites)`, `crates/metal2vulkan-runtime/src/texture.rs (resolve_attachment)` | `-` | +| `AttachmentPlace` | A render pass attachment or resolve texture of a level or slice past its texture's | every device (a public call's own check of its arguments) | `metal-measured`: an Apple M3 Max, macOS 27.0.1, probe `resolve_depth_planes.m` in the conformance crate, job m3-max-73495: Metal's validation layer ends the process at the encoder for a resolve into slice 3 of a 2D texture, `Slice is 3, but the texture has only 1 slices`, and for a resolve at depth plane 3 of one, `depth plane is 3, but the texture has a depth of 1 at mip level 0`; with the layer off, plain Metal writes slice and plane 0 instead. A level past the texture's was not run: that part is ours, as no texel of the texture is there to render into | 4: `crates/metal2vulkan-runtime/src/texture.rs (attachment_view, 3 sites)`, `crates/metal2vulkan-runtime/src/texture.rs (resolve_attachment)` | `-` | | `AttachmentFormat` | A render pass color attachment of a depth or stencil pixel format, a depth attachment of a format without depth, or a stencil attachment of a... | every device (a public call's own check of its arguments) | `metal-documented`: a color attachment takes a color-renderable format, a depth attachment a format with depth and a stencil attachment a format with stencil; Metal's validation stops the descriptor | 3: `crates/metal2vulkan-runtime/src/pass.rs (check, 3 sites)` | `-` | | `NoAttachmentPass` | A render pass with no attachment whose `renderTargetWidth` or `renderTargetHeight` is 0, or whose `defaultRasterSampleCount` is 0, Metal's default | every device (a public call's own check of its arguments) | `metal-measured`: an Apple M3 Max, macOS 27.0.1, the API validation layer off, m3-max-62174, `probes/no_attachment_passes.m`: a side of 0 makes no encoder, nil, and a count of 0 ends the process at the encoder, SIGABRT, where 64 by 64 pixels at 1 sample makes one | 1: `crates/metal2vulkan-runtime/src/pass.rs (check)` | `-` | | `SamplePositions` | A render pass's sample positions (`setSamplePositions:count:`) other than the device's own | every device (a public call's own check of its arguments) | `metal-documented`: `MTLRenderPass.h`: the positions are "to be used in MSAA rendering (i.e. when sample count > 1)" and the count "must be a valid sample count"; `MTLTypes.h`: a position's range is "[0,1) for both x and y"; `MTLDevice.h`'s `programmableSamplePositionsSupported`; Metal's validation stops a pass of more positions than samples, a coordinate outside the pixel and positions in a pass of one sample, and one position past the samples ends plain Metal's process on an Apple M4, the conformance suite's `sample_positions` module | 1: `crates/metal2vulkan-runtime/src/positions.rs (locations)` | `-` |