From: Connor Abbott <connor.w.abb...@intel.com> It appears that not only math instructions, but also MOV_BYTES or any instruction that uses Align1 mode cannot be in the middle of a dependency control sequence or the GPU will hang (at least on my BDW). This fixes GPU hangs in some fp64 tests.
Reviewed-by: Iago Toral Quiroga <ito...@igalia.com> --- src/mesa/drivers/dri/i965/brw_vec4.cpp | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp index 3bcd5cb..bc0a33b 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp @@ -838,6 +838,17 @@ vec4_visitor::is_dep_ctrl_unsafe(const vec4_instruction *inst) } /* + * Instructions that use Align1 mode cause the GPU to hang when inserted + * between a NoDDClr and NoDDChk in Align16 mode. Discovered empirically. + */ + + if (inst->opcode == VEC4_OPCODE_PACK_BYTES || + inst->opcode == VEC4_OPCODE_MOV_BYTES || + inst->is_math()) + return true; + + + /* * mlen: * In the presence of send messages, totally interrupt dependency * control. They're long enough that the chance of dependency @@ -851,12 +862,8 @@ vec4_visitor::is_dep_ctrl_unsafe(const vec4_instruction *inst) * enable of the last instruction, the optimization must be avoided. This is * to avoid instructions being shot down the pipeline when no writes are * required. - * - * math: - * Dependency control does not work well over math instructions. - * NB: Discovered empirically */ - return (inst->mlen || inst->predicate || inst->is_math()); + return (inst->mlen || inst->predicate); } /** -- 1.9.1 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev