WO2010116403A1 - プリフェッチ要求回路 - Google Patents

プリフェッチ要求回路 Download PDF

Info

Publication number
WO2010116403A1
WO2010116403A1 PCT/JP2009/001465 JP2009001465W WO2010116403A1 WO 2010116403 A1 WO2010116403 A1 WO 2010116403A1 JP 2009001465 W JP2009001465 W JP 2009001465W WO 2010116403 A1 WO2010116403 A1 WO 2010116403A1
Authority
WO
WIPO (PCT)
Prior art keywords
instruction
memory
memory copy
prefetch
copy
Prior art date
Application number
PCT/JP2009/001465
Other languages
English (en)
French (fr)
Inventor
伏島敦史
五明則人
Original Assignee
富士通株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 富士通株式会社 filed Critical 富士通株式会社
Priority to EP09842915.2A priority Critical patent/EP2416250B1/en
Priority to JP2011508060A priority patent/JP5229383B2/ja
Priority to PCT/JP2009/001465 priority patent/WO2010116403A1/ja
Publication of WO2010116403A1 publication Critical patent/WO2010116403A1/ja
Priority to US13/220,006 priority patent/US8856498B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0862Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches with prefetch
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30003Arrangements for executing specific machine instructions
    • G06F9/3004Arrangements for executing specific machine instructions to perform operations on memory
    • G06F9/30043LOAD or STORE instructions; Clear instruction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/3017Runtime instruction translation, e.g. macros
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30181Instruction operation extension or modification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/34Addressing or accessing the instruction operand or the result ; Formation of operand address; Addressing modes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/38Concurrent instruction execution, e.g. pipeline or look ahead
    • G06F9/3824Operand accessing
    • G06F9/383Operand prefetching

