-
Notifications
You must be signed in to change notification settings - Fork 803
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some AsyncMemoize fixes #18074
Some AsyncMemoize fixes #18074
Conversation
|
/azp run |
Azure Pipelines successfully started running 2 pipeline(s). |
tests/FSharp.Compiler.ComponentTests/CompilerService/AsyncMemoize.fs
Outdated
Show resolved
Hide resolved
Yeah, this returns an async computation that decreases request count in fsharp/src/Compiler/Facilities/AsyncMemoize.fs Lines 72 to 76 in 95fe045
Benign in real usage but can be tripped in tests causing job cancellation to not happen. |
/azp run |
Azure Pipelines successfully started running 2 pipeline(s). |
tests/FSharp.Compiler.ComponentTests/CompilerService/AsyncMemoize.fs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you :)
Got a stress test failure with this fix already included :/ https://dev.azure.com/dnceng-public/public/_build/results?buildId=883746&view=ms.vss-test-web.build-test-results-tab&runId=23109844&resultId=100187&paneView=debug |
I'll try to stress test the stress test locally and reproduce it. The timeout in stress-test is very generous, it doesn't look like a fluke. |
I can't repro the deadlock but after some 1.5k iterations I got once:
|
Description
AsyncMemoize
tests became flaky again because of recent changes, for example: https://dev.azure.com/dnceng-public/public/_build/results?buildId=881078&view=ms.vss-test-web.build-test-results-tab&runId=23026540&resultId=100189&paneView=debugThe problem was a not atomic handling of request count. It was possible to cancel the request mid-flight in such a way that the finally block decreasing request count never run.
Checklist