Join threads in MULTITHREADED_COMPUTE
example.
#5129
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Join all threads before returning from the test case, to ensure that we don't return from
main
until all openDevice
s have been dropped.This avoids a race condition in glibc in which a thread calling
dlclose
can unmap a shared library's code even while the main thread is still running its finalization functions. (See #5084 for details.) Joining all threads before returning from the test ensures that the Vulkan loader has finisheddlclose
-ing the Vulkan validation layer shared library beforemain
returns.Remove
skip
for this test on GL/llvmpipe. With this change, that has not been observed to crash. Without it, the test crashes within ten runs or so.Fixes #5084.
Fixed #4285.
Checklist
cargo fmt
.cargo clippy
.cargo xtask test
to run tests.CHANGELOG.md
. See simple instructions inside file.