[Mesa-dev] [PATCH] radv: adjust the VGT workaround for prim restart on GFX9
Samuel Pitoiset
samuel.pitoiset at gmail.com
Tue Dec 11 15:10:52 UTC 2018
ping?
After looking into this again today, I can't find any better solutions.
We should probably push this patch because at least two games are
affected. My opinion is that correctness is more important than performance.
On 10/11/18 10:42 AM, Samuel Pitoiset wrote:
> WD_SWITCH_ON_EOP seems to be the only workaround that fixes
> the GPU hangs with Yakuza and The Evil Within on Vega. I don't
> like as it might decrease geometry performance as pointed out
> by Marek, but I don't know how to implement a better one.
>
> Cc: mesa-stable at lists.freedesktop.org
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> ---
> src/amd/vulkan/radv_pipeline.c | 13 +++++++++++--
> 1 file changed, 11 insertions(+), 2 deletions(-)
>
> diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c
> index 426b417e172..2256b2c58e9 100644
> --- a/src/amd/vulkan/radv_pipeline.c
> +++ b/src/amd/vulkan/radv_pipeline.c
> @@ -3412,14 +3412,23 @@ radv_compute_ia_multi_vgt_param_helpers(struct radv_pipeline *pipeline,
> }
>
> /* Workaround for a VGT hang when strip primitive types are used with
> - * primitive restart.
> + * primitive restart. This fixes GPU hangs with Yakuza and The Evil
> + * Within, at least. Not sure if we can implement a better workaround.
> */
> if (pipeline->graphics.prim_restart_enable &&
> (prim == V_008958_DI_PT_LINESTRIP ||
> prim == V_008958_DI_PT_TRISTRIP ||
> prim == V_008958_DI_PT_LINESTRIP_ADJ ||
> prim == V_008958_DI_PT_TRISTRIP_ADJ)) {
> - ia_multi_vgt_param.partial_vs_wave = true;
> + if (device->physical_device->rad_info.chip_class >= GFX9) {
> + /* XXX: This might decrease geometry performance by 2x,
> + * but this appears to be the only workaround that
> + * fixes the GPU hang.
> + */
> + ia_multi_vgt_param.wd_switch_on_eop = true;
> + } else {
> + ia_multi_vgt_param.partial_vs_wave = true;
> + }
> }
>
> ia_multi_vgt_param.base =
>
More information about the mesa-dev
mailing list