TWI772034B - In-memory computation system - Google Patents

In-memory computation system Download PDF

Info

Publication number
TWI772034B
TWI772034B TW110118502A TW110118502A TWI772034B TW I772034 B TWI772034 B TW I772034B TW 110118502 A TW110118502 A TW 110118502A TW 110118502 A TW110118502 A TW 110118502A TW I772034 B TWI772034 B TW I772034B
Authority
TW
Taiwan
Prior art keywords
signal
flip
flop
circuit
electrically connected
Prior art date
Application number
TW110118502A
Other languages
Chinese (zh)
Other versions
TW202247012A (en
Inventor
王朝欽
黃嘉億
葉家宏
Original Assignee
國立中山大學
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 國立中山大學 filed Critical 國立中山大學
Priority to TW110118502A priority Critical patent/TWI772034B/en
Application granted granted Critical
Publication of TWI772034B publication Critical patent/TWI772034B/en
Publication of TW202247012A publication Critical patent/TW202247012A/en

Links

Images

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)
  • Dram (AREA)
  • Complex Calculations (AREA)

Abstract

An in-memory computation system includes a static random access memory (SRAM) array, a ripple carry computation unit, a computation control unit, and an automatic switching write-back unit. The computation control unit is used to control the output the logic data of the two stored data stored in the SRAM array for the computation. The ripple carry computation unit outputs the computation data of the two stored data according to the logic data, the automatic switching write-back unit restores the computation data to the SRAM array for completing the in-memory computation.

Description

記憶體內運算系統in-memory computing system

本發明是關於一種記憶體內運算系統,特別是關於一種具有靜態隨機存取記憶體陣列之記憶體內運算系統。The present invention relates to an in-memory computing system, in particular to an in-memory computing system with a static random access memory array.

現今計算機系統有著進行人工智慧、類神經網路之等需要大量運算資源的需求,使得運算速度一直是計算機系統的發展重點,但計算機系統的運算速度基於其基礎設計而存在著范紐曼瓶頸(von Neumann bottleneck),也就是因為中央處理單元及記憶體分別獨立設置,使得中央處理單元與記憶體之間的數據傳輸時間成為了無法降低的運算時間,導致以先進半導體製程製成的中央處理單元及記憶體雖然已有著突破性的運算速度,但整體計算機系統的運算速度仍受到范紐曼瓶頸的限制,為了打破這個限制,可在記憶體單元內完成運算之記憶體內運算系統已經成為計算機系統提高運算速度的研究重點之一。Nowadays, computer systems have the demand for a large amount of computing resources for artificial intelligence, neural-like networks, etc., so that computing speed has always been the focus of the development of computer systems, but the computing speed of computer systems is based on its basic design and there is a Van Neumann bottleneck (von Neumann). Neumann bottleneck), that is, because the central processing unit and the memory are independently set up, the data transfer time between the central processing unit and the memory becomes an unreduced computing time, resulting in the central processing unit and the advanced semiconductor process. Although memory has a breakthrough computing speed, the computing speed of the overall computer system is still limited by the Van Neumann bottleneck. One of the research priorities of speed.

本發明的主要目的在於藉由運算控制單元及自動切換寫回單元達成記憶體內運算系統的數據運算並將運算結果自動回存至記憶體中,因此可突破運算瓶頸而大幅提高運算速度。The main purpose of the present invention is to achieve the data operation of the in-memory computing system through the operation control unit and the automatic switching write-back unit and automatically store the operation results back into the memory, thereby breaking through the operation bottleneck and greatly improving the operation speed.

本發明之一種記憶體內運算系統包含一靜態隨機存取記憶體陣列、一漣波進位運算單元、一運算控制單元及一自動切換寫回單元,該靜態隨機存取記憶體陣列具有複數個記憶體單元、複數個2T開關單元組及一預充電電路,各該記憶體單元具有一儲存節點及一反儲存節點,各該2T開關單元組電性連接各該記憶體單元之該儲存節點及該反儲存節點,該預充電電路電性連接該些2T開關單元組,該些2T開關單元組輸出複數個邏輯數據,該漣波進位運算單元電性連接該些2T開關單元組以接收該些邏輯數據,且該漣波進位運算單元輸出複數個運算數據,該運算控制單元電性連接該靜態隨機存取記憶體陣列,該運算控制單元用以輸出複數個控制訊號至該預充電電路及該些2T開關單元組,以控制該預充電電路及各該2T開關單元組的開啟或關閉,該自動切換寫回單元電性連接該漣波進位運算單元及該靜態隨機存取記憶體陣列,以由該些漣波進位運算單元接收該些運算數據,且該自動切換寫回單元將該些運算數據寫回該靜態隨機存取記憶體陣列之該些記憶體單元中。An in-memory computing system of the present invention includes a static random access memory array, a ripple carry operation unit, an operation control unit and an automatic switching write-back unit, and the static random access memory array has a plurality of memories unit, a plurality of 2T switch unit groups and a precharge circuit, each of the memory cells has a storage node and an inverse storage node, each of the 2T switch cell groups is electrically connected to the storage node and the inverse storage node of each of the memory cells a storage node, the precharge circuit is electrically connected to the 2T switch unit groups, the 2T switch unit groups output a plurality of logic data, the ripple carry operation unit is electrically connected to the 2T switch unit groups to receive the logic data , and the ripple carry operation unit outputs a plurality of operation data, the operation control unit is electrically connected to the SRAM array, and the operation control unit is used for outputting a plurality of control signals to the precharge circuit and the 2T A switch unit group to control the precharge circuit and each of the 2T switch unit groups to be turned on or off, the automatic switching write-back unit is electrically connected to the ripple carry operation unit and the SRAM array, so that the The ripple-carry operation units receive the operation data, and the automatic switching write-back unit writes the operation data back into the memory cells of the SRAM array.

本發明藉由該運算控制單元輸出之訊號控制該靜態隨機存取記憶體陣列進行該些邏輯數據運算,並藉由該漣波進位運算單元依據該些邏輯數據求得所需之該些運算數據,最後藉由該自動切換寫回單元將該些運算數據寫回該靜態隨機存取記憶體陣列中,由於直接於記憶體中完成運算,可突破運算瓶頸而大幅提高運算速度。In the present invention, the SRAM array is controlled by the signal output from the operation control unit to perform the logic data operations, and the ripple carry operation unit is used to obtain the required operation data according to the logic data. Finally, the operation data is written back into the SRAM array by the automatic switching write-back unit. Since the operation is directly completed in the memory, the operation bottleneck can be broken and the operation speed can be greatly improved.

請參閱第1圖,其為本發明之一實施例,一種記憶體內運算系統100的功能方塊圖,其包含一靜態隨機存取記憶體陣列110、一漣波進位運算單元120、一運算控制單元130、一自動切換寫回單元140、一SRAM控制單元150及一欄選擇器160。Please refer to FIG. 1, which is a functional block diagram of an in-memory computing system 100 according to an embodiment of the present invention, which includes a static random access memory array 110, a ripple-carry operation unit 120, and an operation control unit 130 , an automatic switching write-back unit 140 , a SRAM control unit 150 and a column selector 160 .

請參閱第2圖,為本實施例之該靜態隨機存取記憶體陣列110電路圖,該靜態隨機存取記憶體陣列110具有複數個記憶體單元111、複數個2T開關單元組112及複數個預充電電路113,各該記憶體單元111具有一儲存節點Q及一反儲存節點Qb,各該2T開關單元組112電性連接各該記憶體單元111之該儲存節點Q及該反儲存節點Qb,該預充電電路113電性連接該些2T開關單元組112,該些2T開關單元組112輸出複數個邏輯數據。Please refer to FIG. 2 , which is a circuit diagram of the SRAM array 110 of this embodiment. The SRAM array 110 has a plurality of memory cells 111 , a plurality of 2T switch unit groups 112 and a plurality of pre- In the charging circuit 113, each of the memory cells 111 has a storage node Q and an inverse storage node Qb, and each of the 2T switch cell groups 112 is electrically connected to the storage node Q and the inverse storage node Qb of each of the memory cells 111, The precharge circuit 113 is electrically connected to the 2T switch unit groups 112 , and the 2T switch unit groups 112 output a plurality of logic data.

在本實施例中,共具有4列×4欄之16個該記憶體單元111,每個記憶體單元111皆電性連接一組該2T開關單元組,其中,請參閱第3圖,各該2T開關單元組112具有一進位值2T開關112a、一反或值2T開關112b及一及值2T開關112c。該進位值2T開關112a電性連接該記憶體單元111之該儲存節點Q及一反進位值線11,且該進位值2T開關112a受到一進位運算控制訊號S及該記憶體單元111之該儲存節點Q之電位的控制。該反或值2T開關112b電性連接該記憶體單元111之該儲存節點Q及一反或值線12,且該反或值2T開關112b受到一邏輯運算控制訊號C及該記憶體單元111之該儲存節點Q之電位的控制。該及值2T開關112c電性連接該記憶體單元111之該反儲存節點Qb及一及值線13,且及值2T開關112c受到該邏輯運算控制訊號C及該記憶體單元111之該反儲存節點Qb之電位的控制。In this embodiment, there are 16 memory cells 111 in 4 rows×4 columns in total, and each memory cell 111 is electrically connected to a group of the 2T switch cell groups. Please refer to FIG. The 2T switch unit group 112 has a carry-value 2T switch 112a, an inverse-OR 2T switch 112b, and an sum-value 2T switch 112c. The carry 2T switch 112a is electrically connected to the storage node Q of the memory cell 111 and an inverse carry line 11, and the carry 2T switch 112a receives a carry operation control signal S and the storage of the memory cell 111 Control of the potential of node Q. The inverse-OR 2T switch 112b is electrically connected to the storage node Q of the memory cell 111 and an inverse-OR line 12 , and the inverse-OR 2T switch 112b receives a logic operation control signal C and the memory cell 111 Control of the potential of the storage node Q. The sum-value 2T switch 112c is electrically connected to the inverse storage node Qb of the memory cell 111 and a sum-value line 13 , and the sum-value 2T switch 112c receives the logic operation control signal C and the inverse storage of the memory cell 111 Control of the potential of the node Qb.

請參閱第2及3圖,同一欄之該記憶體單元111之該2T開關單元組112電性連接同一個該預充電電路113。請參閱第3圖,該預充電電路113具有3個該預充電電晶體113a,各該充電電晶體113a分別電性連接該反進位值線11、該反或值線12及該及值線13,各該充電電晶體113a受一預充電控制訊號PreC控制而在導通時將該反進位值線11、該反或值線12及該及值線13拉至高電位。此外,分別電性連接至該反進位值線11、該反或值線12及該及值線13的三個旁路電容BC則用以穩定電壓值。Please refer to FIGS. 2 and 3 , the 2T switch unit group 112 of the memory unit 111 in the same column is electrically connected to the same precharge circuit 113 . Please refer to FIG. 3, the precharge circuit 113 has three precharge transistors 113a, and each of the charge transistors 113a is electrically connected to the inverse carry value line 11, the inverse OR value line 12 and the sum value line 13 respectively. , each of the charging transistors 113a is controlled by a precharge control signal PreC to pull the inverse carry value line 11 , the inverse OR value line 12 and the sum value line 13 to a high potential when turned on. In addition, the three bypass capacitors BC electrically connected to the inverse carry value line 11 , the inverse OR value line 12 and the sum value line 13 respectively are used for stabilizing the voltage value.

