diff options
| author | 2022-02-04 14:17:11 -0800 | |
|---|---|---|
| committer | 2022-02-13 15:07:38 -0800 | |
| commit | bc2231439041494989b023a79bd3181928d17eaa (patch) | |
| tree | b9f560b1b8824f2bd44df46927c478efef7fa47f /libs/jpegrecoverymap/jpegencoderhelper.cpp | |
| parent | d12d361a58bf97fc555ea47c8098907105fb068c (diff) | |
Have DumpPool return futures
Have DumpPool return futures when tasks are enqueued, instead of
having users register their task with a string. This change has the
following benefits:
* Simplifies DumpPool since it no longer needs to keep the map of
strings to futures.
* Allows adding a set of tasks to DumpPool that might not be known at
build time. For example, we can add a bunch of tasks from a vector,
without needing to generate arbitrary strings for them.
* Reduces the ability to misuse DumpPool. Before this change, the user
had to come up with strings representing each task, and needed to
know a task with said name existed. This change moves it from being a
runtime error to being a compile time one.
Test: atest dumpstate_smoke_test
Change-Id: Ic6c1a983b049e5236ac596e8af200a21c07ac31b
Diffstat (limited to 'libs/jpegrecoverymap/jpegencoderhelper.cpp')
0 files changed, 0 insertions, 0 deletions