From 1b239a378614ea0c2aa486c8010474a2431c17ee Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Fri, 19 Feb 2021 12:44:50 -0500 Subject: [PATCH] panfrost: Hide MSAA 8x/16x support dEQP-GLES31.functional.texture.multisample.samples_16.sample_position is failing on Bifrost, and we already weren't advertising on Midgard. Until someone gets spare cycles to debug all the problems, keep it hidden behind a debug flag to avoid introducing bugs. Signed-off-by: Alyssa Rosenzweig Reviewed-by: Boris Brezillon Part-of: --- src/gallium/drivers/panfrost/pan_screen.c | 9 +++++---- src/panfrost/lib/pan_util.h | 1 + 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/gallium/drivers/panfrost/pan_screen.c b/src/gallium/drivers/panfrost/pan_screen.c index 1ab278d..1ab507e 100644 --- a/src/gallium/drivers/panfrost/pan_screen.c +++ b/src/gallium/drivers/panfrost/pan_screen.c @@ -66,6 +66,7 @@ static const struct debug_named_value panfrost_debug_options[] = { {"gl3", PAN_DBG_GL3, "Enable experimental GL 3.x implementation, up to 3.3"}, {"noafbc", PAN_DBG_NO_AFBC, "Disable AFBC support"}, {"nocrc", PAN_DBG_NO_CRC, "Disable transaction elimination"}, + {"msaa16", PAN_DBG_MSAA16, "Enable MSAA 8x and 16x support"}, DEBUG_NAMED_VALUE_END }; @@ -478,7 +479,7 @@ panfrost_is_format_supported( struct pipe_screen *screen, return false; /* MSAA 2x gets rounded up to 4x. MSAA 8x/16x only supported on v5+. - * TODO: Advertise on v5 */ + * TODO: debug MSAA 8x/16x */ switch (sample_count) { case 0: @@ -487,10 +488,10 @@ panfrost_is_format_supported( struct pipe_screen *screen, break; case 8: case 16: - if (dev->arch < 6) - return false; - else + if (dev->debug & PAN_DBG_MSAA16) break; + else + return false; default: return false; } diff --git a/src/panfrost/lib/pan_util.h b/src/panfrost/lib/pan_util.h index 72a8158..eb10bb8 100644 --- a/src/panfrost/lib/pan_util.h +++ b/src/panfrost/lib/pan_util.h @@ -39,5 +39,6 @@ #define PAN_DBG_GL3 0x0100 #define PAN_DBG_NO_AFBC 0x0200 #define PAN_DBG_FP16 0x0400 +#define PAN_DBG_MSAA16 0x0800 #endif /* PAN_UTIL_H */ -- 2.7.4