diff --git a/lgc/include/lgc/state/AbiMetadata.h b/lgc/include/lgc/state/AbiMetadata.h index 2e2c5b0bdf..ad89a08c46 100644 --- a/lgc/include/lgc/state/AbiMetadata.h +++ b/lgc/include/lgc/state/AbiMetadata.h @@ -230,7 +230,6 @@ static constexpr char VgtGsMode[] = ".vgt_gs_mode"; static constexpr char VgtTfParam[] = ".vgt_tf_param"; static constexpr char VgtLsHsConfig[] = ".vgt_ls_hs_config"; static constexpr char IaMultiVgtParam[] = ".ia_multi_vgt_param"; -static constexpr char IaMultiVgtParamPiped[] = ".ia_multi_vgt_param_piped"; static constexpr char SpiInterpControl[] = ".spi_interp_control"; static constexpr char SpiPsInputCntl[] = ".spi_ps_input_cntl"; static constexpr char VgtHosMinTessLevel[] = ".vgt_hos_min_tess_level"; @@ -331,12 +330,6 @@ static constexpr char SwitchOnEoi[] = ".switch_on_eoi"; static constexpr char PartialEsWaveOn[] = ".partial_es_wave_on"; }; // namespace IaMultiVgtParamMetadataKey -namespace IaMultiVgtParamPipedMetadataKey { -static constexpr char PrimgroupSize[] = ".primgroup_size"; -static constexpr char SwitchOnEoi[] = ".switch_on_eoi"; -static constexpr char PartialEsWaveOn[] = ".partial_es_wave_on"; -}; // namespace IaMultiVgtParamPipedMetadataKey - namespace VgtGsModeMetadataKey { static constexpr char Mode[] = ".mode"; static constexpr char Onchip[] = ".onchip"; diff --git a/lgc/patch/RegisterMetadataBuilder.cpp b/lgc/patch/RegisterMetadataBuilder.cpp index 94c0bbc05c..7be14870b3 100644 --- a/lgc/patch/RegisterMetadataBuilder.cpp +++ b/lgc/patch/RegisterMetadataBuilder.cpp @@ -1459,8 +1459,6 @@ void RegisterMetadataBuilder::setVgtShaderStagesEn(unsigned hwStageMask) { // ===================================================================================================================== // Set up the metadata for register IA_MULT_VGT_PARAM void RegisterMetadataBuilder::setIaMultVgtParam() { - bool isIaMultVgtParamPiped = m_isNggMode || (m_gfxIp.major == 10 && !m_isNggMode); - if (m_hasTcs || m_hasTes) { // With tessellation, SWITCH_ON_EOI and PARTIAL_ES_WAVE_ON must be set if primitive ID is used by either the TCS, // TES, or GS. @@ -1477,19 +1475,15 @@ void RegisterMetadataBuilder::setIaMultVgtParam() { usePrimitiveId = gsBuiltInUsage.primitiveId; } - if (isIaMultVgtParamPiped) { - auto iaMultVgtParamPiped = - getGraphicsRegNode()[Util::Abi::GraphicsRegisterMetadataKey::IaMultiVgtParamPiped].getMap(true); - iaMultVgtParamPiped[Util::Abi::IaMultiVgtParamPipedMetadataKey::SwitchOnEoi] = usePrimitiveId; + auto iaMultVgtParam = getGraphicsRegNode()[Util::Abi::GraphicsRegisterMetadataKey::IaMultiVgtParam].getMap(true); + iaMultVgtParam[Util::Abi::IaMultiVgtParamMetadataKey::SwitchOnEoi] = usePrimitiveId; + if (m_isNggMode || (m_gfxIp.major == 10 && !m_isNggMode)) { if (needWaveOnField) - iaMultVgtParamPiped[Util::Abi::IaMultiVgtParamPipedMetadataKey::PartialEsWaveOn] = usePrimitiveId; + iaMultVgtParam[Util::Abi::IaMultiVgtParamMetadataKey::PartialEsWaveOn] = usePrimitiveId; } else { - auto iaMultVgtParam = getGraphicsRegNode()[Util::Abi::GraphicsRegisterMetadataKey::IaMultiVgtParam].getMap(true); - iaMultVgtParam[Util::Abi::IaMultiVgtParamMetadataKey::SwitchOnEoi] = usePrimitiveId; if (needWaveOnField) iaMultVgtParam[Util::Abi::IaMultiVgtParamMetadataKey::PrimgroupSize] = usePrimitiveId; } - } else { unsigned primGroupSize = 128; if (!m_hasGs && !m_hasMesh) { @@ -1499,15 +1493,8 @@ void RegisterMetadataBuilder::setIaMultVgtParam() { if (numShaderEngines > 2) primGroupSize = alignTo(primGroupSize, 2); } - - if (isIaMultVgtParamPiped || m_hasMesh) { - auto iaMultVgtParamPiped = - getGraphicsRegNode()[Util::Abi::GraphicsRegisterMetadataKey::IaMultiVgtParamPiped].getMap(true); - iaMultVgtParamPiped[Util::Abi::IaMultiVgtParamPipedMetadataKey::PrimgroupSize] = primGroupSize - 1; - } else { - auto iaMultVgtParam = getGraphicsRegNode()[Util::Abi::GraphicsRegisterMetadataKey::IaMultiVgtParam].getMap(true); - iaMultVgtParam[Util::Abi::IaMultiVgtParamMetadataKey::PrimgroupSize] = primGroupSize - 1; - } + auto iaMultVgtParam = getGraphicsRegNode()[Util::Abi::GraphicsRegisterMetadataKey::IaMultiVgtParam].getMap(true); + iaMultVgtParam[Util::Abi::IaMultiVgtParamMetadataKey::PrimgroupSize] = primGroupSize - 1; } } diff --git a/llpc/test/shaderdb/general/PipelineVsFs_TestNullFs.pipe b/llpc/test/shaderdb/general/PipelineVsFs_TestNullFs.pipe index 3b65216351..2b902e0b5c 100644 --- a/llpc/test/shaderdb/general/PipelineVsFs_TestNullFs.pipe +++ b/llpc/test/shaderdb/general/PipelineVsFs_TestNullFs.pipe @@ -54,7 +54,7 @@ colorBuffer[0].blendSrcAlphaToColor = 0 ; CHECK-NEXT: .stencil_test_val_export_enable: 0 ; CHECK-NEXT: .z_export_enable: 0 ; CHECK-NEXT: .z_order: 0x1 -; CHECK-NEXT: .ia_multi_vgt_param_piped: +; CHECK-NEXT: .ia_multi_vgt_param: ; CHECK-NEXT: .primgroup_size: 0x7f ; CHECK-NEXT: .pa_cl_clip_cntl: ; CHECK-NEXT: .dx_linear_attr_clip_ena: true diff --git a/llpc/test/shaderdb/gfx10/PipelineVsFs_TestVsOutMiscSideBusEna.pipe b/llpc/test/shaderdb/gfx10/PipelineVsFs_TestVsOutMiscSideBusEna.pipe index 044e3c5f78..a2d8a6b716 100644 --- a/llpc/test/shaderdb/gfx10/PipelineVsFs_TestVsOutMiscSideBusEna.pipe +++ b/llpc/test/shaderdb/gfx10/PipelineVsFs_TestVsOutMiscSideBusEna.pipe @@ -59,7 +59,7 @@ entryPoint = main ; SHADERTEST-NEXT: .stencil_test_val_export_enable: 0 ; SHADERTEST-NEXT: .z_export_enable: 0 ; SHADERTEST-NEXT: .z_order: 0x1 -; SHADERTEST-NEXT: .ia_multi_vgt_param_piped: +; SHADERTEST-NEXT: .ia_multi_vgt_param: ; SHADERTEST-NEXT: .primgroup_size: 0x7f ; SHADERTEST-NEXT: .pa_cl_clip_cntl: ; SHADERTEST-NEXT: .dx_linear_attr_clip_ena: true diff --git a/llpc/test/shaderdb/gfx11/SgprUserDataInit_Fs.pipe b/llpc/test/shaderdb/gfx11/SgprUserDataInit_Fs.pipe index d5f60e5dfa..5b2be37628 100644 --- a/llpc/test/shaderdb/gfx11/SgprUserDataInit_Fs.pipe +++ b/llpc/test/shaderdb/gfx11/SgprUserDataInit_Fs.pipe @@ -176,7 +176,7 @@ colorBuffer[0].blendSrcAlphaToColor = 0 ; CHECK-NEXT: .prim_amp_factor: 0x1 ; CHECK-NEXT: .threads_per_subgroup: 0x100 ; CHECK-NEXT: .gs_vgpr_comp_cnt: 0x1 -; CHECK-NEXT: .ia_multi_vgt_param_piped: +; CHECK-NEXT: .ia_multi_vgt_param: ; CHECK-NEXT: .primgroup_size: 0x7f ; CHECK-NEXT: .max_verts_per_subgroup: 0x80 ; CHECK-NEXT: .pa_cl_clip_cntl: