专利名称:ONE-TIME INITIALIZATION发明人:Arun Kishan,Neill M. Clift申请号:US13106836申请日:20110512
公开号:US20110219379A1公开日:20110908
专利附图:
摘要:Aspects of the present invention are directed at providing safe and efficientways for a program to perform a one-time initialization of a data item in a multi-threadedenvironment. In accordance with one embodiment, a method is provided that allows aprogram 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 initializethe data item from a current thread. In response to receiving the request, the methoddetermines whether the current thread is the first thread to attempt to initialize the dataitem. If the current thread is the first thread to attempt to initialize the data item, themethod enforces mutual exclusion and blocks other attempts to initialize the data itemmade by concurrent threads. Then, the current thread is allowed to execute programcode provided by the program to initialize the data item.
申请人:Arun Kishan,Neill M. Clift
地址:Bellevue WA US,Kirkland WA US
国籍:US,US
更多信息请下载全文后查看
因篇幅问题不能全部显示,请点此查看更多更全内容