In-memory computing architecture and method for performing MAC operations - Patents.com

The analog IMC architecture with dual charge storage banks and multilevel non-volatile memory devices addresses power efficiency issues in MAC operations, enhancing computational throughput for AI applications.

JP7542638B2Active Publication Date: 2024-08-30INFINEON TECHNOLOGIES LLC
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
JP2022552684
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2020-06-22
Filing Date
2021-02-26
Publication Date
2024-08-30
Estimated Expiration
2041-02-26

AI Technical Summary

Technical Problem

Current in-memory computing (IMC) technologies for artificial intelligence applications face power efficiency issues due to latency and high power overhead in converting digital data to analog representations for multiply-accumulate (MAC) operations, particularly in neural network architectures.

Method used

An analog IMC architecture with a MAC core using multilevel non-volatile memory devices and dual charge storage banks, coupled with analog-to-digital converters, enables high-speed conversion of digital data to analog without additional power consumption, reducing latency and improving efficiency.

Benefits of technology

The proposed architecture significantly enhances power efficiency and computational throughput by minimizing latency and power overhead in MAC operations, making it suitable for AI applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007542638000007
    Figure 0007542638000007
  • Figure 0007542638000008
    Figure 0007542638000008
  • Figure 0007542638000006
    Figure 0007542638000006
Patent Text Reader

Abstract

An in-memory computing architecture and method for performing multiply-and-accumulate operations are provided. The method includes sequentially shifting bits of a first input byte into each row of an array of memory cells arranged in rows and columns. Each memory cell is activated based on the bit, and a bit line current from each activated memory cell is formed on a column of shared bit lines, the bit line current being proportional to the product of the bit and a weight stored therein. Charge formed by the sum of the bit line currents of a column is accumulated in a first charge storage bank coupled to each shared bit line of the column. Simultaneously, charge from a second input byte, previously accumulated in a second charge storage bank coupled to the column, is sequentially converted into an output byte. Each charge storage bank is swapped after the first input byte is accumulated and the charge from the second input byte is converted. The method is then repeated.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS This application is an international application of U.S. Nonprovisional Application No. 16 / 908,210, filed June 22, 2020, which claims the benefit of priority under 35 U.S.C. §119(e) to U.S. Provisional Application No. 62 / 983,866, filed March 2, 2020, the entire contents of which are incorporated herein by reference.

[0002] Technical Field The present disclosure relates generally to in-memory computing (IMC), and more specifically to an IMC architecture and a method of operating the IMC architecture to perform multiply-accumulate (MAC) operations. [Background technology]

[0003] In-memory computing (IMC) or in-memory processing is a developing technique for performing calculations on data in memory, rather than fetching data from memory and performing the calculations in separate computational elements in a processor. The Von Neumann computational architecture approach to artificial intelligence (AI) requires continuous external memory access to fetch accumulated weights and data used in neural networks and to store intermediate results in computational elements. The data movement between said external memory and the processing structure limits the system power efficiency. In IMC, data stored in memory is not transferred to and from processing elements outside of the memory, greatly improving data processing speed and power efficiency of computation. IMC has proven to be particularly useful for high-speed neural network architectures for power-sensitive AI applications.

[0004] Current IMC technologies primarily use digital implementations, which offer some improvements in data processing speed but can suffer from significant power efficiency issues. In particular, IMC implementations used in AI applications lose power efficiency due to the latency associated with converting the input digital byte stream to an analog equivalent representation before accessing the memory rows for analog multiplication and accumulation (MAC) operations. Previous attempts to provide analog IMC solutions rely on digital-to-analog converters (DACs) that convert the input data byte stream to analog for each row in a memory array or matrix, and the DAC outputs are used to drive memory cells that store the weights of the data matrix. Thus, current analog IMC implementations have a large power overhead due to the DACs used to convert the input data byte stream to analog and due to the latency incurred in generating the output analog voltages from the input data byte stream.

[0005] Therefore, what is needed is an analog IMC architecture and method of operation for performing multiply-accumulate (MAC) operations that can provide fast, power-efficient analog conversion of an input digital byte stream. Summary of the Invention [Means for solving the problem]

[0006] An in-memory computing (IMC) architecture and method for performing multiply-accumulate (MAC) operations are provided. The IMC architecture for performing MAC operations and the method for operating the IMC architecture are particularly useful when used within or in conjunction with hardware accelerators, such as those used in artificial intelligence (AI) devices.

[0007] The IMC architecture includes a MAC core including an array of memory cells arranged in rows and columns, each memory cell including a multilevel non-volatile memory (NVM) device, and each column including a shared bit line connecting the NVM devices in the column. A plurality of registers, each coupled to one row of the array, are configured to sequentially shift a bit of a first input byte into the row, activate an NVM device based on a state of the bit, and form a weighted bit line current from each activated NVM device in proportion to a product of the bit and a weight stored therein. A plurality of first charge storage banks are each coupled to the shared bit line of one of the plurality of columns, and are configured to receive a sum of the weighted bit line currents and accumulate a charge formed by the sum of the weighted bit line currents for each bit of the input byte. The MAC core further includes a plurality of second charge storage banks coupled to a plurality of analog-to-digital converters (ADCs), each of the second charge storage banks configured to, simultaneously with the shifting and accumulating, provide a scaled voltage for each bit of a previously received second input byte to the ADC for conversion into an output byte. A controller coupled to the plurality of first charge storage banks and the second charge storage bank is configured such that the first charge storage bank is switched or swapped with the second charge storage bank after each bit of the plurality of first input bytes is accumulated in the first charge storage bank and the charge in the second charge storage bank is converted.

