Skip to content

[5.7]🍒Ensure clocks properly respect leeways and use raw time for calculations for continuous clocks #58472

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

Merged

Conversation

phausler
Copy link
Contributor

Original PR: #58396

Continuous clocks incorrectly used non raw clock values (which could result in missing time frames in cases where the raw clock did not align with dispatch's expectations).

This aligns those expectations further as well as handling the leeway functions for the clock sources.

Risk: Low

…ons for continuous clocks (swiftlang#58396)

* Ensure clocks properly respect leeways and use raw time for calculations for continuous clocks

* slurp up time calcualtions to inline forms

* ensure the tolerance codepaths get tested as well

* Use task local storage for task sources in leeway based calculations

* use comparison assertions for leeway based calculations

* Whitespace cleanup

* Use the CLOCK_MONOTONIC value for linux to be compatible with linux scheduling for dispatch

* remove incorrect paren in macro check for OpenBSD

* Address feedback and remove stray ;
@phausler phausler requested a review from a team as a code owner April 27, 2022 22:46
@phausler
Copy link
Contributor Author

@swift-ci please smoke test

@phausler
Copy link
Contributor Author

@swift-ci please test

@phausler phausler merged commit 40a930e into swiftlang:release/5.7 May 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants