Apparatus, method and system for dual spatial pattern prefetcher

The dual spatial pattern prefetcher addresses the inefficiencies in existing prefetching techniques by dynamically optimizing for coverage and accuracy with low storage costs, enhancing processor performance through adaptive memory access predictions.

JP7537696B2Active Publication Date: 2024-08-21INTEL CORP
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
JP2020103671
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2019-12-28
Filing Date
2020-06-16
Publication Date
2024-08-21
Estimated Expiration
2040-06-16

AI Technical Summary

Technical Problem

Existing processor prefetching techniques struggle to optimize for both coverage and accuracy while maintaining low storage costs, particularly in the context of evolving DRAM landscapes with increasing memory latency and bandwidth, leading to inefficiencies in processor performance.

Method used

A dual spatial pattern prefetcher that uses bitwise operations to dynamically optimize for both coverage and accuracy, employing two modulation bit patterns to predict future memory accesses, capturing local and global deltas, and adapting to memory bandwidth headroom with low storage costs.

Benefits of technology

The dual spatial pattern prefetcher enhances processor performance by improving prefetch coverage and accuracy, scaling with increasing memory bandwidth, and efficiently managing storage requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007537696000030
    Figure 0007537696000030
  • Figure 0007537696000018
    Figure 0007537696000018
  • Figure 0007537696000013
    Figure 0007537696000013
Patent Text Reader

Abstract

To provide a method of a dual spatial (bit) pattern prefetcher.SOLUTION: A prefetch circuit tracks a page and cache line accesses for a single access signature, to generate a plurality of spatial bit patterns 312 for the cache line accesses for each page. The prefetch circuit forms a plurality of single spatial bit patterns for the single access signature for each of the plurality of spatial bit patterns that has respective same spatial bit patterns. The prefetch circuit performs a logical OR operation or a logical AND operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern 320 and a second modulated bit pattern 322 for the single access signature. For a prefetch request for the single access signature, the prefetch circuit uses the first modulated bit pattern when bandwidth utilization of a memory is equal to a threshold or less, and uses the second modulated bit pattern when the bandwidth utilization of the memory exceeds the threshold to perform prefetch.SELECTED DRAWING: Figure 3
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] [CROSS REFERENCE TO RELATED APPLICATIONS] This patent application claims the benefit of U.S. Provisional Patent Application No. 62 / 903,550, filed Sep. 20, 2019, and entitled “Apparatus, Method, and System for a Dual Spatial Pattern Prefetcher,” which is incorporated herein by reference in its entirety.

[0002] The present disclosure relates generally to electronics, and more particularly, embodiments of the present disclosure relate to a dual spatial pattern prefetch circuit. [Background technology]

[0003] A processor or set of processors executes instructions from an instruction set, e.g., an instruction set architecture (ISA). An instruction set is a portion of a computer architecture that is relevant to programming and generally includes native data types, instructions, register architecture, addressing modes, memory architecture, interrupt and exception handling, and external input and output (I / O). Note that the term instructions, as used herein, may refer to macroinstructions, e.g., instructions provided to a processor for execution, or microinstructions, e.g., instructions that result from a decoder of a processor that decodes a macroinstruction. [Brief description of the drawings]

[0004] The present disclosure is illustrated by way of example and not limitation in the figures of the accompanying drawings, in which like reference numerals indicate similar elements and in which:

[0005] [Figure 1] 1 illustrates a block diagram of a multiple-core hardware processor including a prefetch circuit according to an embodiment of the present disclosure.

[0006] [Diagram 2]1 illustrates a spatial bit pattern anchored to a trigger access that captures local and global deltas according to an embodiment of the present disclosure.

[0007] [Diagram 3] 1 illustrates a modulated bit pattern according to an embodiment of the present disclosure.

[0008] [Figure 4A] 1 illustrates a flow diagram for a dual spatial pattern prefetcher according to an embodiment of the present disclosure.

[0009] [Figure 4B] 1 illustrates a dual spatial pattern prefetch circuit according to an embodiment of the present disclosure.

[0010] [Diagram 5] 1 illustrates a circuit for updating a coverage bias modulation bit pattern (CovP) and an accuracy bias modulation bit pattern (AccP) according to an embodiment of the present disclosure.

[0011] [Figure 6] 1 illustrates a flow diagram for selecting between a coverage biased modulation bit pattern (CovP) and an accuracy biased modulation bit pattern (AccP) according to an embodiment of the present disclosure.

[0012] [Figure 7] 1 illustrates a table of exemplary sizes of storage for a dual spatial pattern prefetcher according to an embodiment of the present disclosure.

[0013] [Figure 8] 1 is a flow diagram according to an embodiment of the present disclosure.

[0014] [Figure 9A] FIG. 2 is a block diagram illustrating a generic vector friendly instruction format and their class A instruction templates according to an embodiment of the present disclosure.

[0015] [Figure 9B] FIG. 1 is a block diagram illustrating a generic vector friendly instruction format and their class B instruction templates according to an embodiment of the present disclosure.

[0016] [Figure 10A] FIG. 11 is a block diagram illustrating fields for the generic vector friendly instruction format in FIGS. 9A and 9B according to an embodiment of the present disclosure.

[0017] [Figure 10B] FIG. 10B is a block diagram illustrating the fields of the particular vector friendly instruction format in FIG. 10A creating a full opcode field in accordance with one embodiment of the present disclosure.

[0018] [Figure 10C] FIG. 10B is a block diagram illustrating the fields of the particular vector friendly instruction format in FIG. 10A that create a register index field in accordance with one embodiment of the present disclosure.

[0019] [Figure 10D] FIG. 10B is a block diagram illustrating the fields of the particular vector friendly instruction format in FIG. 10A that creates an extended operation field 950 in accordance with one embodiment of the present disclosure.

[0020] [Figure 11] 1 is a block diagram of a register architecture according to one embodiment of the present disclosure.

[0021] [Figure 12A] 1A-1C are block diagrams illustrating both an example in-order pipeline and an example register renaming, out-of-order issue / execution pipeline according to an embodiment of the present disclosure.

[0022] [Figure 12B]1 is a block diagram illustrating both an example embodiment of an in-order architecture core and an example register renaming, out-of-order issue / execution architecture core included in a processor according to an embodiment of the present disclosure.

[0023] [Figure 13A] 1 is a block diagram of a single processor core shown with its connection to an on-die interconnect network and a local subset of a level 2 (L2) cache according to an embodiment of the present disclosure.

[0024] [Figure 13B] FIG. 13B is an expanded view of a portion of the processor core in FIG. 13A according to an embodiment of the present disclosure.

[0025] [Figure 14] 1 is a block diagram of a processor that may have more than one core, may have an integrated memory controller, and may have integrated graphics according to an embodiment of the present disclosure.

[0026] [Figure 15] 1 is a block diagram of a system according to an embodiment of the present disclosure.

[0027] [Figure 16] 1 shows a block diagram of a more specific exemplary system according to an embodiment of the present disclosure.

[0028] [Figure 17] 1 shows a block diagram of a second, more specific, exemplary system according to an embodiment of the present disclosure.

[0029] [Figure 18] 1 illustrates a block diagram of a system on chip (SoC) according to an embodiment of the present disclosure.

[0030] [Figure 19]1 is a block diagram contrasting the use of a software instruction converter to convert binary instructions in a source instruction set to binary instructions in a target instruction set according to an embodiment of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0031] In the following description, numerous specific details are set forth. However, it will be understood that embodiments of the present disclosure may be practiced without these specific details. In other instances, well-known circuits, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.

[0032] References herein to "one embodiment," "one embodiment," "exemplary embodiment," and the like indicate that the embodiment being described may include a particular feature, structure, or characteristic, but not all embodiments necessarily include that particular feature, structure, or characteristic. Moreover, such phrases do not necessarily refer to the same embodiment. Moreover, when a particular feature, structure, or characteristic is described in relation to one embodiment, it is believed to be within the knowledge of one of ordinary skill in the art to affect such feature, structure, or characteristic in relation to other embodiments, whether or not explicitly described.

[0033] A processor may use a prefetcher (e.g., prefetch circuitry) to prefetch data, e.g., predict access addresses and bring the data for those addresses into a cache or multiple caches (e.g., from a memory such as, but not limited to, dynamic random access memory (DRAM)).

[0034] High latency accesses, e.g., from DRAM main memory, often stall the in-order retirement of instructions in a processor (e.g., core), reducing the foresight for instruction level parallelism (ILP) extraction. Furthermore, while memory bandwidth increases with newer generations of DRAM, in certain embodiments, memory latency increases as well. The move to narrower channels (e.g., in low power double data rate (LPDDR) DRAM) also increases the overall latency from the DRAM. Embodiments herein overcome these challenges through a novel address prediction mechanism that simultaneously optimizes for both prefetch coverage and accuracy at low storage cost, scaling up the performance delivered when memory bandwidth headroom increases.

[0035] There are various solutions to the memory wall limitation in performance. These solutions include increasing the processor depth which adds tolerance to higher latencies (a complex and expensive approach, and one that is less effective if the processor width is also increased), on-die caches with low access latencies (limited by the cache capacity / area), and prefetching or predicting addresses required by loads in a program (limited by the ability to predict most of the load addresses early). High performance processors may use a combination of some or all of these solutions.

[0036] Certain embodiments herein focus on prefetching to improve processor performance. The main criteria for prefetching may generally be as follows: Coverage: The fraction of high-latency accesses by a program that are preserved by the prefetcher (e.g., higher is better); Timeliness: The fraction of high-latency accesses that are hidden by prefetching (e.g., higher is better), Accuracy: The fraction of addresses that were correctly predicted by the prefetcher (e.g., higher is better), and Storage: The storage requirements of the prefetcher (e.g., smaller is better).

[0037] In certain embodiments, the prefetcher needs to simultaneously optimize for coverage, timeliness, and accuracy while maintaining low storage costs. Certain prefetching techniques statically bias these optimizations toward either coverage or accuracy. Bit pattern prefetchers can have very high storage requirements (e.g., on the order of 100 KB).

[0038] Furthermore, as the DRAM landscape and technology evolve, prefetching techniques require the ability to dynamically adapt to bandwidth, increasing prediction and coverage when headroom exists, and throttling down to high accuracy when bandwidth utilization in a particular embodiment is near peaks. Embodiments herein enable their performance to scale with higher DRAM bandwidth headroom.

[0039] In one embodiment, each of the specified requirements (low storage costs and dynamically optimizing for both coverage and accuracy while scaling with DRAM bandwidth) are addressed head-on, effectively, and efficiently by an embodiment of the dual spatial bit pattern prefetcher disclosed herein.

[0040] In one embodiment, the dual spatial (bit) pattern prefetcher is a lightweight spatial domain prefetcher that uses bit operations such as rotate, bitwise OR, and bitwise AND to dynamically improve both coverage and accuracy at low storage cost and scales its performance with DRAM bandwidth headroom.

[0041] In certain embodiments, the dual spatial pattern prefetcher (e.g., prefetch circuitry) contributes to the following innovations: In one embodiment, a dual spatial pattern prefetcher (e.g., a prefetch circuit) employs two modulated bit patterns to simultaneously optimize for coverage, accuracy, and storage. The bit patterns are stored by rotating them relative to their triggering offsets within a page. This effectively captures all possible deltas from the triggering offset. In one embodiment, the bit patterns are stored compressed at a higher (e.g., 128B) granularity rather than a lower (e.g., 64B) granularity to reduce storage and allow two patterns to be used simultaneously. In one embodiment, the coverage bias pattern adds bits / prediction through the use of a simple bitwise OR operation, for example, with a second accuracy bias pattern that preserves the recursive bits through a simple bitwise AND operation. Furthermore, in one embodiment, the method of tracking bandwidth and measuring coverage and accuracy allows dynamic selection of the best prediction candidate at run-time.

[0042] An important distinction of a dual spatial pattern prefetcher as disclosed herein is the scaling in performance with increasing memory bandwidth, which traditional prefetchers do not appear to achieve.

[0043] The dual spatial pattern prefetcher disclosed herein, in the following embodiments, extracts more patterns from the address access stream (thus increasing prefetch coverage) and dynamically adapts to memory bandwidth headroom.

[0044] In certain embodiments, a spatial bit pattern representation anchored around a trigger access effectively captures all deltas (local and global) from the trigger, revealing patterns that would otherwise be obfuscated by reordering within the machine.

[0045] In one embodiment, prefetching is a speculative execution mechanism that predicts future addresses that will be accessed by a program. These address access patterns can be expressed in various forms (e.g., full cache line addresses, offsets in 2KB / 4KB regions, or deltas between successive offsets), and selecting address access patterns that have the best chance of revealing repeating patterns can help improve prefetch coverage and performance. Patterns in address accesses that are evident when using a global or cumulative view of accesses may not be visible when a limited low-level view of deltas between successive accesses is utilized.

[0046] FIG. 1 illustrates a block diagram 100 of a multiple core hardware processor 102 having a prefetch circuit 120 according to an embodiment of the present disclosure. Any processor may include a prefetch circuit, such as the processors discussed below. FIG. 1 illustrates an embodiment of multiple processor cores (Core A and Core B) and multiple levels of cache (L1, L2, and L3), such as in a cache coherency hierarchy. Although two cores are depicted, a single or more than two cores may be utilized. Although multiple levels of cache are depicted, a single or any number of caches may be utilized. The cache may be organized in any manner, such as a physically or logically centralized or distributed cache.