[0008] A method of performing a MAC operation using the above architecture includes coupling each of a plurality of first input bytes stored in the register to one of a plurality of rows in the array, sequentially shifting the bits of the first input byte to each memory cell of each row, and activating each memory cell based on the state of the bit to multiply each bit by a weight stored in each memory cell to form a weighted bitline current from each activated memory cell proportional to the product of the bit and the weight stored therein. The charge formed by the sum of the weighted bitline currents from each activated memory cell in the column is accumulated in a first charge storage bank, each coupled to a shared bitline in one of the columns. In general, the method includes converting the charge formed by the sum of the weighted bitline currents from the plurality of second input bytes, which have been shifted, multiplied and accumulated in the first charge storage bank and accumulated previously in the second charge storage bank, to an output byte using a plurality of ADCs, and accumulating each bit of the first input byte to convert the charge in the second charge storage bank before swapping the first and second charge storage banks.

[0009] Further features and advantages of the embodiments of the invention, as well as the structure and operation of various embodiments of the invention, are described in detail with reference to the accompanying drawings. It should be noted that the invention is not limited to the specific embodiments described herein. These embodiments are presented herein for illustrative purposes only. Additional embodiments will be apparent to those skilled in the art based on the teachings contained herein.

[0010] Embodiments of the invention will now be described, by way of example only, with reference to the accompanying schematic drawings in which corresponding reference characters indicate corresponding parts and in which: FIG. 1 illustrates an embodiment of the invention, and together with the description, serve to explain basic schemes of the invention and enable one skilled in the art to make and use the invention. [Brief description of the drawings]

[0011] [Figure 1A] FIG. 1 is a schematic block diagram of one embodiment of an analog multiplication and accumulation (MAC) core including a memory array, multiple charge storage banks, and an analog-to-digital converter (ADC) to reduce latency and improve efficiency in performing MAC operations. [Figure 1B] FIG. 1 is a schematic block diagram of another embodiment of a MAC core in which each memory cell in a memory array includes two non-volatile memory (NVM) cells, and each NVM cell includes one or more NVM devices. [Diagram 2] FIG. 1 is a block diagram illustrating a cross-sectional side view of a SONOS NVM transistor. [Diagram 3] 1C is a flowchart of a method for performing a MAC operation using the MAC core of FIG. 1A or FIG. 1B. [Figure 4A] FIG. 1C is a schematic block diagram of an embodiment of a charge storage bank for use in the MAC core of FIGS. 1A and 1B configured to sample currents in columns obtained as the first bit of an input data byte is shifted into each row and store the resulting charge in charge storage elements in the charge storage bank. [Figure 4B] FIG. 4B is a schematic block diagram of the charge storage bank of FIG. 4A configured to sample the current in the column resulting from a second bit of the input data byte and store the resulting charge in a second charge storage element of the charge storage bank. [Figure 4C] FIG. 4B is a schematic block diagram of the charge storage bank of FIG. 4A configured to hold the charge resulting from all bits of an input data byte and to provide an equivalent voltage at node N required to scale the voltage associated with each input bit. [Figure 4D] FIG. 4B is a schematic block diagram of the charge storage bank of FIG. 4A configured to convert the charge resulting from a MAC operation on all bits of the input data byte into an output data byte a using a successive approximation register analog-to-digital converter (SAR ADC). [Diagram 5]1 is a flowchart of a method of operating a single charge storage bank coupled to a single bit line to accumulate current resulting from shifting an input data byte into each row, perform a MAC operation on all bits of the input data byte, and convert the charge resulting from the MAC operation on all bits of the input data byte into an output data byte. [Figure 6] FIG. 1 is a schematic block diagram of one embodiment of an artificial intelligence (AI) system with a hardware accelerator including multiple neural engines with MAC cores operating in accordance with the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0012] An in-memory computing (IMC) architecture and method of operation therewith for performing multiplication and accumulation operations quickly and efficiently is provided. The disclosed IMC architecture and method are particularly useful when used within or with hardware accelerators that include multiple neural engine cores, such as those used in artificial intelligence (AI) devices.

[0013] In the following description, for purposes of explanation, numerous specific details are set forth in order to provide a thorough understanding of the present invention. However, it will be apparent to those skilled in the art that the present invention may be practiced without these specific details. In other instances, well-known structures and techniques have not been shown in detail or have been shown in block diagram form in order to avoid unnecessarily obscuring an understanding of this specification.

[0014] As used herein, "one embodiment" or "an embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment is included in at least one embodiment of the invention. The appearances of the phrase "in one embodiment" in various places in this specification do not necessarily all refer to the same embodiment. As used herein, the term "connect" can include both direct electrical connection of two or more elements or components, and indirect connection via one or more intervening elements.

[0015] 1A and 1B are schematic block diagrams illustrating an embodiment of an analog multiply-accumulate (MAC) engine or core 100 suitable for use in a hardware accelerator in an artificial intelligence (AI) device or system to reduce latency and improve efficiency in performing MAC operations.

[0016] 1A, in one embodiment, the MAC core 100 includes a memory array or array 102 of memory units or cells 104 arranged as a number (m) of rows and a number (n) of columns, each having a programmed value or weight stored therein (depicted in FIG. 1A by ellipses W00, W01, W10, ..., etc.), where each memory cell in a column is coupled to a shared bit line 106 and each memory cell in a row is coupled to a shared word line 108. In the illustrated embodiment, the memory array 102 is a 4 by 8 array having 4 rows and 8 columns, although it will be understood that the array may alternatively have any number of rows and columns, including embodiments having fewer rows or columns than those shown. The MAC core 100 further includes a number of registers 110 capable of storing multi-bit input data words or bytes, typically at least one register for each row of the memory array 102. Each register 110 is coupled to one row of the memory array 102 via a shared word line, sequentially shifts the bits of a first input data byte, i.e., D0-D7 in the illustrated embodiment, into the row in response to a clock signal, activates memory cells 104 in the row based on the state of the shifted bits, and forms a weighted bit line current on the shared bit line of the column from each activated memory cell in the column that is proportional to the product of the bit and a weight stored therein.

