331889d067
When a thread is created, it is expected that some other thread (usually the creating thread) will want to make sure it completes. This is done using the pthread_join() or wait_for_thread() calls. It is possible that threads end before another thread waits for its completion. That's why there is a dead thread list for each team, which holds thread ids and their exit status so that a call to pthread_join() or wait_for_thread() in the future can complete succesfully. The dead thread list was limited to 32 threads per team. If there would be more, the oldest thread would be kicked off. This could cause issues in situations where a team would create more than 32 threads, and would start waiting for their result after they have finished. Some of the calls would fail because the threads would no longer be in the dead list. This specifically caused problems for cargo (the Rust package manager), which could depending on the number of dependencies, could create more than 32 threads. See: https://github.com/nielx/rust/issues/3 This change removes the limit of dead threads within a team. Note that there is a risk that a badly written program that does not detach or joins its threads can make this an endless list, but the impact is relatively small (dead threads only occupy a bit of kernel memory). Change-Id: I0135dd54e10ee48a529f23228d21237d4f1a74e2 Reviewed-on: https://review.haiku-os.org/c/haiku/+/3178 Reviewed-by: Adrien Destugues <pulkomandy@gmail.com> |
||
---|---|---|
.. | ||
app | ||
audio | ||
binary_compatibility | ||
bluetooth | ||
debug | ||
debugger | ||
device | ||
drivers | ||
file_systems | ||
firewire | ||
fs_shell | ||
graphics | ||
i2c | ||
index_server | ||
input | ||
interface | ||
kernel | ||
libroot | ||
locale | ||
media | ||
midi | ||
mount | ||
net | ||
notification | ||
package | ||
preferences | ||
runtime_loader | ||
screen_saver | ||
shared | ||
storage | ||
support | ||
syslog_daemon | ||
system | ||
textencoding | ||
tracker | ||
usb_vision | ||
userlandfs | ||
virtio | ||
vmdk | ||
wmi |