請參閱第4圖,為本實施例之該記憶體單元111的電路圖,該記憶體單元111為7T之靜態隨機存取單端讀取記憶體架構,其具有2個P型電晶體MP201~202及5個N型電晶體MN201~205,其中相互電性連接之P型電晶體MP201~202用以鎖存儲存於該儲存節點Q及該反儲存節點Qb中的數據,N型電晶體MN201~203則分別受3個控制訊號WL、WA、WAB控制進行數據的讀取或寫入,N型電晶體MN204~205則分別提供該儲存節點Q及該反儲存節點Qb一個放電路經,以避免漏電流累積而導致儲存數據的反轉。Please refer to FIG. 4 , which is a circuit diagram of the memory unit 111 of this embodiment. The memory unit 111 is a 7T SRAM single-ended read memory structure, which has two P-type transistors MP201-202 and five N-type transistors MN201-205, wherein the P-type transistors MP201-202 electrically connected to each other are used to latch the data stored in the storage node Q and the inverse storage node Qb, and the N-type transistors MN201- 203 is controlled by three control signals WL, WA, WAB to read or write data, and N-type transistors MN204~205 respectively provide a discharge circuit for the storage node Q and the reverse storage node Qb to avoid The leakage current accumulates and causes the inversion of the stored data.

請再參閱第4圖,一反位元線14電性連接該記憶體單元111以讀取該記憶體單元111之該反儲存節點Qb數據,或是將數據寫入該記憶體單元111中,一位元線15則經由一反向器INV電性連接該反位元線14以得到儲存於該儲存節點Q中之數據的電位大小。N型電晶體MN206則受到一預放電控制訊號PreD控制,以在該記憶體單元111進行寫入前導通時將該反位元線14放電至低電位,以避免影響該記憶體單元111的數據讀取及寫入。Please refer to FIG. 4 again, an inversion bit line 14 is electrically connected to the memory cell 111 to read the data of the inversion storage node Qb of the memory cell 111 , or write data into the memory cell 111 , The bit line 15 is electrically connected to the inversion bit line 14 via an inverter INV to obtain the potential magnitude of the data stored in the storage node Q. The N-type transistor MN206 is controlled by a pre-discharge control signal PreD to discharge the inversion line 14 to a low potential when the memory cell 111 is turned on before writing, so as to avoid affecting the data of the memory cell 111 read and write.

在本實施例中,該記憶體單元111在寫入0時,該預放電控制訊號PreD上升至高電位使該N型電晶體MN206導通,該反位元線14放電至低電位,同時,控制訊號WL、WAB為高電位,WA為低電位而導通N型電晶體MN201、MN203,截止N型電晶體MN202,使該儲存節點Q降至低電位而完成寫入0。該記憶體單元111在寫入1時,該預放電控制訊號PreD上升至高電位使該N型電晶體MN206導通,該反位元線14放電至低電位,同時,控制訊號WL、WA為高電位,WAB為低電位而導通N型電晶體MN201、MN202,截止N型電晶體MN203,使該反儲存節點Qb降至低電位導通該P型電晶體MP202而完成寫入1。該記憶體單元111於讀取時,該預放電控制訊號PreD下降至低電位使該N型電晶體MN206截止,同時,控制訊號WL、WA為高電位,WAB為低電位而導通N型電晶體MN201、MN202,截止N型電晶體MN203,使該反儲存節點Qb的電位傳送至該反位元線14,並經由該反向器反向至該位元線15而完成讀取。In this embodiment, when the memory cell 111 is writing 0, the pre-discharge control signal PreD rises to a high level to turn on the N-type transistor MN206, the inversion line 14 is discharged to a low level, and at the same time, the control signal WL and WAB are at high potential, WA is at low potential, turn on N-type transistors MN201 and MN203, turn off N-type transistor MN202, and lower the storage node Q to a low potential to complete writing 0. When writing 1 in the memory cell 111, the pre-discharge control signal PreD rises to a high potential to turn on the N-type transistor MN206, the inversion line 14 is discharged to a low potential, and at the same time, the control signals WL and WA are at a high potential , WAB turns on the N-type transistors MN201 and MN202 at a low potential, and turns off the N-type transistor MN203, so that the reverse storage node Qb drops to a low potential and turns on the P-type transistor MP202 to complete writing 1. When the memory cell 111 is being read, the pre-discharge control signal PreD drops to a low potential to turn off the N-type transistor MN206, and at the same time, the control signals WL and WA are at a high potential, and WAB is at a low potential to turn on the N-type transistor MN201 and MN202 turn off the N-type transistor MN203, so that the potential of the inversion storage node Qb is transmitted to the inversion bit line 14, and is reversed to the bit line 15 through the inverter to complete the reading.

請參閱第5及6圖,該些2T開關單元組112輸出該些邏輯數據包含一反進位值CB、一反或值NOR及一及值AND,且進行記憶體內運算時,其中一個該進位值2T開關112a及其中兩個該反或值2T開關112b及該及值2T開關112c開啟,其餘之該些進位值2T開關112a、該些反或值2T開關112b及該些及值2T開關112c關閉。Please refer to FIGS. 5 and 6, the logic data output by the 2T switch unit groups 112 includes an inverse carry value CB, an inverse OR value NOR and an AND value AND, and when performing in-memory operations, one of the carry values 2T switch 112a and two of the inverse-OR 2T switches 112b and the sum 2T switch 112c are on, and the rest of the carry 2T switches 112a, the inverse-or 2T switches 112b and the sum 2T switches 112c are off .

請參閱第5圖,該反進位值CB是兩組多位元之數據相加時,前一位元進行加法運算而得並存入該記憶體單元111中之進位值的反向值。以該進位值為1儲存於第2位元之該記憶體單元111為例,在讀取該反進位值CB時,先以該預充電電路113拉高該反進位值線11的電位,再將該進位運算控制訊號S2提高至高電位,由於第2位元之該儲存節點Q2所儲存的進位值為1,使得第2位元之該進位值2T開關112a導通,該反進位值線11經由該進位值2T開關112a接地而降至低電位,即得到該進位值1的反向值0。Please refer to FIG. 5 , the inverse carry value CB is the inverse value of the carry value stored in the memory unit 111 , which is obtained by adding the previous bit when two sets of multi-bit data are added. Taking the carry value 1 stored in the memory cell 111 in the second bit as an example, when reading the reverse carry value CB, the precharge circuit 113 first pulls up the potential of the reverse carry value line 11, and then The carry operation control signal S2 is raised to a high level. Since the carry value stored in the storage node Q2 of the second bit is 1, the carry value 2T switch 112a of the second bit is turned on, and the inverse carry value line 11 is connected via The carry value 2T switch 112a is grounded and lowered to a low level, that is, the inverse value 0 of the carry value 1 is obtained.

請參閱第6圖,該反或值NOR及該及值AND則是分別儲存於兩個位元之該記憶體單元111之數據之間的邏輯數據,以儲存於第0位元之值1及儲存於第1位元之值0進行運算為例。先以該預充電電路113拉高該反或值線12及該及值線13的電位,再將該邏輯運算控制訊號C0及C1提高至高電位,由於第0位元之該儲存節點Q0所儲存的值為1,該反儲存節點Qb0所儲存的值為0,使得第0位元之該反或值2T開關112b導通、該及值2T開關112c截止,該反或值線12經由該反或值2T開關112b接地而降至低電位。由於第1位元之該儲存節點Q1所儲存的值為0,該反儲存節點Qb1所儲存的值為1,使得第1位元之該反或值2T開關112b截止、該及值2T開關112c導通,該及值線13經由該及值2T開關112c接地而降至低電位,而可得到反或值NOR與該及值AND皆為0的結果。Please refer to FIG. 6 , the inverse-OR value NOR and the AND-value AND are logical data stored between the data of the memory cell 111 of the two bits, respectively, to be stored in the value 1 and the value of the 0th bit. Take the value 0 stored in the first bit for operation as an example. The precharge circuit 113 is used to pull up the potentials of the inverse OR value line 12 and the sum value line 13 first, and then the logic operation control signals C0 and C1 are raised to a high potential, because the storage node Q0 of the 0th bit stores is 1, and the value stored in the inverse storage node Qb0 is 0, so that the inverse-OR value 2T switch 112b of the 0th bit is turned on, the AND-value 2T switch 112c is turned off, and the inverse-OR value line 12 passes through the inverse-OR value line 12. The value 2T switch 112b is grounded to a low potential. Since the value stored in the storage node Q1 of the first bit is 0, the value stored in the inverted storage node Qb1 is 1, so that the inverse OR 2T switch 112b of the first bit is turned off, and the sum 2T switch 112c is turned off. When turned on, the sum line 13 is grounded to a low level through the sum 2T switch 112c, and the result that the inverse OR value NOR and the sum value AND are both 0 can be obtained.

請參閱第6圖,接著以儲存於第0位元之值0及儲存於第1位元之值0進行運算為例,先以該預充電電路113拉高該反或值線12及該及值線13的電位,再將該邏輯運算控制訊號C0及C1提高至高電位,由於第0位元之該儲存節點Q0所儲存的值為0,該反儲存節點Qb0所儲存的值為1,使得第0位元之該反或值2T開關112b截止、該及值2T開關112c導通,該及值線13經由該及值2T開關112c接地而降至低電位。由於第1位元之該儲存節點Q1所儲存的值為0,該反儲存節點Qb1所儲存的值為1,使得第1位元之該反或值2T開關112b截止、該及值2T開關112c導通,該及值線13經由該及值2T開關112c接地而降至低電位,而可得到反或值為1與該及值為0的結果。Please refer to FIG. 6, and then take the value 0 stored in the 0th bit and the value 0 stored in the 1st bit as an example, first, the precharge circuit 113 pulls up the inverse OR line 12 and the and The potential of the value line 13, and then the logic operation control signals C0 and C1 are raised to a high potential. Since the value stored in the storage node Q0 of the 0th bit is 0, the value stored in the inverse storage node Qb0 is 1, so that The inverse-OR 2T switch 112b of the 0th bit is turned off, the sum 2T switch 112c is turned on, and the sum line 13 is grounded to a low level through the sum 2T switch 112c. Since the value stored in the storage node Q1 of the first bit is 0, the value stored in the inverted storage node Qb1 is 1, so that the inverse OR 2T switch 112b of the first bit is turned off, and the sum 2T switch 112c is turned off. When turned on, the sum line 13 is grounded to a low level through the sum 2T switch 112c, and the result of the inverse OR value of 1 and the sum value of 0 can be obtained.

