nir/vtn: Add support for kernel images to SPIRV-to-NIR.
[mesa.git] / src / compiler / shader_info.h
index 57b0eabd79a0fda81b1cc846aa5e88c21e265136..c49fed923e28427747312c51e6f5a15a579926c6 100644 (file)
@@ -42,7 +42,9 @@ struct spirv_supported_capabilities {
    bool descriptor_indexing;
    bool device_group;
    bool draw_parameters;
+   bool float32_atomic_add;
    bool float64;
+   bool float64_atomic_add;
    bool fragment_shader_sample_interlock;
    bool fragment_shader_pixel_interlock;
    bool geometry_streams;
@@ -55,6 +57,7 @@ struct spirv_supported_capabilities {
    bool int64_atomics;
    bool integer_functions2;
    bool kernel;
+   bool kernel_image;
    bool min_lod;
    bool multiview;
    bool physical_storage_buffer_address;
@@ -191,6 +194,11 @@ typedef struct shader_info {
    /* Whether flrp has been lowered. */
    bool flrp_lowered:1;
 
+   /* Whether nir_lower_io has been called to lower derefs.
+    * nir_variables for inputs and outputs might not be present in the IR.
+    */
+   bool io_lowered:1;
+
    /* Whether the shader writes memory, including transform feedback. */
    bool writes_memory:1;
 
@@ -232,8 +240,8 @@ typedef struct shader_info {
          /** Whether or not this shader uses EndPrimitive */
          bool uses_end_primitive:1;
 
-         /** Whether or not this shader uses non-zero streams */
-         bool uses_streams:1;
+         /** The streams used in this shaders (max. 4) */
+         uint8_t active_stream_mask:4;
       } gs;
 
       struct {
@@ -300,6 +308,17 @@ typedef struct shader_info {
 
          /** gl_FragDepth layout for ARB_conservative_depth. */
          enum gl_frag_depth_layout depth_layout:3;
+
+         /**
+          * Interpolation qualifiers for drivers that lowers color inputs
+          * to system values.
+          */
+         unsigned color0_interp:3; /* glsl_interp_mode */
+         bool color0_sample:1;
+         bool color0_centroid:1;
+         unsigned color1_interp:3; /* glsl_interp_mode */
+         bool color1_sample:1;
+         bool color1_centroid:1;
       } fs;
 
       struct {