freedreno/a6xx: Don't blit with R2D_RAW
authorKristian H. Kristensen <hoegsberg@google.com>
Wed, 1 Jul 2020 21:50:52 +0000 (14:50 -0700)
committerMarge Bot <eric+marge@anholt.net>
Tue, 14 Jul 2020 06:12:22 +0000 (06:12 +0000)
Map all formats to a valid ifmt.  FMT6_10_10_10_2_UNORM_DEST still
doesn't work on the blitter so keep that one on the u_blitter path.

Fixes
dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.*
with FD_MESA_DEBUG=nogmem.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5717>

.gitlab-ci/deqp-freedreno-a630-bypass-fails.txt
.gitlab-ci/traces-baremetal.yml
src/gallium/drivers/freedreno/a6xx/fd6_blitter.c
src/gallium/drivers/freedreno/a6xx/fd6_format.h

index 45fac70f001a67cdb93f42d029986901b21ca00d..db865ecf467b802150549052757dff0c31fff041 100644 (file)
@@ -67,16 +67,6 @@ dEQP-GLES31.functional.draw_buffers_indexed.overwrite_indexed.common_advanced_bl
 dEQP-GLES31.functional.draw_buffers_indexed.overwrite_indexed.common_advanced_blend_eq_buffer_blend_eq
 dEQP-GLES31.functional.draw_buffers_indexed.overwrite_indexed.common_advanced_blend_eq_buffer_separate_blend_eq
 dEQP-GLES31.functional.draw_buffers_indexed.overwrite_indexed.common_separate_blend_eq_buffer_blend_eq
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.11
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.15
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.17
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.18
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.2
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.3
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.6
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_implementation_draw_buffers.7
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_required_draw_buffers.19
-dEQP-GLES31.functional.draw_buffers_indexed.random.max_required_draw_buffers.3
 dEQP-GLES31.functional.image_load_store.early_fragment_tests.early_fragment_tests_depth_fbo
 dEQP-GLES31.functional.ssbo.layout.3_level_array.std140.column_major_mat4x2
 dEQP-GLES31.functional.ssbo.layout.3_level_unsized_array.std430.mat3
index 09df7af9365c967dabaa67ef3a0077b437563a2f..95da793883af8350fc3e18ed725f2f69327a3305 100644 (file)
@@ -72,7 +72,7 @@ traces:
     expectations:
       # Bad rendering -- some sort of gap in the upper right of the image.
       - device: freedreno-a630
-        checksum: 1c7411cebed6ba0015aaef102539fc5a
+        checksum: c6d7e9712631762b6acdd53bc1dd2aa3
   - path: humus/RaytracedShadows.trace
     expectations:
       - device: freedreno-a630
index feb2b44d4a4113b050a393dab7510a08fe3b56e0..e90807fc340d82b203f4a69e3f32e72cc12aa4ab 100644 (file)
@@ -80,7 +80,7 @@ ok_format(enum pipe_format pfmt)
        if (fmt == FMT6_NONE)
                return false;
 
-       if (fd6_ifmt(fmt) == 0)
+       if (fmt == FMT6_10_10_10_2_UNORM_DEST)
                return false;
 
        return true;
@@ -409,15 +409,6 @@ emit_blit_or_clear_texture(struct fd_context *ctx, struct fd_ringbuffer *ring,
                        dfmt = FMT6_Z24_UNORM_S8_UINT_AS_R8G8B8A8;
                        break;
                }
-               case PIPE_FORMAT_B5G6R5_UNORM:
-               case PIPE_FORMAT_B5G5R5A1_UNORM:
-               case PIPE_FORMAT_B5G5R5X1_UNORM:
-               case PIPE_FORMAT_B4G4R4A4_UNORM:
-                       color->ui[0] = float_to_ubyte(color->f[0]);
-                       color->ui[1] = float_to_ubyte(color->f[1]);
-                       color->ui[2] = float_to_ubyte(color->f[2]);
-                       color->ui[3] = float_to_ubyte(color->f[3]);
-                       break;
                default:
                        break;
                }
@@ -439,12 +430,10 @@ emit_blit_or_clear_texture(struct fd_context *ctx, struct fd_ringbuffer *ring,
                        OUT_RING(ring, _mesa_float_to_half(color->f[3]));
                        sfmt = FMT6_16_16_16_16_FLOAT;
                        break;
-
                case R2D_FLOAT32:
                case R2D_INT32:
                case R2D_INT16:
                case R2D_INT8:
-               case R2D_RAW:
                default:
                        OUT_RING(ring, color->ui[0]);
                        OUT_RING(ring, color->ui[1]);
index a7fe81084e760e548701730c3b78b49f267e053e..331450eb768546249117c596d4914ad7290eeb3a 100644 (file)
@@ -61,6 +61,9 @@ fd6_ifmt(enum a6xx_format fmt)
        case FMT6_8_8_8_8_UNORM:
        case FMT6_8_8_8_X8_UNORM:
        case FMT6_8_8_8_8_SNORM:
+       case FMT6_4_4_4_4_UNORM:
+       case FMT6_5_5_5_1_UNORM:
+       case FMT6_5_6_5_UNORM:
                return R2D_UNORM8;
 
        case FMT6_32_UINT:
@@ -77,6 +80,7 @@ fd6_ifmt(enum a6xx_format fmt)
        case FMT6_16_16_SINT:
        case FMT6_16_16_16_16_UINT:
        case FMT6_16_16_16_16_SINT:
+       case FMT6_10_10_10_2_UINT:
                return R2D_INT16;
 
        case FMT6_8_UINT:
@@ -85,6 +89,8 @@ fd6_ifmt(enum a6xx_format fmt)
        case FMT6_8_8_SINT:
        case FMT6_8_8_8_8_UINT:
        case FMT6_8_8_8_8_SINT:
+       case FMT6_Z24_UNORM_S8_UINT:
+       case FMT6_Z24_UNORM_S8_UINT_AS_R8G8B8A8:
                return R2D_INT8;
 
        case FMT6_16_UNORM:
@@ -102,16 +108,9 @@ fd6_ifmt(enum a6xx_format fmt)
        case FMT6_16_16_FLOAT:
        case FMT6_16_16_16_16_FLOAT:
        case FMT6_11_11_10_FLOAT:
+       case FMT6_10_10_10_2_UNORM_DEST:
                return R2D_FLOAT16;
 
-       case FMT6_10_10_10_2_UNORM_DEST:
-       case FMT6_4_4_4_4_UNORM:
-       case FMT6_5_5_5_1_UNORM:
-       case FMT6_5_6_5_UNORM:
-       case FMT6_10_10_10_2_UINT:
-       case FMT6_Z24_UNORM_S8_UINT:
-       case FMT6_Z24_UNORM_S8_UINT_AS_R8G8B8A8:
-               return R2D_RAW;
        default:
                unreachable("bad format");
                return 0;