-
Notifications
You must be signed in to change notification settings - Fork 538
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
5 additions
and
2 deletions.
There are no files selected for viewing
This file contains 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
3da03b9
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.
@durban should we do
parked.getAndSet(false)
unconditionally? Or should we only do that ifpolled == true
?3da03b9
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.
Probably only if
polled == true
. It's just unnecessary (but semantically harmless) work otherwise, I think.3da03b9
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.
Sorry, one more thing about this: can you give any pointers about how to write a test that exercises the bug this patches? I tried last night and failed miserably, I'm going to try again tonight. Thanks!
3da03b9
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.
I'm not really sure, I always tested with the FS2 test (which practically always failed on my machine). I guess the worker threads should go into untimed parking frequently (
parkLoop
), which must be finished by a polling system event, so that it will take the problematic branch. How to do that... I'm not sure. If the test does a lot ofblocking
, that could cause the compute threads to park... how to do the event, I don't know.3da03b9
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.
Thanks, finally got a test in place! Merged into my PR :)