i965/skl: Break down SIMD16 3-source instructions when required.
[mesa.git] / src / mesa / drivers / dri / i965 / brw_fs_visitor.cpp
index 60a7a97f0e07c8e9e49f52917fa3a5c159c02529..2920a82abc6e0625cfaf89b942313db1305bc291 100644 (file)
@@ -2497,16 +2497,7 @@ fs_visitor::visit(ir_discard *ir)
    cmp->flag_subreg = 1;
 
    if (brw->gen >= 6) {
-      /* For performance, after a discard, jump to the end of the shader.
-       * Only jump if all relevant channels have been discarded.
-       */
-      fs_inst *discard_jump = emit(FS_OPCODE_DISCARD_JUMP);
-      discard_jump->flag_subreg = 1;
-
-      discard_jump->predicate = (dispatch_width == 8)
-                                ? BRW_PREDICATE_ALIGN1_ANY8H
-                                : BRW_PREDICATE_ALIGN1_ANY16H;
-      discard_jump->predicate_inverse = true;
+      emit_discard_jump();
    }
 }