freedreno/ir3: don't DCE ij_pix if used for pre-fs-texture-fetch
[mesa.git] / src / freedreno / ir3 / ir3.h
index 34447c2cc2b0f4bb55cec700e4e82945731e8f21..8b8788a8a97571a84fcc32177423b2e977d40e64 100644 (file)
@@ -268,8 +268,12 @@ struct ir3_instruction {
                        int off;              /* component/offset */
                } fo;
                struct {
-                       struct ir3_block *block;
-               } inout;
+                       /* for sysvals, identifies the sysval type.  Mostly so we can
+                        * identify the special cases where a sysval should not be DCE'd
+                        * (currently, just pre-fs texture fetch)
+                        */
+                       gl_system_value sysval;
+               } input;
        };
 
        /* transient values used during various algorithms: */
@@ -1058,13 +1062,13 @@ void ir3_print(struct ir3 *ir);
 void ir3_print_instr(struct ir3_instruction *instr);
 
 /* depth calculation: */
+struct ir3_shader_variant;
 int ir3_delayslots(struct ir3_instruction *assigner,
                struct ir3_instruction *consumer, unsigned n);
 void ir3_insert_by_depth(struct ir3_instruction *instr, struct list_head *list);
-void ir3_depth(struct ir3 *ir);
+void ir3_depth(struct ir3 *ir, struct ir3_shader_variant *so);
 
 /* copy-propagate: */
-struct ir3_shader_variant;
 void ir3_cp(struct ir3 *ir, struct ir3_shader_variant *so);
 
 /* group neighbors and insert mov's to resolve conflicts: */