請參閱第1圖,該漣波進位運算單元120電性連接該些2T開關單元組112以接收該些邏輯數據,且該漣波進位運算單元120根據該些邏輯數據輸出複數個運算數據。請參閱第7圖,在本實施例中,該漣波進位運算單元120具有一邏輯計算電路121、一加法電路122及一進位電路123,該邏輯計算電路121電性連接該些2T開關單元組112以接收該反進位值CB、該反或值NOR及該及值AND,且該邏輯計算電路121根據該反進位值CB、該反或值NOR及該及值AND輸出複數個邏輯運算數據,在本實施例中,該些邏輯運算數據包含一反及值NAND、一反互斥或值XNOR、一互斥或值XOR及一進位值Cl。在本實施例中,該邏輯計算電路121具有三個反向器及一個反或閘,以藉由該些邏輯閘的邏輯運算得到該些邏輯運算數據。Please refer to FIG. 1 , the ripple-carry operation unit 120 is electrically connected to the 2T switch unit groups 112 to receive the logic data, and the ripple-carry operation unit 120 outputs a plurality of operation data according to the logic data. Please refer to FIG. 7. In this embodiment, the ripple-carry operation unit 120 has a logic calculation circuit 121, an addition circuit 122 and a carry circuit 123. The logic calculation circuit 121 is electrically connected to the 2T switch unit groups 112 receives the inverse carry value CB, the inverse OR value NOR and the sum value AND, and the logic calculation circuit 121 outputs a plurality of logical operation data according to the inverse carry value CB, the inverse OR value NOR and the sum value AND, In the present embodiment, the logical operation data includes an inverse AND value NAND, an inverse exclusive OR value XNOR, an exclusive OR value XOR, and a carry value C1. In this embodiment, the logic calculation circuit 121 has three inverters and an invertor gate, so as to obtain the logic operation data through the logic operation of the logic gates.

請參閱第7圖,該加法電路122電性連接該些2T開關組112及該邏輯計算電路121以接收該反進位值CB、該互斥或值XOR、該進位值Cl及該反互斥或值XNOR,且該加法單元122根據該些邏輯數據及該些邏輯運算數據輸出一加法值SUM,在本實施例中,該加法電路122由兩個P型電晶體MP6、MP7及兩個N型電晶體MN9、MN10構成,該些電晶體藉由該反進位值CB、該互斥或值XOR、該進位值Cl及該反互斥或值XNOR的控制輸出該加法值SUM。Please refer to FIG. 7, the addition circuit 122 is electrically connected to the 2T switch groups 112 and the logic calculation circuit 121 to receive the inverse carry value CB, the mutually exclusive OR value XOR, the carry value C1 and the inverse mutually exclusive OR value value XNOR, and the addition unit 122 outputs an addition value SUM according to the logic data and the logic operation data. In this embodiment, the addition circuit 122 consists of two P-type transistors MP6, MP7 and two N-type transistors Transistors MN9 and MN10 are formed, and these transistors output the added value SUM under the control of the inverse carry value CB, the mutually exclusive OR value XOR, the carry value C1 and the inverse mutually exclusive OR value XNOR.

該進位電路123電性連接該些2T開關單元組112及該邏輯計算電路121以接收該及值AND、該互斥或值XOR、該進位值Cl、該反互斥或值XNOR及該反及值NAND,且該加法單元122根據該邏輯數據及該些該些邏輯運算數據輸出一進位值CO。在本實施例中,該進位電路123由三個P型電晶體MP3、MP4、MP5及三個N型電晶體MN6、MN7、MN8構成,該些電晶體藉由該及值AND、該互斥或值XOR、該進位值Cl、該反互斥或值XNOR及該反及值NAND的控制輸出該進位值CO。The carry circuit 123 is electrically connected to the 2T switch unit groups 112 and the logic calculation circuit 121 to receive the sum value AND, the mutually exclusive OR value XOR, the carry value C1, the inverse mutex OR value XNOR and the inverse sum The value is NAND, and the addition unit 122 outputs a carry value CO according to the logic data and the logic operation data. In this embodiment, the carry circuit 123 is composed of three P-type transistors MP3, MP4, MP5 and three N-type transistors MN6, MN7, MN8. The control of the OR value XOR, the carry value C1, the inverse mutually exclusive OR value XNOR, and the inverse AND value NAND outputs the carry value CO.

較佳的,該及值線13之該及值AND還可作為兩個位元之數據進相乘而得的積值PRO,而該邏輯計算電路121邏輯運算而得之該互斥閘值XOR則還可作為兩個位元之數據的符號相乘而得的符號值SIG,因此,該漣波進位運算單元120除了可用於計算兩個位元之數據之間的加法運算外,還可用於兩個具符號之數據之間的乘法運算。Preferably, the AND value of the AND-value line 13 can also be used as the product value PRO obtained by multiplying the data of two bits, and the logical calculation circuit 121 obtains the mutually exclusive gate value XOR by logical operation. Then, it can also be used as the symbol value SIG obtained by multiplying the symbols of the two bits of data. Therefore, the ripple carry operation unit 120 can be used to calculate the addition operation between the two bits of data. Multiplication between two signed data.

請參閱第1及8圖,該運算控制單元130電性連接該靜態隨機存取記憶體陣列110,該運算控制單元130用以輸出複數個控制訊號至該靜態隨機存取記憶體陣列110之該預充電電路113及該些2T開關單元組112,以控制該預充電電路113及各該2T開關單元組112的開啟或關閉,進而讓對應位址之該記憶體單元111所儲存的數據進行加法或乘法之運算。Please refer to FIGS. 1 and 8 , the operation control unit 130 is electrically connected to the SRAM array 110 , and the operation control unit 130 is used for outputting a plurality of control signals to the SRAM array 110 . The precharge circuit 113 and the 2T switch unit groups 112 are used to control the precharge circuit 113 and each of the 2T switch unit groups 112 to be turned on or off, so as to allow the data stored in the memory unit 111 of the corresponding address to be added or multiplication.

請參閱第8圖,在本實施例中,該運算控制單元130具有一運算時脈控制電路131、一自動預充電切換控制電路132、一位址選擇電路133及一內運算控制電路134,該運算時脈控制電路131用以接收一加法運算訊號ADD、一乘法運算訊號MUL及一時脈訊號Clk,且該運算時脈控制電路131輸出一運算訊號OP、一總運算訊號Opprec、一寫入選擇訊號Wrsel及一反讀取寫入訊號Dffwr,在本實施例中,該運算時脈控制電路131具有一第一或閘131a、一第一正反器131b、一第二正反器131c、一第三正反器131d及一第四正反器131e,該第一或閘131a接收該加法運算訊號ADD及該乘法運算訊號MUL,且該第一或閘131a輸出該運算訊號OP,其中,該加法運算訊號ADD或該乘法運算訊號MUL上升至高電位表示進行記憶體準備進行加法或乘法運算,因此,該運算訊號OP上升至高電位。Referring to FIG. 8, in this embodiment, the operation control unit 130 has an operation clock control circuit 131, an automatic precharge switching control circuit 132, an address selection circuit 133 and an internal operation control circuit 134. The operation clock control circuit 131 is used for receiving an addition operation signal ADD, a multiplication operation signal MUL and a clock signal Clk, and the operation clock control circuit 131 outputs an operation signal OP, a total operation signal Opprec, and a write select The signal Wrsel and an inverse read and write signal Dffwr. In this embodiment, the operation clock control circuit 131 has a first OR gate 131a, a first flip-flop 131b, a second flip-flop 131c, a The third flip-flop 131d and a fourth flip-flop 131e, the first OR gate 131a receives the addition operation signal ADD and the multiplication operation signal MUL, and the first OR gate 131a outputs the operation signal OP, wherein the When the addition operation signal ADD or the multiplication operation signal MUL rises to a high level, it indicates that the memory is ready to perform an addition or multiplication operation. Therefore, the operation signal OP rises to a high level.

該第一正反器131b接收一讀寫控制訊號wr_en及該時脈訊號Clk,且該第一正反器131b經由緩衝器輸出一讀取寫入訊號Dffwr,該第一正反器131b輸出之該讀取寫入訊號Dffwr使用以讓該讀寫控制訊號wr_en與該時脈訊號Clk同步。該第二正反器131c電性連接該第一或閘131a,該第二正反器131c接收該時脈訊號Clk及該運算訊號OP,且該第二正反器131c輸出該總運算訊號Opprec,該第二正反器131c輸出之該總運算訊號Opprec是用以讓該運算訊號OP與該時脈訊號Clk同步。該第三正反器131d電性連接該第一或閘131a及該第一正反器131b以接收該運算訊號OP及該讀取寫入訊號Dffwr,且該第三正反器131d輸出該寫入選擇訊號Wrsel,該第三正反器131d用以將該讀取寫入訊號Dffwr除頻而輸出該寫入選擇訊號Wrsel。該第四正反器131e電性連接第一正反器131b,該第四正反器接收該讀取寫入訊號Dffwr及該時脈訊號Clk,且該第四正反器131e經由緩衝器輸出該反讀取寫入訊號Dffwrb,該第四正反器131e用以反向該讀取寫入訊號Dffwr而輸出該反讀取寫入訊號Dffwrb。The first flip-flop 131b receives a read-write control signal wr_en and the clock signal Clk, and the first flip-flop 131b outputs a read-write signal Dffwr through the buffer, which is output by the first flip-flop 131b The read-write signal Dffwr is used to synchronize the read-write control signal wr_en with the clock signal Clk. The second flip-flop 131c is electrically connected to the first OR gate 131a, the second flip-flop 131c receives the clock signal Clk and the operation signal OP, and the second flip-flop 131c outputs the total operation signal Opprec , the total operation signal Opprec output by the second flip-flop 131c is used to synchronize the operation signal OP with the clock signal Clk. The third flip-flop 131d is electrically connected to the first OR gate 131a and the first flip-flop 131b to receive the operation signal OP and the read-write signal Dffwr, and the third flip-flop 131d outputs the write signal the input selection signal Wrsel, the third flip-flop 131d is used for dividing the frequency of the read write signal Dffwr to output the write selection signal Wrsel. The fourth flip-flop 131e is electrically connected to the first flip-flop 131b, the fourth flip-flop receives the read and write signal Dffwr and the clock signal Clk, and the fourth flip-flop 131e outputs through a buffer The reverse read and write signal Dffwrb, the fourth flip-flop 131e is used for inverting the read and write signal Dffwr to output the reverse read and write signal Dffwrb.

該自動預充電切換控制電路132電性連接該運算時脈控制電路131以接收該總運算訊號Opprec、該寫入選擇訊號Wrsel及該反讀取寫入訊號Dffwr,且該自動預充電切換控制電路132輸出一預充電觸發訊號PreC_bit。在本實施例中,該自動預充電時脈控制電路132具有一第五正反器132a、一第六正反器132b、一計數器132c及一第一解碼器132d。該第五正反器132a電性連接運算時脈控制電路131以接收該總運算訊號Opprec及該運算訊號OP,且該第五正反器132a輸出一計數啟動訊號Cimp,第五正反器132a輸出之該計數啟動訊號Cimp用以在該總運算訊號Opprec上升至高電位時啟動該計數器132c進行計數。The automatic precharge switching control circuit 132 is electrically connected to the operation clock control circuit 131 to receive the total operation signal Opprec, the write selection signal Wrsel and the reverse read write signal Dffwr, and the automatic precharge switch control circuit 132 outputs a precharge trigger signal PreC_bit. In this embodiment, the automatic precharge clock control circuit 132 has a fifth flip-flop 132a, a sixth flip-flop 132b, a counter 132c and a first decoder 132d. The fifth flip-flop 132a is electrically connected to the operation clock control circuit 131 to receive the total operation signal Opprec and the operation signal OP, and the fifth flip-flop 132a outputs a count start signal Cimp, the fifth flip-flop 132a The outputted counting start signal Cimp is used to start the counter 132c to count when the total operation signal Opprec rises to a high level.

