diff options
author | jadahl@opera.com <jadahl@opera.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-31 09:07:02 +0000 |
---|---|---|
committer | jadahl@opera.com <jadahl@opera.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-31 09:07:02 +0000 |
commit | e3c4a9abad01205eed3e7556158dc05800051f7b (patch) | |
tree | 20dcee8098386d67ed3d9322f230b08e74b451fb /gpu/GLES2 | |
parent | 15770a4144bf8def5cd689351db58a842f2535a1 (diff) | |
download | chromium_src-e3c4a9abad01205eed3e7556158dc05800051f7b.zip chromium_src-e3c4a9abad01205eed3e7556158dc05800051f7b.tar.gz chromium_src-e3c4a9abad01205eed3e7556158dc05800051f7b.tar.bz2 |
gpu: Reuse transfer buffers more aggresively
By keeping track of transfer buffer usage (both sync and async), it is
possible to reuse an existing transfer buffer earlier than it is today.
For synchronous uploads, this is done by inserting tokens marking a
buffer's last usage. If such a token has passed, the buffer can be
reused.
For asynchronous uploads, this is done by adding an internal async
upload token to the GLES2Implementation and GLES2CmdDecoderImpl that
enumerates all asynchronous uploads. When an upload is completed, the
token is synchronized with the client which then can free the memory
associated with the async token.
The fenced allocator and mapped memory manager gets a callback that is
used to allow fenced allocator to make the user, in this case
GLES2Implementation, poll the current async upload token and free any
associated memory.
BUG=328808
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=260177
Review URL: https://codereview.chromium.org/116863003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@260507 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/GLES2')
-rw-r--r-- | gpu/GLES2/gl2chromium_autogen.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gpu/GLES2/gl2chromium_autogen.h b/gpu/GLES2/gl2chromium_autogen.h index 19f89f3..bbef99f 100644 --- a/gpu/GLES2/gl2chromium_autogen.h +++ b/gpu/GLES2/gl2chromium_autogen.h @@ -225,6 +225,8 @@ #define glAsyncTexSubImage2DCHROMIUM GLES2_GET_FUN(AsyncTexSubImage2DCHROMIUM) #define glAsyncTexImage2DCHROMIUM GLES2_GET_FUN(AsyncTexImage2DCHROMIUM) #define glWaitAsyncTexImage2DCHROMIUM GLES2_GET_FUN(WaitAsyncTexImage2DCHROMIUM) +#define glWaitAllAsyncTexImage2DCHROMIUM \ + GLES2_GET_FUN(WaitAllAsyncTexImage2DCHROMIUM) #define glDiscardFramebufferEXT GLES2_GET_FUN(DiscardFramebufferEXT) #define glLoseContextCHROMIUM GLES2_GET_FUN(LoseContextCHROMIUM) #define glInsertSyncPointCHROMIUM GLES2_GET_FUN(InsertSyncPointCHROMIUM) |