[0017] The MAC core 100 further includes a plurality of accumulators 112 each connected to the shared bit line of one of the columns, the plurality of accumulators 112 each switchably connected to the shared bit line 106 and including a first charge storage bank 114a configured to receive a sum of weighted bit line currents from activated memory cells 104 in the column and accumulate a scaled charge formed by the sum of the weighted bit line currents for each bit of the first input data byte. Each of the accumulators 112 further includes a second charge storage bank 114b coupled to a plurality of analog-to-digital converters (ADCs 116), each configured to shift bits to each row and accumulate the scaled charge in the first charge storage bank 114a in response to a clock signal while providing the accumulated voltage for each bit line of the previously received second input data byte to the ADCs 116 for conversion into digital bits of an output byte that are accumulated in a multi-bit output register 118. In one exemplary embodiment, the operation is timed such that the time to shift one bit into the first charge storage bank is substantially equal to the time to convert one bit line of a previously received second input data byte.

[0018] The MAC core 100 further includes a controller 120 coupled to the first charge storage bank 114a and the second charge storage bank 114b, and in each of the accumulators 112, the controller is configured to switch or swap the first charge storage bank 114a with the second charge storage bank 114b after all bits of the first input data bytes are accumulated in the first charge storage bank and the charge of the second charge storage bank is converted. Switching or swapping means that the first charge storage bank 114a in each accumulator 112 coupled to the shared bit lines 106 in a column of the memory array 102 is disconnected from the shared bit lines or memory array and coupled to the multiple ADCs 116 for charge-to-voltage conversion, while the second charge storage bank 114b is substantially simultaneously disconnected from the multiple ADCs and coupled to the shared bit lines in the memory array 102 for charge accumulation. In some illustrated embodiments, controller 120 is included in MAC core 100 and may be fabricated integrally on a common or shared substrate with other elements of the MAC core, or packaged in a shared integrated circuit package, or mounted on a common or shared circuit substrate with other elements of the MAC core. Alternatively, controller 120 may be a controller in one of ADCs 116, or a microcontrol unit (MCU), or a processor in a hardware accelerator that includes MAC core 100, or a processor in a system in which a hardware accelerator is used.

[0019] In general, the multiple ADCs 116 in the MAC core 100 are selected such that during the time bits of the first input data byte are shifted into each row of the memory array 102, the ADC completes the conversion of all the charge stored in each of the second charge storage banks 114b and accumulates the scaled charge per bit in the first charge storage bank 114a. It should be noted that the conversion of the accumulated charge stored in the multiple second charge storage banks 114b begins at substantially the same first clock cycle as the shifting of the bits of the input data byte and the accumulation of the scaled charge in the first charge storage bank 114a occurs, but the time or number of clock cycles required to read the shared bit line 106 need not be the same as the conversion of the total charge stored in each of the second charge storage banks 114b. If the time required to read one bit line current is equal to the ADC conversion time, then 8 bits of scaled current per shared bit line 106 are accumulated in the first charge storage bank 114a while a single 8-bit ADC 116 is sufficient to convert the charge from the previous input data byte accumulated in the second charge storage bank 114b, and the number of ADCs 116 is equal to or greater than n / b rounded to the nearest integer, where n is the column in the memory array 102 and b is the number of bits in the input data byte. Note that if more time is required to shift and accumulate the scaled charge for each bit read in the first charge storage bank 114a, for example if the charge accumulation time per shared bit line is twice the amount of time or clock cycles required for ADC conversion, then one ADC can be time multiplexed to convert on twice the number of bit lines 106 or columns, thus halving the number of ADCs 116, thereby reducing the ADC area while still maintaining efficient utilization and 100% throughput of the ADC.

[0020] Here, the number of clock cycles required to shift and accumulate the input data bytes is several (x) times greater than the number of clock cycles to convert the voltage, and the MAC core 100 includes a clock buffer 122 that increases the frequency of the clock signal provided to the first charge storage bank 114a and the second charge storage bank 114b, and multiple ADCs 116, as shown.

[0021] Generally, as in the embodiment shown in FIG. 1A, each memory cell 104 in the memory array 102 includes a multi-level non-volatile memory (NVM) device or transistor with a weight (analogous, corresponding to the multiple value levels that can be stored in an NVM cell) stored in each memory cell. In another embodiment shown in FIG. 1B, each memory unit 104 in the memory array 102 can have two NVM devices or NVM transistors, including a first NVM cell coupled to a first bit line 106a represented by sub-column P and a second NVM cell coupled to a second bit line 106b represented by sub-column N. In that embodiment, programming a value or weight into each memory cell 104 in the memory array 102 includes programming the first NVM device of sub-column P and the second NVM cell of sub-column N with different values ​​or weights stored in the first and second NVM devices having opposite polarities N and P, respectively. Also, in this embodiment, as shown in FIG. 1B, the plurality of ADCs 116 may include a differential ADC having a differential input coupled to the first bit line 106a and the second bit line 106b.

[0022] In any embodiment, the multi-level NVM device may include multi-level silicon-oxide-nitride-oxide-silicon (SONOS) NVM transistors that include one or more nitride or oxynitride charge trapping layers, and a threshold voltage (V) to be applied to a word line coupled to the gate of the ONO type NVM transistor. TH) to store or trap multiple charge levels to shift the charge level of the memory cell 104, turning on the transistor to program or store a programming value or weight in the memory cell 104. FIG. 2 is a block diagram illustrating a cross-sectional side view of a SONOS NVM transistor. Referring to FIG. 2, the SONOS NVM transistor 200 includes a gate stack 202 formed over a substrate 204. The NVM transistor 200 further includes source / drain regions 206 / 208 formed in a well 210 in the substrate 204 on either side of the gate stack 202, a channel region 212 below the gate stack, and a body bias terminal 214, also referred to as a well terminal or bulk terminal, for forming an ohmic contact with the well 210. The source region 206, drain region 208, channel region 212, and body bias terminal 214 are formed by implanting the appropriate type of dopant by ion implantation or diffusion into the well 210, depending on whether the NVM transistor is p-type or n-type. The well 210 can also be formed by ion implantation or diffusion. The source region 206 , the drain region 208 and the body bias terminal 214 may further include a thin layer of silicide, not shown, to form ohmic contacts with regions in the substrate 204 .

