Device, method and system for blockchain transaction acceleration
Through hardware accelerator and software combination technology, the blockchain transaction processing speed is improved, the problem of slow blockchain transaction processing speed is solved, efficient and low-cost transaction processing is achieved, and the blockchain transaction processing speed is improved. value.
Patent Information
- Application Number
- CN201810642959.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2018-01-30
- Filing Date
- 2018-06-21
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2038-06-21
AI Technical Summary
Blockchain transaction processing speed is slow, and existing technology is difficult to effectively increase the transaction rate, which limits the value and efficiency of blockchain in enterprise-level applications.
Using a combination of hardware and software technologies such as hardware accelerators, network interface controllers (NICs), and dispatchers to offload blockchain transaction processing through hardware accelerators, improve transaction processing throughput and reduce wait times, leveraging multi-core expansion, FPGA circuits, and ASICs Hardware accelerator optimizes instruction level and data plane processing to achieve efficient blockchain transaction processing.
Significantly improving the blockchain transaction processing speed, exceeding 100,000 transactions per second, reducing transaction processing costs, reducing bottlenecks in privacy and security guarantees, and improving the feasibility and efficiency of blockchain in enterprise-level applications.
Smart Images

Figure CN109284185B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates generally to electronics, and more particularly, embodiments of the present disclosure relate to hardware circuitry for blockchain transaction acceleration. Background Art
[0002] A processor or a collection of processors executes instructions from an instruction set, such as an instruction set architecture (ISA). An instruction set is the portion of a computer architecture that is relevant to programming, and generally includes native data types, instructions, register architecture, addressing modes, memory architecture, interrupt and exception handling, and external input and output (I / O). It should be noted that the term instruction herein may refer to macroinstructions, such as instructions provided to a processor for execution, or to microinstructions, such as instructions generated by a processor's decoder decoding a macroinstruction. BRIEF DESCRIPTION OF THE DRAWINGS
[0003] The present disclosure is illustrated by way of example and not limitation in the figures of the accompanying drawings in which like references indicate similar elements and in which:
[0004] Figure 1 An example blockchain according to an embodiment of the present disclosure is illustrated.
[0005] Figure 2 An example blockchain according to an embodiment of the present disclosure is illustrated.
[0006] Figure 3 An example blockchain according to an embodiment of the present disclosure is illustrated.
[0007] Figure 4 A hardware processor with a hardware accelerator according to an embodiment of the present disclosure is illustrated.
[0008] Figure 5 A hardware processor and a hardware accelerator according to an embodiment of the present disclosure are illustrated.
[0009] Figure 6 A hardware processor with a network interface controller (NIC) is illustrated according to an embodiment of the present disclosure.
[0010] Figure 7 A hardware processor and a network interface controller (NIC) according to an embodiment of the present disclosure are illustrated.
[0011] Figure 8 A circuit for blockchain transaction acceleration according to an embodiment of the present disclosure is illustrated.
[0012] Fig. 9 A flowchart of a blockchain dispatcher according to an embodiment of the present disclosure is illustrated.
[0013] Fig.10 A circuit for blockchain transaction acceleration according to an embodiment of the present disclosure is illustrated.
[0014] Fig.11 A hardware accelerator for blockchain transaction acceleration according to an embodiment of the present disclosure is illustrated.
[0015] Fig.12 A flow chart according to an embodiment of the present disclosure is illustrated.
[0016] Fig.13A is a block diagram illustrating both an exemplary in-order pipeline and an exemplary register renaming, out-of-order issue / execution pipeline according to embodiments of the present disclosure.
[0017] Fig. 13B is a block diagram illustrating both exemplary embodiments of an exemplary register renaming, out-of-order issue / execution architecture core and an exemplary embodiment of an in-order architecture core to be included in a processor according to embodiments of the present disclosure.
[0018] Fig.14A is a block diagram of a single processor core along with its connection to an on-die interconnect network and along with its local subset of a level 2 (L2) cache in accordance with an embodiment of the present disclosure.
[0019] Fig. 14B According to the embodiment of the present disclosure Fig.14A An expanded diagram of part of a processor core.
[0020] Fig.15 is a block diagram of a processor according to an embodiment of the present disclosure, which may have more than one core, may have an integrated memory controller, and may have integrated graphics.
[0021] Fig.16 is a block diagram of a system according to one embodiment of the present disclosure.
[0022] Fig.17 is a block diagram of a more specific exemplary system in accordance with an embodiment of the present disclosure.
[0023] Fig.18 , a block diagram of a second more specific exemplary system according to an embodiment of the present disclosure is shown.
[0024] Fig.19 , showing a block diagram of a system on a chip (SoC) according to an embodiment of the present disclosure.
[0025] Fig. 20is a block diagram comparing the use of a software instruction converter to convert binary instructions in a source instruction set into binary instructions in a target instruction set according to an embodiment of the present disclosure. DETAILED DESCRIPTION
[0026] In the following description, many specific details are set forth. However, it is to be understood that embodiments of the present disclosure may be practiced without these specific details. In other instances, well-known circuits, structures, and techniques are not shown in detail in order not to obscure the understanding of this description.
[0027] References in this specification to "one embodiment," "an embodiment," "an example embodiment," etc. indicate that the described embodiment may include a particular feature, structure, or characteristic, but every embodiment may not necessarily include the particular feature, structure, or characteristic. Moreover, such phrases do not necessarily refer to the same embodiment. Further, when a particular feature, structure, or characteristic is described in conjunction with an embodiment, it is within the knowledge of those skilled in the art to incorporate such feature, structure, or characteristic in conjunction with other embodiments, whether or not explicitly described.
[0028] A (e.g., hardware) processor or a collection of processors executes instructions from an instruction set (e.g., an instruction set architecture (ISA)). An instruction set is part of a computer architecture related to programming, and generally includes native data types, instructions, register architecture, addressing modes, memory architecture, interrupt and exception handling, and external input and output (I / O). It should be noted that the term instruction herein may refer to macroinstructions, such as instructions provided to a processor for execution, or to microinstructions, such as instructions generated by decoding macroinstructions by a decoding unit (decoder) of a processor. A processor (e.g., having one or more cores to decode and / or execute instructions) may, for example, operate on data when performing arithmetic, logic or other functions. In one embodiment, a processor is coupled to one or more (e.g., on-die) accelerators (e.g., offload engines) for performing one or more (e.g., offloaded) operations, such as instead of performing those operations only on the processor. In one embodiment, a processor (e.g., a central processing unit (CPU)) includes an accelerator (e.g., on-die) for performing one or more operations, such as instead of performing those operations only on the processor. Certain embodiments herein provide circuitry (e.g., hardware accelerators) for blockchain transaction acceleration. Circuitry (e.g., hardware accelerators) for blockchain transactions can accelerate blockchain hashing, signing, and security or one or more other operations (e.g., not including blockchain hashing, signing, and security).
[0029] Blockchain is a strategic emerging workload that is still early from a technology readiness and deployment perspective. Blockchain is an emerging technology that may have the potential to disrupt the scale of the Internet itself. Although blockchain technology may very well have many future prospects, its current implementation occurs with restrictions that strictly constrain the way it can be applied, such as for Bitcoin-type blockchain implementations, transaction rates may be limited to about 4 / second, while some other blockchain implementations may be limited to about 2, 3, 4, 5, 6, 7, 8, 9, 10, 100 or 1000 transactions / second. Certain embodiments herein may be extended to a higher number of transactions, such as more than about 50,000 transactions / second or more than about 100,000 transactions / second. For example, by efficiently extending to a much higher transaction processing rate than previously possible, certain embodiments herein allow blockchain utilization (e.g., processing) to become worthwhile in an enterprise setting. Certain embodiments herein provide acceleration techniques (e.g., hardware accelerators, network interface circuits (NICs) and / or dispatchers) to improve performance around blockchain transaction processing latency and throughput. Certain embodiments herein provide hardware and combined hardware / software based techniques. While some of the discussion herein may be applicable to current blockchain implementations, they should not be so limited and are envisioned for use with future blockchain implementation(s). Certain embodiments herein provide blockchain acceleration to reduce costs, improve efficiency, disintermediate, etc.
[0030] At a high level, a blockchain can be viewed as a chain of blocks, for example, where each block contains a reference to the previous block (s) in the chain and may include some additional information, such as discussed further below. A blockchain may generally be a distributed database for maintaining a continuously growing list of records called blocks. In one embodiment, each block contains a timestamp and a link to the previous block. A blockchain (e.g., a blockchain data structure) may be managed by a peer-to-peer network that collectively adheres to a protocol for validating new blocks. By design, a blockchain inherently resists modification of data. In certain embodiments, once recorded, the data in any given block cannot be retroactively altered without the collusion of all subsequent blocks and the majority of the network. Functionally, a blockchain may serve as an open, distributed ledger that can efficiently and in a verifiable and permanent manner record transactions between two parties. The ledger itself may also be programmed to trigger transactions, such as automatically triggering transactions. Blockchains may be used to record events, medical records, and other record management activities, such as, but not limited to, identity management, transaction processing (e.g., financial transactions), and record provenance.
[0031] Now turning to the graph, Figure 1An example blockchain 100 according to an embodiment of the present disclosure is illustrated. Each block may include one or more records, such as transactions. Each block may include multiple batches of hashed and encoded valid transactions. Each block may include, for example, a hash of a previous block in the blockchain linking the two blocks. The main chain (eight unshaded boxes) in the depicted blockchain 100 is the longest series of blocks from the genesis block 102 to the current block 104. Orphan blocks (106 and 108) exist outside the main chain in the blockchain 100.
[0032] Figure 2 An example blockchain 200 according to an embodiment of the present disclosure is illustrated. Each block in the blockchain 200 includes a reference to the previous block in the chain (e.g., Figure 2 The link to the previous block is what makes it a chain, e.g., given a block, you can find all the information in all previous blocks leading up to it, right back to the block called the genesis block (the first block in the chain). The blockchain can be managed (e.g., and stored) by a network of distributed nodes. Each node can have a copy of the entire blockchain. New nodes can come and go, such as synchronizing their copies of the blockchain with those of other nodes when they join the network. Multiple copies of the blockchain on a distributed network of nodes can be one of the powerful features of the blockchain. It can make the blockchain robust to nodes that disappear temporarily or permanently, such as whether the disappearance is due to connectivity issues, hardware failures, or interference. The more nodes there are in the network, the more difficult it may be to corrupt the storage of the blockchain, such as there is no single point of failure, unlike in a centralized system with a single authority.
[0033] exist Figure 2 In the embodiment of the present invention, each block includes a header and a list of transactions (Tx0, Tx1, ... Tx3). The header may include one or more of the following: a pointer to the previous block (e.g., Figure 2 ), a summary of the transactions that the block contains (e.g., the hashes (e.g., Merkle hashes) of those transactions (e.g., Figure 2 The Tx_Root field in ), a timestamp indicating when the block was created (e.g. Figure 2 ), and proof of the work done to create the block (e.g. Figure 2A timestamp (e.g., from a timestamp server) can provide definitive evidence that the data in the block existed at a particular time. The actual timestamp given in a particular block may not necessarily be accurate to the second. In fact, there is nothing that makes a particular block's timestamp stop before the timestamp of the previous block. If a block is in a blockchain, then what is guaranteed is that the block was added before its timestamp (e.g., at most two hours), the blocks before it in the chain existed at the time the block was created, the block was added to the chain before the next block in the chain existed, and the data in the block (e.g., transactions) existed at the time the block was created. A hash of the block's header, combined with each of these pieces of information, can become an identifier for the block to be used by the next block in the chain.
[0034] (E.g., each) node in the network can add blocks to the blockchain. (E.g., each) node sends data (e.g., transactions) that need to go into the block. (E.g., each) node can pack this data into a block that is backward linked to the last block in the blockchain, which has knowledge of the last block (e.g., knows the last block). (E.g., each) node can then transmit the block to the rest of the network to assert that this is a new blockchain. In order to ensure that the nodes in the network have a consistent consensus opinion on what the blockchain holds in certain embodiments, all nodes operate under a set of protocol rules that determine what a valid block looks like. These rules can include ensuring that each transaction is a valid transaction: (e.g., by pointing to the previous matching transaction within the blockchain) ensuring that it is spending money that actually exists for financial transactions and ensuring that it has been signed by the creator of the transaction. These rules can ensure integrity between transactions: for example, ensuring that the same resource (e.g., money) is not consumed (e.g., spent) twice (e.g., each output of a transaction only forms the input of another transaction). Another test for a valid block is when its random number arrives. In one embodiment, to be a valid block, the hash of the header of the block must always start with a certain number of zeros, for example, the number must be lower than a certain target number. The header may contain the hash of the previous block in the chain, the (e.g., Merkle) hash of the transactions in the block, a timestamp, and a random value. Therefore, if a node includes multiple transactions to be put together in a block to be added to the chain, the node may know the hash of the previous block in the chain. The node can calculate the Merkle hash and the current time for the transaction to be placed in the block. But what may not be known and what is to be calculated is what random number will cause the header of the new block to have a hash starting with multiple zeros. In one embodiment, hashing means that there is no realistic way that a node can algorithmically calculate what random number will give the block this property. A valid block, for example, whose hash starts with multiple zeros, can be a proof that the node that created it did a lot of work, so the random number is sometimes called proof of work.
[0035] The number of zeros that a block's hash must start with, or the target number it must be below, can determine the difficulty of creating a new block, and therefore the average time it will take. The smaller the target number, the more zeros a hash may have to start with, the lower the probability of hitting on such a hash, and the harder it is to create a new block.
[0036] Figure 3 An example blockchain 300 according to an embodiment of the present disclosure is illustrated. Each block in the blockchain 300 includes a reference to the previous block in the chain and some additional information (e.g., proof of work and transactions) that make up the contents of the block. Figure 3The numbers under each heading in are examples only. Transactions may be digitally signed and linked into blocks, where each transaction is cryptographically linked to all earlier transactions by hashing paired data, then pairing and hashing the results until a single hash remains (e.g., a (e.g., Merkle) root hash or master hash). Each new transaction in the blockchain may carry with it an unforgeable record of the entire history of the currency and all previous transactions. This tight cryptographic coupling of all past transactions makes it difficult to assume multiple identities or modify the details of a transaction. At the same time, it may enable either party to verify that the transaction details are authentic and have not been tampered with. Hashes are one-way functions, so there is no easy way to find the correct nonce or design a block to be correct in some embodiments, such that changing a block requires regenerating all successors and redoing the work they contain.
[0037] A hash function can take any input and produce an output of a specific (e.g., fixed) size. The process of applying a hash function to some data is generally referred to as hashing. The output of a hash function is generally referred to as a hash. The essential feature of a particular hash function is the (e.g., fixed) size output it produces. One characteristic of a secure cryptographic hash function is that it is one-way. This means that it is virtually impossible or mathematically and computationally improbable to determine what the input is from the output. That is, given a hash, it should be infeasible to learn or find the input data provided to the hash function. The term used for this is anti-imageability. In one embodiment, a secure hash function produces greatly different outputs, for example, even if the inputs differ by only a single bit. Cryptographic hash functions can also be collision-resistant. A collision occurs when a hash function produces the same output for more than one input. A collision occurs if hashed data item 1 and hashed data item 2 produce the same output. Hashing can be widely used with blockchains. Addresses on blockchains can be derived by the process of hashing public keys, for example, Bitcoin addresses can be currently calculated by hashing public keys using SHA2–256 and RIPEMD160. The collision resistance of hash functions can be important because if two users generate the same address (a collision), either one may be able to access the address (e.g., spend money sent to the address). Signatures can also be an essential part of a blockchain. Similar to signing a check, a cryptographic signature can determine which transactions are valid. A signature can be generated from a hash of the data to be signed and a private key. Transaction hashes are highly visible in some blockchains, for example, transactions are referred to by their hashes. For example, 5c504ed432cb51138bcf09aa5e8a410dd4a1e204ef84bfed1be16dfba1b22060 can be a transaction in a blockchain. Using transaction hashes is also more straightforward than a description such as "transaction 1024 in block 1337". Blocks in a blockchain can be identified by their hash, which serves the dual purpose of identification as well as integrity verification. An identification string that also provides its own integrity can be referred to as a self-certifying identifier. For blockchains that use mining, the proof of work can be a number, generally called a nonce, that when combined with other data and hashed produces a value less than a specified target, such as one in more than 10^25 (10 septillion) hashes. When a valid nonce is found, verification of it can be completed within one second, and then the new block is propagated across the network, forming the latest consensus and blockchain.
[0038] Since storage in a blockchain can be considered permanent, and it is uneconomical to store large amounts of data on a blockchain, a practical way to store data on a blockchain can be to store a fixed (e.g., and normally smaller) size representation of the data, which is called a "hash of the data." Another use of the blockchain is as a timestamping service. People can store data in a blockchain now, and at any later time, they may be able to show the data on the blockchain to prove that the data previously existed. In some blockchains, instead, the data itself is hashed and the hash is stored on the blockchain. When data is to be proven to have that age, people can provide the data, and then people can hash the picture and compare it to the hash stored on the blockchain. There are also more advanced examples where hashing is involved, such as involving Merkle numbers, which are at the root of current innovations and scalability for blockchains.
[0039] Certain embodiments herein provide blockchain transaction processing (e.g., acceleration) based on core extensions, hardware accelerators (e.g., field programmable gate array (FPGA) circuits and / or application specific integrated circuits (ASICs)), and / or (e.g., intelligent) network interface controller (NIC) hardware (e.g., circuits). In one embodiment, a NIC connects a computer (e.g., components thereof) to a network. Certain embodiments herein provide software and hardware techniques, such as secure enclaves, hardware security modules, and / or a collection of data plane libraries and network interface controller drivers for data (e.g., packet) processing (e.g., a data plane development kit (DPDK)), as a way to accelerate certain types of private and secure transaction processing, for example, where custom hardware is not appropriate. Certain embodiments herein provide an architecture for integrating hardware circuitry (e.g., one or more hardware accelerators) into a computing system, such as including a new dispatcher component to distribute work to processing (e.g., execution) units and / or perform initial processing on incoming transactions. Certain embodiments herein scale beyond a threshold of (e.g., approximately 1,000) transactions per second. Certain embodiments herein reduce bottlenecks in transaction processing due to complex functions (e.g., (e.g., elliptic curve digital signature algorithm (ECDSA)) key recovery, (e.g., ECDSA) signature verification, and execution of the transaction (or smart contract) itself. Certain embodiments herein reduce bottlenecks in transaction processing for enhanced privacy and security guarantees, such as, for example, zero-knowledge proofs and homomorphic encryption with higher computational costs. Certain embodiments herein provide Hardware and methods for accelerating transaction processing to improve throughput, latency, and / or assurance. The actual approach taken in any given deployment may vary based on the requirements of the domain. In order to ease the burden in developing domain-specific solutions, certain embodiments herein provide a modular architecture that supports multiple accelerator types and / or a dispatcher that intelligently distributes transactions to heterogeneous execution units and / or accelerators for processing. Certain embodiments herein provide acceleration techniques and hardware for blockchain transaction processing, such as utilizing multi-core extensions, hardware accelerators (e.g., field programmable gate array (FPGA) circuits and / or application-specific integrated circuits (ASICs)), (e.g., intelligent) network interface controller (NIC) hardware (e.g., circuits), instruction-level enhancements, hardware assurance modules, secure enclaves, and / or a collection of data plane libraries and network interface controller drivers for data (e.g., packet) processing (e.g., data plane development kits (DPDKs) to provide acceleration techniques and hardware for blockchain transaction processing. Certain embodiments herein provide added value in one or more of the following fields: financial settlement, payment, remittance, supply chain, autonomous vehicles, and / or black-box vehicle recorders.
[0040] Certain embodiments herein provide blockchain workload acceleration utilizing a focus on hardware-based mechanisms and hardware-enabled mechanisms. Examples of several possible hardware-based accelerators are included below. Descriptions of various accelerator options are included below. Fig.10 The discussion describes an example of resource allocation in a blockchain hardware system.
[0041] Figure 4 A hardware processor 400 with a hardware accelerator 404 according to an embodiment of the present disclosure is illustrated. The hardware processor 400 (e.g., core 402) may receive a request (e.g., from software) to execute a blockchain transaction and may offload the execution of a blockchain transaction (e.g., at least a portion of a blockchain transaction) to a hardware accelerator (e.g., hardware accelerator 404). The hardware processor 400 may include one or more cores (0 to N). In one embodiment, each core may communicate with (e.g., be coupled to) a hardware accelerator 404. In one embodiment, each core may communicate with (e.g., be coupled to) one of a plurality of hardware accelerators. The (multiple) cores, (multiple) accelerators, and memory (e.g., data storage device) 406 may communicate with (e.g., be coupled to) each other. The arrows indicate bidirectional communication (e.g., to and from a component), but unidirectional communication may be used. In one embodiment, (e.g., each) core may communicate with (e.g., be coupled to) a memory, which, for example, stores and / or outputs data. The hardware accelerator may include any hardware (e.g., circuit or line) discussed herein. In one embodiment, the (eg, each) accelerator may be in communication with (eg, coupled to) a memory, such as to receive data.
[0042] Figure 5A hardware processor 501 and a hardware accelerator 504 according to an embodiment of the present disclosure are illustrated. In one embodiment, the hardware accelerator is on a die with the hardware processor. In one embodiment, the hardware accelerator is off-die of the hardware processor. In one embodiment, the system 500 includes at least the hardware processor 501 and the hardware accelerator 504 as a system on a chip (SoC). The hardware processor 501 (e.g., core 502) may receive a request (e.g., from software) to execute a blockchain transaction and may offload the execution of a blockchain transaction (e.g., at least a portion of a blockchain transaction) to a hardware accelerator (e.g., hardware accelerator 504). The hardware processor 501 may include one or more cores (0 to N). In one embodiment, each core may communicate with (e.g., be coupled to) a hardware accelerator 504. In one embodiment, each core may communicate with (e.g., be coupled to) one of a plurality of hardware accelerators. The core(s), accelerator(s), and memory (e.g., data storage device) 506 may communicate with (e.g., be coupled to) each other. Arrows indicate bidirectional communication (e.g., to and from a component), but unidirectional communication may be used. In one embodiment, (e.g., each) core may be in communication with (e.g., coupled to) a memory, such as to store and / or output data. A hardware accelerator may include any hardware (e.g., circuitry or wiring) discussed herein. In one embodiment, (e.g., each) accelerator may be in communication with (e.g., coupled to) a memory, such as to receive data.
[0043] Figure 6 A hardware processor 600 with a network interface controller (NIC) 604 accelerator is illustrated in accordance with an embodiment of the present disclosure. The NIC 604 may provide an interface to a network (e.g., network 608) utilizing an Internet protocol suite of networking protocols. The NIC 604 may respond to various types of networking protocol packets, for example without involving a processor. Additionally or alternatively, the NIC 604 may execute a blockchain transaction (e.g., a portion of a blockchain transaction). The network 608 may provide access to other nodes storing blockchains.
[0044] The hardware processor 600 (e.g., core 602) may receive a request (e.g., from software) to perform a blockchain transaction and may offload the execution of the blockchain transaction (e.g., at least a portion of the blockchain transaction) to a hardware accelerator (e.g., hardware accelerator 606) and / or NIC 604. The hardware processor 600 may include one or more cores (0 to N). In one embodiment, each core may communicate with (e.g., be coupled to) a hardware accelerator 606 and / or NIC 604. In one embodiment, each core may communicate with (e.g., be coupled to) one of a plurality of hardware accelerators and / or NICs. The (multiple) cores, (multiple) accelerators, NICs, and memory (e.g., data storage device) (not shown) may communicate with (e.g., be coupled to) each other. The arrows indicate bidirectional communication (e.g., to and from a component), but unidirectional communication may be used. In one embodiment, (e.g., each) core may communicate with (e.g., be coupled to) a memory, which, for example, stores and / or outputs data. The hardware accelerator or NIC may include any hardware (e.g., circuits or lines) discussed herein. In one embodiment, (e.g., each) accelerator or NIC may communicate (e.g., be coupled) with a memory, such as to receive data. The NIC may communicate with a network 608.
[0045] Figure 7 A hardware processor 701 and a network interface controller (NIC) 704 are illustrated in accordance with an embodiment of the present disclosure. In one embodiment, the hardware accelerator is on a die with the hardware processor. In one embodiment, the hardware accelerator is off-die of the hardware processor. In one embodiment, the NIC is on a die with the hardware processor and / or accelerator. In one embodiment, the NIC is off-die of the hardware processor and / or accelerator. In one embodiment, the system 700 includes at least the hardware processor 701 and the NIC 704 as a SoC.
[0046] NIC 704 can provide an interface to a network (e.g., network 708) utilizing an Internet protocol suite of networking protocols. NIC 704 can respond to various types of networking protocol packets, for example without involving a processor. Additionally or alternatively, NIC 704 can execute a blockchain transaction (e.g., a portion of a blockchain transaction). Network 708 can provide access to other nodes storing blockchains.
[0047] The hardware processor 701 (e.g., core 702) may receive a request (e.g., from software) to perform a blockchain transaction and may offload the execution of the blockchain transaction (e.g., at least a portion of the blockchain transaction) to a hardware accelerator (e.g., hardware accelerator 706) and / or NIC 704. The hardware processor 701 may include one or more cores (0 to N). In one embodiment, each core may communicate with (e.g., be coupled to) a hardware accelerator 706 and / or NIC 704. In one embodiment, each core may communicate with (e.g., be coupled to) one of a plurality of hardware accelerators and / or NICs. The (multiple) cores, (multiple) accelerators, NICs, and memory (e.g., data storage device) (not shown) may communicate with (e.g., be coupled to) each other. The arrows indicate bidirectional communication (e.g., to and from a component), but unidirectional communication may be used. In one embodiment, (e.g., each) core may communicate with (e.g., be coupled to) a memory, which, for example, stores and / or outputs data. The hardware accelerator or NIC may include any hardware (e.g., circuits or lines) discussed herein. In one embodiment, (e.g., each) accelerator or NIC may communicate (e.g., be coupled) with a memory, such as to receive data. The NIC may communicate with a network 708.
[0048] Figure 8A circuit 800 for blockchain transaction acceleration according to an embodiment of the present disclosure is illustrated. The block diagram of circuit 800 illustrates one embodiment and options for where various acceleration functions can be implemented. Examples of each of the acceleration functions are described in more detail in the following text. The block diagram of circuit 800 includes one or more processors (e.g., central processing unit (CPU) socket 802), each of which contains one or more cores, which can then support the decoding and / or execution of one or more execution threads (e.g., its instructions). The cores can be connected to each other and / or high-speed input / output (IO) circuits, such as peripheral component interconnect express (PCIe) circuits, via (e.g., high-speed) on-chip interconnects or (e.g., high-speed) buses. Three companion circuits (e.g., chips) connected via (e.g., high-speed) interconnects or (e.g., high-speed) buses are shown: (e.g., intelligent) network interface controller (NIC) 804, a first accelerator 806 (e.g., ASIC), and a second accelerator 808 (e.g., FPGA). The blockchain acceleration system can have any one, any combination, or all of the components described. The block diagram of line 800 also shows an example list of one or more acceleration functions that can be assigned to various components. In some embodiments, there is flexibility in where these functions are assigned. In some implementations, the assignment may take into account application requirements, cost budgets, power budgets, completeness of blockchain architecture / implementation / algorithms, assurance requirements, etc. This figure is not intended to show a complete set of accelerators or mappings to physical implementations, but rather an example.
[0049] Trade Execution
[0050] Transaction (or smart contract) execution generally refers to the task of executing a blockchain transaction. In one embodiment, this occurs on a general-purpose core. In another embodiment, this (e.g., at least part of this) occurs on reprogrammable and / or dedicated hardware (e.g., in the form of FPGAs, ASICs, and / or specialized instructions) to provide higher performance than a general-purpose core with lower power consumption. This is particularly true in the case of supporting specialized and potentially constrained languages in transactions. Bitcoin is an example of a blockchain that can support a minimal scripting language for describing transactions and is amenable to hardware-level implementations, such as including a hardware state machine.
[0051] Key recovery, signing / verification
[0052] The Elliptic Curve Digital Signature Algorithm (ECDSA) or other (e.g., signature) algorithms may be implemented by a blockchain for proof of identity and transaction signing purposes. Because many messages (including all transactions) may be signed using an algorithm (e.g., ECDSA), and because in many implementations the public key is recovered and not forwarded with the message, key recovery may become a significant portion of the blockchain workload. While ECDSA is an example of a digital signature technology used in a blockchain, the key recovery and / or signature / verification accelerator concepts presented herein will also apply to other digital signature algorithms, such as, but not limited to, the RSA algorithm.
[0053] Two possible accelerator functions involving key recovery and signing / verification are:
[0054] (I) Key Recovery - As defined by a digital signature algorithm (e.g., ECDSA), a public key can be recovered from a (e.g., ECDSA) signed message. Key recovery can be an expensive operation (e.g., in terms of processing resources and / or time) and needs to occur in order to use the public key to verify the origin of transactions and messages. As such, it can become a bottleneck in terms of transaction processing. We consider two options for key recovery acceleration:
[0055] a. (a) Function-Specific Accelerators - Purpose-built hardware (e.g., in the form of ASICs, CPU instructions, FPGAs, or other circuits) can be utilized to accelerate the key recovery function.
[0056] b. Public Key Cache - A caching approach can be taken whereby public keys are recovered as needed and stored for future use. The protocol can use the concept of a random unique identifier to identify each participant in the system. The identifier can be sent with the message, for example, and is much shorter in length than the public key. The identifier can be used as a key in a dictionary containing the associated public key, thereby taking advantage of the locality of key usage to greatly reduce the key recovery load in the workload.
[0057] (II) Sign / Verify - A message (e.g., a blockchain transaction message) can be signed once and verified many times (e.g., once per peer (e.g., node) in the network). Function-specific accelerators (e.g., in the form of ASICs, CPU instructions, FPGAs, or other circuits) can be used to speed up the signing / verification operations.
[0058] Hashes (e.g., Merkle trees)
[0059] A Merkle tree may generally refer to a data structure in which each non-leaf node represents a cryptographic hash of its children. Both Merkle trees and hashing may generally be frequent operations in a blockchain and may warrant acceleration. Adding a (e.g., high-speed) hashing and / or Merkle tree engine to a processor (e.g., a CPU, ASIC, FPGA, or NIC) may speed up transaction and block construction and / or verification. In one embodiment, given a set of transactions, specialized hardware is required to construct an entire blockchain block.
[0060] In some systems, for example, when parallel execution of transactions is desired, a dispatcher (e.g., a dispatcher circuit) can be used to accept packets outside the network, perform initial processing, and / or pass them to appropriate components (e.g., transaction execution circuits, such as but not limited to accelerators) for further processing. In this context, an execution circuit can be any circuit (and software running on the circuit) responsible for processing a transaction. The dispatcher can take into account components (e.g., accelerators) that may be heterogeneous in type and capable of handling multiple types of operations and / or transactions. The dispatcher itself can be based on software, firmware, or hardware. In software, a dedicated thread, process, or CPU can perform the function. A network stack acceleration library such as a data plane development kit (DPDK) can be used to improve the performance of the software, for example, the network stack acceleration library reduces network overhead and latency. As hardware, an accelerator (e.g., an ASIC, an FPGA, or some combination thereof) and / or a NIC can perform accelerated functionality. Fig. 9 The following flow chart and associated text in illustrate an embodiment of how a blockchain transaction would flow through a dispatcher (e.g., a dispatcher circuit).
[0061] Fig. 9 A blockchain dispatcher flow chart 900 according to an embodiment of the present disclosure is illustrated. For example, by the dispatcher interfacing with the network 902, (multiple) blockchain transactions may be initially received from peer nodes (e.g., via a NIC) outside the network. Initial processing 904 may include executing functions of the dispatcher to perform its job, such as key recovery and caching, for example. Initial processing 904 may additionally include functions that the dispatcher does not need but may be better completed in the dispatcher, for example, perhaps because it has more suitable resources. Examples of such functions include ECDSA signature verification, decompression, decryption, requesting missing transactions from peers, or other functions. In order to request missing transactions, the dispatcher may need to identify any missing transactions by, for example, using supplied dependency information or performing dependency analysis on the transactions using transaction identification (ID) information such as from an ordering service. Once identified, the dispatcher can send a request to the peer node to retrieve the missing transaction information, for example, reducing latency compared to waiting until a request is made later in the pipeline.
[0062] After initial processing, the dispatcher may map 908 the transaction to hardware (e.g., an accelerator or NIC), e.g., using one of many possible mapping algorithms. One proposed mapping is based on state updated by the transaction, e.g., where a range of a state space is mapped to each of a plurality of execution resources (e.g., an accelerator or NIC). This may provide locality of state to the execution resource(s), e.g., helping to improve performance. Other mappings may utilize the identity of the initiator or a hash of the message itself to distribute work, e.g., when the type of transaction may indicate which accelerator and / or NIC is able to process it. The dispatcher may queue 910 the work with respect to the appropriate accelerator and / or NIC (e.g., for further processing).
[0063] Parallelization
[0064] Parallel execution of blockchain transactions has the potential to greatly improve throughput in many applications. In some embodiments, most transactions have no data dependencies and can be executed completely independently. Various types of hardware (e.g., execution resources) can be used depending on the specific requirements of the application. For example:
[0065] (1) Hardware accelerators (e.g., FPGA / ASIC) – Where dedicated hardware supports transaction execution, multiple engines or chips can execute many transactions in parallel.
[0066] (2) Cores - Use multiple cores in the form of multi-core processors or multi-socket platforms. This can provide scale-out per core until the number of cores begins to exceed the availability of independent transactions.
[0067] (3) Multiple nodes - For larger scale parallelization, such as in a rack or multiple racks, multiple nodes can be used. In this case, specialized nodes (e.g., FPGAs, ASICs, or hardware security modules (described later)) can be shared so that only certain types of transactions are sent to these (e.g., scarce) resources.
[0068] (4) Map / Reduce - This can be used for distributed processing on a cluster. Data can be distributed to many hosts, which filter and sort the data. The data from multiple hosts can then be merged and reduced in an iterative tree manner to get the final answer. This architecture can be applied to blockchain functions including: building or validating Merkle trees, such as for blocks with extremely large transaction counts, for example, each node can build a portion of the Merkle tree, which is then combined with other nodes to build the root; and / or processing a large number of transactions, such as assigning transaction status to the leaf host that actually executed the transaction. The local state can then be hash-mapped / reduced to build a signature of the entire state after applying the transaction in the block.
[0069] Security / Privacy
[0070] In some cases, security or privacy imposes additional requirements on transaction processing (e.g., execution), resulting in the need for specialized acceleration hardware and / or more secure execution environments. Four such cases are considered below:
[0071] (1) Zero-knowledge proofs - Zero-knowledge proofs are methods for proving that a statement is true without revealing any information about the statement. This technique can strengthen the foundation of some blockchain implementations that focus on user privacy. Since such proofs can be relatively expensive compared to transactions without strong privacy guarantees, certain embodiments herein include acceleration hardware (e.g., in the form of FPGAs or ASICs) to speed up these algorithms. This can result in improved execution time, increased throughput, and reduced latency.
[0072] (2) Homomorphic encryption - Homomorphic encryption provides improved privacy and security by allowing computations to be performed directly on encrypted data without first decrypting it. Blockchain applications can employ homomorphic encryption by storing encrypted data on the blockchain and operating directly on it as it is. However, even more than zero-knowledge proofs, these techniques can be computationally expensive, leading to opportunities to improve performance using acceleration hardware (e.g., FPGAs or ASICs).
[0073] (3) Hardware security modules (e.g., circuits) - Hardware security modules are computing devices that safeguard private keys used in cryptographic algorithms. In blockchain applications where increased security or privacy is required (e.g., but homomorphic encryption or zero-knowledge proofs are considered too expensive or otherwise inapplicable), hardware security circuits (e.g., modules) can be used as a platform to provide higher security and / or privacy levels with high performance. Hardware security circuits (e.g., modules) can ensure that the correct software code is running and privacy is protected.
[0074] (4) Secure Enclaves - Secure enclave technology, such as one or more instructions that, when executed, allow user-level code to allocate a private area of memory called an enclave that is protected from processes running at a higher privilege level. Enclaves can run on cores instead of dedicated HSM hardware and can provide secure and private execution of blockchain transactions.
[0075] Trusted Sync Time
[0076] Timestamping is an important aspect of distributed systems including blockchains, however accurate and precise time sources may not be available in typical computing environments. The Network Time Protocol can provide synchronized time, but is subject to precision and accuracy limitations that reduce its usefulness across many peers. Distributed synchronized time derives highly accurate time along with error bounds from a combination of GPS, atomic clocks, or other reliable sources. Building trust into the system, for example through a tamper-proof environment, encrypted firmware and data links, and data integrity checks, can provide confidence that the generated time has not been tampered with. This allows peers in a distributed system to rely on timestamps for ordering or other purposes without the need for a centralized timestamp server.
[0077] Blockchain Accelerator Implementation Example
[0078] Fig.10 A circuit 1000 for blockchain transaction acceleration according to an embodiment of the present disclosure is illustrated. In this section, a specific implementation of the blockchain accelerator circuit 1000 is discussed using one or more of the previously described components. Fig.10, example functionality (e.g., responsibilities) are depicted next to each component, and example interfaces are depicted next to each interface (shown as block arrows). Note that these are examples, and one or more of the functionalities may be performed by one or more of the components. Externally generated transactions and blocks enter line 1000 from the network (e.g., through a NIC) at the top of the diagram. The (e.g., smart) NIC offloads computationally expensive (e.g., ECDSA) key recovery and signature verification to dedicated circuits on an accelerator (e.g., an FPGA or ASIC). The NIC may track block contents and issue requests to peers for any missing transactions. The core(s) may be responsible for running the distributed ledger system. Valid blocks and transactions may be passed to the core(s) that execute them relative to the ledger. New transactions may be initiated outside the core(s) at the request of a user, and new blocks may be initiated as part of a peer consensus protocol. Optimized libraries can accelerate (e.g., Merkle tree) hashing and (e.g., ECDSA) signing, and dedicated accelerator(s) can compress and decompress data that can be stored directly on-chain or hashed and stored off-chain with signatures on-chain. Instructions (e.g., secure enclave instructions) can provide an isolated execution environment for secure or private transactions, which may include a private side ledger. An attached accelerator (e.g., FPGA or ASIC) can provide dedicated hardware resources to accelerate highly expensive zero-knowledge proof or homomorphic encryption operations, returning valid / invalid, and a set of ledger state updates. The accelerator can also be connected to a GPS receiver and / or atomic clock (not shown) to provide a trusted source of absolute time.
[0079] Certain embodiments herein include a hardware accelerator to fill in missing transactions, such as by accessing a network. Certain embodiments herein include a hardware accelerator to recover keys from encrypted dates (e.g., from blocks of a blockchain). Certain embodiments herein cache recovered keys.
[0080] Fig.11 A hardware accelerator 1100 for blockchain transaction acceleration according to an embodiment of the present disclosure is illustrated. One implementation of an incoming data (eg, packet) flow is discussed below, and there may be an associated outgoing flow.
[0081] Fig.11 Overview
[0082] Fig.11 One implementation of a blockchain accelerator 1100 is shown. If desired, other processing engines (e.g., and circuits) or configurations may be used to meet different needs.
[0083] General Engine Operation
[0084] Each engine includes circuitry with a controller (e.g., control) and some number of computational circuit blocks (A, B, C, ...). In one embodiment, at reset time, the controller polls the bus (or interconnect) to discover what computational blocks are present. This can vary based on application, performance needs, etc.
[0085] When data enters (e.g., each) engine from the left, the corresponding controller first examines the data to determine what computation steps are required and sends the data to the first computation block required. After the computation block is completed, the data returns to the controller, which determines the next computation block required, and repeats until no more processing is required. The data is then passed to the next engine or component.
[0086] If the controller determines that a compute block is needed but it is not present in the instance, or if any other unrecoverable error occurs, the data may be passed to the processor (e.g., CPU) through an exception path (e.g., exception path 1101). This structure may provide pipelining and scaling of data to achieve throughput requirements.
[0087] Packet Processing Engine
[0088] The packet processing engine (e.g., its circuitry) takes packets out of the network and handles their reconstruction into messages. This can be a TCP / IP stack or something more specific to blockchain.
[0089] The types of computational blocks that exist may include (but are not limited to):
[0090] ● Group deduplication
[0091] ● Group reordering
[0092] ● Message reconstruction
[0093] ● Error recovery.
[0094] Message processing engine (for example, dispatcher)
[0095] The engine (e.g., its circuitry) takes the reconstructed message from the packet processing engine and performs processing, such as that which is common to all message types. The types of computational blocks present may include (but are not limited to):
[0096] ● Decompression
[0097] ● Certification.
[0098] After the processing is completed in the circuit (e.g., engine), its controller can determine the required next engine (e.g., circuit) based on the type of message (e.g., transaction, block, or peer type of the message) and forward the message (e.g., and / or other data) to the appropriate engine in the plurality of engines (e.g., circuits). For example, each block in a blockchain may have one or more transactions and other payloads (e.g., such as Figure 2 or Figure 3 ). In one embodiment, a dispatcher (e.g., a message processing engine) routes (e.g., forwards) an operation (e.g., a request for an action or a message to cause an action) to one of a plurality of engines (e.g., accelerators or circuits) based on the type of operation (e.g., the type of action requested), for example, and based on the type of engine. In one embodiment, a block-type operation (e.g., a block operation) includes checking whether the previous block hash is correct and / or whether the proof of work meets the requirements. In one embodiment, a transaction-type operation (e.g., a transaction operation) includes checking whether the sum of inputs is equal to the sum of outputs (e.g., for Bitcoin) or some other function for different blockchains. In one embodiment, some circuits may be repeated in multiple engines, such as decompression circuits.
[0099] Transaction Processing Engine
[0100] The transaction processing engine (eg, its circuitry) handles transaction type messages.
[0101] The types of computational blocks that exist may include (but are not limited to):
[0102] ● Data deduplication
[0103] ● Public key recovery (e.g., once recovered, public keys can be cached and reused for future transactions from the same initiator)
[0104] ● Signature verification
[0105] ● Request missing transactions
[0106] ● Verify the transaction.
[0107] Once processed, the transaction may be stored in a cache and / or sent to a processor (eg, a CPU).
[0108] Block Processing Engine
[0109] The block processing engine (e.g., its circuitry) handles block type messages. The types of computational blocks present may include (but are not limited to):
[0110] ● Data deduplication
[0111] ● Public key recovery (e.g., once recovered, public keys can be cached and reused for future transactions from the same initiator)
[0112] ● Signature verification
[0113] ● Request missing transactions
[0114] ● Verify the block.
[0115] Once processed, the tile may be stored in a cache and / or sent to a processor (eg, a CPU).
[0116] Peer Processing Engine
[0117] The peer processing engine (eg, its circuitry) handles block type messages.
[0118] The types of computational blocks that exist may include (but are not limited to):
[0119] ● Register peers
[0120] ● Unregister a peer
[0121] ● Forward transactions / blocks to peers.
[0122] Cache
[0123] The cache may store data for use by the engine (eg, its circuitry).
[0124] Fig.12 A flowchart 1200 according to an embodiment of the present disclosure is illustrated. The depicted flow 1200 includes receiving an operation for a hardware accelerator using a network interface controller 1202; routing the operation to a transaction processing circuit of the hardware accelerator using a dispatcher circuit of the network interface controller 1204 when the operation is a transaction operation; and routing the operation to a block processing circuit of the hardware accelerator using a dispatcher circuit of the network interface controller 1206 when the operation is a block operation.
[0125] In one embodiment, a hardware processor includes a core to execute a thread and offload an operation of a blockchain transaction; and a hardware accelerator to perform the operation of the blockchain transaction, wherein the hardware accelerator includes a dispatcher circuit to route the operation to a transaction processing circuit when the operation is a transaction operation and to route the operation to a block processing circuit when the operation is a block operation. The dispatcher circuit may perform initial processing for the operation before routing the operation. The initial processing may include one or more of the following: key recovery, key caching, signing, or signature verification for the operation. The dispatcher circuit may route the operation to a peer processing circuit when the operation is a peer operation. The peer operation may include requesting missing transactions of a block from a peer. The peer operation may include sending missing transactions of a block to a peer.
[0126] In another embodiment, a method includes offloading an operation from a hardware processor to a hardware accelerator; routing the operation to a transaction processing circuit of the hardware accelerator using a dispatcher circuit when the operation is a transaction operation; and routing the operation to a block processing circuit of the hardware accelerator using a dispatcher circuit when the operation is a block operation. The method may include performing initial processing for the operation using the dispatcher circuit before routing the operation. The initial processing may include one or more of: key recovery, key caching, signing, or signature verification for the operation. The method may include routing the operation to a peer processing circuit of the hardware accelerator using the dispatcher circuit when the operation is a peer operation. The peer operation may include requesting missing transactions for a block from a peer. The peer operation may include sending missing transactions for a block to a peer.
[0127] In yet another embodiment, a hardware processor includes a hardware accelerator to perform an operation of a blockchain transaction; and a network interface controller including a dispatcher circuit to route the operation to the transaction processing circuit of the hardware accelerator when the operation is a transaction operation and to route the operation to the block processing circuit of the hardware accelerator when the operation is a block operation. The dispatcher circuit may perform initial processing for the operation before routing the operation. The initial processing may include one or more of: key recovery, key caching, signing, or signature verification for the operation. The dispatcher circuit may route the operation to the peer processing circuit when the operation is a peer operation. The peer operation may include requesting missing transactions of a block from a peer using the network interface controller. The peer operation may include sending missing transactions of a block to a peer using the network interface controller.
[0128] In another embodiment, a method includes receiving an operation for a hardware accelerator using a network interface controller; routing the operation to a transaction processing circuit of the hardware accelerator using a dispatcher circuit of the network interface controller when the operation is a transaction operation; and routing the operation to a block processing circuit of the hardware accelerator using a dispatcher circuit of the network interface controller when the operation is a block operation. The method may include performing initial processing for the operation using the dispatcher circuit before routing the operation. The initial processing may include one or more of: key recovery, key caching, signing, or signature verification for the operation. The method may include routing the operation to a peer processing circuit of the hardware accelerator using the dispatcher circuit when the operation is a peer operation. The peer operation may include requesting a missing transaction for a block from a peer using the network interface controller. The peer operation may include sending a missing transaction for a block to a peer using the network interface controller.
[0129] In yet another embodiment, a hardware processor includes a core to execute a thread and offload an operation of a blockchain transaction; and a component to perform the operation of the blockchain transaction, wherein the component is to route the operation to a transaction processing circuit when the operation is a transaction operation and to route the operation to a block processing circuit when the operation is a block operation.
[0130] In another embodiment, a hardware processor includes means to perform an operation of a blockchain transaction; and means to route the operation to a transaction processing circuit when the operation is a transaction operation and to route the operation to a block processing circuit when the operation is a block operation.
[0131] In yet another embodiment, an apparatus includes a data storage device storing code, which, when executed by a hardware processor, causes the hardware processor to perform any method disclosed herein. An apparatus may be as described in the detailed description. A method may be as described in the detailed description.
[0132] In another embodiment, a non-transitory machine-readable medium stores code that, when executed by a machine, causes the machine to perform a method, including any of the methods disclosed herein.
[0133] An instruction set may include one or more instruction formats. A given instruction format may define various fields (e.g., the number of bits, the position of bits) to specify, among other things, operations to be performed (e.g., opcodes) and (multiple) operands and / or (multiple) other data fields (e.g., masks) on which operations are to be performed. Some instruction formats are further decomposed by the definition of instruction templates (or subformats). For example, an instruction template of a given instruction format may be defined as having different subsets of fields of the instruction format (the included fields are usually in the same order, but at least some have different bit positions because fewer fields are included) and / or defined as given fields interpreted differently. Therefore, each instruction in an ISA is expressed using a given instruction format (and if defined, a given one of the instruction templates of the instruction format is adopted) and includes fields for specifying operations and operands. For example, an exemplary addition (ADD) instruction has a specific opcode and instruction format, the instruction format including an opcode field for specifying the opcode and an operand field for selecting operands (source 1 / destination and source 2); and the occurrence of the addition instruction in an instruction stream will have specific content in the operand field for selecting a specific operand. A collection of SIMD extensions known as Advanced Vector Extensions (AVX) (AVX1 and AVX2) and using a vector extension (VEX) encoding scheme has been released and / or announced (e.g., see Intel® 64 and IA-32 Architectures Software Developer's Manual, July 2017; and see Intel® Architecture Instruction Set Extensions Programming Reference, April 2017).
[0134] Exemplary Core Architectures, Processors, and Computer Architectures
[0135] Processor cores may be implemented in different ways, for different purposes, and in different processors. For example, implementations of such cores may include: 1) a general-purpose in-order core intended for general-purpose computing; 2) a high-performance general-purpose out-of-order core intended for general-purpose computing; 3) a special-purpose core intended primarily for graphics and / or scientific (throughput) computing. Implementations of different processors may include: 1) a CPU including one or more general-purpose in-order cores intended for general-purpose computing and / or one or more general-purpose out-of-order cores intended for general-purpose computing; and 2) a coprocessor including one or more special-purpose cores intended primarily for graphics and / or science (throughput). Such different processors result in different computer system architectures, which may include: 1) a coprocessor on a separate chip from the CPU; 2) a coprocessor on a separate die in the same package as the CPU; 3) a coprocessor on the same die as the CPU (in which case such a coprocessor is sometimes referred to as special-purpose logic, such as integrated graphics and / or scientific (throughput) logic, or as a special-purpose core); and 4) a system on a chip, which may include the described CPU (sometimes referred to as (multiple) application cores or (multiple) application processors), the coprocessor described above, and additional functionality on the same die. An exemplary core architecture is described next, followed by a description of exemplary processor and computer architectures.
[0136] Exemplary core architecture
[0137] In-order and out-of-order core diagram
[0138] Fig.13A is a block diagram illustrating both an exemplary in-order pipeline and an exemplary register renaming, out-of-order issue / execution pipeline according to embodiments of the present invention. Fig. 13B is a block diagram illustrating both exemplary embodiments of an exemplary register renaming, out-of-order issue / execution architecture core and an exemplary in-order architecture core to be included in a processor according to embodiments of the present invention. Fig.13A The solid-line boxes in -B illustrate the in-order pipeline and in-order core, while the optional addition of dashed-line boxes illustrates register renaming, out-of-order issue / execution pipeline and core. Assuming that the in-order aspect is a subset of the out-of-order aspect, the out-of-order aspect will be described.
[0139] exist Fig.13A , the processor pipeline 1300 includes a fetch stage 1302, a length decode stage 1304, a decode stage 1306, an allocation stage 1308, a rename stage 1310, a schedule (also called dispatch or issue) stage 1312, a register read / memory read stage 1314, an execute stage 1316, a write back / memory write stage 1318, an exception handling stage 1322, and a commit stage 1324.
[0140] Fig. 13B A processor core 1390 is shown, which includes a front end unit 1330 coupled to an execution engine unit 1350, and both are coupled to a memory unit 1370. The core 1390 can be a reduced instruction set computing (RISC) core, a complex instruction set computing (CISC) core, a very long instruction word (VLIW) core, or a hybrid or alternative core type. As a further option, the core 1390 can be a special purpose core, such as, for example, a network or communication core, a compression engine, a coprocessor core, a general purpose computing graphics processing unit (GPGPU) core, a graphics core, etc.
[0141] The front end unit 1330 includes a branch prediction unit 1332 coupled to an instruction cache unit 1334, which is coupled to an instruction translation lookaside buffer (TLB) 1336, which is coupled to an instruction fetch unit 1338, which is coupled to a decode unit 1340. The decode unit 1340 (or decoder or decoder unit) can decode instructions (e.g., macroinstructions) and generate one or more micro-operations, microcode entry points, microinstructions, other instructions, or other control signals as outputs, which are decoded from or otherwise reflect or are derived from the original instructions. The decode unit 1340 can be implemented using a variety of different mechanisms. Examples of suitable mechanisms include, but are not limited to, lookup tables, hardware implementations, programmable logic arrays (PLA), microcode read-only memories (ROMs), etc. In one embodiment, the core 1390 includes a microcode ROM or other medium that stores microcode for certain macroinstructions (e.g., in the decode unit 1340 or otherwise within the front end unit 1330). Decode unit 1340 is coupled to rename / allocator unit 1352 in execution engine unit 1350 .
[0142] The execution engine unit 1350 includes a rename / allocator unit 1352 coupled to a retirement unit 1354 and a set of one or more scheduler units 1356. The scheduler unit(s) 1356 represent any number of different schedulers, including reservation stations, central instruction windows, etc. The scheduler unit(s) 1356 are coupled to a physical register file(s) unit(s) 1358. Each of the physical register file(s) units 1358 represents one or more physical register files, different of which store one or more different data types, such as scalar integers, scalar floating points, packed integers, packed floating points, vector integers, vector floating points, status (e.g., an instruction pointer that is the address of the next instruction to be executed), etc. In one embodiment, the physical register file(s) unit(s) 1358 include a vector register unit, a write mask register unit, and a scalar register unit. These register units may provide architectural vector registers, vector mask registers, and general purpose registers. The physical register file(s) unit(s) 1358 overlap with the retirement unit(s) 1354 to illustrate various ways in which register renaming and out-of-order execution may be implemented (e.g., using reorder buffer(s) and retirement register file(s); using future file(s), history buffer(s) and retirement register file(s); using register maps and pools of registers; etc.). The retirement unit(s) 1354 and the physical register file(s) unit(s) 1358 are coupled to execution cluster(s) 1360. The execution cluster(s) 1360 include a set of one or more execution units 1362 and a set of one or more memory access units 1364. The execution units 1362 may perform various operations (e.g., shifts, additions, subtractions, multiplications) and on various data types (e.g., scalar floating point, packed integer, packed floating point, vector integer, vector floating point). While some embodiments may include multiple execution units dedicated to a particular function or set of functions, other embodiments may include only one execution unit or multiple execution units that all perform all functions. Scheduler unit(s) 1356, physical register file(s) units 1358, and execution cluster(s) 1360 are shown as possibly plural, as some embodiments create separate pipelines for certain types of data / operations (e.g., scalar integer pipelines, scalar floating point / packed integer / packed floating point / vector integer / vector floating point pipelines, and / or memory access pipelines, each with their own scheduler unit, physical register file(s) units, and / or execution clusters—and in the case of separate memory access pipelines, certain embodiments are implemented where only the execution cluster for that pipeline has memory access unit(s) 1364). It should also be understood that where separate pipelines are used, one or more of these pipelines may be out-of-order issue / execution, and the rest in-order.
[0143] A set of memory access units 1364 are coupled to a memory unit 1370, which includes a data TLB unit 1372 coupled to a data cache unit 1374, which is coupled to a level 2 (L2) cache unit 1376. In one exemplary embodiment, the memory access unit 1364 may include a load unit, a store address unit, and a store data unit, each of which is coupled to the data TLB unit 1372 in the memory unit 1370. The instruction cache unit 1334 is further coupled to a level 2 (L2) cache unit 1376 in the memory unit 1370. The L2 cache unit 1376 is coupled to one or more other levels of cache and ultimately to main memory.
[0144] As an example, an exemplary register renaming, out-of-order issue / execution core architecture may implement pipeline 1300 as follows: 1) instruction fetch 1338 performs fetch and length decode stages 1302 and 1304; 2) decode unit 1340 performs decode stage 1306; 3) rename / allocator unit 1352 performs allocate stage 1308 and rename stage 1310; 4) (multiple) scheduler units 1356 perform schedule stage 1312; 5) (multiple) physical register file units 1358 and memory units 1370 perform register read / memory read stage 1314; execution cluster 1360 performs execute stage 1316; 6) memory unit 1370 and (multiple) physical register file units 1358 perform write back / memory write stage 1318; 7) various units may be involved in exception handling stage 1322; and 8) retirement unit 1354 and (multiple) physical register file units 1358 perform commit stage 1324.
[0145] Core 1390 may support one or more instruction sets (e.g., the x86 instruction set (with some extensions that have been added with newer versions); the MIPS instruction set from MIPS Technologies of Sunnyvale, California; the ARM instruction set from ARM Holdings of Sunnyvale, California (with optional additional extensions such as NEON)), which include the instruction(s) described herein. In one embodiment, core 1390 includes logic to support packed data instruction set extensions (e.g., AVX1, AVX2), allowing operations used by many multimedia applications to be performed using packed data.
[0146] It should be understood that a core can support multithreading (executing two or more parallel sets of operations or threads) and can do so in a variety of ways, including time-sliced multithreading, simultaneous multithreading (where a single physical core provides a logical core for each thread that the physical core multithreads simultaneously, or a combination thereof (e.g., time-sliced fetch and decode followed by simultaneous multithreading such as in Intel® Hyper-Threading Technology).
[0147] Although register renaming is described in the context of out-of-order execution, it should be understood that register renaming can be used in an in-order architecture. Although the illustrated embodiment of the processor also includes separate instruction and data cache units 1334 / 1374 and a shared L2 cache unit 1376, alternative embodiments may have a single internal cache for both instructions and data, such as, for example, a level 1 (L1) internal cache or multiple levels of internal cache. In some embodiments, the system may include a combination of internal caches and external caches external to the core and / or processor. Alternatively, all caches may be external to the core and / or processor.
[0148] Specific exemplary in-order core architecture
[0149] Fig.14A -B illustrates a block diagram of a more specific exemplary in-order core architecture, which would be one of several logic blocks in a chip (including other cores of the same type and / or different types). The logic block communicates with some fixed function logic, memory I / O interfaces, and other necessary I / O logic via a high bandwidth interconnect network (e.g., a ring network), depending on the application.
[0150] Fig.14A 1404 and 1410. FIG. 1405 is a block diagram of a single processor core along with its connection to an on-die interconnect network 1402 and along with its local subset of a level 2 (L2) cache 1404 according to an embodiment of the present disclosure. In one embodiment, the instruction decode unit 1400 supports the x86 instruction set with a packed data instruction set extension. The L1 cache 1406 allows low latency access to cache memory in the scalar and vector units. While in one embodiment (to simplify the design), the scalar unit 1408 and the vector unit 1410 use separate register sets (scalar registers 1412 and vector registers 1414, respectively), and data transferred between them is written to memory and then read back from the level 1 (L1) cache 1406, alternative embodiments of the present disclosure may use a different approach (e.g., using a single register set or including a communication path that allows data to be transferred between the two register files without being written and read back).
[0151] The local subset of L2 cache 1404 is part of the global L2 cache, which is divided into separate local subsets, one for each processor core. Each processor core has a direct access path to its own local subset of L2 cache 1404. Data read by the processor core is stored in its L2 cache subset 1404 and can be quickly accessed in parallel with other processor cores accessing their own local L2 cache subsets. Data written by the processor core is stored in its own L2 cache subset 1404 and flushed from other subsets if necessary. The ring network ensures the consistency of shared data. The ring network is bidirectional to allow agents such as processor cores, L2 caches, and other logic blocks to communicate with each other within the chip. Each ring data-path is 1012 bits wide in each direction.
[0152] Fig. 14B According to an embodiment of the present invention Fig.14A An expanded diagram of part of a processor core. Fig. 14B Includes the L1 data cache 1406A portion of the L1 cache 1404, as well as more details about the vector unit 1410 and vector registers 1414. Specifically, the vector unit 1410 is a 16-wide vector processing unit (VPU) (see 16-wide ALU 1428) that executes one or more of integer, single-precision floating point, and double-precision floating point instructions. The VPU supports swizzling of register inputs using a swizzle unit 1420, numerical conversion using numerical conversion units 1422A-B, and copying of memory inputs using a copy unit 1424. Write mask registers 1426 allow prediction of resulting vector writes.
[0153] Fig.15 is a block diagram of a processor 1500 that may have more than one core, may have an integrated memory controller, and may have integrated graphics according to an embodiment of the present disclosure. Fig.15 The solid line box in the figure illustrates a processor 1500 having a single core 1502A, a system agent 1510, a set of one or more bus controller units 1516, while the optional additional diagram of the dashed line box illustrates an alternative processor 1500 having multiple cores 1502A-N, a set of one or more integrated memory controller units 1514 in the system agent unit 1510, and dedicated logic 1508.
[0154] Thus, different implementations of processor 1500 may include: 1) a CPU having dedicated logic 1508 that is integrated graphics and / or scientific (throughput) logic (which may include one or more cores), and cores 1502A-N that are one or more general purpose cores (e.g., general purpose in-order cores, general purpose out-of-order cores, combinations of the two); 2) a coprocessor having cores 1502A-N that are a large number of dedicated cores intended primarily for graphics and / or science (throughput); and 3) a coprocessor having cores 1502A-N that are a large number of general purpose in-order cores. Thus, processor 1500 may be a general purpose processor, a coprocessor, or a dedicated processor, such as, for example, a network or communication processor, a compression engine, a graphics processor, a GPGPU (general purpose graphics processing unit), a high throughput many integrated core (MIC) coprocessor (including 30 or more cores), an embedded processor, etc. The processor may be implemented on one or more chips. Processor 1500 may be part of one or more substrates and / or may be implemented on one or more substrates using any of a number of process technologies (such as, for example, BiCMOS, CMOS, or NMOS).
[0155] The memory hierarchy includes one or more levels of cache within the core, a set of one or more shared cache units 1506, and external memory (not shown) coupled to a set of integrated memory controller units 1514. The set of shared cache units 1506 may include one or more mid-level caches, such as level 2 (L2), level 3 (L3), level 4 (L4), or other levels of cache, a last level cache (LLC), and / or combinations thereof. While in one embodiment, a ring-based interconnect unit 1512 interconnects the integrated graphics logic 1508, the set of shared cache units 1506, and the system agent unit 1510 / (multiple) integrated memory controller units 1514, alternative embodiments may use any number of well-known techniques for interconnecting such units. In one embodiment, coherency between the one or more cache units 1506 and the cores 1502-AN is maintained.
[0156] In some embodiments, one or more of the cores 1502A-N may be capable of multithreading. System agent 1510 includes those components that coordinate and operate cores 1502A-N. System agent unit 1510 may include, for example, a power control unit (PCU) and a display unit. The PCU may be or include logic and components required to regulate the power state of cores 1502A-N and integrated graphics logic 1508. The display unit is used to drive one or more externally connected displays.
[0157] The cores 1502A-N may be homogeneous or heterogeneous with respect to the architectural instruction set; that is, two or more of the cores 1502A-N may be capable of executing the same instruction set, while other cores may be capable of executing only a different instruction set or a subset of that instruction set.
[0158] Exemplary Computer Architecture
[0159] Figure 16-19 is a block diagram of an exemplary computer architecture. Other system designs and configurations known in the art of laptop computers, desktop computers, handheld PCs, personal digital assistants, engineering workstations, servers, network devices, network hubs, switches, embedded processors, digital signal processors (DSPs), graphics devices, video game devices, set-top boxes, microcontrollers, cellular phones, portable media players, handheld devices, and various other electronic devices are also suitable. In general, a wide variety of systems or electronic devices that can incorporate processors and / or other execution logic as disclosed herein are generally suitable.
[0160] Reference now Fig.16 , shown is a block diagram of a system 1600 in accordance with one embodiment of the present invention. The system 1600 may include one or more processors 1610, 1615 coupled to a controller hub 1620. In one embodiment, the controller hub 1620 includes a graphics memory controller hub (GMCH) 1690 and an input / output hub (IOH) 1650 (which may be on separate chips); the GMCH 1690 includes memory and graphics controllers to which memory 1640 and coprocessors 1645 are coupled; the IOH 1650 couples input / output (I / O) devices 1660 to the GMCH 1690. Alternatively, one or both of the memory and graphics controller are integrated within the processor (as described herein), and the memory 1640 and coprocessors 1645 are directly coupled to the processor 1610 and the controller hub 1620 in a single chip with the IOH 1650. The memory 1640 may include a blockchain acceleration module 1640A, for example, to store code that, when executed, causes the processor to perform any method of the present disclosure.
[0161] exist Fig.16 The optional nature of the additional processor 1615 is indicated by dashed lines in FIG. 16 . Each processor 1610 , 1615 may include one or more of the processing cores described herein and may be some version of processor 1500 .
[0162] The memory 1640 may be, for example, a dynamic random access memory (DRAM), a phase change memory (PCM), or a combination of the two. For at least one embodiment, the controller hub 1620 communicates with the processor(s) 1610, 1615 via a multi-drop bus such as a front side bus (FSB), a point-to-point interface such as a Quick Path Interconnect (QPI), or similar connection 1695.
[0163] In one embodiment, coprocessor 1645 is a special purpose processor such as, for example, a high throughput MIC processor, a network or communication processor, a compression engine, a graphics processor, a GPGPU, an embedded processor, etc. In one embodiment, controller hub 1620 may include an integrated graphics accelerator.
[0164] There may be a variety of differences between the physical resources 1610, 1615 in terms of the range of measurements of indicators including architectural, microarchitectural, thermal, power consumption characteristics, etc.
[0165] In one embodiment, processor 1610 executes instructions that control general types of data processing operations. Embedded within the instructions may be coprocessor instructions. Processor 1610 recognizes these coprocessor instructions as being of a type that should be executed by an attached coprocessor 1645. Accordingly, processor 1610 issues these coprocessor instructions (or control signals representing coprocessor instructions) to coprocessor 1645 on a coprocessor bus or other interconnect. Coprocessor(s) 1645 accept and execute the received coprocessor instructions.
[0166] Reference now Fig.17 , shown is a block diagram of a first more specific exemplary system 1700 according to an embodiment of the present disclosure. Fig.17 As shown in , multiprocessor system 1700 is a point-to-point interconnect system and includes a first processor 1770 and a second processor 1780 coupled via a point-to-point interconnect 1750. Each of processors 1770 and 1780 may be a version of processor 1500. In one embodiment of the present disclosure, processors 1770 and 1780 are processors 1610 and 1615, respectively, and coprocessor 1738 is coprocessor 1645. In another embodiment, processors 1770 and 1780 are processors 1610 and coprocessor 1645, respectively.
[0167] Processors 1770 and 1780 are shown to include integrated memory controller (IMC) units 1772 and 1782, respectively. Processor 1770 also includes point-to-point (PP) interfaces 1776 and 1778 as part of its bus controller unit; similarly, second processor 1780 includes PP interfaces 1786 and 1788. Processors 1770, 1780 can exchange information via point-to-point (PP) interface 1750 using PP interface circuits 1778, 1788. Fig.17 As shown in FIG. 1 , IMCs 1772 and 1782 couple the processors to respective memories, namely, memory 1732 and memory 1734 , which may be portions of main memory locally attached to the respective processors.
[0168] Processors 1770, 1780 may each exchange information with chipset 1790 via separate PP interfaces 1752, 1754 using point-to-point interface circuits 1776, 1794, 1786, 1798. Chipset 1790 may optionally exchange information with coprocessor 1738 via high performance interface 1792. In one embodiment, coprocessor 1738 is a special purpose processor such as, for example, a high throughput MIC processor, a network or communication processor, a compression engine, a graphics processor, a GPGPU, an embedded processor, etc.
[0169] A shared cache (not shown) may be included in either processor or external to both processors, also connected to the processors via the PP interconnect so that if the processors are placed in a low power mode, local cache information of either or both processors may be stored in the shared cache.
[0170] Chipset 1790 may be coupled to first bus 1716 via interface 1796. In one embodiment, first bus 1716 may be a peripheral component interconnect (PCI) bus or a bus such as a PCI Express bus or another third generation I / O interconnect bus, but the scope of the present disclosure is not so limited.
[0171] like Fig.17As shown in , various I / O devices 1714 may be coupled to the first bus 1716 along with a bus bridge 1718 which couples the first bus 1716 to a second bus 1720. In one embodiment, one or more additional processors 1715 such as a coprocessor, a high throughput MIC processor, a GPGPU, an accelerator (such as, for example, a graphics accelerator or a digital signal processing (DSP) unit), a field programmable gate array, or any other processor are coupled to the first bus 1716. In one embodiment, the second bus 1720 may be a low pin count (LPC) bus. In one embodiment, various devices may be coupled to the second bus 1720 including, for example, a keyboard and / or mouse 1722, communication devices 1727, and a storage unit 1728 such as a disk drive or other mass storage device, which may include instructions / code and data 1730. Further, an audio I / O 1724 may be coupled to the second bus 1720. Note that other architectures are possible. For example, instead of Fig.17 Instead of a point-to-point architecture, the system may implement a multi-point bus or other such architecture.
[0172] Reference now Fig.18 , shown is a block diagram of a second more specific exemplary system 1800 according to an embodiment of the present disclosure. Fig.17 and 18 The same elements in the same manner have the same reference numerals and have been changed from Fig.18 Omit Fig.17 to avoid ambiguity Fig.18 other aspects.
[0173] Fig.18 It is illustrated that processors 1770, 1780 may include integrated memory and I / O control logic ("CL") 1772 and 1782, respectively. Thus, CL 1772, 1782 includes an integrated memory controller unit and includes I / O control logic. Fig.18 It is illustrated that not only the memories 1732, 1734 are coupled to the CLs 1772, 1782, but also the I / O devices 1814 are coupled to the control logic 1772, 1782. The legacy I / O devices 1815 are coupled to the chipset 1790.
[0174] Reference now Fig.19 , shown is a block diagram of a SoC 1900 according to an embodiment of the present invention. Fig.15 Similar components in FIG. 1 have the same reference numbers. Also, dashed boxes are optional features on more advanced SoCs. Fig.19, interconnect unit(s) 1902 are coupled to: application processor 1910, which includes a set of one or more cores 202A-N and a shared cache unit(s) 1506; system agent unit 1510; bus controller unit(s) 1519; integrated memory controller unit(s) 1517; a set of one or more coprocessors 1920, which may include integrated graphics logic, image processors, audio processors, and video processors; static random access memory (SRAM) unit 1930; direct memory access (DMA) unit 1932; and display unit 1940 for coupling to one or more external displays. In one embodiment, coprocessor(s) 1920 include special purpose processors such as, for example, network or communication processors, compression engines, GPGPUs, high throughput MIC processors, embedded processors, etc.
[0175] The embodiments (e.g., mechanisms) disclosed herein may be implemented in hardware, software, firmware, or a combination of such implementation methods. The embodiments of the present disclosure may be implemented as program codes or computer programs executed on a programmable system, the programmable system comprising at least one processor, a storage system (including volatile and non-volatile memory and / or storage elements), at least one input device, and at least one output device.
[0176] Such as Fig.17 Program code, such as code 1730 illustrated in FIG. 1 , is applied to input instructions to perform the functions described herein and generate output information. The output information may be applied to one or more output devices in a known manner. For purposes of this application, a processing system includes any system having a processor, such as, for example, a digital signal processor (DSP), a microcontroller, an application specific integrated circuit (ASIC), or a microprocessor.
[0177] The program code can be implemented in a high-level process or object-oriented programming language to communicate with the processing system. If desired, the program code can also be implemented in assembly or machine language. In fact, the mechanism described herein is not limited to any specific programming language in scope. In any case, the language can be a compiled or interpreted language.
[0178] One or more aspects of at least one embodiment may be implemented by representative instructions stored on a machine-readable medium, which represent various logic within a processor, which when read by a machine causes the machine to make logic to perform the techniques described herein. Such representations (referred to as "IP cores") may be stored on a tangible machine-readable medium and supplied to various customers or manufacturing facilities to be loaded into a manufacturing machine that actually makes the logic or processor.
[0179] Such machine-readable storage media may include, without limitation, a non-transitory tangible arrangement of an article manufactured or formed by a machine or device, including storage media such as a hard disk, any other type of disk including a floppy disk, an optical disk, a compact disk-read only memory (CD-ROM), a compact disk-rewritable (CD-RW), and a magneto-optical disk; a semiconductor device such as a read-only memory (ROM), a random access memory (RAM) such as a dynamic random access memory (DRAM), a static random access memory (SRAM), an erasable programmable read-only memory (EPROM), a flash memory, an electrically erasable programmable read-only memory (EEPROM), a phase change memory (PCM); a magnetic card or an optical card; or any other type of medium suitable for storing electronic instructions.
[0180] Accordingly, embodiments of the present disclosure also include non-transitory tangible machine-readable media containing instructions or containing design data, such as hardware description languages (HDL), which define the structures, circuits, devices, processors and / or system features described herein. Such embodiments may also be referred to as program products.
[0181] Simulation (including binary translation, code deformation, etc.)
[0182] In some cases, an instruction converter may be used to convert instructions from a source instruction set to a target instruction set. For example, the instruction converter may translate (e.g., using static binary translation, dynamic binary translation including dynamic compilation), deform, emulate, or otherwise convert instructions to one or more other instructions to be processed by the core. The instruction converter may be implemented in software, hardware, firmware, or a combination thereof. The instruction converter may be on the processor, off the processor, or partially on the processor and partially off the processor.
[0183] Fig. 20 1 is a block diagram of the use of a software instruction converter according to an embodiment of the present disclosure, wherein the software instruction converter is used to convert binary instructions in a source instruction set into binary instructions in a target instruction set. In the illustrated embodiment, the instruction converter is a software instruction converter, but the instruction converter may alternatively be implemented in software, hardware, firmware, or various combinations thereof. Fig. 20It is shown that an x86 compiler 2004 can be used to compile a program in a high-level language 2002 to generate x86 binary code 2006 that can be natively executed by a processor 2016 having at least one x86 instruction set core. A processor 2016 having at least one x86 instruction set core represents any processor that can perform substantially the same functions as an Intel processor having at least one x86 instruction set core by compatibly executing or otherwise processing (1) a substantial portion of the instruction set of an Intel x86 instruction set core, or (2) an object code version of an application or other software that is intended to run on an Intel processor having at least one x86 instruction set core. The x86 compiler 2004 represents a compiler that is operable to generate x86 binary code 2006 (e.g., object code) that can be executed on a processor 2016 having at least one x86 instruction set core with or without additional join processing. Similarly, Fig. 20 It is shown that a program in a high-level language 2002 can be compiled using an alternative instruction set compiler 2008 to generate an alternative instruction set binary code 2010 that can be natively executed by a processor 2014 that does not have at least one x86 instruction set core (e.g., a processor that has a core that executes the MIPS instruction set of MIPS Technologies of Sunnyvale, California and / or executes the ARM instruction set of ARM Holdings of Sunnyvale, California). The x86 binary code 2006 is converted into code that can be natively executed by a processor 2014 that does not have an x86 instruction set core using an instruction converter 2012. The converted code is unlikely to be the same as the alternative instruction set binary code 2010 because an instruction converter with this capability is difficult to make; however, the converted code will perform general operations and consist of instructions from the alternative instruction set. Therefore, the instruction converter 2012 represents software, firmware, hardware, or a combination thereof that allows a processor or other electronic device that does not have an x86 instruction set processor or core to execute the x86 binary code 2006 through simulation, emulation, or any other process.
Claims
1. A device for accelerating blockchain transactions, comprising: The core, which executes threads and offloads blockchain transaction operations; transaction processing circuitry of the hardware accelerator to perform offloaded operations of blockchain transactions; Block processing circuitry of a hardware accelerator to perform offloaded operations of blockchain transactions; as well as A dispatcher circuit of a hardware accelerator, which is to route the offloaded operation to a controller of a transaction processing circuit of the hardware accelerator when the offloaded operation is a transaction operation and to route the offloaded operation to a controller of a block processing circuit of the hardware accelerator when the offloaded operation is a block operation, wherein the controller of the transaction processing circuit is used to determine a computing circuit block to be used among a plurality of different types of computing blocks of the transaction processing circuit and send the transaction operation to the computing circuit block if available, and send the transaction operation to the core if not available, and the controller of the block processing circuit is used to determine a computing circuit block to be used among a plurality of different types of computing blocks of the block processing circuit and send the block operation to the computing circuit block if available, and send the block operation to the core if not available.
2. The apparatus of claim 1, wherein the dispatcher circuit is to perform initial processing for the offloaded operations before routing the offloaded operations, and the initial processing includes a digital signature operation.
3. The apparatus of any of claims 1-2, wherein the dispatcher circuit is to route the offloaded operation to the peer processing circuit when the offloaded operation is a peer operation.
4. The apparatus of claim 3, wherein the peer operation is a request to a peer for missing transactions of a block.
5. The apparatus of claim 3, wherein the peer operation is to cause the peer processing circuit to send missing transactions of the block to the peer.
6. The apparatus of claim 3, wherein the transaction processing circuitry includes a dependency checker to check transactions of a transaction operation for dependent transactions and to cause the peer processing circuitry to retrieve any missing dependent transactions.
7. A method for accelerating blockchain transactions, comprising: offloading operations from hardware processors to hardware accelerators; a controller for routing the operation to the transaction processing circuitry of the hardware accelerator using the dispatcher circuitry when the operation is a transaction operation; a controller that utilizes a dispatcher circuit to route the operation to a block processing circuit of the hardware accelerator when the operation is a block operation; determining, by the controller of the transaction processing circuit, a computing circuit block to be used from among a plurality of different types of computing blocks of the transaction processing circuit; If available, sending the transaction operation to the computing circuit block of the transaction processing circuit; if not available, sending the transaction operation to the hardware processor; determining, by the controller of the block processing circuit, a computational circuit block to be used from among a plurality of different types of computational blocks of the block processing circuit; If available, sending the block operation to the computational circuit block of the block processing circuit, and if not available, sending the block operation to the hardware processor; executing the routed operation using a computational circuit block of a transaction processing circuit of a hardware accelerator when the operation is a transaction operation and the computational circuit block of the transaction processing circuit is available; as well as The routed operation is performed using a computational circuit block of a block processing circuit of a hardware accelerator when the operation is a block operation and the computational circuit block of the block processing circuit is available.
8. The method of claim 7, further comprising performing initial processing for the operation using the dispatcher circuit prior to routing the operation, wherein the initial processing includes a digital signature operation.
9. The method according to any one of claims 7-8 further includes using a dispatcher circuit to route the operation to the peer processing circuit of the hardware accelerator when the operation is a peer operation; and using the peer processing circuit of the hardware accelerator to execute the routed operation when the operation is a peer operation.
10. The method of claim 9, wherein the peer operation comprises requesting missing transactions of a block from a peer.
11. The method of claim 9, wherein the peer operation comprises sending missing transactions of the block to the peer.
12. The method of claim 9, further comprising checking transactions of the transaction operation for dependent transactions using a dependency checker of the transaction processing circuitry, and the dependency checker causes the peer processing circuitry to retrieve any missing dependent transactions.
13. A device for accelerating blockchain transactions, comprising: The transaction processing circuit of the hardware accelerator is to perform the operations of the blockchain transaction; The hardware accelerator’s block processing circuitry is required to perform operations on blockchain transactions; as well as A network interface controller, comprising a dispatcher circuit, the dispatcher circuit being configured to route an operation to a controller of a transaction processing circuit of a hardware accelerator when the operation is a transaction operation and to route the operation to a controller of a block processing circuit of the hardware accelerator when the operation is a block operation, wherein the controller of the transaction processing circuit is configured to determine a computing circuit block to be used from among a plurality of different types of computing blocks of the transaction processing circuit and send the transaction operation to the computing circuit block if available, or send the transaction operation from the transaction processing circuit if unavailable, and the controller of the block processing circuit is configured to determine a computing circuit block to be used from among a plurality of different types of computing blocks of the block processing circuit and send the block operation to the computing circuit block if available, or send the block operation from the block processing circuit if unavailable.
14. The apparatus of claim 13, wherein the dispatcher circuit is to perform initial processing for the operation prior to routing the operation, and the initial processing includes a digital signature operation.
15. An apparatus according to any of claims 13-14, wherein the dispatcher circuit is to route the operation to the peer processing circuit when the operation is a peer operation.
16. The apparatus of claim 15, wherein the peer operation is a request to a peer for missing transactions of a block.
17. The apparatus of claim 15, wherein the peer operation is to cause the peer processing circuit to send missing transactions of the block to the peer.
18. The apparatus of claim 15, wherein the transaction processing circuitry includes a dependency checker to check transactions of a transaction operation for dependent transactions and to cause the peer processing circuitry to retrieve any missing dependent transactions.
19. A method for accelerating blockchain transactions, comprising: receiving, using the network interface controller, an operation for the hardware accelerator; a controller that utilizes the dispatcher circuitry of the network interface controller to route the operation to the transaction processing circuitry of the hardware accelerator when the operation is a transaction operation; a controller that utilizes a dispatcher circuit of the network interface controller to route the operation to the block processing circuit of the hardware accelerator when the operation is a block operation; determining, by the controller of the transaction processing circuit, a computing circuit block to be used from among a plurality of different types of computing blocks of the transaction processing circuit; If available, sending the transaction operation to the computing circuit block of the transaction processing circuit, and if not available, sending the transaction operation from the transaction processing circuit; determining, by the controller of the block processing circuit, a computational circuit block to be used from among a plurality of different types of computational blocks of the block processing circuit; If available, sending the block operation to the computational circuit block of the block processing circuit, and if not available, sending the block operation from the block processing circuit; executing the routed operation using a computational circuit block of a transaction processing circuit of a hardware accelerator when the operation is a transaction operation and the computational circuit block of the transaction processing circuit is available; as well as The routed operation is performed using a computational circuit block of a block processing circuit of a hardware accelerator when the operation is a block operation and the computational circuit block of the block processing circuit is available.
20. The method of claim 19, further comprising performing, using the dispatcher circuit, initial processing for the operation prior to routing the operation, wherein the initial processing includes digitally signing the operation.
21. The method according to any one of claims 19-20 further includes using a dispatcher circuit to route the operation to the peer processing circuit of the hardware accelerator when the operation is a peer operation; and using the peer processing circuit of the hardware accelerator to perform the routed operation when the operation is a peer operation.
22. The method of claim 21, wherein the peer operation comprises utilizing a network interface controller to request missing transactions of a block from a peer.
23. The method of claim 21, wherein the peer operation comprises sending missing transactions of the block to the peer using a network interface controller.
24. The method of claim 21 further comprising checking transactions of the transaction operation for dependent transactions using a dependency checker of the transaction processing circuitry, and the dependency checker causes the peer processing circuitry to retrieve any missing dependent transactions.
25. A computer-readable storage medium having stored thereon instructions which, when executed by a processor, cause the processor to perform the method according to any one of claims 7-12.
26. A computer-readable storage medium having stored thereon instructions which, when executed by a processor, cause the processor to perform the method according to any one of claims 19-24.
27. A computer program product comprising a computer program which, when executed by a processor, causes the processor to perform the method according to any one of claims 7 to 12.
28. A computer program product comprising a computer program which, when executed by a processor, causes the processor to perform the method according to any one of claims 19 to 24.