該第六正反器132b電性連接該第三正反器131d及該第四正反器131e以接收該寫入選擇訊號Wrsel及該反讀取寫入訊號Dffwrb,且該第六正反器132b輸出一預充電時脈訊號PreCclk,該第六正反器132b輸出之該預充電時脈訊號PreCclk為該寫入選擇訊號Wrsel及該反讀取寫入訊號Dffwrb之間的作動,用以決定該第一解碼器132d輸出之訊號產生的頻率。該計數器132c電性連接該第五正反器132a及該第六正反器132b以接收該計數啟動訊號Cimp及該預充電時脈訊號PreCclk,且該計數器132c受到該計數啟動訊號Cimp觸發後開始計數並輸出一計數訊號ct,該第一解碼器132d電性連接該計數器132c以接收該計數訊號ct,且該第一解碼器132d輸出該預充電觸發訊號PreC_bit,該預充電觸發訊號PreC_bit用以觸發不同欄的該預充電電路113。The sixth flip-flop 132b is electrically connected to the third flip-flop 131d and the fourth flip-flop 131e to receive the write select signal Wrsel and the reverse read write signal Dffwrb, and the sixth flip-flop 132b outputs a precharge clock signal PreCclk, and the precharge clock signal PreCclk output by the sixth flip-flop 132b is the action between the write select signal Wrsel and the reverse read write signal Dffwrb, used to determine The frequency of the signal output by the first decoder 132d. The counter 132c is electrically connected to the fifth flip-flop 132a and the sixth flip-flop 132b to receive the count start signal Cimp and the precharge clock signal PreCclk, and the counter 132c starts after being triggered by the count start signal Cimp Counting and outputting a count signal ct, the first decoder 132d is electrically connected to the counter 132c to receive the count signal ct, and the first decoder 132d outputs the precharge trigger signal PreC_bit, the precharge trigger signal PreC_bit is used for The precharge circuits 113 of different columns are activated.

該位址選擇電路133電性連接該運算時脈控制電路131以接收該運算訊號OP,該位址選擇電路133另接收一第一運算位址訊號OpX_add、一第二運算位址訊號OpY_add、一符號位址訊號MS_add及一運算結果位址訊號CR_add,且該位址選擇電路133輸出一運算位址控制訊號w0、一進位位址控制訊號w2及一運算結果位址控制訊號CR_DFF,該運算位址控制訊號w0、該進位位址控制訊號w2及該運算結果位址控制訊號CR_DFF用以決定欲進行運算的該記憶體單元111位址及運算後之運算結果欲儲存的該記憶體單元111位址。The address selection circuit 133 is electrically connected to the operation clock control circuit 131 to receive the operation signal OP. The address selection circuit 133 further receives a first operation address signal OpX_add, a second operation address signal OpY_add, a The symbol address signal MS_add and an operation result address signal CR_add, and the address selection circuit 133 outputs an operation address control signal w0, a carry address control signal w2 and an operation result address control signal CR_DFF, the operation bit The address control signal w0, the carry address control signal w2 and the operation result address control signal CR_DFF are used to determine the address of the memory unit 111 to perform the operation and the memory unit 111 bit to store the operation result after the operation site.

在本實施例中,該位址選擇電路133具有一第七正反器133a、一第八正反器133b、一第九正反器133c、一第十正反器133d、一第二解碼器133e、一第三解碼器133f、一第四解碼器133g及一第二或閘133h。該第七正反器133a電性連接該第一或閘131a,該第七正反器133a接收該運算訊號OP及該第一運算位址訊號OpX_add,且該第七正反器133a輸出一第一運算列訊號OpX,該第八正反器133b電性連接該第一或閘131a,該第八正反器133b接收該運算訊號OP及該第二運算位址訊號OpY_add,且該第八正反器133b輸出一第二運算列訊號OpY,該第九正反器133c電性連接該第一或閘133c,該第九正反器133c接收該運算訊號OP及該符號位址訊號MS_add,且該第九正反器133c輸出一進位列訊號MS,該第十正反器133d電性連接該第一或閘131a,該第十正反器133d接收該運算訊號OP及該預算結果位址訊號CR_DFF,且該第十正反器133d輸出該運算結果位址控制訊號CR_DFF。In this embodiment, the address selection circuit 133 has a seventh flip-flop 133a, an eighth flip-flop 133b, a ninth flip-flop 133c, a tenth flip-flop 133d, and a second decoder 133e, a third decoder 133f, a fourth decoder 133g, and a second OR gate 133h. The seventh flip-flop 133a is electrically connected to the first OR gate 131a, the seventh flip-flop 133a receives the operation signal OP and the first operation address signal OpX_add, and the seventh flip-flop 133a outputs a first For an operation column signal OpX, the eighth flip-flop 133b is electrically connected to the first OR gate 131a, the eighth flip-flop 133b receives the operation signal OP and the second operation address signal OpY_add, and the eighth positive flip-flop 133b receives the operation signal OP and the second operation address signal OpY_add. The inverter 133b outputs a second operation signal OpY, the ninth flip-flop 133c is electrically connected to the first OR gate 133c, the ninth flip-flop 133c receives the operation signal OP and the symbol address signal MS_add, and The ninth flip-flop 133c outputs a carry signal MS, the tenth flip-flop 133d is electrically connected to the first OR gate 131a, and the tenth flip-flop 133d receives the operation signal OP and the estimated result address signal CR_DFF, and the tenth flip-flop 133d outputs the operation result address control signal CR_DFF.

該第二解碼器133e電性連接該第七正反器133a以接收該第一運算列訊號OpX,且該第二解碼器133e輸出一第一解碼訊號,該第三解碼器133f電性連接該第八正反器133b以接收該第二運算列訊號OpY,且該第三解碼器133f輸出一第二解碼訊號,該第四解碼器133g電性連接該第八正反器133b以接收該進位列訊號MS,且該第四解碼器133g輸出該進位位址控制訊號w2,該第二或閘133h電性連接該第一解碼器132d及該第二解碼器133e以接收該第一解碼訊號及該第二解碼訊號,且該第二或閘133h輸出該運算位址控制訊號w0。The second decoder 133e is electrically connected to the seventh flip-flop 133a to receive the first operational column signal OpX, the second decoder 133e outputs a first decoded signal, and the third decoder 133f is electrically connected to the The eighth flip-flop 133b receives the second operational column signal OpY, the third decoder 133f outputs a second decoded signal, and the fourth decoder 133g is electrically connected to the eighth flip-flop 133b to receive the input signal. bit column signal MS, and the fourth decoder 133g outputs the carry address control signal w2, the second OR gate 133h is electrically connected to the first decoder 132d and the second decoder 133e to receive the first decoded signal and the second decoded signal, and the second OR gate 133h outputs the operation address control signal w0.

該內運算控制電路134電性連接該運算時脈控制電路131、該自動預充電切換控制電路132及該位址選擇電路133以接收該運算訊號OP、該反讀取寫入訊號Dffwrb、該預充電觸發訊號PreC_bit、該運算位址控制訊號w0及該進位位址控制訊號w2,且該內運算控制電路134輸出一預充電控制訊號PreC、一邏輯運算控制訊號C及一進位運算控制訊號S至該預充電電路113及該些2T開關單元組112進行控制。The internal operation control circuit 134 is electrically connected to the operation clock control circuit 131 , the automatic precharge switching control circuit 132 and the address selection circuit 133 to receive the operation signal OP, the reverse read and write signal Dffwrb, the precharge The charging trigger signal PreC_bit, the operation address control signal w0 and the carry address control signal w2, and the internal operation control circuit 134 outputs a precharge control signal PreC, a logic operation control signal C and a carry operation control signal S to The precharge circuit 113 and the 2T switch unit groups 112 are controlled.

在本實施例中,該內運算控制電路134具有一預充電控制器134a及一內運算記憶體控制器134b,該預充電控制器134a電性連接該運算時脈控制電路131以接收該運算訊號OP及該反讀取寫入訊號Dffwrb,且該預充電控制器134a輸出一運算位元控制訊號sc及一預充電位元控制訊號pcc,由於記憶體內運算需先對該反進位值線11、該反或值線12及該及值線13進行預充電後再進行該些2T開關單元組112的切換,因此,該預充電控制器134a藉由延遲元件讓該預充電位元控制訊號pcc先觸發該預充電電路113進行預充電後再由該運算位元控制訊號sc觸發2T開關單元組112。In this embodiment, the internal operation control circuit 134 has a precharge controller 134a and an internal operation memory controller 134b, and the precharge controller 134a is electrically connected to the operation clock control circuit 131 to receive the operation signal OP and the reverse read write signal Dffwrb, and the precharge controller 134a outputs an operation bit control signal sc and a precharge bit control signal pcc, since the in-memory operation requires the inverse carry value line 11, The inverse-OR line 12 and the sum-value line 13 are precharged before switching the 2T switch unit groups 112. Therefore, the precharge controller 134a uses a delay element to make the precharge bit control signal pcc first. After triggering the precharging circuit 113 to perform precharging, the 2T switch unit group 112 is triggered by the operation bit control signal sc.

該內運算記憶體控制器134b電性連接該預充電控制器134a、該自動預充電切換控制電路132及該位址選擇電路133,該內運算記憶體控制器134b接收該運算位元控制訊號sc、該預充電位元控制訊號pcc、該預充電觸發訊號PreC_bit、該運算位址控制訊號w0及該進位位址控制訊號w2,且該內運算記憶體控制器134b輸出該預充電控制訊號PreC、該邏輯運算控制訊號C及該進位運算控制訊號S。其中,該內運算記憶體控制器134b讓該預充電觸發訊號PreC_bit由該預充電位元控制訊號pcc觸發而得到該預充電控制訊號PreC,並讓該運算位址控制訊號w0及該進位位址控制訊號w2由該運算位元控制訊號sc觸發而得到該邏輯運算控制訊號C及該進位運算控制訊號S,該預充電控制訊號PreC用以對該些預充電電路進行控制,該邏輯運算控制訊號C及該進位運算控制訊號S則用以對該些2T開關單元組112進行控制,以將對其中兩個該記憶體單元111的儲存數據進行運算。The internal operation memory controller 134b is electrically connected to the precharge controller 134a, the automatic precharge switch control circuit 132 and the address selection circuit 133, and the internal operation memory controller 134b receives the operation bit control signal sc , the precharge bit control signal pcc, the precharge trigger signal PreC_bit, the operation address control signal w0 and the carry address control signal w2, and the internal operation memory controller 134b outputs the precharge control signal PreC, The logic operation control signal C and the carry operation control signal S. The internal operation memory controller 134b makes the precharge trigger signal PreC_bit triggered by the precharge bit control signal pcc to obtain the precharge control signal PreC, and makes the operation address control signal w0 and the carry address The control signal w2 is triggered by the operation bit control signal sc to obtain the logic operation control signal C and the carry operation control signal S. The precharge control signal PreC is used to control the precharge circuits. The logic operation control signal C and the carry operation control signal S are used to control the 2T switch unit groups 112 to perform operations on the stored data of two of the memory units 111 .