[0047] In an embodiment, a processor, such as a processor or processors including the processor core shown in the figures, or any other processor, may include one or more caches. FIG. 1 illustrates an embodiment of three levels of caches (e.g., level 1 (L1), 2 (L2), and 3 (L3)). The processor may include at least one core and at least one uncore. In one embodiment, multiple cores (cores A and B) are of a single processor 102. The cores (e.g., cores A and B) may include the components of the processor to execute instructions. The uncore may include all logic that is not in the core. A processor core (e.g., core A) may include components such as, for example, a level 1 instruction cache (L1I) 108 and a level 1 data cache (L1D) 110. A core (e.g., core A) may include components such as, for example, an address generation unit (AGU) 112, a translation lookaside buffer (TLB) 114, and a level 2 cache (L2) 116. A core may or may not share a cache with other cores. For example, core A and core B may share a level 3 cache (L3) 118 and not share an L2 116 or an L1 (208, 210). A core may include any combination of these components or none of these components. The processor 102 (e.g., core A and core B) may access (e.g., load and store data) data in the system memory 124, for example, as indicated by the arrows. In one embodiment, the system memory 124 communicates with the cores over a bus, for example, at a slower access and / or cycle time than a core that accesses a cache (e.g., a cache on the processor 102). The system memory 124 may include a multi-dimensional array 126, for example, that is loaded into the system memory 124 prior to execution of a prefetch instruction.

[0048] An address generation unit (e.g., AGU 112), e.g., an address calculation unit (ACU), may refer to an execution unit within a processor (e.g., core) that calculates addresses used to access memory (e.g., system memory 124), e.g., to enable the core to access the system memory. In one embodiment, the AGU takes an address stream (e.g., an expression) as input and outputs a (e.g., virtual) address for that stream. The AGU (e.g., circuitry) may perform arithmetic operations, such as addition, subtraction, modulo operations, or bit shifts, e.g., utilizing its adders, multipliers, shifters, rotators, etc.

[0049] A translation lookaside buffer (e.g., TLB 114) may translate virtual addresses to physical addresses (e.g., in system memory). The TLB may include a data table for storing (e.g., recently used) virtual-to-physical memory address translations, for example, so that a translation does not have to be performed for each virtual address present to obtain a physical memory address. If the virtual address entry is not in the TLB, the processor may perform a page walk to determine the virtual-to-physical memory address translation.

[0050] The prefetch circuitry 120 may be a separate functional circuit (e.g., a unit) that does not utilize a functional unit (e.g., an execution unit, an arithmetic logic unit (ALU), an AGU, a TLB, etc.) of a core. The prefetch circuitry may be utilized by a prefetch instruction. The prefetch circuitry may include circuitry (e.g., hardware logic circuitry) to perform the prefetching discussed herein. The prefetch circuitry may be part of a processor (e.g., separate from the core). The prefetch circuitry may communicate with the core of the processor via a communication resource such as, for example, but not limited to, a ring network. The processor 102 may communicate with the system memory 124 and / or cache (e.g., L1, L2, or L3 in FIG. 1) via a memory controller (e.g., as part of the processor) and / or an interconnect. The prefetch circuit 120 may output a system memory address of a multidimensional block of elements to be loaded (e.g., copied) to a cache (e.g., L1, L2, or L3 in FIG. 1) from a multidimensional array 126 in system memory 124. The prefetch circuit 120 may output the system memory address to a memory controller of the processor 102 (e.g., memory unit 1270 in FIG. 12B).

[0051] FIG. 2 illustrates a spatial bit pattern 206 anchored to a trigger access (shown as circled) that captures local and global deltas according to an embodiment of the present disclosure. FIG. 2 illustrates an example of multiple set accesses (e.g., each with a unique access signature) in a spatial region and their representation in various formats. The first access to a region is referred to as a "trigger" access and is marked with a black circle. For example, the first entry "02" in access stream A of stream 202 indicates an access of cache line 2 in page A, the second entry "06" in access stream A indicates an access of cache line 6 in page A, etc. In FIG. 2, the access sets for pages B through E have the same trigger offset in their spatial region and touch all the same offsets in different time orders. Such variations may be artifacts of reordering due to arbitration and scheduling in the cache / memory subsystem. The longer the access sequence, the higher the probability of variation in a particular embodiment. In a particular embodiment, when continuous deltas 204 are used, but can be represented by a single spatial bit pattern, all these accesses have different representations. For example, access set B and access set C with trigger offset 1 have two delta representations (+4, -1, +7, +1, and +4, +6, -7, +8, respectively), but a single bit pattern representation BP2 (0100 1100 0001 1000). Importantly, if the bit patterns are rotated (e.g., to the left) and anchored to the "trigger" offset, all the example sets merge into a single representation 208 (1001 1000 0011 0000). Such an anchored bit pattern captures all deltas for the trigger accesses, including the local (continuous) and global (accumulated) ones in FIG. 2.

[0052] In certain embodiments, both coverage and accuracy can be optimized simultaneously by using bitwise OR and AND operations to modulate two spatial bit patterns, one biased towards coverage and the other biased towards accuracy.

[0053] Multiple access streams in a program may have anchored bit patterns that are similar (e.g., have some crossover in bit sets) but not exactly the same. A dual spatial pattern prefetcher (e.g., prefetch circuit) as disclosed herein uses a novel and intuitive approach of using two modulated bit patterns, e.g., one biased toward coverage and the other biased toward accuracy. Coverage is increased by adding bits to the predicted pattern. This can be achieved using a bitwise OR operation of the two bit patterns. For example, only the retained bits occurring in the pattern track the accuracy, which is achieved via a bitwise AND operation on the two patterns.

[0054] FIG. 3 illustrates a modulated bit pattern 302 according to an embodiment of the present disclosure. FIG. 3 illustrates an example of how different address streams mapped to three rotated bit patterns 314, 316, 318 can be modulated into a coverage bias pattern 320 (e.g., bit vector) and a correctness bias pattern 322 (e.g., bit vector). For example, by a first delta sequence set 306 for a first set of accesses, by a second delta sequence set 308 for a second set of accesses, and by a third delta sequence set 310 for a third set of accesses. A set of accesses may be grouped based on the program counter (PC) (e.g., instruction pointer) that caused each access, e.g., the PC for the instruction that caused each access. In one embodiment, each set of accesses has the same proper subset of the PC's bits (e.g., the least significant or most significant bits), e.g., the same 8 bits.

[0055] In FIG. 3, for a first set of accesses, a first rotated and anchored spatial bit pattern 314 is formed from a first delta sequence set 306, for a second set of accesses, a second rotated and anchored spatial bit pattern 316 is formed from a second delta sequence set 308, and for a third set of accesses, a third rotated and anchored spatial bit pattern 318 is formed from a third delta sequence set 310, e.g., as discussed with reference to FIG. 2.

[0056] In Figure 3, a modulation bit pattern 320 for coverage (CovP) is generated by performing a (bitwise) OR operation 324 on a first rotated and anchored spatial bit pattern 314, a second rotated and anchored spatial bit pattern 316, and a third rotated and anchored spatial bit pattern 318. In Figure 3, a modulation bit pattern 322 for accuracy (AccP) is generated by performing a (bitwise) AND operation 324 on the first rotated and anchored spatial bit pattern 314, the second rotated and anchored spatial bit pattern 316, and the third rotated and anchored spatial bit pattern 318.

[0057] In certain embodiments, dynamic modulation of these bit patterns allows for simultaneous optimization for both coverage and accuracy, even though these criteria are irregular with respect to one another. The available memory bandwidth headroom, coupled with quantitative measures of accuracy and coverage, can be used to dynamically select between two different bit pattern candidates (e.g., coverage-biased or accuracy-biased) at run-time.

[0058] In a particular embodiment, {+1} and {-1} are the two most frequently occurring offset deltas in a program. For example, in a particular program, those two deltas appear, on average, more than 50% of the time. Thus, instead of storing a bit pattern where each bit represents a cache line granularity (e.g., 64B), a dual spatial pattern prefetcher (e.g., prefetch circuit) as disclosed herein may store a compressed bit pattern where each bit represents two adjacent (e.g., 64B) cache lines (e.g., 128B granularity). This directly halves the pattern storage requirements. This could theoretically have up to 50% inaccuracy in prediction, but a dual spatial pattern prefetcher (e.g., prefetch circuit) as disclosed herein may have less than 1 misprediction in every 5 cache line predictions (e.g., less than 20% inaccuracy).

[0059] In certain embodiments, multiple prefetch triggers in a physical page increase prefetch coverage. Certain embodiments of the dual spatial pattern prefetcher (e.g., prefetch circuit) incorporate measures to track accuracy and throttle predictions, and thus can dynamically perform predictions at both full physical page (e.g., 4KB) and half physical page (e.g., 2KB) granularity. Instead of using larger (e.g., 64b) bit patterns for the coverage bias (CovP) and accuracy bias (AccP) patterns, certain embodiments herein split each of them into two smaller (e.g., 32b) patterns.

[0060] In one embodiment, Measure CovP and Measure AccP Two (e.g., small 2-bit) counters, named as , track the coverage and accuracy of each (e.g., 32b) bit pattern, e.g., with both of these counters for each bit pattern. A predictive selection may be made for each 2KB (e.g., 32b) segment of a 4KB page.

[0061] A dual spatial pattern prefetcher (e.g., a prefetch circuit) as disclosed herein may include the following structure: A multiple (e.g., 64) entry first-in-first-out (FIFO) structure called a page buffer (PB) tracks the most recently accessed (e.g., 4KB) pages in a cache (e.g., an L2 cache). In one embodiment, each PB entry is indexed by a (e.g., 4KB) physical page and stores a (e.g., 64b) bit pattern (uncompressed and raw access pattern) that accumulates cache (e.g., L2) accesses seen by program loads and stores. To generate the signature and anchor access bit patterns, a (e.g., 8b) hashed program counter (PC) (e.g., instruction pointer) and two (e.g., 6b) triggering offsets, one for each (e.g., 2KB) segment of the physical page, may be stored, and a multiple (e.g., 256) entry signature pattern table (SPT) stores the correlation between the signature and follower bit patterns. In a particular embodiment, the SPT is a direct-mapped structure indexed by the signature. In one embodiment, each SPT entry stores the following elements: CovP (e.g., 32b): Coverage-biased Compressed Bit Pattern, AccP (e.g., 32b): Accuracy-biased Compressed Bit Pattern, 2×Measure CovP (e.g., 2×2b): Saturating counters that each track coverage feedback for a 2KB region within a physical page; 2×Measure AccP (e.g., 2×2b): A saturating counter that tracks correctness feedback for each 2KB region in a physical page. 2 × OR count(e.g., 2×2b): a saturating counter to keep track of the number of OR operations of the two segments of the CovP; and Prefetch Buffer (eg, 16 entries) - holds two (eg, 64b) bit vectors for prefetches to be generated and issued.

[0062] FIG. 4A illustrates a flow diagram 401 for a dual spatial pattern prefetcher according to an embodiment of the disclosure. FIG. 4B illustrates a dual spatial pattern prefetch circuit 400 according to an embodiment of the disclosure. In a particular embodiment, the prefetch circuit 400 as in FIG. 4B is included in the prefetch data, for example, to predict access addresses and bring data for those addresses to a cache or caches (e.g., from a memory). In one embodiment, the prefetch circuit 400 in FIG. 4B is an instance of the prefetch circuit 120 in FIG. 1. In one embodiment, the prefetch circuit 400 in FIG. 4B is an instance of the prefetch circuit 1278 in FIG. 12B.

[0063] In the following example, every desired access 403 (e.g., L2 cache desired access for a miss in the L1 cache) (e.g., program access 404) looks up 405 the page buffer 402 (PB) by physical page number (phase 1). If a corresponding entry is found, a dual spatial pattern prefetcher (e.g., prefetch circuit) sets 409 the appropriate bit position in the access bit pattern in the PB entry. A check is made at 411 to see if the first access to each (e.g., 2 KB) segment in a (e.g., 4 KB) page is eligible to trigger a prefetch (phase 2). If it is not a triggering access, the flow proceeds to Done 421. If it is a triggering access, the access signature (e.g., program counter) (PC) of this triggering access is stored in the PB entry, and CovP and AccP predictions and their measures of goodness (Measures of Goodness) are generated. CovP and MeasureAccP The trigger access signature (e.g., PC) is used to index into the SPT 406, which returns the trigger access signature (e.g., PC) at 413 (phase 3). A selection flow (e.g., detailed in FIG. 5) uses the system bandwidth 410 and the scale to select (e.g., via multiplexer 408) a predicted pattern 412 for prefetching (phase 4). In a particular embodiment, this predicted pattern 412 is rotated by a rotation circuit 414 to align it with the trigger access offset before issuing the prefetch, to generate a rotated predicted pattern 416. At eviction from the PB (phase 5), as checked at 417, for each trigger (e.g., every 2 KB segment), the stored bit pattern is rotated to anchor to the trigger offset, hashed into the SPT using the stored trigger access signature (e.g., PC), and the pattern and counter are updated at 419. If there is no PB hit at 407, a new PB entry is inserted into the page buffer 402 at 415.

