softpipe: Enable PIPE_CAP_TGSI_ANY_REG_AS_ADDRESS;
authorEric Anholt <eric@anholt.net>
Wed, 15 Jan 2020 21:07:43 +0000 (13:07 -0800)
committerMarge Bot <eric+marge@anholt.net>
Thu, 23 Jul 2020 00:24:26 +0000 (00:24 +0000)
tgsi_exec.c uses the generic src load path for indirects, so we don't
actually need addr regs.  Saves extra intructions.

shader-db results:
total instructions in shared programs: 3346685 -> 3249052 (-2.92%)
instructions in affected programs: 961832 -> 864199 (-10.15%)

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6018>

src/gallium/drivers/softpipe/sp_screen.c

index 9e974ae889379577d64005b192660bb85fd34472..66a204ba25eb2a7d4aef2c8dd74e3d8dd4e2ff97 100644 (file)
@@ -254,6 +254,7 @@ softpipe_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_COPY_BETWEEN_COMPRESSED_AND_PLAIN_FORMATS:
    case PIPE_CAP_TGSI_ARRAY_COMPONENTS:
    case PIPE_CAP_TGSI_TEXCOORD:
+   case PIPE_CAP_TGSI_ANY_REG_AS_ADDRESS:
       return 1;
    case PIPE_CAP_CLEAR_TEXTURE:
       return 1;