Wake-and-go mechanism with software save of thread state
First Claim
1. A method, in a data processing system, for performing a wake-and-go operation, the method comprising:
- detecting a thread that is waiting for an event that modifies a data value associated with a target address;
storing the target address in a wake-and-go entry of a wake-and-go storage array in association with a thread identifier of the thread, wherein the wake-and-go storage array, is a content addressable memory and an address on a bus is used to address the content addressable memory;
storing thread state information for the thread in a thread state storage;
placing the thread in a sleep state; and
responsive to the event that modifies a data value associated with the target address, reloading the thread state information from the thread state storage for the thread corresponding to the thread identifier in the wake-and-go entry, and placing the thread in a non-sleep state, wherein responsive to the event that modifies a data value associated with the target address, the content addressable memory generates an exception.
1 Assignment
0 Petitions
Accused Products
Abstract
A wake-and-go mechanism is provided for a data processing system. When a thread is waiting for an event, rather than performing a series of get-and-compare sequences, the thread updates a wake-and-go array with a target address associated with the event. Software may save the state of the thread. The thread is then put to sleep. When the wake-and-go array snoops a kill at a given target address, logic associated with wake-and-go array may generate an exception, which may result in a switch to kernel mode, wherein the operating system performs some action before returning control to the originating process. In this case, the trap results in other software, such as the operating system or background sleeper thread, for example, to reload thread from thread state storage and to continue processing of the active threads on the processor.
218 Citations
13 Claims
-
1. A method, in a data processing system, for performing a wake-and-go operation, the method comprising:
-
detecting a thread that is waiting for an event that modifies a data value associated with a target address; storing the target address in a wake-and-go entry of a wake-and-go storage array in association with a thread identifier of the thread, wherein the wake-and-go storage array, is a content addressable memory and an address on a bus is used to address the content addressable memory; storing thread state information for the thread in a thread state storage; placing the thread in a sleep state; and responsive to the event that modifies a data value associated with the target address, reloading the thread state information from the thread state storage for the thread corresponding to the thread identifier in the wake-and-go entry, and placing the thread in a non-sleep state, wherein responsive to the event that modifies a data value associated with the target address, the content addressable memory generates an exception. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A data processing system, comprising:
-
a wake-and-go mechanism; and a wake-and-go storage array, wherein the wake-and-go mechanism is configured to; detecting a thread that is waiting for an event that modifies a data value associated with a target address; storing the target address in a wake-and-go entry of a wake-and-go storage array in association with a thread identifier of the thread, wherein the wake-and-go storage array, is a content addressable memory and an address on a bus is used to address the content addressable memory; storing thread state information for the thread in a thread state storage; placing the thread in a sleep state; and responsive to the event that modifies a data value associated with the target address, reloading the thread state information from the thread state storage for the thread corresponding to the thread identifier in the wake-and-go entry, and placing the thread in a non-sleep state, wherein responsive to the event that modifies a data value associated with the target address, the content addressable memory generates an exception. - View Dependent Claims (9, 10, 11)
-
-
12. A computer program product comprising a hardware computer readable storage medium having a computer readable program, wherein the computer readable program, when executed on a computing device, causes the computing device to:
-
detecting a thread that is waiting for an event that modifies a data value associated with a target address; storing the target address in a wake-and-go entry of a wake-and-go storage array in association with a thread identifier of the thread, wherein the wake-and-go storage array, is a content addressable memory and an address on a bus is used to address the content addressable memory; storing thread state information for the thread in a thread state storage; placing the thread in a sleep state; and responsive to the event that modifies a data value associated with the target address, reloading the thread state information from the thread state storage for the thread corresponding to the thread identifier in the wake-and-go entry, and placing the thread in a non-sleep state, wherein responsive to the event that modifies a data value associated with the target address, the content addressable memory generates an exception. - View Dependent Claims (13)
-
Specification