[0064] In one embodiment, each entry (e.g., a row in a table-row matrix) includes: (i) a physical page ID number (e.g., used to identify the page when looking up the page buffer); (ii) a spatial bit pattern for the page (e.g., a bit vector representing spatial access stream information, e.g., which indicates accessed cache lines as 1 and otherwise 0) (e.g., this is the pattern that will be rotated and used to update the CovP and AccP patterns of the SPT); (iii) a program counter (PC) of the triggering (e.g., first) access to the segment (e.g., used to index into the SPT); and / or (iv) a cache line offset of the triggering (e.g., first) access to the segment. Table 1 shows an example of two entries in a page buffer with example values ​​and the triggering access shown underlined.

[0065] Table 1: Example page buffer formats. [Table 1]

[0066] Table 2 shows an example of a single entry in a signature prediction table (SPT). [Table 2]

[0067] An example of an operation with reference to Tables 1 and 2 is to detect a new access to page 0x65, which is from an instruction with a PC of 0x7FFECCA, which is to the fourth (e.g., indexed from 0 to N, where N is a positive integer greater than 1) cache line in the page, which is the triggering access (e.g., the first access to this segment of the page) (e.g., as detected from accessing Table 1). Then, a lookup is performed in the SPT (e.g., in Table 2) using the (e.g., lower proper subset) bits of PC 0x7FF3CCA (e.g., lookup entry 0xCA in the SPT when using the lowest 8 bits), and the SPT lookup results in both CovP and AccP patterns. For example, retrieve one of them to use based on system bandwidth. In a particular embodiment, the retrieved CovP or AccP pattern is now rotated right by the cache line offset of the triggering access (e.g., 4 in the example from Table 1 as shown by underline 1). In the particular embodiment of FIG. 4B, the prefetch circuit 400 outputs a rotated predicted pattern 416 .

[0068] In a particular embodiment, the positions of those in this rotated prediction pattern are prefetches issued for the cache line (e.g., a cache line corresponding to zero has no prefetches issued for it).The SPT may then be updated. [SPT Update Phase]

[0069] In a particular embodiment, each SPT update has three bit patterns of information: (1) The actual program access (e.g., spatial access) bit pattern (e.g., coming from a victim PB entry), (2) the CovP stored in the SPT entry, and (3) The AccP stored within that SPT entry.

[0070] A particular embodiment of a dual spatial pattern prefetcher (e.g., a prefetch circuit) measures the coverage and accuracy metrics of CovP and AccP separately by two ratios of PopCount (which counts the number of bits set in a bit pattern), as shown in Table 3 below.

[0071] Table 3: Example measurements of program coverage and prediction accuracy through simple bit operations. [Table 3] [Table 4]

[0072] 5 illustrates a circuit for updating a coverage bias modulation bit pattern (CovP) 502 and an accuracy bias modulation bit pattern (AccP) 504 according to an embodiment of the present disclosure. A particular embodiment of a dual spatial pattern prefetcher (e.g., a prefetch circuit) modulates the stored CovP and AccP bit patterns based on a calculated ratio as follows: CovP Modulation: CovP adds bits to a stored CovP pattern (CovP pattern 510 in FIG. 5) with the actual program (PROGRAM pattern 514 in FIG. 5) access pattern by bitwise ORing 506. However, because an unchecked number of OR operations can result in all bits being set in the pattern, certain embodiments limit it to a certain number (e.g., 3) of OR operations (e.g., a saturating counter of 2b). Count (tracked by Count is incremented each time the OR operation adds any bit to the predicted pattern. To quantify the goodness of CovP, in a particular embodiment of a dual spatial pattern prefetcher (e.g., a prefetch circuit), the CovP prediction accuracy is measured against a threshold Acc Thr or the program coverage from CovP is less than the threshold Cov Thr A saturating counter that is incremented whenever Measure is less than CovP This will allow Measure CovP is saturated and the CovP may be reset to the incoming program pattern if either the current bandwidth utilization is above a first threshold (e.g., 75%) (e.g., the highest quartile) or the coverage remains below a lower threshold (e.g., 50%) (e.g., despite up to three OR operations). Certain embodiments may use the Acc Thr and Cov Thr Therefore, certain embodiments update the two modulation spatial bit patterns to simultaneously optimize coverage and accuracy. AccP Modulation: In an embodiment, the accuracy bias bit pattern requires keeping the recursive bits in the bit pattern, which can be achieved by a bitwise AND operation 508. In a particular embodiment, rather than a recursive AND operation on the AccP, on each update, the AccP is replaced by a bitwise AND operation of the incoming program access bit pattern (Program pattern 514 in FIG. 5) and the CovP (Coverage Bias Pattern) (CovP pattern 510 in FIG. 5). This effectively keeps only bits with consecutive recursion counts in the bit pattern. Measure CovP Similarly, in certain embodiments herein, a saturating counter (e.g., Measure 2b) is used to track the goodness of AccP. AccP Use Measure AccP Measure is incremented if the AndP prediction accuracy is less than a threshold (e.g., 50%) and decremented otherwise. AccP is used in one embodiment to throttle down predictions completely when bandwidth utilization is high and inaccuracy is high.

[0073] 6 illustrates a flow diagram for selecting between a coverage biased modulation bit pattern (CovP) and an accuracy biased modulation bit pattern (AccP) according to an embodiment of the present disclosure. FIG. 6 illustrates an example flow used between CovP and AccP for prediction. In a particular embodiment of a dual spatial pattern prefetcher (e.g., prefetch circuit), when the bandwidth utilization is in the highest quartile (75%) at 602, Measure AccP If Measure is not saturated, select AccP at 604. If the bandwidth utilization is in the second highest quartile (between 50% and 75%) at 606, then in a particular embodiment of the dual spatial pattern prefetcher (e.g., prefetch circuit), select Measure CovPIf CovP is saturated (meaning, for example, that CovP is too inaccurate for our desired use), then select AccP at 608; otherwise select CovP. If bandwidth utilization is less than 50%, then a particular embodiment of the dual spatial pattern prefetcher (e.g., prefetch circuit) simply uses CovP. These numbers are exemplary and other thresholds may be used. To minimize the impact of any contamination in this mode, Measure CovP If CovP is saturated (meaning that CovP is inaccurate), certain embodiments of the dual spatial pattern prefetcher (e.g., prefetch circuitry) may prematurely fill these prefetches (e.g., with zero age) in the on-die (e.g., L2 and / or L3) caches.

[0074] 7 illustrates an example size table 700 of storage for a dual spatial pattern prefetcher according to an embodiment of the present disclosure. The table 700 includes entries for an example page buffer 702 (PB) and an example signature prediction table 704 (SPT).

[0075] 8 is a flow diagram 800 according to an embodiment of the disclosure. The depicted flow 800 includes accessing a cache storing a cache line by a processor 802, tracking cache line accesses and pages to the cache for a single access signature 804, for cache line accesses for each page of a plurality of pages, generating a spatial bit pattern that is shifted to the first cache line access for each page 806, for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns, generating a single spatial bit pattern for the single access signature 808, and determining the single access signature 809. The method includes performing 810 a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature, performing 812 a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature, receiving 814 a prefetch request for the single access signature, and performing 816 a prefetch operation to prefetch a cache line from the memory into the cache for the prefetch request using the first modulated bit pattern if the threshold is not exceeded and using the second modulated bit pattern if the threshold is exceeded.

[0076] Thus, embodiments of the dual spatial pattern prefetcher (e.g., prefetch circuit) disclosed herein have the ability to scale performance with increasing memory bandwidth by boosting coverage and throttling down to high accuracy when utilized bandwidth is near peak to achieve significant gains in processor performance over alternative prefetchers, for example, by scaling performance to take full advantage of ever-increasing memory bandwidth (e.g., other prefetchers are not capable of doing so), modulating two bit patterns through bitwise operations AND and OR to simultaneously optimize coverage and accuracy, and providing a dual spatial pattern prefetcher (e.g., prefetch circuit) that uses a novel, yet efficiently implemented, method of tracking bandwidth and measuring coverage and accuracy of predicted patterns to enable dynamic selection of the best prediction candidate at run-time.

[0077] Exemplary architectures, systems, etc. used above are detailed below.

[0078] At least some embodiments of the disclosed technology can be explained in light of the following examples.

[0079] (Example 1) a processor core that accesses a memory and a cache that stores cache lines; a prefetch circuit for prefetching cache lines from the memory into the cache, Tracking cache line accesses and pages to said cache for single access signatures; generating, for said cache line accesses for each page of the plurality of pages, a spatial bit pattern that is shifted into a first cache line access for each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single access signature; a prefetch circuit for performing a prefetch operation on the prefetch request using the first modulated bit pattern if a threshold has not been exceeded and using the second modulated bit pattern if a threshold has been exceeded; An apparatus comprising: (Example 2) The single access signature is a single instruction pointer value. The apparatus described in Example 1. (Example 3) The prefetch request has a miss for data in the cache (e.g., the cache having the miss is a first level cache); The apparatus described in Example 1. (Example 4) the threshold is a bandwidth utilization threshold for the memory; The apparatus described in Example 1. (Example 5) the prefetch circuit further updates the first modulated bit pattern with a result of a logical OR operation between the first modulated bit pattern and an actual program access bit pattern for the single access signature. The apparatus described in Example 1. (Example 6) The actual program access bit pattern is for a victim page buffer entry. The apparatus described in Example 5. (Example 7) the pre-fetch circuit further updates the second modulated bit pattern with a result of ANDing the first modulated bit pattern with the actual program access bit pattern for the single access signature. The apparatus described in Example 5. (Example 8) the pre-fetch circuit further updates the second modulated bit pattern with a result of ANDing the first modulated bit pattern with an actual program access bit pattern for the single access signature. The apparatus described in Example 1. (Example 9) accessing, by a processor, a cache storing the cache line; tracking cache line accesses and pages to said cache for a single access signature; generating, for each of the cache line accesses for a plurality of pages, a spatial bit pattern that is shifted into a first cache line access for each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; performing a prefetch operation on the prefetch request using the first modulated bit pattern if the threshold has not been exceeded and using the second modulated bit pattern if the threshold has been exceeded to prefetch a cache line from memory into the cache; A method comprising: (Example 10) The single access signature is a single instruction pointer value. The method described in Example 9. (Example 11) the prefetch request includes a miss of data in the cache. The method described in Example 9. (Example 12) setting the threshold as a bandwidth utilization threshold for the memory. The method described in Example 9. (Example 13) updating the first modulation bit pattern with a result of a logical OR operation between the first modulation bit pattern and an actual program access bit pattern for the single access signature. The method described in Example 9. (Example 14) The actual program access bit pattern is for a victim page buffer entry. The method of Example 13. (Example 15) updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with the actual program access bit pattern for the single access signature. The method of Example 13. (Example 16) updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with an actual program access bit pattern for the single access signature; The method described in Example 9. (Example 17) When executed by a machine, the machine: accessing, by a processor, a cache storing the cache line; tracking cache line accesses and pages to said cache for a single access signature; generating, for said cache line accesses for each page of a plurality of pages, a spatial bit pattern that is shifted into a first cache line access of each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; performing a prefetch operation on the prefetch request using the first modulated bit pattern if the threshold has not been exceeded and using the second modulated bit pattern if the threshold has been exceeded to prefetch a cache line from memory into the cache; storing program code for executing a method having the steps of: Non-transitory machine-readable medium. (Example 18) The single access signature is a single instruction pointer value. The non-transitory machine-readable medium of Example 17. (Example 19) the prefetch request includes a miss of data in the cache. The non-transitory machine-readable medium of Example 17. (Example 20) The method further comprises setting the threshold as a bandwidth utilization threshold for the memory. The non-transitory machine-readable medium of Example 17. (Example 21) The method further comprises updating the first modulation bit pattern with a result of ORing the first modulation bit pattern with an actual program access bit pattern for the single access signature. The non-transitory machine-readable medium of Example 17. (Example 22) The actual program access bit pattern is for a victim page buffer entry. The non-transitory machine-readable medium of Example 21. (Example 23) The method further comprises updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with the actual program access bit pattern for the single access signature. The non-transitory machine-readable medium of Example 21. (Example 24) The method further comprises updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with an actual program access bit pattern for the single access signature. The non-transitory machine-readable medium of Example 17.

[0080] In yet another embodiment, an apparatus comprises a data storage device storing code that, when executed by a hardware processor, causes the hardware processor to perform any method disclosed herein. The apparatus may be similar to that described in the detailed description. The method may be similar to that described in the detailed description.

[0081] An instruction set may include one or more instruction formats. A given instruction format may define, among other things, various fields (e.g., number of bits, bit positions) that specify the operation to be performed (e.g., opcode) and the operands on which the operation is to be performed, and / or other data fields (e.g., masks). Some instruction formats are further subdivided through the definition of instruction templates (or sub-formats). For example, instruction templates of a given instruction format may be defined to have different subsets of the instruction format's fields (where the included fields are typically in the same order, but fewer fields are included so that at least some have different bit positions) and / or where given fields are interpreted differently. Thus, each instruction of the ISA is expressed using a given instruction format (and in a given one of the instruction templates of that instruction format, if defined) and includes fields for specifying the operation and the operands. For example, an exemplary ADD instruction has a particular opcode and an instruction format that includes an opcode field for specifying the opcode and an operand field for selecting the operands (source1 / destination and source2). Occurrences of this ADD instruction in the instruction stream will have particular contents in the operand field that select a particular operand. A set of SIMD extensions have been released and / or published that are referred to as the Advanced Vector Extensions (AVX) (AVX1 and AVX2) and use the Vector Extensions (VEX) coding scheme (see, e.g., the November 2018 Intel 64 and IA-32 Architectures Software Developer's Manual and the October 2018 Intel Architecture Instruction Set Extensions Programming Reference). [Example instruction format]

