gallium: add PIPE_CAP_TGSI_BALLOT
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Thu, 30 Mar 2017 09:16:09 +0000 (11:16 +0200)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Wed, 5 Apr 2017 13:29:31 +0000 (15:29 +0200)
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
17 files changed:
src/gallium/docs/source/screen.rst
src/gallium/drivers/etnaviv/etnaviv_screen.c
src/gallium/drivers/freedreno/freedreno_screen.c
src/gallium/drivers/i915/i915_screen.c
src/gallium/drivers/llvmpipe/lp_screen.c
src/gallium/drivers/nouveau/nv30/nv30_screen.c
src/gallium/drivers/nouveau/nv50/nv50_screen.c
src/gallium/drivers/nouveau/nvc0/nvc0_screen.c
src/gallium/drivers/r300/r300_screen.c
src/gallium/drivers/r600/r600_pipe.c
src/gallium/drivers/radeonsi/si_pipe.c
src/gallium/drivers/softpipe/sp_screen.c
src/gallium/drivers/svga/svga_screen.c
src/gallium/drivers/swr/swr_screen.cpp
src/gallium/drivers/vc4/vc4_screen.c
src/gallium/drivers/virgl/virgl_screen.c
src/gallium/include/pipe/p_defines.h

index f1b91363d642a1086c582dda7660e0bc48e509af..c1b298228337b2c3e74c445e37418fc751abc191 100644 (file)
@@ -384,6 +384,8 @@ The integer capabilities:
 * ``PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE``: The page size of sparse buffers in
   bytes, or 0 if sparse buffers are not supported. The page size must be at
   most 64KB.
+* ``PIPE_CAP_TGSI_BALLOT``: Whether the BALLOT and READ_* opcodes as well as
+  the SUBGROUP_* semantics are supported.
 
 
 .. _pipe_capf:
index 7bff0fdde3d2d3897273b67ae3f8256a95dcb8a7..151a1e031e0e5ec87274244e0a77ef792aab8185 100644 (file)
@@ -248,6 +248,7 @@ etna_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
 
    /* Stream output. */
index 3f189080330383cbf6455a62f853a0236179a26b..cc6b148965a61bf9457448c9b9bb991182e8830f 100644 (file)
@@ -305,6 +305,7 @@ fd_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
        case PIPE_CAP_TGSI_CLOCK:
        case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
        case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+       case PIPE_CAP_TGSI_BALLOT:
                return 0;
 
        case PIPE_CAP_MAX_VIEWPORTS:
index 70dc31f017306f68cb959b790d5a54205c0acd45..ce5348a4b385db0f7edd1c1c8d035c785b9d714d 100644 (file)
@@ -304,6 +304,7 @@ i915_get_param(struct pipe_screen *screen, enum pipe_cap cap)
    case PIPE_CAP_TGSI_TEX_TXF_LZ:
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
 
    case PIPE_CAP_MAX_VIEWPORTS:
index 8abe6e7629f4da733131360b7b4f70f9613fa549..5fe6ae50831931e6132abd8be4f7c941fcd393d4 100644 (file)
@@ -350,6 +350,7 @@ llvmpipe_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
    }
    /* should only get here on unhandled cases */
index 18304d20539fc14ee5020b1ec39069dc92550c4e..95464f7cdc8765f2c3aed5e61455503d4ddb8efb 100644 (file)
@@ -214,6 +214,7 @@ nv30_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
 
    case PIPE_CAP_VENDOR_ID:
index ccd3426c4e19862384f64ba7ca001437065297c4..9e8eeacdbd438c2b80914434b49532dce4e1e63b 100644 (file)
@@ -266,6 +266,7 @@ nv50_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
 
    case PIPE_CAP_VENDOR_ID:
index afbb2d065252a9fb9e39104dd9e4601dad19e24d..064848db4abe51cb2b9cd4a43c0488a99d311316 100644 (file)
@@ -289,6 +289,7 @@ nvc0_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
    case PIPE_CAP_INT64_DIVMOD:
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
 
    case PIPE_CAP_VENDOR_ID:
