Patent ID: 7930520

Claim:
A processor for sequentially executing a plurality of programs using a plurality of register value groups stored in a memory that correspond one-to-one with the plurality of programs, the processor comprising: a plurality of register groups; a select/switch unit operable to select one of the plurality of register groups as an execution target register group on which a program execution is based, and to switch the execution target register group every time a first predetermined period elapses; and a restoring unit operable to restore, every time the switching is performed, one of the plurality of register value groups into one of the plurality of register groups that is not selected as the execution target register group; a saving unit operable to save, prior to the restoring, register values in the one of the plurality of register groups targeted for restoring, by overwriting a register value group in the memory that corresponds to the register values; and a program execution unit operable to execute, every time the switching is performed, a program corresponding to a register value group in the execution target register group, wherein the first predetermined period is a time period that is identified via a timeslot indicating a program execution timeframe which is defined so that time periods for occupying the program execution unit are allotted to programs in accordance with respective processing periods of the programs, the restoring unit, in order to switch between timeslots which are program execution timeframes, periodically in a predetermined order: refers to information specifying a timeslot that is a present execution target and a timeslot that is to become a next execution target; identifies the timeslot that is to become the next execution target; obtains a program execution timeframe allotted to the identified timeslot; and determines a register value group which is to be a restore target, based on a candidate register value group allotted to the identified timeslot.