From 6ced98c94e28b41cc63ec94d4bdfec99d71db598 Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Mon, 20 Jul 2020 13:47:19 +0200 Subject: [PATCH] radv: disable CPU caching for the upload BO to reduce fetch latency AMDGPU_GEM_CREATE_CPU_GTT_USWC should be faster when CPU reads are unexpected (because they aren't cached). Signed-off-by: Samuel Pitoiset Reviewed-by: Bas Nieuwenhuizen Part-of: --- src/amd/vulkan/radv_cmd_buffer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c index 4b14e1ed0af..4130a62d3f9 100644 --- a/src/amd/vulkan/radv_cmd_buffer.c +++ b/src/amd/vulkan/radv_cmd_buffer.c @@ -483,7 +483,8 @@ radv_cmd_buffer_resize_upload_buf(struct radv_cmd_buffer *cmd_buffer, RADEON_DOMAIN_GTT, RADEON_FLAG_CPU_ACCESS| RADEON_FLAG_NO_INTERPROCESS_SHARING | - RADEON_FLAG_32BIT, + RADEON_FLAG_32BIT | + RADEON_FLAG_GTT_WC, RADV_BO_PRIORITY_UPLOAD_BUFFER); if (!bo) { -- 2.30.2