[0023] The gate stack 202 includes an oxide tunnel dielectric layer 216, one or more nitride or oxynitride charge trapping layers 218, a top blocking oxide layer 220, and a layer of polysilicon (poly), silicided polysilicon or metal that functions as a control gate 222.

[0024] With the control gate 222, source region 206, drain region 208 and body bias terminal 214 properly biased, electrons from the source / drain / channel region are injected or tunneled through the tunnel dielectric layer 216 and trapped in the charge trapping layer 218. The mechanism by which the charge is injected can include both Fowler-Nordheim (FN) tunneling and hot carrier injection. The charge trapped in the charge trapping layer 218 creates an energy barrier between the drain and source, increasing the threshold voltage V required to turn off the NVM transistor 200. T , placing the transistor in a "programmed" state. NVM transistor 200 can then be "erased," or the trapped charges can be removed and replaced with holes by applying a reverse bias to control gate 222. Source region 206, drain region 208, and body bias terminal 214 are connected to a multi-level threshold voltage (V TH ) or by varying the cell current (partially programming or partially erasing NVM transistor 200) such that the stored weight value is represented in analog.

[0025] Multi-level SONOS-type NVM transistors are described, for example, in commonly assigned, co-pending U.S. patent application Ser. No. 16 / 827,948, filed Mar. 24, 2020, the disclosure of which is incorporated by reference in its entirety into this specification.

[0026] In operation of the MAC core 100 shown in FIG. 1A or 1B, the input data bytes stored in the register 110 are shifted bit by bit into the memory array 102 starting from the most significant bit (MSB). Each row of the memory array 102 is provided with a different or identical input data byte. These input data bytes can represent, for example, input image pixels or activations in a real convolutional neural network (CNN) application. If the shifted bit is 1, the corresponding memory cell 104 in the row is turned on or selected for a read operation to provide a cell current equivalent to or representative of the programming value of the corresponding memory cell, and if the bit is 0, the memory cell is not turned on or selected for a read operation and no current is passed through the associated shared bit line 106. When multiple rows of memory cells 104 in a column are activated simultaneously as described above, the shared bit line 106 associated with the column carries the sum of the cell currents from the memory cells in the same column. The bitline current accumulated in the first charge storage bank 114a or the second charge storage bank 114b coupled to the shared bitline is scaled within the charge storage bank based on the weights associated with the bits of the input data byte using structures and methods described below.

[0027] Referring to FIG. 1A, consider the case where the number of rows (m) and columns (n) are both 4 to form a 4×4 memory array. The programmed values ​​or weights stored in the first row are W00, W01, W02, and W03. The weights stored in the second row are W10, W11, W12, and W13. The weights stored in the third row are W20, W21, W22, and W23, and the weights stored in the fourth row are W30, W31, W32, and W33.

[0028] Following the procedure described above, the 8-bit input data byte P0 <d7:d0>sequentially shifting the second 8-bit input data byte P1 into the first row of the array 102; <d7:d0>on the second line, the third 8-bit input data byte P2 <d7:d0>on the third line, and the fourth 8-bit input data byte P3 <d7:d0>to the fourth row, respectively. Thus, at the end of the eight clock cycles, the shared bit line 106 in the first column, in which each of the bit input data bytes has been sequentially shifted starting with the MSB of each input data byte,

number

[0029] Similarly, the second column in which each of the bit input data bytes are simultaneously shifted sequentially starting with the MSB of each input data byte is

number

[0030] The effective currents of the third column and the fourth column should also be similar, differing only in the different weights or programming values ​​for each column, i.e., weights W02, W12, W22 and W32 for the third column, and weights W03, W13, W23 and W33 for the fourth column.

[0031] By converting these bit line currents into their equivalent digital values, P0 * W00+P1 * W10+P2 * W20+P3 * W30, P0 for the second row * W01+P1 * W11+P2 * W21+P3 * W31, P0 for the third column * W02+P1 * W12+P2 * W22+P3 * W32, P0 for the 4th column * W03+P1 * W13+P2 * W23+P3 * A valid MAC value of W33 is obtained.

[0032] With reference to the flow chart of FIG. 3, a method for performing a MAC operation using a MAC core similar to that of FIG. 1A will now be described. It should be noted that although the general sequence shown on the right and left sides of this figure occurs simultaneously or nearly simultaneously, the separate discrete steps shown on the right side need not occur substantially in parallel with the steps on the left side. For example, the conversion of a first bitline charge stored in the second charge storage bank does not necessarily overlap exactly with the accumulation of the first bit in the first charge storage bank, since the conversion by the ADC coupled to the second charge storage bank can be faster or slower than the accumulation of bits on the first charge storage bank. Thus, the conversion of a first bitline charge from the second charge storage bank can be completed and the conversion of a second or next bitline charge can begin before the accumulation of charge by the most significant bit (MSB) of the first charge storage bank is completed.

