-
Notifications
You must be signed in to change notification settings - Fork 531
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
Timer stealing without a concurrent data structure #3781
Merged
djspiewak
merged 43 commits into
typelevel:series/3.x
from
armanbilge:topic/timer-stealing-without-synchronization
Feb 19, 2024
Merged
Changes from 40 commits
Commits
Show all changes
43 commits
Select commit
Hold shift + click to select a range
8c68b69
First attempt at unsychronized timer heap
armanbilge 3881a92
Refactor so timers can be canceled on same thread
armanbilge 8bb7da7
Cancel at most once on owning thread
armanbilge 301be74
Merge branch 'series/3.5.x' into topic/timer-stealing-without-synchro…
armanbilge 8397877
Remove `TimerSkipList`
armanbilge 4352294
Better handling of external sleeps
armanbilge 7ae3761
`TimerNode` -> `Node`
armanbilge ac32fb2
Implement timer heap packing
armanbilge 76b9e83
Add test for externally canceled timers
armanbilge 2d19a69
Regenerate workflow
armanbilge b013c7e
Fix some tests
armanbilge 8aca9e3
Workaround Scala 3 crash
armanbilge 1d462fd
Formatting
armanbilge 1a4a249
Only null callback if it is non-null
armanbilge 7176530
`isCanceled` -> `isDeleted`
armanbilge 37cb91f
Fix nanoTime-wrapping test
armanbilge 1e1b82a
Delete dead code
armanbilge 8d08a32
Use atomic `getAndSet` in `ExternalSleepCancel`
armanbilge e0c644c
Track cancelation in generic sleep
armanbilge fb465db
Make cancelation robust to unpublished callback
armanbilge 0d1c55f
Merge remote-tracking branch 'upstream/series/3.5.x' into topic/timer…
armanbilge 856b151
Fix NPE when canceling removed timer
armanbilge 9d00ba0
Invalidate node index when removing
armanbilge bc8fcf9
Fix another NPE when canceling removed timer
armanbilge 9411431
Merge remote-tracking branch 'upstream/series/3.5.x' into topic/timer…
armanbilge 4a03e2f
Enable forking for `SleepDrift`
armanbilge 74c92ae
Use `Arrays.copyOf`
armanbilge 9f74fff
Remove branch from `overflowFree`
armanbilge c001d40
Add NOTICE
armanbilge 04e54ea
Add overview scaladoc for `TimerHeap`
armanbilge 80aeaae
Track externally deleted timers with counter
armanbilge 19449a0
Revert "Track externally deleted timers with counter"
armanbilge 6d0b285
Fix out-dated comment
armanbilge 3059d71
Fix outdated comments
armanbilge 87547e8
Track externally canceled timers with counter
armanbilge 7492faa
Track cancel state atomically for generic sleep
armanbilge 22ee156
Improve code comments
armanbilge 29f3e4d
Optimize `TimerHeap` packing strategy
armanbilge a1bb5d0
Merge branch 'series/3.x' into topic/timer-stealing-without-synchroni…
armanbilge 0856fa1
Regenerate workflow
armanbilge 1908673
Bump copyright year
armanbilge 02f1c9d
Handle exceptions in externally submitted sleeps
armanbilge 0927d34
Account for possible null heap in TimerHeap#steal
armanbilge File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
cats-effect | ||
Copyright 2020-2023 Typelevel | ||
Licensed under Apache License 2.0 (see LICENSE) | ||
|
||
This software contains portions of code derived from scala-js | ||
https://github.com/scala-js/scala-js | ||
Copyright EPFL | ||
Licensed under Apache License 2.0 (see LICENSE) |
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
56 changes: 0 additions & 56 deletions
56
core/jvm/src/main/java/cats/effect/unsafe/TimerSkipListNodeBase.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
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.
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.
2024