i965_drv_vidoe: update max_thread for rendering
authorXiang, Haihao <haihao.xiang@intel.com>
Tue, 18 May 2010 04:55:51 +0000 (12:55 +0800)
committerXiang, Haihao <haihao.xiang@intel.com>
Wed, 2 Jun 2010 05:54:27 +0000 (13:54 +0800)
i965_drv_video/i965_render.c

index 08fa582..dc53529 100644 (file)
@@ -329,12 +329,14 @@ i965_subpic_render_wm_unit(VADriverContextP ctx)
     wm_state->wm4.stats_enable = 0;
     wm_state->wm4.sampler_state_pointer = render_state->wm.sampler->offset >> 5; 
 
-    if (IS_IRONLAKE(i965->intel.device_id))
+    if (IS_IRONLAKE(i965->intel.device_id)) {
         wm_state->wm4.sampler_count = 0;        /* hardware requirement */
-    else
+        wm_state->wm5.max_threads = 12 * 6 - 1;
+    } else {
         wm_state->wm4.sampler_count = (render_state->wm.sampler_count + 3) / 4;
+        wm_state->wm5.max_threads = 10 * 5 - 1;
+    }
 
-    wm_state->wm5.max_threads = PS_MAX_THREADS - 1;
     wm_state->wm5.thread_dispatch_enable = 1;
     wm_state->wm5.enable_16_pix = 1;
     wm_state->wm5.enable_8_pix = 0;
@@ -392,12 +394,14 @@ i965_render_wm_unit(VADriverContextP ctx)
     wm_state->wm4.stats_enable = 0;
     wm_state->wm4.sampler_state_pointer = render_state->wm.sampler->offset >> 5; 
 
-    if (IS_IRONLAKE(i965->intel.device_id))
+    if (IS_IRONLAKE(i965->intel.device_id)) {
         wm_state->wm4.sampler_count = 0;        /* hardware requirement */
-    else 
+        wm_state->wm5.max_threads = 12 * 6 - 1;
+    } else {
         wm_state->wm4.sampler_count = (render_state->wm.sampler_count + 3) / 4;
+        wm_state->wm5.max_threads = 10 * 5 - 1;
+    }
 
-    wm_state->wm5.max_threads = PS_MAX_THREADS - 1;
     wm_state->wm5.thread_dispatch_enable = 1;
     wm_state->wm5.enable_16_pix = 1;
     wm_state->wm5.enable_8_pix = 0;