[0082] Embodiments of the instructions described herein may be embodied in different formats, and exemplary systems, architectures, and pipelines are detailed below. Embodiments of the instructions may be executed on such systems, architectures, and pipelines, but are not limited to those detailed. [Generic Vector Friendly Instruction Format]

[0083] A vector friendly instruction format is an instruction format that is suitable for vector instructions (e.g., there are certain fields that are specific to vector operations). Although embodiments are described in which both vector and scalar operations are supported by the vector friendly instruction format, alternative embodiments use only vector operations with the vector friendly instruction format.

[0084] 9A-9B are block diagrams illustrating generic vector friendly instruction formats and their instruction templates according to embodiments of the present disclosure. FIG. 9A is a block diagram illustrating a generic vector friendly instruction format and its class A instruction templates according to embodiments of the present disclosure, and FIG. 9B is a block diagram illustrating a generic vector friendly instruction format and its class B instruction templates according to embodiments of the present disclosure. Specifically, a generic vector friendly instruction format 900 is defined for class A and class B instruction templates, both of which do not include the no memory access 905 instruction template and the memory access 920 instruction template. The term generic in the context of vector friendly instruction formats refers to an instruction format that is not tied to any particular instruction set.

[0085] In an embodiment of the present disclosure, the vector friendly instruction format supports vector operand lengths (or sizes) of 64 bytes having 32-bit (4 bytes) or 64-bit (8 bytes) data element widths (or sizes) (so a 64-byte vector is composed of either 16 doubleword sized elements or alternatively 8 quadword sized elements), vector operand lengths (or sizes) of 64 bytes having 16-bit (2 bytes) or 8-bit (1 byte) data element widths (or sizes), 32-bit (4 bytes), 64-bit (8 bytes), 16-bit (2 bytes) or 8-bit (1 byte) data element widths (or sizes), While described as supporting vector operand lengths (or sizes) of 32 bytes having data element widths (or sizes), and vector operand lengths (or sizes) of 16 bytes having 32-bit (4-byte), 64-bit (8-byte), 16-bit (2-byte) or 8-bit (1-byte) data element widths (or sizes), alternative embodiments may support more, fewer and / or different vector operand sizes (e.g., 256-byte vector operands) having more, fewer or different data element widths (e.g., 128-bit (16-byte) data element widths).

[0086] The class A instruction templates of Figure 9A include: 1) within the no memory access 905 instruction template, a no memory access, full round control type operation 910 instruction template and a no memory access, data transform type operation 915 instruction template are shown, and 2) within the memory access 920 instruction template, a memory access, temporal 925 instruction template and a memory access, non-temporal 930 instruction template are shown. The class B instruction templates of Figure 9B include: 1) within the no memory access 905 instruction template, a no memory access, write mask control, partial round control type operation 912 instruction template and a no memory access, write mask control, vsize type operation 917 instruction template are shown, and 2) within the memory access 920 instruction template, a memory access, write mask control 927 instruction template is shown.

[0087] The generic vector friendly instruction format 900 includes the following fields, listed below in the order shown in Figures 9A-9B:

[0088] Format field 940 - a particular value in this field (the value of the instruction format identifier) ​​uniquely identifies the vector friendly instruction format and thus the occurrence of an instruction in the vector friendly instruction format in an instruction stream. As such, this field is optional in the sense that it is not required for an instruction set that has only a generic vector friendly instruction format.

[0089] Base Operation field 942 - its contents distinguish between different base operations.

[0090] Register index field 944 - its contents specify the location of the source and destination operands, whether in registers or in memory, either directly or through address generation. These contain a sufficient number of bits to select N registers from a PxQ (e.g., 32x512, 16x128, 32x1024, 64x1024) register file. In one embodiment, N may be up to three source registers and one destination register, while alternative embodiments may support more or fewer source and destination registers (e.g., up to two sources may be supported, where one of the sources also acts as a destination; up to three sources may be supported, where one of the sources also acts as a destination; up to two sources and one destination may be supported).

[0091] A Qualifier field 946 - its contents distinguish occurrences of generic vector instruction format instructions that specify a memory access from those that do not, i.e., distinguish between the No Memory Access 905 instruction template and the Memory Access 920 instruction template. Memory access operations read and / or write to the memory hierarchy (possibly specifying source and / or destination addresses using values ​​in registers), while no memory access operations do not (e.g., the source and destination are registers). In one embodiment, this field also selects between three different ways to perform memory address calculations, while alternative embodiments may support more, less, or different ways to perform memory address calculations.

[0092] Extended operation field 950 - its contents distinguish which of a variety of different operations should be performed in addition to the base operation. This field is context specific. In one embodiment of the present disclosure, this field is split into a class field 968, an alpha field 952, and a beta field 954. The extended operation field 950 allows a common group of operations to be performed with a single instruction rather than two, three, or four instructions.

[0093] Scale field 960 - its contents are the scale factor for memory address generation (e.g., 2 scale x index + base) to allow scaling of the contents of the index field.

[0094] Displacement field 962A - its contents are used as part of memory address generation (e.g., 2 scale × index + base + displacement) is used for address generation.

[0095] Displacement factor field 962B (note that displacement field 962A is juxtaposed directly above displacement factor field 962B, indicating that one or the other may be used) - its contents specify a displacement factor that is used as part of the address generation and that should be scaled by the size (N) of the memory access - where N is the number of bytes in that memory access (e.g., 2 scale× index + base + scaled displacement). Redundant low-order bits are ignored, and therefore the contents of the displacement factor field are multiplied by the total size of the memory operands (N) to generate the final displacement used in calculating the effective address. The value of N is determined by the processor hardware at run-time based on the full opcode field 974 and the data manipulation field 954C (described later in this specification). The displacement field 962A and the displacement factor field 962B are optional in the sense that they are not used in the no memory access 905 instruction template and / or different embodiments may implement only one or neither of the two.

[0096] Data element width field 964 - its contents distinguish which of multiple data element widths should be used (in some embodiments for all instructions, in other embodiments for only some instructions). This field is optional in the sense that it is not needed if only one data element width is supported and / or if data element widths are supported using some aspect of the opcode.

[0097] Write mask field 970 - its contents control whether or not a data element position in the destination vector operand reflects the results of the base and extension operations, based on the data element position. Class A instruction templates support merging-write masking, while class B instruction templates support both merging-write masking and zeroing-write masking. When merging, the vector mask allows any set of elements in the destination (specified by the base and extension operations) to be protected from being updated during the execution of any operation. In another embodiment, the old value of each element in the destination is preserved if the corresponding mask bit has a zero value. In contrast, when zeroing, the vector mask allows any set of elements in the destination (specified by the base and extension operations) to be zeroed during the execution of any operation. In one embodiment, the element in the destination is set to zero if the corresponding mask bit has a zero value. A subset of this functionality is the ability to control the vector length of the operation being executed (i.e., the range of elements being modified from start to finish). However, the modified elements do not need to be contiguous. Thus, the write mask field 970 allows for partial vector operations including loads, stores, arithmetic, logical, etc. While embodiments of the present disclosure are described in which the contents of the write mask field 970 select one of a number of write mask registers containing the write mask to be used (and thus the contents of the write mask field 970 indirectly identify that masking to be performed), alternative embodiments allow the contents of the mask write field 970 to instead or additionally directly specify the masking to be performed.

[0098] Immediate field 972 - its contents allow for the specification of an immediate value. This field is optional in the sense that it is not present in implementations of the generic vector friendly format that do not support immediate values ​​and that it is not present in instructions that do not use immediate values.

[0099] Class field 968 - its contents distinguish between different classes of instructions. With reference to Figures 9A-9B, the contents of this field select between class A and class B instructions. In Figures 9A-9B, a rounded rectangle is used to indicate that a particular value is present in a field (e.g., class A 968A and class B 968B, respectively, of class field 968 in Figures 9A-9B). [Class A instruction template]

[0100] For class A no memory access 905 instruction templates, the alpha field 952 is interpreted as an RS field 952A whose content distinguishes which of the different extended operation types is to be performed (e.g., round 952A.1 and data transform 952A.2 are specified for the no memory access, round type operation 910 and no memory access, data transform type operation 915 instruction templates, respectively), while the beta field 954 distinguishes which of the specified types of operations is to be performed. The scale field 960, displacement field 962A, and displacement scale field 962B are not present in the no memory access 905 instruction template. [No memory access instruction template - full round control type operation]

[0101] In the no memory access, full round control type operation 910 instruction template, the beta field 954 is interpreted as a round control field 954A, whose contents provide static rounding. In the described embodiment of the disclosure, the round control field 954A includes a suppress all floating-point exceptions (SAE) field 956 and a round operation control field 958, although alternative embodiments may support encoding both of these concepts in the same field or may only have one or the other of these concepts / fields (e.g., may only have the round operation control field 958).

[0102] SAE field 956 - its contents distinguish whether exceptional event reporting should be disabled or not. If the contents of SAE field 956 indicate that suppression is enabled, then the given instruction will not report any floating-point exception flags of any kind and will not raise any floating-point exception handlers.

[0103] A round operation control field 958 - its contents distinguish which of a group of rounding operations (e.g., round up, round down, round towards zero, and round towards nearest) is performed. The round operation control field 958 thus allows the rounding mode to be changed on an instruction by instruction basis. In one embodiment of the present disclosure where the processor includes a control register for specifying the rounding mode, the contents of the round operation control field 950 override that register value. [No memory access instruction template - data transformation type operation]

[0104] In the no memory access, data transform type operation 915 instruction template, the beta field 954 is interpreted as a data transform field 954B, whose contents distinguish which of a number of data transforms should be performed (e.g., no data transform, swizzle, broadcast).

[0105] For memory access 920 instruction templates of class A, the alpha field 952 is interpreted as an eviction hint field 952B, whose content distinguishes which of the eviction hints should be used (in FIG. 9A, temporal 952B.1 and non-temporal 952B.2 are specified for the memory access, temporal 925 instruction template and the memory access, non-temporal 930 instruction template, respectively), while the beta field 954 is interpreted as a data manipulation field 954C, whose content distinguishes which of a number of data manipulation operations (also known as primitives) should be performed (e.g., no operation, broadcast, upconversion of source, and downconversion of destination). The memory access 920 instruction templates include a scale field 960, and optionally a displacement field 962A or a displacement scale field 962B.

[0106] The vector memory instructions perform vector loads from memory and vector stores to memory, with conversion support. As with regular vector instructions, the vector memory instructions transfer data to / from memory element by data element, with the actual elements transferred being determined by the contents of the vector mask, which is selected as the writemask. [Memory access instruction template - temporary]

[0107] Transient data is data that is likely to be reused soon enough to benefit from caching. However, this is a hint, and different processors may implement it differently, including ignoring the hint entirely. [Memory access instruction template - non-temporal]

[0108] Non-temporal data is data that is unlikely to be reused soon enough to benefit from caching in the first level cache, and eviction should be prioritized. However, this is a hint, and different processors may implement it differently, including ignoring the hint entirely. [Class B instruction template]

[0109] In the case of class B instruction templates, the alpha field 952 is interpreted as a write mask control (Z) field 952C, whose content distinguishes whether the write masking controlled by the write mask field 970 should be merging or zeroing.

[0110] For class B no memory access 905 instruction templates, a portion of the beta field 954 is interpreted as an RL field 957A, whose contents distinguish which of the different extended operation types are to be performed (e.g., round 957A.1 and vector length (VSIZE) 957A.2 are specified for the no memory access, write mask control, partial round control type operation 912 instruction template and the no memory access, write mask control, VSIZE type operation 917 instruction template, respectively), while the remainder of the beta field 954 distinguishes which of the specified types of operations are to be performed. The scale field 960, displacement field 962A, and displacement scale field 962B are not present in the no memory access 905 instruction template.

[0111] For the no memory access, write mask control, partial round control type operation 910 instruction template, the remainder of the beta field 954 is interpreted as the round operation field 959A and exception event reporting is disabled (the given instruction will not report any floating-point exception flags of any kind or raise any floating-point exception handlers).

[0112] Round operation control field 959A - just like round operation control field 958, its content distinguishes which of a group of rounding operations (e.g., round up, round down, round towards zero, and round towards nearest) is performed. Thus, the round operation control field 959A allows changing of the rounding mode on an instruction basis. In one embodiment of the present disclosure in which the processor includes a control register for specifying the rounding mode, the content of the round operation control field 950 overrides that register value.

[0113] In the no memory access, write mask control, VSIZE type operation 917 instruction template, the remainder of the beta field 954 is interpreted as a vector length field 959B, whose contents distinguish which of a number of data vector lengths should be executed (e.g., 128, 256, or 512 bytes).

[0114] For class B memory access 920 instruction templates, a portion of the beta field 954 is interpreted as a broadcast field 957B, whose content distinguishes whether a broadcast-type data manipulation operation is to be performed, and the remainder of the beta field 954 is interpreted as a vector length field 959B. The memory access 920 instruction templates include a scale field 960 and, optionally, a displacement field 962A or a displacement scale field 962B.

