diff --git a/core/kyty/graphics/host_gpu/graphicContext.h b/core/kyty/graphics/host_gpu/graphicContext.h index 1d2a7a45be1..a59c2ac1ff4 100644 --- a/core/kyty/graphics/host_gpu/graphicContext.h +++ b/core/kyty/graphics/host_gpu/graphicContext.h @@ -38,6 +38,8 @@ struct GraphicContext { bool maintenance8_enabled = false; bool robust_buffer_access_enabled = false; bool ray_query_enabled = false; + bool compute_derivative_quads_enabled = false; + bool compute_derivative_linear_enabled = false; bool r8_srgb_views = false; bool r8g8_srgb_views = false; bool r4g4b4a4_render_targets = false; diff --git a/core/kyty/graphics/host_gpu/renderer/pipeline/pipelineShaderModule.cpp b/core/kyty/graphics/host_gpu/renderer/pipeline/pipelineShaderModule.cpp index 7da161df9f9..14988a915ff 100644 --- a/core/kyty/graphics/host_gpu/renderer/pipeline/pipelineShaderModule.cpp +++ b/core/kyty/graphics/host_gpu/renderer/pipeline/pipelineShaderModule.cpp @@ -143,6 +143,8 @@ ShaderRecompiler::Spirv::Profile SpirvProfile(const GraphicContext& graphics) { .r8g8_srgb_views = graphics.r8g8_srgb_views, .relaxed_float = Config::RelaxedShaderFloatEnabled(), .ray_query = graphics.ray_query_enabled, + .compute_derivative_quads = graphics.compute_derivative_quads_enabled, + .compute_derivative_linear = graphics.compute_derivative_linear_enabled, .lds_lane_sync = LdsLaneSyncEnabled(), .native_float16 = graphics.shader_float16_enabled, .f32_product_no_contraction = F32ProductNoContractionEnabled(), diff --git a/core/kyty/graphics/presentation/window/vulkanWindow.cpp b/core/kyty/graphics/presentation/window/vulkanWindow.cpp index d22791f448a..45d6f1522fa 100644 --- a/core/kyty/graphics/presentation/window/vulkanWindow.cpp +++ b/core/kyty/graphics/presentation/window/vulkanWindow.cpp @@ -526,6 +526,8 @@ static vk::Device VulkanCreateDevice(GraphicContext& graphics, "Some games may render incorrectly or crash.\n"); } graphics.shader_image_int64_atomics_enabled = image_atomic_int64.shaderImageInt64Atomics; + graphics.compute_derivative_quads_enabled = compute_derivatives.computeDerivativeGroupQuads == VK_TRUE; + graphics.compute_derivative_linear_enabled = compute_derivatives.computeDerivativeGroupLinear == VK_TRUE; #if defined(ANYPS5_KYTY) if (PipelineLibrariesWanted() && extended_dynamic_state && HasExtension(available_extensions, VK_KHR_PIPELINE_LIBRARY_EXTENSION_NAME) && @@ -800,7 +802,7 @@ static vk::Device VulkanCreateDevice(GraphicContext& graphics, if (!graphics.conditional_rendering_enabled) { create.unlink(); } - if (!compute_derivatives.computeDerivativeGroupQuads) { + if (!graphics.compute_derivative_quads_enabled && !graphics.compute_derivative_linear_enabled) { create.unlink(); } if (!extended_dynamic_state) { diff --git a/core/kyty/graphics/shader/recompiler/backend/spirv/SpirvEmitter.h b/core/kyty/graphics/shader/recompiler/backend/spirv/SpirvEmitter.h index 5d87b63fc89..429f0da06c0 100644 --- a/core/kyty/graphics/shader/recompiler/backend/spirv/SpirvEmitter.h +++ b/core/kyty/graphics/shader/recompiler/backend/spirv/SpirvEmitter.h @@ -18,6 +18,8 @@ struct Profile { bool r8g8_srgb_views = false; bool relaxed_float = false; bool ray_query = false; + bool compute_derivative_quads = true; + bool compute_derivative_linear = true; bool lds_lane_sync = true; bool native_float16 = true; bool f32_product_no_contraction = true; diff --git a/core/kyty/graphics/shader/recompiler/backend/spirv/spirvEmitterModule.cpp b/core/kyty/graphics/shader/recompiler/backend/spirv/spirvEmitterModule.cpp index d63d8c682e6..48526b61a8e 100644 --- a/core/kyty/graphics/shader/recompiler/backend/spirv/spirvEmitterModule.cpp +++ b/core/kyty/graphics/shader/recompiler/backend/spirv/spirvEmitterModule.cpp @@ -1085,10 +1085,6 @@ void DefineModule(EmitterState& state) { state.builder.RequireCapability(spv::CapabilityGroupNonUniformBallot); state.builder.RequireCapability(spv::CapabilityGroupNonUniformShuffle); } - if (state.program.info.compute_derivatives && state.program.stage == ShaderType::Compute) { - state.builder.RequireCapability(spv::CapabilityComputeDerivativeGroupQuadsKHR); - state.builder.RequireExtension("SPV_KHR_compute_shader_derivatives"); - } const bool fragment_barycentric = state.program.stage == ShaderType::Pixel && std::any_of(state.inputs.begin(), state.inputs.end(), [](const InputBinding& input) { @@ -1124,6 +1120,10 @@ void DefineModule(EmitterState& state) { local_x = cs->threads_num[0] != 0u ? cs->threads_num[0] : local_x; local_y = cs->threads_num[1] != 0u ? cs->threads_num[1] : local_y; local_z = cs->threads_num[2] != 0u ? cs->threads_num[2] : local_z; + if (state.program.stage == ShaderType::Compute && state.program.info.compute_derivatives && + (uint64_t {local_x} * local_y * local_z) % 4u != 0u) { + EXIT("compute derivatives require four-lane workgroups (got %ux%ux%u)", local_x, local_y, local_z); + } if (state.lane_count == 2) { local_x = ((local_x * local_y * local_z + 63u) / 64u) * 32u; local_y = local_z = 1u; @@ -1134,6 +1134,21 @@ void DefineModule(EmitterState& state) { } state.builder.AddExecutionMode(state.main_func, spv::ExecutionModeLocalSize, local_x, local_y, local_z); + if (state.program.stage == ShaderType::Compute && state.program.info.compute_derivatives) { + const bool quads_layout = (local_x & 1u) == 0u && (local_y & 1u) == 0u; + const bool linear_layout = (uint64_t {local_x} * local_y * local_z) % 4u == 0u; + if (quads_layout && state.profile.compute_derivative_quads) { + state.builder.RequireCapability(spv::CapabilityComputeDerivativeGroupQuadsKHR); + state.builder.AddExecutionMode(state.main_func, spv::ExecutionModeDerivativeGroupQuadsKHR); + } else if (linear_layout && state.profile.compute_derivative_linear) { + state.builder.RequireCapability(spv::CapabilityComputeDerivativeGroupLinearKHR); + state.builder.AddExecutionMode(state.main_func, spv::ExecutionModeDerivativeGroupLinearKHR); + } else { + EXIT("compute derivative group feature unavailable for local size %ux%ux%u", local_x, + local_y, local_z); + } + state.builder.RequireExtension("SPV_KHR_compute_shader_derivatives"); + } } if (state.program.stage == ShaderType::Pixel) { state.builder.AddExecutionMode(state.main_func, spv::ExecutionModeOriginUpperLeft); @@ -1155,9 +1170,6 @@ void DefineModule(EmitterState& state) { } #endif } - if (state.program.info.compute_derivatives && state.program.stage == ShaderType::Compute) { - state.builder.AddExecutionMode(state.main_func, spv::ExecutionModeDerivativeGroupQuadsKHR); - } state.builder.AddName(state.main_func, "main"); if (state.program.info.function_lds) { state.builder.AddName(state.lds_variable, "lds_dwords"); diff --git a/core/kyty/graphics/shader/recompiler/ir/Serialize.h b/core/kyty/graphics/shader/recompiler/ir/Serialize.h index 94ef472993c..d9324f3369e 100644 --- a/core/kyty/graphics/shader/recompiler/ir/Serialize.h +++ b/core/kyty/graphics/shader/recompiler/ir/Serialize.h @@ -220,7 +220,7 @@ KYTY_IO_FIELDS(BdaReadWord, a, b) KYTY_IO_FIELDS(BdaReadSpan, a, b, c, d, e) KYTY_IO_FIELDS(BdaReadPlan, a, b) KYTY_IO_FIELDS(CompiledShaderInfo, a, b, c, d, e, f, g, h, i, j, k) -KYTY_IO_FIELDS(Spirv::Profile, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p) +KYTY_IO_FIELDS(Spirv::Profile, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r) #if defined(ANYPS5_KYTY) KYTY_IO_FIELDS(ShaderTessellationInputInfo, a, b, c, d, e, f, g, h, i, j) #else diff --git a/core/kyty/tools/SpirvMatch.cpp b/core/kyty/tools/SpirvMatch.cpp index deba73568be..efa73e50f16 100644 --- a/core/kyty/tools/SpirvMatch.cpp +++ b/core/kyty/tools/SpirvMatch.cpp @@ -44,6 +44,8 @@ bool ReadDump(const std::filesystem::path& path, Dump& dump) { template using EarlierProfile = std::tuple>; +using PreviousProfile = std::tuple, uint32_t>; + bool ReadStoreHeader(std::istream& input) { input.seekg(0, std::ios::end); const auto end = input.tellg(); @@ -67,7 +69,8 @@ bool ReadStoreHeader(std::istream& input) { input.seekg(size); return bool(input); }; - return try_profile(ShaderRecompiler::Spirv::Profile{}) || try_profile(EarlierProfile<9>{}) || + return try_profile(ShaderRecompiler::Spirv::Profile{}) || try_profile(PreviousProfile{}) || + try_profile(EarlierProfile<9>{}) || try_profile(EarlierProfile<8>{}) || try_profile(EarlierProfile<7>{}) || try_profile(EarlierProfile<6>{}); } diff --git a/core/kyty/tools/tests/SpirvMatch.cmake b/core/kyty/tools/tests/SpirvMatch.cmake index 523b3cacf62..3a7e8eff6be 100644 --- a/core/kyty/tools/tests/SpirvMatch.cmake +++ b/core/kyty/tools/tests/SpirvMatch.cmake @@ -20,6 +20,7 @@ string(CONCAT both "${vertex}" "input=3 stage=pixel shader=0000000000000103 module=0000000000000300 variant=standard\n") check_match(0 "${both}" "" fixture.shaders "モジュール.spv" plain.spv ps.spv) check_match(0 "${vertex}" "" legacy.shaders vs.spv) +check_match(0 "${vertex}" "" previous.shaders vs.spv) check_match(1 "${vertex}input=2 no match\n" "" fixture.shaders vs.spv missing.spv) check_match(2 "" "Invalid or unreadable SPIR-V input 2\n" fixture.shaders vs.spv invalid.spv) check_match(2 "" "Invalid or unreadable Kyty shader store header\n" bad-header.shaders vs.spv) diff --git a/core/kyty/tools/tests/SpirvMatchFixture.cpp b/core/kyty/tools/tests/SpirvMatchFixture.cpp index da1964e1b99..7585912a177 100644 --- a/core/kyty/tools/tests/SpirvMatchFixture.cpp +++ b/core/kyty/tools/tests/SpirvMatchFixture.cpp @@ -78,6 +78,14 @@ int main() { Write(legacy, old_header.bytes); WriteModule(legacy, 0x102, 0x201, ShaderType::Vertex, vertex, {}); WriteModule(legacy, 0x101, 0x201, ShaderType::Vertex, vertex, {}); + std::ofstream previous("previous.shaders", std::ios::binary); + Writer previous_header; + const uint32_t all_stages = ~0u; + IoAll(previous_header, stamp, off, off, clock_period, off, off, off, off, off, + on, on, on, on, on, on, on, all_stages, shared_memory); + Write(previous, previous_header.bytes); + WriteModule(previous, 0x102, 0x201, ShaderType::Vertex, vertex, {}); + WriteModule(previous, 0x101, 0x201, ShaderType::Vertex, vertex, {}); std::ofstream malformed("malformed.shaders", std::ios::binary); Write(malformed, header.bytes); @@ -93,5 +101,5 @@ int main() { WriteDump("plain.spv", plain); WriteDump("missing.spv", missing); WriteDump("invalid.spv", {0, 0, 0, 0, 0}); - return !store || !legacy || !malformed || !bad_header; + return !store || !legacy || !previous || !malformed || !bad_header; } diff --git a/core/libs/prx/libSceAgcDriver/KytyShim/fuzz/ShaderRecompilerRun.hpp b/core/libs/prx/libSceAgcDriver/KytyShim/fuzz/ShaderRecompilerRun.hpp index 6d89fb02e6e..d559f3c0132 100644 --- a/core/libs/prx/libSceAgcDriver/KytyShim/fuzz/ShaderRecompilerRun.hpp +++ b/core/libs/prx/libSceAgcDriver/KytyShim/fuzz/ShaderRecompilerRun.hpp @@ -72,7 +72,9 @@ inline void ReportInvalid(const std::string& message, std::span } inline void Run(std::span original, uint8_t mode, uint8_t shape, - std::string* refusal = nullptr, bool* emitted = nullptr) { + std::string* refusal = nullptr, bool* emitted = nullptr, + const Recompiler::Spirv::Profile* device_profile = nullptr, + std::vector* spirv_output = nullptr, uint32_t compute_local_x = 0u) { if (emitted != nullptr) *emitted = false; static const auto profile = Profile(); std::vector storage(original.begin(), original.end()); @@ -84,7 +86,7 @@ inline void Run(std::span original, uint8_t mode, uint8_t shape, options.emit_debug_info = false; options.native_ray_tracing = true; options.ray_stats = false; - options.profile = &profile; + options.profile = device_profile != nullptr ? device_profile : &profile; const std::vector user_data(16u + (shape & 15u), 0u); options.user_data = user_data; @@ -107,7 +109,7 @@ inline void Run(std::span original, uint8_t mode, uint8_t shape, default: compute.wave_size = wave; compute.host_subgroup_size = 32; - compute.threads_num[0] = 1u << (shape & 3u); + compute.threads_num[0] = compute_local_x != 0u ? compute_local_x : 1u << (shape & 3u); compute.threads_num[1] = 1u << ((shape >> 2) & 3u); compute.threads_num[2] = 1; compute.thread_ids_num = 2; @@ -137,6 +139,7 @@ inline void Run(std::span original, uint8_t mode, uint8_t shape, if (!IR::ResourceSpecializationFits(translated.program, specialization)) return; auto compiled = Recompiler::CompileProgram(std::move(translated), options, specialization, 0); if (emitted != nullptr) *emitted = !compiled.spirv.empty(); + if (spirv_output != nullptr) *spirv_output = compiled.spirv; const char* policy = std::getenv("KYTY_FUZZ_SPIRV"); if (!compiled.spirv.empty() && policy != nullptr && std::strcmp(policy, "off") != 0 && policy[0] != 0) { std::string message; diff --git a/core/libs/prx/libSceAgcDriver/KytyShim/tests/HalfProfile.cpp b/core/libs/prx/libSceAgcDriver/KytyShim/tests/HalfProfile.cpp index 891c557fd8f..ac81a70a048 100644 --- a/core/libs/prx/libSceAgcDriver/KytyShim/tests/HalfProfile.cpp +++ b/core/libs/prx/libSceAgcDriver/KytyShim/tests/HalfProfile.cpp @@ -13,9 +13,17 @@ void Require(bool condition, const char* message) { std::exit(1); } -std::vector Header(bool native) { +struct Features { + bool native; + bool quads; + bool linear; +}; + +std::vector Header(Features features) { ShaderRecompiler::Spirv::Profile profile; - profile.native_float16 = native; + profile.native_float16 = features.native; + profile.compute_derivative_quads = features.quads; + profile.compute_derivative_linear = features.linear; const uint64_t stamp = 1234; const uint32_t limit = 65536; ShaderRecompiler::IR::Writer writer; @@ -27,10 +35,19 @@ std::vector Header(bool native) { int main() { Require(ShaderRecompiler::Spirv::DefaultProfile.native_float16, "the default changed the native shader path"); - const auto native = Header(true); - const auto software = Header(false); + Require(ShaderRecompiler::Spirv::DefaultProfile.compute_derivative_quads && + ShaderRecompiler::Spirv::DefaultProfile.compute_derivative_linear, + "the default changed the derivative shader path"); + const auto native = Header({true, true, true}); + const auto software = Header({false, true, true}); + const auto without_quads = Header({true, false, true}); + const auto without_linear = Header({true, true, false}); Require(native != software, "native and software-half stores have the same header"); - for (bool expected : {false, true}) { + Require(native != without_quads && native != without_linear, + "derivative feature profiles have the same store header"); + const Features cases[] = {{false, true, true}, {true, true, true}, + {true, false, true}, {true, true, false}}; + for (const auto& expected : cases) { const auto bytes = Header(expected); ShaderRecompiler::IR::Reader reader {bytes}; uint64_t stamp = 0; @@ -38,8 +55,10 @@ int main() { ShaderRecompiler::Spirv::Profile profile; ShaderStoreFormat::IoStoreHeader(reader, stamp, profile, limit); Require(reader.ok && reader.bytes.empty(), "a profile header did not decode exactly"); - Require(stamp == 1234 && limit == 65536 && profile.native_float16 == expected, - "a store header lost its half-precision profile"); + Require(stamp == 1234 && limit == 65536 && profile.native_float16 == expected.native && + profile.compute_derivative_quads == expected.quads && + profile.compute_derivative_linear == expected.linear, + "a store header lost its shader feature profile"); ShaderRecompiler::IR::Reader truncated {std::span(bytes).first(bytes.size() - 1)}; ShaderStoreFormat::IoStoreHeader(truncated, stamp, profile, limit); Require(!truncated.ok, "a truncated profile header was accepted"); diff --git a/core/libs/prx/libSceAgcDriver/KytyShim/tests/RecompilerRobustness.cpp b/core/libs/prx/libSceAgcDriver/KytyShim/tests/RecompilerRobustness.cpp index 605f0d23f0a..388b8f6ad97 100644 --- a/core/libs/prx/libSceAgcDriver/KytyShim/tests/RecompilerRobustness.cpp +++ b/core/libs/prx/libSceAgcDriver/KytyShim/tests/RecompilerRobustness.cpp @@ -1,5 +1,6 @@ #include "ShaderRecompilerRun.hpp" #include "graphics/shader/recompiler/frontend/decode/ShaderDecoder.h" +#include "spirv/unified1/spirv.hpp" #include #include @@ -15,9 +16,26 @@ struct Case { uint8_t shape; std::vector words; bool requires_spirv = false; + uint32_t execution_mode = 0; + bool quads_supported = true; }; const std::vector Cases = { + {"compute-image-lod-with-2x2-workgroup", 0x01, 0x05, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, true, + spv::ExecutionModeDerivativeGroupQuadsKHR}, + {"compute-image-lod-with-4x2-workgroup", 0x01, 0x06, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, true, + spv::ExecutionModeDerivativeGroupQuadsKHR}, + {"compute-image-lod-with-8x1-workgroup", 0x01, 0x03, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, true, + spv::ExecutionModeDerivativeGroupLinearKHR}, + {"compute-image-lod-with-8x1-wave64-host32", 0x00, 0x03, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, true, + spv::ExecutionModeDerivativeGroupQuadsKHR}, + {"compute-image-lod-with-2x2-without-quads-feature", 0x01, 0x05, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, true, + spv::ExecutionModeDerivativeGroupLinearKHR, false}, {"lds-append-in-a-vertex-shader", 0x03, 0x00, {0xd8f80000u, 0u, 0xbf810000u}, true}, {"lds-consume-in-a-vertex-shader", 0x03, 0x00, {0xd8f40000u, 0u, 0xbf810000u}, true}, {"lds-append-in-a-pixel-shader", 0x04, 0x00, {0xd8f80000u, 0u, 0xbf810000u}, true}, @@ -47,9 +65,20 @@ struct Refusal { uint8_t shape; std::vector words; const char* reason; + bool linear_supported = true; + uint32_t compute_local_x = 0u; }; const std::vector Refusals = { + {"compute-image-lod-with-1x1-workgroup", 0x01, 0x00, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, + "compute derivatives require four-lane workgroups"}, + {"compute-image-lod-with-3x1-workgroup", 0x01, 0x00, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, + "compute derivatives require four-lane workgroups", true, 3u}, + {"compute-image-lod-with-8x1-without-linear-feature", 0x01, 0x03, + {0xf1800000u, 0x00000000u, 0xe8040000u, 0x00000000u, 0xbf810000u}, + "compute derivative group feature unavailable", false}, {"vop3p-without-its-second-word", 0x3b, 0x07, {0x520a0001u, 0xce600001u}, "the code ends after"}, {"literal-constant-without-its-word", 0x00, 0x00, {0x7e0002ffu}, "the code ends after"}, {"vop1-dpp-without-its-modifier-word", 0x00, 0x00, {0x7e0002fau}, "the code ends after"}, @@ -91,6 +120,19 @@ const std::vector ModeWrites = { {0xb9001801u, 0x00u}, }; +bool HasExecutionMode(const std::vector& words, uint32_t expected) { + for (size_t offset = 5; offset < words.size();) { + const uint32_t count = words[offset] >> 16u; + if (count == 0u || count > words.size() - offset) return false; + if ((words[offset] & 0xffffu) == spv::OpExecutionMode && count >= 3u && + words[offset + 2u] == expected) { + return true; + } + offset += count; + } + return false; +} + bool FloatModeBits() { namespace Decoder = Libs::Graphics::ShaderRecompiler::Decoder; bool ok = true; @@ -159,18 +201,29 @@ int main(int argc, char** argv) { if (argc >= 2 && std::string_view(argv[1]) != entry.name) continue; found = true; bool emitted = false; - KytyFuzz::Run(entry.words, entry.mode, entry.shape, nullptr, &emitted); + std::vector spirv; + auto profile = KytyFuzz::Profile(); + profile.compute_derivative_quads = entry.quads_supported; + KytyFuzz::Run(entry.words, entry.mode, entry.shape, nullptr, &emitted, &profile, + entry.execution_mode == 0u ? nullptr : &spirv); if (entry.requires_spirv && !emitted) { std::printf("%s: FAILED, did not emit SPIR-V\n", entry.name); return 1; } + if (entry.execution_mode != 0u && !HasExecutionMode(spirv, entry.execution_mode)) { + std::printf("%s: FAILED, missing execution mode %u\n", entry.name, entry.execution_mode); + return 1; + } std::printf("%s: ok\n", entry.name); } for (const auto& entry: Refusals) { if (argc >= 2 && std::string_view(argv[1]) != entry.name) continue; found = true; std::string refusal; - KytyFuzz::Run(entry.words, entry.mode, entry.shape, &refusal); + auto profile = KytyFuzz::Profile(); + profile.compute_derivative_linear = entry.linear_supported; + KytyFuzz::Run(entry.words, entry.mode, entry.shape, &refusal, nullptr, &profile, + nullptr, entry.compute_local_x); if (refusal.find(entry.reason) == std::string::npos) { std::printf("%s: FAILED, refusal \"%s\" instead of \"%s\"\n", entry.name, refusal.c_str(), entry.reason); return 1; diff --git a/docs/dev/debt/changes/fix-kyty-compute-derivative-local-size.md b/docs/dev/debt/changes/fix-kyty-compute-derivative-local-size.md new file mode 100644 index 00000000000..0957435bb58 --- /dev/null +++ b/docs/dev/debt/changes/fix-kyty-compute-derivative-local-size.md @@ -0,0 +1,5 @@ +# kyty + +## add Functional + +- [Compute quad derivatives](../../../core/kyty/graphics/shader/recompiler/backend/spirv/spirvEmitterModule.cpp) retain `DerivativeGroupQuadsKHR` on compatible 2D layouts and use `DerivativeGroupLinearKHR` for other complete four-lane groups when the device enables it. Incomplete guest groups and unavailable device features are refused. Whether Linear better matches console lane order for every compatible 2D layout remains unverified. Closes when: lane-order behavior is measured across layouts and a valid fallback for unsupported devices is tested.