index 04fd0efe757279fdeb05a439dcad6ea8bd679363..3eedd9ea78024526f633cbefc0a4f45b76dd5d1b 100644 (file)
@@ -236,6 +236,7 @@ static int r300_get_param(struct pipe_screen* pscreen, enum pipe_cap param)
         case PIPE_CAP_TGSI_CLOCK:
         case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
         case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+        case PIPE_CAP_TGSI_BALLOT:
             return 0;
 
         /* SWTCL-only features. */
index 2bea318982228ded51ca166ab4ba416316c0c2d9..5014f2525cf0cae9d9ecc7813cd7ca0cb161d76b 100644 (file)
@@ -384,6 +384,7 @@ static int r600_get_param(struct pipe_screen* pscreen, enum pipe_cap param)
        case PIPE_CAP_TGSI_CLOCK:
        case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
        case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+       case PIPE_CAP_TGSI_BALLOT:
                return 0;
 
        case PIPE_CAP_DOUBLES:
index e163d7bd38c99c159988e96623d3e82f2c42e403..2a6d1510e59533b034b6b8e91a97120e36920ebb 100644 (file)
@@ -503,6 +503,7 @@ static int si_get_param(struct pipe_screen* pscreen, enum pipe_cap param)
        case PIPE_CAP_TGSI_MUL_ZERO_WINS:
        case PIPE_CAP_UMA:
        case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
+       case PIPE_CAP_TGSI_BALLOT:
                return 0;
 
        case PIPE_CAP_QUERY_BUFFER_OBJECT:
index 32f3ec9486c28dac80379447c33688df99545d33..b8d70484ec8d09f791b9c9cef9daf73480aa048d 100644 (file)
@@ -300,6 +300,7 @@ softpipe_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
    case PIPE_CAP_SHADER_BUFFER_OFFSET_ALIGNMENT:
       return 4;
index 6ed4d9abccd02957e4731c2ce6abc95e1d4eaac1..6fa10fad60b15458f740a70446dfc9ee522e4e71 100644 (file)
@@ -430,6 +430,7 @@ svga_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
    }
 
index 2d80ca452b223956e897bd6b0555116879c1dd62..0a5060beb165ec067b2883ea9bf18d3ea31db747 100644 (file)
@@ -322,6 +322,7 @@ swr_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
 
    case PIPE_CAP_VENDOR_ID:
index 5a53cd97cfd01cb92e15ef8c6df92c24e0a0a99a..9030c4baf4bb5211abaa94a59942b2f2222b08e9 100644 (file)
@@ -250,6 +250,7 @@ vc4_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
         case PIPE_CAP_TGSI_CLOCK:
         case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
         case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+        case PIPE_CAP_TGSI_BALLOT:
                 return 0;
 
                 /* Stream output. */
index c3206598add379b16d642f7e26b9c99bee8bd36b..8e0117c9890a49b91e4a617c635dc00de43ca5b4 100644 (file)
@@ -259,6 +259,7 @@ virgl_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_TGSI_CLOCK:
    case PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE:
    case PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE:
+   case PIPE_CAP_TGSI_BALLOT:
       return 0;
    case PIPE_CAP_VENDOR_ID:
       return 0x1af4;
index cd857ae65a7a9d745d5dee94357df4464dc907f6..cb57a28baff700756cc195325bd0091c6cdbd2ed 100644 (file)
@@ -760,6 +760,7 @@ enum pipe_cap
    PIPE_CAP_TGSI_CLOCK,
    PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE,
    PIPE_CAP_SPARSE_BUFFER_PAGE_SIZE,
+   PIPE_CAP_TGSI_BALLOT,
 };
 
 #define PIPE_QUIRK_TEXTURE_BORDER_COLOR_SWIZZLE_NV50 (1 << 0)