Allocating sizes for multiple registers for GPU hardware threads
By introducing thread-by-thread variable register features into the graphics processor, the problem of inflexible register allocation in the prior art is solved, and higher execution performance and more efficient resource utilization are achieved.
Patent Information
- Application Number
- CN202411370819.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2023-11-08
- Filing Date
- 2024-09-29
- Publication Date
- 2025-05-09
AI Technical Summary
When existing graphics processors deal with multithreading, register allocation is not flexible enough, resulting in poor execution performance and register overflow filling problems.
The thread-by-thread variable register (VRT) feature is introduced, allowing different register allocation policies to be defined at each shader stage and adjusted for the specific workload.
Through flexible register allocation, execution performance is improved, register overflow and fill is reduced, and resource utilization is optimized.
Smart Images

Figure CN119963394A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates generally to data processing via a graphics processor, and more particularly, to a method for enabling multiple register allocation sizes for a hardware thread of a graphics processor. Background Art
[0002] Graphics processor architectures include larger register files and support a greater number of concurrent threads relative to general purpose processors (such as central processing units). Conventional graphics processor architectures generally have a fixed relationship between the number of registers that can be used concurrently by hardware threads. This relationship is generally related to the number of registers within the register file and the maximum number of hardware threads that can be concurrently active within the processing resources of the graphics processor. These values are balanced within a given architecture to support a variety of workloads, but may not be optimal for any particular workload. BRIEF DESCRIPTION OF THE DRAWINGS
[0003] The embodiments described herein are illustrated by way of example and not by way of limitation in the figures of the accompanying drawings in which like reference numerals indicate similar elements, and in which:
[0004] Figure 1 is a block diagram illustrating a computer system configured to implement one or more aspects of the embodiments described herein;
[0005] Figure 2A-2D illustrates parallel processor components;
[0006] Figure 3A-3C is a block diagram of a graphics multiprocessor and a multiprocessor-based GPU;
[0007] Figure 4A-4F illustrates an exemplary architecture in which multiple GPUs are communicatively coupled to multiple multi-core processors;
[0008] Figure 5 Diagram of the graphics processing pipeline;
[0009] Figure 6 Diagram of the machine learning software stack;
[0010] Figure 7 Illustration of a general purpose graphics processing unit;
[0011] Figure 8 Diagram of a multi-GPU computing system;
[0012] Figure 9A-9B illustrates the layers of an exemplary deep neural network;
[0013] Fig.10 illustrates an exemplary recurrent neural network;
[0014] Fig.11 Illustration of the training and deployment of deep neural networks;
[0015] Fig. 12A is a block diagram illustrating distributed learning;
[0016] Fig. 12B is a block diagram illustrating a programmable network interface and a data processing unit;
[0017] Fig.13 An exemplary inference system on a chip (SOC) suitable for performing inference using a trained model is illustrated;
[0018] Fig.14 is a block diagram of the processing system;
[0019] Figure 15A-Figure 15C Graphics computing systems and graphics processors;
[0020] Figure 16A-16C A block diagram illustrating an additional graphics processor and computing accelerator architecture;
[0021] Fig.17 is a block diagram of a graphics processing engine of a graphics processor;
[0022] Figures 18A-18C illustrates thread execution logic including an array of processing elements employed in a graphics processor core;
[0023] Fig.19 illustrates a slice of a multi-chip processor according to an embodiment;
[0024] Fig. 20 is a block diagram illustrating a graphics processor instruction format;
[0025] Fig.21 is a block diagram of the attached graphics processor architecture;
[0026] Figure 22A-22B Illustrate the graphics processor command format and command sequence;
[0027] Fig.23 illustrates an exemplary graphical software architecture for a data processing system;
[0028] Fig.24A is a block diagram illustrating an IP core development system;
[0029] Fig. 24B A cross-sectional side view of an integrated circuit package assembly is shown;
[0030] Fig.24Cillustrates a package assembly including a hardware logic chiplet of multiple units connected to a substrate (e.g., base die);
[0031] Fig.24D The illustration includes a package assembly including interchangeable chiplets;
[0032] Fig.25 is a block diagram illustrating an exemplary system-on-chip integrated circuit;
[0033] Figure 26A-26B is a block diagram illustrating an exemplary graphics processor for use within a SoC;
[0034] Fig. 27 is a block diagram of a data processing system according to an embodiment;
[0035] Fig.28 is a block diagram of a system including a GPGPU device, wherein a processing resource has a variable number of threads and per-thread registers;
[0036] Fig.29 illustrates a processing resource architecture according to an embodiment;
[0037] Fig.30 illustrates a system for performing register and accumulator allocation under a VRT according to an embodiment;
[0038] Fig.31 A register file allocation and tracking system according to an embodiment is shown;
[0039] Fig.32 A system for logical register to physical register conversion for VRT according to an embodiment is shown;
[0040] Figure 33A-Figure 33B A flowchart is shown for processing thread dispatch on resources;
[0041] Fig.34 illustrates configurable performance monitoring circuitry of a graphics core according to an embodiment;
[0042] Fig.35 shows examples of processing resources with different thread configurations and performance monitoring circuitry according to an embodiment;
[0043] Fig.36 A method for tracking thread dispatch stalls due to insufficient resources or fragmentation is shown; and
[0044] Fig.37 is a block diagram of a computing device including a graphics processor according to an embodiment. DETAILED DESCRIPTION
[0045] Current parallel graphics data processing includes systems and methods developed to perform specific operations on graphics data, such as, for example, linear interpolation, tessellation, rasterization, texture mapping, depth testing, etc. Traditionally, graphics processors use fixed-function computing units to process graphics data. However, more recently, multiple parts of graphics processors have been made programmable, enabling such processors to support a wider variety of operations to process vertex data and fragment data. In order to further improve performance, graphics processors typically implement processing techniques such as pipelining, which attempt to process as much graphics data as possible in parallel throughout different parts of the graphics pipeline. Parallel graphics processors with a single instruction, multiple thread (SIMT) architecture are designed to maximize the amount of parallel processing in the graphics pipeline. In the SIMT architecture, groups of parallel threads attempt to execute program instructions together synchronously as frequently as possible to improve processing efficiency.
[0046] A graphics processing unit (GPU) is communicatively coupled to a host / processor core to accelerate, for example, graphics operations, machine learning operations, pattern analysis operations, and / or various general-purpose GPU (GPGPU) functions. The GPU may be communicatively coupled to a host processor / core via a bus or another interconnect (e.g., a high-speed interconnect such as PCIe or NVLink). Alternatively, the GPU may be integrated on the same package or chip as the core and communicatively coupled to the core via an internal processor bus / interconnect (i.e., inside the package or chip). Regardless of the manner in which the GPU is connected, the processor core may assign work to the GPU in the form of a sequence of commands / instructions contained in a work descriptor. The GPU then uses dedicated circuits / logic to efficiently process these commands / instructions.
[0047] In the following description, numerous specific details are set forth to provide a more thorough understanding. However, it will be apparent to those skilled in the art that the embodiments described herein may be practiced without one or more of these specific details. In other instances, well-known features are not described to avoid obscuring the details of the current embodiments.
[0048] Described herein is a technique for enabling multiple register allocation sizes for hardware threads of a graphics processor. In one embodiment, a variable registers per thread (VRT) feature is enabled in a graphics processor to enable the number of active hardware threads in a processing resource and the number of registers assigned to those threads. The VRT specification can be defined on the basis of each shader stage and can be adjusted for a specific workload to be executed. When properly adjusted for the workload, this feature can improve execution performance and reduce register overflow / filling during execution. Additionally, a shader compiler can reduce the situation of over-allocation of registers. For example, a vertex shader may only require 32 or 64 registers, while a pixel shader may require 160 registers. System Overview
[0049] Figure 1 1 is a block diagram illustrating a computing system 100 configured to implement one or more aspects of the embodiments described herein. The computing system 100 includes a processing subsystem 101 having one or more processors 102 and a system memory 104 communicating via an interconnect path, which may include a memory hub 105. The memory hub 105 may be a separate component within a chipset component, or may be integrated within one or more processors 102. The memory hub 105 is coupled to an I / O subsystem 111 via a communication link 106. The I / O subsystem 111 includes an I / O hub 107, which may enable the computing system 100 to receive input from one or more input devices 108. In addition, the I / O hub 107 may enable a display controller (which may be included in one or more processors 102) to provide output to one or more display devices 110A. In one embodiment, the one or more display devices 110A coupled to the I / O hub 107 may include local, internal, or embedded display devices.
[0050] The processing subsystem 101 includes, for example, one or more parallel processors 112 coupled to the memory hub 105 via a bus or other communication link 113. The communication link 113 can be one of any number of standard-based communication link technologies or protocols, such as but not limited to PCI Express, or can be a vendor-specific communication interface or communication fabric. The one or more parallel processors 112 can form a parallel or vector processing system in a computational concentration that can include a large number of processing cores and / or processing clusters, such as, for example, a many integrated core (MIC) processor. For example, the one or more parallel processors 112 form a graphics processing subsystem that can output pixels to one of the one or more display devices 110A coupled via the I / O hub 107. The one or more parallel processors 112 may also include a display controller and a display interface (not shown) for enabling direct connection to one or more display devices 110B.
[0051] Within the I / O subsystem 111, a system storage unit 114 may be connected to the I / O hub 107 to provide a storage mechanism for the computing system 100. An I / O switch 116 may be used to provide an interface mechanism to enable connections between the I / O hub 107 and other components, such as a network adapter 118 and / or a wireless network adapter 119 that may be integrated into the platform, and various other devices that may be added via one or more plug-in devices 120. The plug-in device(s) 120 may also include, for example, one or more external graphics processor devices, graphics cards, and / or computing accelerators. The network adapter 118 may be an Ethernet adapter or another wired network adapter. The wireless network adapter 119 may include one or more of the following: Wi-Fi, Bluetooth, near field communication (NFC), or other network devices including one or more wireless radio devices.
[0052] The computing system 100 may include other components not explicitly shown, including USB or other port connections, optical storage drives, video capture devices, etc., which may also be connected to the I / O hub 107. Figure 1 The communication paths for interconnecting the various components in the system may be implemented using any suitable protocol, such as a PCI (Peripheral Component Interconnect) based protocol (e.g., PCI Express), or any other bus or point-to-point communication interface and / or protocol(s), such as NVLink high-speed interconnect, Compute Express Link, or the like. TM (ComputeExpress LinkTM , CXL TM ) (e.g., CXL.mem), Infinity Fabric (IF), Ethernet (IEEE802.3), remote direct memory access (RDMA), InfiniBand, Internet Wide Area RDMA Protocol (iWARP), Transmission Control Protocol (TCP), User Datagram Protocol (UDP), quick UDP Internet Connections (QUIC), RDMA over Converged Ethernet (RoCE), Intel Quick Path Interconnect (QPI), Intel Ultra Path Interconnect (UPI), Intel On-Chip System Fabric (IOSF), Omnipath, HyperTransport, Advanced Microcontroller Bus Architecture (AMBA) interconnect, OpenCAPI, Gen-Z, Cache Coherent Interconnect for Accelerators The data may be copied or stored to a virtualized storage node using protocols such as NVMe (non-volatile memory express over Fabrics, NVME-oF) or NVMe.
[0053] One or more parallel processors 112 may include circuits optimized for graphics and video processing (including, for example, video output circuits) and constitute a graphics processing unit (GPU). Alternatively or additionally, as described in more detail herein, one or more parallel processors 112 may include circuits optimized for general-purpose processing while retaining the underlying computing architecture. Components of the computing system 100 may be integrated on a single integrated circuit with one or more other system elements. For example, one or more parallel processors 112, a memory hub 105, (one or more) processors 102, and an I / O hub 107 may be integrated into a system-on-chip (SoC) integrated circuit. Alternatively, components of the computing system 100 may be integrated into a single package to form a system-in-package (SIP) configuration. In one embodiment, at least a portion of the components of the computing system 100 may be integrated into a multi-chip module (MCM), which may be interconnected with other multi-chip modules into a modular computing system.
[0054] It will be appreciated that the computing system 100 shown herein is illustrative, and variations and modifications are possible. The connection topology, including the number and arrangement of bridges, the number of (one or more) processors 102, and the number of (one or more) parallel processors 112, may be modified as desired. For example, the system memory 104 may be connected to the (one or more) processors 102 directly rather than through a bridge, while other devices communicate with the system memory 104 via the memory hub 105 and the (one or more) processors 102. In other alternative topologies, the (one or more) parallel processors are connected to the I / O hub 107 or directly to one of the one or more processors 102, rather than to the memory hub 105. In other embodiments, the I / O hub 107 and the memory hub 105 may be integrated into a single chip. It is also possible for two or more sets of processors 102 to be attached via multiple slots, which may be coupled to two or more instances of the (one or more) parallel processors 112.
[0055] Some of the specific components shown herein are optional and may not be included in all implementations of computing system 100. For example, any number of plug-in cards or peripherals may be supported, or some components may be eliminated. In addition, some architectures may be specific to the Figure 1 Different terminology is used for components that are similar to those illustrated in FIG. 1. For example, memory hub 105 may be referred to as a north bridge in some architectures, while I / O hub 107 may be referred to as a south bridge.
[0056] Figure 2AThe illustrated parallel processor 200 may be a GPU, a GPGPU, or the like as described herein. The various components of the parallel processor 200 may be implemented using one or more integrated circuit devices, such as a programmable processor, an application specific integrated circuit (ASIC), or a field programmable gate array (FPGA). The illustrated parallel processor 200 may be Figure 1 One or more of the parallel processor(s) 112 shown in FIG.
[0057] Parallel processor 200 includes parallel processing unit 202. Parallel processing unit includes I / O unit 204 that enables communication with other devices, including other instances of parallel processing unit 202. I / O unit 204 can be directly connected to other devices. For example, I / O unit 204 is connected to other devices via the use of a hub or switch interface (such as, memory hub 105). The connection between memory hub 105 and I / O unit 204 forms communication link 113. Within parallel processing unit 202, I / O unit 204 is connected to host interface 206 and memory cross switch 216, wherein host interface 206 receives commands related to performing processing operations and memory cross switch 216 receives commands related to performing memory operations.
[0058] When the host interface 206 receives the command buffer via the I / O unit 204, the host interface 206 can direct the work operations for executing those commands to the front end 208. In one embodiment, the front end 208 is coupled with a scheduler 210, which is configured to distribute commands or other work items to the processing cluster array 212. The scheduler 210 ensures that the processing cluster array 212 is properly configured and in a valid state before the task is distributed to the processing clusters in the processing cluster array 212. The scheduler 210 can be implemented via firmware logic executed on a microcontroller. The microcontroller-implemented scheduler 210 can be configured to perform complex scheduling and work distribution operations at coarse and fine granularity, thereby achieving fast preemption and context switching of threads executed on the processing cluster array 212. Preferably, the host software can confirm the workload for scheduling on the processing cluster array 212 via one of a plurality of graphics processing doorbells. In other examples, polling for new workloads or interrupts can be used to identify or indicate the availability of work to be executed. The workload may then be automatically distributed across the processing cluster array 212 by the scheduler 210 logic within the scheduler microcontroller.
[0059] The processing cluster array 212 may include up to "N" processing clusters (e.g., cluster 214A, cluster 214B to cluster 214N). Each cluster 214A-214N in the processing cluster array 212 may execute a large number of concurrent threads. The scheduler 210 may allocate work to the clusters 214A-214N in the processing cluster array 212 using various scheduling and / or work distribution algorithms, which may vary depending on the workload generated for each type of program or calculation. Scheduling may be handled dynamically by the scheduler 210, or may be partially assisted by compiler logic during the compilation of program logic configured for execution by the processing cluster array 212. Optionally, different clusters 214A-214N in the processing cluster array 212 may be allocated to process different types of programs or to perform different types of calculations.
[0060] Processing cluster array 212 may be configured to perform various types of parallel processing operations. For example, processing cluster array 212 is configured to perform general-purpose parallel computing operations. For example, processing cluster array 212 may include logic for performing processing tasks including filtering of video and / or audio data, performing modeling operations including physical operations, and performing data transformations.
[0061] Processing cluster array 212 is configured to perform parallel graphics processing operations. In such embodiments where parallel processor 200 is configured to perform graphics processing operations, processing cluster array 212 may include additional logic for supporting the execution of such graphics processing operations, including but not limited to texture sampling logic for performing texture operations, and tessellation logic and other vertex processing logic. In addition, processing cluster array 212 may be configured to execute graphics processing related shader programs, such as but not limited to vertex shaders, tessellation shaders, geometry shaders, and pixel shaders. Parallel processing unit 202 may transfer data from system memory via I / O unit 204 for processing. During processing, the transferred data may be stored in on-chip memory (e.g., parallel processor memory 222) during processing, and then the data may be written back to system memory.
[0062] In embodiments where parallel processing units 202 are used to perform graphics processing, scheduler 210 may be configured to divide the processing workload into tasks of approximately equal size to better enable distribution of graphics processing operations to multiple clusters 214A-214N in processing cluster array 212. In some of these embodiments, portions of processing cluster array 212 may be configured to perform different types of processing. For example, a first portion may be configured to perform vertex shading and topology generation, a second portion may be configured to perform tessellation and geometry shading, and a third portion may be configured to perform pixel shading or other screen space operations to produce a rendered image for display. Intermediate data generated by one or more of clusters 214A-214N may be stored in a buffer to allow the intermediate data to be transferred between clusters 214A-214N for further processing.
[0063] During operation, the processing cluster array 212 may receive processing tasks to be executed via the scheduler 210, which receives commands defining the processing tasks from the front end 208. For graphics processing operations, the processing tasks may include data to be processed, such as surface (patch) data, primitive data, vertex data, and / or pixel data, and state parameters and commands defining how the data is to be processed (e.g., what program is to be executed). The scheduler 210 may be configured to fetch an index corresponding to the task, or may receive the index from the front end 208. The front end 208 may be configured to ensure that the processing cluster array 212 is configured to a valid state before a workload specified by an incoming command buffer (e.g., a batch buffer, a push buffer, etc.) is initiated.
[0064] Each of the one or more instances of the parallel processing unit 202 may be coupled to a parallel processor memory 222. The parallel processor memory 222 may be accessed via a memory crossbar switch 216, which may receive memory requests from the processing cluster array 212 and the I / O unit 204. The memory crossbar switch 216 may access the parallel processor memory 222 via a memory interface 218. The memory interface 218 may include a plurality of partition units (e.g., partition unit 220A, partition unit 220B, up to partition unit 220N), each of which may be coupled to a portion (e.g., a memory unit) of the parallel processor memory 222. The number of partition units 220A-220N may be configured to be equal to the number of memory units, such that the first partition unit 220A has a corresponding first memory unit 224A, the second partition unit 220B has a corresponding second memory unit 224B, and the Nth partition unit 220N has a corresponding Nth memory unit 224N. In other embodiments, the number of partition units 220A-220N may not be equal to the number of memory devices.
[0065] The memory units 224A-224N may include various types of memory devices, including dynamic random-access memory (DRAM) or graphics random access memory, such as synchronous graphics random access memory (SGRAM), including graphics double data rate (GDDR) memory. Optionally, the memory units 224A-224N may also include 3D stacked memory, including but not limited to high bandwidth memory (HBM). Those skilled in the art will appreciate that the specific implementation of the memory units 224A-224N may vary and may be selected from one of a variety of conventional designs. Rendering targets such as frame buffers or texture maps may be stored across the memory units 224A-224N, thereby allowing the partition units 220A-220N to write portions of each rendering target in parallel to efficiently use the available bandwidth of the parallel processor memory 222. In some embodiments, local instances of the parallel processor memory 222 may be eliminated in favor of utilizing a unified memory design of the system memory in conjunction with local cache memory.
[0066] Optionally, any of the clusters 214A-214N in the processing cluster array 212 has the capability to process data to be written to any of the memory units 224A-224N within the parallel processor memory 222. The memory crossbar 216 may be configured to transmit the output of each cluster 214A-214N to any partition unit 220A-220N or to another cluster 214A-214N, which may perform additional processing operations on the output. Each cluster 214A-214N may communicate with a memory interface 218 through the memory crossbar 216 to read from or write to various external memory devices. In one embodiment of an embodiment having a memory crossbar switch 216, the memory crossbar switch 216 has connections to a memory interface 218 to communicate with the I / O unit 204 and has connections to a local instance of a parallel processor memory 222, thereby enabling processing units within different processing clusters 214A-214N to communicate with system memory or other memory that is not local to the parallel processing unit 202. In general, the memory crossbar switch 216 may be able to separate traffic flows between the clusters 214A-214N and the partition units 220A-220N using virtual channels, for example.
[0067] Although a single instance of parallel processing unit 202 is illustrated within parallel processor 200, any number of instances of parallel processing unit 202 may be included. For example, multiple instances of parallel processing unit 202 may be provided on a single plug-in card, or multiple plug-in cards may be interconnected. For example, parallel processor 200 may be a plug-in device, such as, Figure 1 Plug-in device 120, which can be a graphics card (such as a discrete graphics card including one or more GPUs, one or more memory devices, and device-to-device or network or structure interfaces). Different instances of parallel processing unit 202 can be configured to interoperate even if different instances have different numbers of processing cores, different amounts of local parallel processor memory, and / or other configuration differences. Optionally, some instances of parallel processing unit 202 may include higher precision floating point units relative to other instances. Systems including one or more instances of parallel processing unit 202 or parallel processor 200 can be implemented in various configurations and form factors, including but not limited to desktop computers, laptop computers, or handheld personal computers, servers, workstations, game consoles, and / or embedded systems. The orchestrator can use one or more of the following to form a composite node for workload execution: decomposed processor resources, cache resources, memory resources, storage resources, and networking resources.
[0068] In one embodiment, parallel processing unit 202 can be partitioned into multiple instances. Those multiple instances can be configured to execute workloads associated with different clients in an isolated manner, so that a predetermined quality of service is provided for each client. For example, each cluster 214A-214N can be partitioned and isolated from other clusters, thereby allowing processing cluster array 212 to be partitioned into multiple computing partitions or instances. In such configurations, the workload executed on the isolated partition is protected from errors or errors associated with different workloads executed on different partitions. Partition units 220A-220N can be configured to enable dedicated paths and / or isolated paths to the memory of the cluster 214A-214N associated with the corresponding computing partition. This data path isolation enables the computing resources in the partition to communicate with one or more assigned memory units 224A-224N without being disturbed by the activities of other partitions.
[0069] Figure 2B is a block diagram of the partition unit 220. The partition unit 220 may be Figure 2A 220N, and a partition unit 220A-220N. As shown, the partition unit 220 includes an L2 cache 221, a frame buffer interface 225, and a ROP 226 (raster operation unit). The L2 cache 221 is a read / write cache configured to perform load and store operations received from the memory crossbar switch 216 and the ROP 226. Read misses and urgent writeback requests are output by the L2 cache 221 to the frame buffer interface 225 for processing. Updates can also be sent to the frame buffer via the frame buffer interface 225 for processing. In one embodiment, the frame buffer interface 225 is connected to the frame buffer interface 225. Figure 2A The partition unit 220 may also interface with a memory unit 224 in the memory units 224A-224N in the parallel processor memory 222. The partition unit 220 may also additionally or alternatively interface with one of the memory units in the parallel processor memory via a memory controller (not shown).
[0070] In graphics applications, ROP 226 is a processing unit that performs raster operations such as stenciling, z-testing, blending, etc. ROP 226 then outputs processed graphics data, which is stored in graphics memory. In some embodiments, ROP 226 includes or is coupled to a codec (CODEC) 227 that includes compression logic for compressing depth or color data written to memory or L2 cache 221 and decompressing depth or color data read from memory or L2 cache 221. The compression logic may be lossless compression logic that utilizes one or more of a variety of compression algorithms. The type of compression performed by CODEC 227 may vary based on the statistical characteristics of the data to be compressed. For example, in one embodiment, delta color compression is performed on depth and color data on a slice-by-slice basis. In one embodiment, CODEC 227 includes compression and decompression logic that can compress and decompress computational data associated with machine learning operations. CODEC 227 can, for example, compress sparse matrix data for sparse machine learning operations. CODEC 227 can also compress sparse matrix data encoded in a sparse matrix format (e.g., coordinate list encoding (COO), compressed sparse row (CSR), compressed sparse column (CSC), etc.) to generate compressed and encoded sparse matrix data. Compressed and encoded sparse matrix data can be decompressed and / or decoded before being processed by a processing element, or a processing element can be configured to consume compressed, encoded, or compressed and encoded data for processing.
[0071] ROP 226 may be included in each processing cluster (e.g., Figure 2A 214A-214N) rather than being included in partition unit 220. In such embodiments, read and write requests for pixel data rather than pixel fragment data are transmitted through memory crossbar switch 216. The processed graphics data may be displayed on a display device such as a Figure 1 10B), is routed for further processing by the processor(s) 102, or is routed for processing by the processor(s) 102. Figure 2A The processing is further processed by one of the processing entities within the parallel processor 200.
[0072] Figure 2Cis a block diagram of a processing cluster 214 within a parallel processing unit. For example, a processing cluster is Figure 2A An instance of a processing cluster in the processing clusters 214A-214N. The processing cluster 214 may be configured to execute many threads in parallel, wherein the term "thread" refers to an instance of a specific program executed on a set of specific input data. Optionally, a single-instruction, multiple-data (SIMD) instruction issuance technique may be used to support the parallel execution of a large number of threads without providing multiple independent instruction units. Alternatively, a single-instruction, multiple-thread (SIMT) technique may be used to support the parallel execution of a large number of threads that are generally synchronized using a common instruction unit configured to issue instructions to a set of processing engines within each processing cluster in the processing cluster. Unlike the SIMD execution mechanism in which all processing engines typically execute the same instruction, SIMT execution allows different threads to more easily follow the divergent execution path through a given thread program. It will be appreciated by those skilled in the art that the SIMD processing mechanism represents a functional subset of the SIMT processing mechanism.
[0073] The operation of the processing cluster 214 may be controlled via a pipeline manager 232 that distributes processing tasks to SIMT parallel processors. The pipeline manager 232 receives requests from Figure 2A The graphics multiprocessor 234 may be configured to receive instructions from the scheduler 210 of the graphics multiprocessor 210, and manage the execution of those instructions via the graphics multiprocessor 234 and / or the texture unit 236. The illustrated graphics multiprocessor 234 is an exemplary instance of a SIMT parallel processor. However, various types of SIMT parallel processors of different architectures may be included within the processing cluster 214. One or more instances of the graphics multiprocessor 234 may be included within the processing cluster 214. The graphics multiprocessor 234 may process data, and the data crossbar 240 may be used to distribute the processed data to one of a plurality of possible destinations, including facilitating data exchange between graphics multiprocessors within the processing cluster 214. The pipeline manager 232 may facilitate the distribution of processed data by specifying a destination for the processed data to be distributed via the data crossbar 240.
[0074] Each graphics multiprocessor 234 within a processing cluster 214 may include an identical set of function execution logic (e.g., arithmetic logic units, load-store units, etc.). The function execution logic may be configured in a pipelined manner in which new instructions may be issued before previous instructions are completed. The function execution logic supports a variety of operations, including integer and floating point arithmetic, comparison operations, Boolean operations, bit shifts, and calculation of various algebraic functions. The same functional unit hardware may be utilized to perform different operations, and any combination of functional units may exist.
[0075] The instructions transmitted to the processing cluster 214 constitute threads. A collection of threads executed across a collection of parallel processing engines is a thread group. A thread group executes the same program on different input data. Each thread within a thread group can be assigned to a different processing engine within the graphics multiprocessor 234. A thread group may include fewer threads than the number of processing engines within the graphics multiprocessor 234. When a thread group includes fewer threads than the number of processing engines, one or more of the processing engines may be idle during the cycle during which the thread group is being processed. A thread group may also include more threads than the number of processing engines within the graphics multiprocessor 234. When a thread group includes more threads than the number of processing engines within the graphics multiprocessor 234, processing may be performed in consecutive clock cycles. Optionally, multiple thread groups may be executed concurrently on the graphics multiprocessor 234.
[0076] The graphics multiprocessor 234 may include internal cache memory to perform load and store operations. Optionally, the graphics multiprocessor 234 may forgo the internal cache and use cache memory (e.g., first level (level 1, L1) cache 248) within the processing cluster 214. Each graphics multiprocessor 234 also has a partition unit (e.g., Figure 2A 220A-220N), which are shared between all processing clusters 214 and can be used to transfer data between threads. Graphics multiprocessor 234 can also access off-chip global memory, which can include one or more of local parallel processor memory and / or system memory. Any memory external to parallel processing unit 202 can be used as global memory. Embodiments in which processing cluster 214 includes multiple instances of graphics multiprocessor 234 can share common instructions and data, which can be stored in L1 cache 248.
[0077] Each processing cluster 214 may include an MMU 245 (memory management unit) configured to map virtual addresses to physical addresses. In other embodiments, one or more instances of MMU 245 may reside in Figure 2A 218. The MMU 245 includes a set of page table entries (PTEs) for mapping virtual addresses to physical addresses of the slice, and optionally includes a cache line index. The MMU 245 may include an address translation lookaside buffer (TLB) or cache that may reside within the graphics multiprocessor 234 or L1 cache 248 of the processing cluster 214. The physical addresses are processed to distribute surface data access locality, thereby allowing efficient request interleaving between partition units. The cache line index can be used to determine whether a request for a cache line is a hit or a miss.
[0078] In graphics and compute applications, the processing clusters 214 may be configured such that each graphics multiprocessor 234 is coupled to a texture unit 236 for performing texture mapping operations, such as determining texture sample locations, reading texture data, and filtering texture data. Texture data is read from an internal texture L1 cache (not shown), or in some embodiments, from an L1 cache within the graphics multiprocessor 234 and retrieved from an L2 cache, local parallel processor memory, or system memory as needed. Each graphics multiprocessor 234 outputs processed tasks to a data crossbar 240 to provide the processed tasks to another processing cluster 214 for further processing, or to store the processed tasks in an L2 cache, local parallel processor memory, or system memory via a memory crossbar 216. A preROP 242 (pre-raster operations unit) is configured to receive data from the graphics multiprocessor 234, direct the data to ROP units, which may be coupled to partition units (e.g., Figure 2A The preROP 242 unit may perform optimizations for color blending, organize pixel color data, and perform address translation.
[0079] It will be appreciated that the core architecture described herein is illustrative, and variations and modifications are possible. Any number of processing units (e.g., graphics multiprocessor 234, texture unit 236, preROP 242, etc.) may be included within a processing cluster 214. Further, while only one processing cluster 214 is shown, a parallel processing unit as described herein may include any number of instances of a processing cluster 214. Optionally, each processing cluster 214 may be configured to operate independently of other processing clusters 214 using separate and distinct processing units, L1 caches, L2 caches, etc.
[0080] Figure 2DAn example of a graphics multiprocessor 234 is shown, where the graphics multiprocessor 234 is coupled to a pipeline manager 232 of a processing cluster 214. The graphics multiprocessor 234 has an execution pipeline that includes, but is not limited to, an instruction cache 252, an instruction unit 254, an address mapping unit 256, a register file 258, one or more general purpose graphics processing unit (GPGPU) cores 262, and one or more load / store units 266. The GPGPU cores 262 and the load / store units 266 are coupled to a cache memory 272 and a shared memory 270 via a memory and cache interconnect 268. The graphics multiprocessor 234 may additionally include a tensor and / or ray tracing core 263 that includes hardware logic for accelerating matrix and / or ray tracing operations.
[0081] The instruction cache 252 may receive an instruction stream to be executed from the pipeline manager 232. The instructions are cached in the instruction cache 252 and dispatched for execution by the instruction unit 254. The instruction unit 254 may dispatch the instructions as a thread group (e.g., a unit group (warp)), wherein each thread in the thread group is assigned to a different execution unit within the GPGPU core 262. The instruction may access any of the local address space, the shared address space, or the global address space by specifying an address within the unified address space. The address mapping unit 256 may be used to translate the address in the unified address space into different memory addresses that can be accessed by the load / store unit 266.
[0082] The register file 258 provides a collection of registers for the functional units of the graphics multiprocessor 234. The register file 258 provides temporary storage for operands of data paths of the functional units (e.g., GPGPU core 262, load / store unit 266) connected to the graphics multiprocessor 234. The register file 258 may be divided between each of the functional units so that each functional unit is assigned a dedicated portion of the register file 258. For example, the register file 258 may be divided between different groups of units executed by the graphics multiprocessor 234.
[0083] The GPGPU cores 262 may each include a floating point unit (FPU) and / or an integer arithmetic logic unit (ALU) for executing instructions of the graphics multiprocessor 234. In some implementations, the GPGPU cores 262 may include hardware logic that may otherwise reside within the tensor and / or ray tracing cores 263. The GPGPU cores 262 may be similar in architecture, or may be different in architecture. For example and in one embodiment, the first portion of the GPGPU core 262 includes a single-precision FPU and an integer ALU, while the second portion of the GPGPU core includes a double-precision FPU. Optionally, the FPU may implement the IEEE 754-2008 standard for floating-point arithmetic, or enable variable-precision floating-point arithmetic. The graphics multiprocessor 234 may additionally include one or more fixed-function or special-function units for performing specific functions, such as copying rectangles or pixel blending operations. One or more of the GPGPU cores in the GPGPU core may also include fixed-function or special-function logic.
[0084] GPGPU core 262 may include SIMD logic capable of executing a single instruction to multiple sets of data. Optionally, GPGPU core 262 may physically execute SIMD4, SIMD8, and SIMD16 instructions, and logically execute SIMD1, SIMD2, and SIMD32 instructions. SIMD instructions for GPGPU cores may be generated by a shader compiler at compile time, or automatically generated when executing a program written and compiled for a single program multiple data (SPMD) or SIMT architecture. Multiple threads of a program configured for a SIMT execution model may be executed via a single SIMD instruction. For example and in one embodiment, eight SIMT threads may be executed in parallel via a single SIMD8 logic unit, and these eight SIMT threads perform the same or similar operations.
[0085] The memory and cache interconnect 268 is an interconnect network that connects each of the functional units of the graphics multiprocessor 234 to the register file 258 and to the shared memory 270. For example, the memory and cache interconnect 268 is a crossbar interconnect that allows the load / store unit 266 to implement load and store operations between the shared memory 270 and the register file 258. The register file 258 can operate at the same frequency as the GPGPU core 262, so data transfers between the GPGPU core 262 and the register file 258 are very low latency. The shared memory 270 can be used to enable communication between threads executed on the functional units within the graphics multiprocessor 234. The cache memory 272 can be used as a data cache, for example, to cache texture data passed between the functional unit and the texture unit 236. The shared memory 270 can also be used as a managed cached program. The shared memory 270 and the cache memory 272 can be coupled with the data crossbar 240 to enable communication with other components of the processing cluster. Threads executing on GPGPU core 262 can programmatically store data in shared memory in addition to automatically cached data stored in cache memory 272 .
[0086] Figure 3A-3C An additional graphics multiprocessor is illustrated in accordance with an embodiment. Figure 3A-3B Graphics multiprocessors 325 and 350 are shown. Graphics multiprocessors 325 and 350 are Figure 2C 234, and may be used in place of one of those graphics multiprocessors. Therefore, any disclosure of features herein in conjunction with graphics multiprocessor 234 also discloses corresponding combinations with graphics multiprocessors 325, 350, but is not limited thereto. Figure 3C A graphics processing unit (GPU) 380 is illustrated, which includes a collection of dedicated graphics processing resources arranged as multi-core groups 365A-365N, which correspond to the graphics multiprocessors 325, 350. The illustrated graphics multiprocessors 325, 350 and multi-core groups 365A-365N may be streaming multiprocessors (SMs) capable of executing a large number of execution threads simultaneously.
[0087] Figure 3A The graphics multiprocessor 325 includes relative Figure 2DThe graphics multiprocessor 325 may include multiple additional instances of execution resource units of the graphics multiprocessor 234. For example, the graphics multiprocessor 325 may include multiple instances of instruction units 332A-332B, register files 334A-334B, and (one or more) texture units 344A-344B. The graphics multiprocessor 325 also includes multiple sets of graphics or compute execution units (e.g., GPGPU cores 336A-336B, tensor cores 337A-337B, ray tracing cores 338A-338B) and multiple sets of load / store units 340A-340B. The execution resource units have a common instruction cache 330, texture and / or data cache memory 342, and shared memory 346.
[0088] The components may communicate via an interconnect structure 327. The interconnect structure 327 may include one or more crossbar switches to enable communication between the components of the graphics multiprocessor 325. The interconnect structure 327 is a separate, high-speed network fabric layer on which each component of the graphics multiprocessor 325 is stacked. The components of the graphics multiprocessor 325 communicate with remote components via the interconnect structure 327. For example, the cores 336A-336B, 337A-337B, and 338A-338B may each communicate with the shared memory 346 via the interconnect structure 327. The interconnect structure 327 may arbitrate communications within the graphics multiprocessor 325 to ensure fair bandwidth allocation between components.
[0089] Figure 3B The graphics multiprocessor 350 includes a plurality of execution resource sets 356A-356D, wherein, for example Figure 2D and Figure 3A As shown in FIG. 1 , each set of execution resources includes multiple instruction units, register files, GPGPU cores, and load storage units. Execution resources 356A-356D can work in conjunction with (one or more) texture units 360A-360D for texture operations while sharing instruction cache 354 and shared memory 353. For example, execution resources 356A-356D can share multiple instances of instruction cache 354 and shared memory 353 and texture and / or data cache memory 358A-358B. Each component can be connected to the CPU via the CPU. Figure 3A The interconnect structure 327 communicates with a similar interconnect structure 352 .
[0090] Those skilled in the art will understand that Figure 1 , Figure 2A-2D as well as Figure 3A-3BThe architecture described in is illustrative and not limiting in terms of the scope of the present embodiments. Thus, the techniques described herein may be implemented on any appropriately configured processing unit without departing from the scope of the embodiments described herein, including but not limited to: one or more mobile application processors; one or more desktop or server central processing units (CPUs), including multi-core CPUs; one or more parallel processor units, such as, Figure 2A The parallel processing unit 202 and one or more graphics processors or special processing units.
[0091] The parallel processor or GPGPU described herein can be communicatively coupled to a host / processor core to accelerate graphics operations, machine learning operations, pattern analysis operations, and various general-purpose GPU (GPGPU) functions. The GPU can be communicatively coupled to the host processor / core via a bus or another interconnect (e.g., a high-speed interconnect, such as PCIe, NVLink, or other known protocols, standardized protocols, or proprietary protocols). In other embodiments, the GPU can be integrated on the same package or chip as the core and communicatively coupled to the core via an internal processor bus / interconnect (i.e., inside the package or chip). Regardless of the manner in which the GPU is connected, the processor core can assign work to the GPU in the form of a sequence of commands / instructions contained in a work descriptor. The GPU then uses dedicated circuits / logic to efficiently process these commands / instructions.
[0092] Figure 3C A graphics processing unit (GPU) 380 is shown that includes a collection of dedicated graphics processing resources arranged as multi-core groups 365A-365N. Although details of only a single multi-core group 365A are provided, it will be appreciated that other multi-core groups 365B-365N may be equipped with the same or similar collection of graphics processing resources. The details described with respect to multi-core groups 365A-365 may also be applied to any of the graphics multiprocessors 234, 325, 350 described herein.
[0093] As illustrated, multi-core group 365A may include a set 370 of graphics cores, a set 371 of tensor cores, and a set 372 of ray tracing cores. Scheduler / dispatcher 368 schedules and dispatches graphics threads for execution on the respective cores 370, 371, 372. A set 369 of register files stores operand values used by cores 370, 371, 372 when executing graphics threads. These register files may include, for example, integer registers for storing integer values, floating point registers for storing floating point values, vector registers for storing packed data elements (integer and / or floating point data elements), and slice registers for storing tensor / matrix values. Slice registers may be implemented as a combined set of vector registers.
[0094] One or more combined first level (L1) caches and shared memory units 373 store graphics data locally within each multi-core group 365A, such as texture data, vertex data, pixel data, light data, bounding volume data, etc. One or more texture units 374 can also be used to perform texture operations, such as texture mapping and sampling. A second level (L2) cache 375 shared by all multi-core groups 365A-365N or a subset of multi-core groups 365A-365N stores graphics data and / or instructions for multiple concurrent graphics threads. As shown, the L2 cache 375 can be shared across multiple multi-core groups 365A-365N. One or more memory controllers 367 couple the GPU 380 to a memory 366, which can be a system memory (e.g., DRAM) and / or a dedicated graphics memory (e.g., GDDR6 memory).
[0095] Input / output (I / O) circuitry 363 couples GPU 380 to one or more I / O devices 362, such as a digital signal processor (DSP), a network controller, or a user input device. On-chip interconnects may be used to couple I / O devices 362 to GPU 380 and memory 366. One or more I / O memory management units (IOMMUs) 364 of I / O circuitry 363 directly couple I / O devices 362 to system memory 366. Optionally, IOMMU 364 manages a plurality of page table sets for mapping virtual addresses to physical addresses in system memory 366. I / O devices 362, CPU(s) 361, and GPU(s) 380 may then share the same virtual address space.
[0096] In one implementation of IOMMU 364, IOMMU 364 supports virtualization. In this case, IOMMU 364 can manage a first set of page tables for mapping guest / graphics virtual addresses to guest / graphics physical addresses and a second set of page tables for mapping guest / graphics physical addresses to system / host physical addresses (e.g., within system memory 366). The base address of each of the first set of page tables and the second set of page tables can be stored in a control register and swapped out at context switch (e.g., so that the new context is provided with access to the relevant set of page tables). Although not described in detail in the prior art, the first set of page tables and the second set of page tables can be stored in a control register and swapped out at context switch (e.g., so that the new context is provided with access to the relevant set of page tables). Figure 3C , but each of the cores 370, 371, 372 and / or multi-core groups 365A-365N may include a translation lookaside buffer (TLB) for caching guest virtual to guest physical translations, guest physical to host physical translations, and guest virtual to host physical translations.
[0097] (One or more) CPU 361, GPU 380 and I / O device 362 can be integrated on a single semiconductor chip and / or chip package. The illustrated memory 366 can be integrated on the same chip, or can be coupled to a memory controller 367 via an off-chip interface. In one implementation, memory 366 includes GDDR6 memory that shares the same virtual address space as other physical system-level memories, but the basic principles described herein are not limited to this particular implementation.
[0098] Tensor core 371 may include multiple execution units specifically designed to perform matrix operations, which are basic computational operations for performing deep learning operations. For example, synchronized matrix multiplication operations may be used for neural network training and inference. Tensor core 371 may perform matrix processing using a variety of operand precisions, including single-precision floating point (e.g., 32 bits), half-precision floating point (e.g., 16 bits), integer words (16 bits), bytes (8 bits), and half bytes (4 bits). For example, a neural network implementation extracts features of each rendered scene, potentially combining details from multiple frames to build a high-quality final image.
[0099] In a deep learning implementation, parallel matrix multiplication work may be scheduled for execution on the tensor core 371. The training of neural networks in particular requires a large number of matrix dot product operations. To handle the inner product formulation of the N xN x N matrix multiplication, the tensor core 371 may include at least N dot product processing elements. Before the matrix multiplication begins, a complete matrix is loaded into the slice register, and for each of the N cycles, at least one column of the second matrix is loaded. For each cycle, there are N dot products that are processed.
[0100] Depending on the specific implementation, matrix elements can be stored with different precisions, including 16-bit words, 8-bit bytes (e.g., INT8), and 4-bit nibbles (e.g., INT4). Different precision modes can be specified for the tensor core 371 to ensure that the most efficient precision is used for different workloads (e.g., such as inference workloads, which can tolerate quantization to bytes and nibbles). Supported formats additionally include 64-bit floating point (FP64) and non-IEEE floating point formats, such as the bfloat16 format (e.g., Brain floating point), a 16-bit floating point format with one sign bit, eight exponent bits, and eight significand bits (seven of which are explicitly stored). One embodiment includes support for a reduced precision tensor floating point (TF32) mode that performs calculations using the range of FP32 (8 bits) and the precision of FP16 (10 bits). Reduced precision TF32 operations can be performed on FP32 inputs and produce FP32 outputs with higher performance relative to FP32 and increased precision relative to FP16. In one embodiment, one or more 8-bit floating point formats (FP32) are supported.
[0101] In one embodiment, the tensor core 371 supports a sparse operation mode for matrices in which the vast majority of values are zero. The tensor core 371 includes support for sparse input matrices encoded in sparse matrix representations (e.g., coordinate list encoding (COO), compressed sparse rows (CSR), compressed sparse columns (CSC), etc.). The tensor core 371 also includes support for compressed sparse matrix representations in the case where the sparse matrix representation can be further compressed. Compressed matrix data, encoded matrix data, and / or compressed and encoded matrix data and associated compression and / or encoding metadata can be read by the tensor core 371, and non-zero values can be extracted. For example, for a given input matrix A, non-zero values can be loaded from at least a portion of the compressed and / or encoded representation of matrix A. Based on the position of the non-zero value in matrix A (which can be determined from the index or coordinate metadata associated with the non-zero value), the corresponding value in the input matrix B can be loaded. Depending on the operation to be performed (e.g., multiplication), if the corresponding value is a zero value, loading the value from the input matrix B can be bypassed. In one embodiment, the pairing of values for certain operations (such as multiplication operations) can be pre-scanned by the scheduler logic, and only operations between non-zero inputs are scheduled. Depending on the dimensions of matrix A and matrix B and the operations to be performed, the output matrix C can be dense or sparse. In the case where the output matrix C is sparse and depending on the configuration of the tensor core 371, the output matrix C can be output in a compressed format, sparse coding, or compressed sparse coding.
[0102] The ray tracing core 372 can accelerate ray tracing operations for both real-time ray tracing implementations and non-real-time ray tracing implementations. Specifically, the ray tracing core 372 may include a ray traversal / intersection circuit for performing ray traversals and identifying intersections between rays and primitives enclosed within a BVH volume using a bounding volume hierarchy (BVH). The ray tracing core 372 may also include circuits for performing depth testing and culling (e.g., using a Z buffer or similar arrangement). In one implementation, the ray tracing core 372 performs traversal and intersection operations in conjunction with the image denoising techniques described herein, at least part of which may be performed on the tensor core 371. For example, the tensor core 371 may implement a deep learning neural network to perform denoising on frames generated by the ray tracing core 372. However, the CPU(s) 361, the graphics core 370, and / or the ray tracing core 372 may also implement all or part of the denoising and / or deep learning algorithms.
[0103] In addition, as described above, a distributed approach to noise reduction may be employed, wherein GPU 380 is in a computing device coupled to other computing devices via a network or high-speed interconnect. According to the distributed approach, the interconnected computing devices may share neural network learning / training data to improve the speed at which the entire system learns to perform noise reduction for different types of image frames and / or different graphics applications.
[0104] The ray tracing core 372 can handle all BVH traversals and / or ray-primitive intersections, thereby preventing the graphics core 370 from being overloaded with thousands of instructions for each ray. For example, each ray tracing core 372 includes a first set of specialized circuits for performing bounding box tests (e.g., for traversal operations) and / or a second set of specialized circuits for performing ray-triangle intersection tests (e.g., intersecting rays that have been traversed). Thus, for example, the multi-core group 365A can simply start ray detection, and the ray tracing core 372 independently performs ray traversals and intersections and returns hit data (e.g., hits, no hits, multiple hits, etc.) to the thread context. While the ray tracing core 370 performs traversal and intersection operations, the other cores 371, 372 are freed up to perform other graphics or computational work.
[0105] Optionally, each ray tracing core 372 may include a traversal unit for performing BVH test operations and / or an intersection unit for performing ray-primitive intersection tests. The intersection unit generates a "hit", "no hit", or "multiple hits" response, which it provides to the appropriate thread. During traversal and intersection operations, execution resources of other cores (e.g., graphics core 370 and tensor core 371) are freed up to perform other forms of graphics work.
[0106] In one optional embodiment described below, a hybrid rasterization / ray tracing approach is used in which the work is distributed between graphics core 370 and ray tracing core 372 .
[0107] The ray tracing core 372 (and / or other cores 370, 371) may include hardware support for ray tracing instruction sets, such as Microsoft's DirectX Ray Tracing (DXR), which includes the DispatchRays command; and ray generation shaders, nearest hit shaders, any hit shaders, and miss shaders, which enable unique shader and texture sets to be assigned to each object. Another ray tracing platform that may be supported by the ray tracing core 372, graphics core 370, and tensor core 371 is the Vulkan API (e.g., Vulkan version 1.1.85, or later). However, it should be noted that the basic principles described herein are not limited to any particular ray tracing ISA.
[0108] In general, each core 372, 371, 370 may support a ray tracing instruction set including instructions / functions for one or more of the following: ray generation, nearest hit, any hit, ray-primitive intersection, per-primitive and hierarchy bounding box construction, misses, visits, and exceptions. More specifically, preferred embodiments include ray tracing instructions for performing one or more of the following functions:
[0109] Light Generation - Ray generation instructions can be executed for each pixel, sample, or other user-defined work assignment.
[0110] Recent Hits - A nearest hit command may be executed to locate the closest intersection of a ray with a primitive within the scene.
[0111] Any hit - Any hit command identifies multiple intersections between rays and primitives within the scene, potentially identifying a new closest intersection point.
[0112] intersect ——The intersection instruction performs a ray-primitive intersection test and outputs the result.
[0113] Per-primitive bounding box construction - This instruction builds a bounding box around a given primitive or group of primitives (e.g., when building a new BVH or other acceleration data structure).
[0114] miss - Indicates that the ray missed the scene or all geometry within a specified region of the scene.
[0115] visit ——Indicates the subvolume that the ray will traverse.
[0116] abnormal - Includes various types of exception handlers (e.g., called for various error conditions).
[0117] In one embodiment, the ray tracing core 372 may be adapted to accelerate general computing operations that can be accelerated using computing techniques similar to ray intersection testing. A computing framework may be provided that enables shader programs to be compiled into low-level instructions and / or primitives that perform general computing operations via the ray tracing core. Exemplary computing problems that may benefit from computing operations performed on the ray tracing core 372 include calculations involving the propagation of beams, waves, rays, or particles within a coordinate space. Interactions associated with that propagation may be calculated relative to a geometry or mesh within the coordinate space. For example, calculations associated with the propagation of electromagnetic signals through an environment may be accelerated using instructions or primitives that are executed via the ray tracing core. Refraction and reflection of signals through objects in the environment may be calculated as direct ray tracing simulations.
[0118] The ray tracing core 372 can also be used to perform calculations that are not directly similar to ray tracing. For example, the ray tracing core 372 can be used to accelerate mesh projection, mesh refinement, and volume sampling calculations. General coordinate space calculations, such as nearest neighbor calculations, can also be performed. For example, a set of points near a given point can be found by defining a bounding box around the given point in the coordinate space. The BVH and ray detection logic in the ray tracing core 372 can then be used to determine the set of intersections of points within the bounding box. The intersection constitutes the origin and the nearest neighbor of that origin. The calculations performed using the ray tracing core 372 can be performed in parallel with the calculations performed on the graphics core 372 and the tensor core 371. The shader compiler can be configured to compile a compute shader or other general graphics processing program into a low-level primitive that can be parallelized across the graphics core 370, the tensor core 371, and the ray tracing core 372. Technologies for GPU to host processor interconnect
[0119] Figure 4A The diagram shows a plurality of GPUs 410-413 (e.g., such as Figure 2A2) is communicatively coupled to a plurality of multi-core processors 405-406 via high-speed links 440A-440D (e.g., buses, point-to-point interconnects, etc.). Depending on the implementation, high-speed links 440A-440D may support 4GB / s, 30GB / s, 80GB / s, or higher communication throughput. Various interconnect protocols may be used, including but not limited to PCIe 4.0 or 5.0 and NVLink 2.0. However, the basic principles described herein are not limited to any particular communication protocol or throughput.
[0120] Two or more of the GPUs 410-413 may be interconnected via high-speed links 442A-442B, which may be implemented using the same or different protocols / links as those used for high-speed links 440A-440D. Similarly, two or more of the multi-core processors 405-406 may be connected via high-speed link 443, which may be a symmetric multi-processor (SMP) bus operating at 20 GB / s, 30 GB / s, 120 GB / s, or lower or higher speeds. Alternatively, Figure 4A All communications between the various system components shown in the can be implemented using the same protocol / links (eg, through a common interconnect structure). However, as mentioned, the basic principles described herein are not limited to any particular type of interconnect technology.
[0121] Each of the multi-core processors 405 and 406 may be communicatively coupled to processor memories 401-402 via memory interconnects 430A-430B, respectively, and each GPU 410-413 may be communicatively coupled to GPU memories 420-423, respectively, via GPU memory interconnects 450A-450D. Memory interconnects 430A-430B and 450A-450D may utilize the same or different memory access technologies. By way of example and not limitation, processor memories 401-402 and GPU memories 420-423 may be volatile memories such as dynamic random access memory (DRAM) (including stacked DRAM), graphics DDR SDRAM (GDDR) (e.g., GDDR5, GDDR6), or high bandwidth memory (HBM), and / or may be non-volatile memories such as 3D Xpoint / Optane or Nano-Ram. For example, a portion of the memory may be volatile memory and another portion may be non-volatile memory (e.g., using a two-level memory (2LM) hierarchy). The memory subsystem described herein may be compatible with several memory technologies, such as the double data rate version published by JEDEC (Joint Electronic Device Engineering Council).
[0122] As described below, although each processor 405-406 and GPU 410-413 may be physically coupled to a specific memory 401-402, 420-423, respectively, a unified memory architecture may be implemented in which the same virtual system address space (also referred to as an "effective address" space) is distributed among all of the various physical memories. For example, processor memories 401-402 may each include 64GB of system memory address space, and GPUs 420-423 may each include 32GB of system memory address space (resulting in a total of 256GB of addressable memory in this example).
[0123] Figure 4B Additional optional details of the interconnection between the multi-core processor 407 and the graphics acceleration module 446 are illustrated. The graphics acceleration module 446 may include one or more GPU chips integrated on a line card that is coupled to the processor 407 via the high-speed link 440. Alternatively, the graphics acceleration module 446 may be integrated on the same package or chip as the processor 407.
[0124] The illustrated processor 407 includes a plurality of cores 460A-460D, each of which has a translation lookaside buffer 461A-461D and one or more caches 462A-462D. The core may include various other components for executing instructions and processing data, which are not illustrated to avoid obscuring the basic principles of the components described herein (e.g., instruction fetch units, branch prediction units, decoders, execution units, reorder buffers, etc.). Caches 462A-462D may include first-level (L1) caches and second-level (L2) caches. In addition, one or more shared caches 456 may be included in the cache hierarchy and shared by the set 460A-460D of cores. For example, one embodiment of the processor 407 includes 24 cores, each of which has its own L1 cache, twelve shared L2 caches, and twelve shared L3 caches. In this embodiment, one of the L2 cache and the L3 cache is shared by two adjacent cores. Processor 407 and graphics accelerator integrated module 446 are connected to system memory 441, which may include processor memories 401-402.
[0125] Coherence is maintained for data and instructions stored in each cache 462A-462D, 456 and system memory 441 via inter-core communications over coherence bus 464. For example, each cache may have cache coherence logic / circuitry associated therewith to communicate over coherence bus 464 in response to a detected read or write to a particular cache line. In one implementation, a cache snooping protocol is implemented over coherence bus 464 to snoop cache accesses. Cache snooping / coherence techniques are well understood by those skilled in the art and will not be described in detail herein to avoid obscuring the basic principles described herein.
[0126] A proxy circuit 425 may be provided that communicatively couples the graphics acceleration module 446 to the coherence bus 464, thereby allowing the graphics acceleration module 446 to participate in a cache coherence protocol as a peer of the core. Specifically, an interface 435 provides connectivity to the proxy circuit 425 via a high-speed link 440 (e.g., a PCIe bus, NVLink, etc.), and an interface 437 connects the graphics acceleration module 446 to the high-speed link 440.
[0127] In one implementation, the accelerator integrated circuit 436 provides cache management, memory access, context management, and interrupt management services on behalf of multiple graphics processing engines 431, 432...N of the graphics acceleration module 446. The graphics processing engines 431, 432...N may each include a separate graphics processing unit (GPU). Alternatively, the graphics processing engines 431, 432...N may include different types of graphics processing engines within the GPU, such as a graphics execution unit, a media processing engine (e.g., a video encoder / decoder), a sampler, and a block image transfer (BLIT) engine. In other words, the graphics acceleration module may be a GPU with multiple graphics processing engines 431-432...N, or the graphics processing engines 431-432...N may be separate GPUs integrated on a common package, line card, or chip. The graphics processing engines 431-432...N may be configured using any graphics processor or computing accelerator architecture described herein.
[0128] The accelerator integrated circuit 436 may include a memory management unit (MMU) 439 for performing various memory management functions such as virtual to physical memory translation (also known as effective to real memory translation) and memory access protocols for accessing the system memory 441. The MMU 439 may also include a translation lookaside buffer (TLB) (not shown) for caching virtual / effective to physical / real address translations. In one implementation, the cache 438 stores commands and data for efficient access by the graphics processing engines 431, 432...N. The data stored in the cache 438 and the graphics memories 433-434...M may be kept consistent with the core caches 462A-462D, 456 and the system memory 441. As mentioned, this may be accomplished via proxy circuitry 425, which participates in cache coherence mechanisms on behalf of cache 438 and memories 433-434...M (e.g., sending updates to cache 438 related to modifications / accesses of cache lines on processor caches 462A-462D, 456, and receiving updates from cache 438).
[0129] The set of registers 445 stores context data for threads executed by the graphics processing engines 431-432...N, and the context management circuit 448 manages these thread contexts. For example, the context management circuit 448 may perform save and restore operations to save and restore the context of each thread during a context switch (e.g., where a first thread is saved and a second thread is restored so that the second thread can be executed by the graphics processing engine). For example, upon a context switch, the context management circuit 448 may store the current register value to a specified area in memory (e.g., identified by a context pointer). When returning to that context, it may then restore the register value. The interrupt management circuit 447 may, for example, receive an interrupt from a system device and process the interrupt received from the system device.
[0130] In one implementation, the virtual / effective address from the graphics processing engine 431 is translated into an actual / physical address in the system memory 441 by the MMU 439. Optionally, the accelerator integrated circuit 436 supports multiple (e.g., 4, 8, 16) graphics accelerator modules 446 and / or other accelerator devices. The graphics accelerator module 446 may be dedicated to a single application executed on the processor 407, or may be shared between multiple applications. Optionally, a virtualized graphics execution environment is provided in which the resources of the graphics processing engines 431-432 ... N are shared with multiple applications, virtual machines (VMs) or containers. Resources may be subdivided into "slices" that are allocated to different VMs and / or applications based on processing requirements and priorities associated with the VMs and / or applications or based on a predetermined partition profile for the graphics accelerator module 446. VMs and containers may be used interchangeably herein.
[0131] A virtual machine (VM) can be software that runs an operating system and one or more applications. A VM can be defined by specifications, configuration files, virtual disk files, non-volatile random access memory (NVRAM) settings files, and log files, and is backed up by the physical resources of the host computing platform. A VM may include an operating system (OS) or application environment installed on software that mimics dedicated hardware. End users have the same experience on a virtual machine as they would on dedicated hardware. Specialized software called a hypervisor completely emulates the CPU, memory, hard disk, network, and other hardware resources of a PC client or server, allowing virtual machines to share resources. A hypervisor can emulate multiple virtual hardware platforms that are isolated from each other, allowing virtual machines to run on the same underlying physical host. Server, VMware ESXi, and other operating systems.
[0132] A container is a package of applications, configurations, and dependencies so that the application runs reliably from one computing environment to another. Containers can share an operating system installed on a server platform and run as isolated processes. A container is a package of software that contains everything the software needs to run, such as system tools, libraries, and settings. Containers are not installed like traditional software programs, which allows them to be isolated from other software and from the operating system itself. The isolated nature of containers provides several benefits. First, the software in a container will run the same way in different environments. For example, a container that includes PHP and MySQL can be run in the same way in different environments. Computer and The machines run in exactly the same way on both. Second, containers provide increased security because the software will not affect the host operating system. While installed applications will change system settings and modify resources (such as the Windows registry), containers can only modify settings within the container.
[0133] Thus, the accelerator integrated circuit 436 acts as a bridge to the system for the graphics acceleration module 446 and provides address translation and system memory caching services. In one embodiment, to facilitate the bridging function, the accelerator integrated circuit 436 may also include a shared I / O 497 (e.g., PCIe, USB, or other elements) and hardware to enable system control of voltage, clock control, performance, heat, and security. The shared I / O 497 may utilize separate physical connections or may span the high-speed link 440. In addition, the accelerator integrated circuit 436 may provide virtualization facilities for the host processor to manage virtualization of the graphics processing engine, interrupts, and memory management.
[0134] Since the hardware resources of the graphics processing engines 431-432 ... N are explicitly mapped to the actual address space seen by the host processor 407, any host processor can directly address these resources using effective address values. An optional function of the accelerator integrated circuit 436 is to physically separate the graphics processing engines 431-432 ... N so that they appear as independent units to the system.
[0135] One or more graphics memories 433-434 ... M may be respectively coupled to each of the graphics processing engines 431-432 ... N. Graphics memories 433-434 ... M store instructions and data processed by each of the graphics processing engines 431-432 ... N. Graphics memories 433-434 ... M may be volatile memories such as DRAM (including stacked DRAM), GDDR memories (e.g., GDDR5, GDDR6), or HBM, and / or may be non-volatile memories such as 3D Xpoint / Optane, Samsung Z-NAND, or Nano-Ram.
[0136] To reduce the amount of data traffic on high-speed link 440, biasing techniques may be used to ensure that the data stored in graphics memory 433-434 ... M is data that will be used most frequently by graphics processing engines 431-432 ... N and preferably not used (at least not frequently) by cores 460A-460D. Similarly, the biasing mechanism attempts to keep data needed by the cores (and preferably not graphics processing engines 431-432 ... N) within system memory 441 and the cores' caches 462A-462D, 456.
[0137] according to Figure 4C In the variant shown in FIG. 4 , the accelerator integrated circuit 436 is integrated within the processor 407. The graphics processing engines 431-432 ... N communicate directly to the accelerator integrated circuit 436 via the high-speed link 440, via the interface 437 and the interface 435 (which again may utilize any form of bus or interface protocol). The accelerator integrated circuit 436 may perform operations related to Figure 4B The operations are the same as those described, but given the close proximity of the accelerator integrated circuit 436 to the coherency bus 464 and caches 462A-462D, 456, it is potentially able to perform the operations at a higher throughput.
[0138] The described embodiments may support different programming models, including a dedicated process programming model (without graphics acceleration module virtualization) and a shared programming model (with virtualization). The latter may include a programming model controlled by the accelerator integrated circuit 436 and a programming model controlled by the graphics acceleration module 446.
[0139] In an embodiment of a dedicated process model, graphics processing engines 431, 432, ..., N can be dedicated to a single application or process under a single operating system. A single application can leak other application requests to graphics engines 431, 432, ..., N, thereby providing virtualization within a VM / partition.
[0140] In a dedicated process programming model, graphics processing engines 431, 432...N can be shared by multiple VM / application partitions. The shared model requires the hypervisor to virtualize graphics processing engines 431-432...N to allow access by each operating system. For a single partition system without a hypervisor, graphics processing engines 431-432...N are owned by the operating system. In both cases, the operating system can virtualize graphics processing engines 431-432...N to provide access to each process or application.
[0141] For the shared programming model, the graphics acceleration module 446 or the individual graphics processing engines 431-432 ... N use a process handle to select a process element. The process element may be stored in the system memory 441 and may be addressable using the effective address to real address translation techniques described herein. The process handle may be an implementation-specific value provided to the host process when registering its context with the graphics processing engine 431-432 ... N (i.e., calling the system software to add the process element to the process element linked list). The lower 16 bits of the process handle may be the offset of the process element within the process element linked list.
[0142] Figure 4D An exemplary accelerator integrated slice 490 is illustrated. As used herein, a "slice" includes a specified portion of the processing resources of an accelerator integrated circuit 436. An application effective address space 482 within the system memory 441 stores process elements 483. Process elements 483 may be stored in response to a GPU call 481 from an application 480 executed on a processor 407. Process elements 483 contain a process state for the corresponding application 480. A work descriptor (WD) 484 contained in the process element 483 may be a single job requested by the application, or may contain a pointer to a job queue. In the latter case, WD 484 is a pointer to a job request queue in the address space 482 of the application.
[0143] Graphics acceleration module 446 and / or each graphics processing engine 431-432 ... N can be shared by all processes in the system or a subset of processes in the system. For example, the technology described herein may include an infrastructure for establishing a process state and sending WD484 to graphics acceleration module 446 to start a job in a virtualized environment.
[0144] In one implementation, the dedicated process programming model is implementation specific. In this model, a single process owns the graphics acceleration module 446 or a separate graphics processing engine 431. Since the graphics acceleration module 446 is owned by a single process, when the graphics acceleration module 446 is assigned, the hypervisor initializes the accelerator integrated circuit 436 for the owning partition, and the operating system initializes the accelerator integrated circuit 436 for the owning process.
[0145] In operation, the WD acquisition unit 491 in the accelerator integrated slice 490 acquires the next WD 484, which includes an indication of the work to be completed by one of the graphics processing engines of the graphics acceleration module 446. As illustrated, data from the WD 484 may be stored in registers 445 and used by the MMU 439, the interrupt management circuit 447, and / or the context management circuit 448. For example, the MMU 439 may include a segment / page walk circuit for accessing a segment table / page table 486 within the OS virtual address space 485. The interrupt management circuit 447 may process an interrupt event 492 received from the graphics acceleration module 446. When performing graphics operations, the effective address 493 generated by the graphics processing engines 431-432 ... N is translated into an actual address by the MMU 439.
[0146] The same register set 445 may be replicated for each graphics processing engine 431-432 ... N and / or graphics acceleration module 446 and may be initialized by a hypervisor or operating system. Each of these replicated registers may be included in an accelerator integrated slice 490. In one embodiment, each graphics processing engine 431-432 ... N may be presented to a hypervisor 496 as a different graphics processor device. QoS settings may be configured for clients of a particular graphics processing engine 431-432 ... N, and data isolation between clients of each engine may be enabled. Exemplary registers that may be initialized by a hypervisor are shown in Table 1. Table 1 - Registers initialized by the hypervisor 1 Slice Control Register 2 Real Address (RA) scheduled process area pointer 3 Permission Mask Override Register 4 Interrupt vector table entry offset 5 Interrupt Vector Table Entry Limits 6 Status Register 7 Logical Partition ID 8 Real Address (RA) Manager Accelerator Utilizes Record Pointers 9 Storage Description Register
[0147] Exemplary registers that may be initialized by the operating system are shown in Table 2. Table 2 - Registers initialized by the operating system 1 Process and thread identities 2 Effective Address (EA) context save / restore pointer 3 Virtual Address (VA) accelerator uses record pointers 4 Virtual Address (VA) Segment Table Pointer 5 Permission Mask 6 Job Descriptor
[0148] Each WD 484 may be specific to a particular graphics acceleration module 446 and / or graphics processing engine 431-432 ... N. It contains all the information needed by the graphics processing engine 431-432 ... N to do its job, or it may be a pointer to a memory location where a command queue where an application has set up work to be done is located.
[0149] Figure 4E Additional optional details of the sharing model are illustrated. It includes a hypervisor real address space 498 in which a process element list 499 is stored. The hypervisor real address space 498 is accessible via a hypervisor 496, which virtualizes the graphics acceleration module engine to the operating system 495.
[0150] The shared programming model allows all processes or a subset of processes from all partitions in the system or a subset of partitions in the system to use the graphics acceleration module 446. There are two programming models in which the graphics acceleration module 446 is shared by multiple processes and partitions: time-sharing and graphics-directed sharing.
[0151] In this model, the hypervisor 496 owns the graphics acceleration module 446 and makes its functionality available to all operating systems 495. In order for the graphics acceleration module 446 to support virtualization by the hypervisor 496, the graphics acceleration module 446 may comply with the following requirements: 1) The application's job requests must be autonomous (i.e., state does not need to be maintained between jobs), or the graphics acceleration module 446 must provide a context save and restore mechanism. 2) The application's job requests are guaranteed by the graphics acceleration module 446 to complete within a specified amount of time, including any conversion errors, or the graphics acceleration module 446 provides the ability to preempt processing of jobs. 3) The graphics acceleration module 446 must be guaranteed fairness between processes when operating in a directed sharing programming model.
[0152] For the directed sharing model, the application 480 may be required to make an operating system 495 system call with a graphics acceleration module 446 type, a work descriptor (WD), an authority mask register (AMR) value, and a context save / restore area pointer (CSRP). The graphics acceleration module 446 type describes the target acceleration function for the system call. The graphics acceleration module 446 type may be a system-specific value. The WD is formatted specifically for the graphics acceleration module 446, and the WD may take the form of a graphics acceleration module 446 command, an effective address pointer to a user-defined structure, an effective address pointer to a command queue, or any other data structure for describing the work to be done by the graphics acceleration module 446. In one embodiment, the AMR value is the AMR state to be used for the current process. The value is passed to the operating system similar to the application setting the AMR. If the accelerator integrated circuit 436 and graphics acceleration module 446 implementation do not support the User Authority Mask Override Register (UAMOR), the operating system may apply the current UAMOR value to the AMR value before passing the AMR in the hypervisor call. The hypervisor 496 may optionally apply the current Authority Mask Override Register (AMOR) value before placing the AMR into the process element 483. The CSRP may be a register in registers 445 that contains the effective address of an area in the application's address space 482 for the graphics acceleration module 446 to use to save and restore context state. This pointer is optional if no state is required to be saved between jobs or when a job is preempted. The context save / restore area may be pinned system memory.
[0153] Upon receiving the system call, the operating system 495 may verify that the application 480 has been registered and has been given permission to use the graphics acceleration module 446. The operating system 492 then calls the hypervisor 496 with the information shown in Table 3. Table 3 - OS call parameters to the hypervisor
[0154] Upon receiving the hypervisor call, the hypervisor 496 verifies that the operating system 495 has registered and has been given permission to use the graphics acceleration module 446. The hypervisor 496 then places the process element 483 in the process element linked list for the corresponding type of graphics acceleration module 446. The process element may include the information shown in Table 4. Table 4 - Process element information
[0155] The hypervisor may initialize registers 445 of the plurality of accelerator integrated slices 490 .
[0156] like Figure 4F As shown in , in an optional implementation, a unified memory addressable via a common virtual memory address space is employed, which is used to access physical processor memory 401-402 and GPU memory 420-423. In this implementation, operations executed on GPUs 410-413 utilize the same virtual / effective memory address space to access processor memory 401-402 and vice versa, thereby simplifying programmability. A first portion of the virtual / effective address space may be allocated to processor memory 401, a second portion may be allocated to second processor memory 402, a third portion may be allocated to GPU memory 420, and so on. The entire virtual / effective memory space (sometimes referred to as the effective address space) can thus be distributed across each of processor memory 401-402 and GPU memory 420-423, allowing any processor or GPU to access the physical memory using a virtual address mapped to any physical memory.
[0157] Bias / coherency management circuits 494A-494E within one or more of the MMUs 439A-439E may be provided that ensure cache coherency between the caches of the host processor (e.g., 405) and the caches of the GPUs 410-413 and implement biasing techniques that indicate the physical memory in which certain types of data should be stored. Figure 4F Multiple instances of bias / consistency management circuits 494A- 494E are illustrated in , but bias / consistency circuits may be implemented within an MMU of one or more host processors 405 and / or within an accelerator integrated circuit 436 .
[0158] The GPU-attached memory 420-423 can be mapped as part of the system memory and accessed using shared virtual memory (SVM) technology, but does not suffer from the typical performance drawbacks associated with full system cache coherence. The ability of the GPU-attached memory 420-423 to be accessed as system memory without heavy cache coherence overhead provides a beneficial operating environment for GPU migration. This arrangement allows the host processor 405 to set up operation objects and access calculation results without the overhead of traditional I / O DMA data copying. Such traditional copying involves driver calls, interrupts, and memory mapped I / O (MMIO) accesses, which are all inefficient relative to simple memory accesses. At the same time, the ability to access the GPU-attached memory 420-423 without cache coherence overhead can be critical to the execution time of the migrated calculation. For example, in the case of a large amount of streaming write memory traffic, the cache coherence overhead may significantly reduce the effective write bandwidth seen by the GPU 410-413. The efficiency of operand setup, the efficiency of result access, and the efficiency of GPU computation all play a role in determining the effectiveness of GPU migration.
[0159] The selection between GPU bias and host processor bias may be driven by a bias tracker data structure. For example, a bias table may be used, which may be a page-granular structure (i.e., controlled at the granularity of a memory page) comprising 1 or 2 bits per GPU-attached memory page. The bias table may be implemented in a stolen memory range of one or more GPU-attached memories 420-423, with or without a bias cache in the GPUs 410-413 (e.g., for caching frequently / recently used entries of the bias table). Alternatively, the entire bias table may be maintained within the GPU.
[0160] In one implementation, the bias table entry associated with each access to the GPU-attached memory 420-423 is accessed prior to the actual access to the GPU memory, resulting in the following operations. First, local requests from the GPU 410-413 for pages that find them in the GPU bias are forwarded directly to the corresponding GPU memory 420-423. Local requests from the GPU for pages that find them in the host bias are forwarded to the processor 405 (e.g., as discussed above, over a high-speed link). Optionally, requests from the processor 405 for pages that find the requested page in the host processor bias complete the request like a normal memory read. Alternatively, requests involving pages in the GPU bias may be forwarded to the GPU 410-413. If the GPU is not currently using the page, the GPU may then convert the page to the host processor bias.
[0161] The bias state of a page may be changed by a software-based mechanism, a hardware-assisted software-based mechanism, or, for a limited set of situations, by a purely hardware-based mechanism.
[0162] One mechanism for changing the bias state employs an API call (e.g., OpenCL), which in turn calls the GPU's device driver, which in turn sends a message (or enqueues a command descriptor) to the GPU directing the GPU to change the bias state and perform a cache flush operation in the host for some transitions. A cache flush operation is required for a transition from host processor 405 bias to GPU bias, but not for the reverse transition.
[0163] Cache coherency may be maintained by temporarily rendering GPU-biased pages that are not cacheable by host processor 405. To access these pages, processor 405 may request access from GPU 410, which may or may not grant immediate access, depending on the implementation. Therefore, to reduce communication between host processor 405 and GPU 410, it is beneficial to ensure that GPU-biased pages are those pages that are needed by the GPU but not by host processor 405, and vice versa. Graphics Processing Pipeline
[0164] Figure 5 5. A graphics processing pipeline 500 is shown. A graphics multiprocessor (such as Figure 2D Graphics multiprocessor 234, Figure 3A Graphics multiprocessor 325, Figure 3B The graphics multiprocessor 350 of FIG. 5 may implement the illustrated graphics processing pipeline 500. The graphics multiprocessor may be included in a parallel processing subsystem as described herein, such as a parallel processing subsystem. Figure 2A The parallel processor 200 can be used with Figure 1 The parallel processors 112 are related and can be used instead of one of those parallel processors. Various parallel processor systems can be implemented via parallel processing units (e.g., Figure 2A The graphics processing pipeline 500 may be implemented using one or more instances of a parallel processing unit 202 of the graphics processing unit. For example, a shader unit (e.g., Figure 2C The graphics multiprocessor 234 of the embodiment of the present invention may be configured to perform the functions of one or more of the following: the vertex processing unit 504, the tessellation control processing unit 508, the tessellation evaluation processing unit 512, the geometry processing unit 516, and the fragment / pixel processing unit 524. The functions of the data assembler 502, the primitive assemblers 506, 514, 518, the tessellation unit 510, the rasterizer 522, and the raster operation unit 526 may also be performed by a processing cluster (e.g., Figure 2A Other processing engines and corresponding partition units (e.g., Figure 2A The graphics processing pipeline 500 may also be implemented using dedicated processing units for one or more functions. It is also possible that one or more portions of the graphics processing pipeline 500 are executed by parallel processing logic within a general-purpose processor (e.g., a CPU). Optionally, one or more portions of the graphics processing pipeline 500 may access on-chip memory (e.g., such as a CPU) via a memory interface 528. Figure 2A The parallel processor memory 222 in the memory interface 528 may be Figure 2A The graphics processor pipeline 500 can also be connected via the memory interface 218 of FIG. Figure 3C This is achieved using the multi-core group 365A in .
[0165] The data assembler 502 is a processing unit that can collect vertex data for surfaces and primitives. The data assembler 502 then outputs the vertex data to the vertex processing unit 504, which includes vertex attributes. The vertex processing unit 504 is a programmable execution unit that executes the vertex shader program to illuminate and transform the vertex data as specified by the vertex shader program. The vertex processing unit 504 reads data stored in a cache, local or system memory for use in processing vertex data, and can be programmed to transform vertex data from an object-based coordinate representation to a world space coordinate space or a normalized device coordinate space.
[0166] A first instance of primitive assembler 506 receives vertex attributes from vertex processing unit 504. Primitive assembler 506 reads the stored vertex attributes as needed and builds graphics primitives for processing by tessellation control processing unit 508. Graphics primitives include triangles, line segments, points, patches, etc. as supported by various graphics processing application programming interfaces (APIs).
[0167] The tessellation control processing unit 508 treats the input vertices as control points of a geometric patch. The control points are transformed from an input representation from the patch (e.g., a basis for the patch) to a representation suitable for use in a surface evaluation performed by the tessellation evaluation processing unit 512. The tessellation control processing unit 508 may also calculate tessellation factors for edges of the geometric patch. The tessellation factors are applied to individual edges and quantize the view-dependent level of detail associated with the edge. The tessellation unit 510 is configured to receive the tessellation factors for the edges of the patch and to tessellate the patch into a plurality of geometric primitives (such as line, triangle, or quadrilateral primitives), which are transmitted to the tessellation evaluation processing unit 512. The tessellation evaluation processing unit 512 operates on the parameterized coordinates of the tessellated patch to generate a surface representation and vertex attributes for each vertex associated with the geometric primitive.
[0168] The second instance of primitive assembler 514 receives vertex attributes from tessellation evaluation processing unit 512 as needed, reads the stored vertex attributes, and builds graphics primitives for processing by geometry processing unit 516. Geometry processing unit 516 is a programmable execution unit that executes geometry shader programs to transform graphics primitives received from primitive assembler 514 as specified by the geometry shader programs. Geometry processing unit 516 can be programmed to tessellate graphics primitives into one or more new graphics primitives and calculate parameters used to rasterize the new graphics primitives.
[0169] The geometry processing unit 516 may be able to add or delete elements in the geometry stream. The geometry processing unit 516 outputs parameters and vertices that specify new graphics primitives to the primitive assembler 518. The primitive assembler 518 receives the parameters and vertices from the geometry processing unit 516 and builds graphics primitives for processing by the viewport scaling, culling, and clipping unit 520. The geometry processing unit 516 reads data stored in the parallel processor memory or system memory for use in processing the geometry data. The viewport scaling, culling, and clipping unit 520 performs clipping, culling, and viewport scaling, and outputs the processed graphics primitives to the rasterizer 522.
[0170] The rasterizer 522 may perform depth culling and other depth-based optimizations. The rasterizer 522 also performs scan conversion on new graphics primitives to generate fragments and outputs those fragments and associated coverage data to the fragment / pixel processing unit 524. The fragment / pixel processing unit 524 is a programmable execution unit configured to execute a fragment shader program or a pixel shader program. The fragment / pixel processing unit 524 transforms the fragments or pixels received from the rasterizer 522 as specified by the fragment or pixel shader program. For example, the fragment / pixel processing unit 524 may be programmed to perform operations including but not limited to texture mapping, shading, blending, texture correction, and perspective correction to produce shaded fragments or pixels output to the raster operation unit 526. The fragment / pixel processing unit 524 may read data stored in a parallel processor memory or system memory for use in processing fragment data. The fragment or pixel shader program may be configured to shade at a sample, pixel, slice, or other granularity depending on the sampling rate configured for the processing unit.
[0171] Raster operation unit 526 is a processing unit that performs raster operations and outputs pixel data to be stored in graphics memory (e.g., as Figure 2A The parallel processor memory 222 and / or Figure 1 The raster operation unit 526 may be configured to compress z data or color data written to memory and decompress z data or color data read from memory. Machine Learning Overview
[0172] The architecture described above can be applied to perform training and inference operations using machine learning models. Machine learning has been successful in solving many types of tasks. The calculations generated when training and using machine learning algorithms (e.g., neural networks) are naturally suitable for efficient parallel implementations. Accordingly, parallel processors such as general purpose graphics processing units (GPGPUs) have played an important role in the actual implementation of deep neural networks. Parallel graphics processors with single instruction multiple threads (SIMT) architectures are designed to maximize the amount of parallel processing in the graphics pipeline. In the SIMT architecture, groups of parallel threads attempt to execute program instructions together synchronously as frequently as possible to increase processing efficiency. The efficiency provided by the parallel machine learning algorithm implementation allows the use of high-capacity networks and enables training of those networks to larger data sets.
[0173] A machine learning algorithm is an algorithm that is capable of learning based on a set of data. For example, a machine learning algorithm can be designed to model high-level abstractions within a data set. For example, an image recognition algorithm can be used to determine which of several categories a given input belongs to; a regression algorithm can output a numerical value given an input; and a pattern recognition algorithm can be used to generate converted text or perform text-to-speech and / or speech recognition.
[0174] An exemplary type of machine learning algorithm is a neural network. There are many types of neural networks; a simple type of neural network is a feedforward network. A feedforward network can be implemented as an acyclic graph in which nodes are arranged in layers. Typically, a feedforward network topology includes an input layer and an output layer separated by at least one hidden layer. The hidden layer transforms the input received by the input layer into a representation useful for generating output in the output layer. The network nodes are fully connected to the nodes in the adjacent layers via edges, but there are no edges between the nodes within each layer. Data received at the nodes of the input layer of the feedforward network is propagated (i.e., "fed forward") to the nodes of the output layer via an activation function, which calculates the state of the nodes of each consecutive layer in the network based on coefficients ("weights") associated with each of the edges connecting these layers. Depending on the specific model being represented by the algorithm being executed, the output from the neural network algorithm can take various forms.
[0175] Before a machine learning algorithm can be used to model a particular problem, the algorithm is trained using a training data set. Training a neural network involves: selecting a network topology; using a set of training data that represents the problem being modeled by the network; and adjusting weights until the network model performs with minimal error for all instances of the training data set. For example, during a supervised learning training process for a neural network, the output generated by the network in response to an input representing an instance in the training data set is compared to the "correct" labeled output for that instance, an error signal representing the difference between the output and the labeled output is calculated, and as the error signal is propagated backward through the layers of the network, the weights associated with the connections are adjusted to minimize that error. The network is considered "trained" when the error for each of the outputs generated from the instances of the training data set is minimized.
[0176] The accuracy of a machine learning algorithm can be significantly affected by the quality of the data set used to train the algorithm. The training process can be computationally intensive and can take a significant amount of time on a conventional general-purpose processor. Accordingly, many types of machine learning algorithms are trained using parallel processing hardware. This is particularly useful for optimizing the training of neural networks, as the calculations performed when adjusting the coefficients in a neural network are naturally suited to parallel implementations. In particular, many machine learning algorithms and software applications have been adapted to exploit the parallel processing hardware within general-purpose graphics processing devices.
[0177] Figure 6 is a generalized diagram of a machine learning software stack 600. A machine learning application 602 is any logic that can be configured to train a neural network using a training data set or to implement machine intelligence using a trained deep neural network. The machine learning application 602 may include training and inference functions for the neural network and / or specialized software that can be used to train the neural network before deployment. The machine learning application 602 may implement any type of machine intelligence, including but not limited to: image recognition, map creation and positioning, autonomous navigation, speech synthesis, medical imaging, or language translation. Example machine learning applications 602 include but are not limited to voice-based virtual assistants, image or facial recognition algorithms, autonomous navigation, and software tools used to train machine learning models used by the machine learning application 602.
[0178] Hardware acceleration for machine learning applications 602 can be enabled via a machine learning framework 604. The machine learning framework 604 can provide a library of machine learning primitives. Machine learning primitives are basic operations typically performed by machine learning algorithms. Without the machine learning framework 604, developers of machine learning algorithms will be required to create and optimize the main computing logic associated with the machine learning algorithm, and then re-optimize the computing logic when developing new parallel processors. Instead, machine learning applications can be configured to use primitives provided by the machine learning framework 604 to perform necessary calculations. Exemplary primitives include tensor convolutions, activation functions, and pooling, which are computational operations performed when training convolutional neural networks (CNNs). The machine learning framework 604 can also provide primitives to implement basic linear algebra subroutines performed by many machine learning algorithms, such as matrix and vector operations. Examples of machine learning frameworks 604 include, but are not limited to, TensorFlow, TensorRT, PyTorch, MXNet, Caffee, and other advanced machine learning frameworks.
[0179] The machine learning framework 604 can process input data received from the machine learning application 602 and generate appropriate inputs to the computing framework 606. The computing framework 606 can abstract the underlying instructions provided to the GPGPU driver 608 so that the machine learning framework 604 can utilize hardware acceleration via the GPGPU hardware 610 without the machine learning framework 604 being very familiar with the architecture of the GPGPU hardware 610. In addition, the computing framework 606 can enable hardware acceleration for the machine learning framework 604 across various types and generations of GPGPU hardware 610. Exemplary computing frameworks 606 include CUDA computing frameworks and associated machine learning libraries, such as CUDA Deep Neural Network (cuDNN) libraries. The machine learning software stack 600 may also include a communication library or framework to facilitate multi-GPU and multi-node computing. GPGPU machine learning acceleration
[0180] Figure 7 A general purpose graphics processing unit 700 is shown, which may be Figure 2A Parallel processor 200 or Figure 1 (one or more) parallel processors 112. The general purpose processing unit (GPGPU) 700 can be configured to provide support for hardware acceleration of primitives provided by machine learning frameworks to accelerate the processing of computing workloads of the type associated with training deep neural networks. In addition, the GPGPU 700 can be directly linked to other instances of the GPGPU to create a multi-GPU cluster, thereby improving the training speed of deep neural networks in particular. Primitives are also supported to accelerate inference operations for deployed neural networks.
[0181] GPGPU 700 includes a host interface 702 for enabling connection to a host processor. Host interface 702 may be a PCI Express interface. However, the host interface may also be a vendor-specific communication interface or communication structure. GPGPU 700 receives commands from the host processor and uses a global scheduler 704 to distribute execution threads associated with those commands to a collection of processing clusters 706A-706H. Processing clusters 706A-706H share cache memory 708. Cache memory 708 may act as a higher level cache for cache memory within processing clusters 706A-706H. The illustrated processing clusters 706A-706H may be connected to a plurality of processors such as CPUs 706A-706H. Figure 2A Corresponding to the processing clusters 214A-214N in.
[0182] GPGPU 700 includes memory 714A-714B coupled to processing clusters 706A-706H via a set of memory controllers 712A-712B. Memories 714A-714B may include various types of memory devices, including dynamic random access memory (DRAM) or graphics random access memory, such as synchronous graphics random access memory (SGRAM), including graphics double data rate (GDDR) memory. Memories 714A-714B may also include 3D stacked memory, including but not limited to high bandwidth memory (HBM).
[0183] Each of processing clusters 706A-706H may include a collection of graphics multiprocessors, such as, Figure 2D Graphics multiprocessor 234, Figure 3A Graphics multiprocessor 325, Figure 3B The graphics multiprocessor 350 may include Figure 3C The graphics multiprocessors of the computing clusters include multiple types of integer and floating point logic units capable of performing computational operations with a range of precisions including those suitable for machine learning computations. For example, at least a subset of the floating point units in each of the processing clusters 706A-706H may be configured to perform 16-bit or 32-bit floating point operations, while a different subset of the floating point units may be configured to perform 64-bit floating point operations.
[0184] Multiple instances of GPGPU 700 may be configured to operate as a computing cluster. The communication mechanisms used by the computing cluster for synchronization and data exchange vary across embodiments. For example, multiple instances of GPGPU 700 communicate via a host interface 702. In one embodiment, GPGPU 700 includes an I / O hub 709 that couples GPGPU 710 with a GPU link 710 that enables direct connection to other instances of GPGPU. GPU link 710 may be coupled to a dedicated GPU to GPU bridge that enables communication and synchronization between multiple instances of GPGPU 700. Optionally, GPU link 710 is coupled to a high-speed interconnect to transmit data to and receive data from other GPGPUs or parallel processors. Multiple instances of GPGPU 700 may be located in separate data processing systems and may communicate via a network device that may be accessed via host interface 702. In addition to or in lieu of host interface 702 , GPU link 710 may be configured to enable connection to a host processor.
[0185] Although the illustrated configuration of GPGPU 700 may be configured for training neural networks, alternative configurations of GPGPU 700 may be configured for deployment within a high-performance or low-power inference platform. In the inference configuration, relative to the training configuration, GPGPU 700 includes fewer processing clusters in processing clusters 706A-706H. In addition, the memory technology associated with memory 714A-714B may differ between the inference configuration and the training configuration. In one embodiment, the inference configuration of GPGPU 700 may support inference specific instructions. For example, the inference configuration may provide support for one or more 8-bit integer or floating point dot product instructions, which are typically used during inference operations for deployed neural networks.
[0186] Figure 8 A multi-GPU computing system 800 is shown. The multi-GPU computing system 800 may include a processor 802 coupled to a plurality of GPGPUs 806A-806D via a host interface switch 804. The host interface switch 804 may be a PCI Express switch device that couples the processor 802 to a PCI Express bus, through which the processor 802 can communicate with the set of GPGPUs 806A-806D. Each of the plurality of GPGPUs 806A-806D may be Figure 7 806A-806D may be interconnected via a set of high-speed point-to-point GPU-to-GPU links 816. The high-speed GPU-to-GPU links may be connected to each of the GPGPUs 806A-806D via a dedicated GPU link, such as Figure 7 P2P GPU link 816 enables direct communication between each of GPGPUs 806A-806D without requiring communication over a host interface bus to which processor 802 is connected. With GPU-to-GPU traffic directed to the P2P GPU link, the host interface bus remains available for system memory access or for communicating with other instances of multi-GPU computing system 800, for example, via one or more network devices. Figure 8 GPGPUs 806A-806D are connected to processor 802 via host interface switch 804, but processor 802 may alternatively include direct support for P2P GPU link 816 and connect directly to GPGPUs 806A-806D. In one embodiment, P2P GPU link 816 enables multi-GPU computing system 800 to operate as a single logical GPU. Machine Learning Neural Network Implementation
[0187] The computing architecture described herein can be configured to perform a type of parallel processing that is particularly suitable for training and deploying neural networks for machine learning. A neural network can be generalized as a network of functions with a graph relationship. As is known in the art, there are various types of neural network implementations used in machine learning. One exemplary type of neural network is a feedforward network as previously described.
[0188] The second exemplary type of neural network is a convolutional neural network (CNN). A CNN is a specialized feedforward neural network for processing data (such as image data) with a known, grid-like topology. Accordingly, CNNs are commonly used in computer vision and image recognition applications, but they can also be used for other types of pattern recognition, such as speech and language processing. The nodes in the input layer of a CNN are organized as a set of "filters" (feature detectors inspired by the receptive fields found in the retina), and the output of each filter set is propagated to the nodes in the successive layers of the network. The calculations used for a CNN include applying a convolution mathematical operation to each filter to produce the output of the filter. Convolution is a specialized type of mathematical operation performed by two functions to produce a third function, which is a modified version of one of the two original functions. In convolutional network terminology, the first function to the convolution may be referred to as the input, and the second function may be referred to as the convolution kernel. The output may be referred to as a feature map. For example, the input to a convolutional layer may be a multidimensional data array defining the various color components of the input image. The convolution kernel may be a multidimensional parameter array, where the parameters are adapted by a training process for the neural network.
[0189] A recurrent neural network (RNN) is a series of feedforward neural networks that include feedback connections between layers. RNNs enable modeling of sequential data by sharing parameter data across different parts of the neural network. The architecture for RNNs includes loops. These loops represent the effect of the current value of a variable on its own value at future moments, because at least part of the output data from the RNN is used as feedback for processing subsequent inputs in the sequence. This feature makes RNNs particularly useful for language processing due to the mutable nature of language data that can be composed.
[0190] The figures described below present exemplary feedforward networks, CNN networks, and RNN networks, and describe the general process for training and deploying each of those types of networks, respectively. It will be understood that these descriptions are exemplary and non-limiting with respect to any specific embodiments described herein, and that the concepts illustrated are generally applicable to deep neural networks and machine learning techniques in general.
[0191] The exemplary neural network described above can be used to perform deep learning. Deep learning is machine learning using deep neural networks. Unlike shallow neural networks that include only a single hidden layer, the deep neural networks used in deep learning are artificial neural networks composed of multiple hidden layers. Deeper neural networks are generally more computationally intensive to train. However, the additional hidden layers of the network enable multi-step pattern recognition that results in reduced output errors relative to shallow machine learning techniques.
[0192] The deep neural network used in deep learning typically includes a front-end network for performing feature recognition, which is coupled to a back-end network that represents a mathematical model that can perform operations (e.g., object classification, speech recognition, etc.) based on the feature representation provided to the mathematical model. Deep learning enables machine learning to be performed without the need to perform manual feature engineering for the model. In contrast, deep neural networks can learn features based on statistical structures or correlations within the input data. The learned features can be provided to a mathematical model that can map the detected features to an output. The mathematical model used by the network is typically dedicated to a specific task to be performed, and different models will be used to perform different tasks.
[0193] Once the neural network is structured, a learning model can be applied to the network to train the network to perform a specific task. The learning model describes how to adjust the weights within the model to reduce the output error of the network. Back propagation of errors is a common method for training neural networks. An input vector is presented to the network for processing. The output of the network is compared to the desired output using a loss function, and an error value is calculated for each neuron in the output layer. Subsequently, the error values are propagated backward until each neuron has an associated error value that roughly represents the contribution of the neuron to the original output. The network can then learn from those errors using an algorithm (such as a stochastic gradient descent algorithm) to update the weights of the neural network.
[0194] Figure 9A-9B Illustration of an example convolutional neural network. Fig.9A The diagram shows the various layers within a CNN. Fig.9AAs shown in , an exemplary CNN for modeling image processing may receive an input 902 describing the red, green, and blue (RGB) components of an input image. The input 902 may be processed by a plurality of convolutional layers (e.g., convolutional layer 904, convolutional layer 906). The outputs from the plurality of convolutional layers may optionally be processed by a collection of fully connected layers 908. As previously described for feedforward networks, neurons in a fully connected layer have full connections to all activations in the previous layer. The outputs from the fully connected layer 908 may be used to generate output results from the network. Activations within the fully connected layer 908 may be calculated using matrix multiplication instead of convolution. Not all CNN implementations utilize a fully connected layer 908. For example, in some implementations, a convolutional layer 906 may generate the output of a CNN.
[0195] The convolutional layers are sparsely connected, which is different from the traditional neural network configuration found in the fully connected layer 908. Traditional neural network layers are fully connected so that each output unit interacts with each input unit. However, as illustrated, the convolutional layers are sparsely connected because the output of the convolution of the receptive field (rather than the corresponding state value of each node in the receptive field) is input to the nodes of the subsequent layer. The kernel associated with the convolutional layer performs a convolution operation, the output of which is sent to the next layer. The dimensionality reduction performed within the convolutional layer is one aspect that enables CNNs to scale to process large images.
[0196] Fig. 9B Schematic diagram of exemplary computational stages within a convolutional layer of a CNN. An input 912 to a convolutional layer of a CNN may be processed in three stages of a convolutional layer 914. The three stages may include a convolution stage 916, a detector stage 918, and a pooling stage 920. The convolutional layer 914 may then output data to a successive convolutional layer. The final convolutional layer of the network may generate output feature map data or provide input to a fully connected layer, for example to generate a classification value for input to the CNN.
[0197] Several convolutions are performed in parallel in the convolution stage 916 to produce a set of linear activations. The convolution stage 916 may include an affine transformation, which is any transformation that can be specified as a linear transformation plus a translation. Affine transformations include rotations, translations, scaling, and combinations of these transformations. The convolution stage calculates the output of a function (e.g., a neuron) connected to specific regions in the input, which can be determined as local regions associated with the neuron. The neuron calculates the dot product between the weight of the neuron and the weight of the region in the local input to which the neuron is connected. The output from the convolution stage 916 defines a set of linear activations processed by successive stages of the convolution layer 914.
[0198] The linear activations may be processed by the detector stage 918. In the detector stage 918, each linear activation is processed by a nonlinear activation function. The nonlinear activation function increases the nonlinear nature of the overall network without affecting the receptive field of the convolutional layer. Several types of nonlinear activation functions may be used. One particular type is the rectified linear unit (ReLU), which uses an activation function defined as f(x) = max(0, x) so that the threshold of the activation is zero.
[0199] The pooling stage 920 uses a pooling function that replaces the output of the convolutional layer 906 with summary statistics of nearby outputs. The pooling function can be used to introduce translation invariance into the neural network so that a small translation to the input does not change the pooled output. The invariance of local translation can be useful in scenarios where the presence of features in the input data is more important than the precise location of the features. Various types of pooling functions can be used during the pooling stage 920, including maximum pooling, average pooling, and l2 norm pooling. In addition, some CNN implementations do not include a pooling stage. Instead, such implementations are alternative and additional convolution stages with an increased span relative to the previous convolution stage.
[0200] The output from the convolutional layer 914 may then be processed by the next layer 922. The next layer 922 may be an additional convolutional layer or a layer in the fully connected layer 908. For example, Fig.9A The first convolution layer 904 can output to the second convolution layer 906, and the second convolution layer can output to the first layer in the fully connected layer 908.
[0201] Fig.10 An exemplary recurrent neural network 1000 is illustrated. In a recurrent neural network (RNN), the previous state of the network affects the output of the current state of the network. RNNs can be established in various ways and using various functions. The use of RNNs generally revolves around using mathematical models to predict the future based on previous sequences of inputs. For example, RNNs can be used to perform statistical language modeling to predict upcoming words given previous sequences of words. The illustrated RNN 1000 can be described as having an input layer 1002 that receives an input vector, a hidden layer 1004 for implementing a recurrent function, a feedback mechanism 1005 for enabling 'memory' of previous states, and an output layer 1006 for outputting results. The RNN 1000 operates based on time steps. The state of the RNN at a given time step is affected based on previous time steps via the feedback mechanism 1005. For a given time step, the state of the hidden layer 1004 is defined by the previous state and the input at the current time step. The initial input (x) at the first time step 1 ) can be processed by the hidden layer 1004. The second input (x2 ) can be used by the hidden layer 1004 on the initial input (x 1 ) is processed by the state information determined during the processing of ). A given state can be calculated as s t =f(Ux t +Ws t-1 ), where U and W are parameter matrices. Function f is generally nonlinear, such as a variant of the hyperbolic tangent function (Tanh) or a modified function f(x)=max(0,x). However, the specific mathematical function used in hidden layer 1004 may vary depending on the specific implementation details of RNN 1000.
[0202] In addition to the basic CNN and RNN networks described, acceleration for variants of those networks can also be enabled. An example RNN variant is a long short term memory (LSTM) RNN. LSTM RNN is able to learn long-term dependencies, which may be necessary for processing longer language sequences. A variant of CNN is a convolutional deep belief network, which has a similar structure to CNN and is trained in a similar manner to a deep belief network. A deep belief network (DBN) is a generative neural network consisting of multiple layers of stochastic (random) variables. DBN can be trained layer by layer using greedy unsupervised learning. The learned weights of the DBN can then be used to provide a pre-trained neural network by determining the optimal initial set of weights for the neural network. In a further embodiment, acceleration for reinforcement learning is enabled. In reinforcement learning, an artificial agent learns by interacting with its environment. The agent is configured to optimize certain goals to maximize cumulative returns.
[0203] Fig.11 The training and deployment of a deep neural network is illustrated. Once a given network has been structured for a task, the neural network is trained using a training dataset 1102. Various training frameworks 1104 have been developed to enable hardware acceleration of the training process. For example, Figure 6 The machine learning framework 604 can be configured as a training framework 1104. The training framework 1104 can access an untrained neural network 1106 and enable the untrained neural network to be trained using the parallel processing resources described herein to generate a trained neural network 1108.
[0204] To start the training process, weights can be randomly selected or initial weights can be selected by pre-training using a deep belief network. Subsequently, a training cycle is performed in a supervised or unsupervised manner.
[0205] Supervised learning is a learning method in which training is performed as a mediated operation, such as when the training data set 1102 includes an input paired with an expected output of the input, or when the training data set includes an input with a known output and the output of the neural network is manually graded. The network processes the input and compares the resulting output with the expected output or a set of expected outputs. Subsequently, the error is propagated back through the system. The training framework 1104 can be adjusted to adjust the weights that control the untrained neural network 1106. The training framework 1104 can provide tools to monitor how well the untrained neural network 1106 is converging to a model suitable for generating the correct answer based on the known input data. The training process occurs repeatedly as the weights of the network are adjusted to refine the output generated by the neural network. The training process can continue until the neural network reaches a statistically expected accuracy associated with the trained neural network 1108. The trained neural network 1108 can then be deployed to implement any number of machine learning operations to generate inference results 1114 based on the input of new data 1112.
[0206] Unsupervised learning is a learning method in which a network attempts to train itself using unlabeled data. Thus, for unsupervised learning, the training data set 1102 will include input data that does not have any associated output data. The untrained neural network 1106 can learn groupings within the unlabeled inputs and can determine how the individual inputs are related to the entire data set. Unsupervised training can be used to generate a self-organizing map, which is a class of trained neural networks 1108 that can perform operations useful in reducing the dimensionality of the data. Unsupervised training can also be used to perform anomaly detection, which allows identification of data points in the input data set that deviate from the normal pattern of the data.
[0207] Variations of supervised and unsupervised training may also be employed. Semi-supervised learning is a technique in which a mixture of labeled and unlabeled data having the same distribution is included in the training data set 1102. Incremental learning is a variation of supervised learning in which input data is used continuously to further train the model. Incremental learning enables a trained neural network 1108 to adapt to new data 1112 without forgetting the knowledge embedded in the network during initial training.
[0208] Whether supervised or unsupervised, the training process for particularly deep neural networks may be too computationally intensive for a single computing node. The training process can be accelerated using a distributed network of computing nodes rather than using a single computing node.
[0209] Fig. 12Ais a block diagram illustrating distributed learning. Distributed learning is a training model that uses multiple distributed computing nodes to perform supervised or unsupervised training of a neural network. Each of the distributed computing nodes may include one or more host processors or one or more general processing nodes such as Figure 7 A highly parallel general purpose graphics processing unit 700 in FIG. As illustrated, distributed learning can be performed with model parallelism 1202 , data parallelism 1204 , or a combination of model and data parallelism 1206 .
[0210] In model parallelism 1202, different computing nodes in a distributed system can perform training computations for different parts of a single network. For example, each layer of a neural network can be trained by a different processing node of the distributed system. Benefits of model parallelism include the ability to scale to particularly large models. Splitting the computations associated with different layers of a neural network enables training of very large neural networks where the weights of all layers would not fit into the memory of a single node. In some instances, model parallelism can be particularly useful when performing unsupervised training of large neural networks.
[0211] In data parallelism 1204, different nodes of the distributed network have complete instances of the model, and each node receives a different portion of the data. The results from different nodes are then combined. Although different ways to implement data parallelism are possible, all data parallel training methods require techniques to combine the results and synchronize the model parameters between each node. Exemplary methods for combining data include parameter averaging and update-based data parallelism. Parameter averaging trains each node on a subset of the training data, and sets global parameters (e.g., weights, biases) to the average value of the parameters from each node. Parameter averaging uses a central parameter server that maintains parameter data. Update-based data parallelism is similar to parameter averaging, with the exception that updates to the model are transmitted instead of transmitting parameters from the node to the parameter server. In addition, update-based data parallelism can be performed in a decentralized manner, where updates are compressed and transmitted between nodes.
[0212] Combined model and data parallelism 1206 can be implemented, for example, in a distributed system where each computing node includes multiple GPUs. Each node can have a complete instance of the model, where separate GPUs within each node are used to train different parts of the model.
[0213] Distributed training has increased overhead relative to training on a single machine. However, the parallel processors and GPGPUs described herein can each implement various techniques to reduce the overhead of distributed training, including techniques for enabling high-bandwidth GPU-to-GPU data transfer and accelerated remote data synchronization.
[0214] Fig. 12B 1 is a block diagram illustrating a programmable network interface 1210 and a data processing unit. The programmable network interface 1210 is a programmable network engine that can be used to accelerate network-based computing tasks within a distributed environment. The programmable network interface 1210 can be coupled to a host system via a host interface 1270. The programmable network interface 1210 can be used to accelerate network or storage operations for a CPU or GPU of the host system. The host system can be, for example, a node of a distributed learning system for performing distributed training, such as Fig. 12A The host system can also be a data center node in a data center.
[0215] In one embodiment, access to a remote storage device containing model data may be accelerated by the programmable network interface 1210. For example, the programmable network interface 1210 may be configured to present the remote storage device as a local storage device of the host system. The programmable network interface 1210 may also accelerate remote direct memory access (RDMA) operations performed between a GPU of the host system and a GPU of the remote system. In one embodiment, the programmable network interface 1210 may enable storage functions such as, but not limited to, NVME-oF. The programmable network interface 1210 may also accelerate encryption, data integrity, compression, and other operations for the remote storage device on behalf of the host system, thereby allowing the remote storage device to approach the latency of a storage device directly attached to the host system.
[0216] The programmable network interface 1210 may also perform resource allocation and management on behalf of the host system. Storage security operations may be migrated to the programmable network interface 1210 and performed in coordination with the allocation and management of remote storage resources. Network-based operations for managing access to remote storage devices that would otherwise be performed by the host system's processor may be performed by the programmable network interface 1210 instead.
[0217] In one embodiment, network and / or data security operations may be migrated from the host system to the programmable network interface 1210. Data center security policies for data center nodes may be handled by the programmable network interface 1210 rather than by the processor of the host system. For example, the programmable network interface 1210 may detect and mitigate attempted network-based attacks (e.g., DDoS) on the host system, thereby preventing the attack from compromising the availability of the host system.
[0218] The programmable network interface 1210 may include a system on chip (SoC 1220) that executes an operating system via multiple processor cores 1222. The processor core 1222 may include a general-purpose processor (e.g., CPU) core. In one embodiment, the processor core 1222 may also include one or more GPU cores. The SoC 1220 may execute instructions stored in a memory device 1240. The storage device 1250 may store local operating system data. The storage device 1250 and the memory device 1240 may also be used to cache remote data for a host system. The network ports 1260A-1260B enable connection to a network or structure and facilitate network access for the SoC 1220 and facilitate network access for the host system via the host interface 1270. The programmable network interface 1210 may also include an I / O interface 1275, such as a USB interface. The I / O interface 1275 may be used to couple an external device to the programmable network interface 1210 or to couple as a debug interface. Programmable network interface 1210 also includes a management interface 1230 that enables software on a host device to manage and configure programmable network interface 1210 and / or SoC 1220. In one embodiment, programmable network interface 1210 may also include one or more accelerators or GPUs 1245 to accept migration of parallel computing tasks from SoC 1220, a host system, or a remote system coupled via network ports 1260A-1260B. Example Machine Learning Applications
[0219] Machine learning can be applied to solve various technical problems, including but not limited to computer vision, autonomous driving and navigation, speech recognition, and language processing. Computer vision has traditionally been one of the most active research areas for machine learning applications. The application range of computer vision is from reproducing human visual capabilities (such as recognizing faces) to creating new categories of visual capabilities. For example, computer vision applications can be configured to identify sound waves from vibrations induced in objects visible in a video. Parallel processor-accelerated machine learning enables computer vision applications to be trained using significantly larger training data sets than previously feasible training data sets, and enables inference systems to be deployed using low-power parallel processors.
[0220] Parallel processor-accelerated machine learning has autonomous driving applications, including lane and road sign recognition, obstacle avoidance, navigation, and driving control. Accelerated machine learning techniques can be used to train driving models based on data sets that define appropriate responses to specific training inputs. The parallel processors described in this article enable rapid training of increasingly complex neural networks for autonomous driving solutions and enable the deployment of low-power inference processors in mobile platforms suitable for integration into autonomous vehicles.
[0221] Parallel processor-accelerated deep neural networks have enabled machine learning approaches for automatic speech recognition (ASR). ASR involves creating a function that computes the most likely speech sequence given a sequence of input sounds. Accelerated machine learning using deep neural networks has enabled replacements for the hidden Markov models (HMM) and Gaussian mixture models (GMM) previously used for ASR.
[0222] Parallel processor accelerated machine learning can also be used to accelerate natural language processing. The automatic learning process can utilize statistical inference algorithms to produce models that are robust to erroneous or unfamiliar inputs. Exemplary natural language processor applications include automatic machine translation between human languages.
[0223] The parallel processing platform for machine learning can be divided into a training platform and a deployment platform. The training platform is generally highly parallel and includes optimizations for accelerating multi-GPU single-node training and multi-node multi-GPU training. Exemplary parallel processors suitable for training include Figure 7 The general purpose graphics processing unit 700 and Figure 8 The multi-GPU computing system 800 of FIG. In contrast, the deployed machine learning platform generally includes lower-power parallel processors suitable for use in products such as cameras, autonomous robots, and autonomous vehicles.
[0224] In addition, machine learning techniques can also be applied to accelerate or enhance graphics processing activities. For example, a machine learning model can be trained to recognize output generated by a GPU-accelerated application and generate an amplified version of the output. Such techniques can be applied to accelerate the generation of high-resolution images for gaming applications. Various other graphics pipeline activities can benefit from the use of machine learning. For example, a machine learning model can be trained to perform tessellation operations on geometric data to increase the complexity of the geometric model, thereby allowing more detailed geometry to be automatically generated from relatively low-detail geometry.
[0225] Fig.13An exemplary inference system-on-chip (SOC) 1300 suitable for performing inference using a trained model is illustrated. The SOC 1300 may integrate processing components, including a media processor 1302, a visual processor 1304, a GPGPU 1306, and a multi-core processor 1308. The GPGPU 1306 may be a GPGPU described herein, such as GPGPU 700, and the multi-core processor 1308 may be a multi-core processor described herein, such as multi-core processors 405-406. The SOC 1300 may additionally include an on-chip memory 1305 that may enable a shared on-chip data pool that can be accessed by each of the processing components. The processing components may be optimized for low-power operation to enable deployment of various machine learning platforms including autonomous vehicles and autonomous robots. For example, an implementation of the SOC 1300 may be used as part of a master control system for an autonomous vehicle. Where the SOC 1300 is configured for use in an autonomous vehicle, the SOC is designed and configured to comply with relevant functional safety standards of the deployment jurisdiction.
[0226] During operation, the media processor 1302 and the visual processor 1304 can work in tandem to accelerate computer vision operations. The media processor 1302 can enable low latency decoding of multiple high-resolution (e.g., 4K, 8K) video streams. The decoded video streams can be written to a buffer in the on-chip memory 1305. The visual processor 1304 can then parse the decoded video and perform preliminary processing operations on the frames of the decoded video to prepare the frames for processing using a trained image recognition model. For example, the visual processor 1304 can accelerate convolution operations for a CNN that is used to perform image recognition on high-resolution video data, while the back-end model calculations are performed by the GPGPU 1306.
[0227] The multi-core processor 1308 may include control logic for assisting in sequencing and synchronizing data transfers and shared memory operations performed by the media processor 1302 and the vision processor 1304. The multi-core processor 1308 may also act as an application processor for executing software applications that can utilize the inference computing capabilities of the GPGPU 1306. For example, at least a portion of navigation and steering logic may be implemented in software executing on the multi-core processor 1308. Such software may issue computational workloads directly to the GPGPU 1306, or computational workloads may be issued to the multi-core processor 1308, which may migrate at least a portion of those operations to the GPGPU 1306.
[0228] GPGPU 1306 may include a computing cluster, such as low-power configuration processing clusters 706A-706H within general purpose graphics processing unit 700. The computing cluster within GPGPU 1306 may support instructions specifically optimized to perform inference calculations on trained neural networks. For example, GPGPU 1306 may support instructions for performing low-precision calculations such as 8-bit and 4-bit integer vector operations. Additional System Overview
[0229] Fig.14 is a block diagram of processing system 1400 . Fig.14 Elements with the same or similar names as elements of any other figures herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, can include the same components, and can be linked to other entities, such as, but not limited to, those entities described elsewhere herein. System 1400 can be used in: a single-processor desktop computer system, a multi-processor workstation system, or a server system with a large number of processors 1402 or processor cores 1407. System 1400 can be a processing platform incorporated into a system-on-chip (SoC) integrated circuit for use in a mobile device, handheld device, or embedded device, such as, for use in an Internet-of-things (IoT) device with wired or wireless connectivity to a local area network or a wide area network.
[0230] System 1400 may be a system having Figure 1 For example, in different configurations, processor(s) 1402 or processor(s) core(s) 1407 may be associated with Figure 1 The graphics processor(s) 1408 may correspond to the processor(s) 102 of FIG. Figure 1 The external graphics processor 1418 may be Figure 1 One of the (one or more) plug-in devices 120.
[0231] The system 1400 may include, be coupled with, or be integrated into: a server-based gaming platform; a gaming console, including gaming and media consoles; a mobile gaming console, a handheld gaming console, or an online gaming console. The system 1400 may be part of a mobile phone, a smart phone, a tablet computing device, or a mobile internet-connected device, such as a laptop with low internal storage capacity. The processing system 1400 may also include, be coupled with, or be integrated into: a wearable device, such as a smart watch wearable device; smart glasses or clothing that is enhanced with augmented reality (AR) or virtual reality (VR) features to provide visual, audio, or tactile output to supplement the real-world visual, audio, or tactile experience or otherwise provide text, audio, graphics, video, holographic images or video, or tactile feedback; other augmented reality (AR) devices; or other virtual reality (VR) devices. The processing system 1400 may include, or may be part of a television or set-top box device. System 1400 may include, be coupled to, or be integrated within an autonomous vehicle, such as a bus, a tractor trailer, an automobile, an electric or electrical cycle, an airplane, or a glider (or any combination thereof). An autonomous vehicle may use system 1400 to process the environment sensed around the vehicle.
[0232] The one or more processors 1402 may include one or more processor cores 1407 for processing instructions that, when executed, perform operations for system and user software. At least one of the one or more processor cores 1407 may be configured to process a specific instruction set 1409. The instruction set 1409 may facilitate complex instruction set computing (CISC), reduced instruction set computing (RISC), or computing via very long instruction words (VLIW). The one or more processor cores 1407 may process different instruction sets 1409, which may include instructions for facilitating emulation of other instruction sets. The processor core 1407 may also include other processing devices, such as a digital signal processor (DSP).
[0233] The processor 1402 may include a cache memory 1404. Depending on the architecture, the processor 1402 may have a single internal cache or multiple levels of internal cache. In some embodiments, the cache memory is shared between various components of the processor 1402. In some embodiments, the processor 1402 also uses an external cache (e.g., a third level (L3) cache or a last level cache (Last Level Cache, LLC)) (not shown), which can be shared between the processor cores 1407 using known cache coherence techniques. A register file 1406 may additionally be included in the processor 1402 and may include different types of registers (e.g., integer registers, floating point registers, status registers, and instruction pointer registers) for storing different types of data. Some registers may be general purpose registers, while other registers may be specific to the design of the processor 1402.
[0234] One or more processors 1402 may be coupled to one or more interface buses 1410 to transmit communication signals, such as address, data, or control signals, between the processor 1402 and other components in the system 1400. In one of these embodiments, the interface bus 1410 may be a processor bus, such as a version of a Direct Media Interface (DMI) bus. However, the processor bus is not limited to a DMI bus and may include one or more peripheral component interconnect buses (e.g., PCI, PCI Express), memory buses, or other types of interface buses. For example, the processor(s) 1402 may include an integrated memory controller 1416 and a platform controller hub 1430. The memory controller 1416 facilitates communication between memory devices and other components of the system 1400, while the platform controller hub (PCH) 1430 provides connections to I / O devices via a local I / O bus.
[0235] The memory device 1420 may be a dynamic random access memory (DRAM) device, a static random access memory (SRAM) device, a flash memory device, a phase change memory device, or some other memory device having suitable performance to act as a process memory. The memory device 1420 may, for example, operate as a system memory for the system 1400 to store data 1422 and instructions 1421 for use when one or more processors 1402 execute applications or processes. The memory controller 1416 is also coupled to an optional external graphics processor 1418, which may communicate with one or more graphics processors 1408 in the processor 1402 to perform graphics operations and media operations. In some embodiments, graphics operations, media operations, and / or computing operations may be assisted by an accelerator 1412, which is a coprocessor that may be configured to perform a collection of specialized graphics operations, media operations, or computing operations. For example, the accelerator 1412 may be a matrix multiplication accelerator for optimizing machine learning or computing operations. The accelerator 1412 may be a ray tracing accelerator that may be used to perform ray tracing operations in coordination with the graphics processor 1408. In one embodiment, an external accelerator 1419 may be used instead of the accelerator 1412 or in coordination with the accelerator 1412.
[0236] A display device 1411 may be provided and may be connected to the processor(s) 1402. The display device 1411 may be one or more of an internal display device, such as in a mobile electronic device or laptop device, or an external display device attached via a display interface (e.g., a display port, etc.). The display device 1411 may be a head mounted display (HMD), such as a stereoscopic display device for use in virtual reality (VR) applications or augmented reality (AR) applications.
[0237] The platform controller hub 1430 can enable peripheral devices to be connected to the memory device 1420 and the processor 1402 via a high-speed I / O bus. The I / O peripherals include, but are not limited to, an audio controller 1446, a network controller 1434, a firmware interface 1428, a wireless transceiver 1426, a touch sensor 1425, a data storage device 1424 (e.g., non-volatile memory, volatile memory, hard drive, flash memory, NAND, 3D NAND, 3D Xpoint / Optane, etc.). The data storage device 1424 can be connected via a storage interface (e.g., SATA) or via a peripheral bus (e.g., PCI, PCI Express). The touch sensor 1425 can include a touch screen sensor, a pressure sensor, or a fingerprint sensor. The wireless transceiver 1426 can be a Wi-Fi transceiver, a Bluetooth transceiver, or a mobile network transceiver, such as a 3G, 4G, 5G, or Long-Term Evolution (LTE) transceiver. The firmware interface 1428 enables communication with the system firmware and can be, for example, a unified extensible firmware interface (UEFI). The network controller 1434 can enable network connection to a wired network. In some embodiments, a high-performance network controller (not shown) is coupled to the interface bus 1410. The audio controller 1446 can be a multi-channel high-definition audio controller. In some of these embodiments, the system 1400 includes an optional traditional I / O controller 1440 for coupling traditional (e.g., Personal System 2 (PS / 2)) devices to the system. The platform controller hub 1430 can also be connected to one or more Universal Serial Bus (USB) controllers 1442 to connect to input devices, such as a keyboard and mouse 1443 combination, a camera 1444, or other USB input devices.
[0238] It will be appreciated that the illustrated system 1400 is exemplary and not limiting, as other types of data processing systems configured in different manners may also be used. For example, instances of the memory controller 1416 and the platform controller hub 1430 may be integrated into a discrete external graphics processor, such as the external graphics processor 1418. The platform controller hub 1430 and / or the memory controller 1416 may be external to the one or more processors 1402. For example, the system 1400 may include the external memory controller 1416 and the platform controller hub 1430, which may be configured as a memory controller hub and a peripheral controller hub within a system chipset that communicates with the processor(s) 1402.
[0239] For example, a circuit board ("sled") may be used on which components (such as CPUs, memory and other components) are placed and on which components (such as CPUs, memory and other components) are designed to achieve improved thermal performance. Processing components such as processors may be located on the top side of the sled, while nearby memory such as DIMMs are located on the bottom side of the sled. As a result of the enhanced airflow provided by the design, components can operate at higher frequencies and power levels than in typical systems, thereby improving performance. In addition, the sled is configured to blindly mate power and data communication cables in a rack, thereby enhancing their ability to be quickly removed, upgraded, reinstalled and / or replaced. Similarly, the various components (such as processors, accelerators, memory and data storage drives) located on the sled are configured to be easily upgraded due to their increased spacing from each other. In an illustrative embodiment, the components additionally include hardware authentication features for proving their authenticity.
[0240] The data center may utilize a single network architecture ("fabric") that supports multiple other network architectures, including Ethernet and omni-path. The sleds may be coupled to the switches via optical fiber, which provides higher bandwidth and lower latency than typical twisted pair cabling (e.g., Category 5, Category 5e, Category 6, etc.). Due to the high-bandwidth, low-latency interconnect and network architecture, the data center may, in use, centralize physically dispersed resources such as memory, accelerators (e.g., GPUs, graphics accelerators, FPGAs, ASICs, neural network and / or artificial intelligence accelerators, etc.), and data storage drives, and provide them to computing resources (e.g., processors) as needed, thereby enabling the computing resources to access these centralized resources as if the centralized resources were local.
[0241] A power supply or power source may provide voltage and / or current to the system 1400 or any component or system described herein. In one example, the power supply includes an AC to DC (alternating current to direct current) adapter for plugging into a wall socket. Such AC power may be a renewable energy (e.g., solar) power source. In one example, the power source includes a DC power source, such as an external AC to DC converter. The power source or power supply may also include wireless charging hardware for charging by approaching a charging field. The power source may include an internal battery, an AC supply, a motion-based power supply, a solar power supply, or a fuel cell source.
[0242] Figure 15A-Figure 15C Illustration of a computing system and a graphics processor. Figure 15A-Figure 15C Elements having the same or similar names as elements of any other figures herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, may include the same components, and may be linked to other entities such as, but not limited to, those described elsewhere herein.
[0243] Fig.15A1402. It is a block diagram of a processor 1500, which may be a variant of one of the processors 1402 and may be used in place of one of those processors. Therefore, the disclosure of any feature herein in conjunction with the processor 1500 also discloses the corresponding combination with (one or more) processors 1402, but is not limited thereto. The processor 1500 may have one or more processor cores 1502A-1502N, an integrated memory controller 1514, and an integrated graphics processor 1508. In the case where the integrated graphics processor 1508 is excluded, a system including the processor will include a graphics processor device within a system chipset or coupled via a system bus. The processor 1500 may include additional cores, up to and including additional cores 1502N represented by dashed boxes. Each of the processor cores 1502A-1502N includes one or more internal cache units 1504A-1504N. In some embodiments, each processor core 1502A-1502N also has access to one or more shared cache units 1506. The internal cache units 1504A-1504N and the shared cache units 1506 represent a cache memory hierarchy within the processor 1500. The cache memory hierarchy may include at least one level of instruction and data cache within each processor core and one or more levels of shared mid-level cache, such as a second level (L2), third level (L3), fourth level (L4), or other level of cache, where the highest level of cache before external memory is classified as LLC. In some embodiments, cache coherency logic maintains coherency between each cache unit 1506 and 1504A-1504N.
[0244] The processor 1500 may also include a set of one or more bus controller units 1516 and a system agent core 1510. The one or more bus controller units 1516 manage a set of peripheral buses, such as one or more PCI buses or PCI Express buses. The system agent core 1510 provides management functions for various processor components. The system agent core 1510 may include one or more integrated memory controllers 1514 for managing access to various external memory devices (not shown).
[0245] For example, one or more of the processor cores 1502A-1502N may include support for simultaneous multithreaded operations. The system agent core 1510 includes components for coordinating and operating the cores 1502A-1502N during multithreaded processing. The system agent core 1510 may additionally include a power control unit (PCU) that includes logic and components for regulating the power state of the processor cores 1502A-1502N and the graphics processor 1508.
[0246] The processor 1500 may additionally include a graphics processor 1508 for performing graphics processing operations. In some of these embodiments, the graphics processor 1508 is coupled to a set of shared cache units 1506 and a system agent core 1510, which includes one or more integrated memory controllers 1514. The system agent core 1510 may also include a display controller 1511 for driving the graphics processor output to one or more coupled displays. The display controller 1511 may also be a separate module coupled to the graphics processor via at least one interconnect, or may be integrated within the graphics processor 1508.
[0247] A ring-based interconnect 1512 may be used to couple internal components of the processor 1500. However, alternative interconnect units may be used, such as point-to-point interconnects, switched interconnects, or other technologies, including those known in the art. In some of these embodiments with a ring-based interconnect 1512, the graphics processor 1508 is coupled to the ring-based interconnect 1512 via an I / O link 1513.
[0248] Exemplary I / O link 1513 represents at least one of a plurality of various I / O interconnects, including an on-package I / O interconnect that facilitates communication between various processor components and a high-performance memory module 1518, such as an eDRAM module or a high-bandwidth memory (HMB) module. Optionally, each of processor cores 1502A-1502N and graphics processor 1508 may use high-performance memory module 1518 as a shared last-level cache.
[0249] The processor cores 1502A-1502N may be, for example, isomorphic cores that execute the same instruction set architecture. Alternatively, the processor cores 1502A-1502N are heterogeneous in terms of instruction set architecture (ISA), wherein one or more of the processor cores 1502A-1502N execute a first instruction set and at least one of the other cores executes a subset of the first instruction set or a different instruction set. The processor cores 1502A-1502N may be heterogeneous in terms of microarchitecture, wherein one or more cores with relatively high power consumption are coupled with one or more power cores with lower power consumption. As another example, the processor cores 1502A-1502N are heterogeneous in terms of computing power. In addition, the processor 1500 may be implemented on one or more chips, or as a SoC integrated circuit having the illustrated components in addition to other components.
[0250] Fig. 15B is a block diagram of the hardware logic of the graphics processor core block 1519 according to some embodiments described herein. In some embodiments, Fig. 15B Elements having the same reference numerals (or names) as elements of any other figure herein may operate or function in a manner similar to that described elsewhere herein. In one embodiment, graphics processor core block 1519 is an example of a partition of a graphics processor. Graphics processor core block 1519 may be included in Fig.15A The graphics processor 1508 may be integrated into the graphics processor 1508 or a discrete graphics processor, parallel processor and / or computing accelerator. A graphics processor as described herein may include multiple graphics core blocks based on a target power and performance envelope. Each graphics processor core block 1519 may include a functional block 1530 coupled to multiple graphics cores 1521A-1521F, and the multiple graphics cores 1521A-1521F include modular blocks of fixed function logic and general programmable logic. The graphics processor core block 1519 also includes a shared / cache memory 1536 that can be accessed by all graphics cores 1521A-1521F, rasterizer logic 1537, and additional fixed function logic 1538.
[0251] In some embodiments, functional block 1530 includes a geometry / fixed function pipeline 1531 that can be shared by all graphics cores in graphics processor core block 1519. In various embodiments, geometry / fixed function pipeline 1531 includes a 3D geometry pipeline, a video front end unit, a thread generator and a global thread dispatcher, and a unified return buffer manager that manages a unified return buffer. In one embodiment, functional block 1530 also includes a graphics SoC interface 1532, a graphics microcontroller 1533, and a media pipeline 1534. Graphics SoC interface 1532 provides an interface between graphics processor core block 1519 and other core blocks within a graphics processor or computing accelerator SoC. Graphics microcontroller 1533 is a programmable subprocessor that can be configured to manage various functions of graphics processor core block 1519, including thread dispatching, scheduling, and preemption. Media pipeline 1534 includes logic for facilitating decoding, encoding, preprocessing, and / or post-processing of multimedia data (including image and video data). The media pipeline 1534 implements media operations via requests to computational or sampling logic within the graphics cores 1521A-1521F. One or more pixel backends 1535 may also be included within the functional block 1530. The pixel backend 1535 includes a buffer memory for storing pixel color values and is capable of performing blending operations and lossless color compression on rendered pixel data.
[0252] In one embodiment, the graphics SoC interface 1532 enables the graphics processor core block 1519 to communicate with a general-purpose application processor core (e.g., CPU) and / or other components within the SoC or within a system host CPU coupled to the SoC via a peripheral interface. The graphics SoC interface 1532 also enables communication with off-chip memory hierarchy elements, such as shared last-level cache memory, system RAM, and / or embedded on-chip or on-package DRAM. The SoC interface 1532 can also enable communication with fixed-function devices within the SoC, such as a camera imaging pipeline, and enable the use and / or implementation of global memory atomicity, which can be shared between the graphics processor core block 1519 and the CPU within the SoC. The graphics SoC interface 1532 can also implement power management controls for the graphics processor core block 1519 and enable interfaces between the clock domain of the graphics processor core block 1519 and other clock domains within the SoC. In one embodiment, graphics SoC interface 1532 enables receiving command buffers from a command stream converter and global thread dispatcher configured to provide commands and instructions to each of one or more graphics cores within a graphics processor. Commands and instructions can be dispatched to media pipeline 1534 when media operations are to be performed, and can be dispatched to geometry and fixed function pipeline 1531 when graphics processing operations are to be performed. When compute operations are to be performed, compute dispatch logic can dispatch commands to graphics cores 1521A-1521F, thereby bypassing the geometry pipeline and the media pipeline.
[0253] The graphics microcontroller 1533 may be configured to perform various scheduling and management tasks for the graphics processor core block 1519. In one embodiment, the graphics microcontroller 1533 may execute graphics workloads and / or computational workloads scheduled on the various vector engines 1522A-1522F, 1524A-1524F and matrix engines 1523A-1523F, 1525A-1525F within the graphics cores 1521A-1521F. In this scheduling model, host software executed on the CPU core of the SoC including the graphics processor core block 1519 may submit a workload to one of a plurality of graphics processor doorbells, which invokes a scheduling operation to the appropriate graphics engine. The scheduling operation includes determining which workload to run next, submitting the workload to the command stream converter, preempting an existing workload running on the engine, monitoring the progress of the workload, and notifying the host software when the workload is completed. In one embodiment, the graphics microcontroller 1533 can also facilitate a low power or idle state for the graphics processor core block 1519, thereby providing the graphics processor core block 1519 with the ability to save and restore registers within the graphics processor core block 1519 across low power state transitions independent of the operating system and / or graphics driver software on the system.
[0254] The graphics processor core block 1519 may have more or less than the illustrated graphics cores 1521A-1521F, up to a maximum of N modular graphics cores. For each set of N graphics cores, the graphics processor core block 1519 may also include: a shared / cache memory 1536, which may be configured as a shared memory or a cache memory; a rasterizer logic 1537; and additional fixed function logic 1538 for accelerating various graphics and compute processing operations.
[0255] Included within each graphics core 1521A-1521F is a collection of execution resources that can be used to perform graphics operations, media operations, and compute operations in response to requests made by a graphics pipeline, a media pipeline, or a shader program. Graphics cores 1521A-1521F include multiple vector engines 1522A-1522F, 1524A-1524F, matrix acceleration units 1523A-1523F, 1525A-1525D, cache / shared local memory (SLM), samplers 1526A-1526F, and ray tracing units 1527A-1527F.
[0256] The vector engines 1522A-1522F, 1524A-1524F are general purpose graphics processing units capable of performing floating point and integer / fixed point logic operations to serve graphics operations, media operations, or computing operations (including graphics programs, media programs, or computing / GPGPU programs). The vector engines 1522A-1522F, 1524A-1524F are capable of operating with variable vector widths using SIMD execution mode, SIMT execution mode, or SIMT+SIMD execution mode. The matrix acceleration units 1523A-1523F, 1525A-1525D include matrix-matrix and matrix-vector acceleration logic that improves the performance of matrix operations, especially low-precision and mixed-precision (e.g., INT8, FP16, BF16, FP8) matrix operations for machine learning. In one embodiment, each of the matrix acceleration units 1523A-1523F, 1525A-1525D includes one or more systolic arrays of processing elements capable of performing concurrent matrix multiplication or dot product operations on matrix elements.
[0257] Samplers 1526A-1526F can read media data or texture data into memory and can sample data in different ways based on the configured sampler state and the texture / media format being read. Threads executing on vector engines 1522A-1522F, 1524A-1524F or matrix acceleration units 1523A-1523F, 1525A-1525D can utilize caches / SLMs 1528A-1528F within each of graphics cores 1521A-1521F. Caches / SLMs 1528A-1528F can be configured as a pool of cache memory or shared memory local to each of the corresponding graphics cores 1521A-1521F. Ray tracing units 1527A-1527F within graphics cores 1521A-1521F include ray traversal / intersection circuitry for performing ray traversals using a bounding volume hierarchy (BVH) and identifying intersections between rays and primitives enclosed within the BVH volume. In one embodiment, ray tracing units 1527A-1527F include circuitry for performing depth testing and culling (e.g., using a depth buffer or similar arrangement). In one implementation, ray tracing units 1527A-1527F perform traversal and intersection operations in coordination with image denoising, at least a portion of which may be performed using associated matrix acceleration units 1523A-1523F, 1525A-1525D.
[0258] Fig. 15C15 is a block diagram of a general purpose graphics processing unit (GPGPU) 1570 according to an embodiment described herein, which GPGPU 1570 can be configured as a graphics processor (e.g., graphics processor 1508) and / or a computing accelerator. GPGPU 1570 can be interconnected with a host processor (e.g., one or more CPUs 1546) and memories 1571, 1572 via one or more system and / or memory buses. Memory 1571 can be system memory that can be shared with one or more CPUs 1546, while memory 1572 is device memory dedicated to GPGPU 1570. For example, components within GPGPU 1570 and memory 1572 can be mapped to memory addresses that can be accessed by one or more CPUs 1546. Access to memories 1571 and 1572 can be facilitated via a memory controller 1568. Memory controller 1568 may include an internal direct memory access (DMA) controller 1569, or may include logic for performing operations that would otherwise be performed by a DMA controller.
[0259] GPGPU 1570 includes a plurality of cache memories, including an L2 cache 1553, an L1 cache 1554, an instruction cache 1555, and a shared memory 1556, at least a portion of which may also be partitioned as a cache memory. GPGPU 1570 also includes a plurality of computing units 1560A-1560N. Each computing unit 1560A-1560N includes a set 1561 of vector registers, a set 1562 of scalar registers, a set 1563 of vector logic units, and a set 1564 of scalar logic units. Computing units 1560A-1560N may also include a local shared memory 1565 and a program counter 1566. Computing units 1560A-1560N may be coupled to a constant cache 1567, which may be used to store constant data, which is data that does not change during the execution of a kernel program or a shader program executed on GPGPU 1570. The constant cache 1567 may be a scalar data cache, and the cached data may be directly fetched into the scalar register 1562 .
[0260] During operation, one or more CPUs 1546 may write commands to registers in GPGPU 1570, or to memory in GPGPU 1570 that has been mapped into an accessible address space. Command processor 1557 may read commands from registers or memory and determine how to process those commands within GPGPU 1570. Thread dispatcher 1558 may then be used to dispatch threads to computing units 1560A-1560N to execute those commands. Each computing unit 1560A-1560N may execute threads independently of other computing units. In addition, each computing unit 1560A-1560N may be independently configured for conditional computation and may conditionally output the results of the computation to memory. Command processor 1557 may interrupt one or more CPUs 1546 when the submitted commands are completed.
[0261] Figure 16A-16C The diagram is described in this article, for example according to Figure 15A-Figure 15C The embodiments provide block diagrams of additional graphics processor and computing accelerator architectures. Figure 16A-16C Elements having the same or similar names as elements of any other figures herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, may include the same components, and may be linked to other entities such as, but not limited to, those described elsewhere herein.
[0262] Fig.16A 1 is a block diagram of a graphics processor 1600, which may be a discrete graphics processing unit, or may be a graphics processor integrated with multiple processing cores or other semiconductor devices, such as, but not limited to, memory devices or network interfaces. Graphics processor 1600 may be a variant of graphics processor 1508 and may be used in place of graphics processor 1508. Therefore, the disclosure of any feature herein in conjunction with graphics processor 1508 also discloses the corresponding combination with graphics processor 1600, but is not limited thereto. The graphics processor may communicate via a memory-mapped I / O interface to registers on the graphics processor and using commands placed into processor memory. Graphics processor 1600 may include a memory interface 1614 for accessing memory. Memory interface 1614 may be an interface to local memory, one or more internal caches, one or more shared external caches, and / or to system memory.
[0263] Optionally, graphics processor 1600 also includes a display controller 1602 for driving display output data to a display device 1618. Display controller 1602 includes hardware for compositing one or more overlay planes of a display and multiple layers of video or user interface elements. Display device 1618 can be an internal or external display device. In one embodiment, display device 1618 is a head mounted display device, such as a virtual reality (VR) display device or an augmented reality (AR) display device. The graphics processor 1600 may include a video codec engine 1606 for encoding media into one or more media coding formats, decoding media from one or more media coding formats, or transcoding media between one or more media coding formats, including but not limited to: Moving Picture Experts Group (MPEG) formats (such as MPEG-2), Advanced Video Coding (AVC) formats (such as H.264 / MPEG-4AVC, H.265 / HEVC, Alliance for Open Media (AOMedia) VP8, VP9), and the Society of Motion Picture & Television Engineers (SMPTE) 421M / VC-1, and Joint Photographic Experts Group (JPEG) formats (such as JPEG and Motion JPEG (MJPEG) formats).
[0264] Graphics processor 1600 may include a block image transfer (BLIT) engine 1603 for performing two-dimensional (2D) rasterizer operations, including, for example, bit-boundary block transfers. However, alternatively, 2D graphics operations may be performed using one or more components of a graphics processing engine (GPE) 1610. In some embodiments, GPE 1610 is a compute engine for performing graphics operations, including three-dimensional (3D) graphics operations and media operations.
[0265] GPE 1610 may include a 3D pipeline 1612 for performing 3D operations, such as rendering three-dimensional images and scenes using processing functions that act on 3D primitive shapes (e.g., rectangles, triangles, etc.). 3D pipeline 1612 includes programmable and fixed-function elements that perform various tasks within the element and / or spawn execution threads to 3D / media subsystem 1615. While 3D pipeline 1612 may be used to perform media operations, embodiments of GPE 1610 also include a media pipeline 1616 that is specifically used to perform media operations, such as video post-processing and image enhancement.
[0266] The media pipeline 1616 may include fixed-function or programmable logic units for performing one or more specialized media operations, such as video decoding acceleration, video deinterlacing, and video encoding acceleration, instead of, or on behalf of, the video codec engine 1606. The media pipeline 1616 may additionally include a thread generation unit for generating threads for execution on the 3D / media subsystem 1615. The generated threads perform calculations for media operations on one or more graphics execution units included in the 3D / media subsystem 1615.
[0267] 3D / media subsystem 1615 may include logic for executing threads generated by 3D pipeline 1612 and media pipeline 1616. The pipeline may send thread execution requests to 3D / media subsystem 1615, which includes thread dispatch logic for arbitrating and dispatching various requests for available thread execution resources. Execution resources include an array of graphics execution units for processing 3D threads and media threads. 3D / media subsystem 1615 may include one or more internal caches for thread instructions and data. In addition, 3D / media subsystem 1615 may also include shared memory for sharing data between threads and for storing output data, which includes registers and addressable memory.
[0268] Fig. 16B Graphics processor 1620 is shown, which is a variant of graphics processor 1600 and can be used in place of graphics processor 1600 and vice versa. Therefore, any feature disclosed herein in conjunction with graphics processor 1600 also discloses the corresponding combination with graphics processor 1620, but is not limited thereto. According to the embodiments described herein, graphics processor 1620 has a sliced architecture. Graphics processor 1620 may include graphics processing engine cluster 1622, which has graphics engine slices 1610A-1610D. Fig.16AMultiple instances of the graphics processing engine 1610 of the graphics processing engine 1610. Each graphics engine slice 1610A-1610D can be interconnected via a set of slice interconnects 1623A-1623F. Each graphics engine slice 1610A-1610D can also be connected to a memory module or memory device 1626A-1626D via a memory interconnect 1625A-1625D. The memory device 1626A-1626D can use any graphics memory technology. For example, the memory device 1626A-1626D can be a graphics double data rate (GDDR) memory. The memory device 1626A-1626D can be a high bandwidth memory (HBM) module, which can be on the die with its corresponding graphics engine slice 1610A-1610D. The memory device 1626A-1626D can be a stacked memory device that can be stacked on top of its corresponding graphics engine slice 1610A-1610D. Each graphics engine slice 1610A-1610D and associated memory 1626A-1626D may reside on separate chiplets that are bonded to a base die or base substrate, such as in Figure 24B-Figure 24D As described in further detail in .
[0269] Graphics processor 1620 may be configured with a non-uniform memory access (NUMA) system in which memory devices 1626A-1626D are coupled to associated graphics engine slices 1610A-1610D. A given memory device may be accessed by a graphics engine slice different from the graphics engine slice to which the memory device is directly connected. However, when accessing the local slice, access latency to memory devices 1626A-1626D may be minimized. In one embodiment, a cache coherent NUMA (ccNUMA) system is enabled that uses slice interconnects 1623A-1623F to enable communication between cache controllers within graphics engine slices 1610A-1610D to maintain a consistent memory image when more than one cache stores the same memory location.
[0270] The graphics processing engine cluster 1622 may be connected to an on-chip or on-package fabric interconnect 1624. In one embodiment, the fabric interconnect 1624 includes a network processor, a network on a chip (NoC), or another switching processor for enabling the fabric interconnect 1624 to function as a packet-switched fabric interconnect for exchanging data packets between components of the graphics processor 1620. The fabric interconnect 1624 may enable communication between the graphics engine slices 1610A-1610D and components such as the video codec 1606 and one or more replication engines 1604. The replication engines 1604 may be used to move data out of the memory devices 1626A-1626D and memory external to the graphics processor 1620 (e.g., system memory), move data into the memory devices 1626A-1626D and memory external to the graphics processor 1620 (e.g., system memory), and move data between the memory devices 1626A-1626D and memory external to the graphics processor 1620 (e.g., system memory). Fabric interconnect 1624 may also be used to interconnect graphics engine slices 1610A-1610D. Graphics processor 1620 may optionally include display controller 1602 to enable connection to external display device 1618. Graphics processor may also be configured as a graphics accelerator or a computing accelerator. In an accelerator configuration, display controller 1602 and display device 1618 may be omitted.
[0271] Graphics processor 1620 may be connected to a host system via host interface 1628. Host interface 1628 may enable communication between graphics processor 1620, system memory, and / or other system components. Host interface 1628 may be, for example, a PCI Express bus or another type of host system interface. For example, host interface 1628 may be an NVLink or NVSwitch interface. Host interface 1628 and fabric interconnect 1624 may collaborate to enable multiple instances of graphics processor 1620 to act as a single logical device. Collaboration between host interface 1628 and fabric interconnect 1624 may also enable individual graphics engine slices 1610A-1610D to be presented to the host system as different logical graphics devices.
[0272] Fig. 16C FIG. 16 shows a computing accelerator 1630 according to an embodiment described herein. The computing accelerator 1630 may include Fig. 16BThe computing engine cluster 1632 may include a collection of computing engine slices 1640A-1640D, which include execution logic optimized for parallel or vector-based general-purpose computing operations. The computing engine slices 1640A-1640D may not include fixed-function graphics processing logic, but in some embodiments, one or more of the computing engine slices 1640A-1640D may include logic for performing media acceleration. The computing engine slices 1640A-1640D may be connected to the memory 1626A-1626D via the memory interconnect 1625A-1625D. The memory 1626A-1626D and the memory interconnect 1625A-1625D may be similar technologies as in the graphics processor 1620, or may be different technologies. The compute engine slices 1640A-1640D may also be interconnected via a set of slice interconnects 1623A-1623F and may be connected to and / or interconnected through a fabric interconnect 1624. In one embodiment, the compute accelerator 1630 includes a large L3 cache 1636 that may be configured as a device-wide cache. The compute accelerator 1630 may also be configured to communicate with Fig. 16B Graphics processor 1620 is similarly connected to a host processor and memory via host interface 1628 .
[0273] The computing accelerator 1630 may also include an integrated network interface 1642. In one embodiment, the integrated network interface 1642 includes a network processor and controller logic that enables the computing engine cluster 1632 to communicate over a physical layer interconnect 1644 without the data having to traverse the memory of the host system. In one embodiment, one of the computing engine slices 1640A-1640D is replaced by the network processor logic, and data to be transmitted or received via the physical layer interconnect 1644 may be transmitted directly to or from the memory 1626A-1626D. Multiple instances of the computing accelerator 1630 may be combined into a single logical device via the physical layer interconnect 1644. Alternatively, each computing engine slice 1640A-1640D may be presented as a different network accessible computing accelerator device. Graphics processing engine
[0274] Fig.17 1 is a block diagram of a graphics processing engine 1710 of a graphics processor according to some embodiments. The graphics processing engine (GPE) 1710 may be Fig.16A A version of the GPE 1610 shown in FIG. 1610 and may also represent Fig. 16B Graphics engine slices 1610A-1610D. Fig.17Elements with the same or similar names as elements of any other figure herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, can include the same components, and can be linked to other entities such as, but not limited to, those described elsewhere in this document. For example, in Fig.17 Also shown in the figure Fig.16A 1710. The 3D pipeline 1612 and the media pipeline 1616 of the GPE 1710. The media pipeline 1616 is optional in some embodiments of the GPE 1710 and may not be explicitly included in the GPE 1710. For example and in at least one embodiment, separate media and / or image processors are coupled to the GPE 1710.
[0275] The GPE 1710 may be coupled to or include a command stream converter 1703 that provides a command stream to the 3D pipeline 1612 and / or the media pipeline 1616. Alternatively or additionally, the command stream converter 1703 may be directly coupled to a unified return buffer 1718. The unified return buffer 1718 may be communicatively coupled to the graphics core cluster 1714. Optionally, the command stream converter 1703 is coupled to a memory, which may be a system memory, or one or more of an internal cache memory and a shared cache memory. The command stream converter 1703 may receive commands from the memory and send these commands to the 3D pipeline 1612 and / or the media pipeline 1616. These commands are instructions taken from a ring buffer that stores commands for the 3D pipeline 1612 and the media pipeline 1616. The ring buffer may additionally include a batch command buffer that stores a batch of multiple commands. Commands for the 3D pipeline 1612 may also include references to data stored in memory, such as, but not limited to, vertex data and geometry data for the 3D pipeline 1612 and / or image data and memory objects for the media pipeline 1616. The 3D pipeline 1612 and the media pipeline 1616 process commands and data by performing operations via logic within the corresponding pipelines or by dispatching one or more execution threads to the graphics core cluster 1714. The graphics core cluster 1714 may include one or more graphics core blocks (e.g., graphics core block 1715A, graphics core block 1715B), each block including one or more graphics cores. Each graphics core includes a collection of graphics execution resources, including: general and graphics-specific execution logic for performing graphics operations and compute operations; and fixed-function texture processing logic and / or machine learning and artificial intelligence acceleration logic.
[0276] In various embodiments, the 3D pipeline 1612 may include fixed function and programmable logic for processing one or more shader programs, such as vertex shaders, geometry shaders, pixel shaders, fragment shaders, compute shaders, or other shader programs, by processing instructions and dispatching execution threads to the graphics core cluster 1714. The graphics core cluster 1714 provides a unified execution resource block for use in processing these shader programs. The multi-function execution logic (e.g., execution units) within the graphics core blocks 1715A-1715B of the graphics core cluster 1714 includes support for various 3D API shader languages and can execute multiple simultaneous execution threads associated with multiple shaders.
[0277] Graphics core cluster 1714 may include execution logic for performing media functions such as video and / or image processing. In addition to graphics processing operations, the execution units may also include general purpose logic that can be programmed to perform parallel general purpose computing operations. The general purpose logic may be performed in parallel or in combination with Fig.14 (one or more) processor cores 1407 or Fig.15A The processing operations are performed by the general logic within cores 1502A-1502N.
[0278] Output data generated by threads executing on graphics core cluster 1714 can output data to memory in unified return buffer (URB) 1718. URB 1718 can store data for multiple threads. URB 1718 can be used to send data between different threads executing on graphics core cluster 1714. URB 1718 can additionally be used for synchronization between threads on graphics core cluster 1714 and fixed function logic within shared function logic 1720.
[0279] Optionally, graphics core cluster 1714 may be scalable such that the array includes a variable number of graphics cores, each with a variable number of execution units based on the target power and performance level of GPE 1710. Execution resources may be dynamically scalable such that execution resources may be enabled or disabled as needed.
[0280] The graphics core cluster 1714 is coupled to shared function logic 1720, which includes a plurality of resources shared between the graphics cores in the graphics core array. The shared functions within the shared function logic 1720 are hardware logic units that provide specialized supplemental functions to the graphics core cluster 1714. In various embodiments, the shared function logic 1720 includes, but is not limited to, sampler 1721 logic, math 1722 logic, and inter-thread communication (ITC) 1723 logic. In addition, one or more caches 1725 within the shared function logic 1720 may be implemented.
[0281] Shared functionality is implemented at least in cases where demand for a given specialized function is insufficient to be included within the graphics core cluster 1714. Instead, a single instantiation of that specialized function is implemented as an independent entity in shared functionality logic 1720 and shared between execution resources within the graphics core cluster 1714. The exact set of functions shared between the graphics core clusters 1714 and included within the graphics core cluster 1714 varies from embodiment to embodiment. Specific shared functions within the shared functionality logic 1720 that are widely used by the graphics core cluster 1714 may be included within the shared functionality logic 1716 within the graphics core cluster 1714. Optionally, the shared functionality logic 1716 within the graphics core cluster 1714 may include some or all of the logic within the shared functionality logic 1720. All logic elements within the shared functionality logic 1720 may be replicated within the shared functionality logic 1716 of the graphics core cluster 1714. Alternatively, the shared functionality logic 1720 is excluded in favor of the shared functionality logic 1716 within the graphics core cluster 1714. Graphics processing resources
[0282] Figures 18A-18C Execution logic including an array of processing elements employed in a graphics processor is illustrated according to embodiments described herein. Fig.18A Illustrated is a graphics core cluster according to an embodiment. Fig.18B Illustrated is a vector engine of a graphics core according to an embodiment. Fig. 18C Illustrated is a matrix engine of a graphics core according to an embodiment. Figures 18A-18C Elements having the same reference numeral as elements of any other figure herein may operate or function in any manner similar to that described elsewhere herein, but are not limited thereto. For example, Figures 18A-18C The components can be Fig. 15B The graphics processor core block 1519 and / or Fig.17 In one embodiment, Figures 18A-18C The components have Fig.15AGraphics processor 1508 or Fig. 15C The GPGPU 1570 is an equivalent component with similar functionality.
[0283] like Fig.18A As shown in FIG. 1 , in one embodiment, the graphics core cluster 1714 includes a graphics core block 1715, which may be Fig.17 Graphics core block 1715 may include any number of graphics cores (e.g., graphics core 1815A, graphics core 1815B, all the way to graphics core 1815N) and may include multiple instances of graphics core block 1715. In one embodiment, the elements of graphics cores 1815A-1815N have the same Fig. 15B In such embodiments, graphics cores 1815A-1815N each include circuits including, but not limited to, vector engines 1802A-1802N, matrix engines 1803A-1803N, memory load / store units 1804A-1804N, instruction caches 1805A-1805N, data caches / shared local memories 1806A-1806N, ray tracing units 1808A-1808N, and samplers 1810A-1810N. The circuits of graphics cores 1815A-1815N may additionally include fixed function logic 1812A-1812N. The number of vector engines 1802A-1802N and matrix engines 1803A-1803N within a design's graphics cores 1815A-1815N may vary based on the workload, performance, and power targets for the design.
[0284] With reference to graphics core 1815A, vector engine 1802A and matrix engine 1803A are configurable to perform parallel computation operations on data in various integer and floating point data formats based on instructions associated with shader programs. Each vector engine 1802A and matrix engine 1803A can act as a programmable general purpose computing unit capable of executing multiple synchronous hardware threads while processing multiple data elements in parallel for each thread. Vector engine 1802A and matrix engine 1803A support processing of variable width vectors in various SIMD widths, including but not limited to SIMD8, SIMD16 and SIMD32. Input data elements can be stored in registers as compact data types, and vector engine 1802A and matrix engine 1803A can process each element based on the data size of the element. For example, when operating on a 256-bit wide vector, the 256 bits of the vector are stored in registers, and the vector is processed as four separate 64-bit packed data elements (quad-word (QW)) size data elements), eight separate 32-bit packed data elements (double-word (DW)) size data elements), sixteen separate 16-bit packed data elements (word (W) size data elements), or thirty-two separate 8-bit data elements (byte (B) size data elements). However, different vector widths and register sizes are possible. In one embodiment, the vector engine 1802A and the matrix engine 1803A can also be configured to perform SIMT operations on various sizes of unit groups and thread groups (e.g., 8, 16 or 32 threads).
[0285] Continuing with the graphics core 1815A, the memory load / store unit 1804A services memory access requests issued by the vector engine 1802A, the matrix engine 1803A, and / or other components of the graphics core 1815A that have access to memory. The memory access request may be processed by the memory load / store unit 1804A to load or store the requested data into a cache or memory, or from a cache or memory into a register file associated with the vector engine 1802A and / or the matrix engine 1803A. The memory load / store unit 1804A may also perform pre-fetch operations. Also refer to Fig.19In one embodiment, memory load / store unit 1804A is configured to provide SIMT scatter / gather prefetch or block prefetch for data stored in memory 1910, from memory local to other slices via slice interconnect 1908, or from system memory. Prefetching can be performed to a specific L1 cache (e.g., data cache / shared local memory 1806A), L2 cache 1904, or L3 cache 1906. In one embodiment, prefetching to L3 cache 1906 automatically causes the data to be stored in L2 cache 1904.
[0286] Instruction cache 1805A stores instructions to be executed by graphics core 1815A. In one embodiment, graphics core 1815A also includes instruction acquisition and pre-fetch circuits that fetch or pre-fetch instructions into instruction cache 1805A. Graphics core 1815A also includes instruction decoding logic for decoding instructions within instruction cache 1805A. Data cache / shared local memory 1806A can be configured as a data cache managed by a cache controller that implements a cache replacement strategy and / or configured as a shared memory that is explicitly managed. Ray tracing unit 1808A includes circuits for accelerating ray tracing operations. Sampler 1810A provides texture sampling for 3D operations and media sampling for media operations. Fixed function logic 1812A includes fixed function circuits that are shared between instances of vector engine 1802A and matrix engine 1803A. Graphics cores 1815B-1815N can operate in a similar manner to graphics core 1815A.
[0287] The functions of the instruction caches 1805A-1805N, data caches / shared local memory 1806A-1806N, ray tracing units 1808A-1808N, samplers 1810A-1812N, and fixed function logic 1812A-1812N correspond to the equivalent functions in the graphics processor architecture described herein. Fig. 15C The data cache / shared local memory 1806A-1806N, ray tracing units 1808A-1808N, and samplers 1810A-1812N can operate in a manner similar to the instruction cache 1555 of FIG. Fig. 15B The fixed function logic 1812A-1812N may include: Fig. 15B In one embodiment, ray tracing units 1808A-1808N include components for performing the ray tracing operations performed by Figure 3C Circuitry for ray tracing acceleration operations performed by the ray tracing core 372.
[0288] like Fig.18B As shown in FIG. 1 , in one embodiment, the vector engine 1802 includes an instruction fetch unit 1837, a general register file array (GRF) 1824, an architectural register file array (ARF) 1826, a thread arbiter 1822, an issue unit 1830, a branch unit 1832, a set of SIMD floating point units (FPUs) 1834, and a set of integer SIMD ALUs 1835 in one embodiment. The GRF 1824 and ARF 1826 include a set of general register files and architectural register files associated with each hardware thread that can be active in the vector engine 1802. In one embodiment, the per-thread architectural state is maintained in the ARF 1826, while data used during thread execution is stored in the GRF 1824. The execution state of each thread, including the instruction pointer for each thread, can be saved in thread-specific registers in the ARF 1826. Register renaming can be used to dynamically assign registers to hardware threads.
[0289] In one embodiment, the vector engine 1802 has an architecture that is a combination of Simultaneous Multi-Threading (SMT) and fine-grained Interleaved Multi-Threading (IMT). The architecture has a modular configuration that can be fine-tuned at design time based on the target number of simultaneous threads and the number of registers per graphics core, where graphics core resources are divided across logic for executing multiple simultaneous threads. The number of logical threads that can be executed by the vector engine 1802 is not limited to the number of hardware threads, and multiple logical threads can be assigned to each hardware thread.
[0290] In one embodiment, the vector engine 1802 can issue multiple instructions in coordination, and these instructions can be different instructions respectively. The thread arbiter 1822 can dispatch instructions to one of the send unit 1830, the branch unit 1832 or (one or more) SIMD FPU 1834 for execution. Each execution thread can access 128 general registers in the GRF 1824, wherein each register can store 32 bytes that can be accessed as a variable width vector with 32-byte data elements. In one embodiment, each thread has access to 4 kilobytes in the GRF 1824, but the embodiment is not limited thereto, and more or less register resources can be provided in other embodiments. In one embodiment, the vector engine 1802 is partitioned into seven hardware threads that can independently perform computing operations, but the number of threads of each vector engine 1802 can also vary according to the embodiment. For example, in one embodiment, a maximum of 16 hardware threads are supported. In an embodiment in which seven threads can access 4 kilobytes, the GRF 1824 can store a total of 28 kilobytes. With 16 threads accessing 4 kilobytes, a total of 64 kilobytes can be stored by GRF 1824. Flexible addressing modes allow registers to be addressed together, effectively creating wider registers or representing strided rectangular block data structures.
[0291] In one embodiment, memory operations, sampler operations, and other longer latency system communications are dispatched via "send" instructions executed by message passing send unit 1830. In one embodiment, branch instructions are dispatched to a dedicated branch unit 1832 to facilitate SIMD scatter and eventual convergence.
[0292] In one embodiment, the vector engine 1802 includes one or more SIMD floating point units (FPU(s)) 1834 for performing floating point operations. In one embodiment, FPU(s) 1834 also supports integer calculations. In one embodiment, FPU(s) 1834 can perform up to M 32-bit floating point (or integer) operations, or up to 2M 16-bit integer or 16-bit floating point operations. In one embodiment, at least one of the FPU(s) provides extended math capabilities that support high throughput transcendental math functions and double precision 64-bit floating points. In some embodiments, a set 1835 of 8-bit integer SIMD ALUs also exists and can be specifically optimized to perform operations associated with machine learning calculations. In one embodiment, the SIMD ALUs are replaced by a set 1834 of additional SIMD ALUs that can be configured to perform integer and floating point operations. In one embodiment, SIMD FPU 1834 and SIMD ALU 1835 can be configured to execute SIMT programs. In one embodiment, combined SIMD+SIMT operations are supported.
[0293] In one embodiment, an array of multiple instances of vector engine 1802 may be instantiated in a graphics core. For scalability, product architects may choose the exact number of vector engines grouped per graphics core. In one embodiment, vector engine 1802 may execute instructions across multiple execution lanes. In further embodiments, each thread executed on vector engine 1802 is executed on a different lane.
[0294] like Fig. 18CAs shown in, in one embodiment, matrix engine 1803 includes an array of processing elements configured to perform tensor operations, and the tensor operations include vector / matrix operations and matrix / matrix operations, such as but not limited to matrix multiplication and / or dot product operations. Matrix engine 1803 can be configured using processing elements (1852AA-1852MN) of M rows and N columns, and the processing elements (PE 1852AA-PE 1852MN) include multipliers and adder circuits organized in a pipelined manner. In one embodiment, processing elements 1852AA-1852MN form the physical pipeline stage of the systolic array of N width and M depth, and the systolic array can be used to perform vector / matrix operations or matrix / matrix operations in a data parallel manner, including matrix multiplication, fusion multiplication and addition, dot product or other general matrix-matrix multiplication (GEMM) operations. In one embodiment, matrix engine 1803 supports 16-bit and 8-bit floating point operations, as well as 8-bit, 4-bit, 2-bit and binary integer operations. The matrix engine 1803 may also be configured to accelerate certain machine learning operations. In such embodiments, the matrix engine 1803 may be configured with support for a bfloat (brain floating point) 16-bit floating point format with a different number of mantissa bits and exponent bits relative to the Institute of Electrical and Electronics Engineers (IEEE) 754 format, or a tensor floating point 32-bit floating point format (TF32).
[0295] In one embodiment, during each cycle, each stage may add the result of the operation performed at that stage to the output of the previous stage. In other embodiments, after a set of computation cycles, the pattern of data movement between processing elements 1852AA-1852MN may vary based on the instructions or macro operations executed. For example, in one embodiment, a partial sum loopback is enabled, and the processing element may instead add the output of the current cycle to the output generated in the previous cycle. In one embodiment, the final stage of the systolic array may be configured with a loop to the initial stage of the systolic array. In such embodiments, the number of physical pipeline stages may be decoupled from the number of logical pipeline stages supported by the matrix engine 1803. For example, where the processing elements 1852AA-1852MN are configured as a systolic array of M physical stages, a loop from stage M to the initial pipeline stage may enable the processing elements 1852AA-1852MN to operate as a systolic array of logical pipeline stages, such as 2M, 3M, 4M, etc.
[0296] In one embodiment, matrix engine 1803 includes memory 1841A-1841N, 1842A-1842M, for storing input data in the form of row and column data for input matrix. Memory 1842A-1842M can be configured to store row elements (A0-Am) of the first input matrix, and memory 1841A-1841N can be configured to store column elements (B0-Bn) of the second input matrix. Row elements and column elements are provided as input to processing element 1852AA-1852MN for processing. In one embodiment, the element row and column elements of the input matrix can be stored in the systolic register file 1840 in the matrix engine 1803 before these elements are provided to memory 1841A-1841N, 1842A-1842M. In one embodiment, systolic register file 1840 is excluded, and registers (e.g., Fig.18B The GRF 1824 of the vector engine 1802) or other memory of the graphics core including the matrix engine 1803 (e.g., Fig.18A The data cache / shared local memory 1806A for matrix engine 1803A) loads memory 1841A-1841N, 1842A-1842M. The results generated by processing elements 1852AA-1852MN are then output to output buffers and / or written to register files (e.g., systolic register file 1840, GRF 1824, data cache / shared local memory 1806A-1806N) for further processing by other functional units of the graphics processor or for output to memory.
[0297] In some embodiments, the matrix engine 1803 is configured with support for input sparsity, wherein multiplication operations of sparse regions of input data can be bypassed by skipping multiplication operations of operands with zero values. In one embodiment, processing elements 1852AA-1852MN are configured to skip the execution of certain operations with zero-value inputs. In one embodiment, the sparsity within the input matrix can be detected, and operations with known zero output values can be bypassed before being submitted to processing elements 1852AA-1852MN. Loading zero-value operands into processing elements can be bypassed, and processing elements 1852AA-1852MN can be configured to perform multiplication on non-zero-value input elements. The matrix engine 1803 can also be configured with support for output sparsity, so that operations with results predetermined to zero can be bypassed. For input sparsity and / or output sparsity, in one embodiment, metadata is provided to processing elements 1852AA-1852MN to indicate which processing elements and / or data channels will be active during the cycle for a certain processing cycle.
[0298] In one embodiment, the matrix engine 1803 includes hardware for enabling operations on sparse data with a compressed representation of a sparse matrix, which stores non-zero values and metadata identifying the location of the non-zero values in the matrix. Exemplary compressed representations include, but are not limited to, compressed tensor representations, such as, compressed sparse rows (CSR) representations, compressed sparse columns (CSC) representations, compressed sparse fibers (CSF) representations. Support for compressed representations enables operations to be performed on inputs in compressed tensor format without the need for compressed representations to be decompressed or decoded. In such embodiments, operations can be performed only on non-zero input values, and the resulting non-zero output values can be mapped into the output matrix. In some embodiments, hardware support for machine-specific lossless data compression formats is also provided, which are used when transmitting data within hardware or across system buses. Such data can be retained in a compressed format for sparse input data, and the matrix engine 1803 can use compressed metadata for compressed data to enable operations to be performed only on non-zero values or to enable blocks of zero data input to be bypassed for multiplication operations.
[0299] In various embodiments, the input data may be provided by the programmer in a compressed tensor representation, or the codec may compress the input data into a compressed tensor representation or another sparse data encoding. In addition, in order to support the compressed tensor representation, streaming compression of the sparse input data may be performed before the input data is provided to the processing element 1852AA-1852MN. In one embodiment, compression is performed on the data written to the cache memory associated with the graphics core cluster 1714, wherein the compression is performed using the encoding supported by the matrix engine 1803. In one embodiment, the matrix engine 1803 includes support for inputs with structured sparsity, in which a predetermined level or predetermined pattern of sparsity is applied to the input data. The data may be compressed to a known compression ratio, wherein the compressed data is processed by the compression element 1852AA-1852MN according to metadata associated with the compressed data.
[0300] Fig.19 FIG. 19 shows a slice 1900 of a multi-slice processor according to an embodiment. In one embodiment, slice 1900 represents Fig. 16B Graphics engine chip 1610A-1610D or Fig. 16CThe slice 1900 of the multi-slice graphics processor includes an array of graphics core clusters (e.g., graphics core cluster 1714A, graphics core cluster 1714B, through graphics core cluster 1714N), wherein each graphics core cluster has an array of graphics cores 1815A-1815N. The slice 1900 also includes a global dispatcher 1902 for dispatching threads to processing resources of the slice 1900.
[0301] Slice 1900 may include or be coupled with L3 cache 1906 and memory 1910. In various embodiments, L3 cache 1906 may be excluded or slice 1900 may include additional levels of cache, such as an L4 cache. Fig. 16B and Fig. 16C , each instance of slice 1900 in a multi-chip graphics processor has an associated memory 1910. In one embodiment, the multi-chip processor can be configured as a multi-chip module in which the L3 cache 1906 and / or the memory 1910 reside on a separate chiplet that is distinct from the graphics core clusters 1714A-1714N. In this context, a chiplet is an at least partially packaged integrated circuit that includes different logic units that can be assembled into a larger package with other chiplets. For example, the L3 cache 1906 may be included in a dedicated cache chiplet, or reside on the same chiplet as the graphics core clusters 1714A-1714N. In one embodiment, the L3 cache 1906 may be included in a dedicated cache chiplet such as Fig.24C An active base die or an active interposer is shown.
[0302] Memory structure 1903 enables communication between graphics core cluster 1714A-1714N, L3 cache 1906, and memory 1910. L2 cache 1904 is coupled to memory structure 1903 and can be configured to cache transactions executed via memory structure 1903. Slice interconnect 1908 enables communication with other slices on the graphics processor and can be Fig. 16B and Fig. 16C1623F of the slice interconnects 1623A-1623F. In embodiments where the L3 cache 1906 is excluded from the slice 1900, the L2 cache 1904 may be configured as a combined L2 / L3 cache. The memory structure 1903 may be configured to route data to the L3 cache 1906 or to a memory controller associated with the memory 1910 based on the presence or absence of the L3 cache 1906 in a particular implementation. The L3 cache 1906 may be configured as a per-tile cache that is dedicated to the processing resources of the slice 1900 or may be part of a GPU-wide L3 cache.
[0303] Fig. 20 2000. The graphics processor execution unit supports an instruction set having instructions in a variety of formats. Solid line boxes illustrate components that are typically included in the execution unit instructions, while dashed lines include components that are optional or included only in a subset of the instructions. In some embodiments, the graphics processor instruction format 2000 described and illustrated are macroinstructions because they are instructions supplied to the execution unit, as opposed to micro-operations that result from instruction decoding that is performed once the instruction is processed. Therefore, a single instruction can cause the hardware to perform multiple micro-operations.
[0304] As described herein, the graphics processor execution unit can natively support instructions in the 128-bit instruction format 2010. Based on the selected instructions, instruction options, and the number of operands, a 64-bit compact instruction format 2030 can be used for some instructions. The native 128-bit instruction format 2010 provides access to all instruction options, while some options and operations are limited in the 64-bit format 2030. The native instructions available in the 64-bit format 2030 vary from embodiment to embodiment. The instructions are partially compressed using a set of index values in the index field 2013. The execution unit hardware references a set of compression tables based on the index values and uses the compression table output to reconstruct the native instructions of the 128-bit instruction format 2010. Instructions of other sizes and formats can be used.
[0305] For each format, the instruction opcode 2012 defines the operation to be performed by the execution unit. The execution unit executes each instruction in parallel across multiple data elements of each operand. For example, in response to an addition instruction, the execution unit performs a synchronous addition operation across each color channel representing a texture element or a picture element. By default, the execution unit executes each instruction across all data channels of the operand. The instruction control field 2014 can enable control of certain execution options (such as channel selection (e.g., predication) and data channel order (e.g., swizzle)). For instructions in the 128-bit instruction format 2010, the execution size field 2016 limits the number of data channels that will be executed in parallel. The execution size field 2016 may not be available for the 64-bit compact instruction format 2030.
[0306] Some execution unit instructions have up to three operands, including two source operands src0 2020, src1 2022 and one destination operand (dest 2018). Other instructions (such as, for example, data manipulation instructions, dot product instructions, multiply-add instructions, or multiply-accumulate instructions) may have a third source operand (e.g., src2 2024). The instruction opcode 2012 determines the number of source operands. The last source operand of the instruction may be an immediate (e.g., hard-coded) value passed with the instruction. The execution unit may also support multiple destination instructions, where one or more of the destinations are implicit or implicit based on the instruction and / or the specified destination.
[0307] The 128-bit instruction format 2010 may include an access / addressing mode field 2026 that specifies, for example, whether direct register addressing mode or indirect register addressing mode is used. When direct register addressing mode is used, the register addresses of one or more operands are provided directly by bits in the instruction.
[0308] 128-bit instruction format 2010 may also include an access / addressing mode field 2026, which specifies the addressing mode and / or access mode of the instruction. The access mode may be used to define the data access alignment of the instruction. The access mode may support access modes including 16-byte aligned access modes and 1-byte aligned access modes, wherein the byte alignment of the access mode determines the access alignment of the instruction operand. For example, when in the first mode, the instruction may use byte-aligned addressing for source operands and destination operands, and when in the second mode, the instruction may use 16-byte aligned addressing for all source operands and destination operands.
[0309] The addressing mode portion of the access / addressing mode field 2026 may determine whether the instruction uses direct or indirect addressing. When direct register addressing mode is used, the bits in the instruction directly provide the register address of one or more operands. When indirect register addressing mode is used, the register address of one or more operands may be calculated based on the address register value and the address immediate field in the instruction.
[0310] Instructions can be grouped based on the opcode 2012 bit fields to simplify opcode decoding 2040. For 8-bit opcodes, bit 4, bit 5, and bit 6 allow execution units to determine the type of opcode. The exact opcode grouping shown is only an example. Move and logic opcode group 2042 can include data movement and logic instructions (e.g., move (mov), compare (cmp)). Move and logic group 2042 can share five least significant bits (least significant bit, LSB), wherein the move (mov) instruction adopts the form of 0000xxxxb, and the logic instruction adopts the form of 0001xxxxb. Flow control instruction group 2044 (e.g., call (call), jump (jmp)) includes instructions in the form of 0010xxxxb (e.g., 0x20). Miscellaneous instruction group 2046 includes a mixture of instructions, including synchronization instructions (e.g., wait (wait), send (send)) in the form of 0011xxxxb (e.g., 0x30). The parallel math instruction group 2048 includes component-by-component arithmetic instructions (e.g., addition, multiplication (mul)) of the form 0100xxxxb (e.g., 0x40). The parallel math instruction group 2048 performs arithmetic operations in parallel across data channels. The vector math group 2050 includes arithmetic instructions (e.g., dp4) of the form 0101xxxxb (e.g., 0x50). The vector math group performs arithmetic on vector operands, such as dot product calculations. In one embodiment, the illustrated opcode decoding 2040 can be used to determine which portion of the execution unit will be used to execute the decoded instructions. For example, some instructions may be designated as systolic instructions to be executed by a systolic array. Other instructions, such as ray tracing instructions (not shown), may be routed to a ray tracing core or ray tracing logic within a slice or partition of the execution logic. Graphics Pipeline
[0311] Fig.21 is a block diagram of a graphics processor 2100 according to another embodiment. Fig.21Elements having the same or similar names as elements of any other figures herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, may include the same components, and may be linked to other entities such as, but not limited to, those described elsewhere herein.
[0312] The graphics processor 2100 may include different types of graphics processing pipelines, such as a geometry pipeline 2120, a media pipeline 2130, a display engine 2140, a thread execution logic 2150, and a rendering output pipeline 2170. The graphics processor 2100 may be a graphics processor within a multi-core processing system that includes one or more general-purpose processing cores. The graphics processor may be controlled by register writes to one or more control registers (not shown) or via commands issued to the graphics processor 2100 through a ring interconnect 2102. The ring interconnect 2102 may couple the graphics processor 2100 to other processing components (such as other graphics processors or general-purpose processors). Commands from the ring interconnect 2102 are interpreted by a command stream converter 2103, which supplies instructions to various components of the geometry pipeline 2120 or the media pipeline 2130.
[0313] The command stream converter 2103 may direct the operation of the vertex fetcher 2105, which reads vertex data from memory and executes vertex processing commands provided by the command stream converter 2103. The vertex fetcher 2105 may provide the vertex data to the vertex shader 2107, which performs coordinate space transformation and lighting operations on each vertex. The vertex fetcher 2105 and the vertex shader 2107 may execute the vertex processing instructions by dispatching execution threads to the graphics cores 2152A-2152B via the thread dispatcher 2131.
[0314] The graphics cores 2152A-2152B may be an array of vector processors with instruction sets for performing graphics operations and media operations. The graphics cores 2152A-2152B may have an attached L1 cache 2151 that is dedicated to each array or shared between arrays. The cache may be configured as a data cache, an instruction cache, or partitioned into a single cache containing data and instructions in different partitions.
[0315] The geometry pipeline 2120 may include a tessellation component for performing hardware accelerated tessellation of 3D objects. The programmable hull shader 2111 may configure the tessellation operation. The programmable domain shader 2117 may provide back-end evaluation of the tessellation output. The tessellation 2113 may operate under the direction of the hull shader 2111 and may contain dedicated logic for generating a detailed set of geometric objects based on a coarse geometric model that is provided as input to the geometry pipeline 2120. In addition, if tessellation is not used, the tessellation component (e.g., the hull shader 2111, the tessellation 2113, and the domain shader 2117) may be bypassed. The tessellation component may operate based on data received from the vertex shader 2107.
[0316] The complete geometric object may be processed by the geometry shader 2119 via one or more threads dispatched to the graphics core 2152A-2152B, or may proceed directly to the clipper 2129. The geometry shader may operate on the entire geometric object, rather than on vertices or patches of vertices as in previous stages of the graphics pipeline. If tessellation is disabled, the geometry shader 2119 receives input from the vertex shader 2107. The geometry shader 2119 may be programmable by a geometry shader program to perform geometry tessellation when the tessellation unit is disabled.
[0317] Before rasterization, the clipper 2129 processes the vertex data. The clipper 2129 can be a fixed function clipper or a programmable clipper with clipping and geometry shader functions. The rasterizer and depth test component 2173 in the render output pipeline 2170 can dispatch a pixel shader to convert the geometric object into a pixel-by-pixel representation. The pixel shader logic can be included in the thread execution logic 2150. Optionally, the application can bypass the rasterizer and depth test component 2173 and access the unrasterized vertex data via the outflow unit 2123.
[0318] The graphics processor 2100 has an interconnect bus, interconnect structure, or some other interconnect mechanism that allows data and messages to be passed between the main components of the processor. In some embodiments, the graphics core 2152A-2152B and associated logic units (e.g., L1 cache 2151, sampler 2154, texture cache 2158, etc.) are interconnected via data port 2156 to perform memory access and communicate with the rendering output pipeline components of the processor. Sampler 2154, cache 2151, 2158 and graphics core 2152A-2152B can each have a separate memory access path. Optionally, texture cache 2158 can also be configured as a sampler cache.
[0319] The rendering output pipeline 2170 may include a rasterizer and depth test component 2173, which converts vertex-based objects into associated pixel-based representations. The rasterizer logic may include a windower / masker unit for performing fixed-function triangle and line rasterization. In some embodiments, an associated rendering cache 2178 and a depth cache 2179 are also available. A pixel operation component 2177 performs pixel-based operations on data, but in some instances, pixel operations associated with 2D operations (e.g., using mixed bit block image transfer) are performed by the 2D engine 2141, or replaced by a display controller 2143 using an overlay display plane when displayed. A shared L3 cache 2175 may be available to all graphics components, allowing data to be shared without using main system memory.
[0320] The media pipeline 2130 may include a media engine 2137 and a video front end 2134. The video front end 2134 may receive pipeline commands from the command stream converter 2103. The media pipeline 2130 may include a separate command stream converter. The video front end 2134 may process the media commands before sending them to the media engine 2137. The media engine 2137 may include a thread generation function for generating threads for dispatching to the thread execution logic 2150 via the thread dispatcher 2131.
[0321] The graphics processor 2100 may include a display engine 2140. The display engine 2140 may be external to the processor 2100 and may be coupled to the graphics processor via a ring interconnect 2102, or some other interconnect bus or structure. The display engine 2140 may include a 2D engine 2141 and a display controller 2143. The display engine 2140 may contain dedicated logic capable of operating independently of the 3D pipeline. The display controller 2143 may be coupled to a display device (not shown), which may be a system-integrated display device such as in a laptop or an external display device attached via a display device connector.
[0322] The geometry pipeline 2120 and the media pipeline 2130 can be configured to perform operations based on multiple graphics and media programming interfaces and are not dedicated to any one application programming interface (API). Driver software for a graphics processor can convert API calls dedicated to a specific graphics or media library into commands that can be processed by the graphics processor. Support can be provided for all Open Graphics Library (OpenGL), Open Computing Language (OpenCL) and / or Vulkan graphics and computing APIs from the Khronos Group. Support can also be provided for the Direct3D library from Microsoft. Combinations of these libraries can be supported. Support can also be provided for the OpenSource Computer Vision Library (OpenCV). If a mapping from the pipeline of a future API to the pipeline of a graphics processor can be performed, future APIs with compatible 3D pipelines will also be supported. Graphics pipeline programming
[0323] Fig.22A is a block diagram illustrating a graphics processor command format 2200 for programming a graphics processing pipeline, such as, for example, the graphics processing pipeline described herein in conjunction with Fig.16A , Fig.17 , Fig.21 Describe the pipeline. Fig. 22B is a block diagram illustrating a graphics processor command sequence 2210 according to an embodiment. Fig.22A The solid-line boxes in illustrate components that are generally included in the graphics commands, while the dashed lines include components that are optional or included only in a subset of the graphics commands. Fig.22A An exemplary graphics processor command format 2200 includes fields for identifying the client of the command 2202, a command operation code (opcode) 2204, and a data field 2206. A subopcode 2205 and a command size 2208 are also included in some commands.
[0324] Client 2202 may specify a client unit of a graphics device that processes command data. A graphics processor command parser may check the client field of each command to adjust further processing of the command and route the command data to the appropriate client unit. A graphics processor client unit may include a memory interface unit, a rendering unit, a 2D unit, a 3D unit, and a media unit. Each client unit may have a corresponding processing pipeline for processing commands. Once a command is received by a client unit, the client unit reads an opcode 2204 and a subopcode 2205 (if present) to determine the operation to be performed. The client unit uses the information in the data field 2206 to execute the command. For some commands, an explicit command size 2208 is expected to specify the size of the command. The command parser may automatically determine the size of at least some of the commands based on the command opcode. Commands may be aligned via multiples of double words. Other command formats may also be used.
[0325] Fig. 22B 2210. The flowchart in 2222 illustrates an exemplary graphics processor command sequence. Software or firmware of a data processing system featuring an exemplary graphics processor may use a version of the command sequence shown to establish, execute, and terminate a set of graphics operations. The sample command sequence is shown and described for exemplary purposes only, and the sample command sequence is not limited to these particular commands or command sequences. In addition, commands may be issued as batches of commands in a command sequence so that the graphics processor will process the command sequence in an at least partially concurrent manner.
[0326] The graphics processor command sequence 2210 can begin with a pipeline flush command 2212 to cause any active graphics pipeline to complete currently pending commands for the pipeline. Optionally, the 3D pipeline 2222 and the media pipeline 2224 may not operate concurrently. The pipeline flush is performed to cause the active graphics pipeline to complete any pending commands. In response to the pipeline flush, the command parser for the graphics processor will suspend command processing until the active paint engines complete pending operations and the associated read caches are invalidated. Optionally, any data marked as "dirty" in the render cache can be flushed to memory. The pipeline flush command 2212 can be used for pipeline synchronization, or can be used before placing the graphics processor in a low power state.
[0327] When a command sequence requires the graphics processor to explicitly switch between pipelines, a pipeline select command 2213 may be used. A pipeline select command 2213 may be required only once in an execution context before issuing a pipeline command, unless the context is issuing commands for both pipelines. A pipeline flush command 2212 may be required immediately before a pipeline switch via a pipeline select command 2213.
[0328] Pipeline control commands 2214 may configure the graphics pipeline for operation and may be used to program 3D pipeline 2222 and media pipeline 2224. Pipeline control commands 2214 may configure pipeline states for active pipelines. Pipeline control commands 2214 may be used for pipeline synchronization and to clear data from one or more cache memories within an active pipeline before processing a batch of commands.
[0329] Commands associated with return buffer state 2216 may be used to configure a set of return buffers for a corresponding pipeline for writing data. Some pipeline operations require the allocation, selection, or configuration of one or more return buffers into which the operation writes intermediate data during processing. A graphics processor may also use one or more return buffers to store output data and perform cross-thread communication. Return buffer state 2216 may include selecting the size and number of return buffers to be used for a set of pipeline operations.
[0330] The remaining commands in the command sequence differ based on the active pipeline for operation. Based on pipeline decision 2220 , the command sequence is tailored for either 3D pipeline 2222 starting at 3D pipeline state 2230 , or media pipeline 2224 starting at media pipeline state 2240 .
[0331] The commands for configuring the 3D pipeline state 2230 include 3D state setup commands for vertex buffer state, vertex element state, constant color state, depth buffer state, and other state variables that will be configured before processing 3D primitive commands. The values of these commands are determined at least in part based on the specific 3D API in use. The 3D pipeline state 2230 commands may also be able to selectively disable or bypass certain pipeline elements if those elements will not be used.
[0332] 3D primitive 2232 commands can be used to submit 3D primitives to be processed by the 3D pipeline. The commands and associated parameters passed to the graphics processor via the 3D primitive 2232 commands are forwarded to the vertex acquisition function in the graphics pipeline. The vertex acquisition function uses the 3D primitive 2232 command data to generate a vertex data structure. The vertex data structure is stored in one or more return buffers. The 3D primitive 2232 commands can be used to perform vertex operations on 3D primitives via a vertex shader. In order to process the vertex shader, the 3D pipeline 2222 dispatches the shader execution thread to the graphics processor execution unit.
[0333] The 3D pipeline 2222 can be triggered via an execute 2234 command or event. A register can be written to trigger a command execution. Execution can be triggered via a "go" or "kick" command in a command sequence. Command execution can be triggered using a pipeline synchronization command to flush the command sequence through the graphics pipeline. The 3D pipeline will perform geometry processing for 3D primitives. Once the operation is completed, the resulting geometric objects are rasterized and the pixel engine shades the resulting pixels. For those operations, additional commands for controlling pixel shading and pixel backend operations may also be included.
[0334] When performing media operations, the graphics processor command sequence 2210 may follow the media pipeline 2224 path. In general, the specific purpose and manner of programming the media pipeline 2224 depends on the media or computing operations to be performed. During media decoding, specific media decoding operations may be migrated to the media pipeline. The media pipeline may also be bypassed, and the media decoding may be performed in whole or in part using resources provided by one or more general-purpose processing cores. The media pipeline may also include elements for general-purpose graphics processor unit (GPGPU) operations, where the graphics processor is used to perform SIMD vector operations using compute shader programs that are not explicitly related to the rendering of graphics primitives.
[0335] The media pipeline 2224 can be configured in a similar manner to the 3D pipeline 2222. A collection of commands for configuring the media pipeline state 2240 are dispatched or placed into a command queue prior to the media object commands 2242. The commands for the media pipeline state 2240 may include data for configuring the media pipeline elements that will be used to process the media objects. This includes data for configuring the video decoding and video encoding logic within the media pipeline, such as encoding or decoding formats. The commands for the media pipeline state 2240 may also support the use of one or more pointers to an "indirect" state element that contains a batch of state settings.
[0336] The media object command 2242 may supply a pointer to a media object for processing by the media pipeline. The media object includes a memory buffer that contains the video data to be processed. Optionally, all media pipeline states must be valid before issuing the media object command 2242. Once the pipeline state is configured and the media object command 2242 is queued, the media pipeline 2224 is triggered via an execute command 2244 or an equivalent execute event (e.g., a register write). The output from the media pipeline 2224 may then be post-processed by operations provided by the 3D pipeline 2222 or the media pipeline 2224. GPGPU operations may be configured and executed in a manner similar to media operations. Graphics Software Architecture
[0337] Fig.23 An exemplary graphics software architecture for data processing system 2300 is illustrated. Such a software architecture may include a 3D graphics application 2310, an operating system 2320, and at least one processor 2330. Processor 2330 may include a graphics processor 2332 and one or more general-purpose processor cores 2334. Processor 2330 may be a variant of processor 1402 or any other of the processors described herein. Processor 2330 may be used in place of processor 1402 or any other of the processors described herein. Therefore, the disclosure of any feature in conjunction with processor 1402 or any other of the processors described herein also discloses the corresponding combination with graphics processor 2330, but is not limited thereto. In addition, Fig.23 Elements with the same or similar names as elements of any other figures herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, can include the same components, and can be linked to other entities, such as, but not limited to, those described elsewhere herein. Graphics application 2310 and operating system 2320 are each executed in system memory 2350 of the data processing system.
[0338] The 3D graphics application 2310 may include one or more shader programs including shader instructions 2312. The shader language instructions may be in a high-level shader language, such as Direct3D's High-Level Shader Language (HLSL), OpenGL Shader Language (GLSL), etc. The application may also include executable instructions 2314 in a machine language suitable for execution by a general purpose processor core 2334. The application may also include graphics objects 2316 defined by vertex data.
[0339] The operating system 2320 may be a system from Microsoft Corporation. An operating system, a proprietary UNIX-like operating system, or an open source UNIX-like operating system using a variant of the Linux kernel. The operating system 2320 may support a graphics API 2322, such as a Direct3D API, an OpenGL API, or a Vulkan API. When the Direct3D API is in use, the operating system 2320 uses a front-end shader compiler 2324 to compile any shader instructions 2312 using HLSL into a lower-level shader language. The compilation may be just-in-time (JIT) compilation or application executable shader precompilation. During the compilation of the 3D graphics application 2310, high-level shaders may be compiled into low-level shaders. The shader instructions 2312 may be provided in an intermediate form, such as a version of the Standard Portable Intermediate Representation (SPIR) used by the Vulkan API.
[0340] The user mode graphics driver 2326 may include a backend shader compiler 2327 to compile shader instructions 2312 into a hardware specific representation. When the OpenGL API is in use, the shader instructions 2312 in the GLSL high level language are passed to the user mode graphics driver 2326 for compilation. The user mode graphics driver 2326 may use the operating system kernel mode functions 2328 to communicate with the kernel mode graphics driver 2329. The kernel mode graphics driver 2329 may communicate with the graphics processor 2332 to dispatch commands and instructions. IP core implementation
[0341] One or more aspects may be implemented by representative code stored on a machine-readable medium that represents and / or defines logic within an integrated circuit (such as a processor). For example, a machine-readable medium may include instructions representing various logic within a processor. When read by a machine, the instructions may cause the machine to manufacture logic for performing the techniques described herein. Such representations (referred to as "IP cores") are reusable units of logic for an integrated circuit that can be stored on a tangible, machine-readable medium as a hardware model describing the structure of the integrated circuit. The hardware model may be supplied to each customer or manufacturing facility that loads the hardware model on a manufacturing machine that manufactures the integrated circuit. The integrated circuit may be manufactured so that the circuit performs the operations described in association with any of the embodiments described herein.
[0342] Fig.24A24 is a block diagram of an IP core development system 2400 that can be used to manufacture an integrated circuit to perform operations according to an embodiment. The IP core development system 2400 can be used to generate a modular, reusable design that can be incorporated into a larger design or used to build an entire integrated circuit (e.g., a SOC integrated circuit). The design facility 2430 can generate a software simulation 2410 of the IP core design using a high-level programming language (e.g., C / C++). The software simulation 2410 can be used to design, test, and verify the behavior of the IP core using a simulation model 2412. The simulation model 2412 can include functional simulation, behavioral simulation, and / or timing simulation. A register transfer level (RTL) design 2415 can then be created or synthesized from the simulation model 2412. The RTL design 2415 is an abstraction of the behavior of an integrated circuit (including associated logic executed using the modeled digital signals) that models the flow of digital signals between hardware registers. In addition to the RTL design 2415, a lower level design at the logic level or transistor level can also be created, designed, or synthesized. Thus, the specific details of the initial design and simulation can be different.
[0343] The RTL design 2415 or equivalent may be further synthesized by the design facility into a hardware model 2420, which may be in a hardware description language (HDL) or some other representation of physical design data. The HDL may be further simulated or tested to verify the IP core design. The IP core design may be stored using a non-volatile memory 2440 (e.g., a hard disk, flash memory, or any non-volatile storage medium) for delivery to a third-party manufacturing facility 2465. Alternatively, the IP core design may be transmitted via a wired connection 2450 or a wireless connection 2460 (e.g., via the Internet). The manufacturing facility 2465 may then manufacture an integrated circuit based at least in part on the IP core design. The manufactured integrated circuit may be configured to perform operations according to at least one embodiment described herein.
[0344] Fig. 24BA cross-sectional side view of an integrated circuit package assembly 2470 is shown. The integrated circuit package assembly 2470 illustrates an implementation of one or more processors or accelerator devices as described herein. The package assembly 2470 includes a plurality of hardware logic units 2472, 2474 connected to a substrate 2480. The logic 2472, 2474 may be implemented at least in part in configurable logic or fixed-function logic hardware, and may include one or more portions of any of the (one or more) processor cores, (one or more) graphics processors, or other accelerator devices described herein. Each logic unit 2472, 2474 may be implemented within a semiconductor die and coupled to the substrate 2480 via an interconnect structure 2473. The interconnect structure 2473 may be configured to route electrical signals between the logic 2472, 2474 and the substrate 2480, and may include interconnects such as, but not limited to, bumps or pillars. Interconnection structure 2473 can be configured to route electrical signals, such as, for example, input / output (I / O) signals and / or power or ground signals associated with the operation of logic 2472, 2474. Optionally, substrate 2480 can be a laminate substrate based on epoxy resin. Substrate 2480 can also include other suitable types of substrates. Package assembly 2470 can be connected to other electrical devices via package interconnect 2483. Package interconnect 2483 can be coupled to the surface of substrate 2480 to route electrical signals to other electrical devices, such as a motherboard, other chipsets, or multi-chip modules.
[0345] The logic units 2472, 2474 may be electrically coupled to a bridge 2482 configured to route electrical signals between the logic 2472 and the logic 2474. The bridge 2482 may be a dense interconnect structure that provides routing for electrical signals. The bridge 2482 may include a bridge substrate composed of glass or a suitable semiconductor material. Circuit features may be formed on the bridge substrate to provide a chip-to-chip connection between the logic 2472 and the logic 2474.
[0346] Although two logic units 2472, 2474 and bridge 2482 are illustrated, the embodiments described herein may include more or fewer logic units on one or more dies. The one or more dies may be connected by zero or more bridges, as bridge 2482 may be excluded when the logic is included on a single die. Alternatively, multiple dies or logic units may be connected by one or more bridges. In addition, multiple logic units, dies, and bridges may be connected together in other possible configurations, including three-dimensional configurations.
[0347] Fig.24CThe illustrated package assembly 2490 includes a hardware logic chiplet of multiple units connected to a substrate 2480 (e.g., a base die). A graphics processing unit, parallel processor, and / or computing accelerator as described herein may be composed of various silicon chiplets manufactured separately. In this context, a chiplet is an integrated circuit that is at least partially packaged, and the at least partially packaged integrated circuit includes different logic units that can be assembled into a larger package with other chiplets. Chipsets with various sets of different IP core logic can be assembled into a single device. In addition, chiplets can be integrated into a base die or base chiplet using active interposer technology. The concepts described herein enable interconnection and communication between different forms of IP within a GPU. IP cores can be manufactured using different process technologies and constructed during manufacturing, which avoids the complexity of converging multiple IPs into the same manufacturing process, especially for large SoCs with several styles of IP. Allowing the use of multiple process technologies improves time to market and provides a cost-effective method to create multiple product SKUs. Furthermore, decomposed IP is more easily modified to be independently power gated, and components not in use for a given workload can be shut down, thereby reducing overall power consumption.
[0348] In various embodiments, the package assembly 2490 may include a fewer or greater number of components and chiplets interconnected by structures 2485 or one or more bridges 2487. The chiplets within the package assembly 2490 may have a 2.5D arrangement using chip-on-wafer-on-substrate stacking, where multiple dies are stacked side-by-side on a silicon interposer that includes through-silicon vias (TSVs) to couple the chiplets with a substrate 2480 that includes electrical connections to the package interconnects 2483.
[0349] In one embodiment, the silicon interposer is an active interposer 2489 that includes embedded logic in addition to TSVs. In such embodiments, the chiplets within the package assembly 2490 are arranged on top of the active interposer 2489 using 3D face-to-face die stacking. The active interposer 2489 may include hardware logic for I / O 2491, cache memory 2492, and other hardware logic 2493 in addition to the interconnect structure 2485 and the silicon bridge 2487. The structure 2485 enables communication between the various logic chiplets 2472, 2474 and the logic 2491, 2493 within the active interposer 2489. The structure 2485 can be a NoC interconnect or another form of packet switching structure that exchanges data packets between components of the package assembly. For complex components, the structure 2485 can be a dedicated chiplet that enables communication between the hardware logic of the package assembly 2490.
[0350] A bridge structure 2487 within the active interposer 2489 may be used to facilitate point-to-point interconnection between, for example, a logic or I / O chiplet 2474 and a memory chiplet 2475. In some implementations, the bridge structure 2487 may also be embedded within the substrate 2480.
[0351] The hardware logic chiplets may include dedicated hardware logic chiplets 2472, logic or I / O chiplets 2474, and / or memory chiplets 2475. The hardware logic chiplets 2472 and logic or I / O chiplets 2474 may be implemented at least in part in configurable logic or fixed-function logic hardware and may include one or more portions of any of the processor core(s), graphics processor(s), parallel processors, or other accelerator devices described herein. The memory chiplets 2475 may be DRAM (e.g., GDDR, HBM) memory or cache (SRAM) memory. The cache memory 2492 within the active interposer 2489 (or substrate 2480) may act as a global cache for the package assembly 2490, as part of a distributed global cache, or as a dedicated cache for the structure 2485.
[0352] Each chiplet may be fabricated as a separate semiconductor die and may be coupled to a base die that is embedded within or coupled to a substrate 2480. Coupling to the substrate 2480 may be performed via an interconnect structure 2473. The interconnect structure 2473 may be configured to route electrical signals between various chiplets and logic within the substrate 2480. The interconnect structure 2473 may include interconnects such as, but not limited to, bumps or pillars. In some embodiments, the interconnect structure 2473 may be configured to route electrical signals, such as, for example, input / output (I / O) signals and / or power or ground signals associated with the operation of logic, I / O, and memory chiplets. In one embodiment, an additional interconnect structure couples the active interposer 2489 to the substrate 2480.
[0353] Substrate 2480 may be an epoxy-based laminate substrate, however, it is not limited thereto, and substrate 2480 may also include other suitable types of substrates. Package assembly 2490 may be connected to other electrical devices via package interconnect 2483. Package interconnect 2483 may be coupled to the surface of substrate 2480 to route electrical signals to other electrical devices, such as a motherboard, other chipsets, or multi-chip modules.
[0354] The logic or I / O chiplet 2474 and the memory chiplet 2475 may be electrically coupled via a bridge 2487 configured to route electrical signals between the logic or I / O chiplet 2474 and the memory chiplet 2475. The bridge 2487 may be a dense interconnect structure that provides routing for electrical signals. The bridge 2487 may include a bridge substrate composed of glass or a suitable semiconductor material. Circuit features may be formed on the bridge substrate to provide a chip-to-chip connection between the logic or I / O chiplet 2474 and the memory chiplet 2475. The bridge 2487 may also be referred to as a silicon bridge or an interconnect bridge. For example, the bridge 2487 is an embedded multi-die interconnect bridge (Embedded Multi-die Interconnect Bridge, EMIB). Alternatively, the bridge 2487 may simply be a direct connection from one chiplet to another chiplet.
[0355] Fig.24DA package assembly 2494 including an interchangeable chiplet 2495 is illustrated according to an embodiment. The interchangeable chiplet 2495 can be assembled into standardized sockets on one or more base chiplets 2496, 2498. The base chiplets 2496, 2498 can be coupled via a bridge interconnect 2497, which can be similar to other bridge interconnects described herein and can be, for example, EMIB. Memory chiplets can also be connected to logic or I / O chiplets via a bridge interconnect. The I / O and logic chiplets can communicate via an interconnect structure. The base chiplets can each support one or more sockets in a standardized format for one of logic or I / O or memory / cache.
[0356] The SRAM and power delivery circuits may be fabricated into one or more of the base chiplets 2496, 2498, which may be fabricated using a different process technology relative to the interchangeable chiplets 2495, which are stacked on top of the base chiplets. For example, the base chiplets 2496, 2498 may be fabricated using a larger process technology, while the interchangeable chiplets may be fabricated using a smaller process technology. One or more of the interchangeable chiplets 2495 may be memory (e.g., DRAM) chiplets. Different memory densities may be selected for the package assembly 2494 based on power and / or performance for the product using the package assembly 2494. In addition, logic chiplets with different numbers of types of functional units may be selected at assembly time based on power and / or performance for the product. In addition, chiplets containing IP logic cores of different types may be inserted into interchangeable chiplet sockets, thereby enabling hybrid processor designs that can mix and match IP blocks of different technologies. Exemplary System-on-Chip Integrated Circuit
[0357] Figure 25-26B An exemplary integrated circuit and associated graphics processor that can be manufactured using one or more IP cores are shown. Other logic and circuits may be included in addition to what is shown, including additional graphics processors / cores, peripheral interface controllers, or general purpose processor cores. Figure 25-26B Elements having the same or similar names as elements of any other figures herein describe the same elements as in the other figures, can operate or function in a similar manner as in the other figures, may include the same components, and may be linked to other entities such as, but not limited to, those described elsewhere herein.
[0358] Fig.25is a block diagram illustrating an exemplary system-on-chip integrated circuit 2500 that may be manufactured using one or more IP cores. The exemplary integrated circuit 2500 includes one or more application processors 2505 (e.g., CPUs), at least one graphics processor 2510, which may be a variation of the graphics processors 1408, 1508, 2510, or may be any graphics processor described herein and may be used in place of any of the graphics processors described. Thus, the disclosure of any feature herein in conjunction with a graphics processor also discloses the corresponding combination with the graphics processor 2510, but is not limited thereto. The integrated circuit 2500 may additionally include an image processor 2515 and / or a video processor 2520, either of which may be a modular IP core from the same design facility or from multiple different design facilities. The integrated circuit 2500 may include peripheral or bus logic, including a USB controller 2525, a UART controller 2530, an SPI / SDIO controller 2535, and an I 2 S / I 2 The integrated circuit may include a display device 2545 coupled to one or more of a high-definition multimedia interface (HDMI) controller 2550 and a mobile industry processor interface (MIPI) display interface 2555. Storage may be provided by a flash memory subsystem 2560 (including flash memory and a flash memory controller). A memory interface may be provided via a memory controller 2565 to obtain access to SDRAM or SRAM memory devices. Some integrated circuits additionally include an embedded security engine 2570.
[0359] Figure 26A-26B is a block diagram illustrating an exemplary graphics processor for use within a SoC according to embodiments described herein. The illustrated graphics processor may be a variation of graphics processor 1408, 1508, 2510, or any other graphics processor described herein. The graphics processor may be used in place of graphics processor 1408, 1508, 2510, or any other of the graphics processors described herein. Thus, any disclosure of features in conjunction with graphics processor 1408, 1508, 2510, or any other of the graphics processors described herein also discloses the corresponding Figure 26A-26B The present invention may be combined with, but not limited to, a graphics processor. Fig.26A An exemplary graphics processor 2610 of a system-on-chip integrated circuit is illustrated that may be fabricated using one or more IP cores in accordance with an embodiment. Fig.26B An additional exemplary graphics processor 2640 is illustrated of a system-on-chip integrated circuit that may be fabricated using one or more IP cores in accordance with an embodiment. Fig.26A Graphics processor 2610 is an example of a low-power graphics processor core. Fig.26B The graphics processor 2640 of FIG. 26 is an example of a higher performance graphics processor core. For example, as mentioned at the beginning of this paragraph, each of the graphics processors in the graphics processor 2610 and the graphics processor 2640 may be Fig.25 A variant of the graphics processor 2510.
[0360] like Fig.26A As shown in , the graphics processor 2610 includes a vertex processor 2605 and one or more fragment processors 2615A-2615N (e.g., 2615A, 2615B, 2615C, 2615D, all the way to 2615N-1 and 2615N). The graphics processor 2610 can execute different shader programs via separate logic, so that the vertex processor 2605 is optimized to perform operations for the vertex shader program, while the one or more fragment processors 2615A-2615N perform fragment (e.g., pixel) shading operations for the fragment or pixel shader program. The vertex processor 2605 performs the vertex processing stage of the 3D graphics pipeline and generates primitives and vertex data. (One or more) fragment processors 2615A-2615N use the primitive data and vertex data generated by the vertex processor 2605 to generate a frame buffer that is displayed on the display device. The fragment processor(s) 2615A-2615N may be optimized to execute fragment shader programs as provided in the OpenGL API, which may be used to perform similar operations as pixel shader programs as provided in the Direct 3D API.
[0361] The graphics processor 2610 additionally includes one or more memory management units (MMUs) 2620A-2620B, (one or more) caches 2625A-2625B, and (one or more) circuit interconnects 2630A-2630B. The one or more MMUs 2620A-2620B provide virtual to physical address mappings for the graphics processor 2610 (including for the vertex processor 2605 and / or (one or more) fragment processors 2615A-2615N), which can reference vertex data or image / texture data stored in memory in addition to vertex data or image / texture data stored in the one or more caches 2625A-2625B. The one or more MMUs 2620A-2620B can be synchronized with other MMUs within the system so that each processor 2505-2520 can participate in a shared or unified virtual memory system, including other MMUs within the system. Fig.25 One or more MMUs 2620A-2620B may be associated with one or more application processors 2505, image processors 2515, and / or video processors 2520. The components of graphics processor 2610 may correspond to the components of other graphics processors described herein. Figure 2C The vertex processor 2605 and the fragment processors 2615A-2515N may correspond to the graphics multiprocessor 234. According to an embodiment, one or more circuit interconnects 2630A-2630B enable the graphics processor 2610 to interface with other IP cores within the SoC via an internal bus of the SoC or via a direct connection. The one or more circuit interconnects 2630A-2630B may be connected to Figure 2C Further correspondence may be found between similar components of graphics processor 2610 and the various graphics processor architectures described herein.
[0362] like Fig.26B As shown in FIG. , the graphics processor 2640 includes Fig.26AOne or more MMUs 2620A-2620B, caches 2625A-2625B, and circuit interconnects 2630A-2630B of a graphics processor 2610. Graphics processor 2640 includes one or more shader cores 2655A-2655N (e.g., 2655A, 2655B, 26555C, 2655D, 2655E, 2655F, all the way to 2655N-1 and 2655N) that provide a unified shader core architecture in which a single core or type or core can execute all types of programmable shader code, including shader program code for implementing vertex shaders, fragment shaders, and / or compute shaders. The exact number of shader cores present may vary by embodiment and implementation. In addition, the graphics processor 2640 includes an inter-core task manager 2645 that acts as a thread dispatcher for dispatching execution threads to one or more shader cores 2655A-2655N and a tiling unit 2658 for accelerating tiling operations for tile-based rendering, in which rendering operations for a scene are subdivided in image space, for example, to exploit local spatial coherence within a scene or to optimize the use of internal caches. The shader cores 2655A-2655N may, for example, communicate with Figure 2D The graphics multiprocessor 234 in the embodiment of the present invention corresponds to the graphics multiprocessor 234 in the embodiment of the present invention, or respectively corresponds to the graphics multiprocessor 234 in the embodiment of the present invention. Figure 3A and Figure 3B The graphics multiprocessor 325, 350 corresponds to or corresponds to Figure 3C The multi-core group 365A corresponds to. Data processing system for GPGPU program execution
[0363] Fig. 27 27 is a block diagram of a data processing system 2700 according to an embodiment. The data processing system 2700 is a heterogeneous processing system having a processor 2702, a unified memory 2710, and a GPGPU 2720 including machine learning acceleration logic. The processor 2702 and the GPGPU 2720 can be any of the processors and GPGPU / parallel processors described herein. For example, refer to Figure 1 , the application processor 2702 may be a variant of the processor in the one or more processors 102 illustrated and / or share an architecture with the processor in the one or more processors 102 illustrated. The GPGPU 2720 may be a variant of the parallel processor in the one or more parallel processors 112 illustrated and / or share an architecture with the parallel processor in the one or more parallel processors 112 illustrated. Fig.14, processor 2702 may be a variant of and / or share architecture with one of the processors 1402 illustrated in (one or more) embodiments, and GPGPU 2720 may be a variant of and / or share architecture with one of the graphics processors 1408 illustrated in (one or more) embodiments.
[0364] The application processor 2702 may execute instructions for the compiler 2715 stored in the system memory 2712. In one embodiment, the compiler 2715 is executed on the application processor 2702 to compile the source code 2714A into the compiled code 2714B. The compiled code 2714B may include instructions that are executable by the application processor 2702 and / or instructions that are executable by the GPGPU 2720. The compilation of instructions to be executed by the GPGPU may be performed by a shader or compute program compiler (such as, Fig.23 In one embodiment, the compilation of instructions to be executed by the GPGPU may be performed alternatively or additionally at least in part via execution logic within the GPGPU 2720. For example, the compiler 2715 may migrate certain program code analysis, translation, or compilation operations to the GPGPU 2720.
[0365] During compilation, the compiler 2715 may perform operations to insert metadata including hints about the level of data parallelism present in the compiled code 2714B and / or hints about data locality associated with threads to be dispatched based on the compiled code 2714B. The compiler 2715 may include information necessary to perform such operations, or may perform these operations with the assistance of the runtime library 2716. The runtime library 2716 may also assist the compiler 2715 at the time of compilation of the source code 2714A, and may also include instructions that are linked to the compiled code 2714B at runtime to facilitate the execution of the compiled instructions on the GPGPU 2720. The compiler 2715 may also facilitate register allocation of variables via a register allocator (RA), and generate load and store instructions for moving data for the variable between memory and registers assigned to the variable.
[0366] Unified memory 2710 represents a unified address space accessible by processor 2702 and GPGPU 2720. Unified memory may include system memory 2712 and GPGPU memory 2718. GPGPU memory 2718 is memory within the address space of GPGPU 2720 and may include some or all of system memory 2712. In one embodiment, compiled code 2714B stored in system memory 2712 may be mapped into GPGPU memory 2718 for access by GPGPU 2720. GPGPU memory 2718 also includes GPGPU local memory 2728 of GPGPU 2720. GPGPU local memory 2728 may include, for example, HBM or GDDR memory.
[0367] GPGPU 2720 includes a plurality of computing blocks 2724A-2724N, which may include one or more of the various processing resources described herein. The processing resources may be or may include a variety of different computing resources, such as, for example, execution units, computing units, streaming multiprocessors, graphics multiprocessors, or multi-core groups. In one embodiment, GPGPU 2720 additionally includes a tensor accelerator 2723 (e.g., a matrix accelerator), which may include one or more dedicated computing units designed to accelerate a subset of matrix operations (e.g., dot products, etc.). Some functions to be performed by computing blocks 2724A-2724N may be directly scheduled or migrated to tensor accelerator 2723. In various embodiments, tensor accelerator 2723 includes processing element logic configured to efficiently perform matrix computing operations, such as multiplication and addition operations and dot product operations used by 3D graphics or computing shader programs. In one embodiment, the tensor accelerator 2723 may be configured to accelerate the operation used by the machine learning framework. In one embodiment, the tensor accelerator 2723 is an application-specific integrated circuit explicitly configured to perform a specific set of parallel matrix multiplication and / or addition operations. In one embodiment, the tensor accelerator 2723 is a field programmable gate array (FPGA), which provides fixed-function logic that can be updated between workloads. In one embodiment, the set of computational operations that can be performed by the tensor accelerator 2723 may be limited relative to the operations that can be performed by the computing blocks 2724A-2724N. However, the tensor accelerator 2723 can perform parallel tensor operations with a significantly higher throughput relative to the computing blocks 2724A-2724N. The tensor accelerator 2723 may also be referred to as a tensor accelerator or a tensor core. In one embodiment, the logic components within the tensor accelerator 2723 may be distributed across the processing resources of multiple computing blocks 2724A-2724N, rather than being concentrated in a single circuit.
[0368] GPGPU 2720 may also include a collection of resources that can be shared by computing blocks 2724A-2724N and tensor accelerator 2723, including, but not limited to, a set of registers 2725, a power and performance module 2726, and a cache 2727. In one embodiment, registers 2725 include directly accessible and indirectly accessible registers, wherein the indirectly accessible registers are optimized for use by tensor accelerator 2723. Power and performance module 2726 may be configured to adjust power delivery and clock frequency for computing blocks 2724A-2724N to power gate idle components within computing blocks 2724A-2724N. In various embodiments, cache 2727 may include an instruction cache and / or a low-level data cache.
[0369] The GPGPU 2720 may additionally include an L3 data cache 2730, which may be used to cache data accessed from the unified memory 2710 by the tensor accelerator 2723 and / or computing elements within the compute blocks 2724A-2724N. In one embodiment, the L3 data cache 2730 includes a shared local memory 2732, which may be shared by the computing elements within the compute blocks 2724A-2724N and the tensor accelerator 2723.
[0370] In one embodiment, the GPGPU 2720 includes instruction handling logic, such as a fetch and decode unit 2721 and a scheduler controller 2722. The fetch and decode unit 2721 includes a fetch unit and a decode unit for fetching instructions and decoding the instructions for execution by one or more of the computational blocks 2724A-2724N or by the tensor accelerator 2723. The instructions may be dispatched to the appropriate functional units within the computational blocks 2724A-2724N or the tensor accelerator via the scheduler controller 2722. In one embodiment, the scheduler controller 2722 is an ASIC configurable to perform advanced scheduling operations. In one embodiment, the scheduler controller 2722 is a microcontroller or a low per-instruction energy processor configured to execute scheduling instructions loaded from a firmware module. Data processing system with thread-by-thread variable registers
[0371] Fig.282800 is a block diagram of a system including a GPGPU device 2802, wherein the processing resources have a variable number of threads and thread-by-thread registers. The GPGPU device 2802 includes a graphics engine 2808 and a plurality of computing engines 2810. The graphics engine 2808 can process a command list or command buffer of instructions received from a graphics driver. The graphics engine 2808 performs graphics operations in response to these commands. A rendering command stream converter (RCS2816) associated with the graphics engine 2808 can stream rendering commands to perform shader operations. A thread dispatcher 2820 dispatches threads for these shader operations to processing resources within a computing block 2720A-2720N. The dispatched threads are executed via hardware threads within the processing resources. Similarly, a collection 2810 of computing engines operating asynchronously with each other, and the graphics engine 2808 can dispatch commands for computing shaders and / or GPGPU programs via a plurality of computing command stream converters (CCSn 2818). Thread dispatcher 2820 dispatches threads to processing resources within compute blocks 2720A-2720N to execute compute shaders and / or GPGPU programs. The dispatched threads are executed via hardware threads within the processing resources.
[0372] In the embodiment described herein, the number of active hardware threads in the processing resources of computing blocks 2720A-2720N is configurable.The number of registers assigned to a given hardware thread is also configurable.In one embodiment, the configuration is executed via the VRT configuration 2806 in the non-pipeline state defined in GPU device 2802.Non-pipeline state 2804 defines the state attributes of the global application to hardware resources (such as the processing resources in the graphics core of computing blocks 2720A-2720N).In the non-pipeline state 2804 applied to processing resources, VRT configuration 2806 is defined on the basis of shader stage (for example, shader type), and has an enabling bit, to promote backward compatibility.For example, in one embodiment, VRT configuration 2806 may include a separate configuration for vertex shader, tessellation shader, geometry shader, fragment / pixel shader, mesh shader, compute shader, etc. The VRT configuration 2806 is delivered to the computing blocks 2720A-2720N for execution by the thread dispatcher 2820 associated with the dispatch of threads. The computing blocks 2720A-2720N can configure separate processing resources as required to execute the dispatched workload. The local thread dispatch within the computing blocks 2720A-2720N is then executed according to the VRT configuration 2806 for the shader type to be executed.
[0373] In one embodiment, a three-bit value may be provided as a parameter defining the number of registers enabled for a hardware thread. Table 5 below describes an exemplary register value encoding according to such an embodiment. Table 5 - Variable Register Encoding Register Code Value Number of registers 0 32 1 64 2 96 3 128 4 160 5 192 7 256
[0374] As shown in Table 5, in one embodiment, a maximum of 256 registers can be assigned to a hardware thread in a processing resource, with a minimum of 32 registers per thread. The maximum number of threads that can be used in a processing resource can be limited based on the number of registers enabled per thread. For example, in a processing resource with 1024 registers, if each thread uses 256 registers, only four threads are enabled. In a processing resource with 2028 registers, if each thread uses 256 registers, eight threads can be enabled. However, different numbers of registers can be assigned to different threads in a processing resource. For example, 256 registers can be assigned to two threads, and 64 registers can be assigned to the remaining threads in the processing resource.
[0375] Fig.29 2900 according to an embodiment. The processing resource architecture 2900 includes a graphics core (such as Fig.18A The functional units found in any one of the graphics cores 1815A-1815N of FIG. 1 include Fig.18B The vector engine 1802 and Fig. 18C Components of the matrix engine 1803 of the graphics core 1815A. In one embodiment, a graphics core (e.g., graphics core 1815A) may include multiple instances of a processing resource having a processing resource architecture 2900. A local thread dispatcher (TDL 2901) may dispatch instructions to a collection 2902 of ready instruction queues associated with hardware threads (T0-Tn) for each processing resource. Threads may be distributed to processing resources in a round-robin manner. If an instruction for a thread is not ready to execute, the dispatch of the thread may be skipped. If a processing resource does not have sufficient resources to accept an incoming thread, the TDL 2901 may skip the processing resource.
[0376] Each hardware thread (T0-Tn) is a SIMD thread that can execute a single instruction on multiple channels of data. The data for the instruction can be read from the register in the register file 2910 and written to the register in the register file 2910. The intermediate data for calculation can be stored in the array 2911 of the accumulator. In various embodiments, the register file 2910 can be configured with the characteristics of other GPU register files (e.g., register file 258, register file 334A-334B, register file 369, register 445, etc.) described herein. The register file 2910 may include vector registers (e.g., vector registers 1561), and in one embodiment, include a limited number of scalar registers (scalar registers 1562). In one embodiment, the register file 2910 may include a general register file array, such as GRF 1824. In one embodiment, the number of hardware threads is configurable, wherein a configurable number of registers in the register file 2910 is assigned to each thread. In one embodiment, SIMT execution is enabled by assigning multiple SIMT threads to a single SIMD hardware thread. Data elements associated with multiple SIMT threads may be mapped to multiple sub-registers within a single SIMD register file. The thread control unit 2932 executes via hardware thread control instructions. The thread control unit 2932 includes a thread arbiter 2904 that arbitrates which ready instructions are assigned to an instruction queue 2906 associated with a floating point (FPU), integer (INT) or matrix pipeline (Matrix).
[0377] Source read arbiter 2908 arbitrates the access to register file and accumulator of the source operand read stage of the instruction execution of the instruction in instruction queue 2906. The operand read from register file 2910 can be buffered in reuse buffer 2912 coupled with the functional unit of FPU, INT and matrix pipeline. Reuse buffer 2912 can act as an operand cache, which promotes the reuse of operand data by those functional units. In one embodiment, reuse buffer 2912 is multi-layer deep, thereby allowing the source operands from multiple instructions to be cached. Processing resource architecture 2900 includes multiple different types of functional units, including matrix unit 2914, single precision floating point (FP32) unit 2916, high throughput double precision floating point (FP64) 2917, low throughput FP64 unit 2919 and integer unit 2920. The high-throughput FP64 2917 unit can be configured to execute instructions intended for use by high-performance compute (HPC) and scientific computing workloads, and can be found primarily in graphics processors and computing accelerators designed for servers and / or workstations. The low-throughput FP64 unit 2919 can be found primarily in consumer-grade graphics processors and / or computing accelerators. At least one embodiment may include a high-throughput FP64 2917 unit and a low-throughput FP64 unit 2919. The processing resource architecture may also include an architecture-specific register file (ARF 2918) that contains configuration registers and other non-general purpose registers. The ARF 2918 may be similar to Fig.18B ARF 1826.
[0378] Different instructions are assigned to different functional units based on the instruction type. Matrix operations such as dot product or matrix multiplication operations are assigned to the matrix unit 2914, which can be Fig. 18C An instance of a matrix engine 1803 of, or another matrix unit described herein (such as Figure 3COne or more tensor cores 371 in the register file 2910). Single-precision floating-point instructions can be executed by the FP32 unit 2916 or the high-throughput FP64 unit 2917. Double-precision floating-point instructions can be executed by the high-throughput FP64 unit 2917 or the low-throughput FP64 unit 2919. Integer operations are performed by the integer unit 2920. In one embodiment, the FP32 unit 2916 and the high-throughput FP64 unit 2917 are grouped into a first ALU / FPU (e.g., FPU0), while the low-throughput FP64 unit 2919 and the integer unit 2920 are grouped into a second ALU / FPU (e.g., FPU1). The outputs from these functional units can be written back to the general registers in the register file 2910, or stored in one or more accumulators 2911 via the destination write arbiter 2922.
[0379] In one embodiment, the processing resource architecture 2900 includes a message execution unit (MEU 2915). The MEU 2915 generates messages in response to requests from functional units within the processing resource architecture 2900 and transmits the messages to shared functional units associated with the processing resources of the resource architecture 2900. Such shared functional units include, for example, ray tracing units, samplers, and other fixed function logic, such as those associated with Fig.18A The MEU 2915 may also generate and transmit messages to load / store units, such as the memory load / store unit 1804A and / or the graphics core 1815A. Fig.28 The load / store circuitry 2821 of FIG. Messages to the load / store unit are used to perform load and store operations between the register file 2910 and memory (eg, via the data cache / shared local memory 1806A).
[0380] In one embodiment, the processing resource architecture 2900 includes a source crossbar switch 2930 coupled to the integer unit 2920. The source crossbar switch implements shuffling and reordering of incoming data according to the desired data pattern. In one embodiment, the source crossbar switch 2930 is coupled only to the Src0 input. In other embodiments, the source crossbar switch 2930 can be coupled to other source inputs (e.g., Src1, Src2). For use in the conversion instructions described herein, only the Src0 input is required. However, other conversion instructions utilizing multiple source inputs can be envisioned.
[0381] The source data elements can be read from registers within the register file and stored in a reuse buffer associated with the integer unit 2920. Subsequently, before the data elements are provided as input to the integer unit 2920, the compaction mode of the source data elements can be reconstructed via the source crossbar switch 2930. The way in which data elements are stored in registers of the register file is called the regionalization mode of the register. Register regionalization involves dividing the SIMD register into smaller regions, each region being able to hold a subset of data elements. In one embodiment, the register region can be 1D or 2D (e.g., 1x16, 2x8, 4x4, etc.). The instructions executed by the processing resource can specify registers and sub-registers and regionalization pointing, which regionalization points to the vertical and horizontal spans of the specified region and the number of data elements per row of the region. The vertical span indicates the number of data elements to be skipped to reach the next row of the multi-row region. The width specifies the number of data elements per row in the region. The horizontal span indicates which elements in the row are selected for input. For example, a horizontal span of one indicates that each element is selected. A horizontal span of two indicates that every other element is selected.
[0382] When VRT is enabled, TDL 2901 is configured to check register file 2910 and accumulator array 2911 for processing resources to determine whether sufficient resources are available based on the VRT configuration for the thread to be dispatched. When the thread is dispatched, the receiving processing resource will allocate registers and accumulators as needed based on the VRT configuration for the thread.
[0383] Fig.30 The system 3000 for performing register and accumulator allocation under VRT according to an embodiment is illustrated. Register blocks 3003AA-3003BF in the register file 2910 are allocated to thread slots 3002, where each register block includes 32 registers. The TDL 2901 can maintain a bitmap that includes one bit for each register block within each processing resource of the graphics core. The TDL 2901 also includes a counter for tracking the availability of accumulators 2911. The bitmap and counter data can be maintained by the TDL 2901 to maintain a TDL scoreboard 3010 for each processing resource. The TDL scoreboard 3010 is used to track the valid bit 3014 (which indicates the availability status for the thread) for each thread 3012 within the available thread slot 3002 of the processing resource, the number of register blocks 3016 assigned to the thread, and the register base address 3018 for the thread (which is the starting register offset for the registers assigned to the thread). Each thread knows (eg, via the register encoding values in Table 5) the number of assigned registers associated with the shader stage to be executed by the thread, and will logically address registers starting from the assigned physical register base address.
[0384] In one embodiment, and like the illustrated system, each processing resource includes eight (T0-T7) hardware thread slots 3002, which allows up to 8 concurrent threads. In such embodiments, the register file 2910 includes 1024 registers, which are arranged in 32 register blocks 3003AA-3003BF. When the three-bit register encoding of Table 5 is used, the register size of the thread can be configured to 32, 64, 96, 128, 160, 192, or 256. Some embodiments use an increased number of bits to achieve a finer-grained VRT configuration.
[0385] The actual number of threads that a processing resource can run simultaneously may vary depending on the VRT configuration for the active threads of the processing resource.Table 6 gives an example of resource scaling for a processing resource if each thread is configured identically. Table 6 – Per-thread resources
[0386] As shown in Table 6, in one embodiment, each thread is assigned four accumulators by default. When 256 or more registers are assigned to a thread, an eight accumulator configuration is available. In order to schedule 256 registers to a thread in a processing resource with 1024 registers, TDL will search for a processing resource with an idle thread in an even thread slot (T[n*2]) and its corresponding pair in an odd thread slot (T[(n*2)+1]), where the threads are paired as {T0, T1}, {T2, T3}, {T4, T5}, {T6, T7}. If any of the half does not have any available idle threads, TDL will stop dispatching until the idle thread is available. When TDL allocates an even thread slot to a thread with >= 256 registers, it must also select a thread from the odd thread slot and obtain the accumulator identifier associated with the thread. Then, TDL masks the odd thread slot to prevent subsequent use of the thread slot until its accumulator identifier is no longer used. To ensure proper thread balance between even and odd thread slots, TDL will round-robin arbitration between even and odd thread slots when allocating threads for smaller register size allocations. The number of accumulators is not scaled proportionally for 96 and 160 registers to avoid an odd number of per-thread accumulators, which can cause functional issues for certain data types.
[0387] Not all threads are required to have the same configuration. Threads of different register sizes are supported in the same processing resource. Accordingly, the number of concurrent threads allowed in the processing resource is determined based on the register allocation size and accumulator availability. As an example, a processing resource can have four threads of 64 registers and two threads of 256 registers, as well as many other possible combinations. Since the number of threads that a processing resource can run is no longer a fixed number, TDL 2901 can be configured to dispatch threads based on threads, accumulators, and register availability.
[0388] Fig.31 A register file allocation and tracking system 3100 according to an embodiment is shown. When the VRT is enabled, the local thread dispatcher circuit system (e.g., TDL 2901) allocates threads, registers, and accumulators at the time of dispatch based on the resources specified for the threads. The TDL of the graphics core tracks the general registers and accumulators for each processing resource within the graphics core. The TDL tracks general registers in blocks of 32 registers and tracks accumulator availability in groups of four accumulators. The register file allocation and tracking system 3100 enables the VRT to track register file allocations based on the number of register block indexes within the allocation, wherein each register block index 3102 is associated with a block size of 32 registers. In one embodiment, the register block grouping can be predetermined based on the register allocation size, wherein the register allocation direction 3108 is determined based on the size of the register allocation. The TDL allocates groups of 32, 64, and 96 registers starting from the "bottom" (e.g., highest index) register block, while allocations greater than or equal to 128 registers are allocated from the "top" (e.g., lowest index) register block. In one embodiment, the allocated registers are accessed by threads using base+offset addressing. For example, Fig.30 The TDL scoreboard 3010 shows a configuration in which the eight registers of the processing resources are each allocated 64 registers, which is equivalent to a two-block register allocation for each thread. Thread zero is allocated registers in block indexes 30 and 31, thread one is allocated registers in block indexes 28 and 29, etc. However, no particular correlation is required between the thread identifiers and the order in which registers are allocated to the threads.
[0389] When an incoming thread is ready to be dispatched, TDL searches the register free list in each processing unit and tries to Fig.31. To allocate registers, the scheduling algorithm searches for a sufficient number of free continuous blocks to satisfy the register allocation request. A processing resource is selected from a processing resource with a sufficient number of free registers and / or accumulators. Then, an available hardware thread of the processing resource is selected. Then, TDL allocates the first free continuous block set of the selected processing resource to the thread. The starting block address becomes the base address for the thread. TDL can provide register allocation information to the processing resource in a transparent header for dispatch or via a sideband channel. If the thread group has a barrier, a pre-check is required before the first thread of the thread group is dispatched to the processing resource, where each thread in the thread group will have the same VRT configuration. When TDL receives the end of thread (EoT) from the processing resource, TDL checks the thread scoreboard to determine the register block assigned to the thread. Then, TDL updates the register tracking and thread tracking information in the TDL scoreboard. An exemplary scheduling algorithm is shown in the pseudo code below. TDL Scheduling Algorithm for VRT
[0390] Fig.32 A system 3200 for logical register to physical register conversion for VRT is shown. The system 3200 includes hardware logic for converting register read requests and write requests from a logical register space into a physical register space. The logical register space refers to the register naming scheme used by the processing resource and the kernel program executed by the hardware unit external to the processing reso...
Claims
1. A graphics processor, comprising: Memory interface; a processing cluster coupled to the memory interface, the processing cluster comprising a plurality of graphics cores coupled via a data interconnect; as well as circuitry for dispatching a workload for execution by processing resources within a graphics core of the plurality of graphics cores, the circuitry being configured to: receiving a request to dispatch program code for execution, the program code being associated with a register configuration selected from a plurality of register configurations; selecting a processing resource among a plurality of processing resources within the graphics core, the processing resource determined to have sufficient available resources to satisfy the register configuration for the program code; assigning a number of registers to hardware threads of the processing resources based on the register configuration selected for the program code; and Instructions of the program code are executed via the hardware threads.
2. The graphics processor according to claim 1, wherein: Each register configuration of the plurality of register configurations specifies a number of registers for the hardware thread assigned to the processing resource.
3. The graphics processor according to claim 2, wherein: The number of registers for the hardware thread assigned to the processing resource includes a first number of general purpose registers for the hardware thread assigned to the processing resource and a second number of accumulator registers for the hardware thread assigned to the processing resource.
4. The graphics processor according to claim 3, wherein: The register configuration is selected for the program code based on a shader type associated with the program code.
5. The graphics processor according to any one of claims 1 to 4, wherein: The circuitry is configured to track a number of registers of the processing resource that are allocated to active hardware threads within the processing resource.
6. The graphics processor of claim 5, wherein: The circuitry is configured to track a number of free registers in each respective processing resource of the plurality of processing resources within the graphics core.
7. The graphics processor according to claim 5, wherein: The circuitry is configured to track registers of the processing resource at a register block granularity, wherein a register block includes a plurality of contiguous registers.
8. The graphics processor of claim 7, wherein: The register block includes 32 registers.
9. The graphics processor of claim 8, wherein: The circuitry is configured to select the processing resource of the plurality of processing resources within the graphics core via a round robin scheduler.
10. The graphics processor of claim 9, wherein: The circuit system is configured to: determining whether sufficient contiguous blocks of registers are available in the processing resource based on the register configuration associated with the program code; responsive to a determination that sufficient contiguous blocks of registers are not available, bypassing the processing resources; as well as A next available processing resource is selected among the plurality of processing resources.
11. A method for dynamically configuring processing resources within a graphics core, the method comprising: receiving a request to dispatch program code to a processing resource within the graphics core for execution; Determine whether a per-thread variable register (VRT) is enabled for the program code; responsive to a determination that the VRT is not enabled for the program code, statically configuring the processing resources within the graphics core, the processing resources being selected to execute the program code utilizing a default number of registers per thread; In response to a determination that the VRT is enabled for the program code, dynamically allocating registers to hardware threads of the processing resources according to a register configuration associated with the program code; and Instructions of the program code are executed via the hardware threads.
12. The method of claim 11, wherein: The register configuration associated with the program code is selected from a plurality of register configurations, each register configuration of the plurality of register configurations specifying a number of registers for assignment to the hardware thread of the processing resource.
13. The method of claim 12, additionally comprising: A register configuration is selected from the plurality of register configurations based on a shader type associated with the program code.
14. The method of claim 11, additionally comprising: Determining whether the program code is an asynchronous computing program; determining an asynchronous computation throttling limit for the processing resource configuration; as well as Responsive to a determination that the asynchronous computation throttling limit has not been reached, the hardware thread of the program code is dispatched.
15. The method of claim 14, additionally comprising: In response to a determination that the VRT is enabled for the program code: scaling the asynchronous compute throttling limit based on the register configuration; as well as Based on the scaled asynchronous compute throttling limit, dispatching the hardware thread to the processing resource is stopped.
16. A system comprising means for performing the method according to any one of claims 11-15.
17. A graphics processing system comprising: Memory devices; as well as a graphics processor comprising a processing cluster coupled to the memory device, the processing cluster comprising a plurality of graphics cores coupled via a data interconnect, and circuitry for dispatching a workload for execution by at least one of a plurality of processing resources within a graphics core of the plurality of graphics cores, wherein the circuitry is configured to: receiving a request to dispatch program code for execution, the program code being associated with a register configuration selected from a plurality of register configurations, each register configuration of the plurality of register configurations for specifying a number of registers for assignment to a hardware thread; selecting a processing resource among the plurality of processing resources within the graphics core that is determined to have sufficient available resources to satisfy the register configuration for the program code; assigning a number of registers to the hardware thread of the processing resource based on the register configuration selected for the program code; and Instructions of the program code are executed via the hardware threads.
18. The graphics processor of claim 17, wherein: The number of registers for the hardware thread assigned to the processing resource includes a first number of general purpose registers for the hardware thread assigned to the processing resource and a second number of accumulator registers for the hardware thread assigned to the processing resource.
19. The graphics processing system of claim 18, wherein: The register configuration is selected for the program code based on a shader type associated with the program code.
20. The graphics processing system of claim 16, wherein: The circuitry is configured to track a number of registers of the processing resource that are allocated to active hardware threads within the processing resource.
21. The graphics processing system of claim 20, wherein: The circuitry is configured to track a number of free registers in each respective processing resource of the plurality of processing resources within the graphics core.
22. The graphics processing system of claim 20, wherein: The circuitry is configured to track registers of the processing resource at a register block granularity, wherein a register block includes a plurality of contiguous registers.
23. The graphics processing system of claim 22, wherein: The register block includes 32 registers.
24. The graphics processing system of claim 23, wherein: The circuitry is configured to select the processing resource of the plurality of processing resources within the graphics core via a round robin scheduler.
25. The graphics processing system of claim 24, wherein: The circuit system is configured to: determining whether sufficient contiguous blocks of registers are available in the processing resource based on the register configuration associated with the program code; responsive to a determination that sufficient contiguous blocks of registers are not available, bypassing the processing resources; as well as A next available processing resource is selected among the plurality of processing resources.