mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-21 13:18:09 +02:00
radv: fix another case of VRS with mipmaps on GFX10.3
When a VRS view is used with a depth/stencil view, the driver is
expected to copy the VRS rates to the HTILE buffer of the depth/stencil
view. Though if the image uses mipmaps and the base level can't support
HTILE there is no way to copy the rates. The workaround is to force VRS
to be 1x1 which is valid in Vulkan.
This fixes old VKCTS failures on RAPHAEL just because it supports
fragmentShadingRateWithShaderDepthStencilWrites compared to other GPUs
in CI (NAVI21/VANGOGH).
Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
(cherry picked from commit da0ee50c3b)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/41540>
This commit is contained in:
parent
6b27a4a393
commit
00967135c8
3 changed files with 17 additions and 28 deletions
|
|
@ -334,7 +334,7 @@
|
|||
"description": "radv: fix another case of VRS with mipmaps on GFX10.3",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null,
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -1,29 +1,3 @@
|
|||
# Issues specific to the Raphael. The list can be reduced when disabling VRS flat shading
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.noshaderrate.keep.replace.1x1.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.noshaderrate.keep.replace.1x1.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.noshaderrate.keep.replace.4x4.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.noshaderrate.keep.replace.4x4.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.keep.replace.1x1.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.keep.replace.1x1.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.keep.replace.4x4.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.keep.replace.4x4.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.replace.replace.1x1.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.replace.replace.1x1.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.replace.replace.4x4.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragdepth_baselevel.dynamic.attachment.shaderrate.replace.replace.4x4.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.noshaderrate.keep.replace.1x1.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.noshaderrate.keep.replace.1x1.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.noshaderrate.keep.replace.4x4.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.noshaderrate.keep.replace.4x4.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.keep.replace.1x1.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.keep.replace.1x1.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.keep.replace.4x4.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.keep.replace.4x4.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.replace.replace.1x1.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.replace.replace.1x1.samples1.vs,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.replace.replace.4x4.samples1.ms,Fail
|
||||
dEQP-VK.fragment_shading_rate.renderpass2.monolithic.fragstencil_baselevel.dynamic.attachment.shaderrate.replace.replace.4x4.samples1.vs,Fail
|
||||
|
||||
# https://gitlab.khronos.org/Tracker/vk-gl-cts/-/issues/6256
|
||||
dEQP-VK.sparse_resources.image_sparse_residency.2d.r10x6_unorm_pack16.1024_128_1,Crash
|
||||
dEQP-VK.sparse_resources.image_sparse_residency.2d.r10x6_unorm_pack16.11_137_1,Crash
|
||||
|
|
|
|||
|
|
@ -4240,6 +4240,7 @@ radv_emit_fsr_state(struct radv_cmd_buffer *cmd_buffer)
|
|||
struct radv_device *device = radv_cmd_buffer_device(cmd_buffer);
|
||||
const struct radv_physical_device *pdev = radv_device_physical(device);
|
||||
const struct radv_dynamic_state *d = &cmd_buffer->state.dynamic;
|
||||
const struct radv_rendering_state *render = &cmd_buffer->state.render;
|
||||
struct radv_cmd_stream *cs = cmd_buffer->cs;
|
||||
|
||||
/* When per-vertex VRS is forced and the dynamic fragment shading rate is a no-op, ignore
|
||||
|
|
@ -4259,7 +4260,7 @@ radv_emit_fsr_state(struct radv_cmd_buffer *cmd_buffer)
|
|||
|
||||
assert(pdev->info.gfx_level >= GFX10_3);
|
||||
|
||||
if (!cmd_buffer->state.render.vrs_att.iview) {
|
||||
if (!render->vrs_att.iview) {
|
||||
/* When the current subpass has no VRS attachment, the VRS rates are expected to be 1x1, so we
|
||||
* can cheat by tweaking the different combiner modes.
|
||||
*/
|
||||
|
|
@ -4285,6 +4286,20 @@ radv_emit_fsr_state(struct radv_cmd_buffer *cmd_buffer)
|
|||
default:
|
||||
break;
|
||||
}
|
||||
} else if (render->ds_att.iview && radv_image_has_vrs_htile(device, render->ds_att.iview->image) &&
|
||||
!radv_htile_enabled(render->ds_att.iview->image, render->ds_att.iview->vk.base_mip_level)) {
|
||||
/* Otherwise, adjust the combiners to force VRS rate to 1x1 when the depth/stencil view is
|
||||
* incompatible with VRS which can happen with mipmaps.
|
||||
*/
|
||||
switch (htile_comb_mode) {
|
||||
case VK_FRAGMENT_SHADING_RATE_COMBINER_OP_MIN_KHR:
|
||||
case VK_FRAGMENT_SHADING_RATE_COMBINER_OP_REPLACE_KHR:
|
||||
rate_x = rate_y = 0;
|
||||
pipeline_comb_mode = V_028848_SC_VRS_COMB_MODE_PASSTHRU;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Disable VRS and use the rates from PS_ITER_SAMPLES if:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue