Repository navigation
fix(arty): avoid blocking worker startup during TLS teardown - #1036
Draft
martin-kolinek wants to merge 1 commit into
Draft
martin-kolinek wants to merge 1 commit into
martin-kolinek wants to merge 1 commit into
Conversation
Complete the existing FIFO barrier before the external thread exits, then poll the retained ready join once during TLS destruction. Preserve destroyed-slot lookup coverage without waiting under the Windows loader lock. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1036 +/- ##
=========================================
Coverage 99.9% 100.0%
=========================================
Files 854 130 -724
Lines 75041 8382 -66659
=========================================
- Hits 75032 8382 -66650
+ Misses 9 0 -9
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Agent assessment
Self-reported assessment, not an independent review.
Assessed revision:
4653dd5a0da0de9226f31960b36743068fb4df16↑ Equivalent isolated fixture passed 3,000 repetitions and retained destroyed-slot sensitivity.
↓ Official Windows release validation awaits merge.
↓ No stack dump from the original CI hang is available.
↓ Windows Server/provider concurrency has not yet been observed with this fix.
🤖 Fixes Bug 8263513.
Problem
Build 20261127.3 stalled in Arty's existing worker-slot teardown regression. Its TLS destructor could wait for a native blocking worker to start while Windows held the loader lock that startup needs.
Changes
Wait for the fixture's existing second task before the external thread exits. The existing single-worker FIFO pool publishes the retained first result before that barrier completes. During TLS destruction, poll the retained join once with
now_or_neverand require its successful result instead of entering a blocking executor.This changes only the test fixture. It still polls after the worker TLS slot is destroyed and verifies
42, preserving PR 896's original regression. Production runtime behavior is unchanged.Validation
Local: both existing tests passed in release mode using CI's
1.97.1-ms-20261116.4LLVM compiler:cargo +ms-prod-1.97@llvm test --locked --offline --release -p arty --all-features --test blocking_wait_cycles -- --nocapturejust anvil-clippy,just anvil-fmt --fix,just anvil-readme --fix, andjust anvil-spellcheckpassed. Equivalent isolated design evidence covers 3,000 successful teardown repetitions and an intentionalCURRENT.withnegative control that fails with destroyed-slotAccessError; no repetition helper or runtime mutation is included.PR checks cover broader platforms and quality. After merge, the existing main-branch publishing pipeline must show successful Windows release testing and advance beyond it; that provider result is not yet available.