[0115] In relation to the generic vector friendly instruction format 900, includes a format field 940, a base operation field 942, and a data element width field 964. A full opcode field 974 is shown. Although one embodiment is shown in which the full opcode field 974 includes all of these fields, in embodiments that do not support all of them, the full opcode field 974 includes less than all of these fields. The full opcode field 974 provides an operation code (opcode).

[0116] The extended operation field 950, data element width field 964, and write mask field 970 allow these characteristics to be specified on an instruction-by-instruction basis in a generic vector friendly instruction format.

[0117] The combination of the write mask field and the data element width field create a typed instruction in that they allow masks to be applied based on different data element widths.

[0118] The various instruction templates found within class A and class B are useful in various situations. In some embodiments of the present disclosure, different processors or different cores within a processor may support only class A, only class B, or both classes. For example, a high-performance general-purpose out-of-order core intended for general-purpose computing may support only class B, a core intended primarily for graphics and / or scientific (throughput) computing may support only class A, and a core intended for both may support both (of course, a core may have some combination of templates and instructions from both classes, but not all templates and instructions from both classes are within the scope of the present disclosure). Also, a single processor may include multiple cores, all of which support the same class, or different cores support different classes. For example, in a processor with separate graphics and general-purpose cores, one of the graphics cores intended primarily for graphics and / or scientific computing may support only class A, and one or more of the general-purpose cores may be a high-performance general-purpose core with out-of-order execution and register renaming intended for general-purpose computing that supports only class B. Another processor that does not have a separate graphics core may include one or more general-purpose in-order or out-of-order cores that support both class A and class B. Of course, functionality from one class may be implemented in other classes in different embodiments of the present disclosure. Programs written in high-level languages ​​can be put into a variety of different executable formats (e.g., just-in-time compiled or statically compiled), including 1) a format that has only instructions of classes supported by the target processor for execution, or 2) a format that has alternative routines written using different combinations of instructions of all classes, with control flow code that selects which routines to execute based on the instructions supported by the processor currently executing the code. [Example specific vector friendly instruction formats]

[0119] 10A and 10B are block diagrams illustrating an example specific vector friendly instruction format according to an embodiment of the present disclosure. FIG. 10A and 10B show a specific vector friendly instruction format 1000. The specific vector friendly instruction format 1000 is specific in the sense that it specifies the location, size, interpretation, and field order, as well as the values ​​of some of these fields. The specific vector friendly instruction format 1000 may be used to extend the x86 instruction set, and thus some fields are similar or identical to fields used in the existing x86 instruction set and its extensions (e.g., AVX). This format maintains consistency with the prefix encoding field, real opcode byte field, MOD R / M field, SIB field, displacement field, and immediate field of the existing x86 instruction set with its extensions. It is shown which fields of FIG. 9A and FIG. 9B map to which fields of FIG. 10A and FIG. 10B.

[0120] Although embodiments of the present disclosure are described in the context of a generic vector friendly instruction format 900 and with reference to a specific vector friendly instruction format 1000 for illustrative purposes, it should be understood that the present disclosure is not limited to a specific vector friendly instruction format 1000 except as set forth in the claims. For example, the generic vector friendly instruction format 900 contemplates a variety of possible sizes for various fields, but the specific vector friendly instruction format 1000 is shown as having fields of specific sizes. As a specific example, although the data element width field 964 is shown in the specific vector friendly instruction format 1000 as a one-bit field, the present disclosure is not so limited (i.e., the generic vector friendly instruction format 900 contemplates data element width fields 964 of other sizes).

[0121] The generic vector friendly instruction format 900 includes the following fields, listed below in the order shown in FIG. 10A:

[0122] EVEX Prefix (bytes 0-3) 1002 - Encoded in a 4-byte format.

[0123] Format Field 940 (EVEX Byte 0, bits [7:0]) - The first byte (EVEX Byte 0) is the format field 940, which contains 0x62 (a unique value used in one embodiment of the present disclosure to distinguish vector friendly instruction formats).

[0124] The second through fourth bytes (EVEX bytes 1-3) contain a number of bit fields that provide specific functions.

[0125] The REX field 1005 (EVEX byte 1, bits [7-5] - consists of the EVEX.R bit field (EVEX byte 1, bit [7] - R), the EVEX.X bit field (EVEX byte 1, bit [6] - X), and the 957BEX byte 1, bit [5] - B). The EVEX.R, EVEX.X, and EVEX.B bit fields provide the same functionality as the corresponding VEX bit fields, and they are encoded using one's complement format; that is, ZMM0 is encoded as 1111B, ZMM15 is encoded as 0000B. The other fields of the instruction encode the lower three bits of the register index (rrr, xxx, and bbb) as known in the art, so that Rrrr, Xxxx, and Bbbb may be formed by adding EVEX.R, EVEX.X, and EVEX.B.

[0126] REX' Field 910 - This is the first part of the REX' field 910, the EVEX.R' bit field (EVEX byte 1, bit [4] - R') that is used to encode either the top 16 or the bottom 16 of the extended 32 register set. In one embodiment of the disclosure, this bit is stored in a bit-reversed format along with others as shown below to distinguish it from the BOUND instruction (in the well-known x86 32-bit mode) whose real opcode byte is 62, but the MOD R / M field (described below) does not accept a value of 11 in the MOD field. In an alternative embodiment of the disclosure, this bit and the others as shown below are not stored in an inverted format. A value of 1 is used to encode the bottom 16 registers. In other words, R'Rrrr is formed by combining EVEX.R', EVEX.R, and the other RRR from the other fields.

[0127] Opcode map field 1015 (EVEX byte 1, bits [3:0]-mmmm) - Its contents encode the implied initial opcode byte (0F, 0F38, or 0F3).

[0128] Data Element Width field 964 (EVEX byte 2, bit [7]-W) - represented by the notation EVEX.W. EVEX.W is used to specify the granularity (size) of the data type (either 32-bit data elements or 64-bit data elements).

[0129] EVEX.vvvv1020 (EVEX byte 2, bits [6:3]-vvvv) - The role of EVEX.vvvv may include: 1) EVEX.vvvv encodes the first source register operand specified in inverted (one's complement) form and is valid for instructions with two or more source operands. 2) EVEX.vvvv encodes the destination register operand specified in one's complement form for certain vector shifts. 3) EVEX.vvvv does not encode any operand, the field is reserved and should contain 1111b. Thus, EVEX.vvvv field 1020 encodes the four least significant bits of the first source register specifier stored in inverted (one's complement) form. Depending on the instruction, additional different EVEX bit fields are used to extend the specifier size to 32 registers.

[0130] EVEX.U968 Class field (EVEX byte 2, bit [2]-U) - If EVEX.U=0, this indicates class A or EVEX.U0. If EVEX.U=1, this indicates class B or EVEX.U1.

[0131] Prefix Encoding Field 1025 (EVEX byte 2, bits [1:0]-pp) - this provides additional bits of the base operation field. In addition to providing support for legacy SSE instructions in the EVEX prefix format, this also has the benefit of compacting the SIMD prefix (instead of requiring one byte to represent the SIMD prefix, the EVEX prefix only requires two bits). In one embodiment, to support legacy SSE instructions that use SIMD prefixes (66H, F2H, F3H) in both the legacy and EVEX prefix formats, these legacy SIMD prefixes are encoded in the SIMD prefix encoding field. These legacy SIMD prefixes are expanded to legacy SIMD prefixes at run-time before being provided to the decoder's PLA (so the PLA can execute both the legacy and EVEX formats of these legacy instructions without modification). Newer instructions can directly use the contents of the EVEX prefix encoding field as an opcode extension. However, certain embodiments extend them in a similar manner for consistency, but allow these legacy SIMD prefixes to have different meanings specified. Alternate embodiments can redesign the PLA to support 2-bit SIMD prefix encodings and therefore not require the extensions.

[0132] Alpha field 952 (EVEX byte 3, bit [7] - EH, also known as EVEX.EH, EVEX.rs, EVEX.RL, EVEX.write mask control and EVEX.N, and denoted with an alpha) - As previously mentioned, this field is context specific.

[0133] Beta field 954 (EVEX byte 3, bits [6:4] - SSS, EVEX.s 2-0 , EVEX.r 2-0, EVEX.rrl, EVEX.LL0, EVEX.LLB, and denoted using βββ) - as mentioned above, this field is context specific.

[0134] REX' field 910 - this is the remainder of the REX' field, the EVEX.V' bit field (EVEX byte 3, bit [3] - V') which can be used to encode either the top 16 or the bottom 16 of the extended 32 register set. This bit is stored in bit-reversed format. A value of 1 is used to encode the bottom 16 registers. In other words, combining EVEX.V', EVEX.vvvv forms V'VVVV.

[0135] Write mask field 970 (EVEX byte 3, bits [2:0] - kkk) - its contents specify the index of a register in the write mask register, as previously described. In one embodiment of the present disclosure, a special value EVEX.kkk=000 has special behavior that indicates that there is no write mask to be used for the particular instruction (this can be implemented in various ways, including a hardwired write mask for everything, or the use of hardware to bypass the masking hardware).

[0136] The real opcode field 2030 (byte 4) is also known as the opcode byte. Part of the opcode is specified in this field.

[0137] MOD R / M field 1040 (byte 5) includes MOD field 1042, Reg field 1044, and R / M field 1046. As previously mentioned, the contents of MOD field 1042 distinguish between memory access operations and operations without memory access. The role of Reg field 1044 can be summarized in two situations: encoding either a destination register operand or a source register operand, or being treated as an opcode extension and not used to encode an instruction operand. The role of R / M field 1046 can include encoding an instruction operand that references a memory address, or encoding either a destination register operand or a source register operand.

[0138] Scale, Index, Base (SIB) Byte (Byte 6) - As mentioned above, the contents of the scale field 950 are used for memory address generation. SIB.xxx 1054 and SIB.bbb 1056 - The contents of these fields have already been mentioned in relation to the register indexes Xxxx and Bbbb.

[0139] Displacement field 962A (bytes 7-10): If the MOD field 1042 contains 10, then bytes 7-10 are the displacement field 962A, which works the same as the legacy 32-bit displacement (disp32), and works at byte granularity.

[0140] Displacement factor field 962B (byte 7) - When MOD field 1042 contains 01, byte 7 is the displacement factor field 962B. The location of this field is the same as that of the 8-bit displacement (disp8) of the legacy x86 instruction set, which works at byte granularity. Since disp8 is sign-extended, it can only address between -128 and 127 byte offsets, and for a 64-byte cache line, disp8 uses 8 bits that can only be set to the four really useful values ​​-128, -64, 0, and 64; since a larger range is often needed, disp32 is used, but disp32 requires 4 bytes. In contrast to disp8 and disp32, the displacement factor field 962B is a reinterpretation of disp8, and when using the displacement factor field 962B, the actual displacement is determined by the contents of the displacement factor field multiplied by the size of the memory operand access (N). This type of displacement is referred to as disp8×N. This reduces the average instruction length (a single byte used for displacement, but with a much larger range). Such a compressed displacement is based on the assumption that the effective displacement is a multiple of the granularity of the memory access, and therefore the redundant lower bits of the address offset do not need to be encoded. In other words, the displacement factor field 962B replaces the 8-bit displacement of the legacy x86 instruction set. Thus, the displacement factor field 962B is encoded in the same way as the 8-bit displacement of the x86 instruction set, except that disp8 is overloaded to disp8×N (hence, no change in the ModRM / SIB encoding rules). In other words, there is no change in the encoding rules or encoding length, only in the interpretation of the displacement value by the hardware (the displacement needs to be scaled by the size of the memory operand to get the address offset in bytes). The immediate field 972 works as previously described. [Full Opcode Field]

[0141] 10B is a block diagram illustrating the fields of a particular vector friendly instruction format 1000 that creates a full opcode field 974 in accordance with one embodiment of the present disclosure. Specifically, the full opcode field 974 includes a format field 940, a base operation field 942, and a data element width (W) field 964. The base operation field 942 includes a prefix encoding field 1025, an opcode map field 1015, and a real opcode field 1030. [Register index field]

[0142] 10C is a block diagram illustrating fields of a particular vector friendly instruction format 1000 that create a register index field 944 according to one embodiment of the present disclosure. Specifically, the register index field 944 includes a REX field 1005, a REX′ field 1010, a MODR / M.reg field 1044, a MODR / Mr / m field 1046, a VVVV field 1020, a xxx field 1054, and a bbb field 1056. [Extended operation field]

[0143] 10D is a block diagram illustrating the fields of a particular vector friendly instruction format 1000 that creates an extended operation field 950 according to one embodiment of the present disclosure. If the class (U) field 968 contains a 0, it means EVEX.U0 (Class A 968A), and if it contains a 1, it means EVEX.U1 (Class B 968B). If U=0 and the MOD field 1042 contains 11 (meaning an operation without a memory access), the alpha field 952 (EVEX byte 3, bit [7]) - EH) is interpreted as an rs field 952A. If the rs field 952A contains a 1 (round 952A.1), the beta field 954 (EVEX byte 3, bits [6:4] - SSS) is interpreted as a round control field 954A. The round control field 954A includes a 1-bit SAE field 956 and a 2-bit round operation field 958. If the rs field 952A contains 0 (data transformation 952A.2), then the beta field 954 (EVEX byte 3, bits [6:4] - SSS) is interpreted as a 3-bit data transformation field 954B. If U=0 and the MOD field 1042 contains 00, 01 or 10 (signifying a memory access operation), then the alpha field 952 (EVEX byte 3, bit [7] - EH) is interpreted as an eviction hint (EH) field 952B and the beta field 954 (EVEX byte 3, bits [6:4] - SSS) is interpreted as a 3-bit data operation field 954C.

