summaryrefslogtreecommitdiff
path: root/libs/gui/SurfaceControl.cpp
diff options
context:
space:
mode:
author Jorim Jaggi <jjaggi@google.com> 2018-07-17 13:48:33 +0200
committer Jorim Jaggi <jjaggi@google.com> 2018-07-17 16:57:06 +0200
commit0a3e7847012108f047a6582ebfb88026d640277f (patch)
tree38f6fc2edc609a577b6b9a33740aa0a00cc5a75f /libs/gui/SurfaceControl.cpp
parent9885bd4b3faf93a5651f069e52cbb346418e6ca5 (diff)
Do not block on allocating buffers
There is really no point in doing that because this can be done in an async way such that the first and subsequent dequeueBuffer still don't block because at that point allocation is very likely done. Furthermore, avoid calling setAsyncMode initially, as it will also block RT on buffer allocation. However, the default is false in any case, so we really don't need to call it. Also, only allocate one buffer at a time and don't block in dequeueBuffer on allocating buffers. It will likely have one buffer available already, and there is no point in waiting for other buffers to be allocated. Test: Press home with memory contention, observe less delay. Test: General smoke testing for increased jank Bug: 111517695 Change-Id: I9deb435013b2503178d2fe032151c1aaedd667af
Diffstat (limited to 'libs/gui/SurfaceControl.cpp')
0 files changed, 0 insertions, 0 deletions