Processor with register stack engine that dynamically spills/fills physical registers to backing store
AssigneeIntel Corporation
InventorTuan H. Bui
Life of this patent
Estimating the term…
Abstract
According to an embodiment of the invention, a processor comprises a register file and a register stack engine. The register file has a predetermined size and a set of registers in the register file is allocated when a function in a code sequence is called. The register stack engine saves the contents of a set of registers in a reserve storage area responsive to a function call if the function call would overflow the predetermined size of the register file. The register stack engine restores data from the reserve storage area to the register file if a recursive function call occurs.
Claims39
A processor comprising:
- a register file having a predetermined size, a set of registers in the register file being allocated when a function in a code sequence is called;
- and
- a register stack engine, the register stack engine saving the contents of a set of registers in a reserve storage area responsive to a function call if the function call would overflow the predetermined size of the register file, the register stack engine restoring data from the reserve storage area to the register file if a recursive function call occurs.
A processor comprising:
- a register file, the register file including a plurality of registers;
- a reserved memory area;
- and
- a unit that:
- allocates a set of registers for [the call of]a function call, the unit saving the contents of certain registers in the reserved memory area when a function is called that requires allocation of a number of registers that exceeds an available number of registers of the register file,
- restores the contents of a set of registers for a function from the reserved memory area to the register file responsive to a recursive call of the function, and
- deallocates the set of registers upon completion of the function.
A method comprising:
- executing an instruction with a processor, the execution of the instruction including making a frame of registers in a register file available to a called procedure;
- stalling the processor in response to an overflow condition, the overflow condition including that a sufficient number of registers are not available in the register file to accommodate the called procedure;
- performing a backing store operation, the backing store operation including saving the contents of one or more registers to a dedicated memory;
- and
- restoring the contents of register from the dedicated memory to the register file, including restoring the contents of a set of registers for a function from the dedicated memory to the register file
- responsive to a recursive call of the function.
A processor comprising:
- a register file comprising a stacked set of physical registers, a frame of registers of the register file being allocated associated with a procedure call, the register file being comprised of a plurality of regions, the plurality of regions including:
- an active region of registers,
- a clean region of registers containing values from a parent frame that have been spilled to memory, and
- a dirty region of registers containing values from a previous frame that have not been spilled to memory;
- and
- a cache dedicated for use as a backing store memory associated with the register file.
A method comprising:
- receiving a code sequence, the code sequence including a plurality of procedure calls;
- calling one of the plurality of procedure calls;
- allocating a first set of registers in response to the called procedure, the first set of registers being a part of a registers file, the register file having a certain size, the procedure call resulting in an overflow condition for the register file;
- saving the contents of a second set of registers in a reserve storage area, the second set of registers being a part of the register file;
- and
- if a recursive procedure call occurs, restoring the contents of a set of register associated with the procedure call from the reserve storage.
A microprocessor comprising:
- a register file comprising a plurality of registers, the register file having a certain size;
- a unit, the unit allocating a frame of registers in the register file upon receiving a call to a procedure, the unit saving the contents of a set of registers in a reserve storage area if the procedure call results in an overflow condition for the register file, the unit restoring the contents of a set of registers for a function from the reserve storage area to the register file if a recursive call of the function occurs.
Dependencies are inferred from the claim text.