[0144] If U=1, the alpha field 952 (EVEX byte 3, bit [7]—EH) is interpreted as a write mask control (Z) field 952C. If U=1 and the MOD field 1042 contains 11 (signifying a no memory access operation), then part of the beta field 954 (EVEX byte 3, bit [4]—S0) is interpreted as the RL field 957A. If it contains 1 (round 957A.1), then the remainder of the beta field 954 (EVEX byte 3, bits [6-5]—S 2-1) is interpreted as the round operation field 959A, while if the RL field 957A contains zero (VSIZE 957.A2), the remainder of the beta field 954 (EVEX byte 3, bits [6-5]—S 2-1 ) is the vector length field 959B (EVEX byte 3, bits [6‐5] – L 1-0 If U=1 and the MOD field 1042 contains 00, 01, or 10 (indicating a memory access operation), the beta field 954 (EVEX byte 3, bits [6:4]—SSS) is interpreted as the vector length field 959B (EVEX byte 3, bits [6-5]—L 1-0 ) and broadcast field 957B (EVEX byte 3, bit [4] – B). [Example Register Architecture]

[0145] 11 is a block diagram of a register architecture 1100 according to one embodiment of the present disclosure. In the embodiment shown, there are 32 vector registers 1110 that are 512 bits wide. These registers are referenced as zmm0 through zmm31. The lower 256 bits of the lower 16 zmm registers overlap registers ymm0 through ymm16. The lower 128 bits of the lower 16 zmm registers (the lower 128 bits of the ymm registers) overlap registers xmm0 through xmm15. A particular vector friendly instruction format 1000 operates on these overlapping register files as shown in the table below. [Table 5]

[0146] In other words, the vector length field 959B selects between a maximum length and one or more other shorter lengths, where each such shorter length is half the length of the preceding length, and instruction templates without the vector length field 959B operate on the maximum vector length. Furthermore, in one embodiment, the class B instruction templates of the particular vector friendly instruction format 1000 operate on packed or scalar single / double precision floating point data, and packed or scalar integer data. Scalar operations are operations performed on the least significant data element positions in the zmm / ymm / xmm registers. Depending on the embodiment, the more significant data element positions either remain the same as before the instruction or are zeroed out.

[0147] Write Mask Registers 1115 - In the embodiment shown, there are eight write mask registers (k0 through k7), each of which is 64 bits in size. In an alternative embodiment, the write mask registers 1115 are 16 bits in size. As previously mentioned, in one embodiment of the present disclosure, vector mask register k0 cannot be used as a write mask; if an encoding that would normally indicate k0 is used for a write mask, selecting a hardwired write mask of 0xFFFF effectively disables write masking for that instruction.

[0148] General purpose registers 1125 - in the illustrated embodiment, there are sixteen 64-bit general purpose registers that are used in conjunction with existing x86 addressing modes to address memory operands. These registers are referenced by the names RAX, RBX, RCX, RDX, RBP, RSI, RDI, RSP, and R8 through R15.

[0149] Scalar floating-point stack register file (x87 stack) 1145 into which MMX packed integer flat register file 1150 is aliased - in the illustrated embodiment, the x87 stack is an 8-element stack used to perform scalar floating-point operations on 32 / 64 / 80-bit floating-point data using the x87 instruction set extensions, while the MMX registers are used to perform operations on 64-bit packed integer data, as well as to hold operands for some operations performed between MMX and XMM registers.

[0150] Alternative embodiments of the present disclosure may use wider or narrower registers. Additionally, alternative embodiments of the present disclosure may use more, fewer, or different register files and registers. [Exemplary Core Architectures, Processors, and Computer Architectures]

[0151] Processor cores may be implemented in different ways, for different purposes, and in different processors. For example, implementations of such cores may include: 1) a general purpose in-order core for general purpose computing, 2) a high performance general purpose out-of-order core for general purpose computing, 3) a special purpose core primarily for graphics and / or scientific (throughput) computing. Implementations of different processors may include: 1) a CPU including one or more general purpose in-order cores for general purpose computing and / or one or more general purpose out-of-order cores for general purpose computing, and 2) a co-processor including one or more special purpose cores primarily for graphics and / or scientific (throughput). Such different processors result in different computer system architectures, which may include: 1) coprocessors on a separate chip from the CPU, 2) coprocessors on a separate die in the same package as the CPU, 3) coprocessors on the same die as the CPU (in which case such coprocessors are sometimes referred to as special purpose logic, e.g., integrated graphics and / or scientific (throughput) logic, or are sometimes referred to as application-specific cores), and 4) systems-on-chips (sometimes referred to as application cores or application processors, the coprocessors and additional functionality discussed above) that may be included on the same die as the described CPU. Exemplary core architectures are described next, followed by exemplary processor and computer architectures. [Example Core Architecture] (In-order and out-of-order core block diagram)

[0152] FIG. 12A is a block diagram illustrating both an example in-order pipeline and an example register renaming, out-of-order issue / execution pipeline according to embodiments of the present disclosure. FIG. 12B is a block diagram illustrating both an example embodiment of an in-order architecture core and an example register renaming, out-of-order issue / execution architecture core included in a processor according to embodiments of the present disclosure. The solid lined boxes in FIG. 12A-B indicate the in-order pipeline and the in-order core, while the optional addition of dashed lined boxes indicates the register renaming, out-of-order issue / execution pipeline and core. The out-of-order aspects will be described assuming that the in-order aspects are a subset of the out-of-order aspects.

[0153] In FIG. 12A , a processor pipeline 1200 includes a fetch stage 1202, a length decode stage 1204, a decode stage 1206, an allocation stage 1208, a renaming stage 1210, a scheduling (also known as dispatch or issue) stage 1212, a register read / memory read stage 1214, an execution stage 1216, a writeback / memory write stage 1218, an exception handling stage 1222, and a commit stage 1224.

[0154] 12B shows a processor core 1290 that includes a front end unit 1230 coupled to an execution engine unit 1250, both of which are coupled to a memory unit 1270. Core 1290 may be a reduced instruction set computing (RISC) core, a complex instruction set computing (CISC) core, a very long instruction word (VLIW) core, or a hybrid or alternative core type. As yet another option, core 1290 may be an application-specific core, such as, for example, a network or communication core, a compression engine, a co-processor core, a general purpose computing graphics processing unit (GPGPU) core, or a graphics core.

[0155] The front-end unit 1230 includes a branch prediction unit 1232 coupled to an instruction cache unit 1234, which is coupled to an instruction translation lookaside buffer (TLB) 1236, which is coupled to an instruction fetch unit 1238, which is coupled to a decode unit 1240. The decode unit 1240 (or a decoder or decoder unit) may decode instructions (e.g., macro-instructions) and generate as output one or more micro-operations, microcode entry points, microinstructions, other instructions, or other control signals decoded from or otherwise reflecting or derived from the original instruction. The decode unit 1240 may be implemented using a variety of different mechanisms. Examples of suitable mechanisms include, but are not limited to, look-up tables, hardware implementations, programmable logic arrays (PLAs), microcode read-only memories (ROMs), and the like. In one embodiment, core 1290 includes a microcode ROM or other medium that stores microcode for particular macro instructions (e.g., in decode unit 1240 or otherwise within front end unit 1230). Decode unit 1240 is coupled to rename / allocator unit 1252 within execution engine unit 1250.

[0156] The execution engine units 1250 include a rename / allocator unit 1252 coupled to a retirement unit 1254 and a set of one or more scheduler units 1256. The scheduler units 1256 represent any number of different schedulers including reservation stations, central instruction windows, etc. The scheduler units 1256 are coupled to physical register file units 1258. Each of the physical register file units 1258 represents one or more physical register files. The different physical register files store one or more different data types, such as scalar integer, scalar floating point, packed integer, packed floating point, vector integer, vector floating point, status (e.g., an instruction pointer, which is the address of the next instruction to be executed), etc. In one embodiment, the physical register file units 1258 include a vector register unit, a write mask register unit, and a scalar register unit. These register units can provide architectural vector registers, vector mask registers, and general purpose registers. The physical register files unit 1258 is overlaid with a retirement unit 1254 to illustrate various ways in which register renaming and out-of-order execution may be implemented (e.g., using a reorder buffer and retirement register file, using a future file, a history buffer, and a retirement register file, using a register map and a pool of registers, etc.). The retirement unit 1254 and the physical register files unit 1258 are coupled to an execution cluster 1260. The execution cluster 1260 includes a set of one or more execution units 1262 and a set of one or more memory access units 1264. The execution units 1262 may perform various operations (e.g., shift, add, subtract, multiply) on various types of data (e.g., scalar floating point, packed integer, packed floating point, vector integer, vector floating point).Some embodiments may include multiple execution units dedicated to a particular function or set of functions, while other embodiments may include only one execution unit, or multiple execution units that all perform all functions. Scheduler unit 1256, physical register file unit 1258, and execution cluster 1260 are shown as possibly multiple because certain embodiments create separate pipelines for particular types of data / operations (e.g., scalar integer pipelines, scalar floating point / packed integer / packed floating point / vector integer / vector floating point pipelines, and / or memory access pipelines, each with its own scheduler unit, physical register file unit, and / or execution cluster, and in the case of a separate memory access pipeline, certain embodiments are implemented in which only the execution cluster of this pipeline has memory access unit 1264). It should also be understood that if separate pipelines are used, one or more of these pipelines may be out-of-order issue / execution and the rest may be in-order.

[0157] The set of memory access units 1264 is coupled to a memory unit 1270 that includes a data TLB unit 1272 coupled to a data cache unit 1274 that is coupled to a level 2 (L2) cache unit 1276. In an exemplary embodiment, the memory access units 1264 may include a load unit, a store address unit, and a store data unit, each of which is coupled to the data TLB unit 1272 in the memory unit 1270. The instruction cache unit 1234 is further coupled to a level 2 (L2) cache unit 1276 in the memory unit 1270. The L2 cache unit 1276 is coupled to one or more other levels of cache and ultimately to a main memory.

[0158] In a particular embodiment, a prefetch circuit 1278 is included to prefetch data, for example, to predict access addresses and bring data for those addresses (e.g., from memory 1280) to a cache or caches. In one embodiment, the prefetch circuit 1278 is an instance of the prefetch circuit in FIG. 12B.

[0159] As an example, an exemplary register renaming, out-of-order issue / execution core architecture may implement the pipeline 1200 as follows: 1) instruction fetch 1238 performs the fetch stage 1202 and the length decoding stage 1204; 2) decode unit 1240 performs the decode stage 1206; 3) rename / allocator unit 1252 performs the allocation stage 1208 and the renaming stage 1210; 4) scheduler unit 1256 performs the schedule stage 1212; 5) physical register file unit 1258 and memory unit 1270 perform the register read / memory read stage 1214, and execution cluster 1260 performs the execution stage 1216; 6) memory unit 1270 and physical register file unit 1258 perform the writeback / memory write stage 1218; 7) various units may be involved in the exception handling stage 1222. 8) The retirement unit 1254 and the physical register file unit 1258 perform the commit stage 1224.

[0160] Core 1290 may support one or more instruction sets (e.g., the x86 instruction set (with some extensions added in newer versions), the MIPS instruction set from MIPS Technologies of Sunnyvale, Calif., the ARM instruction set (with optional additional extensions such as NEON) from ARM Holdings of Sunnyvale, Calif.) that include the instructions described herein. In one embodiment, core 1290 includes logic to support packed data instruction set extensions (e.g., AVX1, AVX2), allowing operations used by many multimedia applications to be performed with packed data.

[0161] It will be appreciated that a core may support multithreading (executing two or more parallel sets of operations or threads) in a variety of ways including time sliced ​​multithreading, simultaneous multithreading (wherein a single physical core provides a logical core for each thread that the physical core is simultaneously multithreading), or a combination thereof (e.g., time sliced ​​fetching and decoding, and later simultaneous multithreading such as Intel® Hyper-Threading Technology).

[0162] Although register renaming is described in the context of out-of-order execution, it should be understood that register renaming may also be used in in-order architectures. The illustrated embodiment of the processor also includes separate instruction and data cache units 1234 / 1274 and a shared L2 cache unit 1276, although alternative embodiments may have a single internal cache for both instructions and data, such as a level 1 (L1) internal cache, or multiple levels of internal cache. In some embodiments, the system may include a combination of an internal cache and an external cache that is external to the core and / or processor. Alternatively, all of the caches may be external to the core and / or processor. [Specific Exemplary In-Order Core Architecture]

[0163] 13A-13B show block diagrams of a more specific exemplary in-order core architecture. The core may be one of several logic blocks (including other cores of the same and / or different types) in a chip. The logic block communicates with some fixed function logic, memory I / O interfaces, and other necessary I / O logic through a high bandwidth interconnect network (e.g., a ring network) depending on the application.

