Skip to content
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

[AdaptiveTree] Fix spurious wakeups on TreeUpdateThread #1661

Merged
merged 1 commit into from
Aug 28, 2024

Conversation

CastagnaIT
Copy link
Collaborator

Description

This problem was causing a delay on manifest updates due to wrong timings
and so weird buffering with some live streaming

was due to spurious wakeups where the previous wait_for was exiting early by returning std::cv_status::no_timeout
and so the while loop restarted, and the interval also each time restarted

Motivation and context

fix #1660

How has this been tested?

https://livesim2.dashif.org/livesim2/segtimeline_1/testpic_2s/Manifest.mpd
by looking at log timing between manifest downloads

Screenshots (if appropriate):

Types of change

  • Bug fix (non-breaking change which fixes an issue)
  • Clean up (non-breaking change which removes non-working, unmaintained functionality)
  • Improvement (non-breaking change which improves existing functionality)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that will cause existing functionality to change)
  • Cosmetic change (non-breaking change that doesn't touch code)
  • None of the above (please explain below)

Checklist:

  • I have read the Contributing document
  • My code follows the Code Guidelines of this project
  • My change requires a change to the Wiki documentation
  • I have updated the documentation accordingly

This problem was causing a delay on manifest updates due to wrong timings

was due to spurious wakeups where the previous wait_for was exiting early
by returning std::cv_status::no_timeout
and so the while loop restarted, and the interval also each time restarted
@CastagnaIT CastagnaIT added Type: Fix non-breaking change which fixes an issue Backport: Needed v22 Piers labels Aug 27, 2024
@matthuisman
Copy link
Contributor

yes to 21 backport please :)

@matthuisman
Copy link
Contributor

will test tonight and report back

Copy link
Contributor

@matthuisman matthuisman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍

@CastagnaIT
Copy link
Collaborator Author

good! yes i will backport and i will make new releases

@CastagnaIT CastagnaIT merged commit 57d6f36 into xbmc:Piers Aug 28, 2024
10 checks passed
@CastagnaIT CastagnaIT deleted the fix_spurious_wakeups branch August 28, 2024 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backport: Done Type: Fix non-breaking change which fixes an issue v22 Piers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] [21] minimumUpdatePeriod sometimes double
2 participants