i965/eu: Change gen == 7 to gen >= 7 in a couple brw_eu_emit.c cases.
authorKenneth Graunke <kenneth@whitecape.org>
Mon, 30 Jun 2014 14:26:30 +0000 (07:26 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Mon, 11 Aug 2014 02:01:52 +0000 (19:01 -0700)
Broadwell is going to use the brw_eu_emit.c code soon.  We want to get
the fake MRF handling and URB HWord channel mask handling.

We don't need the CMP thread switch workaround, though.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Matt Turner <mattst88@gmail.com>
src/mesa/drivers/dri/i965/brw_eu_emit.c

index e894abdaec015ef33aef049d28170b9809563674..038bfc60a59b7313414c156d6d274b0e4f8b80a6 100644 (file)
@@ -97,7 +97,7 @@ gen7_convert_mrf_to_grf(struct brw_compile *p, struct brw_reg *reg)
     * registers required for messages with EOT.
     */
    struct brw_context *brw = p->brw;
-   if (brw->gen == 7 && reg->file == BRW_MESSAGE_REGISTER_FILE) {
+   if (brw->gen >= 7 && reg->file == BRW_MESSAGE_REGISTER_FILE) {
       reg->file = BRW_GENERAL_REGISTER_FILE;
       reg->nr += GEN7_MRF_HACK_START;
    }
@@ -2265,7 +2265,7 @@ void brw_urb_WRITE(struct brw_compile *p,
 
    gen6_resolve_implied_move(p, &src0, msg_reg_nr);
 
-   if (brw->gen == 7 && !(flags & BRW_URB_WRITE_USE_CHANNEL_MASKS)) {
+   if (brw->gen >= 7 && !(flags & BRW_URB_WRITE_USE_CHANNEL_MASKS)) {
       /* Enable Channel Masks in the URB_WRITE_HWORD message header */
       brw_push_insn_state(p);
       brw_set_default_access_mode(p, BRW_ALIGN_1);