[0164] FIG. 13A is a block diagram illustrating a single processor core according to embodiments of the present disclosure, along with its connection to an on-die interconnect network 1302 and its local subset of a level 2 (L2) cache 1304. In one embodiment, an instruction decode unit 1300 supports the x86 instruction set with a packed data instruction set extension. An L1 cache 1306 allows low latency access to cache memory in the scalar and vector units. In one embodiment (for design simplicity), the scalar unit 1308 and the vector unit 1310 use separate register sets (scalar registers 1312 and vector registers 1314, respectively). Data transferred between them is written to the memory of the level 1 (L1) cache 1306 and then re-read, although alternative embodiments of the present disclosure may use different approaches (e.g., using a single register set or including a communication path that allows data transfer between the two register files without writing and re-reading).

[0165] The local subset of the L2 cache 1304 is part of a global L2 cache that is divided into separate local subsets, one for each processor core. Each processor core has a direct access path to its local subset of the L2 cache 1304. Data read by a processor core is stored in its L2 cache subset 1304 and can be accessed quickly in parallel with other processor cores accessing their local L2 cache subsets. Data written by a processor core is stored in its L2 cache subset 1304 and is flushed from other subsets when necessary. The ring network ensures coherency of shared data. The ring network is bidirectional to allow agents such as processor cores, L2 caches, and other logic blocks to communicate with each other within the chip. Each ring data path is 1012 bits wide per direction.

[0166] FIG. 13B is an expanded view of a portion of the processor core in FIG. 13A according to embodiments of the present disclosure. FIG. 13B includes an L1 data cache 1306A portion of the L1 cache 1304, as well as further details regarding the vector unit 1310 and vector registers 1314. Specifically, the vector unit 1310 is a 16-wide vector processing unit (VPU) (see 16-wide ALU 1328) that executes one or more of integer, single-precision, and double-precision float instructions. The VPU supports swizzling of register inputs using swizzle unit 1320, numeric conversion using numeric conversion units 1322A-1322B, and duplication for memory inputs using duplication unit 1324. A write mask register 1326 allows for the resulting vector writes to be predicated.

[0167] 14 is a block diagram of a processor 1400, which may have more than one core, an integrated memory controller, and integrated graphics, according to embodiments of the present disclosure. The solid lined box in FIG. 14 illustrates a processor 1400 having a single core 1402A, a system agent 1410, and a set of one or more bus controller units 1416, while the optional addition of dashed lined boxes illustrates an alternative processor 1400 having multiple cores 1402A-1402N, a set of one or more integrated memory controller units 1414 in the system agent unit 1410, and special purpose logic 1408.

[0168] Thus, different implementations of the processor 1400 may include: 1) a CPU with special purpose logic 1408 (which may include one or more cores) that is integrated graphics and / or scientific (throughput) logic, and one or more general purpose cores 1402A-1402N (e.g., general purpose in-order cores, general purpose out-of-order cores, combinations of the two); 2) a coprocessor with many special purpose cores 1402A-1402N that are primarily targeted at graphics and / or scientific (throughput); and 3) a coprocessor with many general purpose in-order cores 1402A-1402N. Thus, the processor 1400 may be a general purpose processor, coprocessor, or special purpose processor, such as, for example, a network or communication processor, a compression engine, a graphics processor, a GPGPU (general purpose graphics processing unit), a high throughput MIC (many integrated core) coprocessor (containing 30 or more cores), an embedded processor, etc. The processor may be implemented on one or more chips. The processor 1400 may be a part of and / or be implemented on one or more substrates using any of a number of process technologies, such as, for example, BiCMOS, CMOS, or NMOS.

[0169] The memory hierarchy includes one or more levels of cache within the cores, a set of shared cache units 1406 or one or more shared cache units 1406, and an external memory (not shown) coupled to a set of integrated memory controller units 1414. The set of shared cache units 1406 may include one or more mid-level caches, such as level 2 (L2), level 3 (L3), level 4 (L4), or other level caches, a last level cache (LLC), and / or combinations thereof. In one embodiment, a ring-based interconnect unit 1412 interconnects the integrated graphics logic 1408, the set of shared cache units 1406, and the system agent unit 1410 / integrated memory controller unit 1414, although alternative embodiments may use any number of well-known techniques for interconnecting such units. In one embodiment, coherency is maintained between the one or more cache units 1406 and the cores 1402A-1402N.

[0170] In some embodiments, one or more of the cores 1402A-1402N are capable of multithreading. The system agent 1410 includes those components that coordinate and operate the cores 1402A-1402N. The system agent unit 1410 may include, for example, a power control unit (PCU) and a display unit. The PCU may be or may include the logic and components necessary to coordinate the power state of the cores 1402A-1402N and the integrated graphics logic 1408. The display unit is for driving one or more externally connected displays.

[0171] The cores 1402A-1402N may be homogenous or heterogeneous with respect to architectural instruction sets, i.e., two or more of the cores 1402A-1402N may be capable of executing the same instruction set, while others may be capable of executing only a subset of that instruction set or a different instruction set. [Example Computer Architecture]

[0172] 15-18 are block diagrams of exemplary computer architectures. Other system designs and configurations known in the art for laptops, desktops, handheld PCs, personal digital assistants, engineering workstations, servers, network devices, network hubs, switches, embedded processors, digital signal processors (DSPs), graphics devices, video game devices, set-top boxes, microcontrollers, mobile phones, portable media players, handheld devices, and various other electronic devices are also suitable. In general, a wide variety of systems or electronic devices capable of incorporating the processors and / or other execution logic disclosed herein are generally suitable.

[0173] 15, a block diagram of a system 1500 according to one embodiment of the present disclosure is shown. The system 1500 may include one or more processors 1510, 1515, which are coupled to a controller hub 1520. In one embodiment, the controller hub 1520 includes a graphics memory controller hub (GMCH) 1590 and an input / output hub (IOH) 1550, which may be on separate chips. The GMCH 1590 includes a memory controller and a graphics controller, to which a memory 1540 and a coprocessor 1545 are coupled. The IOH 1550 couples an input / output (I / O) device 1560 to the GMCH 1590. Alternatively, one or both of the memory controller and the graphics controller are integrated within the processor (as described herein), and the memory 1540 and the coprocessor 1545 are directly coupled to the processor 1510 and the controller hub 1520, which are in a single chip with the IOH 1550. Memory 1540 may include, for example, prefetcher code 1540A that stores code that, when executed, causes a processor to perform any of the methods of this disclosure.

[0174] The optional nature of the additional processors 1515 is indicated by dashed lines in Figure 15. Each processor 1510, 1515 may include one or more of the processing cores described herein and may be some version of the processor 1400.

[0175] The memory 1540 may be, for example, dynamic random access memory (DRAM), phase change memory (PCM), or a combination of the two. For at least one embodiment, the controller hub 1520 communicates with the processors 1510, 1515 via a connection 1595, for example, a multi-drop bus such as a front side bus (FSB), a point-to-point interface such as a QuickPath Interconnect (QPI), or similar.

[0176] In one embodiment, coprocessor 1545 is a special purpose processor such as, for example, a high throughput MIC processor, a network or communication processor, a compression engine, a graphics processor, a GPGPU, an embedded processor, etc. In one embodiment, controller hub 1520 may include an integrated graphics accelerator.

[0177] There may be a wide variety of differences between the physical resources 1510, 1515 in terms of a wide range of value criteria including architectural characteristics, microarchitectural characteristics, thermal characteristics, power consumption characteristics, and the like.

[0178] In one embodiment, the processor 1510 executes instructions that control a general type of data processing operation. Coprocessor instructions may be embedded within the instructions. The processor 1510 recognizes these coprocessor instructions as being of a type that should be executed by an attached coprocessor 1545. The processor 1510 therefore issues these coprocessor instructions (or control signals representing the coprocessor instructions) to the coprocessor 1545 over a coprocessor bus or other interconnect. The coprocessor 1545 accepts and executes the received coprocessor instructions.

[0179] 16, a block diagram of a first, more specific, exemplary system 1600 according to an embodiment of the present disclosure is shown. As shown in FIG. 16, the multiprocessor system 1600 is a point-to-point interconnect system and includes a first processor 1670 and a second processor 1680 coupled via a point-to-point interconnect 1650. Each of the processors 1670 and 1680 may be some version of the processor 1400. In one embodiment of the present disclosure, the processors 1670 and 1680 are the processors 1510 and 1515, respectively. Meanwhile, the coprocessor 1638 is the coprocessor 1545. In another embodiment, the processors 1670 and 1680 are the processors 1510 and 1545, respectively.

[0180] Processor 1670 and processor 1680 are shown as including integrated memory controller (IMC) units 1672 and 1682, respectively. Processor 1670 also includes point-to-point (PP) interfaces 1676 and 1678 as part of its bus controller unit. Similarly, second processor 1680 includes PP interfaces 1686 and 1688. Processors 1670, 1680 may exchange information using PP interface circuits 1678, 1688 via point-to-point (PP) interface 1650. As shown in FIG. 16, IMCs 1672 and 1682 couple the processors to respective memories, i.e., memory 1632 and memory 1634. These memories may be part of a main memory locally attached to the respective processors.

[0181] Each of the processors 1670, 1680 can exchange information with a chipset 1690 using point-to-point interface circuits 1676, 1694, 1686, 1698 via respective PP interfaces 1652, 1654. The chipset 1690 may optionally exchange information with a coprocessor 1638 via a high performance interface 1639. In one embodiment, the coprocessor 1638 is a special purpose processor such as, for example, a high throughput MIC processor, a network or communication processor, a compression engine, a graphics processor, a GPGPU, an embedded processor, or the like.

[0182] A shared cache (not shown) may be contained within either processor or external to both processors, but may be connected to the processors via the PP interconnect so that local cache information of one or both processors may be stored in the shared cache when the processors enter a low power mode.

[0183] Chipset 1690 may be coupled to a first bus 1616 via an interface 1696. In one embodiment, first bus 1616 may be a bus such as a Peripheral Component Interconnect (PCI) bus, or a PCI Express bus or another third generation I / O interconnect bus, although the scope of the disclosure is not so limited.

[0184] As shown in FIG. 16, various input / output devices 1614 may be coupled to the first bus 1616, along with a bus bridge 1618 that couples the first bus 1616 to a second bus 1620. In one embodiment, one or more additional processors 1615, such as a co-processor, a high-throughput MIC processor, a GPGPU, an accelerator (e.g., a graphics accelerator or a digital signal processing (DSP) unit), a field programmable gate array, or any other processor, are coupled to the first bus 1616. In one embodiment, the second bus 1620 may be a low pin count (LPC) bus. In one embodiment, various devices may be coupled to the second bus 1620, including, for example, a keyboard and / or mouse 1622, a communication device 1627, and a storage unit 1628, such as a disk drive or other mass storage device that may contain instructions / code and data 1630. Additionally, audio input / output 1624 may be coupled to the second bus 1620. It should be noted that other architectures are possible. For example, instead of the point-to-point architecture of FIG. 16, the system may implement a multi-drop bus or other such architecture.

[0185] Referring now to Figure 17, a block diagram of a second, more specific, exemplary system 1700 according to an embodiment of the present disclosure is shown. Like elements in Figures 16 and 17 are labeled with like reference numbers, and certain aspects of Figure 16 have been omitted from Figure 17 to avoid obscuring other aspects of Figure 17.

[0186] FIG. 17 shows that the processors 1670, 1680 may include integrated memory and input / output control logic ("CL") 1672 and 1682, respectively. Thus, the CL 1672, 1682 includes an integrated memory controller unit and input / output control logic. FIG. 17 shows that not only the memory 1632, 1634 is coupled to the CL 1672, 1682, but also the input / output devices 1714 are coupled to the control logic 1672, 1682. The legacy input / output devices 1715 are coupled to the chipset 1690.

[0187] Referring now to FIG. 18, a block diagram of an SoC 1800 according to an embodiment of the present disclosure is shown. Similar elements in FIG. 14 are labeled with similar reference numbers. Also, the dashed boxes are optional features in more advanced SoCs. In FIG. 18, an interconnect unit 1802 is coupled to an application processor 1810 including a set of one or more cores 1402A-1402N and a shared cache unit 1406, a system agent unit 1410, a bus controller unit 1416, an integrated memory controller unit 1414, a set or one or more coprocessors 1820 that may include integrated graphics logic, an image processor, an audio processor, and a video processor, a static random access memory (SRAM) unit 1830, a direct memory access (DMA) unit 1832, and a display unit 1840 for coupling to one or more external displays. In one embodiment, the coprocessor 1820 includes a special purpose processor, such as, for example, a network or communication processor, a compression engine, a GPGPU, a high throughput MIC processor, or an embedded processor.

[0188] The embodiments (e.g., mechanisms) disclosed herein may be implemented in hardware, software, firmware, or a combination of such implementation approaches. The embodiments of the present disclosure may be implemented as a computer program or program code running on a programmable system comprising at least one processor, a storage system (including volatile and non-volatile memory and / or storage elements), at least one input device, and at least one output device.

[0189] Program code, such as code 1630 shown in Figure 16, may be applied to input instructions to perform functions described herein and to generate output information. The output information may be applied to one or more output devices, in known fashion. For purposes of this application, a processing system includes any system having a processor, such as, for example, a digital signal processor (DSP), a microcontroller, an application specific integrated circuit (ASIC), or a microprocessor.

