summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i965/brw_fs.h
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-10-22 12:57:00 -0700
committerEric Anholt <eric@anholt.net>2010-10-22 14:53:21 -0700
commit07cd8f46acc34b04308f81de2faf05ba33da264b (patch)
treeb1e91f9595dae06cb713c3b50c709014efd09b2a /src/mesa/drivers/dri/i965/brw_fs.h
parentff622d5528c8cca465e29081c0792ca210cdd092 (diff)
i965: Add support for pull constants to the new FS backend.
Fixes glsl-fs-uniform-array-5, but not 6 which fails in ir_to_mesa.
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_fs.h')
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs.h b/src/mesa/drivers/dri/i965/brw_fs.h
index b571c23530..9b7fcde858 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.h
+++ b/src/mesa/drivers/dri/i965/brw_fs.h
@@ -76,6 +76,7 @@ enum fs_opcodes {
FS_OPCODE_DISCARD_AND,
FS_OPCODE_SPILL,
FS_OPCODE_UNSPILL,
+ FS_OPCODE_PULL_CONSTANT_LOAD,
};
@@ -100,6 +101,7 @@ public:
this->negate = 0;
this->abs = 0;
this->hw_reg = -1;
+ this->smear = -1;
}
/** Generic unset register constructor. */
@@ -162,6 +164,7 @@ public:
bool negate;
bool abs;
struct brw_reg fixed_hw_reg;
+ int smear; /* -1, or a channel of the reg to smear to all channels. */
/** Value for file == BRW_IMMMEDIATE_FILE */
union {
@@ -366,6 +369,7 @@ public:
int choose_spill_reg(struct ra_graph *g);
void spill_reg(int spill_reg);
void split_virtual_grfs();
+ void setup_pull_constants();
void calculate_live_intervals();
bool propagate_constants();
bool register_coalesce();
@@ -384,6 +388,7 @@ public:
void generate_ddy(fs_inst *inst, struct brw_reg dst, struct brw_reg src);
void generate_spill(fs_inst *inst, struct brw_reg src);
void generate_unspill(fs_inst *inst, struct brw_reg dst);
+ void generate_pull_constant_load(fs_inst *inst, struct brw_reg dst);
void emit_dummy_fs();
fs_reg *emit_fragcoord_interpolation(ir_variable *ir);