diff options
author | Tom Tromey <tromey@adacore.com> | 2022-12-13 12:03:34 -0700 |
---|---|---|
committer | Tom Tromey <tromey@adacore.com> | 2023-01-17 07:03:26 -0700 |
commit | 63078a04984b73e1fdeb4571a63605ee5c13f929 (patch) | |
tree | c5c7be98dd5323cc23b89bcc533fee341a94ff84 /gdb/contrib | |
parent | 55e0daa3a3dcf6e1648fa96029a0a361cc110911 (diff) | |
download | gdb-63078a04984b73e1fdeb4571a63605ee5c13f929.zip gdb-63078a04984b73e1fdeb4571a63605ee5c13f929.tar.gz gdb-63078a04984b73e1fdeb4571a63605ee5c13f929.tar.bz2 |
Avoid submitting empty tasks in parallel_for_each
I found that parallel_for_each would submit empty tasks to the thread
pool. For example, this can happen if the number of tasks is smaller
than the number of available threads. In the DWARF reader, this
resulted in the cooked index containing empty sub-indices. This patch
arranges to instead shrink the result vector and process the trailing
entries in the calling thread.
Diffstat (limited to 'gdb/contrib')
0 files changed, 0 insertions, 0 deletions