請參閱第1圖,該自動切換寫回單元140電性連接該漣波進位運算單元120及該靜態隨機存取記憶體陣列110,以由該些漣波進位運算單元120接收該些運算數據,且該自動切換寫回單元140將該些運算數據寫回該靜態隨機存取記憶體陣列110之該些記憶體單元111中。Please refer to FIG. 1 , the automatic switching write-back unit 140 is electrically connected to the ripple carry operation unit 120 and the SRAM array 110 , so that the ripple carry operation units 120 receive the operation data, And the automatic switching write-back unit 140 writes back the operation data to the memory cells 111 of the SRAM array 110 .

請參閱第9圖,該自動切換寫回單元140具有一位元線自動切換電路141、一資料切換電路142及一字元線自動切換電路143,該位元線自動切換電路141電性連接該運算時脈控制電路131以接收該寫入選擇訊號Wrsel及該讀取寫入訊號Dffwr,且該位元線自動切換電路141輸出一位元線切換訊號BL_auto,在本實施例中,該自動切換寫回單元141具有一第十一正反器141a及一位元線計數器141b,該第十一正反器141a接收反向之該寫入選擇訊號Wrsel及反向之該讀取寫入訊號Dffwr,並以反向之該讀取寫入訊號Dffwr觸發該寫入選擇訊號Wrsel而輸出一位元線時脈訊號BL_Clk至該位元線計數器141b進行計數,該位元線計數器141b輸出該位元線切換訊號BL_auto,以決定欲存入之該記憶體單元111的欄數。Please refer to FIG. 9, the automatic switching write-back unit 140 has a bit line automatic switching circuit 141, a data switching circuit 142 and a word line automatic switching circuit 143, the bit line automatic switching circuit 141 is electrically connected to the The operation clock control circuit 131 receives the write selection signal Wrsel and the read write signal Dffwr, and the bit line automatic switching circuit 141 outputs a bit line switching signal BL_auto. In this embodiment, the automatic switching The write-back unit 141 has an eleventh flip-flop 141a and a one-bit line counter 141b. The eleventh flip-flop 141a receives the reverse write selection signal Wrsel and the reverse read write signal Dffwr , and trigger the write selection signal Wrsel with the reverse read write signal Dffwr to output a bit line clock signal BL_Clk to the bit line counter 141b for counting, and the bit line counter 141b outputs the bit line The line switching signal BL_auto is used to determine the number of columns of the memory cell 111 to be stored.

該字元線自動切換電路143電性連接該運算時脈控制電路131及該位址選擇電路133,該字元線自動切換電路143接收該加法運算訊號ADD、該乘法運算訊號MUL、該運算訊號OP、該反讀取寫入訊號Dffwrb、該符號位址訊號MS_add及該運算結果位址控制訊號CR_DFF,且該字元線自動切換電路143輸出一字元線切換訊號WL_auto。在本實施例中,該字元線自動切換電路143具有一及閘143a、一第十二正反器143b、一第一多工器143c、一第二多工器143d及一第三或閘143e。該及閘143a接收該反讀取寫入訊號Dffwrb及該運算訊號OP,該第十二正反器143b電性連接該及閘143a,且該第十二正反器143輸出一記憶體內運算選擇訊號CIM_datasel,該記憶體內運算選擇訊號CIM_datasel用以在加法運算中交替切換存入加法值、進位值以及在乘法運算中交替切換存入積值、符號值。The word line automatic switching circuit 143 is electrically connected to the operation clock control circuit 131 and the address selection circuit 133, and the word line automatic switching circuit 143 receives the addition operation signal ADD, the multiplication operation signal MUL, and the operation signal OP, the reverse read write signal Dffwrb, the symbol address signal MS_add, and the operation result address control signal CR_DFF, and the word line automatic switching circuit 143 outputs a word line switching signal WL_auto. In this embodiment, the word line automatic switching circuit 143 has an AND gate 143a, a twelfth flip-flop 143b, a first multiplexer 143c, a second multiplexer 143d and a third OR gate 143e. The AND gate 143a receives the reverse read and write signal Dffwrb and the operation signal OP, the twelfth flip-flop 143b is electrically connected to the AND gate 143a, and the twelfth flip-flop 143 outputs an in-memory operation selection The signal CIM_datasel, the in-memory operation selection signal CIM_datasel is used to alternately switch and store the addition value and the carry value in the addition operation, and alternately switch and store the product value and the sign value in the multiplication operation.

該第一多工器143c電性連接該第十二正反器143b,且該第一多工器接收該加法運算訊號ADD、該符號位址訊號MS_add、該運算結果位址控制訊號CR_DFF及該記憶體內運算選擇訊號CIM_datasel,當該加法訊算訊號ADD為高電位時,該第一多工器143c啟動,並由該記憶體內運算選擇訊號CIM_datasel選擇其輸出為該符號位址訊號MS_add或該運算結果位址控制訊號CR_DFF。該第二多工器143d電性連接該第十二正反器143b,且該第二多工器接收該乘法運算訊號MUL、該符號位址訊號MS_add、該運算結果位址控制訊號CR_DFF及該記憶體內運算選擇訊號CIM_datasel,當該乘法運算訊號MUL為高電位時,該第二多工器啟動,並由該記憶體內運算選擇訊號CIM_datasel其輸出為該符號位址訊號MS_add或該運算結果位址控制訊號CR_DFF。該第三或閘143e電性連接該第一多工器143c及該第二多工器143d,且該第三或閘143e輸出該字元線切換訊號WL_auto,以決定欲存入之該記憶體單元111的列數。The first multiplexer 143c is electrically connected to the twelfth flip-flop 143b, and the first multiplexer receives the addition operation signal ADD, the symbol address signal MS_add, the operation result address control signal CR_DFF and the The in-memory operation selection signal CIM_datasel, when the addition signal ADD is at a high level, the first multiplexer 143c is activated, and the in-memory operation selection signal CIM_datasel selects its output to be the symbol address signal MS_add or the operation The resulting address control signal CR_DFF. The second multiplexer 143d is electrically connected to the twelfth flip-flop 143b, and the second multiplexer receives the multiplication signal MUL, the symbol address signal MS_add, the operation result address control signal CR_DFF and the In-memory operation selection signal CIM_datasel, when the multiplication operation signal MUL is high, the second multiplexer is activated, and the in-memory operation selection signal CIM_datasel outputs the symbol address signal MS_add or the operation result address Control signal CR_DFF. The third OR gate 143e is electrically connected to the first multiplexer 143c and the second multiplexer 143d, and the third OR gate 143e outputs the word line switching signal WL_auto to determine the memory to be stored The number of columns of cell 111.

該資料切換電路142電性連接該位元線自動切換電路141及該漣波進位運算單元120,該資料切換電路142接收該位元線切換訊號BL_auto及該些運算數據,且該資料切換電路142輸出一記憶體內運算資料CIM_Data。在本實施例中,該資料切換電路142具有一第三多工器142a、一第四多工器142b、一第五多工器142c、一第六多工器142d、一第七多工器142e、一第八多工器142f、一第二及閘142g、一第三及閘142h及一第四或閘142i。該第三多工器142a接收該加法值SUM及該位元線切換訊號BL_auto,並依據該位元線切換訊號BL_auto輸出對應位元線之該加法值SUM。該第四多工器142b接收該進位值CO及該位元線切換訊號BL_auto,並依據該位元線切換訊號BL_auto輸出對應位元線之該進位值CO。該第五多工器142c接收該積值PRO及該位元線切換訊號BL_auto,並依據該位元線切換訊號BL_auto輸出對應位元線之該積值SUM。該第六多工器142d接收該符號值SIG及該位元線切換訊號BL_auto,並依據該位元線切換訊號BL_auto輸出對應位元線之該符號值SIG。The data switching circuit 142 is electrically connected to the bit line automatic switching circuit 141 and the ripple carry operation unit 120 , the data switching circuit 142 receives the bit line switching signal BL_auto and the operation data, and the data switching circuit 142 Output an in-memory operation data CIM_Data. In this embodiment, the data switching circuit 142 has a third multiplexer 142a, a fourth multiplexer 142b, a fifth multiplexer 142c, a sixth multiplexer 142d, and a seventh multiplexer 142e, an eighth multiplexer 142f, a second and gate 142g, a third and gate 142h, and a fourth OR gate 142i. The third multiplexer 142a receives the added value SUM and the bit line switching signal BL_auto, and outputs the added value SUM corresponding to the bit line according to the bit line switching signal BL_auto. The fourth multiplexer 142b receives the carry value CO and the bit line switching signal BL_auto, and outputs the carry value CO corresponding to the bit line according to the bit line switching signal BL_auto. The fifth multiplexer 142c receives the product value PRO and the bit line switching signal BL_auto, and outputs the product value SUM corresponding to the bit line according to the bit line switching signal BL_auto. The sixth multiplexer 142d receives the symbol value SIG and the bit line switching signal BL_auto, and outputs the symbol value SIG corresponding to the bit line according to the bit line switching signal BL_auto.

該第七多工器142e電性連接該第三多工器142a及該第四多工器142b,且該第七多工器142e接收該記憶體內運算選擇訊號CIM_datasel,該第七多工器142e輸出一加法運算結果訊號add_data,該加法運算結果訊號add_data由該記憶體內運算選擇訊號CIM_datasel切換為該加法值SUM或該進位值CO。該第八多工器142f電性連接該第五多工器142c及該第六多工器142d,且該第八多工器142f接收該記憶體內運算選擇訊號CIM_datasel,該第八多工器142f輸出一乘法運算結果訊號mul_data,該乘法運算結果訊號mul_data由該記憶體內運算選擇訊號CIM_datasel切換為該積值PRO或該符號值SIG。The seventh multiplexer 142e is electrically connected to the third multiplexer 142a and the fourth multiplexer 142b, and the seventh multiplexer 142e receives the in-memory operation selection signal CIM_datasel, and the seventh multiplexer 142e An addition operation result signal add_data is output, and the addition operation result signal add_data is switched to the addition value SUM or the carry value CO by the in-memory operation selection signal CIM_datasel. The eighth multiplexer 142f is electrically connected to the fifth multiplexer 142c and the sixth multiplexer 142d, and the eighth multiplexer 142f receives the in-memory operation selection signal CIM_datasel, and the eighth multiplexer 142f A multiplication result signal mul_data is output, and the multiplication result signal mul_data is switched to the product value PRO or the symbol value SIG by the in-memory operation selection signal CIM_datasel.

該第二及閘142g接收該加法運算結果訊號add_data及該加法運算訊號ADD,以由該加法運算訊號ADD啟動該第二及閘142g輸出該加法運算結果訊號add_data,該第三及閘142h接收該乘法運算結果訊號mul_data及該乘法運算訊號MUL,以由該乘法運算訊號MUL啟動該第三及閘142h輸出該乘法運算結果訊號mul_data。該第四或閘142i電性連接該第二及閘142g及該第三及閘142h,且該第四或閘輸出該記憶體內運算資料CIM_Data。The second and gate 142g receives the addition operation result signal add_data and the addition operation signal ADD, so that the second and gate 142g is activated by the addition operation signal ADD to output the addition operation result signal add_data, and the third and gate 142h receives the addition operation signal add_data For the multiplication result signal mul_data and the multiplication signal MUL, the third gate 142h is activated by the multiplication signal MUL to output the multiplication result signal mul_data. The fourth OR gate 142i is electrically connected to the second and gate 142g and the third and gate 142h, and the fourth OR gate outputs the in-memory operation data CIM_Data.