[0033] In a first phase, the charge of each bit of a plurality of input data bytes of b bits (b=8 in this embodiment) is accumulated or stored in a first charge storage bank from most significant bit (MSB) to least significant bit (LSB) in b or 8 clock cycles. Referring to FIG. 3, the method starts with shifting each MSB of the input data bytes to each row of the memory array in a first clock cycle and storing the resulting MSB data in a first charge storage bank (301). By shifting each MSB of the input data bytes to each row of the memory array, each memory cell in the row is activated based on the state of the bit, i.e., the memory cell is activated when the shifted bit is "1", and the activation of each memory cell multiplies the bit with the weight stored in each memory cell by generating a weighted bit line current proportional to the product of the bit and the weight stored therein. The weighted bitline currents from each activated memory cell in each column are coupled to a shared bitline in the column forming a sum of the weighted bitline currents per column, which are then converted to a scaled charge and accumulated on charge storage elements or capacitors in a first charge storage bank, as described below with reference to Figures 4 and 5. Typically, the first and second charge storage banks include sampling or bitline capacitors in a number equal to or greater than the number of bits in the input data byte, and data or charge from each bit is accumulated on a separate one of the bitline capacitors. Each of the bitline capacitors has a different capacitance, and data obtained from each bit is accumulated on a bitline capacitor selected with respect to the importance of the bit in the input data byte. Thus, if the first bit shifted to each row is the MSB of the first input data byte coupled to that row, the charge formed by the sum of the weighted bitline currents from the MSB bit is accumulated on the bitline capacitor in the first charge storage bank with the largest capacitance.

[0034] In a second clock cycle, the next most significant bit (MSB-1) of each of the input data bytes is shifted into each row of the memory array, and the resulting MSB-1 data is stored in the first charge storage bank (302). Again, similar to shifting the MSB into the array and accumulating the resulting MSB data, each memory cell in the row is activated based on the state of the bit, and the bit is effectively multiplied with the weight stored in each memory cell to form a weighted bitline current proportional to the product of the bit and the weight stored therein, which is then converted to a charge and accumulated in the charge storage element or capacitor in the first charge storage bank having the next largest capacitance. The process continues by sequentially shifting one bit of each of the first input bytes into each row in the array on successive clock cycles, after which the least significant bit of each of the first input bytes is shifted into each row of the memory array, and the resulting LSB data is stored in the charge storage element or capacitor in the first charge storage bank having the smallest capacitance (303).

[0035] Concurrently or nearly simultaneously with the shifting of bits of the first input data byte and storing or accumulating the resulting data, the accumulated charge from the preceding second input data byte stored in a plurality of second charge storage banks is converted from an analog value to a multi-bit digital output data byte using a plurality of ADCs coupled to the second charge storage banks.

[0036] Referring back to FIG. 3, in a first conversion step following the same first clock cycle of step 301, the charge accumulated from the previously received second input data byte and stored in a second charge storage bank coupled to a first bit line of a first column of the array is converted (304). The conversion is accomplished using a plurality of ADCs, with each of the bit line capacitors in the second charge storage bank being sequentially coupled to an output node of the second charge storage bank, as described in more detail below with reference to FIGS. 4 and 5. Next, the charge accumulated from the second input data byte and stored in the second charge storage bank coupled to the second bit line of the array is converted (305). Following the conversion, the charge accumulated from the second input data byte is converted and stored in each of a plurality of second charge storage banks coupled to sequential bit lines of the array until the accumulated data from all bit lines has been converted (306). In the above example, the number of bits (b) of each input data byte being accumulated and stored in the first and second charge storage banks is 8. Thus, the last charge storage bank of the multiple second charge storage banks to which the accumulated charge is converted is the second charge storage bank coupled to bit line 8 of the eighth column of the array, and one ADC may be sufficient to perform the conversion for all eight bit lines.

[0037] Finally, in a second phase, the couplings of the charge storage banks are swapped or exchanged (307) and the ADC starts converting the charge stored in the first charge storage bank during the first phase while the second charge storage bank starts accumulating and storing charge for the next input data byte. Swapping or exchanging means that the first charge storage bank is decoupled from the memory array and coupled to the multiple ADCs, and the second charge storage bank is decoupled from the multiple ADCs and coupled to the memory array.

[0038] It should be noted that, again, the conversion of the accumulated charge stored in the second plurality of charge storage banks described in steps 304-306 begins at substantially the same first clock cycle as the shifting and accumulating of the MSB input data in step 301, but the time (number of clock cycles) required to read the memory cells described in steps 301-303 above need not be the same. In the exemplary method shown in FIG. 3, it is assumed that the charge accumulation time per bit of the input byte is substantially equal to the ADC conversion time per bit line. If the time taken to shift one bit of the input byte is equal to the ADC conversion time of one bit line, then during the time that 8 bits of scaled current are accumulated in the first charge storage bank for each bit line, a single ADC will complete the conversion of the charge from the previous input data byte stored in the second plurality of charge storage banks, each coupled to one of the 8 bit lines of the array. However, if more time is needed per bit of charge integration time, e.g., twice the time or number of clock cycles required for ADC conversion of one bit line, then one ADC can be multiplexed to perform conversions for twice the number of bit lines or columns, thereby reducing the number of ADCs by half, thereby reducing the ADC area while still maintaining efficient use of the ADCs and 100% throughput.

[0039] A charge storage bank suitable for use in a MAC core 100, such as the MAC core 100 shown in FIGS. 1A and 1B, is described below with reference to the schematic block diagram of FIG. 4A. Referring to FIG. 4A, the charge storage bank 400 generally includes a current-to-voltage (I / V) converter 402 for converting the sum of multiple bit line currents from activated memory cells in a column in the array to which the charge storage bank is coupled, such as an operational amplifier 404 including a feedback resistor 406, and multiple charge storage elements, such as sampling capacitors or bit line capacitors 408a-408e, for sampling or accumulating the charge generated or formed by the sum of the bit line currents. Typically, the number of sampling capacitors 408a-408e is equal to or greater than the number of bits (b) expected in a multi-bit input byte. Thus, in the embodiment shown in FIG. 4A, the charge storage bank 400 is particularly suitable for accumulating and converting a five bit input byte and includes five sampling capacitors 408a-408e. The charge storage bank 400 also includes a dummy capacitor (C dummy 410) into which any charge stored on the sampling capacitors 408a-408e may be redistributed to derive or form a voltage for scaling the voltage of the charge stored on each sampling capacitor prior to analog-to-digital conversion by elements or circuitry of the ADC (not shown in this figure).

