vbo: remove unnecessary max_basevertex computation
authorIlia Mirkin <imirkin@alum.mit.edu>
Wed, 17 Aug 2016 21:12:10 +0000 (17:12 -0400)
committerIlia Mirkin <imirkin@alum.mit.edu>
Fri, 19 Aug 2016 00:26:34 +0000 (20:26 -0400)
The max basevertex is already computed and added into max_index by the
caller, _tnl_draw_prims.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/mesa/vbo/vbo_split.c

index 2f957462a8c0a95437492590e196499b96665f10..79d7dd408348528c44a75a69230d3fb4dd3cf1ad 100644 (file)
@@ -108,14 +108,6 @@ void vbo_split_prims( struct gl_context *ctx,
                      vbo_draw_func draw,
                      const struct split_limits *limits )
 {
-   GLint max_basevertex = prim->basevertex;
-   GLuint i;
-
-   for (i = 1; i < nr_prims; i++)
-      max_basevertex = MAX2(max_basevertex, prim[i].basevertex);
-
-   /* XXX max_basevertex is computed but not used, why? */
-
    if (ib) {
       if (limits->max_indices == 0) {
         /* Could traverse the indices, re-emitting vertices in turn.