[0190] The program code may be implemented in a high level procedural or object oriented programming language to communicate with a processing system. The program code may also be implemented in assembly or machine language, as desired. Indeed, the mechanisms described herein are not limited in scope to any particular programming language. In any case, the language may be a compiled or interpreted language.

[0191] One or more aspects of at least one embodiment may be implemented by representative instructions stored on a machine-readable medium that represent various logic within a processor that, when loaded by a machine, causes the machine to assemble logic to perform the techniques described herein. Such representations, known as "IP cores," may be stored on tangible machine-readable media and supplied to various customers or manufacturing facilities for loading into manufacturing machines that actually produce the logic or processors.

[0192] Such machine-readable storage media may include, but are not limited to, non-transitory tangible configurations of articles manufactured or formed by a machine or device, including storage media such as hard disks, floppy disks, optical disks, compact disk-read only memory (CD-ROM), compact disk-rewriteable (CD-RW), and any other type of disk, including magneto-optical disks, semiconductor devices such as read-only memory (ROM), random access memory (RAM), such as dynamic random access memory (DRAM), static random access memory (SRAM), erasable programmable read-only memory (EPROM), flash memory, electrically erasable programmable read-only memory (EEPROM), phase change memory (PCM), magnetic or optical cards, or any other type of medium suitable for storing electronic instructions.

[0193] Accordingly, embodiments of the present disclosure further include a non-transitory, tangible, machine-readable medium that includes instructions or design data, such as a hardware description language (HDL), that defines functions of the structures, circuits, devices, processors and / or systems described herein. Such embodiments may also be referred to as a program product. [Emulation (including binary conversion, code, morphing, etc.)]

[0194] In some cases, an instruction converter may be used to convert instructions from a source instruction set to a target instruction set. For example, the instruction converter may translate, morph, emulate, or otherwise convert (e.g., using static binary translation, dynamic binary translation including dynamic compilation), instructions into one or more other instructions to be processed by the core. The instruction converter may be implemented in software, hardware, firmware, or a combination thereof. The instruction converter may be on-processor, off-processor, or partially on-processor and partially off-processor.

[0195] 19 is a block diagram contrasting the use of a software instruction converter to convert binary instructions of a source instruction set into binary instructions of a target instruction set, according to embodiments of the present disclosure. In the illustrated embodiment, the instruction converter is a software instruction converter, but alternatively, the instruction converter may be implemented in software, firmware, hardware, or various combinations thereof. FIG. 19 illustrates that a program in a high-level language 1902 may be compiled using an x86 compiler 1904 to generate x86 binary code 1906 that may be natively executed by a processor 1916 having at least one x86 instruction set core. Processor with at least one x86 instruction set core 1916 represents any processor that may perform substantially the same functions as an Intel processor with at least one x86 instruction set core by compatibly executing or otherwise processing (1) a majority of the instruction set of an Intel x86 instruction set core, or (2) object code versions of applications or other software intended to run on an Intel processor with at least one x86 instruction set core, to achieve substantially the same results as an Intel processor with at least one x86 instruction set core. x86 compiler 1904 represents a compiler operable to generate x86 binary code 1906 (e.g., object code) that may be executed on processor with at least one x86 instruction set core 1916, with or without additional linkage processing.Similarly, Figure 19 shows that a program in high level language 1902 may be compiled using an alternative instruction set compiler 1908 that generates alternative instruction set binary code 1910 that may be natively executed by a processor 1914 that does not have at least one x86 instruction set core (e.g., a processor that executes the MIPS instruction set from MIPS Technologies of Sunnyvale, Calif. and / or has a core that executes the ARM instruction set from ARM Holdings of Sunnyvale, Calif.). An instruction converter 1912 is used to convert the x86 binary code 1906 into code that is natively executable by a processor 1914 that does not have an x86 instruction set core. This converted code is unlikely to be the same as the alternative instruction set binary code 1910 because it would be difficult to manufacture an instruction converter that could achieve this. However, the converted code implements common operations and is composed of instructions in the alternative instruction set. Thus, the instruction converter 1912 represents software, firmware, hardware, or a combination thereof that enables a processor or other electronic device that does not have an x86 instruction set processor or core to execute the x86 binary code 1906 through emulation, simulation, or any other process. [Other possible claims] The following claims are possible: [Item 1] a processor core that accesses a memory and a cache that stores cache lines; a prefetch circuit for prefetching cache lines from the memory into the cache, Tracking cache line accesses and pages to said cache for single access signatures; generating, for said cache line accesses for each page of the plurality of pages, a spatial bit pattern that is shifted into a first cache line access for each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single access signature; a prefetch circuit for performing a prefetch operation on the prefetch request using the first modulated bit pattern if a threshold has not been exceeded and using the second modulated bit pattern if a threshold has been exceeded; An apparatus comprising: [Item 2] The single access signature is a single instruction pointer value. Item 1. The device according to item 1. [Item 3] The prefetch request has a miss on data in the cache. Item 1. The device according to item 1. [Item 4] the threshold is a bandwidth utilization threshold for the memory; Item 1. The device according to item 1. [Item 5] the prefetch circuit further updates the first modulated bit pattern with a result of a logical OR operation between the first modulated bit pattern and an actual program access bit pattern for the single access signature. Item 1. The device according to item 1. [Item 6] The actual program access bit pattern is for a victim page buffer entry. Item 5. The apparatus according to item 5. [Item 7] the pre-fetch circuit further updates the second modulated bit pattern with a result of ANDing the first modulated bit pattern with the actual program access bit pattern for the single access signature. Item 5. The apparatus according to item 5. [Item 8] the pre-fetch circuit further updates the second modulated bit pattern with a result of ANDing the first modulated bit pattern with an actual program access bit pattern for the single access signature. Item 1. The device according to item 1. [Item 9] accessing, by a processor, a cache storing the cache line; tracking cache line accesses and pages to said cache for a single access signature; generating, for each of the cache line accesses for each of the plurality of pages, a spatial bit pattern that is shifted into a first cache line access for each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; performing a prefetch operation on the prefetch request using the first modulated bit pattern if the threshold has not been exceeded and using the second modulated bit pattern if the threshold has been exceeded to prefetch a cache line from memory into the cache; A method comprising: [Item 10] The single access signature is a single instruction pointer value. Item 9. The method according to item 9. [Item 11] the prefetch request includes a miss of data in the cache. Item 9. The method according to item 9. [Item 12] setting the threshold as a bandwidth utilization threshold for the memory. Item 9. The method according to item 9. [Item 13] updating the first modulation bit pattern with a result of a logical OR operation between the first modulation bit pattern and an actual program access bit pattern for the single access signature. Item 9. The method according to item 9. [Item 14] The actual program access bit pattern is for a victim page buffer entry. Item 14. The method according to item 13. [Item 15] updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with the actual program access bit pattern for the single access signature. Item 14. The method according to item 13. [Item 16] updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with an actual program access bit pattern for the single access signature; Item 9. The method according to item 9. [Item 17] When executed by a machine, the machine: accessing, by a processor, a cache storing the cache line; tracking cache line accesses and pages to said cache for a single access signature; generating, for said cache line accesses for each page of a plurality of pages, a spatial bit pattern that is shifted into a first cache line access of each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; performing a prefetch operation on the prefetch request using the first modulated bit pattern if the threshold has not been exceeded and using the second modulated bit pattern if the threshold has been exceeded to prefetch a cache line from memory into the cache; storing program code for executing a method having the steps of: Non-transitory machine-readable medium. [Item 18] The single access signature is a single instruction pointer value. Item 18. The non-transitory machine-readable medium of item 17. [Item 19] the prefetch request includes a miss of data in the cache. Item 18. The non-transitory machine-readable medium of item 17. [Item 20] The method further comprises setting the threshold as a bandwidth utilization threshold for the memory. Item 18. The non-transitory machine-readable medium of item 17. [Item 21] The method further comprises updating the first modulation bit pattern with a result of ORing the first modulation bit pattern with an actual program access bit pattern for the single access signature. Item 18. The non-transitory machine-readable medium of item 17. [Item 22] The actual program access bit pattern is for a victim page buffer entry. 22. The non-transitory machine-readable medium of item 21. [Item 23] The method further comprises updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with the actual program access bit pattern for the single access signature. 22. The non-transitory machine-readable medium of item 21. [Item 24] The method further comprises updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with an actual program access bit pattern for the single access signature. Item 18. The non-transitory machine-readable medium of item 17.

Claims

1. a processor core that accesses a memory and a cache that stores cache lines; a prefetch circuit for prefetching a cache line from the memory into the cache, tracking cache line accesses and pages to the cache for single access signatures; generating, for said cache line accesses for each page of a plurality of pages, a spatial bit pattern that is shifted into a first cache line access for each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having an identical spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; a prefetch circuit that performs a prefetch operation on the prefetch request using the first modulated bit pattern if a threshold has not been exceeded and using the second modulated bit pattern if a threshold has been exceeded; An apparatus comprising:

2. the single access signature is a single instruction pointer value; 2. The apparatus of claim 1.

3. the prefetch request comprises a miss for data in the cache; 3. Apparatus according to claim 1 or 2.

4. the threshold is a bandwidth utilization threshold of the memory; 4. Apparatus according to any one of claims 1 to 3.

5. the prefetch circuit further updates the first modulated bit pattern with a result of ORing the first modulated bit pattern with an actual program access bit pattern for the single-access signature.

5. Apparatus according to any one of claims 1 to 4.

6. the actual program access bit pattern is for a victim page buffer entry; 6. The apparatus of claim 5.

7. the prefetch circuit further updates the second modulated bit pattern with a result of ANDing the first modulated bit pattern with the actual program access bit pattern for the single access signature.

7. Apparatus according to claim 5 or 6.

8. the prefetch circuit further updates the second modulated bit pattern with a result of ANDing the first modulated bit pattern with an actual program access bit pattern for the single access signature.

5. Apparatus according to any one of claims 1 to 4.

9. accessing, by a processor, a cache storing the cache line; tracking cache line accesses and pages to the cache for a single access signature; generating, for each of the cache line accesses of a plurality of pages, a spatial bit pattern that is shifted into a first cache line access for each of the pages; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having the same spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; performing a prefetch operation on the prefetch request using the first modulated bit pattern if a threshold has not been exceeded and using the second modulated bit pattern if the threshold has been exceeded to prefetch a cache line from memory into the cache; A method comprising:

10. the single access signature is a single instruction pointer value; 10. The method of claim 9.

11. the prefetch request includes a miss of data in the cache.

11. The method according to claim 9 or 10.

12. setting the threshold as a bandwidth utilization threshold for the memory.

12. The method according to any one of claims 9 to 11.

13. updating the first modulation bit pattern with a result of ORing the first modulation bit pattern with an actual program access bit pattern for the single access signature.

13. The method according to any one of claims 9 to 12.

14. the actual program access bit pattern is for a victim page buffer entry; The method of claim 13.

15. updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with the actual program access bit pattern for the single access signature.

15. The method according to claim 13 or 14.

16. updating the second modulation bit pattern with a result of ANDing the first modulation bit pattern with an actual program access bit pattern for the single access signature.

13. The method according to any one of claims 9 to 12.

17. When executed by a processor, the processor a step of accessing a cache that stores the cache line; tracking cache line accesses and pages to said cache for a single access signature; generating, for said cache line accesses for each page of a plurality of pages, a spatial bit pattern that is shifted into a first cache line access of each page; generating a single spatial bit pattern for the single access signature for each of the spatial bit patterns having an identical spatial bit pattern to form a plurality of single spatial bit patterns; performing a logical OR operation on the plurality of single spatial bit patterns to generate a first modulated bit pattern for the single access signature; performing a logical AND operation on the plurality of single spatial bit patterns to generate a second modulated bit pattern for the single access signature; receiving a prefetch request for the single-access signature; performing a prefetch operation on the prefetch request using the first modulated bit pattern if a threshold has not been exceeded and using the second modulated bit pattern if the threshold has been exceeded to prefetch a cache line from memory into the cache; A program for executing the program.

18. the single access signature is a single instruction pointer value; 18. The program according to claim 17.

19. the prefetch request includes a miss of data in the cache.

19. The program according to claim 17 or 18.

20. The program further causes the processor to execute a procedure of setting the threshold as a bandwidth utilization threshold for the memory.

20. The program according to any one of claims 17 to 19.

21. The program further causes the processor to execute a procedure of updating the first modulation bit pattern with a result of a logical OR operation between the first modulation bit pattern and an actual program access bit pattern for the single-access signature.

21. The program according to any one of claims 17 to 20.

22. the actual program access bit pattern is for a victim page buffer entry; 22. The program of claim 21.

23. The program further causes the processor to execute a procedure of updating the second modulation bit pattern with a result of a logical AND operation of the first modulation bit pattern and the actual program access bit pattern for the single access signature.

23. The program according to claim 21 or 22.

24. The program further causes the processor to execute a procedure of updating the second modulation bit pattern with a result of a logical AND operation between the first modulation bit pattern and an actual program access bit pattern for the single access signature.

21. The program according to any one of claims 17 to 20.

25. A computer readable storage medium storing a program according to any one of claims 17 to 24.

Citation Information

Patent Citations

  • Apparatus and method for prefetching data

    JP2009540429A

  • System and method for spatial memory streaming training

    US20180329823A1

  • Prefetch performance

    US20180341591A1