-
Notifications
You must be signed in to change notification settings - Fork 217
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 abstraction for condition variables #1252
Comments
Looking into doing this as bplib (for DTN) relies on condition variables for synchronization and it would benefit from having an OSAL API that provides this capability. |
jphickey
added a commit
to jphickey/osal
that referenced
this issue
Aug 10, 2022
This initial commit defines the conceptual condition variable API. This is not implemented yet for any OS, but should be implementable on POSIX, RTEMS, and VxWorks 7.x. Older VxWorks releases may not have the underlying support to implement this.
jphickey
added a commit
to jphickey/osal
that referenced
this issue
Aug 10, 2022
This initial commit defines the conceptual condition variable API. This is not implemented yet for any OS, but should be implementable on POSIX, RTEMS, and VxWorks 7.x. Older VxWorks releases may not have the underlying support to implement this.
jphickey
added a commit
to jphickey/osal
that referenced
this issue
Aug 23, 2022
Adds a complete implementation of condition variables for POSIX. Includes coverage and unit tests. RTEMS and VxWorks will temporarily use a "no-condvar" placeholder until an implementation for those systems is added.
jphickey
added a commit
to jphickey/osal
that referenced
this issue
Aug 23, 2022
This initial commit defines the conceptual condition variable API. This is not implemented yet for any OS, but should be implementable on POSIX, RTEMS, and VxWorks 7.x. Older VxWorks releases may not have the underlying support to implement this.
dzbaker
added a commit
that referenced
this issue
Sep 8, 2022
Fix #1252, condition variable API for OSAL
travis-r-wheatley
pushed a commit
to travis-r-wheatley/osal
that referenced
this issue
Sep 16, 2022
This initial commit defines the conceptual condition variable API. This is not implemented yet for any OS, but should be implementable on POSIX, RTEMS, and VxWorks 7.x. Older VxWorks releases may not have the underlying support to implement this.
travis-r-wheatley
pushed a commit
to travis-r-wheatley/osal
that referenced
this issue
Sep 16, 2022
Adds a complete implementation of condition variables for POSIX. Includes coverage and unit tests. RTEMS and VxWorks will temporarily use a "no-condvar" placeholder until an implementation for those systems is added.
thesamprice
pushed a commit
to thesamprice/osal
that referenced
this issue
Sep 22, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
POSIX condition variables can be useful for implementing worker thread pools, allowing worker task(s) to pend for work and dispatcher/manager tasks to unblock those workers once a job becomes available.
Describe the solution you'd like
Abstraction of something like POSIX condition variables via OSAL APIs.
Describe alternatives you've considered
Some of the worker pool concepts may be implemented with simple semaphores, but those aren't ideal for some use cases:
Note that in the POSIX OSAL the binary semaphore is, in fact, implemented using condition variables underneath - where the condition is just a single boolean value. But only this limited use-case is exposed/available to applications.
As a backward-compatible compromise of sorts - it may be possible to build on the current binary sem concept but allow the application to register its own "condition test" routine beyond the simple boolean.
Additional context
VxWorks support is not fully clear, I think VxWorks 7 has the underlying APIs to implement this, but 6.x might not.
Requester Info
Joseph Hickey, Vantage Systems, Inc.
The text was updated successfully, but these errors were encountered: