WO2022010015A1 - 프로세싱인메모리의 메모리 관리 방법 및 장치 - Google Patents
프로세싱인메모리의 메모리 관리 방법 및 장치 Download PDFInfo
- Publication number
- WO2022010015A1 WO2022010015A1 PCT/KR2020/009163 KR2020009163W WO2022010015A1 WO 2022010015 A1 WO2022010015 A1 WO 2022010015A1 KR 2020009163 W KR2020009163 W KR 2020009163W WO 2022010015 A1 WO2022010015 A1 WO 2022010015A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- memory
- address
- command
- pim
- instruction
- Prior art date
- Legal status (The legal status 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 status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/14—Handling requests for interconnection or transfer
- G06F13/16—Handling requests for interconnection or transfer for access to memory bus
- G06F13/1605—Handling requests for interconnection or transfer for access to memory bus based on arbitration
- G06F13/1642—Handling requests for interconnection or transfer for access to memory bus based on arbitration with request queuing
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/14—Handling requests for interconnection or transfer
- G06F13/16—Handling requests for interconnection or transfer for access to memory bus
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/14—Handling requests for interconnection or transfer
- G06F13/16—Handling requests for interconnection or transfer for access to memory bus
- G06F13/1605—Handling requests for interconnection or transfer for access to memory bus based on arbitration
- G06F13/161—Handling requests for interconnection or transfer for access to memory bus based on arbitration with latency improvement
- G06F13/1626—Handling requests for interconnection or transfer for access to memory bus based on arbitration with latency improvement by reordering requests
- G06F13/1631—Handling requests for interconnection or transfer for access to memory bus based on arbitration with latency improvement by reordering requests through address comparison
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F15/00—Digital computers in general; Data processing equipment in general
- G06F15/76—Architectures of general purpose stored program computers
- G06F15/78—Architectures of general purpose stored program computers comprising a single central processing unit
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F15/00—Digital computers in general; Data processing equipment in general
- G06F15/76—Architectures of general purpose stored program computers
- G06F15/78—Architectures of general purpose stored program computers comprising a single central processing unit
- G06F15/7807—System on chip, i.e. computer system on a single chip; System in package, i.e. computer system on one or more chips in a single package
- G06F15/7821—Tightly coupled to memory, e.g. computational memory, smart memory, processor in memory
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0602—Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
- G06F3/061—Improving I/O performance
- G06F3/0611—Improving I/O performance in relation to response time
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0655—Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
- G06F3/0659—Command handling arrangements, e.g. command buffers, queues, command scheduling
Definitions
- the present invention relates to a processing in memory (PIM), and more particularly, to a memory controller inside a PIM device.
- PIM processing in memory
- the present invention relates to a memory control method for minimizing a transaction time of a PIM internal memory and a hardware structure of a PIM for the same.
- Processing-in-memory is a memory in which a memory and a processing unit are integrated into a single chip, and improves system performance and power efficiency by reducing the frequency at which the processor accesses the memory for operation.
- the processing-in-memory approach of the processor uses an instruction signal for operation in addition to the address and data signals, unlike the traditional memory access method.
- the processing-in-memory arithmetic unit has complicated hardware because it processes instructions received from the processor, and thus the performance of the processing-in-memory memory is degraded.
- An object of the present invention is to improve PIM performance by reducing unnecessary DRAM access time of processing-in-memory (PIM) as a memory management method for maximizing PIM performance.
- PIM processing-in-memory
- the present invention provides an open page hit ratio of an internal memory (eg, DRAM) by changing the processing order of a memory address directly or implicitly included in a processing-in-memory (PIM) command (PIM operations).
- PIM processing-in-memory
- open page hit rate is improved.
- the command processing unit processes the PIM command packet, it processes the destination address access request with a high probability of sequentially reading and writing the internal memory with a lower priority.
- the row-address of an open page in the internal memory can match the row address to which the PIM command packet processing result is returned.
- the present invention minimizes the performance loss that occurs in an open page miss situation of the internal memory by identifying the memory addresses directly and implicitly included in the PIM command in advance in the command processing device and notifying the memory controller.
- the instruction processing unit inside the PIM maintains the previously requested memory write and read addresses. It compares the previous memory address maintained by the command processing unit and the address of the packet to be processed, and informs the memory controller of the comparison result in advance through a page close signal. The memory controller determines whether to keep or close the page of the internal memory through this page close signal.
- the present invention improves the open page hit rate of the internal DRAM by changing the processing order of memory addresses directly or implicitly included in a processing-in-memory (PIM) instruction (PIM operations).
- PIM processing-in-memory
- the present invention can reduce performance loss due to a page miss that occurs when the internal DRAM management of the PIM is operated in an open page mode.
- FIG. 1 is an internal structure diagram of a processing-in-memory (PIM);
- FIG. 3 is an exemplary structural diagram of a PIM instruction packet
- FIG. 5 is a processing flowchart of a PIM command packet according to an embodiment of the present invention.
- FIG. 6 is a structural diagram of a PIM according to the present invention.
- FIG. 7 is a flowchart of an operation of a DRAM controller inside a PIM according to another embodiment of the present invention.
- FIG. 8 is a structural diagram of a PIM command processing device according to the present invention.
- Processing-in-memory is an intelligent semiconductor that integrates a memory and an arithmetic unit and packages it into a single chip.
- PIM By using PIM, it is possible to maximize the performance of the computer system because it can solve the memory bottleneck of the traditional computer.
- the memory used for manufacturing the PIM may be various memories, and the present invention relates to a PIM using DRAM as an internal memory.
- FIG. 1 is a diagram illustrating an internal structure of a PIM.
- the command processing unit 20 inside the processing-in-memory 10 sends a read and write request 21 to the DRAM controller 30 to access the DRAM 40 .
- the command processing unit 20 sends a read/write request signal 21 to the DRAM controller 30 .
- write data 22 is provided to the DRAM controller 30
- read data 23 is received from the internal DRAM 40 through the DRAM controller 30 .
- the DRAM controller 30 sends a control signal 31 to the DRAM 40 to transmit/receive write/read data 32 to and from the DRAM 40 .
- the requested address is divided into row-address and column-address and processed sequentially.
- a PRECHARGE operation is performed before processing the row-address. Because row-address processing and PRECHARGE operations require a long time that takes up most of DRAM response time, an open page policy that omits unnecessary row-address processing and PRECHARGE operations is mainly used in existing computer systems. As shown in FIG.
- the open page policy waits for a memory read/write request (50), and when a request is received, the requested address is divided into row-address and column-address, and row-address processing (60) is performed first, and then It performs column-address processing (70) and waits for the next read/write request (80).
- the row-address of the address processed for the previous request is compared with the row-address of the address to be processed for this request (90). If the row-address matches, the row-address processing (60) is omitted and only the column-address is processed (70).
- both the PRECHARGE operation (100) and the row-address processing (60) must be performed.
- the PIM performs arithmetic functions in addition to general memory read and write functions. Accordingly, the PIM and the computer system exchange a command packet 110 that may be configured as shown in FIG. 3 , for example, in order to request and respond to the memory function and the arithmetic function of the PIM.
- the command packet 110 may include an OPCODE, a destination address, and an operand address.
- OPCODE specifies the type of operation to be performed by the PIM
- the destination address is the destination address to write back the operation result after the PIM executes the operation function
- the operand address specifies the operands required for the operation. address to which it is directed.
- both a method of directly indicating an operand (immediate type) and a method of indicating an address of an operand (recall type) are possible.
- a method of indicating the address of an operand there are a method of directly designating the address and a method of indirectly designating the address range by designating it. These addressing methods can be used in various ways depending on the purpose and design method of the PIM.
- the processing process of the command packet of the PIM has an atomic operation in which memory read and write functions and arithmetic functions are sequentially executed as shown in FIG. 4 . That is, the PIM command processing device (20 in FIG. 1 ) interprets 120 the received PIM command packet and sends a destination address access request 130 and an operand address access request 140 to the DRAM controller to process it. And after performing the operation function indicated by the OPCODE in the command packet 110 (150), to return the operation result (write back), the DRAM controller (30 in FIG. 1) is once again requested to access the destination address (160) ).
- the memory management method of the PIM according to the present invention includes the following two PIM command packet processing methods in order to improve the response speed and throughput of the PIM. Through this processing method, the page hit rate can be improved when the internal DRAM of the PIM uses the open page policy.
- the PIM memory management method according to the present invention is a method in which the source address is accessed first and then the destination address is accessed later when the command processing device (refer to 230 in FIG. 6) processes a command packet that uses data of the destination address as an operand.
- FIG. 5 is a flowchart of processing of a PIM command packet according to the present invention. This will be described with reference to the PIM structure shown in FIG. 6 and the structure of the instruction processing unit 230 shown in FIG. 8 . 6 and 8 will be described in detail later.
- the PIM command processing device interprets the PIM command packet 170 , and sends an access request 180 to the operand address data to the DRAM controller to process it, and then the destination address Performs an access request 190 to the data.
- the DRAM controller After performing the operation function indicated in the command packet ( 200 ), the DRAM controller ( 30 in FIG. 1 ) is again requested to access the destination address ( 210 ) in order to write back the operation result.
- This method proposed by the present invention sequentially performs the destination address access 190 for operand data and the destination address access 210 for returning the operation result by requesting the destination address with a lower priority, so that the internal DRAM (250 in FIG. 6) ) matches the line address of the open page and the line address to which the PIM command packet processing result is returned. Therefore, the page hit ratio of DRAM is improved.
- the page close signal 234 used between the command processing unit 230 of the PIM 220 and the memory controller, that is, the DRAM controller 240 is shown.
- the command processing unit 230 inside the PIM stores (maintains) the memory (DRAM) read and write addresses that were previously requested (231) when processing the PIM command packet. And when interpreting the next PIM command packet, the previous address stored (maintained) is compared with the address of the packet to be processed, and the result of the comparison (ie, whether to close the open page of the DRAM 250) is paged.
- the DRAM controller 240 is informed in advance through the close signal 234 .
- the command processing unit 230 makes a read/write request 231 to the DRAM controller 240 .
- write data 232 is provided to the DRAM controller 240
- read data 233 is received from the internal DRAM 250 through the DRAM controller 240 .
- the DRAM controller 240 sends a control signal 241 to the DRAM 250 and transmits/receives write/read data 242 to and from the DRAM 250 .
- the DRAM controller 240 waits for a memory read/write request (260), and when the request is received, divides the requested address into row-address and column-address, performs row-address processing (270), and column-address processing ( 280). Then, it is determined whether to keep or close the page of the internal DRAM according to the page close signal 234 ( 290 ).
- the PRECHARGE operation 300 is performed and the memory read/write request is again waited ( 260 ), and when the page close signal is not received, the next read/write request is waited ( 310 ).
- the row-address of the address processed for the previous request is compared with the row-address of the address to be processed for this request ( 320 ). If the row-address matches, the row-address processing (270) is omitted and only the column-address is processed (280). On the other hand, when the row-addresses of the addresses to be processed do not match, both the PRECHARGE operation 330 and the row-address processing 270 are performed.
- the DRAM controller 240 maintains the page according to the page close signal 234 of the command processing unit 230 after the column-address processing 280 . It is determined whether or not (290). According to this method, performance loss can be reduced by performing PRECHARGE, which is conventionally performed by DRAM controllers in case of page mismatch.
- FIG. 8 is a diagram illustrating the structure of the command processing unit 230 for performing the above-described method for managing the memory of the PIM.
- the flowcharts of FIGS. 5 and 7 may be implemented by the finite state machine 350 of FIG. 8 .
- the memory controller 360 of FIG. 8 may be located outside or inside the command processing unit 230 , but for convenience of description, it is indicated by a dotted line inside the command processing unit 230 .
- the arithmetic unit 370 can be implemented as one or more arithmetic units 1 to N according to the types of instructions that can be processed.
- the command analyzer 340 analyzes the PIM command packet to extract a command 341 and a destination address 342 , and extracts an operand address 343 or direct data 344 depending on the type of command.
- the finite state machine 350 uses the direct data 344 as write data to perform a memory write operation. If the instruction 341 to be processed is a memory read, the finite state machine 350 requests the data of the destination address from the memory controller 360 to output the read response data 361 .
- the finite state machine 350 In the case of an arithmetic instruction (I-type) using direct data, the finite state machine 350 requests the operand to the destination address 342 and transmits it to the arithmetic unit 370 together with the direct data 344, and the result of the operation (371) is returned to the destination address (342).
- the finite state machine 350 In the case of an operation instruction (R-type) using an operand address, the finite state machine 350 first requests the operand address 343 from the memory controller 360 and then requests the data of the destination address 342 . do. Then, the collected operands are transferred to the arithmetic unit 370 and the arithmetic result 371 is returned to the destination address 342 .
- the instruction analyzer 340 compares the destination address of the previous instruction with the operand address of the current instruction while analyzing the PIM instruction packet to check whether the row-address matches (see FIG. 7 ). In case of mismatch, a page close signal 345 is generated and transmitted to the memory controller 360, and a PRECHARGE operation of the internal DRAM is performed in advance. That is, the memory controller 360 determines whether to keep or close the page of the internal DRAM through the page close signal 345 .
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- Human Computer Interaction (AREA)
- Computing Systems (AREA)
- Microelectronics & Electronic Packaging (AREA)
- Dram (AREA)
Abstract
본발명은 PIM의 성능을 극대화하기 위한 메모리 관리 방법으로서 프로세싱인메모리(PIM)의 불필요한 DRAM 접근 시간을 줄임으로써 PIM의 성능을 향상시키는 것을 목적으로 한다. 이를 위해 명령어 처리장치가 PIM 명령어패킷을 처리할 때, 내부 메모리의 읽기와 쓰기 동작이 연이어 진행될 가능성이 높은 목적주소 접근 요청을 후순위로 처리한다. 목적주소를 후순위로 요청함에 의해, 내부 메모리의 오픈 되어 있는 페이지의 행-주소와 PIM 명령어패킷 처리 결과를 돌려줄 행 주소가 일치될 수 있다. 또한 PIM 내부의 명령어 처리장치는 이전에 요청했던 메모리 쓰기 및 읽기 주소를 유지한다. 명령어 처리장치가 유지하고 있는 이전 메모리 주소와, 처리해야 할 패킷의 주소를 비교하고 비교 결과를 페이지 닫음 신호를 통해 메모리 제어기에게 미리 알려준다. 본 발명에 의해, 내부 메모리의 오픈페이지 적중률(open page hit rate)이 향상되고, 내부 메모리 관리가 오픈페이지 모드로 운영될 때 발생하는 페이지 불일치(page miss)로 인한 성능 손실이 줄어든다.
Description
본발명은 프로세싱인메모리(Processing in Memory, PIM)에 관한 것으로, 구체적으로, PIM 장치 내부의 메모리 컨트롤러에 관한 것이다. 특히, 본발명은 PIM 내부 메모리의 트랜잭션(transaction) 시간을 최소화하기 위한 메모리 제어 방법과 이를 위한 PIM의 하드웨어 구조에 관한 것이다
프로세싱인메모리는 메모리와 연산장치(Processing Unit)가 하나의 칩으로 집적된 메모리로, 프로세서가 연산을 위해 메모리에 접근하는 빈도를 감소시킴으로써 시스템의 성능과 전력효율을 향상시킨다. 프로세서의 프로세싱인메모리 접근 방식은 전통적인 메모리 접근 방식과 다르게, 주소와 데이터 신호들 외에 연산을 위한 명령어 신호를 함께 사용한다. 프로세싱인메모리의 연산장치는 프로세서로부터 전달받은 명령어를 처리하기 때문에 복잡한 하드웨어를 가지며, 이로 인해 프로세싱인메모리의 메모리로서의 성능은 저하된다. 따라서, 프로세싱인메모리의 메모리로서의 성능을 크게 저하시키지 않아야 하기 때문에 연산장치에 대해서 가능한 낮은 하드웨어 복잡도가 요구되며, 이에 따라 비교적 간단한 연산만을 지원하도록 설계된다. PIM 제작에 사용되는 메모리는 다양한 메모리가 활용될 수 있다(예를 들어, DRAM).
한편, DRAM은 종래의 다른 메모리와 다른 독특한 동작 방식으로 인해 관리 방법에 따라 요구되는 메모리 트랜잭션(transaction) 시간이 크게 달라진다. 전통적인 컴퓨터 시스템에서는 오픈페이지 모드(open page mode)와 클로즈페이지 모드(close page mode)를 이용하는 다양한 메모리 관리 방법을 통하여 시스템의 성능을 향상시켰다. 최근에는 사회적 요구로 인해 다양한 구조의 컴퓨터 시스템이 개발되고 있으며, 각각의 컴퓨터 시스템은 요구 사항에 부합하는 다양한 메모리 스케줄링 방법을 도입하고 있다. 하지만, 프로세싱인메모리(PIM)는 컴퓨터 시스템의 성능을 극대화하기 위해 새롭게 연구되고 있는 컴퓨터 구조이지만 메모리 관리에 대해 제안된 기술은 미흡하다.
본발명은 PIM의 성능을 극대화하기 위한 메모리 관리 방법으로서 프로세싱인메모리(PIM)의 불필요한 DRAM 접근 시간을 줄임으로써 PIM의 성능을 향상시키는 것을 목적으로 한다.
상기 과제를 해결하기 위하여, 본발명은 프로세싱인메모리(PIM) 명령어(PIM operations)에 직접적, 암시적으로 포함된 메모리 주소의 처리 순서를 변경함으로써 내부 메모리(예를 들어, DRAM)의 오픈페이지 적중률(open page hit rate)을 향상시킨다. 이를 위해 명령어 처리장치가 PIM 명령어패킷을 처리할 때, 내부 메모리의 읽기와 쓰기 동작이 연이어 진행될 가능성이 높은 목적주소 접근 요청을 후순위로 처리한다. 목적주소를 후순위로 요청함에 의해, 내부 메모리의 오픈 되어 있는 페이지의 행-주소와 PIM 명령어패킷 처리 결과를 돌려줄 행 주소가 일치될 수 있다.
또한 본발명은 PIM 명령어에 직접적, 암시적으로 포함된 메모리 주소들을 명령어 처리장치에서 미리 파악하고 메모리 제어기에 알려줌으로써 내부 메모리의 오픈페이지 불일치(open page miss) 상황에서 발생하는 성능 손실을 최소화 한다. 이를 위해 PIM 내부의 명령어 처리장치는 이전에 요청했던 메모리 쓰기 및 읽기 주소를 유지한다. 명령어 처리장치가 유지하고 있는 이전 메모리 주소와, 처리해야 할 패킷의 주소를 비교하고 비교 결과를 페이지 닫음 신호를 통해 메모리 제어기에게 미리 알려준다. 메모리 제어기는 내부 메모리의 페이지를 유지할지 닫을지 여부를 이 페이지 닫음 신호를 통해 결정한다.
본발명의 더 상세한 구성 및 작용은 이후에 도면과 함께 설명하는 구체적인 실시예를 통하여 더욱 명확해질 것이다.
본발명은 프로세싱인메모리(PIM) 명령어(PIM operations)에 직접적, 암시적으로 포함된 메모리 주소의 처리 순서를 변경함으로써 내부 DRAM의 오픈페이지 적중률(open page hit rate)을 향상시킨다.
본발명은 PIM의 내부 DRAM 관리를 오픈페이지(open page) 모드로 운영할 때 발생하는 페이지 불일치(page miss)로 인한 성능 손실을 줄일 수 있다.
도 1은 프로세싱인메모리(PIM)의 내부 구조도
도 2는 DRAM 오픈페이지 정책의 순서도
도 3은 PIM 명령어패킷의 예시적 구조도
도 4는 PIM의 명령어 수행 절차의 순서도
도 5는 본발명의 일 실시예에 따른 PIM 명령어패킷의 처리 순서도
도 6은 본발명에 따른 PIM의 구조도
도 7은 본발명의 다른 실시예에 따른 PIM 내부의 DRAM 제어기의 동작 순서도
도 8은 본발명에 따른 PIM의 명령어 처리장치의 구조도
본발명의 이점 및 특징, 그리고 이들을 달성하는 방법은 이하 첨부된 도면과 함께 상세하게 기술된 바람직한 실시예를 참조하면 명확해질 것이다. 그러나 본발명은 이하에 기술된 실시예에 한정되는 것이 아니라 다양한 다른 형태로 구현될 수 있다. 실시예는 단지 본발명을 완전하게 개시하며 본발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 발명의 범주를 완전하게 알려주기 위해 제공되는 것일 뿐, 본발명은 청구항의 기재 내용에 의해 정의되는 것이다.
또한, 본 명세서에서 사용된 용어는 실시예를 설명하기 위한 것이며 본발명을 제한하고자 하는 것이 아니다. 본 명세서에서, 단수형은 특별히 언급하지 않는 한 복수형도 포함한다. 또한 명세서에 사용된 '포함한다(comprise, comprising 등)'라는 용어는 언급된 구성요소, 단계, 동작, 및/또는 소자 이외의 하나 이상의 다른 구성요소, 단계, 동작, 및/또는 소자의 존재 또는 추가를 배제하지 않는 의미로 사용된 것이다.
이하, 본발명의 바람직한 실시예를 첨부 도면을 참조하여 상세히 설명한다. 실시예의 설명에 있어, 관련된 공지 구성 또는 기능에 대한 구체적인 설명이 본발명의 요지를 흐릴 수 있는 경우에는 그 상세한 설명을 생략한다.
<기초 설명>
·프로세싱인메모리(processing in memory; PIM)
프로세싱인메모리는 메모리와 연산장치를 집적하여 하나의 칩으로 패키징한 지능형 반도체이다. PIM을 사용하면 전통적인 컴퓨터의 메모리 병목현상을 해소할 수 있기 때문에 컴퓨터 시스템의 성능을 극대화 할 수 있다. PIM 제작에 사용되는 메모리는 다양한 메모리가 될 수 있으며, 본발명은 내부 메모리로 DRAM을 사용하는 PIM에 대한 발명이다.
도 1은 PIM의 내부 구조를 도시한 그림이다. 도 1과 같이 프로세싱인메모리(10) 내부의 명령어 처리장치(20)는 DRAM(40)에 접근하기 위해 DRAM 제어기(30)에게 읽기 및 쓰기 요청(21)을 보낸다. 구체적으로, 명령어 처리장치(20)는 DRAM 제어기(30)에 읽기/쓰기 요청 신호(21)를 보낸다. 쓰기 요청인 경우에는 쓰기 데이터(22)를 DRAM 제어기(30)에 제공하고, 내부 DRAM(40)으로부터 DRAM 제어기(30)를 통해 읽기 데이터(23)를 수신한다. DRAM 제어기(30)는 DRAM(40)과 쓰기/읽기 데이터(32)를 송수신하기 위하여 DRAM(40)에 제어 신호(31)를 보낸다.
·DRAM에 대한 페이지 정책
DRAM에 데이터를 쓰거나 DRAM으로부터 데이터를 읽기 위해서, 요청 받은 주소를 행-주소(row address)와 열-주소(column address)로 구분하여 차례로 처리한다. 행-주소를 처리하기 전에는 프리챠지(PRECHARGE) 동작을 수행한다. 행-주소 처리와 PRECHARGE 동작시에는 DRAM의 응답시간 대부분을 차지할만큼 긴 시간이 요구되기 때문에 기존 컴퓨터 시스템에서는 불필요한 행-주소 처리와 PRECHARGE 동작을 생략하는 오픈페이지(open page) 정책을 주로 사용한다. 오픈페이지 정책은 도 2와 같이, 메모리 읽기/쓰기 요청을 기다리고 있다가(50) 요청이 수신되면 요청 받은 주소를 행-주소와 열-주소로 구분하여 먼저 행-주소 처리(60)를 한 다음에 열-주소 처리(70)를 하고, 다음 번 읽기/쓰기 요청을 대기한다(80). 다음 번 읽기/쓰기 요청이 수신되면, 이전 요청에 대해 처리했던 주소의 행-주소와 이번 요청에 대해 처리해야 할 주소의 행-주소를 비교한다(90). 행-주소가 일치하면 행-주소 처리(60)를 생략하고 열-주소만 처리한다(70). 반면에, 처리해야 할 주소의 행-주소가 일치하지 않을 경우에는 PRECHARGE 동작(100)과 행-주소 처리(60)를 모두 해야 한다.
·PIM 명령어패킷
PIM은 일반적인 메모리의 읽기 및 쓰기 기능 외에 연산 기능을 수행한다. 따라서 PIM과 컴퓨터 시스템은 PIM의 메모리 기능과 연산 기능을 요청하고 응답하기 위해 예컨대 도 3과 같이 구성될 수 있는 명령어패킷(110)을 주고받는다. 명령어패킷(110)에는 OPCODE, 목적주소, 피연산자주소가 포함될 수 있다. OPCODE는 PIM이 수행해야 할 연산의 종류를 지정하고, 목적주소는 PIM이 연산 기능을 수행 후 연산 결과를 돌려주기(write back) 위한 대상 주소이고, 피연산자주소는 연산을 위해 필요한 피연산자(operand)를 지시하는 주소이다. 피연산자를 지시하는 방식으로는, 직접 피연산자를 지시하는 방식(immediate type)과 피연산자의 주소를 지시하는 방식(recall type)이 모두 가능하다. 또한, 피연산자의 주소를 지시하는 방식에는 주소를 직접 지정하는 방식과 주소의 범위를 지정하여 간접 지정하는 방식이 있다. 이들 주소지정 방식은 PIM의 용도와 설계 방법에 따라 다양하게 사용 가능하다.
PIM의 명령어패킷의 처리 과정은 도 4와 같이 메모리 읽기 및 쓰기 기능과 연산 기능이 순차적으로 실행되는 원자적 형태(atomic operation)를 가진다. 즉, PIM 명령어 처리장치(도 1의 20)는 수신한 PIM 명령어패킷을 해석(120)하고 이를 처리하기 위해 DRAM 제어기에 목적주소 접근 요청(130) 및 피연산자주소 접근 요청(140)을 보낸다. 그리고 명령어패킷(110)에서 OPCODE로 지시된 연산 기능을 수행(150)한 후, 연산 결과를 돌려주기 위해(write back) DRAM 제어기(도 1의 30)에게 목적주소 접근을 또 한번 요청한다(160).
<본발명의 내용>
본발명에 따른 PIM의 메모리 관리방법은 PIM의 응답속도와 처리율을 향상시키기 위해 다음과 같은 두 가지의 PIM 명령어패킷 처리 방식을 포함한다. 이러한 처리 방식을 통해서 PIM의 내부 DRAM이 오픈페이지 정책을 사용시에 페이지 적중률을 향상 시킬 수 있다.
(1) 목적주소의 후순위 요청
PIM 명령어패킷의 종류 중에는 수행하는 연산이 원천주소뿐만 아니라 목적주소의 데이터를 피연산자로 사용해야 하는 명령어패킷이 있다. 본발명에 따른 PIM 메모리 관리방법은 명령어 처리장치(도 6의 230 참조)가 목적주소의 데이터를 피연산자로 사용해야 하는 명령어패킷을 처리할 때 원천주소를 먼저 접근한 후에 목적주소를 나중에 접근하는 방식을 포함한다.
도 5는 본발명에 따른 PIM 명령어패킷의 처리 순서도이다. 이에 대해서 도 6에 나타낸 PIM 구조 및 도 8에 나타낸 명령어 처리장치(230)의 구조를 참조하여 설명한다. 도 6과 도 8에 대해서는 차후에 상세히 설명한다.
도 5를 참조하면, PIM 명령어 처리장치(도 6의 230)는 PIM 명령어패킷을 해석(170)하고, 이를 처리하기 위해 DRAM 제어기에 피연산자주소 데이터로의 접근 요청(180)을 보낸 연후에 목적주소 데이터로의 접근 요청(190)을 수행한다. 명령어패킷에서 지시된 연산 기능을 수행(200)한 후, 연산 결과를 돌려주기 위해(write back) DRAM 제어기(도 1의 30)에 목적주소 접근을 또 다시 요청한다(210).
본발명에서 제안하는 이러한 방식은 목적주소를 후순위로 요청하여 피연산자 데이터를 위한 목적주소 접근(190)과 연산 결과를 돌려주기 위한 목적주소 접근(210)을 연속적으로 수행함으로써 내부 DRAM(도 6의 250)의 오픈되어 있는 페이지의 행-주소와 PIM 명령어패킷 처리 결과를 돌려줄 행 주소를 일치시킨다. 따라서 DRAM의 페이지 적중률이 향상된다.
(2) 페이지 닫음 신호
도 6의 PIM 구조도에, PIM(220)의 명령어 처리장치(230)와 메모리 제어기, 즉, DRAM 제어기(240) 사이에 사용되는 페이지 닫음 신호(234)를 나타내었다. PIM 내부의 명령어 처리장치(230)는 PIM 명령어패킷을 처리할 때 이전에 요청했던(231) 메모리(DRAM) 읽기 및 쓰기 주소를 저장(유지)한다. 그리고 다음 PIM 명령어패킷을 해석할 때에, 이 저장(유지)하고 있던 이전 주소와 처리해야 할 패킷의 주소를 비교하여 비교 결과를(즉, DRAM(250)의 오픈된 페이지를 닫을지 여부를) 페이지 닫음 신호(234)를 통해 DRAM 제어기(240)에게 미리 알려준다.
도 6에서 여타 동작은 도 1에서 설명한 것과 같과 동일하다. 즉, 명령어 처리장치(230)는 DRAM 제어기(240)에 읽기/쓰기 요청(231)을 한다. 쓰기 요청인 경우에는 쓰기 데이터(232)를 DRAM 제어기(240)에 제공하고, 내부 DRAM(250)으로부터 DRAM 제어기(240)를 통해 읽기 데이터(233)를 수신한다. DRAM 제어기(240)는 DRAM(250)에 제어 신호(241)를 보내고 DRAM(250)과 쓰기/읽기 데이터(242)를 송수신한다.
도 7은 이와 같이 페이지 닫음 신호(234)를 추가한 경우에, PIM 내부의 DRAM 제어기(240)의 동작 순서도이다. DRAM 제어기(240)는 메모리 읽기/쓰기 요청을 기다리고 있다가(260) 요청이 수신되면 요청 받은 주소를 행-주소와 열-주소로 구분하여 행-주소 처리(270)를 하고 열-주소 처리(280)를 한다. 그리고 페이지 닫음 신호(234)에 따라서 내부 DRAM의 페이지를 유지할지 닫을지 여부를 결정한다(290). 페이지 닫음 신호가 수신된 경우에는 PRECHARGE 동작(300)을 수행하고 다시 메모리 읽기/쓰기 요청을 대기하고(260), 페이지 닫음 신호가 수신되지 않은 경우에는 다음 번 읽기/쓰기 요청을 기다린다(310). 다음 번 읽기/쓰기 요청이 수신되면, 이전 요청에 대해 처리했던 주소의 행-주소와 이번 요청에 대해 처리해야 할 주소의 행-주소를 비교한다(320). 행-주소가 일치하면 행-주소 처리(270)를 생략하고 열-주소만 처리한다(280). 반면에, 처리해야 할 주소의 행-주소가 일치하지 않을 경우에는 PRECHARGE 동작(330)과 행-주소 처리(270)를 모두 수행한다.
이와 같이, DRAM 제어기(240)는 기존의 오픈페이지 정책을 사용하는 DRAM 제어기들과 달리, 열-주소 처리(280) 후 명령어 처리장치(230)의 페이지 닫음 신호(234)에 따라서 페이지를 유지할지 여부를 결정한다(290). 본 방식에 따르면, 종래에 DRAM 제어기들이 페이지 불일치의 경우에 수행하는 PRECHARGE를 미리 수행함으로써 성능 손실을 줄일 수 있다.
도 8은 상술한 PIM의 메모리 관리 방법을 수행하는 명령어 처리장치(230)의 구조를 도시한 그림이다. 도 5 및 7의 순서도는 도 8의 유한상태기계(350)에 의해 구현될 수 있다. 도 8의 메모리 제어기(360)는 명령어 처리장치(230)의 외부 혹은 내부에 있을 수 있지만 설명의 편의를 위해 명령어 처리장치(230)의 내부에 점선으로 표시하였다. 연산 장치(370)는 처리 가능한 명령어의 종류에 따라 하나 이상의 연산 장치(1~N)로 구현 가능하다.
명령어 분석기(340)는 PIM 명령어패킷을 분석하여 명령어(341)와 목적주소(342)를 추출하고, 명령어의 종류에 따라 피연산자주소(343) 혹은 직접데이터(344)를 추출한다.
유한상태기계(350)는, 처리할 명령어(341)가 만약 메모리 쓰기 명령어라면 직접데이터(344)를 쓰기 데이터로 사용하여 메모리 쓰기 동작을 수행한다. 만일 처리할 명령어(341)가 메모리 읽기인 경우에 유한상태기계(350)는 목적주소의 데이터를 메모리 제어기(360)에 요청하여 읽기 응답 데이터(361)로 내보내도록 한다.
직접데이터를 사용하는 연산 명령어(I-type)의 경우, 유한상태기계(350)는 목적주소(342)에 피연산자를 요청하여 이를 직접데이터(344)와 함께 연산 장치(370)에 전달하고 연산 결과(371)를 목적주소(342)에 돌려준다. 반면, 피연산자주소를 사용하는 연산 명령어(R-type)의 경우, 유한상태기계(350)는 피연산자주소(343)를 메모리 제어기(360)에 우선 요청하고 연후에 목적주소(342)의 데이터를 요청한다. 그리고 수집된 피연산자들을 연산 장치(370)에 전달하고 연산 결과(371)를 목적주소(342)에 돌려준다.
명령어 분석기(340)는 PIM 명령어패킷을 분석하면서 이전 명령어의 목적주소와 현재 명령어의 피연산자주소를 비교하여 행-주소 일치 여부를 검사한다(도 7 참조). 불일치일 경우 페이지 닫음 신호(345)를 생성하여 메모리 제어기(360)에 전달하고 내부 DRAM의 PRECHARGE 동작을 미리 수행하게 한다. 즉, 메모리 제어기(360)는 내부 DRAM의 페이지를 유지할지 닫을지 여부를 페이지 닫음 신호(345)를 통해 결정한다.
지금까지 본발명의 바람직한 실시예를 통하여 본발명을 상세히 설명하였으나, 본발명이 속하는 기술분야의 통상의 지식을 가진 자는 본발명이 그 기술적 사상이나 필수적인 특징을 변경하지 않고서 본 명세서에 개시된 내용과는 다른 구체적인 형태로 실시될 수 있다는 것을 이해할 수 있을 것이다. 이상에서 기술한 실시예들은 모든 면에서 예시적인 것이며 한정적이 아닌 것으로 이해해야 한다. 또한 본발명의 보호범위는 상기 상세한 설명보다는 후술한 특허청구범위에 의하여 정해지며, 특허청구의 범위 그리고 그 균등 개념으로부터 도출되는 모든 변경 또는 변형된 형태는 본발명의 기술적 범위에 포함되는 것으로 해석되어야 한다.
Claims (7)
- 명령어 처리장치, 메모리 제어기, 및 메모리가 포함된 프로세싱인메모리의 상기 메모리를 관리하는 방법으로,상기 명령어 처리장치가 명령어패킷을 해석하는 단계; 및상기 명령어 처리장치가 상기 해석된 명령어패킷의 연산기능을 수행하기 위해 상기 메모리 제어기에 먼저 피연산자주소 데이터로의 접근 요청을 보내고 그 이후에 목적주소 데이터로의 접근 요청을 수행하는 단계를 포함하는, 프로세싱인메모리의 메모리 관리 방법.
- 제1항에 있어서,상기 명령어 처리장치가 상기 목적주소 데이터로의 접근 요청을 수행하는 단계 이후에, 상기 명령어 처리장치에 포함된 연산장치가 상기 명령어패킷에서 지시된 연산 기능을 수행하는 단계; 및상기 연산장치가 수행한 연산의 결과를 돌려주기 위해 상기 명령어 처리장치가 상기 메모리 제어기에 목적주소 접근을 재차 요청하는 단계를 추가로 포함하는, 프로세싱인메모리의 메모리 관리 방법.
- 제1항에 있어서, 상기 메모리 제어기에 먼저 피연산자주소 데이터로의 접근 요청을 보내고 그 이후에 목적주소 데이터로의 접근 요청을 수행하는 단계는 상기 명령어 처리장치에 포함된 유한상태기계에 의해 수행되는, 프로세싱인메모리의 메모리 관리 방법.
- 명령어 처리장치, 메모리 제어기, 및 메모리가 포함된 프로세싱인메모리의 상기 메모리를 관리하는 방법으로,상기 명령어 처리장치가 명령어패킷의 처리를 위해 상기 메모리 제어기에 주소를 요청하는 단계;상기 명령어 처리장치가 요청했던 주소를 유지하는 단계;상기 명령어 처리장치가 다음 번 명령어패킷을 처리시에, 상기 유지하고 있는 이전 명령어의 주소와, 처리해야 할 현재 명령어패킷의 주소를 비교하는 단계; 및상기 명령어 처리장치가 상기 비교 결과 주소가 불일치할 경우 페이지 닫음 신호를 생성하여 상기 메모리 제어기에 전달하여 상기 메모리의 PRECHARGE 동작을 수행하도록 하는 단계를 포함하는, 프로세싱인메모리의 메모리 관리 방법.
- 제4항에 있어서, 상기 메모리 제어기가 상기 명령어 처리장치로부터 상기 페이지 닫음 신호를 수신하면 상기 메모리의 페이지를 닫고 PRECHARGE 동작을 수행하는 단계를 추가로 포함하는, 프로세싱인메모리의 메모리 관리 방법.
- 제1항에 있어서,상기 명령어 처리장치가 명령어패킷의 처리를 위해 상기 메모리 제어기에 요청하는 주소는 메모리 읽기 및 쓰기의 목적주소이고,상기 명령어 처리장치가 상기 유지하고 있는 이전 명령어패킷의 주소와 처리해야 할 현재 명령어패킷의 주소를 비교하는 단계에서, 이전 명령어패킷의 주소는 목적주소이고 현재 명령어패킷의 주소는 피연산자주소인, 프로세싱인메모리의 메모리 관리 방법.
- 제4항에 있어서, 상기 페이지 닫음 신호를 생성하여 상기 메모리 제어기에 전달하는 단계는 상기 명령어 처리장치에 포함된 명령어 분석기에 의해 수행되는, 프로세싱인메모리의 메모리 관리 방법.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| US17/137,003 US11347504B2 (en) | 2020-07-10 | 2020-12-29 | Memory management method and apparatus for processing-in-memory |
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| KR10-2020-0085573 | 2020-07-10 | ||
| KR1020200085573A KR20220007403A (ko) | 2020-07-10 | 2020-07-10 | 프로세싱인메모리의 메모리 관리 방법 및 장치 |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| US17/137,003 Continuation US11347504B2 (en) | 2020-07-10 | 2020-12-29 | Memory management method and apparatus for processing-in-memory |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2022010015A1 true WO2022010015A1 (ko) | 2022-01-13 |
Family
ID=79553276
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/KR2020/009163 Ceased WO2022010015A1 (ko) | 2020-07-10 | 2020-07-13 | 프로세싱인메모리의 메모리 관리 방법 및 장치 |
Country Status (2)
| Country | Link |
|---|---|
| KR (1) | KR20220007403A (ko) |
| WO (1) | WO2022010015A1 (ko) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| KR102923004B1 (ko) | 2023-06-05 | 2026-02-04 | 고려대학교 산학협력단 | 인메모리 연산 메모리 장치 및 이 장치에서 간접주소 지정방식을 수행하는 방법 |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20040044832A1 (en) * | 2002-08-27 | 2004-03-04 | Dodd James M | Precharge suggestion |
| KR100623892B1 (ko) * | 1998-01-23 | 2006-09-14 | 프리스케일 세미컨덕터, 인크. | 메모리 제어기 및 메모리 액세스 방법 |
| KR20170119396A (ko) * | 2016-04-19 | 2017-10-27 | 에스케이하이닉스 주식회사 | 메모리 제어장치 및 이를 포함하는 데이터 저장 장치 |
| KR101867219B1 (ko) * | 2017-02-22 | 2018-06-12 | 연세대학교 산학협력단 | 동적 메모리 인터페이스에 기반하여 서로 다른 메모리 연산들을 처리하기 위한 장치 및 방법 |
| KR20200046270A (ko) * | 2018-10-24 | 2020-05-07 | 전자부품연구원 | 상용 메모리 버스를 이용하는 프로세싱 인 메모리 장치 |
-
2020
- 2020-07-10 KR KR1020200085573A patent/KR20220007403A/ko not_active Withdrawn
- 2020-07-13 WO PCT/KR2020/009163 patent/WO2022010015A1/ko not_active Ceased
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| KR100623892B1 (ko) * | 1998-01-23 | 2006-09-14 | 프리스케일 세미컨덕터, 인크. | 메모리 제어기 및 메모리 액세스 방법 |
| US20040044832A1 (en) * | 2002-08-27 | 2004-03-04 | Dodd James M | Precharge suggestion |
| KR20170119396A (ko) * | 2016-04-19 | 2017-10-27 | 에스케이하이닉스 주식회사 | 메모리 제어장치 및 이를 포함하는 데이터 저장 장치 |
| KR101867219B1 (ko) * | 2017-02-22 | 2018-06-12 | 연세대학교 산학협력단 | 동적 메모리 인터페이스에 기반하여 서로 다른 메모리 연산들을 처리하기 위한 장치 및 방법 |
| KR20200046270A (ko) * | 2018-10-24 | 2020-05-07 | 전자부품연구원 | 상용 메모리 버스를 이용하는 프로세싱 인 메모리 장치 |
Also Published As
| Publication number | Publication date |
|---|---|
| KR20220007403A (ko) | 2022-01-18 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US12066953B2 (en) | Handling address translation requests | |
| US9639464B2 (en) | Application-assisted handling of page faults in I/O operations | |
| US9137179B2 (en) | Memory-mapped buffers for network interface controllers | |
| US8914458B2 (en) | Look-ahead handling of page faults in I/O operations | |
| US8745276B2 (en) | Use of free pages in handling of page faults | |
| WO2017196138A2 (en) | System and method for early data pipeline lookup in large cache design | |
| US8850125B2 (en) | System and method to provide non-coherent access to a coherent memory system | |
| US7472205B2 (en) | Communication control apparatus which has descriptor cache controller that builds list of descriptors | |
| CN101510191B (zh) | 具备缓存窗口的多核体系架构的实现方法 | |
| US20210377345A1 (en) | Establishment of socket connection in user space | |
| US6952761B2 (en) | Bus interface selection by page table attributes | |
| WO2022032990A1 (zh) | 一种命令信息传输方法、系统、装置及可读存储介质 | |
| WO2020085583A1 (ko) | 상용 메모리 버스를 이용하는 프로세싱 인 메모리 장치 | |
| US5915124A (en) | Method and apparatus for a first device accessing computer memory and a second device detecting the access and responding by performing sequence of actions | |
| US20220012054A1 (en) | Memory management method and apparatus for processing-in-memory | |
| US5913231A (en) | Method and system for high speed memory address forwarding mechanism | |
| KR20220007403A (ko) | 프로세싱인메모리의 메모리 관리 방법 및 장치 | |
| EP3772212B1 (en) | Data access method and apparatus, and electronic device | |
| US5727179A (en) | Memory access method using intermediate addresses | |
| US8719499B2 (en) | Cache-line based notification | |
| US20050091458A1 (en) | Storage control apparatus, control system capable of DMA transfer, and method of controlling DMA transfer | |
| JPS6126702B2 (ko) | ||
| WO2021020646A1 (ko) | 효율적인 명령어 처리를 위한 프로세싱-인-메모리 제어 방법 및 이를 적용한 연산장치 | |
| WO2022010016A1 (ko) | 프로세싱인메모리의 읽고-쓰기-연산 명령어 처리 방법 및 장치 | |
| JPH0210450A (ja) | キヤツシユメモリの先行フエツチ制御方式 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 20943929 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 20943929 Country of ref document: EP Kind code of ref document: A1 |