u_upload_flush() is called each time r600_flush() is used. There is a comment specifically saying : /* XXX This shouldn't be really necessary, but removing it breaks some tests. * Needless buffer reallocations may significantly increase memory consumption, * so getting rid of this call is important. */ u_upload_flush(rctx->vbuf_mgr->uploader); I think the call to u_upload_flush() should be removed, unless someone knows a test case showing an issue ? I've done some regressions testing (piglit quick.tests, Unigine Heaven, Openarena, Lightsmark) and found almost no problem. The regressions reported by piglit concerned 3 tests : - fbo-sys-sub-blit - fp-fragment-position - kil-swizzle Which are all tests that fails sporadically (with or without patch applied) ; so this does not count as a regression. (All testing was done with HD4850) The simple attached patch removed function call + comment. Pierre-Eric
From 4596e9040bde510fd974d500af69070341871b46 Mon Sep 17 00:00:00 2001 From: Pierre-Eric Pelloux-Prayer <pelloux@xxxxxxxxx> Date: Fri, 10 Jun 2011 15:45:01 +0200 Subject: [PATCH 2/2] r600g: remove useless call to u_upload_flush No regressions found with : - piglit (quick.tests) - Unigine Heaven - Lightsmark - openarena - Imprudence (Second Life fork) --- src/gallium/drivers/r600/r600_pipe.c | 5 ----- 1 files changed, 0 insertions(+), 5 deletions(-) diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c index f924d79..ce2db88 100644 --- a/src/gallium/drivers/r600/r600_pipe.c +++ b/src/gallium/drivers/r600/r600_pipe.c @@ -138,11 +138,6 @@ static void r600_flush(struct pipe_context *ctx, dc++; #endif r600_context_flush(&rctx->ctx); - - /* XXX This shouldn't be really necessary, but removing it breaks some tests. - * Needless buffer reallocations may significantly increase memory consumption, - * so getting rid of this call is important. */ - u_upload_flush(rctx->vbuf_mgr->uploader); } static void r600_update_num_contexts(struct r600_screen *rscreen, int diff) -- 1.7.5.1
_______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx http://lists.freedesktop.org/mailman/listinfo/dri-devel