Patent ID: 7617499

Claim:
A method of performing a context switch operation in a multithreaded computer, the method comprising initiating a prefetch of at least one instruction likely to be executed by a thread prior to resuming execution of the thread, wherein initiating the prefetch includes: retrieving state information associated with a working state of the thread, wherein the retrieved state information is stored during a prior context switch from the thread and includes a program counter; selecting a prefetch address for the instruction to be prefetched based upon the program counter from the retrieved state information; and initiating a prefetch of a cache line for the selected prefetch address and at least one immediately succeeding cache line; wherein initiating the prefetch includes storing prefetch control data for the thread in a buffer, the method further comprising retrieving the prefetch control data from the buffer and performing a prefetch operation based during the prefetch control data, and wherein initiating the prefetch occurs during suspension of the thread.