Definitions

  • the disclosed technology relates to a prefetch request technology for requesting prefetch when a memory is accessed in a processor device having a cache.
  • a processor device of a computer is equipped with a secondary cache, a primary data cache, a primary instruction cache, and the like in order to improve access performance to the main memory.
  • an instruction read from the main memory via the secondary cache and the primary instruction cache is sent to the instruction decoder, where it is decoded.
  • the decoded instruction is a memory access instruction such as a load instruction, a store instruction, or a memory copy instruction
  • the operand address generator calculates a memory address to be accessed, and the primary data cache is calculated according to the calculated address. To access.
  • address A the data of the copy source address on the memory
  • address B the copy destination address
  • the copy size When a data size less than or equal to the data transfer capability in one cycle between the main memory and the secondary cache or between the secondary cache and the primary data cache is designated by one instruction as the copy size, for example, (a ) Is executed.
  • the decoded memory copy instructions are registered in an instruction queue called CSE (Commit Stack Entry) in the order of decoding.
  • CSE Common Stack Entry
  • an IID instruction identifier
  • a valid flag for instructing whether the registered instruction is valid or invalid
  • the number of CSE entries is, for example, about several tens of entries.
  • the processor is provided with an instruction queue called RS (Reservation Station) that can register each instruction with priority (priority) and execute it out-of-order.
  • An IID for identifying each command is also registered in each RS entry.
  • the memory copy instruction is processed by the operand address generator via RS, and a memory copy process based on the memory copy instruction is executed.
  • an instruction registered in the CSE in decoding order and an instruction executed out of order via the RS are linked by an instruction identifier (IID).
  • the instruction that has been executed via the RS is checked against the CSE entry by the IID registered in the RS entry corresponding to the instruction, and the valid flag (Valid) of the CSE entry in which the same IID is registered. ) Is changed to a value indicating invalidity to complete the execution of the instruction.
  • the data transfer capability of the memory copy instruction is, for example, 16 bytes (16B), and the “16B memory copy” instruction indicates a data transfer instruction of up to 16 bytes.
  • FIG. 1B when a data size exceeding the data transfer capability in one cycle between the main memory and the secondary cache or between the secondary cache and the primary data cache is designated by one instruction as the copy size, for example, FIG.
  • the instruction decoder executes a process called multiflow expansion for a “32B memory copy” instruction which is a 32-byte data transfer instruction, for example.
  • the “32B memory copy” instruction is broken down into two “16B memory copy” instructions.
  • Each of the “16B memory copy” instructions thus decoded into a plurality of instructions is registered in individual CSE entries CSE0 and CSE1, respectively, as shown in FIGS. 1B and 1C.
  • each “16B memory copy” instruction registered in each entry of CSE0 and CSE1 is executed out of order via an individual RS entry associated with each IID registered together with each instruction.
  • Each “16B memory copy” instruction registered in each entry of CSE0 and CSE1 is executed out of order via an individual RS entry associated with each IID registered together with each instruction.
  • IID registered together with each instruction.
  • each memory copy instruction is executed in a multiflow manner.
  • the data transfer capability between the secondary cache and the primary data cache is 16 bytes
  • the maximum data size specified by one memory copy instruction is 256 bytes.
  • a 1024-byte memory copy process is described as four consecutive 256-byte memory copy instructions, and each 256-byte memory copy instruction is multi-flow expanded into 16 16-byte memory copy instructions.
  • a memory copy instruction of the maximum size for example, 256 bytes
  • a memory copy instruction obtained by multi-flow expansion of each memory copy instruction is called an MF memory copy instruction.
  • a prefetch request is issued for the execution of the first MF memory copy instruction obtained by multi-flow development of each memory copy instruction. This prefetch request is not issued at the time of execution of the second and subsequent MF memory copy instructions obtained by multiflow expansion of each memory copy instruction.
  • memory data in the address range of several blocks from the memory address specified by the first MF memory copy instruction is fetched from the main memory to the secondary cache, and a part of the memory data is also primary data. It is also fetched into the cache.
  • the address range of several blocks is an address range corresponding to, for example, one data transfer unit from the main memory to the secondary cache, for example, 256 bytes.
  • a prefetch operation is executed based on a prefetch request issued by the instruction.
  • memory data in the address range of several blocks from the several blocks ahead of the memory address designated by the first MF memory copy instruction is prefetched in advance into the secondary cache.
  • the prefetch operation is not executed regardless of the prefetch request.
  • the prefetch request is not issued, and thus the prefetch operation is not executed.
  • the primary data cache misses (L1 $ miss) during execution of the second and subsequent MF memory copy instructions a normal fetch operation for the secondary cache or main memory is executed.
  • the memory block corresponding to the data transfer unit from the secondary cache to the primary data cache is 64 bytes (64B), and the maximum data size that can be specified by one memory copy instruction is 256 bytes. is there.
  • One large size memory copy process is executed by a plurality of continuous 256-byte memory copy instructions. Then, assuming that the addresses A and B are located at the block boundary of the memory block, the copy source head address in the first 256-byte memory copy instruction of the memory copy process is A and the copy destination head address is B.
  • a prefetch request is issued at the time of the first MF memory copy instruction obtained by multiflow expansion of the first (1st) memory copy instruction.
  • the copy source head address is A and the copy destination head address is B.
  • This prefetch request is not issued in the second and subsequent MF memory copy instructions obtained by multiflow expansion of the first (1st) memory copy instruction.
  • the copy source memory data in the address range of 4 memory blocks from the memory address A designated by the first MF memory copy instruction corresponding to the first (1st) memory copy instruction is transferred from the main memory to the secondary cache. Is fetched.
  • the copy destination memory area in the address range (from B to B + 255) from the memory address B designated by the first MF memory copy instruction to 4 memory blocks is secured (fetched) in the secondary cache.
  • a prefetch request issued by the instruction is executed. That is, copy source memory data in an address range of 4 memory blocks further from the memory address specified by the first MF memory copy instruction is prefetched from the main memory to the secondary cache. This address range is from A + 256 to A + 511. The same applies to the area reservation (prefetch) in the secondary cache for the copy destination memory data (from B + 256 to B + 511).
  • the prefetch operation is not executed because no prefetch request is issued. If the primary data cache misses (L1 $ miss) in the execution of the second and subsequent MF memory copy instructions, a normal fetch operation is executed. In this case, when the first MF memory copy instruction corresponding to the first (1st) memory copy instruction is executed, the main memory to the secondary cache for the address range of 4 memory blocks from the memory address A (or B) is transferred. A fetch operation is being performed. Therefore, in the fetch operation when the primary data cache misses (L1 $ miss) during execution of the second and subsequent MF memory copy instructions, the secondary cache hits (L2 $ HIT), and high-speed memory access is realized. Is done.
  • the memory block corresponding to the data transfer unit from the secondary cache to the primary data cache is 64 bytes (64B), one memory
  • the maximum data size that can be specified by the copy command is 256 bytes.
  • one large size memory copy process is executed by a plurality of continuous 256-byte memory copy instructions.
  • the copy source start address in the first 256-byte memory copy instruction of the memory copy process is A + 16, and the copy destination start address is B + 16. The That is, in case 1 of FIG. 3, the start address of the memory copy process exists at the block boundary (addresses A and B), but in case 2 of FIG. 4, it does not exist at the block boundary.
  • a prefetch request is issued at the time of the first MF memory copy instruction obtained by multiflow expansion of the first (1st) memory copy instruction.
  • the copy source head address is A + 16
  • the copy destination head address is B + 16.
  • This prefetch request is not issued in the second and subsequent MF memory copy instructions obtained by multiflow expansion of the first (1st) memory copy instruction, as in case 1 of FIG.
  • the copy source memory data in the address range of 4 memory blocks from the memory address A + 16 designated by the first MF memory copy instruction corresponding to the first (1st) memory copy instruction is transferred from the main memory to the secondary cache. Is fetched.
  • some memory blocks of the memory data fetched to the secondary cache are also fetched to the primary data cache. The same applies to the area reservation (fetch) in the secondary cache for the copy destination memory data (from B to B + 255).
  • a prefetch request issued by the instruction is executed. That is, copy source memory data in an address range of 4 memory blocks further from the memory address specified by the first MF memory copy instruction is prefetched from the main memory to the secondary cache. This address range is also specified in memory block units, and is from A + 256 to A + 511. The same applies to the area reservation (prefetch) in the secondary cache for the copy destination memory data (from B + 256 to B + 511).
  • the primary data cache hits (L1 $ HIT) and does not miss.
  • the prefetch operation from the main memory to the secondary cache is executed only when a prefetch request is issued to the primary data cache and the primary data cache misses (L1 $ miss). Therefore, when the first MF memory copy instruction corresponding to the second (2nd) memory copy instruction is executed, the prefetch request is issued, but the third (3rd) memory copy instruction The prefetch operation is not executed.
  • the copy source start address is A + 528 and the copy destination start address is B + 528.
  • the memory block including these addresses is the same as the memory block accessed when the last MF memory copy instruction corresponding to the second (2nd) memory copy instruction is executed. Therefore, in case 2 of FIG. 4, even when the first MF memory copy instruction corresponding to the third (3rd) memory copy instruction is executed, the primary data cache hits (L1 $ HIT) and does not miss. Therefore, even when the first MF memory copy instruction corresponding to the third (3rd) memory copy instruction is executed, the prefetch request is issued, but the fourth (4th) memory copy instruction Therefore, the prefetch operation is not executed.
  • the problem to be solved by the disclosed technique is to increase the effect of a prefetch request in any case when memory access instructions having the maximum transfer capability size are continuously executed.
  • a first aspect of the disclosed technique is a processor in which the storage area is hierarchized into two or more, and when executing each instruction flow in which one instruction is multiflow-expanded into a plurality of instruction flows at the time of instruction decoding
  • This is realized as a prefetch request circuit in a processor device capable of prefetching data at an address scheduled to be used in advance between appropriate storage areas of two or more storage areas.
  • the prefetch request signal output unit outputs a prefetch request signal for requesting prefetch every time each instruction flow is executed based on the output signal of the latch unit and a signal indicating the execution timing of each instruction flow.
  • a second aspect of the disclosed technology includes a main memory, a secondary cache, and a primary data cache, and multi-flows one instruction into a plurality of instruction flows and executes each instruction flow at the time of instruction decoding.
  • a prefetch request circuit in a processor device capable of prefetching data at an address scheduled to be used in advance from the main memory to the secondary cache during memory access to the data cache is assumed.
  • the latch circuit unit multi-states the state when it is instructed to execute each instruction flow corresponding to the memory copy instruction for instructing the data copy or movement between the memory addresses and the operation with the maximum specifiable data transfer amount. Hold for the duration of the flow deployment.
  • the AND circuit section takes an AND logic between the output signal of the latch section and a signal indicating the execution timing of each instruction flow, and outputs a prefetch request signal each time an instruction flow is issued as the AND logic output.
  • a prefetch request signal that increases the effect of the prefetch request in any case is output. Is possible.
  • FIG. 6 is an explanatory diagram of a memory access operation performed by the instruction decoder 504, the CSE 505, the RSA 506, the operand address generator 509, and the primary data cache 510 of FIG. It is a figure which shows embodiment of a prefetch request circuit. It is an operation
  • FIG. 5 is an overall configuration diagram of a processor device according to an embodiment of the present invention.
  • an instruction fetch address generator 519 accesses the primary instruction cache 503 to read a necessary instruction from the main memory 501 via the secondary cache 502 and the primary instruction cache 503. .
  • the read instruction is sent to the instruction decoder 504.
  • the instruction decoder 504 decodes the instruction in order in the decode (D) cycle. Instructions decoded by the instruction decoder 504 are registered in order in a CSE (Commit Stack Entry) 505. At the same time, the instruction decoded by the instruction decoder 504 is registered in each reservation station RSA (Reservation Station for Address) 506 and RSE (Reservation Station for Execute) 507 which perform out-of-order execution control. Further, when the instruction decoded by the instruction decoder 504 is a branch instruction, the instruction is registered in a branch station reservation station RSBR (Reservation Station for Branch) 508.
  • an IID instruction identifier
  • a valid flag for instructing whether the registered instruction is valid or invalid is registered together with the IID.
  • An instruction registered in the order of decoding in the CSE 505 and an instruction executed out of order via the RSA 506, RSE 507, or RSBR 508 are linked by an instruction identifier (IID).
  • the instruction that has been executed via the RSA 506, RSE 507, or RSBR 508 is checked against the entry of the CSE 505 by the IID registered in the RSA 506, RSE 507, or RSBR 508 entry corresponding to the instruction. Then, the valid flag (Valid) of the entry of CSE 505 in which the same IID is registered is changed to a value indicating invalidity, and the execution of the instruction is completed.
  • the order of instructions executed out-of-order via the RSA 506, RSE 507, or RSBR 508 is guaranteed by the CSE 505.
  • each instruction issued by the instruction decoder 504 is registered in the RSA 506.
  • the subsequent instruction issued by the instruction decoder 504 is registered in the RSA 506 when a cache miss occurs in the primary data cache 510 and it takes time to fetch the memory data.
  • the priority (priority) of each entry is determined.
  • the operand address generator 509 calculates a memory address to be accessed in an address calculation (X) cycle.
  • Memory access instructions include load instructions, store instructions, memory copy instructions, and the like.
  • the operand address generator 509 accesses the primary data cache 510 with the calculated address.
  • the instruction is not registered in the RSA 506 but is input to the operand address generator 509 immediately after being decoded by the instruction decoder 504.
  • a prefetch request signal + P_PREFETCH_REQUEST is issued from the RSA 506 to the primary data cache.
  • the prefetch request signal is the first MF memory copy among the MF memory copy instructions (multiflow expansion instructions) corresponding to the memory copy instruction having the maximum copy size, as described above with reference to FIG. 3 or FIG. It was issued only when the instruction was issued.
  • the present embodiment is different in that a prefetch request signal + P_PREFETCH_REQUEST is issued each time each MF memory copy instruction that has been multi-flow expanded from a memory copy instruction having the maximum copy size is issued from the RSA 506, as will be described later.
  • the contents of the fixed-point register 513 or the floating-point register 514 are read and input to the arithmetic unit 511 or 512 out of order.
  • the computing unit 511 or 512 executes the computation specified by the computation instruction in the computation execution (X) cycle.
  • the execution result in the arithmetic unit 511 or 512 is stored in the fixed-point update buffer 515 or the floating-point update buffer 516 in a register update (U) cycle, and waits for instruction completion (commit) processing.
  • the CSE 505 receives a report such as completion of operation in the arithmetic unit 511 or 512, completion of data transfer in the primary data cache 510, or branch determination completion from the branch prediction mechanism 518
  • the fixed-point update buffer 515 or floating point In the update buffer 516 commit processing is performed in-order. Further, each register 513 or 514 is written from each update buffer 515 or 516 in a register write (W) cycle.
  • the instruction fetch address generator 519 generates the next instruction fetch address based on the instruction fetch address information given from the PSW 517, RSBR 508, or RSBR 508 via the branch prediction mechanism 518, and uses the generated instruction fetch address as the primary instruction.
  • the cache 503 is accessed.
  • FIG. 6 is an explanatory diagram of a memory access operation performed by the instruction decoder 504, CSE 505, RSA 506, operand address generator 509, and primary data cache 510 shown in FIG.
  • MVC MOVE character
  • the MVC instruction is a memory copy instruction that specifies a maximum of 256 bytes of data in units of bytes and copies it from an arbitrary copy source address A to a copy destination address B.
  • MVC256 an MVC instruction having a maximum value of 256 bytes.
  • the MVC256 instruction decoded in the decode (D) cycle is decomposed into 16 “MVC16” instructions by multiflow expansion.
  • the “MVC16” instruction is an instruction for executing data LOAD or STORE for the main memory 501, the secondary cache 502, or the primary data cache 510 or simultaneous processing of LOAD and STORE in units of 16 bytes.
  • each “MVC16” instruction that has been multi-flow expanded into a plurality of MF memory copy instructions and decoded is individually registered in 16 CSE entries CSE0 to CSE15 in CSE505. .
  • Each “MVC16” instruction is registered in the RSA 506 and the RSE 507.
  • the IID of each “MVC16” instruction is registered in each CES entry CSE0 to CSE15, and each CES entry CSE0 to CSE15 and each entry in the RSA 506 or RSE 507 are linked by this IID.
  • the + D_MVC_256_1ST signal is a signal that is set from the instruction decoder 504 and indicates that it is the first MF memory copy instruction that has been multi-flow expanded for a memory copy instruction having a maximum copy size of 256 bytes.
  • Each entry of each “MVC16” instruction registered in the RSA 506 is issued to the operand address generator 509 in descending order of priority. As a result, the operand address generator 509 performs a memory access to the primary data cache 510. Note that the + P_EAG_VALID signal indicating that the operand address generator 509 (EAG) is enabled (VALID) is asserted from the RSA 506 to the primary data cache every time each “MVC16” instruction is issued.
  • the prefetch request signal + P_PREFETCH_REQUEST is asserted.
  • FIG. 7 is a diagram illustrating a configuration of a prefetch request circuit implemented in the RSA 506 in order to issue the above-described prefetch request signal + P_PREFETCH_REQUEST.
  • FIG. 8 is an operation timing chart showing the operation of the prefetch request circuit of FIG.
  • the prefetch request circuit of FIG. 7 operates as described below. First, the prefetch request circuit in FIG. 7 operates based on the + D_MF_TGR signal, the + P_EAG_VALID signal, and the + P_MVC_256_1ST signal.
  • the + D_MF_TGR signal is issued from the instruction decoder 504 and is asserted during a period during multiflow development.
  • the + D_MF_TGR signal is asserted during a period from t2 to t5 in FIG.
  • the + P_EAG_VALID signal is asserted by the RSA 506 every time the RSA 506 issues an instruction to the operand address generator 509.
  • the + P_EAG_VALID signal is asserted at timings t1, t3, and t4 in FIG. Is done.
  • the + P_MVC_256_1ST signal is a signal generated inside the RSA 506 based on the + D_MVC_256_1ST signal issued from the instruction decoder 504. More specifically, the + P_MVC_256_1ST signal is issued at the timing when the first “MVC16” instruction that has been multi-flow expanded from the “MVC256” instruction having the maximum copy size is issued from the RSA 506 to the operand address generator 509. At this time, at the timing when the first “MVC16” instruction is executed, the + P_MVC_256_1ST signal is asserted based on the + D_MVC_256_1ST signal set in the entry in the RSA 506 in which the first “MVC16” instruction is registered. . The + P_MVC_256_1ST signal is asserted, for example, at the timing t1 in FIG. 8B.
  • the AND circuit 701 takes AND logic of the + P_MVC_256_1ST signal (FIG. 8 (b)) and the + P_EAG_VALID signal (FIG. 8 (a)), and is asserted, for example, from t1 to t2 in FIG. 8 (c). Output a signal.
  • the output of the AND circuit 701 asserted from t1 to t2 is the primary data cache 510 via the OR circuit 706 as a prefetch request signal + P_PREFETCH_REQUEST corresponding to the first multiflow expansion instruction “MVC16” corresponding to the “MVC256” instruction. Issued to.
  • FIG. 8D shows an output signal of the OR circuit 702 input to Din, and is asserted in the period from t1 to t5.
  • the signal latched by the 1-bit latch 703 is output from Dout of the 1-bit latch 703 in the next clock cycle.
  • the Dout output signal is ANDed with the + D_MF_TGR signal (FIG. 8D) input from the instruction decoder 504 in the AND circuit 704.
  • the output of the AND circuit 704 is asserted, for example, in the period from t2 to t5 in FIG.
  • FIG. 8G shows the output from the output terminal Dout of the 1-bit latch 703, and is on during the period from t2 to t6.
  • the AND circuit 705 takes AND logic of + P_EAG_VALID and the output Dout (FIG. 8 (g)) of the 1-bit latch 703.
  • the + P_EAG_VALID signal is asserted every time the RSA 506 issues an instruction to the operand address generator 509, as shown in FIG.
  • the output Dout of the 1-bit latch 703 is asserted during the multiflow expansion period of the “MVC256” instruction having the maximum copy size, as shown in FIG.
  • the output of the AND circuit 705 outputs the timings t3 corresponding to the second and subsequent multiflow development instructions “MVC16” corresponding to the “MVC256” instruction having the maximum copy size, and Asserted at t4.
  • This output signal is issued to the primary data cache 510 through the OR circuit 706 as a prefetch request signal + P_PREFETCH_REQUEST.
  • a prefetch request signal + P_PREFETCH_REQUEST is issued to the primary data cache 510 as an OR output of the AND circuits 701 and 705 at every execution timing of each “MVC16” instruction corresponding to the “MVC256” instruction.
  • FIG. 9 is a diagram for explaining the effect of the prefetch request circuit of FIG.
  • the memory block corresponding to the data transfer unit from the secondary cache to the primary data cache is 64 bytes (64B)
  • the maximum data size that can be specified by the memory copy instruction is 256 bytes.
  • one large size memory copy process is executed by a plurality of continuous 256-byte memory copy instructions.
  • the copy source start address in the first 256-byte memory copy instruction of the memory copy process is A + 16, and the copy destination start address Is B + 16. That is, the start address of the memory copy process does not exist at the block boundary.
  • the prefetch request signal + P_PREFETCH_REQUEST is issued by the prefetch request circuit of FIG. 7 at the time of the first MF memory copy instruction obtained by multi-flow expansion of the first (1st) memory copy instruction.
  • This timing corresponds to, for example, the period from t1 to t2 in FIG.
  • the copy source head address is A + 16
  • the copy destination head address is B + 16.
  • the operand address generator 509 calculates an access address based on the address specified by the first MF memory copy instruction, and accesses the primary data cache 510. As a result, when both the primary data cache 510 and the secondary cache 502 miss in execution of the first MF memory copy instruction corresponding to the first (1st) memory copy instruction (L1 $, L2 $ miss), The following fetch and prefetch operations are performed.
  • a prefetch operation is executed based on the prefetch request signal + P_PREFETCH_REQUEST issued by the first MF memory copy instruction corresponding to the first (1st) memory copy instruction. That is, copy source memory data in an address range of 4 memory blocks from the memory address specified by the first MF memory copy instruction is prefetched from the main memory 501 to the secondary cache 502. This address range is also specified in memory block units, and is from A + 256 to A + 511. The same applies to the area reservation (prefetch) in the secondary cache for the copy destination memory data (from B + 256 to B + 511).
  • the prefetch request signal + P_PREFETCH_REQUEST is issued even in the second and subsequent MF memory copy instructions other than the first MF memory copy instruction obtained by multi-flow expansion of the first (1st) memory copy instruction. Is done.
  • the timing is t3 and t4 in FIG.
  • the prefetch operation is executed based on the prefetch request signal + P_PREFETCH_REQUEST issued by the currently executed MF memory copy instruction. That is, the portion not existing in the secondary cache 502 in the address range corresponding to four memory blocks from the memory address specified by the MF memory copy instruction currently being executed is further transferred from the main memory 501 to the secondary cache 502. Is prefetched.
  • the second (2nd) memory copy instruction is continuously executed after the first (1st) memory copy instruction is executed by multi-flow expansion.
  • a prefetch request is issued again.
  • the copy source head address is A + 272
  • the copy destination head address is B + 272.
  • the memory block including these addresses is the same as the memory block accessed when the last MF memory copy instruction corresponding to the first (1st) memory copy instruction is executed. Therefore, in the case of FIG.
  • the prefetch request signal + P_PREFETCH_REQUEST is issued by the prefetch request circuit of FIG.
  • the memory block in the address area of A + 320 (B + 320) does not exist in the primary data cache 510 because it is a memory block that has not been executed yet. Therefore, the primary data cache 510 misses (L1 $ miss).
  • a memory block starting from the address of A + 320 (B + 320) is fetched from the secondary cache 502 to the primary data cache 510.
  • a prefetch operation is executed based on L1 $ miss and the prefetch request signal + P_PREFETCH_REQUEST. That is, copy source memory data in an address range of 4 memory blocks further from the memory block boundary A + 320 specified by the MF memory copy instruction is prefetched from the main memory 501 to the secondary cache 502.
  • the This address range is from A + 576 to A + 831.
  • the prefetch operation for the third (3rd) memory copy instruction is also appropriately executed.
  • the multi-flow expansion of the third (3rd) memory copy instruction is performed based on the prefetch request signal + P_PREFETCH_REQUEST issued for each MF memory copy instruction. Prefetch operations are performed appropriately.
  • the prefetch request circuit shown in FIG. 7 even if the addressing of the multiflow expansion instruction is not at the memory block boundary, the memory copy instruction 2 continuously executed according to the maximum copy size. It is possible to increase the effect of the prefetch request by reducing the penalty due to the miss of the next cache.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Memory System Of A Hierarchy Structure (AREA)
  • Advance Control (AREA)

