Patent ID: 7426628

Claim:
A method for run-time prediction of a next caller of a shared functional unit, wherein the shared functional unit is operable to be called by two or more callers out of a plurality of callers, the method comprising: storing a caller history of the shared functional unit; detecting a calling pattern of the plurality of callers of the shared functional unit, wherein said detecting comprises: dividing the caller history into a first portion of the caller history and a second portion of the caller history, wherein the first portion and the second portion each hold an equal amount of the caller history; and comparing the callers in the first portion of the caller history to the callers in the second portion of the caller history; predicting the next caller out of the plurality of callers of the shared functional unit; and loading state information associated with the next caller out of the plurality of callers; wherein the shared functional unit and the plurality of callers are operable to execute in parallel on a parallel execution unit.