radv/gfx10: Disable DCC with scanout.

Submitted by Bas Nieuwenhuizen on July 25, 2019, 2:34 p.m.

Details

Message ID 20190725143432.22937-1-bas@basnieuwenhuizen.nl
State New
Headers show
Series "radv/gfx10: Disable DCC with scanout." ( rev: 1 ) in Mesa

Not browsing as part of any series.

Commit Message

Bas Nieuwenhuizen July 25, 2019, 2:34 p.m.
(a) radv does not set the DCC fields required yet.
(b) radeonsi just broke their DCC metadata.

Fixes: f8b6c5a1a63 "radeonsi: rewrite si_get_opaque_metadata, also for gfx10 support"
---
 src/amd/vulkan/radv_image.c | 3 +++
 1 file changed, 3 insertions(+)

Patch hide | download patch | download mbox

diff --git a/src/amd/vulkan/radv_image.c b/src/amd/vulkan/radv_image.c
index 09413333cbb..4bcdb70214a 100644
--- a/src/amd/vulkan/radv_image.c
+++ b/src/amd/vulkan/radv_image.c
@@ -161,6 +161,9 @@  radv_use_dcc_for_image(struct radv_device *device,
 	if (image->shareable)
 		return false;
 
+	if (radv_surface_has_scanout(device, create_info))
+		return false;
+
 	/* TODO: Enable DCC for storage images. */
 	if ((pCreateInfo->usage & VK_IMAGE_USAGE_STORAGE_BIT) ||
 	    (pCreateInfo->flags & VK_IMAGE_CREATE_EXTENDED_USAGE_BIT))

Comments

bleh, you're right ....

So we should not be using DCC ...

On Thu, Jul 25, 2019 at 4:37 PM Samuel Pitoiset
<samuel.pitoiset@gmail.com> wrote:
>
> It's already disabled later in this function?
>
> On 7/25/19 4:34 PM, Bas Nieuwenhuizen wrote:
> > (a) radv does not set the DCC fields required yet.
> > (b) radeonsi just broke their DCC metadata.
> >
> > Fixes: f8b6c5a1a63 "radeonsi: rewrite si_get_opaque_metadata, also for gfx10 support"
> > ---
> >   src/amd/vulkan/radv_image.c | 3 +++
> >   1 file changed, 3 insertions(+)
> >
> > diff --git a/src/amd/vulkan/radv_image.c b/src/amd/vulkan/radv_image.c
> > index 09413333cbb..4bcdb70214a 100644
> > --- a/src/amd/vulkan/radv_image.c
> > +++ b/src/amd/vulkan/radv_image.c
> > @@ -161,6 +161,9 @@ radv_use_dcc_for_image(struct radv_device *device,
> >       if (image->shareable)
> >               return false;
> >
> > +     if (radv_surface_has_scanout(device, create_info))
> > +             return false;
> > +
> >       /* TODO: Enable DCC for storage images. */
> >       if ((pCreateInfo->usage & VK_IMAGE_USAGE_STORAGE_BIT) ||
> >           (pCreateInfo->flags & VK_IMAGE_CREATE_EXTENDED_USAGE_BIT))
It's already disabled later in this function?

On 7/25/19 4:34 PM, Bas Nieuwenhuizen wrote:
> (a) radv does not set the DCC fields required yet.
> (b) radeonsi just broke their DCC metadata.
>
> Fixes: f8b6c5a1a63 "radeonsi: rewrite si_get_opaque_metadata, also for gfx10 support"
> ---
>   src/amd/vulkan/radv_image.c | 3 +++
>   1 file changed, 3 insertions(+)
>
> diff --git a/src/amd/vulkan/radv_image.c b/src/amd/vulkan/radv_image.c
> index 09413333cbb..4bcdb70214a 100644
> --- a/src/amd/vulkan/radv_image.c
> +++ b/src/amd/vulkan/radv_image.c
> @@ -161,6 +161,9 @@ radv_use_dcc_for_image(struct radv_device *device,
>   	if (image->shareable)
>   		return false;
>   
> +	if (radv_surface_has_scanout(device, create_info))
> +		return false;
> +
>   	/* TODO: Enable DCC for storage images. */
>   	if ((pCreateInfo->usage & VK_IMAGE_USAGE_STORAGE_BIT) ||
>   	    (pCreateInfo->flags & VK_IMAGE_CREATE_EXTENDED_USAGE_BIT))