[0040] As discussed above, each sampling capacitor 408a-408e has a different capacitance selected to scale the voltage associated with each bit of the input data byte. For example, in the illustrated embodiment, the bit line current (I MSB ) is the voltage (V MSB ) and stored or accumulated as a charge on a sampling capacitor 408e having a capacitance of 16C. MSB-1 ) is stored in a sampling capacitor 408d having a capacitance of 8C, and V MSB-2 is stored on sampling capacitor 408c having capacitance 4C, and V MSB-3 is stored on sampling capacitor 408b having a capacitance of 2C, and V LSB is stored on a sampling capacitor 408a having a capacitance C.

[0041] In addition to the above, the charge storage bank 400 further comprises a first bus or input bus 414 connected to the output of the I / V converter 402 or a reference voltage (V REF ), and a second switch 416 that can couple the accumulated charge generated by the sum of the bit line currents stored in each of the sampling capacitors 408a-408e to a second bus or output bus 418 to ground. A first or top plate of each of the sampling capacitors 408a-408e is individually coupled to the input bus 414 via independent switches 420a-420e, such that the charge for each bit in the input data byte is accumulated individually on one of the sampling capacitors 408a-408e, rather than stored simultaneously on all of the sampling capacitors as in a conventional SAR ADC. The second and subsequent plates of each of the sampling capacitors 408a-408e are coupled in parallel with each other, and the subsequent plates of the dummy capacitor 410 are coupled to the output bus 418. The top plate of the dummy capacitor 410 is coupled to the input bus via a switch 422. When the input to I / V converter 402 is coupled to a shared bit line 424 in a column of the memory array that receives current from a bit line corresponding to a particular bit of the input data byte stream, switches 420a-420e are turned on in sequence to charge each of sampling capacitors 408a-408e. Switches 412, 416, 420a-420e and 422 are controlled or operated by a controller (not shown) in or coupled to the MAC core.

[0042] 5 is a flow chart of a method of operating a charge storage bank coupled to a single bit line to accumulate current resulting from shifting an input data byte into each row, perform a MAC operation on all bits of the input data byte, and convert the charge resulting from the MAC operation on all bits of the input data byte into an output data byte. Although the following method is described as a single charge storage bank coupled to a single bit line, it will be understood that in actual operation of a MAC core including a first charge storage bank and a second charge storage bank coupled to each bit line of a column of an array including multiple columns, these steps are performed simultaneously or nearly simultaneously in each of multiple first and second charge storage banks coupled to each bit line of the array.

[0043] Referring to FIG. 5, in a first phase, the method calculates a first column bitline current (I 1 ), which is the sum of weighted bitline currents from all memory cells in a first column activated by the MSB of a first input data byte that is shifted into a row in the array and coupled to the charge storage bank during a first clock cycle. MSB ) is received (502). The sum of the weighted bit line currents is then calculated as a voltage (V MSB ) and stored as a charge in a first charge storage element in the charge storage bank (504). Referring to FIG. 4A, this is accomplished by converting the current to a voltage using I / V converter 402, closing switch 412 to couple input bus 414 to the output of I / V converter 402, closing switch 416 to couple output bus 418 to ground, and closing switch 420e to couple the accumulated charge onto first capacitor 408e. In the second clock cycle, the next MSB (MSB-1) of the first input data byte is shifted down a row in the array and the sum of the weighted bitline currents (I MSB-1 ) is received (506). The sum of the weighted bit line currents formed from the next MSB is a voltage (V MSB-1 ) and stored as a charge in a second charge storage element in the charge storage bank (508). Referring to FIG. 4B, this is accomplished by opening switch 420e and closing switch 420d, accumulating charge in second capacitor 408d. The process continues in a similar order until the weighted bit line currents formed by all the bits of the first input data byte have been received and stored in the individual capacitors 408a-408e of charge storage bank 400. Referring to FIG. 4C, the accumulated charge provided by all the bits of the input data byte is then converted to a reference voltage (V REF ), and opening switch 416 to connect all switches 420a-420e to ground. In an alternative embodiment, instead of the MSB first approach, the LSB is shifted in the first clock cycle, continuing with LSB+1, until the weighted bitline currents formed by all bits of the first input data byte have been received and stored in the individual capacitors 408e-408a in the charge storage bank 400.

[0044] At the end of the five clock cycles, the charge storage bank is decoupled from the shared bit lines in the column and coupled to the ADC at or through node N (510). An equivalent voltage required to scale the voltage associated with each input bit is then provided to node N (512). Referring to FIG. 4C, this can be accomplished by closing all of the switches 420a-420e and switch 422 to couple the top plates of all of the sampling capacitors 408a-408e to the dummy capacitor 410 and thus to ground, whereupon the charge is redistributed. A standard SAR ADC conversion of the voltages associated with each input bit stored on each sampling capacitor 408b-408f is then performed in sequence (514). Referring to FIG. 4D, this is accomplished by closing switch 420e to V REF By switching REF This can be accomplished by forcing a voltage onto node N, which produces a voltage of VREF / 2-Vin (where Vin is the scaled equivalent of all the charges stored on capacitors 408a-408e in all sampling phases across all input bits in the input byte). The ADC determines the MSB bit based on the voltage seen at node N. Normal SAR controller operation then proceeds as follows: based on the MSB bit decision, the SAR controller applies a sample VREF / 4 or 3 to node N. * Determine VREF / 4, and so on.

