The translator built geometry stages in two forms that no Metal function asks for: - the barycentric weights: a fragment function's [[barycentric_coord]] read as varyings, which a generated geometry stage of each topology class wrote, on a device without fragmentShaderBarycentric; - the rate map's fan-out: a draw of a rasterization-rate-mapped pass's triangles once, a geometry stage emitting a copy of each per region, with its probe and its region-copy vertex variant. Neither form reached a guest. The runtime enables no geometryShader, so it refused the weights form already. It never sets BindShape::region_fan_out, and draws a rate-mapped pass region by region (the regions route, RateMapRegions, and region_viewports, which stay). Validation never set region_fan_out either. After this change, one form is left for each: - A fragment function that reads [[barycentric_coord]] reads the device's own BaryCoordKHR/BaryCoordNoPerspKHR. Without fragmentShaderBarycentric it is refused as Unsupported(Barycentrics) needing that feature alone; geometryShader is no longer offered. - A rate-mapped pass draws through the regions route. Rule 1: no precision note stops being raised. The fan-out's copies were a near-equivalent of the regions route, which carries its own note (RateMapRegions::precision), and the weights form raised none. The catalogue is unchanged. Removed: - pipeline::link::geometry (GeometryStages, the three classes' stages) and pipeline::link::fan_out, with their tests (link/tests/geometry.rs, link/tests/fan_out.rs) and tests/engine_region_fan_out; - bind::fan_out (the region table, the probe's word layout and its constants); - RegionFanOut and FanOutState; - the region_fan_out fields of GraphicsState, BindState, BindShape, VariantKey and RenderLinkInputs, and LoweringInputs::region_copies; - the region copy's lowering: StageIoPlan::region_copy, RegionCopy and the region table's declaration; - PushField::RegionBox and RegionProbe; - SyntheticBinding::RateMapRegions and RateMapFlags, and WriteSource::RateMapRegions and RateMapFlags; - RuntimeFact::SynthesizedGeometry, RenderPipeline::runs_stage and Linked::geometry; - IoRole::Barycentric with VaryingKey::barycentric and its key tag; - VkProperty::SubgroupGeometryStage; - the SPIR-V IR's geometry execution model, which only these stages produced: ExecModel::Geometry, OpEmitVertex and OpEndPrimitive, the InputPoints, InputLines, OutputLineStrip, OutputTriangleStrip and Invocations modes, ModelNeed::Geometry, EntryRule::GeometryModes and the builder's geometry ops; - from scripts/regen-spirv-grammar/items.txt, the opcodes EmitVertex and EndPrimitive, the execution model Geometry and those five execution modes. spv.rs is regenerated: the opcodes and the model stay as test-only values, which the test parser reads, and the modes go; - in validation, the census's geometry stage filter, the draw's runs_stage filter and the candidate's GEOMETRY stage arm. The census test that read three geometry stages from engine/bary_weights goes with them. The SPIR-V builder now marks only Position Invariant; ClipDistance was the fan-out's. band::plan loses its geometry flag, and takes the four SPIR-V helpers it shared with the geometry module. The binder's stage map takes a geometry stage as no render stage. Validation cases that executed either form: none. - Fan-out: no validation code sets region_fan_out. - Weights: two authored cases read [[barycentric_coord]], fa8b920d3cf3 and ae0a7e39b12f. Neither has a stored Vulkan observation on a profile without fragmentShaderBarycentric. fa8b920d3cf3 is observed on Metal and MoltenVK, and moltenvk-m3 has the feature. ae0a7e39b12f is observed on Metal only. Fourth user of GeometryStages: none. It was used by link, the compile API's splice, the binder's selection (through RuntimeFact::SynthesizedGeometry and GraphicsState::region_fan_out) and its own tests. Tests: - engine_stage_io_tail's weights test is now without_the_feature_the_weights_are_refused: on lavapipe, ANV's Iris Xe, NVIDIA's Pascal (each with geometryShader) and runtime-floor (without it), both barycentric entries are refused needing fragmentShaderBarycentric. - engine_target_indices checks each pipeline's stages valid where it counted geometry stages, and loses the_weights_stage_beside_a_vertex_layer_is_not_implemented: that combination is now the plain refusal above. - engine_amplification no longer counts geometry stages. - The binder's render stage test refuses a geometry stage. - The builder's invariant test refuses ClipDistance. - engine_rotated_weights' rotated draw runs on moltenvk-m3 and RDNA3's RADV, each with fragmentShaderBarycentric, where it ran on lavapipe through the weights form. - The fact mechanism test numbers its 100 RuntimeFact variants densely again (PrivateArena, which development added, takes 99). Bless due until the next named pin, where the M3 bless job takes them; nothing is blessed here: - tests::public_fixtures_engine (the inventory): every [[barycentric_coord]] cell on a profile without fragmentShaderBarycentric becomes Unsupported(Barycentrics) needing it alone, where it compiled through the geometry stages (with geometryShader) or offered GeometryShader as the alternative; - tests::golden_hashes, and pipeline::compile::tests::the_old_render_descriptor_key_keeps_its_value (the render key), as under the commit below: the profiles' fingerprints change; - the authored compile census. SEMANTICS_VERSION 2247 -> 2248 and ARTIFACT_FORMAT_VERSION 583 -> 584 are placeholders that main renumbers. SEMANTICS: a fragment function's weights and every rate-mapped variant change form. ARTIFACT: the codec loses the RegionFanOut, FanOutState, GraphicsState::region_fan_out, IoRole::Barycentric, RuntimeFact::SynthesizedGeometry, PushField, SyntheticBinding and VkProperty tags. RUNTIME_VERSION stays: the runtime's render-pipeline kind no longer reads region_fan_out, which it never set, and its SynthesizedStages doc names the bands alone. runtime-sources.sha256 keeps development's (land-pkt re-pins it), api_signatures and api_surface drop the removed items, and docs/REFUSALS.md is regenerated. API.md drops the geometry stages from RenderPipeline's stages, its barycentric bullet and its band bullet. ARCHITECTURE.md's link line drops pipeline::link::geometry, and the runtime README's Barycentrics gap names the feature alone. Consumer check (consumer_check.sh, consumer development b76d6ac4a9): region_fan_out, RegionFanOut, FanOutState, region_copies, region_copy, RateMapFlags, RegionBox, RegionProbe, SynthesizedGeometry, FEW_COPIES, PROBE_DRAW_WORDS, RegionCopies and runs_stage have 0 hits. GeometryStages appears in crates/reims-vgpu-c/link-order.txt only. fan_out's hits are the consumer's own event fan-out in crates/reims-vgpu/src/graphics/decode/cmdbuf.rs, not this module. Verified (jobs read): - m3-max-61801: the suites at this change's work in progress (4f1f934423); its real reds were the mechanism numbering and the rotated weights on amd-rdna3-radv, both fixed here; the render key reads bless-due. - At the stack's tip over this change (dvl-5 1fa4aed963 and dvl-6 92fe40c38f): 61978 and 61987, fmt, clippy in every configuration, Rustdoc, each feature alone, the API docs and the Windows clippy, green; 61891, the suites at dvl-4: 13 failures, each a bless-due golden above or development's own (the raster state test, the inventory's sample_fill rows); 61968, the lavapipe device suite of metal2vulkan-validation, 1483 of 1483, and public case qualification Match; 62042, the metal2vulkan-validation suite at dvl-5, 1378 of 1378 passed. - States-only play of this change's player (p-gd.zst) over 35 distinct streams on gem10 (61919), um870 (61924), ms01 (61967) and um790 (62004): 456,384 render and 91,972 compute states made, 0 refused, every stream exit 0. The msi stream (windrag-780m-b2) is not played: msi had no memory free. Rebased onto development4cf936ed4d(selidx landed as3ecf606aa8). The conflicts: the version lines; the mechanism test, where development added RuntimeFact::PrivateArena; runtime-sources.sha256, where development's is kept; and api_signatures.tsv and docs/REFUSALS.md, both regenerated (signatures.py --bless, refusal_surface.py) and differing from development by this change's items alone. The jobs above ran at the old base; the rebased tip's are in the report to main.
141 lines
8.3 KiB
Plaintext
141 lines
8.3 KiB
Plaintext
# The SPIR-V grammar items the translator names: generate.py emits these into
|
|
# crates/metal2vulkan/src/spv.rs and nothing else. A value the code names that is missing here
|
|
# fails to build; a value listed here that nothing uses is dead code, which rustc reports where it
|
|
# can see it (not for a type the crate's public impls reach, such as `Op` through `BuildError`).
|
|
# Values only test code names go in test-values, so the library build has none of them.
|
|
#
|
|
# type Word | const MAGIC_NUMBER the word type; the module header's first word
|
|
# enum <Kind> [test] an operand kind of the core grammar by its grammar name (a
|
|
# mask for a BitEnum kind), `Op` for the core instructions or
|
|
# `GlslStd450Op` for GLSL.std.450's; `test`: in test builds only
|
|
# from_u32 [test] the kind's word-to-value conversion (it needs every value)
|
|
# values <Name>... | * values every build has, by their Rust names (generate.py's
|
|
# variant_name and const_name); `*`: all not named yet
|
|
# test-values <Name>... | * values only test builds have
|
|
|
|
type Word test
|
|
const MAGIC_NUMBER
|
|
|
|
enum Op
|
|
from_u32 test
|
|
values Nop Undef Extension ExtInstImport ExtInst MemoryModel EntryPoint ExecutionMode Capability
|
|
values TypeVoid TypeBool TypeInt TypeFloat TypeVector TypeMatrix TypeImage TypeSampler
|
|
values TypeSampledImage TypeArray TypeRuntimeArray TypeStruct TypePointer TypeFunction ConstantTrue
|
|
values ConstantFalse Constant ConstantComposite ConstantNull SpecConstantTrue SpecConstantFalse
|
|
values SpecConstant SpecConstantComposite SpecConstantOperation Function FunctionParameter FunctionEnd
|
|
values FunctionCall Variable ImageTexelPointer Load Store AccessChain ArrayLength Decorate
|
|
values MemberDecorate VectorExtractDynamic VectorInsertDynamic VectorShuffle CompositeConstruct
|
|
values CompositeExtract CompositeInsert CopyObject SampledImage ImageSampleImplicitLod
|
|
values ImageSampleExplicitLod ImageSampleDrefImplicitLod ImageSampleDrefExplicitLod
|
|
values ImageSampleProjImplicitLod ImageSampleProjExplicitLod ImageSampleProjDrefImplicitLod
|
|
values ImageSampleProjDrefExplicitLod ImageFetch ImageGather ImageDrefGather ImageRead ImageWrite
|
|
values Image ImageQuerySizeLod ImageQuerySize ImageQueryLod ImageQueryLevels ImageQuerySamples
|
|
values ConvertFToU ConvertFToS ConvertSToF ConvertUToF UConvert SConvert FConvert QuantizeToF16
|
|
values ConvertUToPtr Bitcast SNegate FNegate IAdd FAdd ISub FSub IMul FMul UDiv SDiv FDiv UMod SRem
|
|
values SMod FRem VectorTimesScalar Dot IAddCarry ISubBorrow UMulExtended SMulExtended Any All IsNan
|
|
values IsInf LogicalEqual LogicalNotEqual LogicalOr LogicalAnd LogicalNot Select IEqual INotEqual
|
|
values UGreaterThan SGreaterThan UGreaterThanEqual SGreaterThanEqual ULessThan SLessThan
|
|
values ULessThanEqual SLessThanEqual FOrdEqual FUnordEqual FOrdNotEqual FUnordNotEqual FOrdLessThan
|
|
values FUnordLessThan FOrdGreaterThan FUnordGreaterThan FOrdLessThanEqual FUnordLessThanEqual
|
|
values FOrdGreaterThanEqual FUnordGreaterThanEqual ShiftRightLogical ShiftRightArithmetic
|
|
values ShiftLeftLogical BitwiseOr BitwiseXor BitwiseAnd Not BitFieldInsert BitFieldSExtract
|
|
values BitFieldUExtract BitReverse BitCount DPdx DPdy Fwidth DPdxFine DPdyFine FwidthFine
|
|
values ControlBarrier MemoryBarrier AtomicLoad AtomicStore AtomicExchange AtomicCompareExchange
|
|
values AtomicIAdd AtomicISub AtomicSMin AtomicUMin AtomicSMax AtomicUMax AtomicAnd AtomicOr
|
|
values AtomicXor Phi LoopMerge SelectionMerge Label Branch BranchConditional Switch Kill Return
|
|
values ReturnValue Unreachable ImageSparseSampleImplicitLod ImageSparseSampleExplicitLod
|
|
values ImageSparseSampleDrefImplicitLod ImageSparseSampleDrefExplicitLod ImageSparseFetch
|
|
values ImageSparseGather ImageSparseDrefGather ImageSparseTexelsResident ImageSparseRead
|
|
values GroupNonUniformElect GroupNonUniformAll GroupNonUniformAny GroupNonUniformBroadcastFirst
|
|
values GroupNonUniformBallot GroupNonUniformBallotBitExtract GroupNonUniformShuffle
|
|
values GroupNonUniformShuffleXor GroupNonUniformIAdd GroupNonUniformFAdd GroupNonUniformIMul
|
|
values GroupNonUniformFMul GroupNonUniformSMin GroupNonUniformUMin GroupNonUniformFMin
|
|
values GroupNonUniformSMax GroupNonUniformUMax GroupNonUniformFMax GroupNonUniformBitwiseAnd
|
|
values GroupNonUniformBitwiseOr GroupNonUniformBitwiseXor GroupNonUniformLogicalAnd
|
|
values GroupNonUniformLogicalOr GroupNonUniformLogicalXor GroupNonUniformQuadBroadcast
|
|
values GroupNonUniformQuadSwap TerminateInvocation FmaKHR TypeRayQueryKHR RayQueryInitializeKHR
|
|
values RayQueryConfirmIntersectionKHR RayQueryProceedKHR RayQueryGetIntersectionTypeKHR
|
|
values EmitMeshTasksEXT SetMeshOutputsEXT TypeAccelerationStructureKHR BeginInvocationInterlockEXT
|
|
values EndInvocationInterlockEXT DemoteToHelperInvocation IsHelperInvocationEXT
|
|
values RayQueryGetIntersectionTKHR RayQueryGetIntersectionInstanceCustomIndexKHR
|
|
values RayQueryGetIntersectionInstanceIdKHR
|
|
values RayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR
|
|
values RayQueryGetIntersectionGeometryIndexKHR RayQueryGetIntersectionPrimitiveIndexKHR
|
|
values RayQueryGetIntersectionBarycentricsKHR RayQueryGetIntersectionFrontFaceKHR
|
|
values RayQueryGetIntersectionObjectToWorldKHR RayQueryGetIntersectionWorldToObjectKHR
|
|
values AtomicFAddEXT
|
|
test-values *
|
|
|
|
enum Capability
|
|
from_u32
|
|
values *
|
|
|
|
enum ExecutionModel
|
|
from_u32 test
|
|
values Vertex TessellationControl TessellationEvaluation Fragment GLCompute TaskEXT MeshEXT
|
|
test-values *
|
|
|
|
enum AddressingModel
|
|
values Logical PhysicalStorageBuffer64
|
|
|
|
enum MemoryModel
|
|
values GLSL450 Vulkan
|
|
|
|
enum ExecutionMode
|
|
values SpacingEqual SpacingFractionalEven SpacingFractionalOdd VertexOrderCw VertexOrderCcw
|
|
values OriginUpperLeft EarlyFragmentTests DepthReplacing DepthGreater DepthLess LocalSize Triangles
|
|
values Quads OutputVertices OutputPoints SubgroupUniformControlFlowKHR SignedZeroInfNanPreserve
|
|
values StencilRefReplacingEXT RequireFullQuadsKHR OutputLinesEXT OutputPrimitivesEXT
|
|
values DerivativeGroupLinearKHR OutputTrianglesEXT PixelInterlockOrderedEXT
|
|
values SampleInterlockOrderedEXT MaximallyReconvergesKHR DenormPreserve RoundingModeRTE
|
|
values PostDepthCoverage
|
|
test-values ContractionOff FPFastMathDefault
|
|
|
|
enum StorageClass
|
|
values UniformConstant Input Uniform Output Workgroup Private Function PushConstant Image
|
|
values StorageBuffer PhysicalStorageBuffer TaskPayloadWorkgroupEXT
|
|
|
|
enum Dim
|
|
values D1 D2 D3 Cube Buffer SubpassData
|
|
|
|
enum FPEncoding
|
|
values Float8E4M3EXT Float8E5M2EXT
|
|
|
|
enum ImageFormat
|
|
values *
|
|
|
|
enum Decoration
|
|
values SpecId Block ColMajor ArrayStride MatrixStride BuiltIn NoPerspective Flat Patch Centroid
|
|
values Sample Invariant Aliased Volatile Coherent NonWritable Location Component Index Binding
|
|
values DescriptorSet Offset NoContraction InputAttachmentIndex PerPrimitiveEXT NonUniform
|
|
values AliasedPointer
|
|
test-values FPFastMathMode
|
|
|
|
enum BuiltIn
|
|
values Position PointSize ClipDistance PrimitiveId Layer ViewportIndex TessLevelOuter
|
|
values TessLevelInner TessCoord FragCoord PointCoord FrontFacing SampleId SampleMask FragDepth
|
|
values HelperInvocation NumWorkgroups WorkgroupSize WorkgroupId LocalInvocationId
|
|
values GlobalInvocationId LocalInvocationIndex SubgroupSize SubgroupId SubgroupLocalInvocationId
|
|
values VertexIndex InstanceIndex BaseVertex BaseInstance ViewIndex FragStencilRefEXT BaryCoordKHR
|
|
values BaryCoordNoPerspKHR PrimitivePointIndicesEXT PrimitiveLineIndicesEXT
|
|
values PrimitiveTriangleIndicesEXT CullPrimitiveEXT CullDistance SamplePosition NumSubgroups
|
|
values DrawIndex InvocationId PatchVertices
|
|
test-values WorkDim
|
|
|
|
enum Scope
|
|
values Device Workgroup Subgroup Invocation
|
|
|
|
enum GroupOperation
|
|
values Reduce InclusiveScan ExclusiveScan ClusteredReduce
|
|
|
|
enum FPFastMathMode test
|
|
values NOT_NAN NOT_INF NSZ ALLOW_RECIP ALLOW_REASSOC ALLOW_CONTRACT
|
|
|
|
enum GlslStd450Op
|
|
values Round RoundEven Trunc FAbs SAbs FSign SSign Floor Ceil Fract Radians Degrees Sin Cos Tan
|
|
values Asin Acos Atan Sinh Cosh Tanh Asinh Acosh Atanh Atan2 Pow Exp Log Exp2 Log2 Sqrt InverseSqrt
|
|
values Determinant MatrixInverse ModfStruct FMin UMin SMin FMax UMax SMax FClamp UClamp SClamp FMix
|
|
values Step SmoothStep Fma FrexpStruct Ldexp PackSnorm4x8 PackUnorm4x8 PackSnorm2x16 PackUnorm2x16
|
|
values PackHalf2x16 UnpackSnorm2x16 UnpackUnorm2x16 UnpackHalf2x16 UnpackSnorm4x8 UnpackUnorm4x8
|
|
values Length Distance Cross Normalize FaceForward Reflect Refract FindILsb FindSMsb FindUMsb
|
|
values InterpolateAtCentroid InterpolateAtSample InterpolateAtOffset NMin NMax NClamp |