diff options
author | Eric Anholt <[email protected]> | 2012-12-06 10:43:13 -0800 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2012-12-11 10:12:54 -0800 |
commit | 2c69a9fb60e1b5e879a9b9bb4d0c08485483a7db (patch) | |
tree | 7742c9a7e97cce1394a7448aa12890969abcab11 /src/mesa/drivers | |
parent | 6a1490bc8ffd6b0259e7d36d04ac207f39a029bb (diff) |
i965: Let brw_flag_reg() choose the flag reg and subreg.
We're about to start using the f0.1 subregister.
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_blorp_blit.cpp | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_eu.c | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_eu.h | 6 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_fs_emit.cpp | 4 |
4 files changed, 7 insertions, 7 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp b/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp index e8604e70195..69dab75d2c6 100644 --- a/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp +++ b/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp @@ -1175,7 +1175,7 @@ brw_blorp_blit_program::decode_msaa(unsigned num_samples, void brw_blorp_blit_program::kill_if_outside_dst_rect() { - struct brw_reg f0 = brw_flag_reg(); + struct brw_reg f0 = brw_flag_reg(0, 0); struct brw_reg g1 = retype(brw_vec1_grf(1, 7), BRW_REGISTER_TYPE_UW); struct brw_reg null16 = vec16(retype(brw_null_reg(), BRW_REGISTER_TYPE_UW)); diff --git a/src/mesa/drivers/dri/i965/brw_eu.c b/src/mesa/drivers/dri/i965/brw_eu.c index c60b16c3871..46ada8d995c 100644 --- a/src/mesa/drivers/dri/i965/brw_eu.c +++ b/src/mesa/drivers/dri/i965/brw_eu.c @@ -70,7 +70,7 @@ void brw_set_predicate_control_flag_value( struct brw_compile *p, GLuint value ) if (value != 0xff) { if (value != p->flag_value) { brw_push_insn_state(p); - brw_MOV(p, brw_flag_reg(), brw_imm_uw(value)); + brw_MOV(p, brw_flag_reg(0, 0), brw_imm_uw(value)); p->flag_value = value; brw_pop_insn_state(p); } diff --git a/src/mesa/drivers/dri/i965/brw_eu.h b/src/mesa/drivers/dri/i965/brw_eu.h index c806e0bb5df..e43b543dd96 100644 --- a/src/mesa/drivers/dri/i965/brw_eu.h +++ b/src/mesa/drivers/dri/i965/brw_eu.h @@ -568,11 +568,11 @@ static INLINE struct brw_reg brw_notification_1_reg(void) } -static INLINE struct brw_reg brw_flag_reg( void ) +static INLINE struct brw_reg brw_flag_reg(int reg, int subreg) { return brw_uw1_reg(BRW_ARCHITECTURE_REGISTER_FILE, - BRW_ARF_FLAG, - 0); + BRW_ARF_FLAG + reg, + subreg); } diff --git a/src/mesa/drivers/dri/i965/brw_fs_emit.cpp b/src/mesa/drivers/dri/i965/brw_fs_emit.cpp index 4e8b44e5684..0750b86793c 100644 --- a/src/mesa/drivers/dri/i965/brw_fs_emit.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs_emit.cpp @@ -516,7 +516,7 @@ fs_generator::generate_ddy(fs_inst *inst, struct brw_reg dst, struct brw_reg src void fs_generator::generate_discard(fs_inst *inst) { - struct brw_reg f0 = brw_flag_reg(); + struct brw_reg f0 = brw_flag_reg(0, 0); if (intel->gen >= 6) { struct brw_reg g1 = retype(brw_vec1_grf(1, 7), BRW_REGISTER_TYPE_UW); @@ -744,7 +744,7 @@ fs_generator::generate_varying_pull_constant_load_gen7(fs_inst *inst, void fs_generator::generate_mov_dispatch_to_flags() { - struct brw_reg f0 = brw_flag_reg(); + struct brw_reg f0 = brw_flag_reg(0, 0); struct brw_reg g1 = retype(brw_vec1_grf(1, 7), BRW_REGISTER_TYPE_UW); assert (intel->gen >= 6); |