One-time initialization
AssigneeMicrosoft Corporation
InventorsArun Kishan, Neill M. Clift
Life of this patent
Estimating the term…
Loading patent…
AssigneeMicrosoft Corporation
InventorsArun Kishan, Neill M. Clift
Estimating the term…
Aspects of the present invention are directed at providing safe and efficient ways for a program to perform a one-time initialization of a data item in a multi-threaded environment. In accordance with one embodiment, a method is provided that allows a program to perform a synchronized initialization of a data item that may be accessed by multiple threads. More specifically, the method includes receiving a request to initialize the data item from a current thread. In response to receiving the request, the method determines whether the current thread is the first thread to attempt to initialize the data item. If the current thread is the first thread to attempt to initialize the data item, the method enforces mutual exclusion and blocks other attempts to initialize the data item made by concurrent threads. Then, the current thread is allowed to execute program code provided by the program to initialize the data item.
A blocking method for initializing data in a multi-threaded environment, the blocking method comprising:
At least one computer storage media storing computer-executable instructions that, when executed by a computer, cause the computer to perform a blocking method for initializing data in a multi-threaded environment, the blocking method comprising:
The at least one computer storage media of claim 103, the blocking method further comprising blocking, in response to the initialization state of the data indicating “initializing”, any of the plurality of threads, other than the first-in-time thread, attempting to initialize the data while the initialization state of the data indicates that the data is “initializing”.
A system configured for initializing data in a multi-threaded environment, the system comprising:
Dependencies are inferred from the claim text.