Patent ID: 7421693

Claim:
A method of synchronizing a group of tasks in a microcontroller, said method comprising: receiving a plurality of packets in sequence; each task in said group of tasks processing a packet in said plurality of packets; each task in said group of tasks making an initial determination of one or more paths that said each task is likely to follow, based on information in said packet; each task in said group of tasks declaring one of “need” or “no need” to access a shared resource via a signal in a plurality of signals, based on said initial determination; receiving the plurality of signals from the group of tasks; granting access to said shared resource, based on the plurality of signals, to a task B in said group of tasks that declares a need to access said shared resource if another task A in said group of tasks has declared via another signal no need to access said shared resource; wherein said task A executes without accessing said shared resource; wherein said task B accesses said shared resource only after said granting; wherein said task A processes a first packet that is received prior to receipt of a second packet processed by said task B; wherein one path to be followed by said task B is to use said shared resource to process said second packet; and wherein another path to be followed by said task A is to not use said shared resource to process said first packet.