-
Notifications
You must be signed in to change notification settings - Fork 38
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
Add a synchronization mechanism for the AdvanceableRunner #403
Conversation
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.
Passing by :)
src/System/include/BipedalLocomotion/System/AdvanceableRunner.h
Outdated
Show resolved
Hide resolved
3163440
to
ae32890
Compare
Hi @diegoferigo thank you for reviewing, I applied all the changes you suggested |
The PR seems nice, but just to understand what is the intended use of this feature? |
Hi @traversaro I used this feature here: GiulioRomualdi/centroidal-mpc-walking@8c11834 In this application, I've two blocks running at a different rate and I would like to start the two threads simultaneously |
This PR introduces a synchronization mechanism for the
AdvanceableRunner
class. TheBarrier
class has been developed, the code was taken from here.c++20 introduces the barrier class however since this repo is based on c++17, the implementation of this new class was required.
Barrier
is then used in therun
method of the advanceable runner to synchronize the startup of all the threads.