[0045] 6 is a schematic block diagram of an embodiment of an artificial intelligence (AI) system 600 with a hardware accelerator 602 including multiple neural engines or cores 604 each including a MAC core 606 having an IMC architecture operating in accordance with the present disclosure. With reference to FIG. 6, the system includes a microcontroller or processor 608 in addition to the hardware accelerator 602. The processor 608 may include or be implemented as a system on a chip (SOC), a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), or a microcontroller unit (MCU), and may be integrated on a common or shared substrate with the hardware accelerator 602 or elements thereof, or packaged in a shared integrated circuit package, or mounted on a common or shared substrate with the hardware accelerator, depending on the complexity of the AI ​​system 600, particularly the processor.

[0046] In addition to the MAC core 606, each neural core 604 typically further includes a programmable nonlinear engine (NLE) 610 for performing nonlinear activation functions at the MAC output side, and a cache 612 including random access memory (RAM) or static random access memory (SRAM).

[0047] In addition to the neural core 604, the hardware accelerator 602 typically further includes an AI coprocessor 614, e.g., a central processing unit (CPU) subsystem, a buffer 616 including RAM or SRAM, an input / output subsystem (IOSS 618), and a system resource subsystem (SRSS 620), all of which are electrically coupled via a peripheral interconnect 622 and / or a system interconnect 624 within the AI ​​coprocessor.

[0048] The AI ​​coprocessor 614 typically includes firmware stored in read-only memory (ROM) 626, RAM 628 or SRAM, and a processor 630 having a reduced instruction set computing (RISC) architecture, or a processor including the Cortex M series commercially available from ARM Holdings Plc.

[0049] An in-memory computing (IMC) architecture including a MAC core with an NVM memory array and dual charge storage banks, and a method for operating the same to improve the speed and efficiency of MAC operations have been disclosed. An advantage of the MAC core and MAC operation method is that no additional power needs to be consumed when scaling the input current according to the weight of the input bits, and because the scaled voltage is formed from the same capacitors in the charge storage bank, any charge leakage in the charge storage bank becomes a gain error that can be accounted for at the system level. It will thus be appreciated that the MAC core and MAC operation method disclosed herein provide better power efficiency than can be achieved with similar prior art IMC architectures, providing improved total operations per second (TOPS) and TOPS / Watt.

[0050] The embodiments of the present invention have been described above using functional and schematic block diagrams showing the implementation of specific functions and their relationships. The boundaries of these functional building blocks have been arbitrarily defined in this specification for the convenience of description. Alternative boundaries can be defined as long as the specific functions and their relationships are appropriately performed.

[0051] The above description of the specific embodiments fully reveals the overall nature of the invention, so that by applying knowledge belonging to those skilled in the art, such specific embodiments can be easily modified and / or adapted for various applications without undue experimentation and without departing from the overall concept of the invention. Therefore, such adaptations and modifications are intended to be within the meaning and range of equivalents of the disclosed embodiments, based on the teachings and guidance presented herein. It should be understood that the words or terms used herein are for the purpose of description and not for the purpose of limitation, and thus should be interpreted by those skilled in the art in light of the teachings and guidance.

[0052] It is understood that the Detailed Description section, and not the Summary and Abstract sections, are intended to be used to interpret the claims. The Summary and Abstract sections describe one or more embodiments of the invention contemplated by the inventors, but do not describe every exemplary embodiment, and thus are not intended to limit the scope of the invention and the appended claims in any manner.

[0053] The breadth and scope of the present invention should not be limited by any of the above-described exemplary embodiments, but should be defined only in accordance with the following claims and their equivalents.

Claims

1. A method implemented by a multiplication and accumulation (MAC) core, the method comprising: coupling each of a plurality of first input bytes to one of a plurality of rows in an array of memory cells arranged in rows and columns, each memory cell in a column being coupled to a shared bit line; the MAC core sequentially shifting bits of a first input byte into each memory cell of each row; , where, bit by bit, said MAC core multiplies each bit by a weight stored in each memory cell and activates each memory cell based on the state of said bit, thereby forming a weighted bit line current from each activated memory cell that is proportional to the product of the bit and its internally stored weight; the MAC core accumulates in a first charge storage bank, each coupled to a shared bit line of one of the columns, a charge formed by a sum of weighted bit line currents from each activated memory cell of the column; Concurrently with said shifting, said multiplying and said accumulating, said MAC core converts, from a plurality of second input bytes previously accumulated in a second charge storage bank, charges formed by the sum of the weighted bit line currents into an output byte using a plurality of coupled analog-to-digital converters (ADCs). method.

2. said shifting, said multiplication and said accumulation being accomplished without converting bits of the first input bytes using a digital-to-analog converter; The method of claim 1.

3. The method further includes the step of the MAC core swapping the first charge storage bank with the second charge storage bank after bits of the plurality of first input bytes have been shifted to accumulate charge in the first charge storage bank and after charge in the second charge storage bank has been converted. The method of claim 1.

4. each of the first charge storage bank and the second charge storage bank comprises a plurality of bit line capacitors having different capacitances; accumulating the charge includes accumulating in a column charge formed by sequentially shifting each bit of one of the plurality of bit line capacitors having a capacitance selected in relation to a significance of the bit in the plurality of first input bytes. The method of claim 1.

5. the first bit shifted into each row is the most significant bit (MSB) of the first input byte associated with the row; accumulating the charge formed by the sum of the weighted bit line currents from the first bits of a column includes accumulating the charge on a bit line capacitor in the first charge storage bank having a maximum capacitance. The method of claim 4.

