From 7c71ef3a3d0cf2620525f468960cdc76a0fb0d33 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Wed, 12 Dec 2007 10:25:19 -0800 Subject: [intel] Move bufmgr back to context instead of screen, fixing glthreads. Putting the bufmgr in the screen is not thread-safe since the emit_reloc changes. It also led to a significant performance hit from pthread usage for the attempted thread-safety (up to 12% of a cpu spent on refcounting protection in single-threaded 965). The motivation had been to allow multi-context bufmgr sharing in classic mode, but it wasn't worth the cost. --- src/mesa/drivers/dri/intel/intel_depthstencil.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/mesa/drivers/dri/intel/intel_depthstencil.c') diff --git a/src/mesa/drivers/dri/intel/intel_depthstencil.c b/src/mesa/drivers/dri/intel/intel_depthstencil.c index d269a85a3c..90baecd8c2 100644 --- a/src/mesa/drivers/dri/intel/intel_depthstencil.c +++ b/src/mesa/drivers/dri/intel/intel_depthstencil.c @@ -95,12 +95,12 @@ map_regions(GLcontext * ctx, { struct intel_context *intel = intel_context(ctx); if (depthRb && depthRb->region) { - intel_region_map(intel->intelScreen, depthRb->region); + intel_region_map(intel, depthRb->region); depthRb->pfMap = depthRb->region->map; depthRb->pfPitch = depthRb->region->pitch; } if (stencilRb && stencilRb->region) { - intel_region_map(intel->intelScreen, stencilRb->region); + intel_region_map(intel, stencilRb->region); stencilRb->pfMap = stencilRb->region->map; stencilRb->pfPitch = stencilRb->region->pitch; } @@ -113,12 +113,12 @@ unmap_regions(GLcontext * ctx, { struct intel_context *intel = intel_context(ctx); if (depthRb && depthRb->region) { - intel_region_unmap(intel->intelScreen, depthRb->region); + intel_region_unmap(intel, depthRb->region); depthRb->pfMap = NULL; depthRb->pfPitch = 0; } if (stencilRb && stencilRb->region) { - intel_region_unmap(intel->intelScreen, stencilRb->region); + intel_region_unmap(intel, stencilRb->region); stencilRb->pfMap = NULL; stencilRb->pfPitch = 0; } -- cgit v1.2.3