請參閱第1圖,該SRAM控制單元150接收一重置訊號rst、一字元位址訊號W_add、一位元位址訊號B_add、一輸入數據Data、該讀寫控制訊號wr_en及該時脈訊號Clk。於一般讀寫模式中,該SRAM控制單元150根據該重置訊號rst、該字元位址訊號W_add、該位元位址訊號B_add、該讀寫控制訊號wr_en及該時脈訊號clk輸出該些控制訊號WS、WA、WAB、WL及該預充電控制訊號PreD至該靜態隨機存取記憶體陣列110進行數據的寫入或讀取,並經由該欄選擇器160的選擇輸出為輸出數據Data_out。在記憶體內運算模式中,該SRAM控制單元150接收該自動切換寫回單元140之該位元線切換訊號BL_auto、該字元線切換訊號WL_auto及該記憶體內運算資料CIM_Data,以根據該位元線切換訊號BL_auto及該字元線切換訊號WL_auto輸出該些控制訊號WS、WA、WAB、WL控制該靜態隨機存取記憶體陣列110存入該記憶體內運算資料CIM_Data。Please refer to FIG. 1, the SRAM control unit 150 receives a reset signal rst, a word address signal W_add, a bit address signal B_add, an input data Data, the read/write control signal wr_en and the clock signal Clk. In the normal read/write mode, the SRAM control unit 150 outputs the reset signal rst, the word address signal W_add, the bit address signal B_add, the read/write control signal wr_en and the clock signal clk. The control signals WS, WA, WAB, WL and the precharge control signal PreD are sent to the SRAM array 110 for data writing or reading, and are selected by the column selector 160 and output as output data Data_out. In the in-memory operation mode, the SRAM control unit 150 receives the bit line switching signal BL_auto, the word line switching signal WL_auto, and the in-memory operation data CIM_Data of the automatic switching write-back unit 140, and according to the bit line The switching signal BL_auto and the word line switching signal WL_auto output the control signals WS, WA, WAB, WL to control the SRAM array 110 to store the in-memory operation data CIM_Data.

本發明藉由該運算控制單元130輸出之訊號控制該靜態隨機存取記憶體陣列110進行該些邏輯數據運算,並藉由該漣波進位運算單元120依據該些邏輯數據求得所需之該些運算數據,最後藉由該自動切換寫回單元140將該些運算數據寫回該靜態隨機存取記憶體陣列110中,由於直接於記憶體中完成運算,可突破運算瓶頸而大幅提高運算速度。In the present invention, the SRAM array 110 is controlled by the signal output from the operation control unit 130 to perform the logic data operations, and the ripple carry operation unit 120 is used to obtain the required logic data according to the logic data. Some operation data are finally written back to the SRAM array 110 by the automatic switching write-back unit 140. Since the operation is directly completed in the memory, the operation bottleneck can be broken and the operation speed can be greatly improved .

本發明之保護範圍當視後附之申請專利範圍所界定者為準,任何熟知此項技藝者,在不脫離本發明之精神和範圍內所作之任何變化與修改,均屬於本發明之保護範圍。The protection scope of the present invention shall be determined by the scope of the appended patent application. Any changes and modifications made by anyone who is familiar with the art without departing from the spirit and scope of the present invention shall fall within the protection scope of the present invention. .

100:記憶體內運算系統110:靜態隨機存取記憶體陣列 111:記憶體單元Q:儲存節點 Qb:反儲存節點112:2T開關單元組 112a:進位值2T開關112b:反或值2T開關 112c:及值2T開關113:預充電電路 120:漣波進位運算單元121:邏輯計算電路 122:加法電路123:進位電路 130:運算控制單元131:運算時脈控制電路 131a:第一或閘131b:第一正反器 131c第二正反器131d:第三正反器 131e:第四正反器132:自動預充電切換控制電路 132a:第五正反器132b:第六正反器 132c:計數器132d:第一解碼器 133:位址選擇電路133a:第七正反器 133b:第八正反器133c:第九正反器 133d:第十正反器133e:第二解碼器 133f:第三解碼器133g:第四解碼器 133h:第二或閘134:內運算控制電路 134a:預充電控制器134b:內運算記憶體控制器 140:自動切換寫回單元141:位元線自動切換電路 141a:第十一正反器141b:位元線計數器 142:資料切換電路142a:第三多工器 142b:第四多工器142c:第五多工器 142d:第六多工器142e:第七多工器 142f:第八多工器142g:第二及閘 142h:第三及閘142i:第四或閘 143:字元線自動切換電路143a:及閘 143b:第十二正反器143c:第一多工器 143d:第二多工器143e:第三或閘 150:SRAM控制單元160:欄選擇器 11:反進位值線12:反或值線 13:及值線14:反位元線 15:位元線SUM:加法值 CO:進位值ADD:加法運算訊號 MUL:乘法運算單元Clk:時脈訊號 OP:運算訊號Opprec:總運算訊號 Wrsel:寫入選擇訊號Dffwrb:反讀取寫入訊號 PreC_bit:預充電觸發訊號OpX_add:第一運算位址訊號 OpY_add:第二運算位址訊號MS_add:符號位址訊號 CR_add:運算結果位址訊號w0:運算位址控制訊號 w2:進位位址控制訊號CR_DFF:運算結果位址控制訊號 PreC:預充電控制訊號C:邏輯運算控制訊號 S:進位運算控制訊號wr_en:讀寫控制訊號 Dffwr:讀取寫入訊號Cimp:計數啟動訊號 PreCclk:預充電時脈訊號ct:計數訊號 OpX:第一運算列訊號OpY:第二運算列訊號 MS:進位列訊號sc:運算位元控制訊號 pcc:預充電位元控制訊號BL_auto:位元線控制訊號 CIM_Data:記憶體內運算資料WL_auto:字元線切換訊號 MP201~202:P型電晶體MN201~206:N型電晶體 WS、WA、WAB、WL:控制訊號PRO:積值 SIG:符號值add_data:加法運算結果訊號 mul_data:乘法運算結果訊號Data_out:輸出數據 BL_Clk:位元線時脈訊號CIM_datasel:記憶體內運算選擇訊號 CB:反進位值NOR:反或值 AND:及值NAND:反及值 XNOR:反互斥或值XOR:互斥或值 Cl:進位值rst:重置訊號 W_add:字元位址訊號B_add:位元位址訊號 Data:輸入數據PreD:預放電控制訊號 100: In-Memory Computing System 110: Static Random Access Memory Array 111: memory unit Q: storage node Qb: Anti-storage node 112: 2T switch cell group 112a: carry value 2T switch 112b: reverse or value 2T switch 112c: Sum value 2T switch 113: Precharge circuit 120: Ripple carry operation unit 121: Logic calculation circuit 122: Addition circuit 123: Carry circuit 130: Operation control unit 131: Operation clock control circuit 131a: first or gate 131b: first flip-flop 131c second flip-flop 131d: third flip-flop 131e: fourth flip-flop 132: automatic precharge switching control circuit 132a: fifth flip-flop 132b: sixth flip-flop 132c: counter 132d: first decoder 133: address selection circuit 133a: seventh flip-flop 133b: Eighth flip-flop 133c: Ninth flip-flop 133d: Tenth flip-flop 133e: Second decoder 133f: Third Decoder 133g: Fourth Decoder 133h: Second OR gate 134: Internal operation control circuit 134a: precharge controller 134b: internal computing memory controller 140: Auto switch write back unit 141: Bit line auto switch circuit 141a: Eleventh flip-flop 141b: Bit line counter 142: data switching circuit 142a: third multiplexer 142b: Fourth multiplexer 142c: Fifth multiplexer 142d: sixth multiplexer 142e: seventh multiplexer 142f: Eighth Multiplexer 142g: Second and Gate 142h: third and gate 142i: fourth or gate 143: word line automatic switching circuit 143a: and gate 143b: Twelfth Flip-Flop 143c: First Multiplexer 143d: second multiplexer 143e: third OR gate 150: SRAM control unit 160: Column selector 11: Inverted carry value line 12: Inverted OR value line 13: Sum value line 14: Inverse bit line 15: bit line SUM: added value CO: Carry value ADD: Addition signal MUL: Multiplication unit Clk: Clock signal OP: operation signal Opprec: total operation signal Wrsel: write selection signal Dffwrb: reverse read write signal PreC_bit: Precharge trigger signal OpX_add: First operation address signal OpY_add: Second operation address signal MS_add: Symbol address signal CR_add: Operation result address signal w0: Operation address control signal w2: Carry address control signal CR_DFF: Operation result address control signal PreC: Precharge control signal C: Logic operation control signal S: carry operation control signal wr_en: read and write control signal Dffwr: read write signal Cimp: count start signal PreCclk: Precharge clock signal ct: Counting signal OpX: The first operation line signal OpY: The second operation line signal MS: Carry column signal sc: Operation bit control signal pcc: precharge bit control signal BL_auto: bit line control signal CIM_Data: In-memory operation data WL_auto: Word line switching signal MP201~202: P-type transistor MN201~206: N-type transistor WS, WA, WAB, WL: Control signal PRO: Product value SIG: Symbol value add_data: Addition result signal mul_data: Multiplication result signal Data_out: Output data BL_Clk: Bit line clock signal CIM_datasel: In-memory operation selection signal CB: Inverted carry value NOR: Inverted or value AND: and value NAND: inverse and value XNOR: anti-mutual exclusion or value XOR: mutual exclusion or value Cl: carry value rst: reset signal W_add: character address signal B_add: bit address signal Data: Input data PreD: Pre-discharge control signal

第1圖:依據本發明之一實施例,一記憶體內運算系統的功能方塊圖。 第2圖:依據本發明之一實施例,一靜態隨機存取記憶體陣列的電路圖。 第3圖:依據本發明之一實施例,該靜態隨機存取記憶體陣列的局部電路圖。 第4圖:依據本發明之一實施例,一記憶體單元的電路圖。 第5圖:依據本發明之一實施例,一進位值2T開關的作動示意圖。 第6圖:依據本發明之一實施例,一反或值2T開關及一及值2T開關的作動示意圖。 第7圖:依據本發明之一實施例,一漣波進位運算單元的電路圖。 第8圖:依據本發明之一實施例,一運算控制單元的電路圖。 第9圖:依據本發明之一實施例,一自動切換寫回單元的電路圖。 FIG. 1 is a functional block diagram of an in-memory computing system according to an embodiment of the present invention. Figure 2: A circuit diagram of a SRAM array according to an embodiment of the present invention. Figure 3: A partial circuit diagram of the SRAM array according to an embodiment of the present invention. Figure 4: A circuit diagram of a memory cell according to an embodiment of the present invention. FIG. 5 is a schematic diagram of the operation of a 2T switch with a carry value according to an embodiment of the present invention. FIG. 6 is a schematic diagram of the operation of an inverse-or-value 2T switch and a sum-value 2T switch according to an embodiment of the present invention. FIG. 7 is a circuit diagram of a ripple carry operation unit according to an embodiment of the present invention. Fig. 8: A circuit diagram of an arithmetic control unit according to an embodiment of the present invention. Figure 9: A circuit diagram of an automatic switching write-back unit according to an embodiment of the present invention.