6. each of the first charge storage bank and the second charge storage bank further comprising a dummy capacitor coupled to its output node; and converting the previously accumulated charge in the second charge storage bank includes redistributing the charge stored on the plurality of bit line capacitors to the dummy capacitors to provide an equivalent voltage for scaling a voltage associated with the charge stored on each of the plurality of bit line capacitors. The method of claim 4.

7. Each memory cell comprises a multi-level non-volatile memory (NVM) device; The method further includes the step of the MAC core storing a weight for each NVM device prior to sequentially shifting bits of the plurality of first input bytes into each memory cell. The method of claim 1.

8. each memory cell includes two multi-level non-volatile memory (NVM) devices including a first NVM device coupled to the shared bitline and a second NVM device coupled to a second shared bitline shared by a second NVM device in the column of memory cells; The method further includes the step of the MAC core storing a different weight for each of the first NVM device and the second NVM device within the memory cells prior to sequentially shifting bits of the plurality of first input bytes into each memory cell. The method of claim 1.

9. the different weights stored in each of the first NVM device and the second NVM device have opposite polarities. The method of claim 8.

10. A multiplication and accumulating (MAC) core, comprising: an array of memory cells arranged in rows and columns, each memory cell in a column being coupled to a shared bit line; a plurality of registers, each coupled to one row of said array, for sequentially shifting bits of a first input byte into said row, activating said memory cells based on the state of said bits, and forming weighted bit line currents from each activated memory cell proportional to the product of the bit and a weight stored therein; a plurality of first charge storage banks each coupled to the shared bit line in one of the columns and configured to receive sums of weighted bit line currents and to accumulate charges formed by the sums of weighted bit line currents for each bit of the input byte; a plurality of second charge storage banks coupled to a plurality of analog-to-digital converters (ADCs), each configured to provide, simultaneously with said shifting and said accumulating, a bit-wise scaled voltage of a previously received second input byte to said plurality of ADCs for conversion into an output byte; a controller coupled to the plurality of first charge storage banks and the second charge storage bank such that each bit of the first input byte is accumulated in the first charge storage bank and a charge in the second charge storage bank is converted before the first charge storage bank is switched to the second charge storage bank; A multiplication and accumulation (MAC) core comprising:

11. the MAC core does not include a digital-to-analog converter between the plurality of registers and the array; The MAC core of claim 10.

12. each of the first charge storage bank and the second charge storage bank comprises a plurality of bit line capacitors having different capacitances for accumulating charge formed in a column by sequentially shifting bits of one of the plurality of bit line capacitors each having a capacitance selected with respect to a significance of a bit in the first input byte; The MAC core of claim 10.

13. each of the first charge storage bank and the second charge storage bank further comprising a dummy capacitor coupled to an output node thereof, the dummy capacitor redistributing charge stored on the plurality of bit line capacitors to the dummy capacitor to provide a voltage equivalent to a scaled voltage associated with charge stored on each of the plurality of bit line capacitors; 13. The MAC core of claim 12.

14. Each memory cell includes a multi-level non-volatile memory (NVM) device with a weight stored in each memory cell. The MAC core of claim 10.

15. each memory cell includes two multi-level non-volatile memory (NVM) devices including a first NVM device coupled to the shared bitline and a second NVM device coupled to a second shared bitline shared by a second NVM device in the column of memory cells, the first NVM device and the second NVM device storing different weights; 15. The MAC core of claim 14.

16. a time to accumulate the scaled charge generated from each bit of the first input byte in the first charge storage bank is longer than a time to convert the charge in the second charge storage bank, and the plurality of ADCs are time multiplexed to convert the charges in the plurality of second charge storage banks. The MAC core of claim 10.

17. 1. An artificial intelligence (AI) system, comprising: A microcontroller; A plurality of multiplication and accumulation (MAC) cores; Each MAC core comprises: an array of memory cells arranged in rows and columns, each memory cell including a non-volatile memory (NVM) device, each column including bit lines connecting the NVM devices in the column; a plurality of registers, each coupled to one row of the array, for sequentially shifting bits of a first input byte into the row to activate the NVM devices based on the state of the bits, and for forming weighted bitline currents from each activated NVM device proportional to the product of the bit and a weight stored therein; a plurality of first charge storage banks, each coupled to a bit line of one of said columns and configured to receive a sum of weighted bit line currents and to accumulate a charge formed by said sum of weighted bit line currents for each bit of said input byte; a plurality of second charge storage banks coupled to a plurality of analog-to-digital converters (ADCs) and configured to provide, simultaneously with said shifting and said accumulating, a bit-wise scaled voltage of a previously received second input byte to said plurality of ADCs for conversion into an output byte; a controller coupled to the plurality of first charge storage banks and the second charge storage bank such that each bit of the first input byte is accumulated in the first charge storage bank and a charge in the second charge storage bank is converted before the first charge storage bank is switched to the second charge storage bank; A system including:

18. each of the first charge storage bank and the second charge storage bank comprises a plurality of bit line capacitors having different capacitances for accumulating charge formed in a column by sequentially shifting bits of one of the plurality of bit line capacitors each having a capacitance selected with respect to a significance of a bit in the first input byte; 20. The system of claim 17.

19. each of the first charge storage bank and the second charge storage bank further comprising a dummy capacitor coupled to an output node thereof, the dummy capacitor redistributing charge stored on the plurality of bit line capacitors to the dummy capacitor to provide a voltage equivalent to a scaled voltage associated with charge stored on each of the plurality of bit line capacitors; 20. The system of claim 18.

20. Each NVM device comprises a multi-level NVM device with weights stored for each memory cell.

20. The system of claim 17.

Citation Information

Patent Citations

  • Integrated circuit

    JP1997198365A

  • Product sum calculation circuit and method therefor

    JP2005122466A

  • Semiconductor integrated circuit

    JP2020035502A

  • JPP6521207B

  • JPP6540931B