gallium: add PIPE_CAP_TGSI_ATOMFADD to indicate support
authorIlia Mirkin <imirkin@alum.mit.edu>
Wed, 5 Dec 2018 05:21:34 +0000 (00:21 -0500)
committerIlia Mirkin <imirkin@alum.mit.edu>
Thu, 27 Dec 2018 01:04:57 +0000 (20:04 -0500)
ATOMFADD is a little special -- make drivers have to specify it
explicitly.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/auxiliary/util/u_screen.c
src/gallium/docs/source/screen.rst
src/gallium/include/pipe/p_defines.h

index aef21bc46ae0d3878d6493455c15a88ceb0985da..f1e8eda701f82d825330e173f9606639a7d5912d 100644 (file)
@@ -311,6 +311,7 @@ u_pipe_screen_get_param_defaults(struct pipe_screen *pscreen,
    case PIPE_CAP_MAX_COMBINED_SHADER_BUFFERS:
    case PIPE_CAP_MAX_COMBINED_HW_ATOMIC_COUNTERS:
    case PIPE_CAP_MAX_COMBINED_HW_ATOMIC_COUNTER_BUFFERS:
+   case PIPE_CAP_TGSI_ATOMFADD:
       return 0;
 
    case PIPE_CAP_MAX_GS_INVOCATIONS:
index 24a4d5031e5d13bb575c753d935f3c2cdace4499..8eb71ae82c2bd117631b4e831ff452d0ed7d4627 100644 (file)
@@ -480,6 +480,8 @@ subpixel precision bias in bits during conservative rasterization.
 * ``PIPE_CAP_SURFACE_SAMPLE_COUNT_TEXTURE``: Whether the driver
   supports pipe_surface overrides of resource nr_samples. If set, will
   enable EXT_multisampled_render_to_texture.
+* ``PIPE_CAP_TGSI_ATOMFADD``: Atomic floating point adds are supported on
+  images, buffers, and shared memory.
 
 .. _pipe_capf:
 
index 6d96f1ccb5beb01096ddcf7a1df46a940f123579..82c49c801e5cfdfb1c7f2cf7f00e9d660b18a082 100644 (file)
@@ -833,6 +833,7 @@ enum pipe_cap
    PIPE_CAP_MAX_TEXTURE_UPLOAD_MEMORY_BUDGET,
    PIPE_CAP_MAX_VERTEX_ELEMENT_SRC_OFFSET,
    PIPE_CAP_SURFACE_SAMPLE_COUNT,
+   PIPE_CAP_TGSI_ATOMFADD,
 };
 
 /**