100:記憶體內運算系統 100: In-Memory Computing System

110:靜態隨機存取記憶體陣列 110: Static random access memory array

120:漣波進位運算單元 120: Ripple carry operation unit

130:運算控制單元 130: Operation control unit

140:自動切換寫回單元 140: Auto switch write back unit

150:SRAM控制單元 150: SRAM control unit

160:欄選擇器 160: Column selector

SUM:加法值 SUM: Summation value

CO:進位值 CO: carry value

ADD:加法運算訊號 ADD: Addition signal

MUL:乘法運算單元 MUL: Multiplication unit

Clk:時脈訊號 Clk: Clock signal

Wrsel:寫入選擇訊號 Wrsel: write select signal

Dffwrb:反讀取寫入訊號 Dffwrb: reverse read write signal

OpX_add:第一運算位址訊號 OpX_add: The first operation address signal

OpY_add:第二運算位址訊號 OpY_add: The second operation address signal

MS_add:符號位址訊號 MS_add: Symbol address signal

CR_add:運算結果位址訊號 CR_add: Operation result address signal

CR_DFF:運算結果位址控制訊號 CR_DFF: Operation result address control signal

PreC:預充電控制訊號 PreC: Precharge control signal

C:邏輯運算控制訊號 C: logic operation control signal

S:進位運算控制訊號 S: carry operation control signal

wr_en:讀寫控制訊號 wr_en: read and write control signal

BL_auto:位元線控制訊號 BL_auto: bit line control signal

CIM_Data:記憶體內運算資料 CIM_Data: In-memory operation data

WL_auto:字元線切換訊號 WL_auto: word line switching signal

WS、WA、WAB、WL:控制訊號 WS, WA, WAB, WL: Control signal

PRO:積值 PRO: product value

SIG:符號值 SIG: symbol value

Data_out:輸出數據 Data_out: output data

BL_Clk:位元線時脈訊號 BL_Clk: bit line clock signal

CB:反進位值 CB: reverse carry value

NOR:反或值 NOR: Negative or value

AND:及值 AND: and value

rst:重置訊號 rst: reset signal

W_add:字元位址訊號 W_add: character address signal

B_add:位元位址訊號 B_add: bit address signal

Data:輸入數據 Data: input data

PreD:預放電控制訊號 PreD: Pre-discharge control signal

Claims (9)

一種記憶體內運算系統,其包含:一靜態隨機存取記憶體陣列,具有複數個記憶體單元、複數個2T開關單元組及一預充電電路,各該記憶體單元具有一儲存節點及一反儲存節點,各該2T開關單元組電性連接各該記憶體單元之該儲存節點及該反儲存節點,該預充電電路電性連接該些2T開關單元組,該些2T開關單元組輸出複數個邏輯數據;一漣波進位運算單元,電性連接該些2T開關單元組以接收該些邏輯數據,該漣波進位運算單元具有一邏輯計算電路、一加法電路及一進位電路,該邏輯計算電路電性連接該些2T開關單元組以接收該些邏輯數據,且該邏輯計算電路根據該些邏輯數據輸出複數個邏輯運算數據,該加法電路電性連接該些2T開關組及該邏輯計算電路以接收該些邏輯數據及該些邏輯運算數據,且該加法單元根據該些邏輯數據及該些邏輯運算數據輸出一加法值,該進位電路電性連接該些2T開關單元組及該邏輯計算電路以接收該邏輯數據及該些邏輯運算數據,且該進位電路根據該邏輯數據及該些該些邏輯運算數據輸出一進位值;一運算控制單元,電性連接該靜態隨機存取記憶體陣列,該運算控制單元用以輸出複數個控制訊號至該預充電電路及該些2T開關單元組,以控制該預充電電路及各該2T開關單元組的開啟或關閉;以及一自動切換寫回單元,電性連接該漣波進位運算單元,以由該漣波進位運算單元接收該加法值及進位值,且該自動切換寫回單元經由一SRAM控制單元將該加法值及進位值寫回該靜態隨機存取記憶體陣列之該些記憶體單元中。 An in-memory computing system, comprising: a static random access memory array having a plurality of memory units, a plurality of 2T switch unit groups and a pre-charging circuit, each of the memory units having a storage node and an inverse storage nodes, each of the 2T switch unit groups is electrically connected to the storage node and the inverse storage node of each of the memory cells, the precharge circuit is electrically connected to the 2T switch unit groups, and the 2T switch unit groups output a plurality of logic data; a ripple carry operation unit electrically connected to the 2T switch unit groups to receive the logic data, the ripple carry operation unit has a logic calculation circuit, an addition circuit and a carry circuit, the logic calculation circuit is electrically The 2T switch unit groups are electrically connected to receive the logic data, and the logic calculation circuit outputs a plurality of logic operation data according to the logic data, and the addition circuit is electrically connected to the 2T switch groups and the logic calculation circuit to receive the logic data and the logic operation data, the addition unit outputs an addition value according to the logic data and the logic operation data, the carry circuit is electrically connected to the 2T switch unit groups and the logic calculation circuit for receiving the logic data and the logic operation data, and the carry circuit outputs a carry value according to the logic data and the logic operation data; an operation control unit electrically connected to the SRAM array, the operation control unit The unit is used for outputting a plurality of control signals to the precharge circuit and the 2T switch unit groups to control the precharge circuit and each of the 2T switch unit groups to be turned on or off; and an automatic switching write-back unit, which is electrically connected The ripple carry operation unit receives the addition value and the carry value from the ripple carry operation unit, and the automatic switching write-back unit writes the addition value and the carry value back to the static random access memory via an SRAM control unit in the memory cells of the bulk array. 如請求項1之記憶體內運算系統,其中各該2T開關單元組具有一進位值2T開關、一反或值2T開關及一及值2T開關,該進位值2T開關電性連接該 記憶體單元之該儲存節點及一反進位值線,該反或值2T開關電性連接該記憶體單元之該儲存節點及一反或值線,該及值2T開關電性連接該記憶體單元之該反儲存節點及一及值線。 The in-memory computing system of claim 1, wherein each of the 2T switch unit groups has a carry-value 2T switch, an inverse-or-value 2T switch, and a sum-value 2T switch, and the carry-value 2T switch is electrically connected to the The storage node of the memory cell and an inverse carry value line, the inverse-OR 2T switch is electrically connected to the storage node of the memory cell and an inverse-OR value line, the sum-value 2T switch is electrically connected to the memory cell the inverse storage node and a sum value line. 如請求項2之記憶體內運算系統,其中進行記憶體內運算時,其中一個該進位值2T開關及其中兩個該反或值2T開關及該及值2T開關開啟,其餘之該些進位值2T開關、該些反或值2T開關及該些及值2T開關關閉。 The in-memory computing system of claim 2, wherein when performing in-memory operations, one of the carry value 2T switches and two of the inverse-OR 2T switches and the sum value 2T switch are turned on, and the rest of the carry value 2T switches are turned on. , the inverse-or value 2T switches and the sum value 2T switches are closed. 如請求項1之記憶體內運算系統,其中該運算控制單元具有一運算時脈控制電路、一自動預充電切換控制電路、一位址選擇電路及一內運算控制電路,該運算時脈控制電路用以接收一加法運算訊號、一乘法運算訊號及一時脈訊號,且該運算時脈控制電路輸出一運算訊號、一總運算訊號、一寫入選擇訊號及一反讀取寫入訊號,該自動預充電切換控制電路電性連接該運算時脈控制電路以接收該總運算訊號、該寫入選擇訊號及該反讀取寫入訊號,且該自動預充電切換控制電路輸出一預充電觸發訊號,該位址選擇電路電性連接該運算時脈控制電路以接收該運算訊號,該位址選擇電路另接收一第一運算位址訊號、一第二運算位址訊號、一符號位址訊號及一運算結果位址訊號,且該位址選擇電路輸出一運算位址控制訊號、一進位位址控制訊號及一運算結果位址控制訊號,該內運算控制電路電性連接該運算時脈控制電路、該自動預充電切換控制電路及該位址選擇電路以接收該運算訊號、該反讀取寫入訊號、該預充電觸發訊號、該運算位址控制訊號及該進位位址控制訊號,且該內運算控制電路輸出一預充電控制訊號、一邏輯運算控制訊號及一進位運算控制訊號至該預充電電路及該些2T開關單元組。 The in-memory computing system of claim 1, wherein the computing control unit has an computing clock control circuit, an automatic precharge switching control circuit, an address selection circuit, and an internal computing control circuit, and the computing clock control circuit uses In order to receive an addition operation signal, a multiplication operation signal and a clock signal, and the operation clock control circuit outputs an operation signal, a total operation signal, a write selection signal and an inverse read write signal, the automatic presetting The charging switch control circuit is electrically connected to the operation clock control circuit to receive the total operation signal, the write selection signal and the reverse read write signal, and the automatic precharge switch control circuit outputs a precharge trigger signal. The address selection circuit is electrically connected to the operation clock control circuit to receive the operation signal, and the address selection circuit further receives a first operation address signal, a second operation address signal, a symbol address signal and an operation The result address signal, and the address selection circuit outputs an operation address control signal, a carry address control signal and an operation result address control signal, the internal operation control circuit is electrically connected to the operation clock control circuit, the The automatic precharge switching control circuit and the address selection circuit receive the operation signal, the reverse read and write signal, the precharge trigger signal, the operation address control signal and the carry address control signal, and the internal operation The control circuit outputs a precharge control signal, a logic operation control signal and a carry operation control signal to the precharge circuit and the 2T switch unit groups. 如請求項4之記憶體內運算系統,其中該運算時脈控制電路具有 一第一或閘、一第一正反器、一第二正反器、一第三正反器及一第四正反器,該第一或閘接收該加法運算訊號及該乘法運算訊號,且該第一或閘輸出該運算訊號,該第一正反器接收一讀寫控制訊號及該時脈訊號,且該第一正反器輸出一讀取寫入訊號,該第二正反器電性連接該第一或閘,該第二正反器接收該時脈訊號及該運算訊號,且該第二正反器輸出該總運算訊號,該第三正反器電性連接該第一或閘及該第一正反器以接收該運算訊號及該讀取寫入訊號,且該第三正反器輸出該寫入選擇訊號,該第四正反器電性連接第一正反器,該第四正反器接收該讀取寫入訊號及該時脈訊號,且該第四正反器輸出該反讀取寫入訊號。 The in-memory computing system of claim 4, wherein the computing clock control circuit has a first OR gate, a first flip-flop, a second flip-flop, a third flip-flop and a fourth flip-flop, the first OR gate receives the addition operation signal and the multiplication operation signal, And the first OR gate outputs the operation signal, the first flip-flop receives a read-write control signal and the clock signal, and the first flip-flop outputs a read-write signal, the second flip-flop The first or gate is electrically connected, the second flip-flop receives the clock signal and the operation signal, the second flip-flop outputs the total operation signal, and the third flip-flop is electrically connected to the first The OR gate and the first flip-flop receive the operation signal and the read-write signal, the third flip-flop outputs the write-select signal, and the fourth flip-flop is electrically connected to the first flip-flop , the fourth flip-flop receives the read-write signal and the clock signal, and the fourth flip-flop outputs the reverse read-write signal. 如請求項4之記憶體內運算系統,其中該自動預充電時脈控制電路具有一第五正反器、一第六正反器、一計數器及一第一解碼器,該第五正反器電性連接運算時脈控制電路以接收該總運算訊號及該運算訊號,且該第五正反器輸出一計數啟動訊號,該第六正反器電性連接該第三正反器及該第四正反器以接收該寫入選擇訊號及該反讀取寫入訊號,且該第六正反器輸出一預充電時脈訊號,該計數器電性連接該第五正反器及該第六正反器以接收該計數啟動訊號及該預充電時脈訊號,且該計數器輸出一計數訊號,該第一解碼器電性連接該計數器以接收該計數訊號,且該第一解碼器輸出該預充電觸發訊號。 The in-memory computing system of claim 4, wherein the automatic precharge clock control circuit has a fifth flip-flop, a sixth flip-flop, a counter and a first decoder, and the fifth flip-flop is electrically is electrically connected to the operation clock control circuit to receive the total operation signal and the operation signal, and the fifth flip-flop outputs a count start signal, and the sixth flip-flop is electrically connected to the third flip-flop and the fourth flip-flop The flip-flop receives the write selection signal and the reverse read write signal, and the sixth flip-flop outputs a precharge clock signal, and the counter is electrically connected to the fifth flip-flop and the sixth flip-flop The inverter receives the count start signal and the precharge clock signal, and the counter outputs a count signal, the first decoder is electrically connected to the counter to receive the count signal, and the first decoder outputs the precharge trigger signal. 如請求項5之記憶體內運算系統,其中該位址選擇電路具有一第七正反器、一第八正反器、一第九正反器、一第十正反器、一第二解碼器、一第三解碼器、一第四解碼器及一第二或閘,該第七正反器電性連接該第一或閘,該第七正反器接收該運算訊號及該第一運算位址訊號,且該第七正反器輸出一第一運算列訊號,該第八正反器電性連接該第一或閘,該第八正反器接收該運算訊號及該第二運算位址訊號,且該第八正反器輸出一第二運算列訊號,該第九正反 器電性連接該第一或閘,該第九正反器接收該運算訊號及該符號位址訊號,且該第九正反器輸出一進位列訊號,該第十正反器電性連接該第一或閘,該第十正反器接收該運算訊號及該預算結果位址訊號,且該第十正反器輸出該運算結果位址控制訊號,該第二解碼器電性連接該第七正反器以接收該第一運算列訊號,且該第二解碼器輸出一第一解碼訊號,該第三解碼器電性連接該第八正反器以接收該第二運算列訊號,且該第三解碼器輸出一第二解碼訊號,該第四解碼器電性連接該第九正反器以接收該進位列訊號,且該第四解碼器輸出該進位位址控制訊號,該第二或閘電性連接該第一解碼器及該第二解碼器以接收該第一解碼訊號及該第二解碼訊號,且該第二或閘輸出該運算位址控制訊號。 The in-memory computing system of claim 5, wherein the address selection circuit has a seventh flip-flop, an eighth flip-flop, a ninth flip-flop, a tenth flip-flop, and a second decoder , a third decoder, a fourth decoder and a second OR gate, the seventh flip-flop is electrically connected to the first OR gate, and the seventh flip-flop receives the operation signal and the first operation bit address signal, and the seventh flip-flop outputs a first operation column signal, the eighth flip-flop is electrically connected to the first OR gate, and the eighth flip-flop receives the operation signal and the second operation address signal, and the eighth flip-flop outputs a second operation column signal, the ninth flip-flop The ninth flip-flop is electrically connected to the first OR gate, the ninth flip-flop receives the operation signal and the symbol address signal, and the ninth flip-flop outputs a carry column signal, and the tenth flip-flop is electrically connected The first OR gate, the tenth flip-flop receive the operation signal and the estimated result address signal, and the tenth flip-flop outputs the operation result address control signal, and the second decoder is electrically connected to the first Seven flip-flops receive the first operational column signal, the second decoder outputs a first decoding signal, the third decoder is electrically connected to the eighth flip-flop to receive the second operational column signal, and The third decoder outputs a second decoded signal, the fourth decoder is electrically connected to the ninth flip-flop to receive the carry column signal, and the fourth decoder outputs the carry address control signal, the first The second OR gate is electrically connected to the first decoder and the second decoder to receive the first decoded signal and the second decoded signal, and the second OR gate outputs the operation address control signal. 如請求項5之記憶體內運算系統,該內運算控制電路具有一預充電控制器及一內運算記憶體控制器,該預充電控制器電性連接該運算時脈控制電路以接收該運算訊號及該反讀取寫入訊號,且該預充電控制器輸出一運算位元控制訊號及一預充電位元控制訊號,該內運算記憶體控制器電性連接該預充電控制器、該自動預充電切換控制電路及該位址選擇電路,該內運算記憶體控制器接收該運算位元控制訊號、該預充電位元控制訊號、該預充電觸發訊號、該運算位址控制訊號及該進位位址控制訊號,且該內運算記憶體控制器輸出該預充電控制訊號、該邏輯運算控制訊號及該進位運算控制訊號。 As claimed in the in-memory computing system of claim 5, the internal computing control circuit has a precharge controller and an internal computing memory controller, the precharge controller is electrically connected to the computing clock control circuit to receive the computing signal and The reverse read and write signal, and the precharge controller outputs an operation bit control signal and a precharge bit control signal, the internal operation memory controller is electrically connected to the precharge controller, the automatic precharge a switching control circuit and the address selection circuit, the internal operation memory controller receives the operation bit control signal, the precharge bit control signal, the precharge trigger signal, the operation address control signal and the carry address a control signal, and the internal operation memory controller outputs the precharge control signal, the logic operation control signal and the carry operation control signal. 如請求項4之記憶體內運算系統,其中該自動切換寫回單元具有一位元線自動切換電路、一資料切換電路及一字元線自動切換電路,該位元線自動切換電路電性連接該運算時脈控制電路以接收該寫入選擇訊號及該讀取寫入訊號,且該位元線自動切換電路輸出一位元線切換訊號,該資料切換電路電性連接該位元線自動切換電路及該漣波進位運算單元,該資料切換電路接收該位元 線切換訊號及該些運算數據,且該資料切換電路輸出一記憶體內運算資料,該字元線自動切換電路電性連接該運算時脈控制電路及該位址選擇電路,該字元線自動切換電路接收該加法運算訊號、該乘法運算訊號、該運算訊號、該反讀取寫入訊號、該符號位址訊號及該運算結果位址控制訊號,且該字元線自動切換電路輸出一字元線切換訊號。 The in-memory computing system of claim 4, wherein the automatic switching write-back unit has a bit line automatic switching circuit, a data switching circuit and a word line automatic switching circuit, and the bit line automatic switching circuit is electrically connected to the The operation clock control circuit receives the write selection signal and the read write signal, and the bit line automatic switching circuit outputs a bit line switching signal, and the data switching circuit is electrically connected to the bit line automatic switching circuit and the ripple carry operation unit, the data switching circuit receives the bit The line switching signal and the operation data, and the data switching circuit outputs an in-memory operation data, the word line automatic switching circuit is electrically connected to the operation clock control circuit and the address selection circuit, and the word line automatically switches The circuit receives the addition operation signal, the multiplication operation signal, the operation signal, the reverse read write signal, the symbol address signal and the operation result address control signal, and the word line automatic switching circuit outputs a word line switching signal.
TW110118502A 2021-05-21 2021-05-21 In-memory computation system TWI772034B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW110118502A TWI772034B (en) 2021-05-21 2021-05-21 In-memory computation system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW110118502A TWI772034B (en) 2021-05-21 2021-05-21 In-memory computation system

