From f1a57ff64a5c335032b14d2abfe4908eb0c832bc Mon Sep 17 00:00:00 2001 From: baldurk Date: Fri, 13 Feb 2026 10:41:59 +0000 Subject: [PATCH] Update SPIR-V headers to latest --- .../driver/shaders/spirv/all_capabilities.txt | 6 +- renderdoc/driver/shaders/spirv/all_exts.txt | 5 + .../driver/shaders/spirv/check_extensions.sh | 2 +- .../driver/shaders/spirv/extension_support.md | 10 + renderdoc/driver/shaders/spirv/spir-v.xml | 8 +- .../shaders/spirv/spirv.core.grammar.json | 694 ++++++++- .../driver/shaders/spirv/spirv_debug.cpp | 45 +- .../shaders/spirv/spirv_debug_setup.cpp | 30 +- renderdoc/driver/shaders/spirv/spirv_gen.cpp | 891 ++++++++++- renderdoc/driver/shaders/spirv/spirv_gen.h | 69 +- .../driver/shaders/spirv/spirv_op_helpers.h | 1308 ++++++++++++++++- .../driver/shaders/spirv/spirv_registry.md | 7 +- 12 files changed, 3000 insertions(+), 75 deletions(-) diff --git a/renderdoc/driver/shaders/spirv/all_capabilities.txt b/renderdoc/driver/shaders/spirv/all_capabilities.txt index 919368b96..6a67b56e0 100644 --- a/renderdoc/driver/shaders/spirv/all_capabilities.txt +++ b/renderdoc/driver/shaders/spirv/all_capabilities.txt @@ -129,6 +129,7 @@ 5116 BFloat16TypeKHR 5117 BFloat16DotProductKHR 5118 BFloat16CooperativeMatrixKHR +5128 DescriptorHeapEXT 5249 SampleMaskOverrideCoverageNV 5251 GeometryShaderPassthroughNV 5254 ShaderViewportIndexLayerEXT @@ -142,7 +143,7 @@ 5284 FragmentBarycentricKHR 5288 ComputeDerivativeGroupQuadsKHR 5291 FragmentDensityEXT -5297 GroupNonUniformPartitionedNV +5297 GroupNonUniformPartitionedEXT 5301 ShaderNonUniform 5302 RuntimeDescriptorArray 5303 InputAttachmentArrayDynamicIndexing @@ -172,6 +173,7 @@ 5380 DisplacementMicromapNV 5381 RayTracingOpacityMicromapEXT 5383 ShaderInvocationReorderNV +5388 ShaderInvocationReorderEXT 5390 BindlessTextureNV 5391 RayQueryPositionFetchKHR 5394 CooperativeVectorNV @@ -180,6 +182,8 @@ 5414 RawAccessChainsNV 5418 RayTracingSpheresGeometryNV 5419 RayTracingLinearSweptSpheresGeometryNV +5423 PushConstantBanksNV +5425 LongVectorEXT 5426 Shader64BitIndexingEXT 5430 CooperativeMatrixReductionsNV 5431 CooperativeMatrixConversionsNV diff --git a/renderdoc/driver/shaders/spirv/all_exts.txt b/renderdoc/driver/shaders/spirv/all_exts.txt index de39a3944..c1cb2e037 100644 --- a/renderdoc/driver/shaders/spirv/all_exts.txt +++ b/renderdoc/driver/shaders/spirv/all_exts.txt @@ -42,11 +42,13 @@ SPV_KHR_workgroup_memory_explicit_layout SPV_EXT_arithmetic_fence SPV_EXT_demote_to_helper_invocation SPV_EXT_descriptor_indexing +SPV_EXT_descriptor_heap SPV_EXT_float8 SPV_EXT_fragment_fully_covered SPV_EXT_fragment_invocation_density SPV_EXT_fragment_shader_interlock SPV_EXT_image_raw10_raw12 +SPV_EXT_long_vector SPV_EXT_mesh_shader SPV_EXT_opacity_micromap SPV_EXT_optnone @@ -58,7 +60,9 @@ SPV_EXT_shader_atomic_float_add SPV_EXT_shader_atomic_float_min_max SPV_EXT_shader_atomic_float16_add SPV_EXT_shader_image_int64 +SPV_EXT_shader_invocation_reorder SPV_EXT_shader_stencil_export +SPV_EXT_shader_subgroup_partitioned SPV_EXT_shader_tile_image SPV_EXT_shader_viewport_index_layer SPV_ALTERA_arbitrary_precision_fixed_point @@ -135,6 +139,7 @@ SPV_NV_fragment_shader_barycentric SPV_NV_geometry_shader_passthrough SPV_NV_linear_swept_spheres SPV_NV_mesh_shader +SPV_NV_push_constant_bank SPV_NV_raw_access_chains SPV_NV_ray_tracing SPV_NV_ray_tracing_motion_blur diff --git a/renderdoc/driver/shaders/spirv/check_extensions.sh b/renderdoc/driver/shaders/spirv/check_extensions.sh index a0cc18d59..3825f859f 100644 --- a/renderdoc/driver/shaders/spirv/check_extensions.sh +++ b/renderdoc/driver/shaders/spirv/check_extensions.sh @@ -6,7 +6,7 @@ unix2dos -q all_exts.txt # sorted by enum value sed -n '/kind.*"Capability",$/,/"category"/p' spirv.core.grammar.json | - grep 'enumerant\>\|value' | paste -sd ' \n' | awk '{print $6" "$3}' | + grep 'enumerant\>\|value' | sed -e '{s#": #" : #g}' | paste -sd ' \n' | awk '{print $6" "$3}' | tr -d '",' | sort -n > all_capabilities.txt unix2dos -q all_capabilities.txt diff --git a/renderdoc/driver/shaders/spirv/extension_support.md b/renderdoc/driver/shaders/spirv/extension_support.md index 633a910de..796201227 100644 --- a/renderdoc/driver/shaders/spirv/extension_support.md +++ b/renderdoc/driver/shaders/spirv/extension_support.md @@ -238,6 +238,8 @@ KHR extensions will definitely be implemented at some point, though KHR extensio ## EXT +* `SPV_EXT_descriptor_heap` + * `DescriptorHeapEXT` * `SPV_EXT_float8` * `Float8EXT` * `Float8CooperativeMatrixEXT` @@ -245,10 +247,16 @@ KHR extensions will definitely be implemented at some point, though KHR extensio * `FragmentShaderSampleInterlockEXT` * `FragmentShaderShadingRateInterlockEXT` * `FragmentShaderPixelInterlockEXT` +* `SPV_EXT_long_vector` + * `LongVectorEXT` * `SPV_EXT_replicated_composites` * `ReplicatedCompositesEXT` * `SPV_EXT_shader_64bit_indexing` * `Shader64BitIndexingEXT` +* `SPV_EXT_shader_invocation_reorder` + * `ShaderInvocationReorderEXT` +* `SPV_EXT_shader_subgroup_partitioned` + * `GroupNonUniformPartitionedEXT` * `SPV_EXT_shader_tile_image` * `TileImageColorReadAccessEXT` * `TileImageDepthReadAccessEXT` @@ -432,6 +440,8 @@ KHR extensions will definitely be implemented at some point, though KHR extensio * `RayTracingLinearSweptSpheresGeometryNV` * `SPV_NV_mesh_shader` * `MeshShadingNV` +* `SPV_NV_push_constant_bank` + * `PushConstantBanksNV` * `SPV_NV_raw_access_chains` * `RawAccessChainsNV` * `SPV_NV_ray_tracing_motion_blur` diff --git a/renderdoc/driver/shaders/spirv/spir-v.xml b/renderdoc/driver/shaders/spirv/spir-v.xml index ba45e3d08..1af07bb27 100644 --- a/renderdoc/driver/shaders/spirv/spir-v.xml +++ b/renderdoc/driver/shaders/spirv/spir-v.xml @@ -140,13 +140,15 @@ + + - + @@ -174,13 +176,15 @@ + + - + diff --git a/renderdoc/driver/shaders/spirv/spirv.core.grammar.json b/renderdoc/driver/shaders/spirv/spirv.core.grammar.json index 74aff15f7..21451e288 100644 --- a/renderdoc/driver/shaders/spirv/spirv.core.grammar.json +++ b/renderdoc/driver/shaders/spirv/spirv.core.grammar.json @@ -4085,7 +4085,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4100,7 +4100,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4115,7 +4115,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4130,7 +4130,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4145,7 +4145,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4160,7 +4160,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4175,7 +4175,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4190,7 +4190,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4205,7 +4205,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4220,7 +4220,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4235,7 +4235,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4250,7 +4250,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4265,7 +4265,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4280,7 +4280,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4295,7 +4295,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -4310,7 +4310,7 @@ { "kind" : "IdRef", "name" : "Value" }, { "kind" : "IdRef", "name" : "ClusterSize", "quantifier" : "?" } ], - "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedNV" ], + "capabilities" : [ "GroupNonUniformArithmetic", "GroupNonUniformClustered", "GroupNonUniformPartitionedEXT" ], "version" : "1.3" }, { @@ -5695,6 +5695,68 @@ "capabilities" : [ "QuadControlKHR" ], "version" : "None" }, + { + "opname" : "OpTypeBufferEXT", + "class" : "Type-Declaration", + "opcode" : 5115, + "operands" : [ + { "kind" : "IdResult" }, + { "kind" : "StorageClass" } + ], + "capabilities": [ "DescriptorHeapEXT" ], + "version" : "None" + }, + { + "opname" : "OpBufferPointerEXT", + "class" : "Memory", + "opcode" : 5119, + "operands" : [ + { "kind" : "IdResultType" }, + { "kind" : "IdResult" }, + { "kind" : "IdRef", "name" : "Buffer" } + ], + "capabilities": [ "DescriptorHeapEXT" ], + "version" : "None" + }, + { + "opname" : "OpUntypedImageTexelPointerEXT", + "class" : "Memory", + "opcode" : 5126, + "operands" : [ + { "kind" : "IdResultType" }, + { "kind" : "IdResult" }, + { "kind" : "IdRef", "name" : "ImageType" }, + { "kind" : "IdRef", "name" : "Image" }, + { "kind" : "IdRef", "name" : "Coordinate" }, + { "kind" : "IdRef", "name" : "Sample" } + ], + "capabilities": [ "DescriptorHeapEXT" ], + "version": "None" + }, + { + "opname" : "OpMemberDecorateIdEXT", + "class" : "Annotation", + "opcode" : 5127, + "operands" : [ + { "kind" : "IdRef", "name" : "Structure Type" }, + { "kind" : "LiteralInteger", "name" : "Member" }, + { "kind" : "Decoration" } + ], + "capabilities": [ "DescriptorHeapEXT" ], + "version" : "None" + }, + { + "opname" : "OpConstantSizeOfEXT", + "class" : "Constant-Creation", + "opcode" : 5129, + "operands" : [ + { "kind" : "IdResultType" }, + { "kind" : "IdResult" }, + { "kind" : "IdRef", "name" : "Type" } + ], + "capabilities": [ "DescriptorHeapEXT" ], + "version" : "None" + }, { "opname" : "OpHitObjectRecordHitMotionNV", "class" : "Reserved", @@ -6168,15 +6230,16 @@ "version" : "None" }, { - "opname" : "OpTypeCooperativeVectorNV", + "opname" : "OpTypeVectorIdEXT", "class" : "Type-Declaration", "opcode" : 5288, + "aliases" : ["OpTypeCooperativeVectorNV"], "operands" : [ { "kind" : "IdResult" }, { "kind" : "IdRef", "name" : "Component Type" }, { "kind" : "IdRef", "name" : "Component Count" } ], - "capabilities" : [ "CooperativeVectorNV" ], + "capabilities" : [ "CooperativeVectorNV", "LongVectorEXT" ], "version" : "None" }, { @@ -6291,16 +6354,16 @@ "version" : "None" }, { - "opname" : "OpGroupNonUniformPartitionNV", + "opname" : "OpGroupNonUniformPartitionEXT", "class" : "Non-Uniform", + "aliases" : ["OpGroupNonUniformPartitionNV"], "opcode" : 5296, "operands" : [ { "kind" : "IdResultType" }, { "kind" : "IdResult" }, { "kind" : "IdRef", "name" : "Value" } ], - "capabilities" : [ "GroupNonUniformPartitionedNV" ], - "extensions" : [ "SPV_NV_shader_subgroup_partitioned" ], + "capabilities" : [ "GroupNonUniformPartitionedEXT" ], "version" : "None" }, { @@ -6374,6 +6437,411 @@ "capabilities" : [ "CooperativeVectorNV" ], "version" : "None" }, + { + "opname" : "OpHitObjectRecordFromQueryEXT", + "class" : "Reserved", + "opcode" : 5304, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Ray Query" }, + { "kind" : "IdRef", "name" : "SBT Record Index" }, + { "kind" : "IdRef", "name" : "Hit Object Attributes" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectRecordMissEXT", + "class" : "Reserved", + "opcode" : 5305, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Ray Flags" }, + { "kind" : "IdRef", "name" : "Miss Index" }, + { "kind" : "IdRef", "name" : "Ray Origin" }, + { "kind" : "IdRef", "name" : "Ray Tmin" }, + { "kind" : "IdRef", "name" : "Ray Direction" }, + { "kind" : "IdRef", "name" : "Ray Tmax" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectRecordMissMotionEXT", + "class" : "Reserved", + "opcode" : 5306, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Ray Flags" }, + { "kind" : "IdRef", "name" : "Miss Index" }, + { "kind" : "IdRef", "name" : "Ray Origin" }, + { "kind" : "IdRef", "name" : "Ray Tmin" }, + { "kind" : "IdRef", "name" : "Ray Direction" }, + { "kind" : "IdRef", "name" : "Ray Tmax" }, + { "kind" : "IdRef", "name" : "Current Time" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT", "RayTracingMotionBlurNV" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetIntersectionTriangleVertexPositionsEXT", + "class" : "Reserved", + "opcode" : 5307, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetRayFlagsEXT", + "class" : "Reserved", + "opcode" : 5308, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectSetShaderBindingTableRecordIndexEXT", + "class" : "Reserved", + "opcode" : 5309, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "SBT Record Index" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectReorderExecuteShaderEXT", + "class" : "Reserved", + "opcode" : 5310, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Payload" }, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Hint" }, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Bits" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectTraceReorderExecuteEXT", + "class" : "Reserved", + "opcode" : 5311, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Acceleration Structure"}, + { "kind" : "IdRef", "name" : "Ray Flags"}, + { "kind" : "IdRef", "name" : "Cull Mask"}, + { "kind" : "IdRef", "name" : "SBT Offset"}, + { "kind" : "IdRef", "name" : "SBT Stride"}, + { "kind" : "IdRef", "name" : "Miss Index"}, + { "kind" : "IdRef", "name" : "Ray Origin"}, + { "kind" : "IdRef", "name" : "Ray Tmin"}, + { "kind" : "IdRef", "name" : "Ray Direction"}, + { "kind" : "IdRef", "name" : "Ray Tmax"}, + { "kind" : "IdRef", "name" : "Payload"}, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Hint" }, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Bits" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectTraceMotionReorderExecuteEXT", + "class" : "Reserved", + "opcode" : 5312, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Acceleration Structure"}, + { "kind" : "IdRef", "name" : "Ray Flags"}, + { "kind" : "IdRef", "name" : "Cull Mask"}, + { "kind" : "IdRef", "name" : "SBT Offset"}, + { "kind" : "IdRef", "name" : "SBT Stride"}, + { "kind" : "IdRef", "name" : "Miss Index"}, + { "kind" : "IdRef", "name" : "Ray Origin"}, + { "kind" : "IdRef", "name" : "Ray Tmin"}, + { "kind" : "IdRef", "name" : "Ray Direction"}, + { "kind" : "IdRef", "name" : "Ray Tmax"}, + { "kind" : "IdRef", "name" : "Current Time"}, + { "kind" : "IdRef", "name" : "Payload"}, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Hint" }, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Bits" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT", "RayTracingMotionBlurNV" ], + "version" : "None" + }, + { + "opname" : "OpTypeHitObjectEXT", + "class" : "Type-Declaration", + "opcode" : 5313, + "operands" : [ + { "kind" : "IdResult" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpReorderThreadWithHintEXT", + "class" : "Reserved", + "opcode" : 5314, + "operands" : [ + { "kind" : "IdRef", "name" : "Hint" }, + { "kind" : "IdRef", "name" : "Bits" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpReorderThreadWithHitObjectEXT", + "class" : "Reserved", + "opcode" : 5315, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Hint" }, + { "kind" : "IdRef", "quantifier" : "?", "name" : "Bits" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectTraceRayEXT", + "class" : "Reserved", + "opcode" : 5316, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Acceleration Structure"}, + { "kind" : "IdRef", "name" : "Ray Flags"}, + { "kind" : "IdRef", "name" : "Cull Mask"}, + { "kind" : "IdRef", "name" : "SBT Offset"}, + { "kind" : "IdRef", "name" : "SBT Stride"}, + { "kind" : "IdRef", "name" : "Miss Index"}, + { "kind" : "IdRef", "name" : "Ray Origin"}, + { "kind" : "IdRef", "name" : "Ray Tmin"}, + { "kind" : "IdRef", "name" : "Ray Direction"}, + { "kind" : "IdRef", "name" : "Ray Tmax"}, + { "kind" : "IdRef", "name" : "Payload"} + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectTraceRayMotionEXT", + "class" : "Reserved", + "opcode" : 5317, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Acceleration Structure"}, + { "kind" : "IdRef", "name" : "Ray Flags"}, + { "kind" : "IdRef", "name" : "Cull Mask"}, + { "kind" : "IdRef", "name" : "SBT Offset"}, + { "kind" : "IdRef", "name" : "SBT Stride"}, + { "kind" : "IdRef", "name" : "Miss Index"}, + { "kind" : "IdRef", "name" : "Ray Origin"}, + { "kind" : "IdRef", "name" : "Ray Tmin"}, + { "kind" : "IdRef", "name" : "Ray Direction"}, + { "kind" : "IdRef", "name" : "Ray Tmax"}, + { "kind" : "IdRef", "name" : "Current Time"}, + { "kind" : "IdRef", "name" : "Payload"} + ], + "capabilities" : [ "ShaderInvocationReorderEXT", "RayTracingMotionBlurNV" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectRecordEmptyEXT", + "class" : "Reserved", + "opcode" : 5318, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectExecuteShaderEXT", + "class" : "Reserved", + "opcode" : 5319, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Payload" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetCurrentTimeEXT", + "class" : "Reserved", + "opcode" : 5320, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" , "RayTracingMotionBlurNV" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetAttributesEXT", + "class" : "Reserved", + "opcode" : 5321, + "operands" : [ + { "kind" : "IdRef", "name" : "Hit Object" }, + { "kind" : "IdRef", "name" : "Hit Object Attribute" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetHitKindEXT", + "class" : "Reserved", + "opcode" : 5322, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetPrimitiveIndexEXT", + "class" : "Reserved", + "opcode" : 5323, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetGeometryIndexEXT", + "class" : "Reserved", + "opcode" : 5324, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetInstanceIdEXT", + "class" : "Reserved", + "opcode" : 5325, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetInstanceCustomIndexEXT", + "class" : "Reserved", + "opcode" : 5326, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetObjectRayOriginEXT", + "class" : "Reserved", + "opcode" : 5327, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetObjectRayDirectionEXT", + "class" : "Reserved", + "opcode" : 5328, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetWorldRayDirectionEXT", + "class" : "Reserved", + "opcode" : 5329, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetWorldRayOriginEXT", + "class" : "Reserved", + "opcode" : 5330, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetObjectToWorldEXT", + "class" : "Reserved", + "opcode" : 5331, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetWorldToObjectEXT", + "class" : "Reserved", + "opcode" : 5332, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetRayTMaxEXT", + "class" : "Reserved", + "opcode" : 5333, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, { "opname" : "OpReportIntersectionKHR", "class" : "Reserved", @@ -6549,6 +7017,78 @@ "capabilities" : [ "RayTracingClusterAccelerationStructureNV" ], "version" : "None" }, + { + "opname" : "OpHitObjectGetRayTMinEXT", + "class" : "Reserved", + "opcode" : 5347, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetShaderBindingTableRecordIndexEXT", + "class" : "Reserved", + "opcode" : 5348, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectGetShaderRecordBufferHandleEXT", + "class" : "Reserved", + "opcode" : 5349, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectIsEmptyEXT", + "class" : "Reserved", + "opcode" : 5350, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectIsHitEXT", + "class" : "Reserved", + "opcode" : 5351, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "opname" : "OpHitObjectIsMissEXT", + "class" : "Reserved", + "opcode" : 5352, + "operands" : [ + { "kind" : "IdResultType"}, + { "kind" : "IdResult"}, + { "kind" : "IdRef", "name" : "Hit Object" } + ], + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, { "opname" : "OpTypeCooperativeMatrixNV", "class" : "Type-Declaration", @@ -13124,6 +13664,12 @@ "capabilities" : [ "MeshShadingEXT" ], "version" : "1.4" }, + { + "enumerant" : "HitObjectAttributeEXT", + "value" : 5411, + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, { "enumerant" : "CodeSectionINTEL", "value" : 5605, @@ -14493,6 +15039,24 @@ "provisional" : true, "version" : "None" }, + { + "enumerant" : "ArrayStrideIdEXT", + "value" : 5124, + "capabilities": [ "DescriptorHeapEXT" ], + "parameters" : [ + { "kind" : "IdRef", "name" : "Array Stride" } + ], + "version" : "None" + }, + { + "enumerant" : "OffsetIdEXT", + "value" : 5125, + "capabilities": [ "DescriptorHeapEXT" ], + "parameters" : [ + { "kind" : "IdRef", "name" : "Byte Offset" } + ], + "version" : "None" + }, { "enumerant" : "OverrideCoverageNV", "value" : 5248, @@ -14577,12 +15141,36 @@ "extensions" : [ "SPV_EXT_physical_storage_buffer", "SPV_KHR_physical_storage_buffer" ], "version" : "1.5" }, + { + "enumerant": "MemberOffsetNV", + "value": 5358, + "parameters" : [ + { "kind" : "LiteralInteger", "name" : "memberOffset" } + ], + "capabilities": [ "PushConstantBanksNV" ], + "version": "None" + }, { "enumerant" : "HitObjectShaderRecordBufferNV", "value" : 5386, "capabilities" : [ "ShaderInvocationReorderNV" ], "version" : "None" }, + { + "enumerant" : "HitObjectShaderRecordBufferEXT", + "value" : 5389, + "capabilities" : [ "ShaderInvocationReorderEXT" ], + "version" : "None" + }, + { + "enumerant" : "BankNV", + "value" : 5397, + "parameters" : [ + { "kind" : "LiteralInteger", "name" : "Bank" } + ], + "capabilities" : [ "PushConstantBanksNV" ], + "version" : "None" + }, { "enumerant" : "BindlessSamplerNV", "value" : 5398, @@ -15639,6 +16227,18 @@ "provisional" : true, "version" : "None" }, + { + "enumerant" : "SamplerHeapEXT", + "value" : 5122, + "capabilities" : [ "DescriptorHeapEXT" ], + "version" : "None" + }, + { + "enumerant" : "ResourceHeapEXT", + "value" : 5123, + "capabilities" : [ "DescriptorHeapEXT" ], + "version" : "None" + }, { "enumerant" : "ViewportMaskNV", "value" : 5253, @@ -16111,24 +16711,24 @@ "version" : "1.3" }, { - "enumerant" : "PartitionedReduceNV", + "enumerant" : "PartitionedReduceEXT", + "aliases" : ["PartitionedReduceNV"], "value" : 6, - "capabilities" : [ "GroupNonUniformPartitionedNV" ], - "extensions" : [ "SPV_NV_shader_subgroup_partitioned" ], + "capabilities" : [ "GroupNonUniformPartitionedEXT" ], "version" : "None" }, { - "enumerant" : "PartitionedInclusiveScanNV", + "enumerant" : "PartitionedInclusiveScanEXT", + "aliases" : ["PartitionedInclusiveScanNV"], "value" : 7, - "capabilities" : [ "GroupNonUniformPartitionedNV" ], - "extensions" : [ "SPV_NV_shader_subgroup_partitioned" ], + "capabilities" : [ "GroupNonUniformPartitionedEXT" ], "version" : "None" }, { - "enumerant" : "PartitionedExclusiveScanNV", + "enumerant" : "PartitionedExclusiveScanEXT", + "aliases" : ["PartitionedExclusiveScanNV"], "value" : 8, - "capabilities" : [ "GroupNonUniformPartitionedNV" ], - "extensions" : [ "SPV_NV_shader_subgroup_partitioned" ], + "capabilities" : [ "GroupNonUniformPartitionedEXT" ], "version" : "None" } ] @@ -16963,6 +17563,13 @@ "extensions" : [ "SPV_KHR_bfloat16" ], "version" : "None" }, + { + "enumerant" : "DescriptorHeapEXT", + "value": 5128, + "capabilities" : [ "UntypedPointersKHR" ], + "extensions" : [ "SPV_EXT_descriptor_heap" ], + "version" : "None" + }, { "enumerant" : "SampleMaskOverrideCoverageNV", "value" : 5249, @@ -17057,9 +17664,10 @@ "version" : "None" }, { - "enumerant" : "GroupNonUniformPartitionedNV", + "enumerant" : "GroupNonUniformPartitionedEXT", + "aliases" : ["GroupNonUniformPartitionedNV"], "value" : 5297, - "extensions" : [ "SPV_NV_shader_subgroup_partitioned" ], + "extensions" : [ "SPV_NV_shader_subgroup_partitioned", "SPV_EXT_shader_subgroup_partitioned" ], "version" : "None" }, { @@ -17280,6 +17888,13 @@ "extensions" : [ "SPV_NV_shader_invocation_reorder" ], "version" : "None" }, + { + "enumerant" : "ShaderInvocationReorderEXT", + "value" : 5388, + "capabilities" : [ "RayTracingKHR" ], + "extensions" : [ "SPV_EXT_shader_invocation_reorder" ], + "version" : "None" + }, { "enumerant" : "BindlessTextureNV", "value" : 5390, @@ -17330,6 +17945,19 @@ "extensions" : [ "SPV_NV_linear_swept_spheres" ], "version" : "None" }, + { + "enumerant" : "PushConstantBanksNV", + "value" : 5423, + "capabilities" : [ "Shader" ], + "extensions" : [ "SPV_NV_push_constant_bank" ], + "version" : "None" + }, + { + "enumerant" : "LongVectorEXT", + "value" : 5425, + "extensions" : [ "SPV_EXT_long_vector" ], + "version" : "None" + }, { "enumerant" : "Shader64BitIndexingEXT", "value" : 5426, @@ -18062,11 +18690,13 @@ { "enumerant" : "RowBlockedInterleavedARM", "value" : 4202, + "capabilities" : [ "CooperativeMatrixLayoutsARM" ], "version" : "None" }, { "enumerant" : "ColumnBlockedInterleavedARM", "value" : 4203, + "capabilities" : [ "CooperativeMatrixLayoutsARM" ], "version" : "None" } ] diff --git a/renderdoc/driver/shaders/spirv/spirv_debug.cpp b/renderdoc/driver/shaders/spirv/spirv_debug.cpp index a77caf429..42a531cfe 100644 --- a/renderdoc/driver/shaders/spirv/spirv_debug.cpp +++ b/renderdoc/driver/shaders/spirv/spirv_debug.cpp @@ -5142,7 +5142,7 @@ void ThreadState::StepNext(bool useDebugState, const uint32_t steps, case Op::FragmentMaskFetchAMD: case Op::FragmentFetchAMD: case Op::ImageSampleFootprintNV: - case Op::GroupNonUniformPartitionNV: + case Op::GroupNonUniformPartitionEXT: case Op::WritePackedPrimitiveIndices4x8NV: case Op::ReportIntersectionKHR: case Op::IgnoreIntersectionNV: @@ -5346,6 +5346,44 @@ void ThreadState::StepNext(bool useDebugState, const uint32_t steps, case Op::CompositeExtractCoopMatQCOM: case Op::ExtractSubArrayQCOM: case Op::FmaKHR: + case Op::BufferPointerEXT: + case Op::UntypedImageTexelPointerEXT: + case Op::ConstantSizeOfEXT: + case Op::HitObjectRecordFromQueryEXT: + case Op::HitObjectRecordMissMotionEXT: + case Op::HitObjectGetIntersectionTriangleVertexPositionsEXT: + case Op::HitObjectGetRayFlagsEXT: + case Op::HitObjectSetShaderBindingTableRecordIndexEXT: + case Op::HitObjectReorderExecuteShaderEXT: + case Op::HitObjectTraceMotionReorderExecuteEXT: + case Op::ReorderThreadWithHintEXT: + case Op::ReorderThreadWithHitObjectEXT: + case Op::HitObjectTraceRayEXT: + case Op::HitObjectTraceRayMotionEXT: + case Op::HitObjectRecordEmptyEXT: + case Op::HitObjectExecuteShaderEXT: + case Op::HitObjectGetCurrentTimeEXT: + case Op::HitObjectRecordMissEXT: + case Op::HitObjectTraceReorderExecuteEXT: + case Op::HitObjectGetAttributesEXT: + case Op::HitObjectGetPrimitiveIndexEXT: + case Op::HitObjectGetGeometryIndexEXT: + case Op::HitObjectGetInstanceIdEXT: + case Op::HitObjectGetInstanceCustomIndexEXT: + case Op::HitObjectGetHitKindEXT: + case Op::HitObjectGetObjectRayOriginEXT: + case Op::HitObjectGetObjectRayDirectionEXT: + case Op::HitObjectGetWorldRayDirectionEXT: + case Op::HitObjectGetWorldRayOriginEXT: + case Op::HitObjectGetObjectToWorldEXT: + case Op::HitObjectGetWorldToObjectEXT: + case Op::HitObjectGetRayTMaxEXT: + case Op::HitObjectGetRayTMinEXT: + case Op::HitObjectGetShaderBindingTableRecordIndexEXT: + case Op::HitObjectGetShaderRecordBufferHandleEXT: + case Op::HitObjectIsEmptyEXT: + case Op::HitObjectIsHitEXT: + case Op::HitObjectIsMissEXT: { RDCERR("Unsupported extension opcode used %s", ToStr(opdata.op).c_str()); @@ -5415,12 +5453,15 @@ void ThreadState::StepNext(bool useDebugState, const uint32_t steps, case Op::TypeNodePayloadArrayAMDX: case Op::ConstantStringAMDX: case Op::SpecConstantStringAMDX: - case Op::TypeCooperativeVectorNV: + case Op::TypeVectorIdEXT: case Op::TypeTensorLayoutNV: case Op::TypeTensorViewNV: case Op::TypeGraphARM: case Op::TypeHitObjectNV: case Op::TypeCooperativeMatrixKHR: + case Op::TypeBufferEXT: + case Op::MemberDecorateIdEXT: + case Op::TypeHitObjectEXT: { RDCERR("Encountered unexpected global SPIR-V operation %s", ToStr(opdata.op).c_str()); break; diff --git a/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp b/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp index c27098867..e1f3be1aa 100644 --- a/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp +++ b/renderdoc/driver/shaders/spirv/spirv_debug_setup.cpp @@ -765,6 +765,34 @@ void Reflector::CheckDebuggable(bool &debuggable, rdcstr &debugStatus) const break; } + // SPV_EXT_shader_invocation_reorder + case Capability::ShaderInvocationReorderEXT: + { + supported = false; + break; + } + + // SPV_EXT_shader_subgroup_partitioned + case Capability::GroupNonUniformPartitionedEXT: + { + supported = false; + break; + } + + // SPV_EXT_long_vector + case Capability::LongVectorEXT: + { + supported = false; + break; + } + + // SPV_EXT_descriptor_heap + case Capability::DescriptorHeapEXT: + { + supported = false; + break; + } + // no plans to support these - mostly Kernel/OpenCL related or vendor extensions case Capability::Addresses: case Capability::Linkage: @@ -792,7 +820,6 @@ void Reflector::CheckDebuggable(bool &debuggable, rdcstr &debugStatus) const case Capability::PerViewAttributesNV: case Capability::MeshShadingNV: case Capability::ImageFootprintNV: - case Capability::GroupNonUniformPartitionedNV: case Capability::CooperativeMatrixNV: case Capability::ShaderSMBuiltinsNV: case Capability::SubgroupShuffleINTEL: @@ -899,6 +926,7 @@ void Reflector::CheckDebuggable(bool &debuggable, rdcstr &debugStatus) const case Capability::BindlessImagesINTEL: case Capability::RayTracingNV: case Capability::ShaderInvocationReorderNV: + case Capability::PushConstantBanksNV: case Capability::Max: case Capability::Invalid: { diff --git a/renderdoc/driver/shaders/spirv/spirv_gen.cpp b/renderdoc/driver/shaders/spirv/spirv_gen.cpp index dd06e9675..d61a48c6c 100644 --- a/renderdoc/driver/shaders/spirv/spirv_gen.cpp +++ b/renderdoc/driver/shaders/spirv/spirv_gen.cpp @@ -461,8 +461,8 @@ rdcstr DoStringise(const rdcspv::StorageClass &el) STRINGISE_ENUM_CLASS(IncomingRayPayloadKHR); STRINGISE_ENUM_CLASS(ShaderRecordBufferKHR); STRINGISE_ENUM_CLASS(PhysicalStorageBuffer); - STRINGISE_ENUM_CLASS(HitObjectAttributeNV); STRINGISE_ENUM_CLASS(TaskPayloadWorkgroupEXT); + STRINGISE_ENUM_CLASS(HitObjectAttributeEXT); STRINGISE_ENUM_CLASS(CodeSectionINTEL); STRINGISE_ENUM_CLASS(DeviceOnlyALTERA); STRINGISE_ENUM_CLASS(HostOnlyALTERA); @@ -814,6 +814,8 @@ rdcstr DoStringise(const rdcspv::Decoration &el) STRINGISE_ENUM_CLASS(PayloadNodeSparseArrayAMDX); STRINGISE_ENUM_CLASS(PayloadNodeArraySizeAMDX); STRINGISE_ENUM_CLASS(PayloadDispatchIndirectAMDX); + STRINGISE_ENUM_CLASS(ArrayStrideIdEXT); + STRINGISE_ENUM_CLASS(OffsetIdEXT); STRINGISE_ENUM_CLASS(OverrideCoverageNV); STRINGISE_ENUM_CLASS(PassthroughNV); STRINGISE_ENUM_CLASS(ViewportRelativeNV); @@ -825,7 +827,9 @@ rdcstr DoStringise(const rdcspv::Decoration &el) STRINGISE_ENUM_CLASS(NonUniform); STRINGISE_ENUM_CLASS(RestrictPointer); STRINGISE_ENUM_CLASS(AliasedPointer); - STRINGISE_ENUM_CLASS(HitObjectShaderRecordBufferNV); + STRINGISE_ENUM_CLASS(MemberOffsetNV); + STRINGISE_ENUM_CLASS(HitObjectShaderRecordBufferEXT); + STRINGISE_ENUM_CLASS(BankNV); STRINGISE_ENUM_CLASS(BindlessSamplerNV); STRINGISE_ENUM_CLASS(BindlessImageNV); STRINGISE_ENUM_CLASS(BoundSamplerNV); @@ -975,6 +979,8 @@ rdcstr DoStringise(const rdcspv::BuiltIn &el) STRINGISE_ENUM_CLASS(FragStencilRefEXT); STRINGISE_ENUM_CLASS(RemainingRecursionLevelsAMDX); STRINGISE_ENUM_CLASS(ShaderIndexAMDX); + STRINGISE_ENUM_CLASS(SamplerHeapEXT); + STRINGISE_ENUM_CLASS(ResourceHeapEXT); STRINGISE_ENUM_CLASS(ViewportMaskNV); STRINGISE_ENUM_CLASS(SecondaryPositionNV); STRINGISE_ENUM_CLASS(SecondaryViewportMaskNV); @@ -1059,9 +1065,9 @@ rdcstr DoStringise(const rdcspv::GroupOperation &el) STRINGISE_ENUM_CLASS(InclusiveScan); STRINGISE_ENUM_CLASS(ExclusiveScan); STRINGISE_ENUM_CLASS(ClusteredReduce); - STRINGISE_ENUM_CLASS(PartitionedReduceNV); - STRINGISE_ENUM_CLASS(PartitionedInclusiveScanNV); - STRINGISE_ENUM_CLASS(PartitionedExclusiveScanNV); + STRINGISE_ENUM_CLASS(PartitionedReduceEXT); + STRINGISE_ENUM_CLASS(PartitionedInclusiveScanEXT); + STRINGISE_ENUM_CLASS(PartitionedExclusiveScanEXT); } END_ENUM_STRINGISE(); } @@ -1214,6 +1220,7 @@ rdcstr DoStringise(const rdcspv::Capability &el) STRINGISE_ENUM_CLASS(BFloat16TypeKHR); STRINGISE_ENUM_CLASS(BFloat16DotProductKHR); STRINGISE_ENUM_CLASS(BFloat16CooperativeMatrixKHR); + STRINGISE_ENUM_CLASS(DescriptorHeapEXT); STRINGISE_ENUM_CLASS(SampleMaskOverrideCoverageNV); STRINGISE_ENUM_CLASS(GeometryShaderPassthroughNV); STRINGISE_ENUM_CLASS(ShaderViewportIndexLayerEXT); @@ -1226,7 +1233,7 @@ rdcstr DoStringise(const rdcspv::Capability &el) STRINGISE_ENUM_CLASS(FragmentBarycentricKHR); STRINGISE_ENUM_CLASS(ComputeDerivativeGroupQuadsKHR); STRINGISE_ENUM_CLASS(FragmentDensityEXT); - STRINGISE_ENUM_CLASS(GroupNonUniformPartitionedNV); + STRINGISE_ENUM_CLASS(GroupNonUniformPartitionedEXT); STRINGISE_ENUM_CLASS(ShaderNonUniform); STRINGISE_ENUM_CLASS(RuntimeDescriptorArray); STRINGISE_ENUM_CLASS(InputAttachmentArrayDynamicIndexing); @@ -1253,7 +1260,7 @@ rdcstr DoStringise(const rdcspv::Capability &el) STRINGISE_ENUM_CLASS(DemoteToHelperInvocation); STRINGISE_ENUM_CLASS(DisplacementMicromapNV); STRINGISE_ENUM_CLASS(RayTracingOpacityMicromapEXT); - STRINGISE_ENUM_CLASS(ShaderInvocationReorderNV); + STRINGISE_ENUM_CLASS(ShaderInvocationReorderEXT); STRINGISE_ENUM_CLASS(BindlessTextureNV); STRINGISE_ENUM_CLASS(RayQueryPositionFetchKHR); STRINGISE_ENUM_CLASS(CooperativeVectorNV); @@ -1262,6 +1269,8 @@ rdcstr DoStringise(const rdcspv::Capability &el) STRINGISE_ENUM_CLASS(RawAccessChainsNV); STRINGISE_ENUM_CLASS(RayTracingSpheresGeometryNV); STRINGISE_ENUM_CLASS(RayTracingLinearSweptSpheresGeometryNV); + STRINGISE_ENUM_CLASS(PushConstantBanksNV); + STRINGISE_ENUM_CLASS(LongVectorEXT); STRINGISE_ENUM_CLASS(Shader64BitIndexingEXT); STRINGISE_ENUM_CLASS(CooperativeMatrixReductionsNV); STRINGISE_ENUM_CLASS(CooperativeMatrixConversionsNV); @@ -2063,6 +2072,11 @@ rdcstr DoStringise(const rdcspv::Op &el) STRINGISE_ENUM_CLASS(SpecConstantStringAMDX); STRINGISE_ENUM_CLASS(GroupNonUniformQuadAllKHR); STRINGISE_ENUM_CLASS(GroupNonUniformQuadAnyKHR); + STRINGISE_ENUM_CLASS(TypeBufferEXT); + STRINGISE_ENUM_CLASS(BufferPointerEXT); + STRINGISE_ENUM_CLASS(UntypedImageTexelPointerEXT); + STRINGISE_ENUM_CLASS(MemberDecorateIdEXT); + STRINGISE_ENUM_CLASS(ConstantSizeOfEXT); STRINGISE_ENUM_CLASS(HitObjectRecordHitMotionNV); STRINGISE_ENUM_CLASS(HitObjectRecordHitWithIndexMotionNV); STRINGISE_ENUM_CLASS(HitObjectRecordMissMotionNV); @@ -2097,7 +2111,7 @@ rdcstr DoStringise(const rdcspv::Op &el) STRINGISE_ENUM_CLASS(ReorderThreadWithHintNV); STRINGISE_ENUM_CLASS(TypeHitObjectNV); STRINGISE_ENUM_CLASS(ImageSampleFootprintNV); - STRINGISE_ENUM_CLASS(TypeCooperativeVectorNV); + STRINGISE_ENUM_CLASS(TypeVectorIdEXT); STRINGISE_ENUM_CLASS(CooperativeVectorMatrixMulNV); STRINGISE_ENUM_CLASS(CooperativeVectorOuterProductAccumulateNV); STRINGISE_ENUM_CLASS(CooperativeVectorReduceSumAccumulateNV); @@ -2105,12 +2119,42 @@ rdcstr DoStringise(const rdcspv::Op &el) STRINGISE_ENUM_CLASS(CooperativeMatrixConvertNV); STRINGISE_ENUM_CLASS(EmitMeshTasksEXT); STRINGISE_ENUM_CLASS(SetMeshOutputsEXT); - STRINGISE_ENUM_CLASS(GroupNonUniformPartitionNV); + STRINGISE_ENUM_CLASS(GroupNonUniformPartitionEXT); STRINGISE_ENUM_CLASS(WritePackedPrimitiveIndices4x8NV); STRINGISE_ENUM_CLASS(FetchMicroTriangleVertexPositionNV); STRINGISE_ENUM_CLASS(FetchMicroTriangleVertexBarycentricNV); STRINGISE_ENUM_CLASS(CooperativeVectorLoadNV); STRINGISE_ENUM_CLASS(CooperativeVectorStoreNV); + STRINGISE_ENUM_CLASS(HitObjectRecordFromQueryEXT); + STRINGISE_ENUM_CLASS(HitObjectRecordMissEXT); + STRINGISE_ENUM_CLASS(HitObjectRecordMissMotionEXT); + STRINGISE_ENUM_CLASS(HitObjectGetIntersectionTriangleVertexPositionsEXT); + STRINGISE_ENUM_CLASS(HitObjectGetRayFlagsEXT); + STRINGISE_ENUM_CLASS(HitObjectSetShaderBindingTableRecordIndexEXT); + STRINGISE_ENUM_CLASS(HitObjectReorderExecuteShaderEXT); + STRINGISE_ENUM_CLASS(HitObjectTraceReorderExecuteEXT); + STRINGISE_ENUM_CLASS(HitObjectTraceMotionReorderExecuteEXT); + STRINGISE_ENUM_CLASS(TypeHitObjectEXT); + STRINGISE_ENUM_CLASS(ReorderThreadWithHintEXT); + STRINGISE_ENUM_CLASS(ReorderThreadWithHitObjectEXT); + STRINGISE_ENUM_CLASS(HitObjectTraceRayEXT); + STRINGISE_ENUM_CLASS(HitObjectTraceRayMotionEXT); + STRINGISE_ENUM_CLASS(HitObjectRecordEmptyEXT); + STRINGISE_ENUM_CLASS(HitObjectExecuteShaderEXT); + STRINGISE_ENUM_CLASS(HitObjectGetCurrentTimeEXT); + STRINGISE_ENUM_CLASS(HitObjectGetAttributesEXT); + STRINGISE_ENUM_CLASS(HitObjectGetHitKindEXT); + STRINGISE_ENUM_CLASS(HitObjectGetPrimitiveIndexEXT); + STRINGISE_ENUM_CLASS(HitObjectGetGeometryIndexEXT); + STRINGISE_ENUM_CLASS(HitObjectGetInstanceIdEXT); + STRINGISE_ENUM_CLASS(HitObjectGetInstanceCustomIndexEXT); + STRINGISE_ENUM_CLASS(HitObjectGetObjectRayOriginEXT); + STRINGISE_ENUM_CLASS(HitObjectGetObjectRayDirectionEXT); + STRINGISE_ENUM_CLASS(HitObjectGetWorldRayDirectionEXT); + STRINGISE_ENUM_CLASS(HitObjectGetWorldRayOriginEXT); + STRINGISE_ENUM_CLASS(HitObjectGetObjectToWorldEXT); + STRINGISE_ENUM_CLASS(HitObjectGetWorldToObjectEXT); + STRINGISE_ENUM_CLASS(HitObjectGetRayTMaxEXT); STRINGISE_ENUM_CLASS(ReportIntersectionKHR); STRINGISE_ENUM_CLASS(IgnoreIntersectionNV); STRINGISE_ENUM_CLASS(TerminateRayNV); @@ -2122,6 +2166,12 @@ rdcstr DoStringise(const rdcspv::Op &el) STRINGISE_ENUM_CLASS(ExecuteCallableNV); STRINGISE_ENUM_CLASS(RayQueryGetIntersectionClusterIdNV); STRINGISE_ENUM_CLASS(HitObjectGetClusterIdNV); + STRINGISE_ENUM_CLASS(HitObjectGetRayTMinEXT); + STRINGISE_ENUM_CLASS(HitObjectGetShaderBindingTableRecordIndexEXT); + STRINGISE_ENUM_CLASS(HitObjectGetShaderRecordBufferHandleEXT); + STRINGISE_ENUM_CLASS(HitObjectIsEmptyEXT); + STRINGISE_ENUM_CLASS(HitObjectIsHitEXT); + STRINGISE_ENUM_CLASS(HitObjectIsMissEXT); STRINGISE_ENUM_CLASS(TypeCooperativeMatrixNV); STRINGISE_ENUM_CLASS(CooperativeMatrixLoadNV); STRINGISE_ENUM_CLASS(CooperativeMatrixStoreNV); @@ -2576,8 +2626,16 @@ rdcstr ParamToStr(const std::function &idName, const rdcspv: ret += "(" + idName(el.payloadNodeBaseIndexAMDX) + ")"; break; case Decoration::PayloadNodeArraySizeAMDX: ret += "(" + idName(el.payloadNodeArraySizeAMDX) + ")"; break; + case Decoration::ArrayStrideIdEXT: + ret += "(" + idName(el.arrayStrideIdEXT) + ")"; break; + case Decoration::OffsetIdEXT: + ret += "(" + idName(el.offsetIdEXT) + ")"; break; case Decoration::SecondaryViewportRelativeNV: ret += "(" + ToStr(el.secondaryViewportRelativeNV) + ")"; break; + case Decoration::MemberOffsetNV: + ret += "(" + ToStr(el.memberOffsetNV) + ")"; break; + case Decoration::BankNV: + ret += "(" + ToStr(el.bankNV) + ")"; break; case Decoration::SIMTCallINTEL: ret += "(" + ToStr(el.sIMTCallINTEL) + ")"; break; case Decoration::FuncParamIOKindINTEL: @@ -5136,6 +5194,30 @@ void OpDecoder::ForEachID(const ConstIter &it, const std::function } }; +template<> +struct DecorationParam +{ + Id arrayStrideIdEXT; + DecorationParam(Id arrayStrideIdEXTParam) { arrayStrideIdEXT = arrayStrideIdEXTParam; } + operator DecorationAndParamData() + { + DecorationAndParamData ret(Decoration::ArrayStrideIdEXT); + ret.arrayStrideIdEXT = arrayStrideIdEXT; + return ret; + } +}; + +template<> +struct DecorationParam +{ + Id offsetIdEXT; + DecorationParam(Id offsetIdEXTParam) { offsetIdEXT = offsetIdEXTParam; } + operator DecorationAndParamData() + { + DecorationAndParamData ret(Decoration::OffsetIdEXT); + ret.offsetIdEXT = offsetIdEXT; + return ret; + } +}; + template<> struct DecorationParam { @@ -1869,6 +1895,32 @@ struct DecorationParam } }; +template<> +struct DecorationParam +{ + uint32_t memberOffsetNV; + DecorationParam(uint32_t memberOffsetNVParam) { memberOffsetNV = memberOffsetNVParam; } + operator DecorationAndParamData() + { + DecorationAndParamData ret(Decoration::MemberOffsetNV); + ret.memberOffsetNV = memberOffsetNV; + return ret; + } +}; + +template<> +struct DecorationParam +{ + uint32_t bankNV; + DecorationParam(uint32_t bankNVParam) { bankNV = bankNVParam; } + operator DecorationAndParamData() + { + DecorationAndParamData ret(Decoration::BankNV); + ret.bankNV = bankNV; + return ret; + } +}; + template<> struct DecorationParam { @@ -2503,10 +2555,26 @@ inline DecorationAndParamData DecodeParam(const ConstIter &it, uint32_t &word) ret.payloadNodeArraySizeAMDX = Id::fromWord(it.word(word)); word += 1; break; + case Decoration::ArrayStrideIdEXT: + ret.arrayStrideIdEXT = Id::fromWord(it.word(word)); + word += 1; + break; + case Decoration::OffsetIdEXT: + ret.offsetIdEXT = Id::fromWord(it.word(word)); + word += 1; + break; case Decoration::SecondaryViewportRelativeNV: ret.secondaryViewportRelativeNV = (uint32_t)it.word(word); word += 1; break; + case Decoration::MemberOffsetNV: + ret.memberOffsetNV = (uint32_t)it.word(word); + word += 1; + break; + case Decoration::BankNV: + ret.bankNV = (uint32_t)it.word(word); + word += 1; + break; case Decoration::SIMTCallINTEL: ret.sIMTCallINTEL = (uint32_t)it.word(word); word += 1; @@ -2762,9 +2830,21 @@ inline void EncodeParam(rdcarray &words, const DecorationAndParamData case Decoration::PayloadNodeArraySizeAMDX: words.push_back(param.payloadNodeArraySizeAMDX.value()); break; + case Decoration::ArrayStrideIdEXT: + words.push_back(param.arrayStrideIdEXT.value()); + break; + case Decoration::OffsetIdEXT: + words.push_back(param.offsetIdEXT.value()); + break; case Decoration::SecondaryViewportRelativeNV: words.push_back((uint32_t)param.secondaryViewportRelativeNV); break; + case Decoration::MemberOffsetNV: + words.push_back((uint32_t)param.memberOffsetNV); + break; + case Decoration::BankNV: + words.push_back((uint32_t)param.bankNV); + break; case Decoration::SIMTCallINTEL: words.push_back((uint32_t)param.sIMTCallINTEL); break; @@ -2925,7 +3005,11 @@ inline uint16_t ExtraWordCount(const Decoration decoration) case Decoration::PayloadNodeNameAMDX: return 1; case Decoration::PayloadNodeBaseIndexAMDX: return 1; case Decoration::PayloadNodeArraySizeAMDX: return 1; + case Decoration::ArrayStrideIdEXT: return 1; + case Decoration::OffsetIdEXT: return 1; case Decoration::SecondaryViewportRelativeNV: return 1; + case Decoration::MemberOffsetNV: return 1; + case Decoration::BankNV: return 1; case Decoration::SIMTCallINTEL: return 1; case Decoration::FuncParamIOKindINTEL: return 1; case Decoration::GlobalVariableOffsetINTEL: return 1; @@ -16351,6 +16435,144 @@ struct OpGroupNonUniformQuadAnyKHR Id predicate; }; +struct OpTypeBufferEXT +{ + OpTypeBufferEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpTypeBufferEXT(IdResult result, StorageClass storageClass) + : op(Op::TypeBufferEXT) + , wordCount(FixedWordSize) + { + this->result = result; + this->storageClass = storageClass; + } + + static constexpr Op OpCode = Op::TypeBufferEXT; + static constexpr uint16_t FixedWordSize = 3U; + Op op; + uint16_t wordCount; + IdResult result; + StorageClass storageClass; +}; + +struct OpBufferPointerEXT +{ + OpBufferPointerEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpBufferPointerEXT(IdResultType resultType, IdResult result, Id buffer) + : op(Op::BufferPointerEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->buffer = buffer; + } + + static constexpr Op OpCode = Op::BufferPointerEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id buffer; +}; + +struct OpUntypedImageTexelPointerEXT +{ + OpUntypedImageTexelPointerEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpUntypedImageTexelPointerEXT(IdResultType resultType, IdResult result, Id imageType, Id image, Id coordinate, Id sample) + : op(Op::UntypedImageTexelPointerEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->imageType = imageType; + this->image = image; + this->coordinate = coordinate; + this->sample = sample; + } + + static constexpr Op OpCode = Op::UntypedImageTexelPointerEXT; + static constexpr uint16_t FixedWordSize = 7U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id imageType; + Id image; + Id coordinate; + Id sample; +}; + +struct OpMemberDecorateIdEXT +{ + OpMemberDecorateIdEXT(const ConstIter &it) + { + uint32_t word = 0;(void)word; + this->op = OpCode; + this->wordCount = (uint16_t)it.size(); + this->structureType = Id::fromWord(it.word(1)); + this->member = (uint32_t)it.word(2); + word = 3; + this->decoration = DecodeParam(it, word); + } + OpMemberDecorateIdEXT(Id structureType, uint32_t member, DecorationAndParamData decoration) + : op(Op::MemberDecorateIdEXT) + , wordCount(MinWordSize + ExtraWordCount(decoration)) + { + this->structureType = structureType; + this->member = member; + this->decoration = decoration; + } + operator Operation() const + { + rdcarray words; + words.push_back(structureType.value()); + words.push_back((uint32_t)member); + EncodeParam(words, decoration); + return Operation(OpCode, words); + } + + static constexpr Op OpCode = Op::MemberDecorateIdEXT; + static constexpr uint16_t MinWordSize = 4U; + Op op; + uint16_t wordCount; + Id structureType; + uint32_t member; + DecorationAndParamData decoration; +}; + +struct OpConstantSizeOfEXT +{ + OpConstantSizeOfEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpConstantSizeOfEXT(IdResultType resultType, IdResult result, Id type) + : op(Op::ConstantSizeOfEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->type = type; + } + + static constexpr Op OpCode = Op::ConstantSizeOfEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id type; +}; + struct OpHitObjectRecordHitMotionNV { OpHitObjectRecordHitMotionNV(const ConstIter &it) @@ -17331,14 +17553,14 @@ struct OpImageSampleFootprintNV ImageOperandsAndParamDatas imageOperands; }; -struct OpTypeCooperativeVectorNV +struct OpTypeVectorIdEXT { - OpTypeCooperativeVectorNV(const ConstIter &it) + OpTypeVectorIdEXT(const ConstIter &it) { memcpy(this, it.words(), sizeof(*this)); } - OpTypeCooperativeVectorNV(IdResult result, Id componentType, Id componentCount) - : op(Op::TypeCooperativeVectorNV) + OpTypeVectorIdEXT(IdResult result, Id componentType, Id componentCount) + : op(Op::TypeVectorIdEXT) , wordCount(FixedWordSize) { this->result = result; @@ -17346,7 +17568,7 @@ struct OpTypeCooperativeVectorNV this->componentCount = componentCount; } - static constexpr Op OpCode = Op::TypeCooperativeVectorNV; + static constexpr Op OpCode = Op::TypeVectorIdEXT; static constexpr uint16_t FixedWordSize = 4U; Op op; uint16_t wordCount; @@ -17695,14 +17917,14 @@ struct OpSetMeshOutputsEXT Id primitiveCount; }; -struct OpGroupNonUniformPartitionNV +struct OpGroupNonUniformPartitionEXT { - OpGroupNonUniformPartitionNV(const ConstIter &it) + OpGroupNonUniformPartitionEXT(const ConstIter &it) { memcpy(this, it.words(), sizeof(*this)); } - OpGroupNonUniformPartitionNV(IdResultType resultType, IdResult result, Id value) - : op(Op::GroupNonUniformPartitionNV) + OpGroupNonUniformPartitionEXT(IdResultType resultType, IdResult result, Id value) + : op(Op::GroupNonUniformPartitionEXT) , wordCount(FixedWordSize) { this->resultType = resultType; @@ -17710,7 +17932,7 @@ struct OpGroupNonUniformPartitionNV this->value = value; } - static constexpr Op OpCode = Op::GroupNonUniformPartitionNV; + static constexpr Op OpCode = Op::GroupNonUniformPartitionEXT; static constexpr uint16_t FixedWordSize = 4U; Op op; uint16_t wordCount; @@ -17893,6 +18115,928 @@ struct OpCooperativeVectorStoreNV MemoryAccessAndParamDatas memoryAccess; }; +struct OpHitObjectRecordFromQueryEXT +{ + OpHitObjectRecordFromQueryEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectRecordFromQueryEXT(Id hitObject, Id rayQuery, Id sBTRecordIndex, Id hitObjectAttributes) + : op(Op::HitObjectRecordFromQueryEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->rayQuery = rayQuery; + this->sBTRecordIndex = sBTRecordIndex; + this->hitObjectAttributes = hitObjectAttributes; + } + + static constexpr Op OpCode = Op::HitObjectRecordFromQueryEXT; + static constexpr uint16_t FixedWordSize = 5U; + Op op; + uint16_t wordCount; + Id hitObject; + Id rayQuery; + Id sBTRecordIndex; + Id hitObjectAttributes; +}; + +struct OpHitObjectRecordMissEXT +{ + OpHitObjectRecordMissEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectRecordMissEXT(Id hitObject, Id rayFlags, Id missIndex, Id rayOrigin, Id rayTmin, Id rayDirection, Id rayTmax) + : op(Op::HitObjectRecordMissEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->rayFlags = rayFlags; + this->missIndex = missIndex; + this->rayOrigin = rayOrigin; + this->rayTmin = rayTmin; + this->rayDirection = rayDirection; + this->rayTmax = rayTmax; + } + + static constexpr Op OpCode = Op::HitObjectRecordMissEXT; + static constexpr uint16_t FixedWordSize = 8U; + Op op; + uint16_t wordCount; + Id hitObject; + Id rayFlags; + Id missIndex; + Id rayOrigin; + Id rayTmin; + Id rayDirection; + Id rayTmax; +}; + +struct OpHitObjectRecordMissMotionEXT +{ + OpHitObjectRecordMissMotionEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectRecordMissMotionEXT(Id hitObject, Id rayFlags, Id missIndex, Id rayOrigin, Id rayTmin, Id rayDirection, Id rayTmax, Id currentTime) + : op(Op::HitObjectRecordMissMotionEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->rayFlags = rayFlags; + this->missIndex = missIndex; + this->rayOrigin = rayOrigin; + this->rayTmin = rayTmin; + this->rayDirection = rayDirection; + this->rayTmax = rayTmax; + this->currentTime = currentTime; + } + + static constexpr Op OpCode = Op::HitObjectRecordMissMotionEXT; + static constexpr uint16_t FixedWordSize = 9U; + Op op; + uint16_t wordCount; + Id hitObject; + Id rayFlags; + Id missIndex; + Id rayOrigin; + Id rayTmin; + Id rayDirection; + Id rayTmax; + Id currentTime; +}; + +struct OpHitObjectGetIntersectionTriangleVertexPositionsEXT +{ + OpHitObjectGetIntersectionTriangleVertexPositionsEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetIntersectionTriangleVertexPositionsEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetIntersectionTriangleVertexPositionsEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetIntersectionTriangleVertexPositionsEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetRayFlagsEXT +{ + OpHitObjectGetRayFlagsEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetRayFlagsEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetRayFlagsEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetRayFlagsEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectSetShaderBindingTableRecordIndexEXT +{ + OpHitObjectSetShaderBindingTableRecordIndexEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectSetShaderBindingTableRecordIndexEXT(Id hitObject, Id sBTRecordIndex) + : op(Op::HitObjectSetShaderBindingTableRecordIndexEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->sBTRecordIndex = sBTRecordIndex; + } + + static constexpr Op OpCode = Op::HitObjectSetShaderBindingTableRecordIndexEXT; + static constexpr uint16_t FixedWordSize = 3U; + Op op; + uint16_t wordCount; + Id hitObject; + Id sBTRecordIndex; +}; + +struct OpHitObjectReorderExecuteShaderEXT +{ + OpHitObjectReorderExecuteShaderEXT(const ConstIter &it) + { + uint32_t word = 0;(void)word; + this->op = OpCode; + this->wordCount = (uint16_t)it.size(); + this->hitObject = Id::fromWord(it.word(1)); + this->payload = Id::fromWord(it.word(2)); + this->hint = (it.size() > 3) ? Id::fromWord(it.word(3)) : Id(); + this->bits = (it.size() > 4) ? Id::fromWord(it.word(4)) : Id(); + } + OpHitObjectReorderExecuteShaderEXT(Id hitObject, Id payload, Id hint = Id(), Id bits = Id()) + : op(Op::HitObjectReorderExecuteShaderEXT) + , wordCount(MinWordSize + OptionalWordCount(hint) + OptionalWordCount(bits)) + { + this->hitObject = hitObject; + this->payload = payload; + this->hint = hint; + this->bits = bits; + } + operator Operation() const + { + rdcarray words; + words.push_back(hitObject.value()); + words.push_back(payload.value()); + if(hint != Id()) words.push_back(hint.value()); + if(bits != Id()) words.push_back(bits.value()); + return Operation(OpCode, words); + } + + static constexpr Op OpCode = Op::HitObjectReorderExecuteShaderEXT; + static constexpr uint16_t MinWordSize = 3U; + Op op; + uint16_t wordCount; + Id hitObject; + Id payload; + Id hint; + Id bits; + + bool HasHint() const { return wordCount > 3; } + bool HasBits() const { return wordCount > 4; } +}; + +struct OpHitObjectTraceReorderExecuteEXT +{ + OpHitObjectTraceReorderExecuteEXT(const ConstIter &it) + { + uint32_t word = 0;(void)word; + this->op = OpCode; + this->wordCount = (uint16_t)it.size(); + this->hitObject = Id::fromWord(it.word(1)); + this->accelerationStructure = Id::fromWord(it.word(2)); + this->rayFlags = Id::fromWord(it.word(3)); + this->cullMask = Id::fromWord(it.word(4)); + this->sBTOffset = Id::fromWord(it.word(5)); + this->sBTStride = Id::fromWord(it.word(6)); + this->missIndex = Id::fromWord(it.word(7)); + this->rayOrigin = Id::fromWord(it.word(8)); + this->rayTmin = Id::fromWord(it.word(9)); + this->rayDirection = Id::fromWord(it.word(10)); + this->rayTmax = Id::fromWord(it.word(11)); + this->payload = Id::fromWord(it.word(12)); + this->hint = (it.size() > 13) ? Id::fromWord(it.word(13)) : Id(); + this->bits = (it.size() > 14) ? Id::fromWord(it.word(14)) : Id(); + } + OpHitObjectTraceReorderExecuteEXT(Id hitObject, Id accelerationStructure, Id rayFlags, Id cullMask, Id sBTOffset, Id sBTStride, Id missIndex, Id rayOrigin, Id rayTmin, Id rayDirection, Id rayTmax, Id payload, Id hint = Id(), Id bits = Id()) + : op(Op::HitObjectTraceReorderExecuteEXT) + , wordCount(MinWordSize + OptionalWordCount(hint) + OptionalWordCount(bits)) + { + this->hitObject = hitObject; + this->accelerationStructure = accelerationStructure; + this->rayFlags = rayFlags; + this->cullMask = cullMask; + this->sBTOffset = sBTOffset; + this->sBTStride = sBTStride; + this->missIndex = missIndex; + this->rayOrigin = rayOrigin; + this->rayTmin = rayTmin; + this->rayDirection = rayDirection; + this->rayTmax = rayTmax; + this->payload = payload; + this->hint = hint; + this->bits = bits; + } + operator Operation() const + { + rdcarray words; + words.push_back(hitObject.value()); + words.push_back(accelerationStructure.value()); + words.push_back(rayFlags.value()); + words.push_back(cullMask.value()); + words.push_back(sBTOffset.value()); + words.push_back(sBTStride.value()); + words.push_back(missIndex.value()); + words.push_back(rayOrigin.value()); + words.push_back(rayTmin.value()); + words.push_back(rayDirection.value()); + words.push_back(rayTmax.value()); + words.push_back(payload.value()); + if(hint != Id()) words.push_back(hint.value()); + if(bits != Id()) words.push_back(bits.value()); + return Operation(OpCode, words); + } + + static constexpr Op OpCode = Op::HitObjectTraceReorderExecuteEXT; + static constexpr uint16_t MinWordSize = 13U; + Op op; + uint16_t wordCount; + Id hitObject; + Id accelerationStructure; + Id rayFlags; + Id cullMask; + Id sBTOffset; + Id sBTStride; + Id missIndex; + Id rayOrigin; + Id rayTmin; + Id rayDirection; + Id rayTmax; + Id payload; + Id hint; + Id bits; + + bool HasHint() const { return wordCount > 13; } + bool HasBits() const { return wordCount > 14; } +}; + +struct OpHitObjectTraceMotionReorderExecuteEXT +{ + OpHitObjectTraceMotionReorderExecuteEXT(const ConstIter &it) + { + uint32_t word = 0;(void)word; + this->op = OpCode; + this->wordCount = (uint16_t)it.size(); + this->hitObject = Id::fromWord(it.word(1)); + this->accelerationStructure = Id::fromWord(it.word(2)); + this->rayFlags = Id::fromWord(it.word(3)); + this->cullMask = Id::fromWord(it.word(4)); + this->sBTOffset = Id::fromWord(it.word(5)); + this->sBTStride = Id::fromWord(it.word(6)); + this->missIndex = Id::fromWord(it.word(7)); + this->rayOrigin = Id::fromWord(it.word(8)); + this->rayTmin = Id::fromWord(it.word(9)); + this->rayDirection = Id::fromWord(it.word(10)); + this->rayTmax = Id::fromWord(it.word(11)); + this->currentTime = Id::fromWord(it.word(12)); + this->payload = Id::fromWord(it.word(13)); + this->hint = (it.size() > 14) ? Id::fromWord(it.word(14)) : Id(); + this->bits = (it.size() > 15) ? Id::fromWord(it.word(15)) : Id(); + } + OpHitObjectTraceMotionReorderExecuteEXT(Id hitObject, Id accelerationStructure, Id rayFlags, Id cullMask, Id sBTOffset, Id sBTStride, Id missIndex, Id rayOrigin, Id rayTmin, Id rayDirection, Id rayTmax, Id currentTime, Id payload, Id hint = Id(), Id bits = Id()) + : op(Op::HitObjectTraceMotionReorderExecuteEXT) + , wordCount(MinWordSize + OptionalWordCount(hint) + OptionalWordCount(bits)) + { + this->hitObject = hitObject; + this->accelerationStructure = accelerationStructure; + this->rayFlags = rayFlags; + this->cullMask = cullMask; + this->sBTOffset = sBTOffset; + this->sBTStride = sBTStride; + this->missIndex = missIndex; + this->rayOrigin = rayOrigin; + this->rayTmin = rayTmin; + this->rayDirection = rayDirection; + this->rayTmax = rayTmax; + this->currentTime = currentTime; + this->payload = payload; + this->hint = hint; + this->bits = bits; + } + operator Operation() const + { + rdcarray words; + words.push_back(hitObject.value()); + words.push_back(accelerationStructure.value()); + words.push_back(rayFlags.value()); + words.push_back(cullMask.value()); + words.push_back(sBTOffset.value()); + words.push_back(sBTStride.value()); + words.push_back(missIndex.value()); + words.push_back(rayOrigin.value()); + words.push_back(rayTmin.value()); + words.push_back(rayDirection.value()); + words.push_back(rayTmax.value()); + words.push_back(currentTime.value()); + words.push_back(payload.value()); + if(hint != Id()) words.push_back(hint.value()); + if(bits != Id()) words.push_back(bits.value()); + return Operation(OpCode, words); + } + + static constexpr Op OpCode = Op::HitObjectTraceMotionReorderExecuteEXT; + static constexpr uint16_t MinWordSize = 14U; + Op op; + uint16_t wordCount; + Id hitObject; + Id accelerationStructure; + Id rayFlags; + Id cullMask; + Id sBTOffset; + Id sBTStride; + Id missIndex; + Id rayOrigin; + Id rayTmin; + Id rayDirection; + Id rayTmax; + Id currentTime; + Id payload; + Id hint; + Id bits; + + bool HasHint() const { return wordCount > 14; } + bool HasBits() const { return wordCount > 15; } +}; + +struct OpTypeHitObjectEXT +{ + OpTypeHitObjectEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpTypeHitObjectEXT(IdResult result) + : op(Op::TypeHitObjectEXT) + , wordCount(FixedWordSize) + { + this->result = result; + } + + static constexpr Op OpCode = Op::TypeHitObjectEXT; + static constexpr uint16_t FixedWordSize = 2U; + Op op; + uint16_t wordCount; + IdResult result; +}; + +struct OpReorderThreadWithHintEXT +{ + OpReorderThreadWithHintEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpReorderThreadWithHintEXT(Id hint, Id bits) + : op(Op::ReorderThreadWithHintEXT) + , wordCount(FixedWordSize) + { + this->hint = hint; + this->bits = bits; + } + + static constexpr Op OpCode = Op::ReorderThreadWithHintEXT; + static constexpr uint16_t FixedWordSize = 3U; + Op op; + uint16_t wordCount; + Id hint; + Id bits; +}; + +struct OpReorderThreadWithHitObjectEXT +{ + OpReorderThreadWithHitObjectEXT(const ConstIter &it) + { + uint32_t word = 0;(void)word; + this->op = OpCode; + this->wordCount = (uint16_t)it.size(); + this->hitObject = Id::fromWord(it.word(1)); + this->hint = (it.size() > 2) ? Id::fromWord(it.word(2)) : Id(); + this->bits = (it.size() > 3) ? Id::fromWord(it.word(3)) : Id(); + } + OpReorderThreadWithHitObjectEXT(Id hitObject, Id hint = Id(), Id bits = Id()) + : op(Op::ReorderThreadWithHitObjectEXT) + , wordCount(MinWordSize + OptionalWordCount(hint) + OptionalWordCount(bits)) + { + this->hitObject = hitObject; + this->hint = hint; + this->bits = bits; + } + operator Operation() const + { + rdcarray words; + words.push_back(hitObject.value()); + if(hint != Id()) words.push_back(hint.value()); + if(bits != Id()) words.push_back(bits.value()); + return Operation(OpCode, words); + } + + static constexpr Op OpCode = Op::ReorderThreadWithHitObjectEXT; + static constexpr uint16_t MinWordSize = 2U; + Op op; + uint16_t wordCount; + Id hitObject; + Id hint; + Id bits; + + bool HasHint() const { return wordCount > 2; } + bool HasBits() const { return wordCount > 3; } +}; + +struct OpHitObjectTraceRayEXT +{ + OpHitObjectTraceRayEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectTraceRayEXT(Id hitObject, Id accelerationStructure, Id rayFlags, Id cullMask, Id sBTOffset, Id sBTStride, Id missIndex, Id rayOrigin, Id rayTmin, Id rayDirection, Id rayTmax, Id payload) + : op(Op::HitObjectTraceRayEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->accelerationStructure = accelerationStructure; + this->rayFlags = rayFlags; + this->cullMask = cullMask; + this->sBTOffset = sBTOffset; + this->sBTStride = sBTStride; + this->missIndex = missIndex; + this->rayOrigin = rayOrigin; + this->rayTmin = rayTmin; + this->rayDirection = rayDirection; + this->rayTmax = rayTmax; + this->payload = payload; + } + + static constexpr Op OpCode = Op::HitObjectTraceRayEXT; + static constexpr uint16_t FixedWordSize = 13U; + Op op; + uint16_t wordCount; + Id hitObject; + Id accelerationStructure; + Id rayFlags; + Id cullMask; + Id sBTOffset; + Id sBTStride; + Id missIndex; + Id rayOrigin; + Id rayTmin; + Id rayDirection; + Id rayTmax; + Id payload; +}; + +struct OpHitObjectTraceRayMotionEXT +{ + OpHitObjectTraceRayMotionEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectTraceRayMotionEXT(Id hitObject, Id accelerationStructure, Id rayFlags, Id cullMask, Id sBTOffset, Id sBTStride, Id missIndex, Id rayOrigin, Id rayTmin, Id rayDirection, Id rayTmax, Id currentTime, Id payload) + : op(Op::HitObjectTraceRayMotionEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->accelerationStructure = accelerationStructure; + this->rayFlags = rayFlags; + this->cullMask = cullMask; + this->sBTOffset = sBTOffset; + this->sBTStride = sBTStride; + this->missIndex = missIndex; + this->rayOrigin = rayOrigin; + this->rayTmin = rayTmin; + this->rayDirection = rayDirection; + this->rayTmax = rayTmax; + this->currentTime = currentTime; + this->payload = payload; + } + + static constexpr Op OpCode = Op::HitObjectTraceRayMotionEXT; + static constexpr uint16_t FixedWordSize = 14U; + Op op; + uint16_t wordCount; + Id hitObject; + Id accelerationStructure; + Id rayFlags; + Id cullMask; + Id sBTOffset; + Id sBTStride; + Id missIndex; + Id rayOrigin; + Id rayTmin; + Id rayDirection; + Id rayTmax; + Id currentTime; + Id payload; +}; + +struct OpHitObjectRecordEmptyEXT +{ + OpHitObjectRecordEmptyEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectRecordEmptyEXT(Id hitObject) + : op(Op::HitObjectRecordEmptyEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectRecordEmptyEXT; + static constexpr uint16_t FixedWordSize = 2U; + Op op; + uint16_t wordCount; + Id hitObject; +}; + +struct OpHitObjectExecuteShaderEXT +{ + OpHitObjectExecuteShaderEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectExecuteShaderEXT(Id hitObject, Id payload) + : op(Op::HitObjectExecuteShaderEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->payload = payload; + } + + static constexpr Op OpCode = Op::HitObjectExecuteShaderEXT; + static constexpr uint16_t FixedWordSize = 3U; + Op op; + uint16_t wordCount; + Id hitObject; + Id payload; +}; + +struct OpHitObjectGetCurrentTimeEXT +{ + OpHitObjectGetCurrentTimeEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetCurrentTimeEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetCurrentTimeEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetCurrentTimeEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetAttributesEXT +{ + OpHitObjectGetAttributesEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetAttributesEXT(Id hitObject, Id hitObjectAttribute) + : op(Op::HitObjectGetAttributesEXT) + , wordCount(FixedWordSize) + { + this->hitObject = hitObject; + this->hitObjectAttribute = hitObjectAttribute; + } + + static constexpr Op OpCode = Op::HitObjectGetAttributesEXT; + static constexpr uint16_t FixedWordSize = 3U; + Op op; + uint16_t wordCount; + Id hitObject; + Id hitObjectAttribute; +}; + +struct OpHitObjectGetHitKindEXT +{ + OpHitObjectGetHitKindEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetHitKindEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetHitKindEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetHitKindEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetPrimitiveIndexEXT +{ + OpHitObjectGetPrimitiveIndexEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetPrimitiveIndexEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetPrimitiveIndexEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetPrimitiveIndexEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetGeometryIndexEXT +{ + OpHitObjectGetGeometryIndexEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetGeometryIndexEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetGeometryIndexEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetGeometryIndexEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetInstanceIdEXT +{ + OpHitObjectGetInstanceIdEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetInstanceIdEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetInstanceIdEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetInstanceIdEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetInstanceCustomIndexEXT +{ + OpHitObjectGetInstanceCustomIndexEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetInstanceCustomIndexEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetInstanceCustomIndexEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetInstanceCustomIndexEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetObjectRayOriginEXT +{ + OpHitObjectGetObjectRayOriginEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetObjectRayOriginEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetObjectRayOriginEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetObjectRayOriginEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetObjectRayDirectionEXT +{ + OpHitObjectGetObjectRayDirectionEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetObjectRayDirectionEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetObjectRayDirectionEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetObjectRayDirectionEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetWorldRayDirectionEXT +{ + OpHitObjectGetWorldRayDirectionEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetWorldRayDirectionEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetWorldRayDirectionEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetWorldRayDirectionEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetWorldRayOriginEXT +{ + OpHitObjectGetWorldRayOriginEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetWorldRayOriginEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetWorldRayOriginEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetWorldRayOriginEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetObjectToWorldEXT +{ + OpHitObjectGetObjectToWorldEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetObjectToWorldEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetObjectToWorldEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetObjectToWorldEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetWorldToObjectEXT +{ + OpHitObjectGetWorldToObjectEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetWorldToObjectEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetWorldToObjectEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetWorldToObjectEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetRayTMaxEXT +{ + OpHitObjectGetRayTMaxEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetRayTMaxEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetRayTMaxEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetRayTMaxEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + struct OpReportIntersectionKHR { OpReportIntersectionKHR(const ConstIter &it) @@ -18201,6 +19345,150 @@ struct OpHitObjectGetClusterIdNV Id hitObject; }; +struct OpHitObjectGetRayTMinEXT +{ + OpHitObjectGetRayTMinEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetRayTMinEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetRayTMinEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetRayTMinEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetShaderBindingTableRecordIndexEXT +{ + OpHitObjectGetShaderBindingTableRecordIndexEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetShaderBindingTableRecordIndexEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetShaderBindingTableRecordIndexEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetShaderBindingTableRecordIndexEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectGetShaderRecordBufferHandleEXT +{ + OpHitObjectGetShaderRecordBufferHandleEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectGetShaderRecordBufferHandleEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectGetShaderRecordBufferHandleEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectGetShaderRecordBufferHandleEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectIsEmptyEXT +{ + OpHitObjectIsEmptyEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectIsEmptyEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectIsEmptyEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectIsEmptyEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectIsHitEXT +{ + OpHitObjectIsHitEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectIsHitEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectIsHitEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectIsHitEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + +struct OpHitObjectIsMissEXT +{ + OpHitObjectIsMissEXT(const ConstIter &it) + { + memcpy(this, it.words(), sizeof(*this)); + } + OpHitObjectIsMissEXT(IdResultType resultType, IdResult result, Id hitObject) + : op(Op::HitObjectIsMissEXT) + , wordCount(FixedWordSize) + { + this->resultType = resultType; + this->result = result; + this->hitObject = hitObject; + } + + static constexpr Op OpCode = Op::HitObjectIsMissEXT; + static constexpr uint16_t FixedWordSize = 4U; + Op op; + uint16_t wordCount; + IdResultType resultType; + IdResult result; + Id hitObject; +}; + struct OpTypeCooperativeMatrixNV { OpTypeCooperativeMatrixNV(const ConstIter &it) diff --git a/renderdoc/driver/shaders/spirv/spirv_registry.md b/renderdoc/driver/shaders/spirv/spirv_registry.md index 3f2c16ccb..faf664427 100644 --- a/renderdoc/driver/shaders/spirv/spirv_registry.md +++ b/renderdoc/driver/shaders/spirv/spirv_registry.md @@ -82,11 +82,13 @@ Note: we no longer push the HTML along side the extension. * [SPV_EXT_arithmetic_fence ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_arithmetic_fence.html) * [SPV_EXT_demote_to_helper_invocation ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_demote_to_helper_invocation.html) * [SPV_EXT_descriptor_indexing ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_descriptor_indexing.html) +* [SPV_EXT_descriptor_heap ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_descriptor_heap.html) * [SPV_EXT_float8 ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_float8.html) * [SPV_EXT_fragment_fully_covered ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_fragment_fully_covered.html) * [SPV_EXT_fragment_invocation_density ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_fragment_invocation_density.html) * [SPV_EXT_fragment_shader_interlock ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_fragment_shader_interlock.html) * [SPV_EXT_image_raw10_raw12 ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_image_raw10_raw12.html) +* [SPV_EXT_long_vector ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_long_vector.html) * [SPV_EXT_mesh_shader ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_mesh_shader.html) * [SPV_EXT_opacity_micromap ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_opacity_micromap.html) * [SPV_EXT_optnone ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_optnone.html) @@ -98,7 +100,9 @@ Note: we no longer push the HTML along side the extension. * [SPV_EXT_shader_atomic_float_min_max ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_atomic_float_min_max.html) * [SPV_EXT_shader_atomic_float16_add ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_atomic_float16_add.html) * [SPV_EXT_shader_image_int64 ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_image_int64.html) +* [SPV_EXT_shader_invocation_reorder ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_invocation_reorder.html) * [SPV_EXT_shader_stencil_export ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_stencil_export.html) +* [SPV_EXT_shader_subgroup_partitioned ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_subgroup_partitioned.html) * [SPV_EXT_shader_tile_image ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_tile_image.html) * [SPV_EXT_shader_viewport_index_layer ]( https://github.khronos.org/SPIRV-Registry/extensions/EXT/SPV_EXT_shader_viewport_index_layer.html) @@ -178,6 +182,7 @@ Note: we no longer push the HTML along side the extension. * [SPV_NV_geometry_shader_passthrough ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_geometry_shader_passthrough.html) * [SPV_NV_linear_swept_spheres ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_linear_swept_spheres.html) * [SPV_NV_mesh_shader ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_mesh_shader.html) +* [SPV_NV_push_constant_bank ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_push_constant_bank.html) * [SPV_NV_raw_access_chains ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_raw_access_chains.html) * [SPV_NV_ray_tracing ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_ray_tracing.html) * [SPV_NV_ray_tracing_motion_blur ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_ray_tracing_motion_blur.html) @@ -191,7 +196,7 @@ Note: we no longer push the HTML along side the extension. * [SPV_NV_stereo_view_rendering ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_stereo_view_rendering.html) * [SPV_NV_tensor_addressing ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_tensor_addressing.html) * [SPV_NV_viewport_array2 ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NV_viewport_array2.html) -* [SPV_NVX_multiview_per_view_attributes ]( https://github.khronos.org/SPIRV-Registry/extensions/NV/SPV_NVX_multiview_per_view_attributes.html) +* [SPV_NVX_multiview_per_view_attributes ]( https://github.khronos.org/SPIRV-Registry/extensions/NVX/SPV_NVX_multiview_per_view_attributes.html) * [SPV_QCOM_cooperative_matrix_conversion ]( https://github.khronos.org/SPIRV-Registry/extensions/QCOM/SPV_QCOM_cooperative_matrix_conversion.html) * [SPV_QCOM_image_processing ]( https://github.khronos.org/SPIRV-Registry/extensions/QCOM/SPV_QCOM_image_processing.html) * [SPV_QCOM_image_processing2 ]( https://github.khronos.org/SPIRV-Registry/extensions/QCOM/SPV_QCOM_image_processing2.html)