Placing a task of a multithreaded environment in a known state
First Claim
1. A method in a computer system for placing a task in a known state, the computer system having an operating system, the task having multiple threads executing on streams of a processor of the computer system, the processor having multiple streams for simultaneously executing threads of the task, the method comprising:
- under control of the operating system,notifying each of the threads of the task executing on a stream of the processor to enter a known state, the known state being an active state in which the thread is not making productive use of the processor;
for each of the threads,in response to receiving the notification, entering the known state so that an action can be performed with the task being in the known state, andnotifying a designated thread of the task that the thread has entered a known state; and
under control of the designated thread,determining whether a notification has been received from each of the other threads of the task, andwhen it is determined that a notification has been received from each of the other threads of the task, notifying the operating system that the task is now in the known state.
2 Assignments
0 Petitions
Accused Products
Abstract
A method and system that prepares a task for being swapped out from processor utilization that is executing on a computer with multiple processors that each support multiple streams. The task has one or more teams of threads, where each team represents threads executing on a single processor. The task designates, for each stream that is executing a thread, one stream as a team master stream and one stream as a task master stream. For each team master stream, the task notifies the operating system that the team is ready to be swapped out when each other thread of the team has saved its state and has quit its stream. Finally, for the task master stream, the task notifies the operating system that the task is ready to be swapped when it has saved its state and each other team has notified that it is ready to be swapped out.
113 Citations
66 Claims
-
1. A method in a computer system for placing a task in a known state, the computer system having an operating system, the task having multiple threads executing on streams of a processor of the computer system, the processor having multiple streams for simultaneously executing threads of the task, the method comprising:
-
under control of the operating system, notifying each of the threads of the task executing on a stream of the processor to enter a known state, the known state being an active state in which the thread is not making productive use of the processor; for each of the threads, in response to receiving the notification, entering the known state so that an action can be performed with the task being in the known state, and notifying a designated thread of the task that the thread has entered a known state; and under control of the designated thread, determining whether a notification has been received from each of the other threads of the task, and when it is determined that a notification has been received from each of the other threads of the task, notifying the operating system that the task is now in the known state. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22)
-
-
23. A method in a computer system for a task to exit a known state, the computer system having an operating system and supporting multiple streams, the task having multiple threads executing on the streams that are in the known state, the known state being an active state in which the thread is not making productive use of the processor, the method comprising:
-
under control of the operating system, notifying a designated thread of the task to exit the known state; under control of the designated thread of the task, notifying each of the other threads of the task executing on a parallel processor architecture having multiple simultaneously executing protection domains to exit the know state; and after notifying each of the other threads, executing instructions that were to be executed prior to entering the know state to effect the exiting of the known state; and for each of the threads, in response to receiving the notification, executing instructions that were to be executed prior to entering the known state to effect the exiting of the known state. - View Dependent Claims (24, 25, 26, 27, 28, 29, 30, 31, 32, 33)
-
-
34. A system for placing a task in a know state, the task having multiple threads executing on streams of the system, the system comprising:
-
a central processing unit; an operating system; a component under control of the operating system for notifying each of the threads of the task executing on a parallel processor architecture having multiple simultaneously executing streams to enter a known state, the known state being an active state in which the thread is not making productive use of the processor; a component for each of the threads that, in response to receiving the notification, causes the thread to enter the known state so that an action can be performed with the task being in the known state; and notifies a designated thread of the task that the thread has entered a known state; and a component for the designated thread that, when a notification has been received from each of the other threads, notifies the operating system that the task is now in the known state. - View Dependent Claims (35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55)
-
-
56. A system for use by a task to exit a known state, the system supporting multiple streams and including an operating system and a central processing unit, the task having multiple threads executing on the streams that are in the known state, the known state being an active state in which the thread is not making productive use of the processor, the system comprising:
-
a component under control of the operating system for notifying a designated thread of the task to exit the known state, wherein the task is executing on a parallel processor architecture having multiple simultaneously executing protection domain; a component of the designated thread for notifying each of the other threads of the task to exit the known state and that after notifying each of the other threads, causes the designated thread to execute instructions that were to be executed prior to entering the known state to effect the exiting of the known state; and a component for each thread that, in response to receiving the notification, executes instructions that were to be executed prior to entering the known state to effect the exiting of the known state. - View Dependent Claims (57, 58, 59, 60, 61, 62, 63, 64, 65, 66)
-
Specification