Publications (2)

Publication Number Publication Date
TWI772034B true TWI772034B (en) 2022-07-21
TW202247012A TW202247012A (en) 2022-12-01

Family

ID=83439709

Family Applications (1)

Application Number Title Priority Date Filing Date
TW110118502A TWI772034B (en) 2021-05-21 2021-05-21 In-memory computation system

Country Status (1)

Country Link
TW (1) TWI772034B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW200504998A (en) * 2003-05-09 2005-02-01 Toshiba Kk Semiconductor memory device
TW201015574A (en) * 2008-10-14 2010-04-16 Hynix Semiconductor Inc Trimming circuit of semiconductor memory apparatus and trimming method thereof
TW201839775A (en) * 2017-01-03 2018-11-01 慧榮科技股份有限公司 Method for performing data management in memory device, and associated memory device and controller thereof
TW202044263A (en) * 2019-05-27 2020-12-01 國立中山大學 In-memory computation system and memory device thereof

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW200504998A (en) * 2003-05-09 2005-02-01 Toshiba Kk Semiconductor memory device
TW201015574A (en) * 2008-10-14 2010-04-16 Hynix Semiconductor Inc Trimming circuit of semiconductor memory apparatus and trimming method thereof
TW201839775A (en) * 2017-01-03 2018-11-01 慧榮科技股份有限公司 Method for performing data management in memory device, and associated memory device and controller thereof
TW202044263A (en) * 2019-05-27 2020-12-01 國立中山大學 In-memory computation system and memory device thereof

Also Published As

Publication number Publication date
TW202247012A (en) 2022-12-01

Similar Documents

Publication Publication Date Title
US11335387B2 (en) In-memory computing circuit for fully connected binary neural network
TWI570716B (en) Memory apparatus and method of operation
CN112581996A (en) Time domain memory computing array structure based on magnetic random access memory
US7990759B2 (en) Hardened memory cell
CN112558919B (en) Memory computing bit unit and memory computing device
CN111429956B (en) Multi-mode calculable SRAM unit circuit and control method thereof
CN116364137A (en) Same-side double-bit-line 8T unit, logic operation circuit and CIM chip
TWI772034B (en) In-memory computation system
CN112951290B (en) Memory computing circuit and device based on nonvolatile random access memory
CN116340256A (en) In-memory computing unit and array based on SRAM (static random Access memory) with DICE (digital computer aided design) structure
Izhar et al. Logic Circuit Implementation for Enabling SRAM Based In Memory Computing
CN111105830A (en) Memory device
Bagamma et al. Implementation of 5–32 address decoders for SRAM memory in 180nm technology
Monga et al. A Novel Decoder Design for Logic Computation in SRAM: CiM-SRAM
TWI706414B (en) In-memory computation system and memory device thereof
TW202219955A (en) Pseudo-triple-port sram datapaths
CN116670763A (en) In-memory computation bit cell with capacitively coupled write operation
US7366032B1 (en) Multi-ported register cell with randomly accessible history
CN108597555B (en) NAND operation circuit, memory chip and computer of memory area calculation
CN117577162B (en) Redundant address register structure, redundant address register array and memory
JP3910650B2 (en) Semiconductor memory device
US11763866B1 (en) SRAM with scan mode
TW202333153A (en) Pseudo-dual-port sram with burst-mode address comparator
CN113921057A (en) 8T SRAM circuit structure for realizing iterative XOR calculation in memory
US20230127502A1 (en) Memory cell and method of operating the same