Abstract

 1ビットラッチ703は、メモリアドレス間のデータのコピー又は移動を指示するメモリコピー命令に対応する各命令フローを最大指定可能データ転送量で実行する状態が+P_MVC_256_1ST信号によって指示されたときに、その状態を+D_MF_TGR信号によって指示されるマルチフロー展開の期間中保持する。アンド回路705は、1ビットラッチ703の出力信号と各命令フローの実行タイミングを示す+P_EAG_VALID信号とのアンド論理を取って、その出力として各命令フローが発行される毎にプリフェッチ要求信号+P_PREFETCH_REQUESTを、オア回路706を介して出力する。

Description

プリフェッチ要求回路
 開示する技術は、キャッシュを備えたプロセッサ装置におけるメモリアクセス時に、プリフェッチを要求するためのプリフェッチ要求技術に関する。
 コンピュータのプロセッサ装置では一般に、メインメモリに対するアクセス性能を高めるために、2次キャッシュ及び1次データキャッシュ、1次命令キャッシュ等が搭載されている。
 プロセッサでは、メインメモリから2次キャッシュ及び1次命令キャッシュを経て読み出された命令は、命令デコーダに送られ、そこでデコードされる。
 デコードされた命令が、ロード命令、ストア命令、メモリコピー命令などのメモリアクセス命令である場合は、オペランドアドレス生成器が、アクセスされるべきメモリアドレスを計算し、計算されたアドレスによって1次データキャッシュにアクセスする。
 ここで、メモリコピー命令の実行時には、メモリ上のコピー元アドレス(これを「アドレスA」とする)のデータが、コピー先アドレス(これを「アドレスB」とする)へコピーされる。命令長は決まっているため、メモリコピー命令において一度に指定できる最大のコピーサイズがある。
 メインメモリと2次キャッシュ間、又は2次キャッシュと1次データキャッシュ間の1サイクルでのデータ転送能力以下のデータサイズがコピーサイズとして1命令で指定された場合には、例えば図1の(a)で示される処理が実行される。即ち、デコードされたメモリコピー命令は、CSE(Commit Stack Entry)と呼ばれる命令キューにデコード順に登録される。図1(a)の例では、CSEの1つのエントリCSE0に、メモリコピー命令が登録されるものとする。
 CSEの各エントリには、各命令を識別するためのIID(命令識別子)と、登録された命令の有効又は無効を指示するためのバリッドフラグが登録される。CSEのエントリ数は例えば数十エントリ程度である。プロセッサには、CSEのほかに、各命令を優先順位(プライオリティ)を付けて登録しアウトオブオーダで実行できる、RS(Reservation Station)と呼ばれる命令キューが備えられている。RSの各エントリにも、各命令を識別するためのIIDが登録される。メモリコピー命令はRSを介してオペランドアドレス生成器で処理され、メモリコピー命令に基づくメモリコピー処理が実行される。この場合、CSEにデコード順に登録された命令とRSを介してアウトオブオーダで実行される命令は、命令識別子(IID)によって紐付けられている。そして、RSを介して実行が完了した命令は、その命令に対応するRSのエントリに登録されているIIDによってCSEのエントリと照合され、同じIIDが登録されているCSEのエントリのバリッドフラグ(Valid)が無効を示す値に変更されて命令の実行を完了する。この紐付け制御により、RSを介してアウトオブオーダで実行される命令の順序が、CSEによって保証される。
 図1(a)において、メモリコピー命令のデータ転送能力は例えば16バイト(16B)であり、「16Bメモリコピー」命令は、16バイトまでのデータ転送命令であることを示している。
 一方、メインメモリと2次キャッシュ間、又は2次キャッシュと1次データキャッシュ間の1サイクルでのデータ転送能力を超えるデータサイズがコピーサイズとして1命令で指定された場合には、例えば図1の(b)及び(c)で示される処理が実行される。この場合には、命令デコーダが、例えば32バイトのデータ転送命令である「32Bメモリコピー」命令に対して、マルチフロー展開と呼ばれる処理を実行する。マルチフロー展開では、「32Bメモリコピー」命令は2つの「16Bメモリコピー」命令に分解される。このように複数の命令にデコードされた各「16Bメモリコピー」命令は、図1(b)及び(c)として示されるように、それぞれ個別のCSEエントリCSE0及びCSE1に登録される。そして、CSE0、CSE1の各エントリに登録された各「16Bメモリコピー」命令は、各命令と共に登録されている各IIDを介して紐付けられている個別のRSエントリを介してアウトオブオーダで実行され、オペランドアドレス生成器で個別にパイプライン処理される。この結果、16バイト単位のメモリコピー処理が実行される。
 ここで、メモリコピー命令で指定できる最大のサイズを超えてデータのコピーを行ないたい場合、プログラムではメモリコピー命令が連続して記述される。つまり、大きなサイズのメモリコピー処理は、連続する複数のメモリコピー命令として記述される。更に、各メモリコピー命令で指定されるデータサイズが2次キャッシュ及び1次データキャッシュ間の1サイクルのデータ転送能力を超えている場合には、各メモリコピー命令がマルチフロー展開されて実行される。例えば、2次キャッシュ及び1次データキャッシュ間の上記データ転送能力が16バイトで、1つのメモリコピー命令で指定される最大データサイズを256バイトとする。この場合、例えば1024バイトのメモリーコピー処理は、連続する4回の256バイトメモリコピー命令として記述され、各256バイトメモリコピー命令は、16回の16バイトメモリコピー命令にマルチフロー展開される。
 この場合、各メモリコピー命令に基づくメモリアクセスで1次データキャッシュがヒットした場合、上記メモリアクセスで1次データキャッシュがミスし2次キャッシュがヒットした場合、及び上記メモリアクセスで両方ともミスした場合のそれぞれでは、図2に示されるように、データアクセス時間に大きな差が生じる。なお、図2において、「L1$HIT」は1次データキャッシュがヒットした場合を示している。また、「L1$miss、L2$HIT」は1次データキャッシュがミスし2次キャッシュがヒットした場合を示している。更に、「L1$、L2$miss」は1次データキャッシュ及び2次キャッシュ共にミスした場合を示している。当然、メモリアクセス実行時には、「L1$、L2$miss」よりも「L1$miss、L2$HIT」、「L1$miss、L2$HIT」よりも「L1$HIT」の発生頻度が高いほうが、高速処理が可能となる。
 そこで、連続するメモリコピー命令が記述され、各メモリコピー命令として、1命令で指定できる最大サイズ(例えば256バイト)のメモリコピー命令が指定されたときには、次のような制御が実行される。なお、以下の説明において、各メモリコピー命令をマルチフロー展開して得られるメモリコピー命令を、MFメモリコピー命令と呼ぶ。
 各メモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令の実行には、プリフェッチ要求が発行される。このプリフェッチ要求は、各メモリコピー命令がマルチフロー展開されて得られる2番目以降のMFメモリコピー命令の実行時には発行されない。
 この結果、各メモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令の実行において、1次データキャッシュ及び2次キャッシュ共にミス(L1$、L2$miss)した場合、次のようなフェッチ動作とプリフェッチ動作が実行される。
 即ちまず、最初のMFメモリコピー命令で指定されるメモリアドレスから数ブロック分のアドレス範囲のメモリデータが、メインメモリから2次キャッシュにフェッチされ、更にそのメモリデータのうちの一部が1次データキャッシュにもフェッチされる。この数ブロック分のアドレス範囲は、例えばメインメモリから2次キャッシュへの1回のデータ転送単位分、例えば256バイト分に対応するアドレス範囲である。
 これと共に、最初のMFメモリコピー命令の実行時の1次データキャッシュのミス(L1$miss)に基づいて、その命令で発行されているプリフェッチ要求に基づいて、プリフェッチ動作が実行される。この結果、最初のMFメモリコピー命令で指定されるメモリアドレスから上記数ブロック分先から更に上記数ブロック分のアドレス範囲のメモリデータが、2次キャッシュに予めプリフェッチされる。
 最初のMFメモリコピー命令において、1次データキャッシュがヒット(L1$HIT)した場合には、上記プリフェッチ要求にかかわらずプリフェッチ動作は実行されない。
 各メモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令以外の2番目以降のMFメモリコピー命令では、プリフェッチ要求は発行されないため上記プリフェッチ動作は実行されない。2番目以降のMFメモリコピー命令の実行時に、1次データキャッシュがミス(L1$miss)した場合には、2次キャッシュ又はメインメモリに対する通常のフェッチ動作が実行される。
 ここで、1つのメモリコピー命令がマルチフロー展開されて実行された後に、次のメモリコピー命令が連続して実行された場合を考える。この場合、次のメモリコピー命令に対応する各MFメモリコピー命令で1次データキャッシュがミス(L1$miss)しても、2次キャッシュに上記各MFメモリコピー命令に対応するメモリデータがプリフェッチされている確率が高まる。即ち、2次キャッシュはヒット(L2$HIT)する可能性が高い。これにより、2番目以降のメモリコピー命令の2次キャッシュのミス(L2$miss)によるペナルティを少なくするような制御が実行される。
 なお、上記次のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、再びプリフェッチ要求が発行される。この結果、次のメモリコピー命令の実行時に1次データキャッシュがミス(L1$miss)すると、更にその次のメモリコピー命令のためのプリフェッチ動作が実行されることになる。この結果、現在マルチフロー展開により実行中のメモリコピー命令の次のメモリコピー命令のためのメモリデータが、順次2次キャッシュにプリフェッチされることになる。
 以上のプリフェッチ制御処理において、マルチフロー展開に基づいて、最大サイズのメモリコピー命令が連続して実行される第1のケースについて、図3の動作説明図に基づいて更に具体的に説明する。
 図3のケース1の例では、2次キャッシュから1次データキャッシュへのデータ転送単位に対応するメモリブロックが64バイト(64B)、1つのメモリコピー命令で指定可能な最大データサイズが256バイトである。また、連続する複数の256バイトメモリコピー命令によって1つの大きなサイズのメモリコピー処理が実行される。そして、アドレスA,Bがメモリブロックのブロック境界に位置するとして、上記メモリコピー処理の最初の256バイトメモリコピー命令におけるコピー元先頭アドレスがA、コピー先先頭アドレスがBである。
 図3においてまず、第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令時に、プリフェッチ要求が発行される。この最初のMFメモリコピー命令において、コピー元先頭アドレスはA、コピー先先頭アドレスはBである。このプリフェッチ要求は、第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる2番目以降のMFメモリコピー命令においては発行されない。
 この結果、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行において、1次データキャッシュ及び2次キャッシュ共にミスした場合(L1$、L2$miss)、次のようなフェッチ動作とプリフェッチ動作が実行される。
 即ちまず、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令で指定されるメモリアドレスAから4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリから2次キャッシュにフェッチされる。このアドレス範囲は、64B×4メモリブロック=256バイト分であり、AからA+255までである。更に、2次キャッシュにフェッチされるメモリデータのうちの一部のメモリブロックが、1次データキャッシュにもフェッチされる。また、最初のMFメモリコピー命令で指定されるメモリアドレスBから4メモリブロック分のアドレス範囲(BからB+255まで)のコピー先メモリ領域が、2次キャッシュに確保(フェッチ)される。
 次に、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時の1次データキャッシュのミス(L1$miss)に基づいて、その命令で発行されているプリフェッチ要求に基づいて、プリフェッチ動作が実行される。即ち、上記最初のMFメモリコピー命令で指定されるメモリアドレスから4メモリブロック分先から更に4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリから2次キャッシュにプリフェッチされる。このアドレス範囲は、A+256からA+511までである。コピー先メモリデータのための2次キャッシュでの領域確保(プリフェッチ)についても同様である(B+256からB+511まで)。
 第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令以外の2番目以降のMFメモリコピー命令では、プリフェッチ要求は発行されないため上記プリフェッチ動作は実行されない。2番目以降のMFメモリコピー命令の実行に1次データキャッシュがミス(L1$miss)した場合には、通常のフェッチ動作が実行される。この場合、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時に、メモリアドレスA(又はB)から4メモリブロック分のアドレス範囲に対するメインメモリから2次キャッシュへのフェッチ動作が実行されている。このため、2番目以降のMFメモリコピー命令の実行時に1次データキャッシュがミス(L1$miss)した場合のフェッチ動作では、2次キャッシュがヒット(L2$HIT)し、高速なメモリアクセスが実現される。
 ここで、第1番目(1st)のメモリコピー命令がマルチフロー展開されて実行された後に、第2番目(2nd)のメモリコピー命令が連続して実行された場合を考える。この場合、第2番目(2nd)のメモリコピー命令に対応する各MFメモリコピー命令で1次データキャッシュがミス(L1$miss)しても、2次キャッシュに上記各MFメモリコピー命令に対応するメモリデータがプリフェッチされている。即ち、2次キャッシュはヒット(L2$HIT)する。これにより、第2番目(2nd)のメモリコピー命令の2次キャッシュのミス(L2$miss)によるペナルティを少なくするような制御が実行される。
 ここで、上記第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時に、再びプリフェッチ要求が発行される。従って、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時に1次データキャッシュがミス(L1$miss)すると、プリフェッチ要求に基づき第3番目(3rd)のメモリコピー命令のためのプリフェッチ動作が実行される。これにより、アドレス範囲A+512からA+767及びB+512からB+767に対応するメインメモリから2次キャッシュへのプリフェッチ動作が実行されることになる。
 このようにして、各メモリコピー命令に対応する最初のMFメモリコピー命令の実行時での1次データキャッシュのミス(L1$miss)により、現在実行中のメモリコピー命令の次のメモリコピー命令のためのプリフェッチ動作が順次実行されることになる。
 次に、プリフェッチ制御処理において、マルチフロー展開に基づいて、最大サイズのメモリコピー命令が連続して実行される第2のケースについて、図4の動作説明図に基づいて更に具体的に説明する。
 図4のケース2の例では、図3のケース1の例の場合と同様に、2次キャッシュから1次データキャッシュへのデータ転送単位に対応するメモリブロックが64バイト(64B)、1つのメモリコピー命令で指定可能な最大データサイズが256バイトである。また、図3の場合と同様に、連続する複数の256バイトメモリコピー命令によって1つの大きなサイズのメモリコピー処理が実行される。図4のケース2では、アドレスA,Bがメモリブロックのブロック境界に位置するとして、上記メモリコピー処理の最初の256バイトメモリコピー命令におけるコピー元先頭アドレスがA+16、コピー先先頭アドレスがB+16とされる。即ち、図3のケース1では、メモリコピー処理の開始アドレスがブロック境界に存在したが(アドレスA,B)、図4のケース2では、ブロック境界に存在しない。
 図4のケース2においてまず、図3のケース1と同様に、第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令時に、プリフェッチ要求が発行される。この最初のMFメモリコピー命令において、コピー元先頭アドレスはA+16、コピー先先頭アドレスはB+16である。このプリフェッチ要求は、図3のケース1と同様に、第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる2番目以降のMFメモリコピー命令においては発行されない。
 この結果、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行において、1次データキャッシュ及び2次キャッシュ共にミスした場合(L1$、L2$miss)、次のようなフェッチ動作とプリフェッチ動作が実行される。
 即ちまず、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令で指定されるメモリアドレスA+16から4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリから2次キャッシュにフェッチされる。このアドレス範囲はメモリブロック単位で指定され、64B×4メモリブロック=256バイト分であり、AからA+255までである。更に、2次キャッシュにフェッチされるメモリデータのうちの一部のメモリブロックが、1次データキャッシュにもフェッチされる。コピー先メモリデータのための2次キャッシュでの領域確保(フェッチ)についても同様である(BからB+255まで)。
 次に、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時の1次データキャッシュのミス(L1$miss)に基づいて、その命令で発行されているプリフェッチ要求に基づいて、プリフェッチ動作が実行される。即ち、上記最初のMFメモリコピー命令で指定されるメモリアドレスから4メモリブロック分先から更に4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリから2次キャッシュにプリフェッチされる。このアドレス範囲もメモリブロック単位で指定され、A+256からA+511までである。コピー先メモリデータのための2次キャッシュでの領域確保(プリフェッチ)についても同様である(B+256からB+511まで)。
 ここで、第1番目(1st)のメモリコピー命令がマルチフロー展開されて実行された後に、第2番目(2nd)のメモリコピー命令が連続して実行された場合を考える。
 第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、再びプリフェッチ要求が発行される。ここで、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令において、コピー元先頭アドレスはA+272、コピー先先頭アドレスはB+272である。そして、これらのアドレスが含まれるメモリブロックは、第1番目(1st)のメモリコピー命令に対応する最後のMFメモリコピー命令が実行されたときにアクセスされたメモリブロックと同一である。従って、図4のケース2では、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、1次データキャッシュはヒット(L1$HIT)しミスしない。メインメモリから2次キャッシュへのプリフェッチ動作は、1次データキャッシュに対してプリフェッチ要求が発行されており、かつ1次データキャッシュがミス(L1$miss)した場合においてのみ実行される。従って、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、プリフェッチ要求が発行されているにもかかわらず、第3番目(3rd)のメモリコピー命令のためのプリフェッチ動作が実行されないことになる。
 この結果、第3番目(3rd)のメモリコピー命令のマルチフロー展開実行時に最初に1次データキャッシュがミス(L1$miss)したときには、2次キャッシュ上に第3番目(3rd)のメモリコピー命令のためのメモリデータが存在しないことになる。このため、1次データキャッシュと2次キャッシュの両方がミス(L1$、L2$miss)することになり、メインメモリから2次キャッシュに第3番目(3rd)のメモリコピー命令のためのメモリデータをフェッチする必要が生じる。これ以後、第3番目(3rd)のメモリコピー命令に対応する各MFメモリコピー命令は、そのフェッチ動作が完了するまで命令実行が待たされることになり、大きなメモリアクセスペナルティが発生する。
 更に、第3番目(3rd)のメモリコピー命令に対応する最初のMFメモリコピー命令において、コピー元先頭アドレスはA+528、コピー先先頭アドレスはB+528である。そして、これらのアドレスが含まれるメモリブロックは、第2番目(2nd)のメモリコピー命令に対応する最後のMFメモリコピー命令が実行されたときにアクセスされたメモリブロックと同一である。従って、図4のケース2では、第3番目(3rd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時も、1次データキャッシュはヒット(L1$HIT)しミスしない。このため、第3番目(3rd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時にも、プリフェッチ要求が発行されているにもかかわらず、第4番目(4th)のメモリコピー命令のためのプリフェッチ動作が実行されないことになる。
 このような悪循環により、図4のケース2では、第2番目(2nd)以降の全てのメモリコピー命令で、各メモリコピー命令に対応する最初のMFメモリコピー命令にてプリフェッチ要求が発行されるにもかかわらず、プリフェッチ動作が実行されないことになる。この結果、メモリコピー命令のメモリアクセス効率が大幅に低下してしまうという問題点を有していた。
特開昭59-218691号公報 特開昭58-169384号公報
 開示する技術が解決しようとする課題は、最大転送能力サイズのメモリアクセス命令が連続して実行される場合において、どのような場合にもプリフェッチ要求の効果が高くなるようにすることにある。
 開示する技術の第1の態様は、記憶領域が2つ以上に階層化されているプロセッサで、命令のデコード時に1つの命令が複数の命令フローにマルチフロー展開された各命令フローを実行するとき、2つ以上の記憶領域のうち適切な記憶領域間で予め利用される予定のアドレスのデータをプリフェッチできるプロセッサ装置におけるプリフェッチ要求回路として実現される。
 ラッチ部は、記憶領域にアクセスするための各命令フローを最大指定可能データ転送量で実行する状態が指示されたときに、その状態をマルチフロー展開の期間中保持する。
 プリフェッチ要求信号出力部は、ラッチ部の出力信号と各命令フローの実行タイミングを示す信号とに基づいて、各命令フローが実行される毎にプリフェッチを要求するプリフェッチ要求信号を出力する。
 開示する技術の第2の態様は、メインメモリと2次キャッシュと1次データキャッシュを備え、命令のデコード時に1つの命令を複数の命令フローにマルチフロー展開し各命令フローを実行し、1次データキャッシュへのメモリアクセス時にメインメモリから2次キャッシュへ予め利用される予定のアドレスのデータをプリフェッチすることができるプロセッサ装置におけるプリフェッチ要求回路を前提とする。
 ラッチ回路部は、メモリアドレス間のデータのコピー又は移動、演算を指示するメモリコピー命令に対応する各命令フローを最大指定可能データ転送量で実行する状態が指示されたときに、その状態をマルチフロー展開の期間中保持する。
 アンド回路部は、ラッチ部の出力信号と各命令フローの実行タイミングを示す信号とのアンド論理を取って、そのアンド論理出力として各命令フローが発行される毎にプリフェッチ要求信号を出力する。
 上記第1又は第2の態様により、最大転送能力サイズのメモリアクセス命令が連続して実行される場合において、どのような場合にもプリフェッチ要求の効果が高くなるようなプリフェッチ要求信号を出力することが可能となる。
マルチフロー展開の説明図である。 キャッシュミス時のペナルティの説明図である。 プリフェッチの効果を説明するための図である。 従来技術の問題点の説明図である。 実施形態を適用できるプロセッサ装置の全体構成図である。 図5の命令デコーダ504、CSE505、RSA506、オペランドアドレス生成器509、及び1次データキャッシュ510の部分によるメモリアクセス動作の説明図である。 プリフェッチ要求回路の実施形態を示す図である。 プリフェッチ要求回路の実施形態の動作タイミングチャートである。 実施形態の効果を説明するための図である。
 以下、図面を参照しながら、本発明の実施形態について詳細に説明する。
 図5は、本発明の一実施形態によるプロセッサ装置の全体構成図である。
 図5に示されるプロセッサ装置においては、命令フェッチアドレス生成器519が1次命令キャッシュ503にアクセスすることにより、メインメモリ501から2次キャッシュ502及び1次命令キャッシュ503を介して必要な命令を読み出す。読み出された命令は、命令デコーダ504に送られる。
 命令デコーダ504は、デコード(D)サイクルにおいて、インオーダにて命令をデコードする。
 命令デコーダ504でデコードされた命令は、CSE(Commit Stack Entry)505に順番に登録される。同時に、命令デコーダ504でデコードされた命令は、アウトオブオーダ実行制御を行う各リザベーションステーションRSA(Reservation Station for Address)506及びRSE(Reservation Station for Execute)507に登録される。更に、命令デコーダ504でデコードされた命令が分岐命令である場合には、命令が分岐命令用リザべーションステーションRSBR(Reservation Station for Branch)508に登録される。CSE505、RSA506、RSE507、及びRSBR508の各エントリには、命令デコーダ504でデコードされた各命令を識別するためのIID(命令識別子)が登録される。また、CSEの各エントリには、IIDと共に、登録された命令の有効又は無効を指示するためのバリッドフラグが登録される。CSE505にデコード順に登録された命令と、RSA506、RSE507、又はRSBR508を介してアウトオブオーダで実行される命令は、命令識別子(IID)によって紐付けられている。そして、RSA506、RSE507、又はRSBR508を介して実行が完了した命令は、その命令に対応するRSA506、RSE507、又はRSBR508のエントリに登録されているIIDによってCSE505のエントリと照合される。そして、同じIIDが登録されているCSE505のエントリのバリッドフラグ(Valid)が無効を示す値に変更されて命令の実行を完了する。この紐付け制御により、RSA506、RSE507、又はRSBR508を介してアウトオブオーダで実行される命令の順序が、CSE505によって保証される。
 命令デコーダ504が、メモリコピー命令をマルチフロー展開した場合のように、同時に複数の命令をデコードして発行したようなときには、命令デコーダ504が発行した各命令がRSA506に登録される。或いは、1次データキャッシュ510においてキャッシュミスが発生しメモリデータのフェッチに時間がかかっているようなときにも、命令デコーダ504が発行した後続する命令がRSA506に登録される。
 RSA506では、各エントリの優先順位(プライオリティ)が決定される。プライオリティ(P)サイクルで実行が可能となったRSA506に登録されたメモリアクセス命令に対しては、オペランドアドレス生成器509が、アクセスするメモリアドレスをアドレス計算(X)サイクルにて計算する。メモリアクセス命令としては、ロード命令、ストア命令、メモリコピー命令などがある。オペランドアドレス生成器509は、計算したアドレスによって、1次データキャッシュ510にアクセスする。
 RSA506にエントリが1つもない場合は、命令は、RSA506には登録されずに、命令デコーダ504でデコードされた後すぐに、オペランドアドレス生成器509に投入される。
 RSA506から1次データキャッシュへは、プリフェッチ要求信号+P_PREFETCH_REQUESTが発行される。プリフェッチ要求信号は、従来は、図3又は図4等で前述したように、最大コピーサイズを有するメモリコピー命令に対応する各MFメモリコピー命令(マルチフロー展開命令)のうち、最初のMFメモリコピー命令が発行されるタイミングでのみ発行されていた。本実施形態では、後述するように、最大コピーサイズを有するメモリコピー命令からマルチフロー展開された各MFメモリコピー命令がRSA506から発行される毎に、プリフェッチ要求信号+P_PREFETCH_REQUESTが発行される点が異なる。
 算術演算命令又は論理演算命令に対しては、固定小数点レジスタ513又は浮動小数点レジスタ514の内容が読み出され、アウトオブオーダで演算器511又は512に投入される。演算器511又は512は、演算実行(X)サイクルで、演算命令によって指定された演算を実行する。
 演算器511又は512での実行結果は、レジスタ更新(U)サイクルで、固定小数点更新バッファ515又は浮動小数点更新バッファ516に格納されて、命令完了(コミット)処理を待つ。演算器511又は512での演算実行完了、1次データキャッシュ510でのデータ転送完了、又は分岐予測機構518からの分岐判定完了などの報告をCSE505が受けた後、固定小数点更新バッファ515又は浮動小数点更新バッファ516において、インオーダでコミット処理が行われる。更に、レジスタ書込み(W)サイクルで、各更新バッファ515又は516から各レジスタ513又は514への書込みが行われる。
 CSE505に登録された1つの命令について実行が完了すると、実行が完了した命令に対応するCSE505のエントリのバリッドフラグが無効を示す値に変更されることによりCSE505での登録が抹消される。そして、次の命令フェッチアドレスを指定するPSW(Program Status Word)517の内容が更新される。
 命令フェッチアドレス生成器519は、PSW517、RSBR508、又はRSBR508から分岐予測機構518を介して与えられる命令フェッチアドレス情報に基づいて、次の命令フェッチアドレスを生成し、生成した命令フェッチアドレスによって1次命令キャッシュ503にアクセスする。
 上記構成を有するプロセッサにおいて、メモリにアクセスする命令の実行時に、1次データキャッシュ510へのアクセスがミスした場合、2次キャッシュ502又はメインメモリ501から、アクセスするアドレスが含まれるメモリブロックがフェッチされる。これにより、1次データキャッシュ510にデータが取得される。メモリコピー命令などのように1パイプラインでは処理しきれない命令は、命令デコーダ504においてマルチフロー展開される。そして、展開されたフロー毎に、CSE505、RSA506、RSE507、及びRSBR508への命令の登録が行われ、スーパスカラーとパイプライン処理によって1命令が実行される。
 図6は、図5の命令デコーダ504、CSE505、RSA506、オペランドアドレス生成器509、及び1次データキャッシュ510の部分によるメモリアクセス動作の説明図である。メモリコピー命令の一例としてMVC(MOVE character)命令を想定する。MVC命令は最大256バイトのデータをバイト単位で指定して、任意のコピー元アドレスAからコピー先アドレスBへコピーするメモリコピー命令である。ここでは、最大値256バイトのMVC命令を「MVC256」命令とよぶ。
 命令デコーダ504において、デコード(D)サイクルでデコードされたMVC256命令は、マルチフロー展開によって、16個の「MVC16」命令に分解される。「MVC16」命令は、16バイト単位で、メインメモリ501、2次キャッシュ502、又は1次データキャッシュ510に対するデータのLOAD若しくはSTORE、又はLOADと及びSTOREの同時処理を実行する命令である。
 このように複数のMFメモリコピー命令にマルチフロー展開されてデコードされた各「MVC16」命令は、図6に示されるように、CSE505内の16個のCSEエントリCSE0からCSE15に個別に登録される。また、各「MVC16」命令は、RSA506、RSE507に登録される。このとき前述したように、各CESエントリCSE0からCSE15には、各「MVC16」命令のIIDが登録され、このIIDによって各CESエントリCSE0~CSE15とRSA506又はRSE507内の各エントリとが紐付けられる。
 「MVC256」命令からマルチフロー展開されて得られた各「MVC16」命令のうち最初の「MVC16」命令が登録されるRSA506のエントリには、最初の「MVC16」命令に対応するIIDと共に、+D_MVC_256_1ST信号がセットされる。
  この+D_MVC_256_1ST信号は、命令デコーダ504からセットされ、コピーサイズが最大の256バイトであるメモリコピー命令に対してマルチフロー展開された最初のMFメモリコピー命令であることを示す信号である。
 また、「MVC256」命令からマルチフロー展開されて得られた各「MVC16」命令のうち、最初の「MVC16」命令のデコード(D)サイクルから、最後の「MVC16」命令の演算器511又は512への投入まで(後述する図8のt2~t5の期間)、命令デコーダ504からRSA506に、マルチフロー展開中であることを示すハイレベルの+D_MF_TGR信号が出力される。
 RSA506に登録された各「MVC16」命令の各エントリは、プライオリティの高い順にオペランドアドレス生成器509に発行される。この結果、オペランドアドレス生成器509が、1次データキャッシュ510へのメモリアクセスを実行する。なお、RSA506から1次データキャッシュへは、各「MVC16」命令が発行される毎に、オペランドアドレス生成器509(EAG)を有効(VALID)にすることを示す+P_EAG_VALID信号がアサートされる。
 また、RSA506から1次データキャッシュ510へは、「MVC256」命令に対応する各マルチフロー展開命令「MVC16」がRSA506から発行される毎に、プリフェッチ要求信号+P_PREFETCH_REQUESTがアサートされる。
 図7は、上述のプリフェッチ要求信号+P_PREFETCH_REQUESTを発行するために、RSA506に実現されるプリフェッチ要求回路の構成を示す図である。また、図8は、図7のプリフェッチ要求回路の動作を示す動作タイミングチャートである。
 図3又は図4等で前述したように、従来は、最大コピーサイズを有する「MVC256」命令に対応する各マルチフロー展開命令「MVC16」のうち、最初の「MVC16」命令が発行されるタイミングにおいてのみプリフェッチ要求信号が発行されていた。これに対して、本実施形態は、各「MVC16」命令が発行される図8(i)として示されるタイミング毎に、プリフェッチ要求信号+P_PREFETCH_REQUESTが発行される点が異なる。
 このプリフェッチ要求信号+P_PREFETCH_REQUESTを出力させるために、図7のプリフェッチ要求回路は、以下に説明するように動作する。
 まず、図7のプリフェッチ要求回路は、+D_MF_TGR信号、+P_EAG_VALID信号、及び+P_MVC_256_1ST信号に基づいて動作する。
 +D_MF_TGR信号は、前述したように、命令デコーダ504から発行され、マルチフロー展開中の期間でアサートされる信号であり、例えば図8(d)のt2からt5までの期間でアサートされる。
 +P_EAG_VALID信号は、前述したように、RSA506がオペランドアドレス生成器509に命令を発行するたびに、RSA506によってアサートされる信号であり、例えば図8(a)のt1、t3、t4の各タイミングでアサートされる。
 +P_MVC_256_1ST信号は、命令デコーダ504から発行される+D_MVC_256_1ST信号に基づいてRSA506内部で生成される信号である。より具体的には、最大コピーサイズを有する「MVC256」命令からマルチフロー展開された最初の「MVC16」命令が、RSA506からオペランドアドレス生成器509に発行されるタイミングで、+P_MVC_256_1ST信号が発行される。このとき、上記最初の「MVC16」命令が実行されるタイミングで、その最初の「MVC16」命令が登録されているRSA506内のエントリにセットされている+D_MVC_256_1ST信号に基づいて、+P_MVC_256_1ST信号がアサートされる。この+P_MVC_256_1ST信号は、例えば図8(b)のt1のタイミングでアサートされる。
 図7において、アンド回路701が+P_MVC_256_1ST信号(図8(b))及び+P_EAG_VALID信号(図8(a))のアンド論理を取ることで、例えば図8(c)のt1からt2でアサートされる信号を出力する。
 t1からt2でアサートされたアンド回路701の出力は、「MVC256」命令に対応する最初のマルチフロー展開命令「MVC16」に対応するプリフェッチ要求信号+P_PREFETCH_REQUESTとして、オア回路706を介して1次データキャッシュ510に発行される。
 t1からt2でアサートされたアンド回路701の出力は同時に、オア回路702を介して1ビットラッチ703の入力端子Dinに入力して、1ビットラッチ703によりラッチされる。図8(d)はDinに入力するオア回路702の出力信号を示しており、t1からt5の期間でアサートされる。
 1ビットラッチ703によりラッチされた信号は、次のクロックサイクルで1ビットラッチ703のDoutから出力される。そのDout出力信号は、アンド回路704において、命令デコーダ504から入力する+D_MF_TGR信号(図8(d))とのアンド論理が取られる。この結果、アンド回路704の出力は、例えば図8(e)のt2からt5の期間でアサートされる。
 そして、アンド回路704の出力がオア回路702を介して1ビットラッチ703の入力端子Dinに入力する。このようにして、マルチフロー展開期間中は、1ビットラッチ703の出力端子Doutは、アサート状態となる。図8(g)は1ビットラッチ703の出力端子Doutからの出力を示しており、t2からt6までの期間オンとなる。
 アンド回路705は、+P_EAG_VALIDと、1ビットラッチ703の出力Dout(図8(g))のアンド論理を取る。+P_EAG_VALID信号は、図8(a)に示されるように、RSA506がオペランドアドレス生成器509に命令を発行する毎にアサートされる。また、1ビットラッチ703の出力Doutは、図8(g)に示されるように、最大コピーサイズを有する「MVC256」命令のマルチフロー展開期間中にアサートされる。
 従って、アンド回路705の出力は、図8(h)に示されるように、最大コピーサイズを有する「MVC256」命令に対応する2番目以降のマルチフロー展開命令「MVC16」に対応する各タイミングt3及びt4でアサートされる。この出力信号が、オア回路706を介して、プリフェッチ要求信号+P_PREFETCH_REQUESTとして、1次データキャッシュ510に発行される。
 この結果、アンド回路701と705のオア出力として、「MVC256」命令に対応する各「MVC16」命令の実行タイミング毎に、プリフェッチ要求信号+P_PREFETCH_REQUESTが、1次データキャッシュ510に発行される。
 図9は、図7のプリフェッチ要求回路の効果を説明するための図である。
 図9のケースの例では、前述した図4のケース2の例の場合と同様に、2次キャッシュから1次データキャッシュへのデータ転送単位に対応するメモリブロックが64バイト(64B)、1つのメモリコピー命令で指定可能な最大データサイズが256バイトである。また、図4の場合と同様に、連続する複数の256バイトメモリコピー命令によって1つの大きなサイズのメモリコピー処理が実行される。更に、図4のケース2と同様に、アドレスA,Bがメモリブロックのブロック境界に位置するとして、上記メモリコピー処理の最初の256バイトメモリコピー命令におけるコピー元先頭アドレスがA+16、コピー先先頭アドレスがB+16とされる。即ち、メモリコピー処理の開始アドレスがブロック境界に存在しない。
 図9のケースにおいてまず、第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令時に、図7のプリフェッチ要求回路によってプリフェッチ要求信号+P_PREFETCH_REQUESTが発行される。このタイミングは、例えば図8(i)のt1からt2の期間に相当する。この最初のMFメモリコピー命令において、コピー元先頭アドレスはA+16、コピー先先頭アドレスはB+16である。
 最初のMFメモリコピー命令で指定された上記アドレスに基づいて、オペランドアドレス生成器509がアクセスアドレスを計算し、1次データキャッシュ510にアクセスする。この結果、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行にて、1次データキャッシュ510及び2次キャッシュ502共にミスした場合(L1$、L2$miss)、以下のフェッチ動作とプリフェッチ動作が実行される。
 即ちまず、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令で指定されるメモリアドレスA+16から4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリ501から2次キャッシュ502にフェッチされる。このアドレス範囲はメモリブロック単位で指定され、64B×4メモリブロック=256バイト分であり、AからA+255までである。更に、2次キャッシュ502にフェッチされるメモリデータのうちの一部のメモリブロックが、1次データキャッシュ510にもフェッチされる。コピー先メモリデータのための2次キャッシュでの領域確保(フェッチ)についても同様である(BからB+255まで)。
 次に、第1番目(1st)のメモリコピー命令に対応する最初のMFメモリコピー命令で発行されているプリフェッチ要求信号+P_PREFETCH_REQUESTに基づいて、プリフェッチ動作が実行される。即ち、上記最初のMFメモリコピー命令で指定されるメモリアドレスから4メモリブロック分先から更に4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリ501から2次キャッシュ502にプリフェッチされる。このアドレス範囲もメモリブロック単位で指定され、A+256からA+511までである。コピー先メモリデータのための2次キャッシュでの領域確保(プリフェッチ)についても同様である(B+256からB+511まで)。
 次に、本実施形態では、第1番目(1st)のメモリコピー命令がマルチフロー展開されて得られる最初のMFメモリコピー命令以外の2番目以降のMFメモリコピー命令でも、プリフェッチ要求信号+P_PREFETCH_REQUESTが発行される。例えば図8(i)のt3、t4のタイミングである。ここで、1次データキャッシュがミス(L1$miss)した場合には、現在実行中のMFメモリコピー命令で発行されているプリフェッチ要求信号+P_PREFETCH_REQUESTに基づいて、プリフェッチ動作が実行される。即ち、現在実行中のMFメモリコピー命令で指定されるメモリアドレスから4メモリブロック分先から更に4メモリブロック分のアドレス範囲において2次キャッシュ502に存在しない分が、メインメモリ501から2次キャッシュ502にプリフェッチされる。
 ここで、第1番目(1st)のメモリコピー命令がマルチフロー展開されて実行された後に、第2番目(2nd)のメモリコピー命令が連続して実行された場合を考える。
 第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、再びプリフェッチ要求が発行される。ここで、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令において、コピー元先頭アドレスはA+272、コピー先先頭アドレスはB+272である。そして、これらのアドレスが含まれるメモリブロックは、第1番目(1st)のメモリコピー命令に対応する最後のMFメモリコピー命令が実行されたときにアクセスされたメモリブロックと同一である。従って、図9のケースでは、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、1次データキャッシュはヒット(L1$HIT)しミスしない。従って、第2番目(2nd)のメモリコピー命令に対応する最初のMFメモリコピー命令の実行時には、プリフェッチ要求信号+P_PREFETCH_REQUESTは発行されているが、プリフェッチ動作は実行されない。
 続いて、第2番目(2nd)のメモリコピー命令に対応するMFメモリコピー命令のうち、メモリブロック境界A+320(B+320)のアドレスを指定するMFメモリコピー命令が実行されるタイミングを考える。この場合も、図7のプリフェッチ要求回路によって、プリフェッチ要求信号+P_PREFETCH_REQUESTが発行される。この場合、A+320(B+320)のアドレス領域のメモリブロックは、未だ実行されていないメモリブロックであるため、1次データキャッシュ510には存在しない。このため、1次データキャッシュ510がミス(L1$miss)する。これによりまず、A+320(B+320)のアドレスから始まるメモリブロックが、2次キャッシュ502から1次データキャッシュ510にフェッチされる。これと共に、L1$missと上記プリフェッチ要求信号+P_PREFETCH_REQUESTとに基づいて、プリフェッチ動作が実行される。即ち、上記MFメモリコピー命令で指定されるメモリブロック境界A+320のアドレスから4メモリブロック分先から更に4メモリブロック分のアドレス範囲のコピー元メモリデータが、メインメモリ501から2次キャッシュ502にプリフェッチされる。このアドレス範囲は、A+576からA+831までである。コピー先メモリデータのための2次キャッシュでの領域確保(プリフェッチ)についても同様である(B+576からB+831まで)。
 このようにして、第3番目(3rd)のメモリコピー命令のためのプリフェッチ動作も適切に実行されることになる。
 第3番目(3rd)のメモリコピー命令のマルチフロー展開実行時についても、上記大2番目(2nd)の場合と同様に、各MFメモリコピー命令毎に発行されるプリフェッチ要求信号+P_PREFETCH_REQUESTに基づいて、プリフェッチ動作が適切に実行される。
 以上のようにして、図7に示されるプリフェッチ要求回路によって、マルチフロー展開命令のアドレス指定がメモリブロック境界にない場合であっても、最大コピーサイズによって連続して実行されるメモリコピー命令の2次キャッシュのミスによるペナルティを少なくして、プリフェッチ要求の効果を高めることが可能となる。

Claims (3)

  1.  記憶領域が2つ以上に階層化されているプロセッサで、命令のデコード時に1つの命令が複数の命令フローにマルチフロー展開された各命令フローを実行するとき、前記2つ以上の記憶領域のうち適切な記憶領域間で予め利用される予定のアドレスのデータをプリフェッチできるプロセッサ装置におけるプリフェッチ要求回路であって、
     前記記憶領域にアクセスするための前記各命令フローを最大指定可能データ転送量で実行する状態が指示されたときに、該状態を前記マルチフロー展開の期間中保持するラッチ部と、
     該ラッチ部の出力信号と前記各命令フローの実行タイミングを示す信号とに基づいて、前記各命令フローが実行される毎に前記プリフェッチを要求するプリフェッチ要求信号を出力するプリフェッチ要求信号出力部と、
     を含むことを特徴とするプリフェッチ要求回路。
  2.  メインメモリと2次キャッシュと1次データキャッシュを備え、命令のデコード時に1つの命令を複数の命令フローにマルチフロー展開し該各命令フローを実行し、前記1次データキャッシュへのメモリアクセス時に前記メインメモリから前記2次キャッシュへ予め利用される予定のアドレスのデータをプリフェッチすることができるプロセッサ装置におけるプリフェッチ要求回路であって、
     メモリアドレス間のデータのコピー又は移動、演算を指示するメモリコピー命令に対応する前記各命令フローを最大指定可能データ転送量で実行する状態が指示されたときに、該状態を前記マルチフロー展開の期間中保持するラッチ回路部と、
     該ラッチ部の出力信号と前記各命令フローの実行タイミングを示す信号とのアンド論理を取って、該アンド論理出力として前記各命令フローが発行される毎にプリフェッチ要求信号を出力するアンド回路部と、
     を含むことを特徴とするプリフェッチ要求回路。
  3.  前記プリフェッチ要求回路を、前記命令フローを実行するリザべーションステーション内に備える、
     ことを特徴とする請求項1又は2の何れか1項に記載のプリフェッチ要求回路。
PCT/JP2009/001465 2009-03-30 2009-03-30 プリフェッチ要求回路 WO2010116403A1 (ja)

Priority Applications (4)

Application Number Priority Date Filing Date Title
EP09842915.2A EP2416250B1 (en) 2009-03-30 2009-03-30 Prefetch request circuit
JP2011508060A JP5229383B2 (ja) 2009-03-30 2009-03-30 プリフェッチ要求回路
PCT/JP2009/001465 WO2010116403A1 (ja) 2009-03-30 2009-03-30 プリフェッチ要求回路
US13/220,006 US8856498B2 (en) 2009-03-30 2011-08-29 Prefetch request circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2009/001465 WO2010116403A1 (ja) 2009-03-30 2009-03-30 プリフェッチ要求回路

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US13/220,006 Continuation US8856498B2 (en) 2009-03-30 2011-08-29 Prefetch request circuit

Publications (1)

Publication Number Publication Date
WO2010116403A1 true WO2010116403A1 (ja) 2010-10-14

Family

ID=42935718

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2009/001465 WO2010116403A1 (ja) 2009-03-30 2009-03-30 プリフェッチ要求回路

Country Status (4)

Country Link
US (1) US8856498B2 (ja)
EP (1) EP2416250B1 (ja)
JP (1) JP5229383B2 (ja)
WO (1) WO2010116403A1 (ja)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015036855A (ja) * 2013-08-12 2015-02-23 富士通株式会社 演算処理装置及び演算処理装置の制御方法

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11347506B1 (en) * 2021-01-15 2022-05-31 Arm Limited Memory copy size determining instruction and data transfer instruction

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58169384A (ja) 1982-03-31 1983-10-05 Hitachi Ltd デ−タ処理装置
JPS59218691A (ja) 1983-05-27 1984-12-08 Fujitsu Ltd プリフエツチ方式
JP2004038345A (ja) * 2002-06-28 2004-02-05 Fujitsu Ltd プリフェッチ制御装置、情報処理装置及びプリフェッチ制御方法
WO2007099582A1 (ja) * 2006-02-28 2007-09-07 Fujitsu Limited プリフェッチ制御装置
WO2007099598A1 (ja) * 2006-02-28 2007-09-07 Fujitsu Limited プリフェッチ機能を有するプロセッサ

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5835967A (en) * 1993-10-18 1998-11-10 Cyrix Corporation Adjusting prefetch size based on source of prefetch address
JP3812258B2 (ja) * 2000-01-13 2006-08-23 株式会社日立製作所 キャッシュ記憶装置
JP3702814B2 (ja) * 2001-07-12 2005-10-05 日本電気株式会社 マルチスレッド実行方法及び並列プロセッサシステム
JP2003208399A (ja) * 2002-01-15 2003-07-25 Hitachi Ltd データ処理装置
US6895474B2 (en) * 2002-04-29 2005-05-17 Micron Technology, Inc. Synchronous DRAM with selectable internal prefetch size
US7613883B2 (en) * 2006-03-10 2009-11-03 Rambus Inc. Memory device with mode-selectable prefetch and clock-to-core timing
KR101032050B1 (ko) 2007-06-19 2011-05-02 후지쯔 가부시끼가이샤 정보 처리 장치 및 캐시 제어 방법

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58169384A (ja) 1982-03-31 1983-10-05 Hitachi Ltd デ−タ処理装置
JPS59218691A (ja) 1983-05-27 1984-12-08 Fujitsu Ltd プリフエツチ方式
JP2004038345A (ja) * 2002-06-28 2004-02-05 Fujitsu Ltd プリフェッチ制御装置、情報処理装置及びプリフェッチ制御方法
WO2007099582A1 (ja) * 2006-02-28 2007-09-07 Fujitsu Limited プリフェッチ制御装置
WO2007099598A1 (ja) * 2006-02-28 2007-09-07 Fujitsu Limited プリフェッチ機能を有するプロセッサ

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP2416250A4 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015036855A (ja) * 2013-08-12 2015-02-23 富士通株式会社 演算処理装置及び演算処理装置の制御方法

Also Published As

Publication number Publication date
US8856498B2 (en) 2014-10-07
JPWO2010116403A1 (ja) 2012-10-11
JP5229383B2 (ja) 2013-07-03
EP2416250A4 (en) 2013-01-30
EP2416250A1 (en) 2012-02-08
EP2416250B1 (en) 2014-08-27
US20110314262A1 (en) 2011-12-22

Similar Documents

Publication Publication Date Title
JP5889986B2 (ja) 実行された命令の結果を選択的にコミットするためのシステムおよび方法
JP6143872B2 (ja) 装置、方法、およびシステム
US9619750B2 (en) Method and apparatus for store dependence prediction
JP6375379B2 (ja) キャッシュ占有決定および命令スケジューリングのための方法および装置
JP6011194B2 (ja) 演算処理装置及び演算処理装置の制御方法
JP5209933B2 (ja) データ処理装置
US20180349144A1 (en) Method and apparatus for branch prediction utilizing primary and secondary branch predictors
US6728867B1 (en) Method for comparing returned first load data at memory address regardless of conflicting with first load and any instruction executed between first load and check-point
US10579378B2 (en) Instructions for manipulating a multi-bit predicate register for predicating instruction sequences
JP6119523B2 (ja) 演算処理装置、演算処理装置の制御方法及びプログラム
JP5229383B2 (ja) プリフェッチ要求回路
US6691210B2 (en) Circuit and method for hardware-assisted software flushing of data and instruction caches
EP1220088B1 (en) Circuit and method for supporting misaligned accesses in the presence of speculative load instructions
CN112395000B (zh) 一种数据预加载方法和指令处理装置
US10853078B2 (en) Method and apparatus for supporting speculative memory optimizations
US6865665B2 (en) Processor pipeline cache miss apparatus and method for operation
JP5949327B2 (ja) 演算処理装置および演算処理装置の制御方法
US20020087832A1 (en) Instruction fetch apparatus for wide issue processors and method of operation
EP1235139B1 (en) System and method for supporting precise exceptions in a data processor having a clustered architecture
CN113568663A (zh) 代码预取指令
TW202213088A (zh) 透過微運算進行暫存器強化的系統、設備及方法
CN114489808A (zh) 高置信度多分支偏移预测器

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 09842915

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2011508060

Country of ref document: JP

Kind code of ref document: A

WWE Wipo information: entry into national phase

Ref document number: 2009842915

Country of ref document: EP

NENP Non-entry into the national phase

Ref country code: DE