You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The FreeRTOS implementation does not guarantee that all tasks see all events in the same order.
The FreeRTOS implementation posts events to subscribing tasks' queues in priority order, from highest to lowest. If a subscribing task (Sub) has a higher priority than the sending task (Send), the FreeRTOS scheduler delivers that event to Sub as soon as it enters its queue, before Send has a chance to post it to other event queues. If Sub sends events in response to the event it receives, those new events will enter other tasks' queues before those from Send even though they occurred logically after them.
Options
Add a lightweight mutex to ErSendEx() that forces previous calls to complete before new calls start. This uses "priority inheritance" to linearize event ordering when there are overlapping sends. This can be made to have (almost) no cost in the case where there is no contention.
Disable the scheduler in ErSendEx() while posting events to queues. This is simpler than 1 but costs more.
The text was updated successfully, but these errors were encountered:
Background
The FreeRTOS implementation does not guarantee that all tasks see all events in the same order.
The FreeRTOS implementation posts events to subscribing tasks' queues in priority order, from highest to lowest. If a subscribing task (Sub) has a higher priority than the sending task (Send), the FreeRTOS scheduler delivers that event to Sub as soon as it enters its queue, before Send has a chance to post it to other event queues. If Sub sends events in response to the event it receives, those new events will enter other tasks' queues before those from Send even though they occurred logically after them.
Options
ErSendEx()
that forces previous calls to complete before new calls start. This uses "priority inheritance" to linearize event ordering when there are overlapping sends. This can be made to have (almost) no cost in the case where there is no contention.ErSendEx()
while posting events to queues. This is simpler than 1 but costs more.The text was updated successfully, but these errors were encountered: