Method and apparatus for converting a synchronized method into a non-synchronized method
OwnerNicholas Shaylor, Douglas N. Simoninventors
Life of this patent
Estimating the term…
Loading patent…
OwnerNicholas Shaylor, Douglas N. Simoninventors
Estimating the term…
One embodiment of the present invention provides a system that facilitates converting a synchronized method into a non-synchronized method. During operation, the system receives a code module that includes a synchronized method. This synchronized method automatically performs a lock operation before executing its method body and automatically performs an unlock operation after executing its method body, whereby at most one thread at a time can execute the method body. Next, the system changes the synchronized method into a non-synchronized method that does not automatically perform lock and unlock operations. The system also inserts an explicit lock instruction at the beginning of the method body, and inserts an explicit unlock instruction at the end of the method body.
A method for converting a synchronized method into a non-synchronized method, comprising:
A computer-readable storage medium storing instructions that when executed by a computer cause the computer to perform a method for converting a synchronized method into a non-synchronized method, the method comprising:
An apparatus that converts a synchronized method into a non-synchronized method, comprising:
Dependencies are inferred from the claim text.