summaryrefslogtreecommitdiff
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-12-25 08:57:22 -0800
committerEric Anholt <eric@anholt.net>2011-01-04 13:01:41 -0800
commitd4ae5f3411cc43657f7ecf1037bcccb2844adfd5 (patch)
tree8cfac514857e96c1be7ff15e4aaf7d8cf8db0017 /src/mesa/drivers
parent1feecbdb00cc838be8c7de0396f8a82707b6f6e8 (diff)
intel: Only do frame throttling at glFlush time when using frontbuffer.
This is the hack for input interactivity of frontbuffer rendering (like we do for backbuffer at intelDRI2Flush()) by waiting for the n-2 frame to complete before starting a new one. However, for an application doing multiple contexts or regular rebinding of a single context, this would end up lockstepping the CPU to the GPU because every unbind was considered the end of a frame. Improves WOW performance on my Ironlake by 48.8% (+/- 2.3%, n=5) (cherry picked from commit b01b73c482474609aceb6bb13b083e96c06ba353)
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/intel/intel_context.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c
index 9c222c7b485..d183d275e73 100644
--- a/src/mesa/drivers/dri/intel/intel_context.c
+++ b/src/mesa/drivers/dri/intel/intel_context.c
@@ -565,7 +565,8 @@ intel_glFlush(struct gl_context *ctx)
intel_flush(ctx);
intel_flush_front(ctx);
- intel->need_throttle = GL_TRUE;
+ if (intel->is_front_buffer_rendering)
+ intel->need_throttle = GL_TRUE;
}
void