[Mesa-dev] [PATCH] radeonsi: don't expose 8xMSAA on slowest APUs

Marek Olšák maraeo at gmail.com
Fri Jan 5 18:33:56 UTC 2018


Please ignore this patch. I'm dropping it.

Marek

On Thu, Jan 4, 2018 at 1:54 AM, Marek Olšák <maraeo at gmail.com> wrote:
> From: Marek Olšák <marek.olsak at amd.com>
>
> i.e. Kabini, Mullins, Stoney.
>
> This was requested internally.
> ---
>  src/gallium/drivers/radeonsi/si_state.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
> index f88bf29..d52fccd 100644
> --- a/src/gallium/drivers/radeonsi/si_state.c
> +++ b/src/gallium/drivers/radeonsi/si_state.c
> @@ -2136,41 +2136,46 @@ static bool si_is_zs_format_supported(enum pipe_format format)
>  {
>         return si_translate_dbformat(format) != V_028040_Z_INVALID;
>  }
>
>  static boolean si_is_format_supported(struct pipe_screen *screen,
>                                       enum pipe_format format,
>                                       enum pipe_texture_target target,
>                                       unsigned sample_count,
>                                       unsigned usage)
>  {
> +       struct si_screen *sscreen = (struct si_screen*)screen;
>         unsigned retval = 0;
>
>         if (target >= PIPE_MAX_TEXTURE_TYPES) {
>                 R600_ERR("r600: unsupported texture type %d\n", target);
>                 return false;
>         }
>
>         if (!util_format_is_supported(format, usage))
>                 return false;
>
>         if (sample_count > 1) {
>                 if (!screen->get_param(screen, PIPE_CAP_TEXTURE_MULTISAMPLE))
>                         return false;
>
>                 if (usage & PIPE_BIND_SHADER_IMAGE)
>                         return false;
>
>                 switch (sample_count) {
>                 case 2:
>                 case 4:
> +                       break;
>                 case 8:
> +                       /* Don't expose 8x MSAA on slowest chips. */
> +                       if (sscreen->info.num_render_backends == 1)
> +                               return false;
>                         break;
>                 case 16:
>                         if (format == PIPE_FORMAT_NONE)
>                                 return true;
>                         else
>                                 return false;
>                 default:
>                         return false;
>                 }
>         }
> --
> 2.7.4
>


More information about the mesa-dev mailing list