i965: VS use SPF mode on sandybridge for now
authorZhenyu Wang <zhenyuw@linux.intel.com>
Fri, 17 Sep 2010 06:47:05 +0000 (14:47 +0800)
committerZhenyu Wang <zhenyuw@linux.intel.com>
Tue, 28 Sep 2010 07:58:20 +0000 (15:58 +0800)
Until conditional instructions were fixed, use SPF mode instead for now.

src/mesa/drivers/dri/i965/brw_vs_emit.c
src/mesa/drivers/dri/i965/gen6_vs_state.c

index 162ddc93c8beaef2ca18f4966371830d36b0fa85..8ac979dceaac38c1ff71226230de2302bca4d6bb 100644 (file)
@@ -1635,6 +1635,10 @@ void brw_vs_emit(struct brw_vs_compile *c )
       printf("\n");
    }
 
+   /* FIXME Need to fix conditional instruction to remove this */
+   if (intel->gen >= 6)
+       p->single_program_flow = GL_TRUE;
+
    brw_set_compression_control(p, BRW_COMPRESSION_NONE);
    brw_set_access_mode(p, BRW_ALIGN_16);
    if_depth_in_loop[loop_depth] = 0;
index 4080a9dedfd50e0a2659d0ab4d89ba68800bbfc0..50047a33a87d6b2b047baaa53ef7f35cfc7dc9f8 100644 (file)
@@ -93,7 +93,7 @@ upload_vs_state(struct brw_context *brw)
    BEGIN_BATCH(6);
    OUT_BATCH(CMD_3D_VS_STATE << 16 | (6 - 2));
    OUT_RELOC(brw->vs.prog_bo, I915_GEM_DOMAIN_INSTRUCTION, 0, 0);
-   OUT_BATCH((0 << GEN6_VS_SAMPLER_COUNT_SHIFT) |
+   OUT_BATCH(GEN6_VS_SPF_MODE | (0 << GEN6_VS_SAMPLER_COUNT_SHIFT) |
             (brw->vs.nr_surfaces << GEN6_VS_BINDING_TABLE_ENTRY_COUNT_SHIFT));
    OUT_BATCH(0); /* scratch space base offset */
    OUT_BATCH((1 << GEN6_VS_DISPATCH_START_GRF_SHIFT) |