gallium: remove PIPE_CAP_USER_CONSTANT_BUFFERS
[mesa.git] / src / gallium / drivers / r600 / r600_asm.h
index f786bab3d59ee90274e2f3cad4a8037b7d821e5b..d7cb64f0b7d8bb93573fdeb0611be74826daf5ef 100644 (file)
@@ -25,6 +25,7 @@
 
 #include "r600_pipe.h"
 #include "r600_isa.h"
+#include "tgsi/tgsi_exec.h"
 
 struct r600_bytecode_alu_src {
        unsigned                        sel;
@@ -52,6 +53,7 @@ struct r600_bytecode_alu {
        unsigned                        op;
        unsigned                        last;
        unsigned                        is_op3;
+       unsigned                        is_lds_idx_op;
        unsigned                        execute_mask;
        unsigned                        update_pred;
        unsigned                        pred_sel;
@@ -59,6 +61,7 @@ struct r600_bytecode_alu {
        unsigned                        bank_swizzle_force;
        unsigned                        omod;
        unsigned                        index_mode;
+       unsigned                        lds_idx;
 };
 
 struct r600_bytecode_tex {
@@ -118,7 +121,6 @@ struct r600_bytecode_vtx {
 struct r600_bytecode_gds {
        struct list_head                list;
        unsigned                        op;
-       unsigned                        gds_op;
        unsigned                        src_gpr;
        unsigned                        src_rel;
        unsigned                        src_sel_x;
@@ -131,6 +133,10 @@ struct r600_bytecode_gds {
        unsigned                        dst_sel_y;
        unsigned                        dst_sel_z;
        unsigned                        dst_sel_w;
+       unsigned                        uav_index_mode;
+       unsigned                        uav_id;
+       unsigned                        alloc_consume;
+       unsigned                        bcast_first_req;
 };
 
 struct r600_bytecode_output {
@@ -151,6 +157,12 @@ struct r600_bytecode_output {
        unsigned                        index_gpr;
 };
 
+struct r600_bytecode_rat {
+       unsigned                        id;
+       unsigned                        inst;
+       unsigned                        index_mode;
+};
+
 struct r600_bytecode_kcache {
        unsigned                        bank;
        unsigned                        mode;
@@ -174,11 +186,14 @@ struct r600_bytecode_cf {
        unsigned                        eg_alu_extended;
        unsigned                        barrier;
        unsigned                        end_of_program;
+       unsigned                        mark;
+       unsigned                        vpm;
        struct list_head                alu;
        struct list_head                tex;
        struct list_head                vtx;
        struct list_head                gds;
        struct r600_bytecode_output             output;
+       struct r600_bytecode_rat                rat;
        struct r600_bytecode_alu                *curr_bs_head;
        struct r600_bytecode_alu                *prev_bs_head;
        struct r600_bytecode_alu                *prev2_bs_head;
@@ -236,15 +251,15 @@ struct r600_bytecode {
        unsigned                        force_add_cf;
        uint32_t                        *bytecode;
        uint32_t                        fc_sp;
-       struct r600_cf_stack_entry      fc_stack[32];
+       struct r600_cf_stack_entry      fc_stack[TGSI_EXEC_MAX_NESTING];
        struct r600_stack_info          stack;
        unsigned        ar_loaded;
        unsigned        ar_reg;
        unsigned        ar_chan;
        unsigned        ar_handling;
        unsigned        r6xx_nop_after_rel_dst;
-       bool            index_loaded[2];
-       unsigned        index_reg[2]; /* indexing register CF_INDEX_[01] */
+       bool            index_loaded[2];
+       unsigned        index_reg[2]; /* indexing register CF_INDEX_[01] */
        unsigned        debug_id;
        struct r600_isa* isa;
 };
@@ -253,6 +268,8 @@ struct r600_bytecode {
 int eg_bytecode_cf_build(struct r600_bytecode *bc, struct r600_bytecode_cf *cf);
 int egcm_load_index_reg(struct r600_bytecode *bc, unsigned id, bool inside_alu_clause);
 int eg_bytecode_gds_build(struct r600_bytecode *bc, struct r600_bytecode_gds *gds, unsigned id);
+int eg_bytecode_alu_build(struct r600_bytecode *bc,
+                         struct r600_bytecode_alu *alu, unsigned id);
 /* r600_asm.c */
 void r600_bytecode_init(struct r600_bytecode *bc,
                        enum chip_class chip_class,
@@ -263,6 +280,8 @@ int r600_bytecode_add_alu(struct r600_bytecode *bc,
                const struct r600_bytecode_alu *alu);
 int r600_bytecode_add_vtx(struct r600_bytecode *bc,
                const struct r600_bytecode_vtx *vtx);
+int r600_bytecode_add_vtx_tc(struct r600_bytecode *bc,
+                            const struct r600_bytecode_vtx *vtx);
 int r600_bytecode_add_tex(struct r600_bytecode *bc,
                const struct r600_bytecode_tex *tex);
 int r600_bytecode_add_gds(struct r600_bytecode *bc,