From 81dcf8bdf23250dc04dd60994aaede0eb5c2dda7 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 00:33:42 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_line_loop_verts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index e4b535fb680..f5d21b8fdc5 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -241,6 +241,7 @@ static void TAG(render_line_loop_verts)( GLcontext *ctx, tmp = ALLOC_VERTS(nr+1); tmp = TAG(emit_verts)( ctx, j, nr, tmp ); tmp = TAG(emit_verts)( ctx, start, 1, tmp ); + (void) tmp; } else { TAG(emit_verts)( ctx, j, nr, ALLOC_VERTS(nr) ); -- cgit v1.2.3 From c2cee7741e877bb78480eae8b8b5bfb55b42158c Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 12:52:02 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_line_loop_verts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index f5d21b8fdc5..5151949063c 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -255,6 +255,7 @@ static void TAG(render_line_loop_verts)( GLcontext *ctx, tmp = ALLOC_VERTS(2); tmp = TAG(emit_verts)( ctx, start+1, 1, tmp ); tmp = TAG(emit_verts)( ctx, start, 1, tmp ); + (void) tmp; } FLUSH(); -- cgit v1.2.3 From 7d529736b9a07ddd5d8127c56cc25e5f6f5f2c12 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 13:39:39 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_tri_fan_verts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index 5151949063c..3d7e21f7459 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -360,6 +360,7 @@ static void TAG(render_tri_fan_verts)( GLcontext *ctx, tmp = ALLOC_VERTS( nr ); tmp = TAG(emit_verts)( ctx, start, 1, tmp ); tmp = TAG(emit_verts)( ctx, j, nr - 1, tmp ); + (void) tmp; currentsz = dmasz; } -- cgit v1.2.3 From c1d361bd0b3570811ca4e49d09d3282aaa5cbe01 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 14:41:35 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_quads_verts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index 3d7e21f7459..f363009be48 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -637,6 +637,7 @@ static void TAG(render_quads_verts)( GLcontext *ctx, /* Send v1, v2, v3 */ tmp = EMIT_VERTS(ctx, j + 1, 3, tmp); + (void) tmp; } } else { -- cgit v1.2.3 From 1e444c9960b18bcee5216a49db997b1c5ec14eca Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 15:08:01 -0800 Subject: swrast: Initialize tex_coords in handle_sample_op. --- src/mesa/swrast/s_atifragshader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/swrast/s_atifragshader.c b/src/mesa/swrast/s_atifragshader.c index 5fefae6c42b..e88ff191239 100644 --- a/src/mesa/swrast/s_atifragshader.c +++ b/src/mesa/swrast/s_atifragshader.c @@ -279,7 +279,7 @@ handle_sample_op(GLcontext * ctx, struct atifs_machine *machine, /* sample from unit idx using texinst->src as coords */ GLuint swizzle = texinst->swizzle; GLuint coord_source = texinst->src; - GLfloat tex_coords[4]; + GLfloat tex_coords[4] = { 0 }; if (coord_source >= GL_TEXTURE0_ARB && coord_source <= GL_TEXTURE7_ARB) { coord_source -= GL_TEXTURE0_ARB; -- cgit v1.2.3 From de9132f2740d3959af548e36e9b280e9853e59b6 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 15:27:30 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_poly_verts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index f363009be48..7eadfc6219f 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -400,6 +400,7 @@ static void TAG(render_poly_verts)( GLcontext *ctx, tmp = ALLOC_VERTS( nr ); tmp = TAG(emit_verts)( ctx, start, 1, tmp ); tmp = TAG(emit_verts)( ctx, j, nr - 1, tmp ); + (void) tmp; currentsz = dmasz; } -- cgit v1.2.3 From af4e4a73f78cb5ccb5b0295a4683b2eae5325d8f Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 16:02:09 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_tri_fan_elts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index 7eadfc6219f..28771004b88 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -951,6 +951,7 @@ static void TAG(render_tri_fan_elts)( GLcontext *ctx, tmp = ALLOC_ELTS( nr ); tmp = TAG(emit_elts)( ctx, elts+start, 1, tmp ); tmp = TAG(emit_elts)( ctx, elts+j, nr - 1, tmp ); + (void) tmp; FLUSH(); currentsz = dmasz; } -- cgit v1.2.3 From 9dc018618d024cfbf1f342b0141bb6aab21f41b1 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 16:18:08 -0800 Subject: t_dd_dmatmp.h: Silence unused value warnings in render_line_loop_elts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index 28771004b88..7182978a171 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -825,6 +825,7 @@ static void TAG(render_line_loop_elts)( GLcontext *ctx, tmp = ALLOC_ELTS(nr+1); tmp = TAG(emit_elts)( ctx, elts+j, nr, tmp ); tmp = TAG(emit_elts)( ctx, elts+start, 1, tmp ); + (void) tmp; } else { TAG(emit_elts)( ctx, elts+j, nr, ALLOC_ELTS(nr) ); @@ -838,6 +839,7 @@ static void TAG(render_line_loop_elts)( GLcontext *ctx, tmp = ALLOC_ELTS(2); tmp = TAG(emit_elts)( ctx, elts+start+1, 1, tmp ); tmp = TAG(emit_elts)( ctx, elts+start, 1, tmp ); + (void) tmp; } FLUSH(); -- cgit v1.2.3 From 7ea452dd35ba8ae063c70cc7fc916975c823ecd6 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 16:56:07 -0800 Subject: t_dd_dmatmp2.h: Silence unused value warnings. --- src/mesa/tnl_dd/t_dd_dmatmp2.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp2.h b/src/mesa/tnl_dd/t_dd_dmatmp2.h index 2380c49fdf4..cd225b6343e 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp2.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp2.h @@ -266,6 +266,7 @@ static void TAG(render_line_loop_verts)( GLcontext *ctx, if (j + nr < count) { ELT_TYPE *dest = ALLOC_ELTS( nr ); dest = TAG(emit_consecutive_elts)( ctx, dest, j, nr ); + (void) dest; j += nr - 1; CLOSE_ELTS(); } @@ -273,6 +274,7 @@ static void TAG(render_line_loop_verts)( GLcontext *ctx, ELT_TYPE *dest = ALLOC_ELTS( nr + 1 ); dest = TAG(emit_consecutive_elts)( ctx, dest, j, nr ); dest = TAG(emit_consecutive_elts)( ctx, dest, start, 1 ); + (void) dest; j += nr; CLOSE_ELTS(); } @@ -554,6 +556,7 @@ static void TAG(render_points_elts)( GLcontext *ctx, nr = MIN2( dmasz, count - j ); dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr ); + (void) dest; CLOSE_ELTS(); } } @@ -590,6 +593,7 @@ static void TAG(render_lines_elts)( GLcontext *ctx, nr = MIN2( dmasz, count - j ); dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr ); + (void) dest; CLOSE_ELTS(); } @@ -621,6 +625,7 @@ static void TAG(render_line_strip_elts)( GLcontext *ctx, nr = MIN2( dmasz, count - j ); dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr ); + (void) dest; CLOSE_ELTS(); } } @@ -671,6 +676,7 @@ static void TAG(render_line_loop_elts)( GLcontext *ctx, j += nr - 1; if (j + 1 >= count && (flags & PRIM_END)) { dest = TAG(emit_elts)( ctx, dest, elts+start, 1 ); + (void) dest; } CLOSE_ELTS(); } @@ -703,6 +709,7 @@ static void TAG(render_triangles_elts)( GLcontext *ctx, nr = MIN2( dmasz, count - j ); dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr ); + (void) dest; CLOSE_ELTS(); } } @@ -734,6 +741,7 @@ static void TAG(render_tri_strip_elts)( GLcontext *ctx, dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr ); + (void) dest; CLOSE_ELTS(); } } @@ -759,6 +767,7 @@ static void TAG(render_tri_fan_elts)( GLcontext *ctx, dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+start, 1 ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr - 1 ); + (void) dest; CLOSE_ELTS(); } } @@ -785,6 +794,7 @@ static void TAG(render_poly_elts)( GLcontext *ctx, dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+start, 1 ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr - 1 ); + (void) dest; CLOSE_ELTS(); } } @@ -843,6 +853,7 @@ static void TAG(render_quad_strip_elts)( GLcontext *ctx, nr = MIN2( dmasz, count - j ); dest = ALLOC_ELTS( nr ); dest = TAG(emit_elts)( ctx, dest, elts+j, nr ); + (void) dest; CLOSE_ELTS(); } } -- cgit v1.2.3 From cd1a09e3bbdb907e3b806e68400804310dc168ce Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 18:42:18 -0800 Subject: glsl: Initialize member label of struct slang_operation to NULL. --- src/mesa/shader/slang/slang_compile_operation.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/shader/slang/slang_compile_operation.c b/src/mesa/shader/slang/slang_compile_operation.c index 3e2bdbc91ff..be73094ca04 100644 --- a/src/mesa/shader/slang/slang_compile_operation.c +++ b/src/mesa/shader/slang/slang_compile_operation.c @@ -52,6 +52,7 @@ slang_operation_construct(slang_operation * oper) _slang_variable_scope_ctr(oper->locals); oper->fun = NULL; oper->var = NULL; + oper->label = NULL; return GL_TRUE; } -- cgit v1.2.3 From 20590b97336c4ebe5d2bcee51d66820e1e5d26c8 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 20:20:02 -0800 Subject: t_dd_dmatmp.h: Silence unused value warning in render_poly_elts. --- src/mesa/tnl_dd/t_dd_dmatmp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/tnl_dd/t_dd_dmatmp.h b/src/mesa/tnl_dd/t_dd_dmatmp.h index 7182978a171..d568bfdb584 100644 --- a/src/mesa/tnl_dd/t_dd_dmatmp.h +++ b/src/mesa/tnl_dd/t_dd_dmatmp.h @@ -991,6 +991,7 @@ static void TAG(render_poly_elts)( GLcontext *ctx, tmp = ALLOC_ELTS( nr ); tmp = TAG(emit_elts)( ctx, elts+start, 1, tmp ); tmp = TAG(emit_elts)( ctx, elts+j, nr - 1, tmp ); + (void) tmp; FLUSH(); currentsz = dmasz; } -- cgit v1.2.3 From 0aef54ba627c748a43f601228c725f5ba79be002 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 22:00:19 -0800 Subject: swrast: Silence uninitialized variable warnings in ss_tritmp.h. --- src/mesa/swrast_setup/ss_tritmp.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/swrast_setup/ss_tritmp.h b/src/mesa/swrast_setup/ss_tritmp.h index 724b5e94fa5..bd20a8d972f 100644 --- a/src/mesa/swrast_setup/ss_tritmp.h +++ b/src/mesa/swrast_setup/ss_tritmp.h @@ -41,9 +41,9 @@ static void TAG(triangle)(GLcontext *ctx, GLuint e0, GLuint e1, GLuint e2 ) GLenum mode = GL_FILL; GLuint facing = 0; GLchan saved_color[3][4]; - GLfloat saved_col0[3][4]; - GLfloat saved_spec[3][4]; - GLfloat saved_index[3]; + GLfloat saved_col0[3][4] = { { 0 } }; + GLfloat saved_spec[3][4] = { { 0 } }; + GLfloat saved_index[3] = { 0 }; v[0] = &verts[e0]; v[1] = &verts[e1]; -- cgit v1.2.3 From aa44efb04504fb6f8a1a2ff9d99388d173f7181a Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 22:17:16 -0800 Subject: st/mesa: Silence uninitialized variables warnings in st_draw.c. --- src/mesa/state_tracker/st_draw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_draw.c b/src/mesa/state_tracker/st_draw.c index c76bff91819..6f5248cbe57 100644 --- a/src/mesa/state_tracker/st_draw.c +++ b/src/mesa/state_tracker/st_draw.c @@ -371,7 +371,7 @@ setup_interleaved_attribs(GLcontext *ctx, { struct pipe_context *pipe = ctx->st->pipe; GLuint attr; - const GLubyte *offset0; + const GLubyte *offset0 = NULL; for (attr = 0; attr < vp->num_inputs; attr++) { const GLuint mesaAttr = vp->index_to_input[attr]; @@ -550,7 +550,7 @@ st_draw_vbo(GLcontext *ctx, GLuint attr; struct pipe_vertex_element velements[PIPE_MAX_ATTRIBS]; unsigned num_vbuffers, num_velements; - GLboolean userSpace; + GLboolean userSpace = GL_FALSE; /* Gallium probably doesn't want this in some cases. */ if (!index_bounds_valid) -- cgit v1.2.3 From 555dc25c4c5a0991fb6846ccc263a195717512de Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 23:47:32 -0800 Subject: swrast: Silence uninitialized variable warnings in s_triangle.c --- src/mesa/swrast/s_triangle.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/swrast/s_triangle.c b/src/mesa/swrast/s_triangle.c index 1ab0e19f922..a65b7b3e228 100644 --- a/src/mesa/swrast/s_triangle.c +++ b/src/mesa/swrast/s_triangle.c @@ -540,6 +540,9 @@ affine_span(GLcontext *ctx, SWspan *span, info.format = obj->Image[0][b]->_BaseFormat; \ info.filter = obj->MinFilter; \ info.envmode = unit->EnvMode; \ + info.er = 0; \ + info.eg = 0; \ + info.eb = 0; \ span.arrayMask |= SPAN_RGBA; \ \ if (info.envmode == GL_BLEND) { \ @@ -809,6 +812,9 @@ fast_persp_span(GLcontext *ctx, SWspan *span, info.format = obj->Image[0][b]->_BaseFormat; \ info.filter = obj->MinFilter; \ info.envmode = unit->EnvMode; \ + info.er = 0; \ + info.eg = 0; \ + info.eb = 0; \ \ if (info.envmode == GL_BLEND) { \ /* potential off-by-one error here? (1.0f -> 2048 -> 0) */ \ -- cgit v1.2.3 From 6c9870b54c1aad42ead5b2655c19c42343b8bf84 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sun, 13 Dec 2009 00:14:31 -0800 Subject: i810: Silence uninitialized variable warnings in i180tris.c --- src/mesa/drivers/dri/i810/i810tris.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/i810/i810tris.c b/src/mesa/drivers/dri/i810/i810tris.c index b508496fb69..213ba541cee 100644 --- a/src/mesa/drivers/dri/i810/i810tris.c +++ b/src/mesa/drivers/dri/i810/i810tris.c @@ -270,7 +270,8 @@ do { \ #define LOCAL_VARS(n) \ i810ContextPtr imesa = I810_CONTEXT(ctx); \ - GLuint color[n], spec[n]; \ + GLuint color[n] = { 0 }; \ + GLuint spec[n] = { 0 }; \ GLuint coloroffset = (imesa->vertex_size == 4 ? 3 : 4); \ GLboolean havespec = (imesa->vertex_size > 4); \ (void) color; (void) spec; (void) coloroffset; (void) havespec; -- cgit v1.2.3 From b18fa9f44810cde45519368170a505cdd0ebb936 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 14 Dec 2009 17:20:34 -0800 Subject: mach64: Silence uninitialized variable warnings. --- src/mesa/drivers/dri/mach64/mach64_tris.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/mach64/mach64_tris.c b/src/mesa/drivers/dri/mach64/mach64_tris.c index f2e8e2e3ae8..c2a0adfef02 100644 --- a/src/mesa/drivers/dri/mach64/mach64_tris.c +++ b/src/mesa/drivers/dri/mach64/mach64_tris.c @@ -1297,7 +1297,8 @@ do { \ #define LOCAL_VARS(n) \ mach64ContextPtr mmesa = MACH64_CONTEXT(ctx); \ - GLuint color[n], spec[n]; \ + GLuint color[n] = { 0 }; \ + GLuint spec[n] = { 0 }; \ GLuint vertex_size = mmesa->vertex_size; \ const GLuint xyoffset = 9; \ const GLuint coloroffset = 8; \ -- cgit v1.2.3 From 6e5fe39f5051bb758b98ed4b9a2b9d550b588edf Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Mon, 14 Dec 2009 17:30:15 -0800 Subject: mga: Silence uninitialized variable warnings. --- src/mesa/drivers/dri/mga/mgatris.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/mga/mgatris.c b/src/mesa/drivers/dri/mga/mgatris.c index b93a21c3acf..c1bcd4b8531 100644 --- a/src/mesa/drivers/dri/mga/mgatris.c +++ b/src/mesa/drivers/dri/mga/mgatris.c @@ -397,7 +397,8 @@ do { \ #define LOCAL_VARS(n) \ mgaContextPtr mmesa = MGA_CONTEXT(ctx); \ - GLuint color[n], spec[n]; \ + GLuint color[n] = { 0 }; \ + GLuint spec[n] = { 0 }; \ (void) color; (void) spec; -- cgit v1.2.3 From 987e9188d25e7c49eb7e6fe64dbe63dd2cfc25ef Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Tue, 15 Dec 2009 12:32:48 -0800 Subject: x86: ifdef out unused function cptr. --- src/mesa/x86/rtasm/x86sse.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/x86/rtasm/x86sse.c b/src/mesa/x86/rtasm/x86sse.c index 5aedf5b04be..647be995c12 100644 --- a/src/mesa/x86/rtasm/x86sse.c +++ b/src/mesa/x86/rtasm/x86sse.c @@ -7,10 +7,12 @@ #define DISASSEM 0 #define X86_TWOB 0x0f +#if 0 static unsigned char *cptr( void (*label)() ) { return (unsigned char *)(unsigned long)label; } +#endif static void do_realloc( struct x86_function *p ) -- cgit v1.2.3 From f23d01e726a57cd6b8e31f1049ee5853773df7ea Mon Sep 17 00:00:00 2001 From: Ian Romanick Date: Tue, 15 Dec 2009 12:14:04 -0800 Subject: intel: Fallback to software if drawable size is > MaxRenderbufferSize This prevents the mystery blank window if, for example, glxgears is resized larger than 2048 wide on 915. Since the Intel drivers in Mesa 7.6 lack GTT mapped fallbacks, the performance is a slideshow at best. On Mesa 7.7 and later the performance is much better. --- src/mesa/drivers/dri/intel/intel_buffers.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/intel/intel_buffers.c b/src/mesa/drivers/dri/intel/intel_buffers.c index e7357e78c53..4b8ac364f79 100644 --- a/src/mesa/drivers/dri/intel/intel_buffers.c +++ b/src/mesa/drivers/dri/intel/intel_buffers.c @@ -172,10 +172,15 @@ intel_draw_buffer(GLcontext * ctx, struct gl_framebuffer *fb) return; } - /* - * How many color buffers are we drawing into? + /* How many color buffers are we drawing into? + * + * If there are zero buffers or the buffer is too big, don't configure any + * regions for hardware drawing. We'll fallback to software below. Not + * having regions set makes some of the software fallback paths faster. */ - if (fb->_NumColorDrawBuffers == 0) { + if ((fb->Width > ctx->Const.MaxRenderbufferSize) + || (fb->Height > ctx->Const.MaxRenderbufferSize) + || (fb->_NumColorDrawBuffers == 0)) { /* writing to 0 */ colorRegions[0] = NULL; intel->constant_cliprect = GL_TRUE; -- cgit v1.2.3