×

Method and system for synchronizing the execution of a critical code section

  • US 20100011372A1
  • Filed: 12/12/2008
  • Published: 01/14/2010
  • Est. Priority Date: 07/09/2008
  • Status: Abandoned Application
First Claim
Patent Images

1. A method for synchronizing the execution of at least one critical code section (C1) by at least one of a plurality of concurrent tasks (S1, Sn) of an application (4), the application (4) running on an operating system (5) providing cooperative multitasking, the critical code section (C1) being restricted to execution by only a limited number of the plurality of tasks (S1, Sn), the method comprising at least the following steps performed by at least one of the tasks (S1, Sn):

  • a. testing (F11) at least one variable (Mx) associated to the at least one critical code section (C1) and setting (F12) the variable (Mx) and entering the associated critical code section (C1), if the variable (Mx) is not set by another task (S1, Sn), or, waiting (F13) for a release (F22) by another task (S1, Sn) and releasing a CPU, if the variable (Mx) is already set by another task (S1, Sn); and

    b. resetting (F21) the variable (Mx) and releasing (F22) at least one of 20 the other waiting tasks (S1, Sn) when leaving the critical code section (C1);

    c. wherein step a. is performed as an atomic function (F1).

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×