On Wed, Mar 4, 2015 at 12:53 PM, Kenneth Graunke <kenn...@whitecape.org> wrote: > Gathering all the checks into a single place makes it easier to add new > workarounds. > > Signed-off-by: Kenneth Graunke <kenn...@whitecape.org> > Cc: Neil Roberts <n...@linux.intel.com> > Cc: Matt Turner <matts...@gmail.com> > --- > src/mesa/drivers/dri/i965/brw_fs_generator.cpp | 28 +++++---------- > src/mesa/drivers/dri/i965/brw_shader.cpp | 48 > ++++++++++++++++++++++++++ > src/mesa/drivers/dri/i965/brw_shader.h | 1 + > 3 files changed, 58 insertions(+), 19 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp > b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp > index cbe6191..8a5ad9b 100644 > --- a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp > +++ b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp > @@ -1613,6 +1613,9 @@ fs_generator::generate_code(const cfg_t *cfg, int > dispatch_width) > unreachable(!"Invalid instruction width"); > } > > + bool must_break_down_simd16_to_simd8 = dispatch_width == 16 && > + !brw_instruction_supports_simd16(brw, inst->opcode);
Instead of calling this for every instruction we emit, can we just put it in the existing if-statements we're modifying below? With that, Reviewed-by: Matt Turner <matts...@gmail.com> _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev