summaryrefslogtreecommitdiffstats
path: root/src/amd
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2018-04-18 14:34:55 +0200
committerSamuel Pitoiset <[email protected]>2018-07-02 10:43:33 +0200
commit02db2363f0f9174ecd8b3484c186b250c2a1259a (patch)
tree5f14ad798492bd03fa6503005d030399d1332abb /src/amd
parentff7daadca1b335002d9bc198e38a3faa88b34478 (diff)
radv: reset the image's predicate after a color decompression pass
After performing a fast-clear eliminate, a FMASK decompress, or a DCC decompress, we can reset the predicate to FALSE. With that, the GPU should be able to skip unnecessary color decompression passes. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/amd')
-rw-r--r--src/amd/vulkan/radv_meta_fast_clear.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/amd/vulkan/radv_meta_fast_clear.c b/src/amd/vulkan/radv_meta_fast_clear.c
index 8ba0a932c0e..136557080d9 100644
--- a/src/amd/vulkan/radv_meta_fast_clear.c
+++ b/src/amd/vulkan/radv_meta_fast_clear.c
@@ -671,6 +671,11 @@ radv_emit_color_decompress(struct radv_cmd_buffer *cmd_buffer,
if (radv_image_has_dcc(image)) {
cmd_buffer->state.predicating = false;
radv_emit_set_predication_state_from_image(cmd_buffer, image, false);
+
+ /* Clear the image's fast-clear eliminate predicate because
+ * FMASK and DCC also imply a fast-clear eliminate.
+ */
+ radv_set_dcc_need_cmask_elim_pred(cmd_buffer, image, false);
}
radv_meta_restore(&saved_state, cmd_buffer);
}