radeonsi: only upload (dump to L2) those descriptors that are used by shaders
[mesa.git] / src / gallium / drivers / svga / svga_tgsi_emit.h
index 1a1dac23507ce7da30652b47b25f55598e349491..114c9563e2b9948758264d7d8288136e6d2e8cbe 100644 (file)
@@ -28,6 +28,7 @@
 
 #include "tgsi/tgsi_scan.h"
 #include "svga_hw_reg.h"
+#include "svga_shader.h"
 #include "svga_tgsi.h"
 #include "svga3d_shaderdefs.h"
 
@@ -83,6 +84,9 @@ struct svga_shader_emitter
 
    int dynamic_branching_level;
 
+   unsigned num_output_writes;
+   boolean constant_color_output;
+
    boolean in_main_func;
 
    boolean created_common_immediate;
@@ -130,6 +134,11 @@ struct svga_shader_emitter
    struct svga_arl_consts arl_consts[12];
    int num_arl_consts;
    int current_arl;
+
+   unsigned pstipple_sampler_unit;
+
+   int num_samplers;
+   uint8_t sampler_target[PIPE_MAX_SAMPLERS];
 };
 
 
@@ -148,6 +157,9 @@ boolean
 svga_shader_emit_instructions(struct svga_shader_emitter *emit,
                               const struct tgsi_token *tokens);
 
+boolean
+svga_shader_emit_samplers_decl(struct svga_shader_emitter *emit);
+
 boolean
 svga_translate_decl_sm30(struct svga_shader_emitter *emit,
                          const struct tgsi_full_declaration *decl);