From 67e9ae856355be532455c1cf1211d59b3a4c5992 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Sun, 26 Aug 2012 15:29:12 -0700 Subject: i965: Disable the swrast context setup on GL 3.1 core. I've reviewed the code, and the swrast callsites remaining are all in drawpixels/copypixels/bitmap/accum, or _swrast_BlitFramebuffer that shouldn't be hit. A piglit run with the context setup disabled on legacy GL and GLES2 showed regressions only in the copypixels and drawpixels tests. If the context type is forced, this reduces the shader_runner maximum heap size for glsl-algebraic-add-add-1.shader_test from 15,137,496b to 4,165,376b. Reviewed-by: Kenneth Graunke Reviewed-by: Ian Romanick Reviewed-by: Chad Versace --- src/mesa/drivers/dri/i965/brw_context.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/mesa/drivers/dri/i965/brw_context.c') diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c index 7f8197d..f83f89f 100644 --- a/src/mesa/drivers/dri/i965/brw_context.c +++ b/src/mesa/drivers/dri/i965/brw_context.c @@ -140,7 +140,9 @@ brwCreateContext(int api, /* Initialize swrast, tnl driver tables: */ intelInitSpanFuncs(ctx); - TNL_CONTEXT(ctx)->Driver.RunPipeline = _tnl_run_pipeline; + TNLcontext *tnl = TNL_CONTEXT(ctx); + if (tnl) + tnl->Driver.RunPipeline = _tnl_run_pipeline; ctx->Const.MaxDualSourceDrawBuffers = 1; ctx->Const.MaxDrawBuffers = BRW_MAX_DRAW_BUFFERS; -- cgit v1.1