summaryrefslogtreecommitdiff
path: root/libs/androidfw/StringPool.cpp
diff options
context:
space:
mode:
author Kweku Adams <kwekua@google.com> 2022-03-22 18:49:48 +0000
committer Kweku Adams <kwekua@google.com> 2022-03-22 21:59:47 +0000
commit7d15491708122a8d0a4aae7a3af48ffeb02a7cac (patch)
treed03e44b3a24b859a45cc94a706c703d7e97e9eca /libs/androidfw/StringPool.cpp
parentb0ea1d0bd89711d5363aa92ac53841a6697888da (diff)
Optimize pending job queue iteration.
Batch the jobs pulled during iteration so that we pull several of an app's jobs from the queue sequentially (resulting in some out of order pulls) instead of pulling purely based on the sort order. Batching it this way will mean we try to run several jobs of the same app at the same, resulting in fewer process restarts, and can allow the iteration runtime to amortize to O(A*J) instead of O(A*J*log(A)) for A <= 33, where A = # apps and J = average # jobs per app. Bug: 204924801 Test: atest FrameworksServicesTests:PendingJobQueueTest Change-Id: I4d3dc17afb4d4ab0fb573d75a319bdb20a68c634
Diffstat (limited to 'libs/androidfw/StringPool.cpp')
0 files changed, 0 insertions, 0 deletions