KR20140109237A - Method and apparatus for analyzing memory architecture - Google Patents

Method and apparatus for analyzing memory architecture Download PDF

Info

Publication number
KR20140109237A
KR20140109237A KR1020130142153A KR20130142153A KR20140109237A KR 20140109237 A KR20140109237 A KR 20140109237A KR 1020130142153 A KR1020130142153 A KR 1020130142153A KR 20130142153 A KR20130142153 A KR 20130142153A KR 20140109237 A KR20140109237 A KR 20140109237A
Authority
KR
South Korea
Prior art keywords
memory
memory address
address
execution time
accessing
Prior art date
Application number
KR1020130142153A
Other languages
Korean (ko)
Other versions
KR101574394B1 (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 단국대학교 산학협력단
Publication of KR20140109237A publication Critical patent/KR20140109237A/en
Application granted granted Critical
Publication of KR101574394B1 publication Critical patent/KR101574394B1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

A technique relating to a method and an apparatus to analyze the architecture of a multi-bank memory is disclosed. A method to analyze the architecture of a memory consisting of multi-banks comprises the steps of: accessing the memory in a cache line unit in accordance to at least one memory address; calculating operation processing time for data corresponding to at least one memory address by accessing the memory in the cache line unit; and determining the architecture of the memory based on the calculated operation processing time. Therefore, the architecture of the memory can easily be analyzed by sequentially accessing the multi-bank memory using a cache line as a unit, and analyze the pattern of operation processing time. This causes a low buffer drive to be minimized, thereby improving the performance of the overall system.

Description

메모리 구조를 분석하는 방법 및 장치{METHOD AND APPARATUS FOR ANALYZING MEMORY ARCHITECTURE}[0001] METHOD AND APPARATUS FOR ANALYZING MEMORY ARCHITECTURE [0002]

본 발명은 메모리 구조에 관한 것으로, 더욱 상세하게는 멀티 뱅크 메모리의 구조를 분석하는 방법 및 장치에 관한 것이다.The present invention relates to a memory structure, and more particularly, to a method and apparatus for analyzing the structure of a multi-bank memory.

최근의 컴퓨터 시스템은 멀티 코어와 대용량 메모리를 기반으로 발전하고 있다. Modern computer systems are evolving based on multicore and large memory.

예컨대, Intel, AMD, ARM, NVIDIA 등과 같은 CPU 제조사에서는 멀티 코어 환경의 다양한 프로세서들을 출시하고 있다. Intel은 10개의 코어를 탑재한 Xeon E7 프로세서를, AMD는 12개의 코어를 제공하는 Opteron 6000 시리즈 프로세서를, ARM과 NVIDIA에서는 각각 4개의 코어를 제공하는 ARM Cortex-A15 MPcore와 512개 이상의 코어를 제공할 수 있는 Tesla를 출시하였다. For example, CPU manufacturers such as Intel, AMD, ARM, and NVIDIA are launching various processors in a multi-core environment. Intel offers an Xeon E7 processor with 10 cores, an AMD Opteron 6000 series processor with 12 cores, an ARM Cortex-A15 MPcore with 4 cores each for ARM and NVIDIA, and more than 512 cores Tesla is available.

또한, 프로세서의 발전과 함께 메모리 또한 대용량화, 접근 속도 고속화, 저가격화가 진행되고 있다. 이러한 발전 방향에 맞춰 멀티 코어와 대용량 메모리의 특성을 고려한 시스템 소프트웨어 수준의 중요성이 커지게 되었다.In addition, along with the development of processors, the capacity of memories is also increasing, the speed of approaching, and the price of the memory are increasing. The importance of the level of system software considering characteristics of multi-core and large memory has been increased in accordance with this development direction.

대용량 메모리를 사용하는 멀티 코어 시스템에서는 멀티 뱅크 구조로 인해 다수의 코어들이 동시에 메모리에 접근하면서 로우 버퍼 충돌 현상을 발생시키며, 이로 인해 병렬성을 저하시키고, 스레드 간의 간섭 현상을 일으켜 시스템의 성능을 떨어뜨리는 요인이 되고 있다.In a multi-core system using a large memory, a multi-bank structure causes a plurality of cores to simultaneously access a memory, causing a low-buffer collision phenomenon, which degrades parallelism and causes interference between threads, It is becoming a factor.

이러한 문제를 OS 수준에서 해결하기 위해서는 실제 물리 메모리의 뱅크 구조와 OS에서 관리하는 페이지 프레임간의 관계를 정확히 분석할 필요가 있으나, 이에 대한 연구는 미흡한 실정이다. In order to solve this problem at the OS level, it is necessary to accurately analyze the relationship between the bank structure of the physical memory and the page frame managed by the OS, but the research on this problem is insufficient.

상기와 같은 문제점을 해결하기 위한 본 발명의 목적은, 로우 버퍼 충돌에 따른 연산 수행 시간에 기반하여 멀티 뱅크 메모리의 구조를 분석하는 방법을 제공하는데 있다.According to an aspect of the present invention, there is provided a method of analyzing a structure of a multi-bank memory based on an operation execution time due to a row buffer conflict.

상기와 같은 문제점을 해결하기 위한 본 발명의 다른 목적은, 로우 버퍼 충돌에 따른 연산 수행 시간에 기반하여 멀티 뱅크 메모리의 구조를 분석하는 장치를 제공하는데 있다.Another object of the present invention is to provide an apparatus for analyzing a structure of a multi-bank memory based on an operation execution time due to a row buffer collision.

상기 목적을 달성하기 위한 본 발명의 실시예에 따른 메모리 구조를 분석하는 방법은, 멀티 뱅크로 구성된 메모리의 구조를 분석하는 방법에 있어서, 적어도 하나의 메모리 주소에 따라 캐시 라인 단위로 메모리에 접근하는 단계와, 캐시 라인 단위로 메모리에 접근하여 적어도 하나의 메모리 주소에 상응하는 데이터에 대한 연산 수행 시간을 산출하는 단계와, 산출된 연산 수행 시간에 기반하여 메모리의 구조를 판단하는 단계를 포함한다.According to another aspect of the present invention, there is provided a method of analyzing a structure of a memory including multi-banks, the method comprising the steps of: accessing a memory in units of cache lines according to at least one memory address; Calculating a calculation execution time for data corresponding to at least one memory address by accessing the memory in units of cache lines, and determining a structure of the memory based on the calculated execution execution time.

여기에서, 상기 메모리에 접근하는 단계는, 제1 메모리 주소 및 제2 메모리 주소에 기반하여 메모리에 미리 설정된 반복 횟수만큼 접근하되, 제1 메모리 주소에 미리 설정된 주소 크기만큼 증가시켜 제2 메모리 주소를 결정할 수 있다. The step of accessing the memory accesses the memory by a preset number of times based on the first memory address and the second memory address and increases the address by a predetermined address size in the first memory address, You can decide.

여기에서, 상기 메모리에 접근하는 단계는, 제2 메모리 주소와 제1 메모리 주소를 차례로 접근하고, 다시 제1 메모리 주소와 제2 메모리 주소를 차례로 접근할 수 있다. Here, the step of accessing the memory may sequentially access the second memory address and the first memory address, and then access the first memory address and the second memory address in turn.

여기에서, 상기 미리 설정된 주소 크기는 64B일 수 있다. Here, the predetermined address size may be 64B.

여기에서, 상기 연산 수행 시간은, 제1 메모리 주소와 제2 메모리 주소에 상응하는 로우(row)에 포함된 데이터를 로우 단위로 로우 버퍼를 통하여 읽어오는 시간을 기초로 할 수 있다. Here, the operation execution time may be based on a time for reading data included in a row corresponding to the first memory address and the second memory address through a row buffer in a row unit.

여기에서, 상기 메모리의 구조를 판단하는 단계는, 연산 수행 시간이 변화하는 패턴에 기반하여 로우 버퍼 충돌을 판단할 수 있다. Here, the step of determining the structure of the memory may determine a row buffer conflict based on a pattern in which an operation execution time varies.

여기에서, 상기 메모리의 구조를 판단하는 단계는, 연산 수행 시간이 증가하는 지점에 상응하는 제1 메모리 주소와 제2 메모리 주소에서 로우 버퍼 충돌이 발생한 것으로 판단할 수 있다. Here, the step of determining the structure of the memory may determine that a row buffer conflict occurs in the first memory address and the second memory address corresponding to the point at which the operation execution time increases.

여기에서, 상기 메모리의 구조를 판단하는 단계는, 로우 버퍼 충돌이 발생한 제1 메모리 주소와 제2 메모리 주소가 서로 다른 메모리 로우에 매핑되는 것으로 판단할 수 있다. Here, the step of determining the structure of the memory may determine that the first memory address and the second memory address where the row buffer conflict occurs are mapped to different memory rows.

상기 다른 목적을 달성하기 위한 본 발명의 실시예에 따른 메모리 구조를 분석하는 장치는, 적어도 하나의 물리 메모리 주소에 따라 캐시 라인 단위로 메모리에 접근을 요청하는 접근 요청부와, 캐시 라인 단위로 메모리에 접근하여 적어도 하나의 물리 메모리 주소에 상응하는 데이터에 대한 연산 수행 시간을 산출하는 버퍼 충돌 확인부와, 산출된 연산 수행 시간에 기반하여 메모리의 구조를 판단하는 메모리 구조 판단부를 포함한다.According to another aspect of the present invention, there is provided an apparatus for analyzing a memory structure, comprising: an access request unit for requesting access to a memory in units of cache lines according to at least one physical memory address; And a memory structure determining unit for determining a structure of a memory based on the computed computation time. The memory structure determining unit determines a structure of the memory based on the calculated computation time.

상기와 같은 본 발명에 따른 메모리 구조를 분석하는 방법 및 장치는 캐시 라인을 단위로 하여 멀티 뱅크 메모리에 순차적으로 접근하여 연산 수행 시간의 패턴을 분석함으로써 메모리의 구조를 용이하게 분석할 수 있다. The method and apparatus for analyzing the memory structure according to the present invention can easily analyze the structure of the memory by sequentially accessing the multi-bank memory in units of cache lines and analyzing patterns of operation execution time.

또한, 메모리 구조에 대한 분석을 통하여 로우 버퍼 충동을 최소화함으로써 전체적인 시스템 성능을 향상시킬 수 있다. Also, by analyzing the memory structure, it is possible to improve the overall system performance by minimizing the low buffer impulse.

도 1은 본 발명의 실시예에 따른 분석 대상 메모리의 구조를 설명하기 위한 개념도이다.
도 2는 본 발명의 실시예에 따른 메모리의 동작을 설명하기 위한 개념도이다.
도 3은 본 발명의 실시예에 따른 메모리 구조를 분석하는 방법을 수행하기 위한 알고리즘을 설명하기 위한 예시도이다.
도 4는 본 발명의 실시예에 따른 메모리 구조를 분석하는 방법을 설명하기 위한 흐름도이다.
도 5는 본 발명의 실시예에 따른 메모리 구조를 분석하는 장치를 설명하기 위한 블록도이다.
도 6은 본 발명의 실시예에 따른 메모리 구조 분석을 통한 시뮬레이션 결과를 나타내는 도면이다.
1 is a conceptual diagram for explaining a structure of a memory to be analyzed according to an embodiment of the present invention.
2 is a conceptual diagram for explaining the operation of the memory according to the embodiment of the present invention.
3 is an exemplary diagram illustrating an algorithm for performing a method of analyzing a memory structure according to an embodiment of the present invention.
4 is a flowchart illustrating a method of analyzing a memory structure according to an embodiment of the present invention.
FIG. 5 is a block diagram illustrating an apparatus for analyzing a memory structure according to an embodiment of the present invention. Referring to FIG.
FIG. 6 is a diagram illustrating a simulation result through analysis of a memory structure according to an embodiment of the present invention.

본 발명은 다양한 변경을 가할 수 있고 여러 가지 실시예를 가질 수 있는 바, 특정 실시예들을 도면에 예시하고 상세한 설명에 상세하게 설명하고자 한다. 그러나, 이는 본 발명을 특정한 실시 형태에 대해 한정하려는 것이 아니며, 본 발명의 사상 및 기술 범위에 포함되는 모든 변경, 균등물 내지 대체물을 포함하는 것으로 이해되어야 한다. 각 도면을 설명하면서 유사한 참조부호를 유사한 구성요소에 대해 사용하였다. While the invention is susceptible to various modifications and alternative forms, specific embodiments thereof are shown by way of example in the drawings and will herein be described in detail. It should be understood, however, that the invention is not intended to be limited to the particular embodiments, but includes all modifications, equivalents, and alternatives falling within the spirit and scope of the invention. Like reference numerals are used for like elements in describing each drawing.

제1, 제2, A, B 등의 용어는 다양한 구성요소들을 설명하는데 사용될 수 있지만, 상기 구성요소들은 상기 용어들에 의해 한정되어서는 안 된다. 상기 용어들은 하나의 구성요소를 다른 구성요소로부터 구별하는 목적으로만 사용된다. 예를 들어, 본 발명의 권리 범위를 벗어나지 않으면서 제1 구성요소는 제2 구성요소로 명명될 수 있고, 유사하게 제2 구성요소도 제1 구성요소로 명명될 수 있다. 및/또는 이라는 용어는 복수의 관련된 기재된 항목들의 조합 또는 복수의 관련된 기재된 항목들 중의 어느 항목을 포함한다. The terms first, second, A, B, etc. may be used to describe various elements, but the elements should not be limited by the terms. The terms are used only for the purpose of distinguishing one component from another. For example, without departing from the scope of the present invention, the first component may be referred to as a second component, and similarly, the second component may also be referred to as a first component. And / or < / RTI > includes any combination of a plurality of related listed items or any of a plurality of related listed items.

어떤 구성요소가 다른 구성요소에 "연결되어" 있다거나 "접속되어" 있다고 언급된 때에는, 그 다른 구성요소에 직접적으로 연결되어 있거나 또는 접속되어 있을 수도 있지만, 중간에 다른 구성요소가 존재할 수도 있다고 이해되어야 할 것이다. 반면에, 어떤 구성요소가 다른 구성요소에 "직접 연결되어" 있다거나 "직접 접속되어" 있다고 언급된 때에는, 중간에 다른 구성요소가 존재하지 않는 것으로 이해되어야 할 것이다. It is to be understood that when an element is referred to as being "connected" or "connected" to another element, it may be directly connected or connected to the other element, . On the other hand, when an element is referred to as being "directly connected" or "directly connected" to another element, it should be understood that there are no other elements in between.

본 출원에서 사용한 용어는 단지 특정한 실시예를 설명하기 위해 사용된 것으로, 본 발명을 한정하려는 의도가 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 출원에서, "포함하다" 또는 "가지다" 등의 용어는 명세서상에 기재된 특징, 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.The terminology used in this application is used only to describe a specific embodiment and is not intended to limit the invention. The singular expressions include plural expressions unless the context clearly dictates otherwise. In the present application, the terms "comprises" or "having" and the like are used to specify that there is a feature, a number, a step, an operation, an element, a component or a combination thereof described in the specification, But do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, or combinations thereof.

다르게 정의되지 않는 한, 기술적이거나 과학적인 용어를 포함해서 여기서 사용되는 모든 용어들은 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자에 의해 일반적으로 이해되는 것과 동일한 의미를 가지고 있다. 일반적으로 사용되는 사전에 정의되어 있는 것과 같은 용어들은 관련 기술의 문맥 상 가지는 의미와 일치하는 의미를 가지는 것으로 해석되어야 하며, 본 출원에서 명백하게 정의하지 않는 한, 이상적이거나 과도하게 형식적인 의미로 해석되지 않는다.
Unless defined otherwise, all terms used herein, including technical or scientific terms, have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. Terms such as those defined in commonly used dictionaries are to be interpreted as having a meaning consistent with the contextual meaning of the related art and are to be interpreted as either ideal or overly formal in the sense of the present application Do not.

본 발명에서 사용되는 용어 '뱅크 메모리(bank memory)'는 동일 주소 공간 내에서 교체 가능한 복수의 물리 메모리를 매핑한 구조를 가진 메모리를 의미하며, '뱅크(bank)'는 최대 64KB의 메모리로 구성될 수 있고, 8개의 뱅크로써 마이크로프로세서의 기억 공간은 50만 바이트까지 확장될 수 있다. 또한, 채널(channel)은 랭크(rank)로 구성되며, 각각의 랭크는 뱅크로 구성된다.
The term " bank memory " used in the present invention means a memory having a structure in which a plurality of replaceable physical memories are mapped in the same address space, and a 'bank' And the memory space of the microprocessor as eight banks can be extended to 500,000 bytes. Also, a channel is composed of a rank, and each rank is made up of banks.

이하, 본 발명에 따른 바람직한 실시예를 첨부된 도면을 참조하여 상세하게 설명한다.
Hereinafter, preferred embodiments according to the present invention will be described in detail with reference to the accompanying drawings.

도 1은 본 발명의 실시예에 따른 분석 대상 메모리의 구조를 설명하기 위한 개념도이다.1 is a conceptual diagram for explaining a structure of a memory to be analyzed according to an embodiment of the present invention.

도 1을 참조하면, 메모리는 메모리 컨트롤러(110)에 주소/명령 버스와 데이터 버스를 공유하는 단위인 채널에 다수 개의 물리 메모리가 연결된다. 물리 메모리는 다수의 칩(120)으로 구성되어 있으며, 각각의 메모리 칩(120)은 다수의 뱅크(bank)(121)로 구성된다. 즉, 도 1에 따르면, 물리 메모리는 기판에 직접 꼽는 하나의 DIMM(Dual In-line Memory Module)으로 구성된다. Referring to FIG. 1, a plurality of physical memories are connected to a memory, which is a unit in which a memory controller 110 shares an address / command bus and a data bus. The physical memory is composed of a plurality of chips 120, and each memory chip 120 is composed of a plurality of banks 121. That is, according to FIG. 1, the physical memory is constituted by one dual in-line memory module (DIMM) directly connected to the substrate.

또한 각 칩(120)의 뱅크들(121)은 데이터 버스 사이즈를 최대한 사용하기 위해서 칩들의 그룹으로 묶인 랭크로 구성된다.In addition, the banks 121 of each chip 120 are configured with ranks grouped into a group of chips in order to maximize the data bus size.

하나의 뱅크(121)는 여러 개의 로우(row)(123)로 구성되며, 이는 프로세서가 메모리에 접근하는 단위이다. 프로세서가 메모리에 접근하게 될 경우, 메모리 주소를 기반으로 컨트롤러에 의해 해당 뱅크(121)가 결정되고 뱅크의 로우(123)를 찾는다. 결정된 로우의 모든 데이터들을 로우 버퍼(row buffer)(125)로 전송하게 된다.One bank 121 consists of a number of rows 123, which is the unit through which the processor accesses the memory. When the processor accesses the memory, the bank 121 is determined by the controller based on the memory address and looks for the row 123 of the bank. And transmits all the data of the determined row to the row buffer 125. [

메모리는 주소를 전달하는 주소 레지스터와 주소 카운터가 존재하고, 주어진 연산을 수행할 제어를 담당하는 제어로직, 뱅크의 로우(row)와 컬럼(column)을 제어하는 뱅크 제어기가 존재하고, 주어진 주소를 바탕으로 읽을 로우/컬럼을 결정하는 로우/컬럼 랫치(Latch)와 디코더(Decoder)가 존재한다.The memory has an address register and an address counter for transferring addresses, a control logic for controlling the execution of a given operation, a bank controller for controlling the rows and columns of the banks, There are row / column latches and decoders that determine the row / column to read.

이러한 구조에서 프로세서가 메모리에 있는 데이터를 읽을 때, 메모리에 접근하는 순서는 다음과 같다.In this architecture, when the processor reads data in memory, the order of accessing the memory is as follows.

프로세서가 메모리 주소를 이용하여 주 메모리에 데이터를 요청한다(S1).The processor requests data to the main memory using the memory address (S1).

프로세서가 넘겨준 메모리 주소를 바탕으로 메모리는 메모리 컨트롤러(110)에 의해 요청이 수행될 뱅크를 결정하고, 해당 뱅크에 메모리 주소를 전달한다(S2).Based on the memory address passed by the processor, the memory determines the bank to be requested by the memory controller 110 and transfers the memory address to the corresponding bank (S2).

뱅크에서는 전달 받은 주소를 바탕으로 주소의 해당 로우를 활성화 시킨다(S3).In the bank, the corresponding row of the address is activated based on the received address (S3).

활성화 되어 있는 비트 라인의 데이터를 로우 버퍼(125)로 전송한다(S4).The data of the activated bit line is transmitted to the row buffer 125 (S4).

로우 버퍼(125)가 데이터를 수신 후 메모리 주소의 비트라인 정보를 확인한다(S5).After receiving the data, the row buffer 125 confirms the bit line information of the memory address (S5).

뱅크 컨트롤러가 컬럼 주소를 확인하여 해당 컬럼을 활성화 시킨다(S6).The bank controller checks the column address and activates the corresponding column (S6).

뱅크는 활성화 된 로우와 컬럼 주소에 해당하는 셀에 있는 데이터를 로우 버퍼를 통해 출력 핀으로 보내고, 프로세스는 데이터 버스의 데이터 출력 핀을 확인한 후 데이터를 읽는다(S7).The bank sends the data in the cell corresponding to the activated row and column address to the output pin through the low buffer, and the process reads the data after confirming the data output pin of the data bus (S7).

뱅크는 데이터 출력을 종료한다(S8).The bank ends the data output (S8).

프로세서가 메모리에 있는 데이터를 반복하여 요청할 때 위 과정을 수행하는 과정에서 이전에 데이터를 읽었던 로우에 대하여 다시 읽기/쓰기 연산이 일어날 경우 뱅크에서 전달 받은 주소를 바탕으로 주소의 해당 로우을 활성화하고 로우 버퍼로 전송하는 등 S3내지 S5의 과정이 필요없다. 이를 로우 버퍼 히트라하여 S3 내지 S5의 과정의 시간만큼 수행 시간을 절약할 수 있다. When the processor repeatedly requests data in the memory, in the course of performing the above procedure, when a read / write operation is performed again on the row in which data was previously read, the corresponding row of the address is activated based on the address received from the bank, The process of S3 to S5 is not necessary. This is referred to as a low buffer hit, and the execution time can be saved by the time of S3 to S5.

하지만 이전에 데이터를 읽은 로우가 아닌 다른 로우에 연산이 수행될 경우 S1 내지 S8의 모든 과정이 수행되어야 하며 이에 따라 로우를 활성화 시키고, 기존 로우 버퍼(125)에 존재하는 데이터를 셀에 저장하는 프리 차징(Pre charging) 비용이 추가적으로 발생하게 된다. 이를 로우 버퍼 미스 또는 로우 버퍼 충돌이라 한다. 로우 버퍼 히트의 경우 5 내지 22ns(nano second), 로우 버퍼 미스의 경우 45 내지 50ns(nano second)의 수행 시간을 가지게 된다. 따라서 로우 버퍼 미스를 최소화하여 전체적인 시스템의 성능을 향상 시킬 수 있다.However, when the operation is performed on a row other than the row in which the data was previously read, all the processes of S1 to S8 must be performed, thereby activating the row, and storing the data existing in the existing row buffer 125 in the cell An additional pre-charging cost is incurred. This is called a low buffer miss or a low buffer collision. A run time of 5 to 22 ns (nano second) for a low buffer hit, and 45 to 50 nano (second nano seconds) for a low buffer miss. Therefore, the performance of the overall system can be improved by minimizing the row buffer miss.

따라서 멀티코어 환경에서 다수의 태스크(task)가 동시에 동작하여 메모리에 접근하게 되는 환경에서 태스크들이 같은 뱅크의 다른 로우에 접근하여 성능이 저하되는 메모리 병목현상을 줄여 프로세서의 대기 시간과 메모리의 접근 시간을 줄이는 것이 시스템의 전체적인 성능을 향상시킬 수 있다.
Therefore, in an environment where multiple tasks access simultaneously to a memory in a multi-core environment, tasks are accessed by other rows in the same bank, thereby reducing the memory bottleneck, thereby reducing the processor latency and memory access time Can improve the overall performance of the system.

도 2는 본 발명의 실시예에 따른 메모리의 동작을 설명하기 위한 개념도이다. 2 is a conceptual diagram for explaining the operation of the memory according to the embodiment of the present invention.

메모리는 전원이 들어오면 대기(idle) 상태(S210)로 천이되며, 로우 주소가 결정되면 로우 활성화(row activate) 상태(S230)로 천이되고, 로우 버퍼 히트(Row Buffer Hit)일 경우 읽기(Read)(S240)와 쓰기(Write)(S250) 동작을 수행할 수 있다. The memory is transited to an idle state (S210) when the power is turned on. When the row address is determined, the memory transitions to a row activate state (S230). When the row address is a row buffer hit, (S240) and a write operation (S250).

로우 버퍼 미스(Row Buffer Miss)의 경우 프리 차징(Pre charging)(S260)을 수행하고 로우 활성화 상태(S230)로 천이한 후 읽기(S240) 및 쓰기(S250) 동작을 수행한다.In the case of a row buffer miss, precharging (S260) is performed and transition to the row activation state (S230) is performed, followed by reading (S240) and writing (S250).

모든 동작이 수행 완료된 후 프리차징 상태(S260)를 거쳐서 다시 대기 상태(S210)로 천이하며, 다시 로우 활성화 상태(S230)로 천이하기 전까지 자동 휴식(auto refresh) 상태(S220)와 대기 상태(S210)를 번갈아 유지한다.
After all operations are completed, transition is made to the standby state (S210) again through the precharged state (S260), and the auto refresh state (S220) and the standby state (S210 ).

도 3은 본 발명의 실시예에 따른 메모리 구조를 분석하는 방법을 수행하기 위한 알고리즘을 설명하기 위한 예시도이다. 3 is an exemplary diagram illustrating an algorithm for performing a method of analyzing a memory structure according to an embodiment of the present invention.

라인 1은 메모리 구조를 분석하기 위한 메모리의 시작 주소(start_addr)와 크기(size)를 나타낸다.Line 1 shows the start address (start_addr) and size (size) of the memory for analyzing the memory structure.

라인 2는 메모리 구조를 분석하기 위한 물리 메모리를 캐시라인 크기 단위로 접근할 수 있는 메모리 주소 변수를 선언하는 것을 나타낸다. 또한 메모리 주소 변수 cl_1은 메모리의 시작 주소(start_addr)로 초기화하고, 메모리 구조를 분석하기 위하여 메모리의 시작 주소(start_addr)를 유지한다.Line 2 represents declaring a memory address variable that can access physical memory for analyzing the memory structure in units of cache line size. The memory address variable cl_1 is initialized with the start address (start_addr) of the memory, and the start address (start_addr) of the memory is maintained to analyze the memory structure.

라인 3은 메모리 구조를 분석하기 위한 물리 메모리를 캐시라인 크기 단위로 접근할 수 있는 다른 메모리 주소 변수를 선언하는 것을 나타낸다. 또한 메모리 주소 변수 cl_2는 메모리의 시작 주소(start_addr)에서 캐시라인 크기 단위로 증가한 두 번째 캐시라인에 해당하는 메모리 주소로 초기화한다.Line 3 represents declaring another memory address variable that can access the physical memory for analyzing the memory structure in units of cache line size. Also, the memory address variable cl_2 is initialized to a memory address corresponding to a second cache line which is increased in a unit of the cache line size from the start address (start_addr) of the memory.

라인 4는 메모리 구조를 분석하기 위한 영역인 메모리 시작 주소(start_addr)에서 메모리 크기(size)에 해당하는 영역을 캐시에서 제거하는 초기화 작업을 수행하여 메모리 구조 분석을 보장한다.Line 4 performs an initialization operation to remove the area corresponding to the memory size (size) from the memory start address (start_addr), which is an area for analyzing the memory structure, to assure the memory structure analysis.

라인 5 내지 라인 14는 메모리 구조를 분석하기 위한 연산 수행 시간을 산출할 수 있는 동작을 수행한다.Lines 5 to 14 perform an operation that can calculate an operation execution time for analyzing the memory structure.

라인 5, 라인 13 및 라인 14는 분석하기 위한 메모리 구조를 캐시라인 단위로 물리 메모리에 접근하도록 동작시키는 것으로 라인 13에서 메모리 주소 변수 cl_2가 캐시라인 단위로 증가하는 것을 나타내고 있으며, 라인 5에서 메모리 구조를 분석하기 위한 메모리의 영역을 벗어나지 않도록 메모리 주소 변수 cl_2의 값이 메모리 시작 주소의 값을 가진 cl_1이 분석하기 위한 메모리 크기(size)의 합보다 작은 조건을 만족하는 가를 판단한다.Line 5, line 13 and line 14 indicate that the memory structure for analysis is operated to access the physical memory in units of cache lines, in which the memory address variable cl_2 increases in units of cache lines, It is judged whether the value of the memory address variable cl_2 satisfies the condition that the value of the memory start address cl_1 is smaller than the sum of the memory size for analysis.

라인 6은 연산 수행 시간을 산출하기 위하여 타이머를 시작하는 것을 나타낸다.Line 6 indicates starting the timer to calculate the operation execution time.

라인 7, 라인 8 및 라인 11은 버스 경쟁이나 명령어들간의 지연과 같은 노이즈의 발생이 메모리 구조의 분석에 영향이 없도록 물리 메모리에 일정 횟수만큼 반복하여 접근하도록 하며, 도 3에서는 하나의 예로 500회를 반복하도록 한다.Line 7, line 8 and line 11 allow the occurrence of noise such as bus contention or delay between instructions to access the physical memory repeatedly a certain number of times so as not to affect the analysis of the memory structure. In FIG. 3, .

라인 9는 분석하기 위한 메모리의 시작 주소와 다른 메모리 주소를 가진 cl_2 메모리 주소 변수에 상응하는 물리 메모리의 데이터 값에 임의의 값을 증가시켜서 메모리 시작 주소 변수에 상응하는 물리 메모리에 할당하는 것을 나타낸다. 따라서, 메모리 주소 변수 cl_2를 이용하여 상응하는 물리 메모리에 접근하여 데이터 값을 획득하고, 메모리 주소 변수 cl_1을 이용하여 상응하는 물리 메모리에 접근하여 새로운 값을 저장한다.Line 9 indicates that the value of the physical memory corresponding to the cl_2 memory address variable having a memory address different from that of the memory to be analyzed is allocated to the physical memory corresponding to the memory start address variable by increasing an arbitrary value. Therefore, the corresponding physical memory is accessed using the memory address variable cl_2 to obtain the data value, and the corresponding physical memory is accessed using the memory address variable cl_1 to store the new value.

라인 10은 메모리 주소 변수 cl_1에 상응하는 물리 메모리의 데이터의 값에 임의의 값을 증가시켜서 메모리 주소 변수 cl_2에 상응하는 물리 메모리에 할당하는 것을 나타낸다. 따라서, 메모리 주소 변수 cl_1에 상응하는 물리 메모리에 접근이 발생하고, 다시 메모리 주소 변수 cl_2에 상응하는 물리 메모리에 접근이 발생한다.Line 10 indicates that an arbitrary value is incremented to the value of the data of the physical memory corresponding to the memory address variable cl_1 and allocated to the physical memory corresponding to the memory address variable cl_2. Therefore, access to the physical memory corresponding to the memory address variable cl_1 occurs, and access to the physical memory corresponding to the memory address variable cl_2 occurs again.

라인 9 및 라인 10을 수행함으로써 중앙처리장치(CPU) 내에서 메모리 주소 변수 cl_1 및 메모리 주소 변수 cl_2에 상응하는 메모리의 데이터를 접근하기 위하여 로우 버퍼를 확인하는 것을 보장할 수 있다.By performing line 9 and line 10, it can be ensured in the central processing unit (CPU) to identify the row buffer in order to access the data in the memory corresponding to the memory address variable cl_1 and the memory address variable cl_2.

라인 11은 물리 메모리에 미리 설정한 횟수만큼 반복적으로 접근하는 조건을 확인하며, 조건을 만족하였을 경우, 라인 12로 진행하여 연산 수행 시간을 측정하는 타이머를 정지한다.The line 11 confirms the conditions for repeatedly accessing the physical memory by the preset number of times. If the condition is satisfied, the process proceeds to the line 12 to stop the timer for measuring the operation execution time.

라인 13은 메모리의 구조를 분석하기 위하여 캐시라인의 크기만큼 메모리 주소 변수 cl_2를 증가시키고 라인 6으로 진행할 수 있다.Line 13 may increment the memory address variable cl_2 by the size of the cache line and proceed to line 6 to analyze the structure of the memory.

요약하면, 도 3의 알고리즘은 구조를 분석하고자 하는 메모리의 시작 주소를 관리하는 메모리 주소 변수 cl_1과 캐시라인 단위로 증가하는 메모리 주소 변수 cl_2에 상응하는 물리 메모리에 번갈아 접근하여 연산을 수행하도록 함으로써 메모리가 로우 단위로 로우 버퍼에 데이터를 전송하는 특징에 따라 연산 수행 시간이 변화하는 것을 기초로 하여 메모리의 구조를 분석할 수 있다.
In summary, the algorithm of FIG. 3 alternately accesses the physical memory corresponding to the memory address variable cl_1 for managing the start address of the memory to analyze the structure and the memory address variable cl_2 for each cache line, The structure of the memory can be analyzed on the basis that the operation execution time is changed according to the feature of transferring data to the row buffer in units of rows.

도 4는 본 발명의 실시예에 따른 메모리 구조를 분석하는 방법을 설명하기 위한 흐름도이다. 4 is a flowchart illustrating a method of analyzing a memory structure according to an embodiment of the present invention.

적어도 하나의 메모리 주소에 따라 캐시 라인 단위로 메모리에 접근한다(S410).The memory is accessed in units of cache lines according to at least one memory address (S410).

구조를 분석하고자 하는 메모리에 따른 접근하기 위하여 메모리 시작 주소와 메모리 종료 주소 또는 메모리 크기 정보가 필요하며, 캐시 라인 단위로 메모리에 접근하기 위하여 캐시 라인 단위의 적어도 하나의 메모리 주소 변수를 설정할 수 있고, 캐시 라인 단위로 메모리 주소 변수를 증가시켜 메모리 주소 변수에 상응하는 물리 메모리에 접근함으로써 메모리 구조 분석을 수행할 수 있다.A memory start address, a memory end address, or memory size information is required to access the memory according to a memory to be analyzed, and at least one memory address variable in a cache line unit can be set to access the memory in units of cache lines, Memory structure analysis can be performed by accessing the physical memory corresponding to the memory address variable by increasing the memory address variable in units of cache lines.

메모리 주소 변수는 분석하고자 하는 메모리 시작 주소를 관리하는 제1 메모리 주소 변수와 캐시 라인 단위로 증가시키며 메모리 구조를 분석하기 위한 제2 메모리 주소 변수를 설정할 수 있다. 즉, 제1 메모리 주소 및 제2 메모리 주소에 기반하여 메모리에 미리 설정된 반복 횟수만큼 접근하되, 제1 메모리 주소에 미리 설정된 주소 크기만큼 증가시켜 제2 메모리 주소를 결정할 수 있다. 여기서, 제1 메모리 주소 변수는 도 3에서 상술한 메모리 주소 변수 cl_1을 의미하고, 제2 메모리 주소 변수는 도 3에서 상술한 메모리 주소 변수 cl_2를 의미할 수 있다. 또한, 미리 설정된 주소 크기는 64B일 수 있다. The memory address variable may be a first memory address variable for managing a memory start address to be analyzed, and a second memory address variable for increasing a cache line unit and analyzing a memory structure. That is, the second memory address can be determined by accessing the memory by a preset number of times based on the first memory address and the second memory address, and increasing the address by a predetermined address size in the first memory address. Here, the first memory address variable means the memory address variable cl_1 described above in FIG. 3, and the second memory address variable can mean the memory address variable cl_2 described in FIG. Also, the preset address size may be 64B.

캐시 라인 단위로 메모리에 접근하여 적어도 하나의 메모리 주소에 상응하는 데이터에 대한 연산 수행 시간을 산출한다(S430).The operation execution time for data corresponding to at least one memory address is calculated by accessing the memory in units of cache lines (S430).

메모리 구조를 분석하기 위하여 로우 버퍼 충돌이 발생 가능한 연산을 수행하고 이에 따른 연산 수행 시간을 산출한다.In order to analyze the memory structure, a computation that can cause a row buffer collision is performed and the computation time is calculated accordingly.

로우 버퍼 충돌이 발생할 수 있도록 제1 메모리 주소 변수와 제2 메모리 주소 변수에 상응하는 물리 메모리에 번갈아서 접근하는 연산을 수행한다. 따라서, 연산 수행 시간은 제1 메모리 주소와 상기 제2 메모리 주소에 상응하는 로우(row)에 포함된 데이터를 로우 단위로 로우 버퍼를 통하여 읽어오는 시간을 기초로 할 수 있다. And performs an operation of alternately accessing the physical memory corresponding to the first memory address variable and the second memory address variable so that a row buffer conflict may occur. Therefore, the operation execution time may be based on the time of reading the data included in the row corresponding to the first memory address and the second memory address through the row buffer in units of rows.

또한, 중앙처리장치(CPU)에서 제1 메모리 주소 변수와 제2 메모리 주소 변수에 상응하는 물리 메모리의 데이터를 로우 버퍼(125)에서 확인하는 것을 보장하기 위하여 제1 메모리 주소 변수와 제2메모리 주소 변수에 상응하는 물리 메모리에 다른 순서로 번갈아서 접근하는 연산을 추가할 수 있다.In order to ensure that the data in the physical memory corresponding to the first memory address variable and the second memory address variable is confirmed in the low buffer 125 in the central processing unit (CPU), the first memory address variable and the second memory address You can add operations to alternate accesses to the physical memory corresponding to the variable in a different order.

산출된 연산 수행 시간에 기반하여 메모리의 구조를 분석한다(S450).The structure of the memory is analyzed based on the computed execution time (S450).

즉, 산출된 연산 수행 시간을 다른 메모리 주소에 대하여 산출된 연산 수행 시간과 비교하여 해당 메모리 주소에 대한 로우 버퍼 충돌 여부를 판단하여 메모리의 구조를 분석할 수 있다.That is, the calculated operation execution time is compared with the operation execution time calculated for the other memory address, and the structure of the memory can be analyzed by determining whether the low buffer conflict occurs for the corresponding memory address.

상세하게는, 연산 수행 시간이 변화하는 패턴에 기반하여 로우 버퍼 충돌을 판단할 수 있다. 예컨대, 제1 메모리 주소와 제2 메모리 주소에서 로우 버퍼 충돌이 발생한 것으로 판단할 수 있으며, 로우 버퍼 충돌이 발생한 제1 메모리 주소와 제2 메모리 주소가 서로 다른 메모리 로우에 매핑되는 것으로 판단할 수 있다.
Specifically, the row buffer conflict can be determined based on a pattern in which an operation execution time varies. For example, it can be determined that a low buffer conflict occurs in the first memory address and the second memory address, and it can be determined that the first memory address and the second memory address in which the row buffer conflict occurs are mapped to different memory rows .

도 5는 본 발명의 실시예에 따른 메모리 구조를 분석하는 장치를 설명하기 위한 블록도이다. FIG. 5 is a block diagram illustrating an apparatus for analyzing a memory structure according to an embodiment of the present invention. Referring to FIG.

도 5를 참조하면, 본 발명의 실시예에 따른 메모리 구조를 분석하는 장치(500)는, 접근 요청부(510), 버퍼 충돌 확인부(520) 및 메모리 구조 판단부(530)를 포함한다. Referring to FIG. 5, an apparatus 500 for analyzing a memory structure according to an embodiment of the present invention includes an access request unit 510, a buffer conflict check unit 520, and a memory structure determination unit 530.

접근 요청부(510)는 적어도 하나의 물리 메모리 주소에 따라 캐시 라인 단위로 메모리에 접근을 요청할 수 있다. The access request unit 510 may request access to the memory in units of cache lines according to at least one physical memory address.

상세하게는, 접근 요청부(510)는 제1 메모리 주소 및 제2 메모리 주소에 기반하여 메모리에 미리 설정된 반복 횟수만큼 접근시키되, 제1 메모리 주소에 미리 설정된 주소 크기만큼 증가시켜 제2 메모리 주소를 결정할 수 있다. 여기서, 미리 설정된 주소 크기는 64B일 수 있다. Specifically, the access request unit 510 accesses the memory by a preset number of times based on the first memory address and the second memory address, increases the first memory address by a preset address size, You can decide. Here, the preset address size may be 64B.

또한, 접근 요청부(510)는 제2 메모리 주소와 제1 메모리 주소를 차례로 접근시키고, 다시 제1 메모리 주소와 제2 메모리 주소를 차례로 접근시킬 수 있다. In addition, the access request unit 510 sequentially accesses the second memory address and the first memory address, and sequentially accesses the first memory address and the second memory address.

버퍼 충돌 확인부(520)는 캐시 라인 단위로 메모리에 접근하여 적어도 하나의 물리 메모리 주소에 상응하는 데이터에 대한 연산 수행 시간을 산출할 수 있다. 여기서, 연산 수행 시간은 제1 메모리 주소와 제2 메모리 주소에 상응하는 로우(row)에 포함된 데이터를 로우 단위로 로우 버퍼를 통하여 읽어오는 시간을 기초로 할 수 있다. The buffer collision checking unit 520 may access the memory in units of cache lines to calculate an operation execution time for data corresponding to at least one physical memory address. Here, the operation execution time may be based on a time for reading data included in a row corresponding to the first memory address and the second memory address through the row buffer in a row unit.

메모리 구조 판단부(530)는 산출된 연산 수행 시간에 기반하여 메모리의 구조를 판단할 수 있다. 상세하게는, 메모리 구조 판단부(530)는 연산 수행 시간이 변화하는 패턴에 기반하여 로우 버퍼 충돌을 판단할 수 있다. 또한, 메모리 구조 판단부(530)는 연산 수행 시간이 증가하는 지점에 상응하는 제1 메모리 주소와 제2 메모리 주소에서 로우 버퍼 충돌이 발생한 것으로 판단할 수 있으며, 로우 버퍼 충돌이 발생한 제1 메모리 주소와 제2 메모리 주소가 서로 다른 메모리 로우에 매핑되는 것으로 판단할 수 있다. The memory structure determination unit 530 may determine the structure of the memory based on the computed execution time. In detail, the memory structure determination unit 530 may determine a row buffer conflict based on a pattern in which an operation execution time varies. In addition, the memory structure determination unit 530 may determine that a row buffer conflict occurs in the first memory address and the second memory address corresponding to the point at which the operation execution time increases, And the second memory address are mapped to different memory rows.

상술한 본 발명의 실시예에 따른 메모리 구조를 분석하는 장치(500)의 각 구성부는 설명의 편의상 각각의 구성부로 나열하여 설명하였으나, 각 구성부 중 적어도 두 개가 합쳐져 하나의 구성부로 이루어지거나, 하나의 구성부가 복수개의 구성부로 나뉘어져 기능을 수행할 수 있고 이러한 각 구성부의 통합 및 분리된 실시예의 경우도 본 발명의 본질에서 벋어나지 않는 한 본 발명의 권리범위에 포함된다.
Although each component of the apparatus 500 for analyzing a memory structure according to an embodiment of the present invention has been described as a component for convenience of description, at least two of the components may be combined into one component, May be divided into a plurality of constituent parts to perform the functions and the case of the integrated and separate embodiments of each constituent part is also included in the scope of the present invention unless the essence of the present invention is satisfied.

도 6은 본 발명의 실시예에 따른 메모리 구조 분석을 통한 시뮬레이션 결과를 나타내는 도면이다.FIG. 6 is a diagram illustrating a simulation result through analysis of a memory structure according to an embodiment of the present invention.

도 6은 Intel XEON x5570 프로세서를 사용하며 1개의 노드를 가진 16GB DDR3 메모리를 가진 IBM X3650 M2 시스템에서 메모리 분석 도구를 수행한 결과를 나타낸 도면이다. FIG. 6 is a diagram illustrating a result of executing a memory analysis tool in an IBM X3650 M2 system with 16GB DDR3 memory using an Intel XEON x5570 processor and one node.

본 발명에서 검증한 시스템은 총 3개의 채널로 구성되며, 각 채널은 4개의 랭크로 이루어져 있으며, 1개의 랭크는 8개의 뱅크로 구성되어 있다. 각 뱅크는 32K개의 로우를 가지고 있으며, 각 로우의 사이즈는 4KB로 구성된다.The system verified in the present invention is composed of a total of three channels, each channel having four ranks, one rank being composed of eight banks. Each bank has 32K rows, and each row has a size of 4KB.

X축은 반복횟수를 나타내며, Y축은 연산 수행 시간 결과를 나타낸다. X축으로 메모리의 주소를 알 수 있는데 이는 메모리 주소 변수 cl_2의 초기값 + 64×반복 횟수(cl_2의 메모리 주소 증가 횟수)와 대응 된다. 예를 들어, 메모리 주소 변수 cl_2의 초기 값이 100번지라고 하면, 100번 반복했을 경우(100회 cl_2의 메모리 주소를 반복하여 증가시켜 연산을 수행했을 경우) 6500번지가 된다. 도 6의 (d)를 참조하면 총 2백만번을 반복하여 메모리 주소 변수 cl_2의 주소를 증가시키며 연산을 수행한 것으로 총 128MB의 메모리에 대하여 수행한 결과임을 나타낸다. 그리고, Y축이 대부분을 차지하는 약 1950us의 수행시간 보다 더 큰 수행시간을 나타내는 2150us 이상의 수행시간일 경우 로우 버퍼 충돌이 발생한 주소라는 것을 알 수 있다.The X-axis represents the number of repetitions, and the Y-axis represents the operation execution time result. The address of the memory can be found on the X axis, which corresponds to the initial value of the memory address variable cl_2 + 64 times the number of iterations (the number of memory address increments of cl_2). For example, assuming that the initial value of the memory address variable cl_2 is 100, if it is repeated 100 times (when the memory address of cl_2 is repeatedly increased 100 times), the address becomes 6500. Referring to FIG. 6 (d), the memory address variable cl_2 is repeatedly increased by 2 million times to increase the address of the memory address variable cl_2. If the execution time is 2150us or more, which indicates a larger execution time than the execution time of about 1950us, which occupies most of the Y axis, it can be seen that the address is the address where the low buffer conflict occurred.

먼저 도 6의 (a)를 살펴보면 연속된 3개의 주소 중, 1개의 수행 시간이 항상 높은 것을 알 수 있다. 이는 로우 버퍼 충돌이 발생한 것으로 판단할 수 있으며, 분석에 사용된 시스템이 3채널로 구성되어 있으며 수행 시간의 결과를 기초로 하여 분석에 사용된 시스템의 채널 인터리빙이 캐시라인 단위로 수행되는 것을 알 수 있다.Referring to FIG. 6 (a), it can be seen that the execution time of one of the three consecutive addresses is always high. It can be determined that a low buffer conflict has occurred. The system used for the analysis is composed of three channels, and based on the result of the execution time, it can be seen that the channel interleaving of the system used for the analysis is performed in units of cache lines have.

다음으로 도 6의 (b)에서 전체 128KB의 메모리 영역에 대하여 연산 수행 시간의 측정결과를 살펴보면 64번의 도 6의 (a)와 같은 결과를 확인할 수 있으며, 따라서 로우의 크기가 4KB로 판단할 수 있다.Referring to FIG. 6 (b), the result of the calculation of the execution time of the entire 128 KB memory area is shown in FIG. 6 (a) of FIG. 64. Accordingly, have.

다음으로 도 6의 (c)에서 도 6의 (b)의 경우가 96KB 단위로 반복된 것을 확인할 수 있고, 따라서 8개의 뱅크로 이루어진 것으로 판단할 수 있으며, 뱅크 인터리빙이 3개의 로우 단위로 구성되는 것을 알 수 있다. 또한 총 3MB의 메모리 범위 내에서 도 6의 (b)의 경우가 32번 발생하고, 도 6의 (d)에서 도 6의 (c)가 12MB 단위로 반복되어 발생하는 것을 기초로 하여 랭크 인터리빙이 3MB 단위로 수행됨을 판단할 수 있다.6 (c) to 6 (b) are repeated in units of 96 KB, so that it can be determined that the bank interleaving is made up of eight banks, and the bank interleaving is configured in units of three rows . Also, rank interleaving is performed on the basis that the case of FIG. 6 (b) occurs 32 times in the total memory of 3 MB, and the case of FIG. 6 (d) It can be determined that the process is performed in units of 3 MB.

상술한 본 발명의 실시예에 따른 메모리 구조를 분석하는 방법 및 장치는 캐시 라인을 단위로 하여 멀티 뱅크 메모리에 순차적으로 접근하여 연산 수행 시간의 패턴을 분석함으로써 메모리의 구조를 용이하게 분석할 수 있다. The method and apparatus for analyzing a memory structure according to an embodiment of the present invention can easily analyze a structure of a memory by sequentially accessing a multi-bank memory in units of cache lines and analyzing a pattern of operation execution time .

또한, 메모리 구조에 대한 분석을 통하여 로우 버퍼 충동을 최소화함으로써 전체적인 시스템 성능을 향상시킬 수 있다. Also, by analyzing the memory structure, it is possible to improve the overall system performance by minimizing the low buffer impulse.

상기에서는 본 발명의 바람직한 실시예를 참조하여 설명하였지만, 해당 기술 분야의 숙련된 당업자는 하기의 특허 청구의 범위에 기재된 본 발명의 사상 및 영역으로부터 벗어나지 않는 범위 내에서 본 발명을 다양하게 수정 및 변경시킬 수 있음을 이해할 수 있을 것이다. It will be apparent to those skilled in the art that various modifications and variations can be made in the present invention without departing from the spirit or scope of the present invention as defined by the following claims It can be understood that

110 : 메모리 컨트롤러 120 : 칩
121 : 뱅크 123 : 로우
125 : 로우 버퍼
500: 메모리 구조 분석 장치 510: 접근 요청부
520: 버퍼 충돌 확인부 530: 메모리 구조 판단부
110: memory controller 120: chip
121: bank 123: low
125: Low buffer
500: memory structure analysis apparatus 510: access request unit
520: buffer collision checking unit 530: memory structure judging unit

Claims (16)

멀티 뱅크로 구성된 메모리의 구조를 분석하는 방법에 있어서,
적어도 하나의 메모리 주소에 따라 캐시 라인 단위로 상기 메모리에 접근하는 단계;
상기 캐시 라인 단위로 상기 메모리에 접근하여 상기 적어도 하나의 메모리 주소에 상응하는 데이터에 대한 연산 수행 시간을 산출하는 단계;
상기 산출된 연산 수행 시간에 기반하여 상기 메모리의 구조를 판단하는 단계를 포함하는 메모리 구조를 분석하는 방법.
1. A method for analyzing a structure of a multi-bank memory,
Accessing the memory in units of cache lines according to at least one memory address;
Accessing the memory in units of the cache lines to calculate an operation execution time for data corresponding to the at least one memory address;
And determining a structure of the memory based on the calculated operation execution time.
청구항 1에 있어서,
상기 메모리에 접근하는 단계는
제1 메모리 주소 및 제2 메모리 주소에 기반하여 상기 메모리에 미리 설정된 반복 횟수만큼 접근하되,
상기 제1 메모리 주소에 미리 설정된 주소 크기만큼 증가시켜 상기 제2 메모리 주소를 결정하는 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method according to claim 1,
The step of accessing the memory
Accessing the memory by a predetermined number of repetitions based on the first memory address and the second memory address,
Wherein the second memory address is determined by incrementing the first memory address by a predetermined address size.
청구항 2에 있어서,
상기 메모리에 접근하는 단계는
상기 제2 메모리 주소와 상기 제1 메모리 주소를 차례로 접근하고, 다시 상기 제1 메모리 주소와 상기 제2 메모리 주소를 차례로 접근하는 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method of claim 2,
The step of accessing the memory
Accessing the second memory address and the first memory address in turn, and then accessing the first memory address and the second memory address in turn.
청구항 2에 있어서,
상기 미리 설정된 주소 크기는 64B인 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method of claim 2,
Wherein the predetermined address size is 64B.
청구항 1에 있어서,
상기 연산 수행 시간은
상기 제1 메모리 주소와 상기 제2 메모리 주소에 상응하는 로우(row)에 포함된 데이터를 로우 단위로 로우 버퍼를 통하여 읽어오는 시간을 기초로 하는 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method according to claim 1,
The operation execution time is
Wherein the first memory address and the second memory address are based on a time that the data included in a row corresponding to the first memory address and the second memory address are read through the row buffer in a row unit basis.
청구항 5에 있어서,
상기 메모리의 구조를 판단하는 단계는,
상기 연산 수행 시간이 변화하는 패턴에 기반하여 로우 버퍼 충돌을 판단하는 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method of claim 5,
Wherein the step of determining the structure of the memory comprises:
And determining a row buffer conflict based on a pattern in which the operation execution time varies.
청구항 6에 있어서,
상기 메모리의 구조를 판단하는 단계는,
상기 연산 수행 시간이 증가하는 지점에 상응하는 상기 제1 메모리 주소와 상기 제2 메모리 주소에서 상기 로우 버퍼 충돌이 발생한 것으로 판단하는 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method of claim 6,
Wherein the step of determining the structure of the memory comprises:
And determining that the row buffer conflict occurs at the first memory address and the second memory address corresponding to a point at which the operation execution time increases.
청구항 7에 있어서,
상기 메모리의 구조를 판단하는 단계는,
상기 로우 버퍼 충돌이 발생한 상기 제1 메모리 주소와 상기 제2 메모리 주소가 서로 다른 메모리 로우에 매핑되는 것으로 판단하는 것을 특징으로 하는 메모리 구조를 분석하는 방법.
The method of claim 7,
Wherein the step of determining the structure of the memory comprises:
And determining that the first memory address and the second memory address where the row buffer conflict occurs are mapped to different memory rows.
멀티 뱅크로 구성된 메모리의 구조를 분석하는 장치에 있어서,
적어도 하나의 물리 메모리 주소에 따라 캐시 라인 단위로 상기 메모리에 접근을 요청하는 접근 요청부;
상기 캐시 라인 단위로 상기 메모리에 접근하여 상기 적어도 하나의 물리 메모리 주소에 상응하는 데이터에 대한 연산 수행 시간을 산출하는 버퍼 충돌 확인부;
상기 산출된 연산 수행 시간에 기반하여 상기 메모리의 구조를 판단하는 메모리 구조 판단부를 포함하는 메모리 구조를 분석하는 장치.
1. An apparatus for analyzing a structure of a multi-bank memory, comprising:
An access request unit for requesting access to the memory in units of cache lines according to at least one physical memory address;
A buffer conflict check unit accessing the memory in units of the cache lines and calculating an operation execution time for data corresponding to the at least one physical memory address;
And a memory structure determining unit for determining a structure of the memory based on the calculated operation execution time.
청구항 9에 있어서,
상기 접근 요청부는,
제1 메모리 주소 및 제2 메모리 주소에 기반하여 상기 메모리에 미리 설정된 반복 횟수만큼 접근시키되,
상기 제1 메모리 주소에 미리 설정된 주소 크기만큼 증가시켜 상기 제2 메모리 주소를 결정하는 것을 특징으로 하는 메모리 구조를 분석하는 장치.
The method of claim 9,
The access request unit,
Accessing the memory by a preset number of times based on a first memory address and a second memory address,
Wherein the second memory address is determined by incrementing the first memory address by a predetermined address size.
청구항 9에 있어서,
상기 접근 요청부는,
상기 제2 메모리 주소와 상기 제1 메모리 주소를 차례로 접근시키고, 다시 상기 제1 메모리 주소와 상기 제2 메모리 주소를 차례로 접근시키는 것을 특징으로 하는 메모리 구조를 분석하는 장치.
The method of claim 9,
The access request unit,
Accesses the second memory address and the first memory address in turn, and then sequentially accesses the first memory address and the second memory address.
청구항 10에 있어서,
상기 미리 설정된 주소 크기는 64B인 것을 특징으로 하는 메모리 구조를 분석하는 장치.
The method of claim 10,
Wherein the predetermined address size is 64B.
청구항 9에 있어서,
상기 연산 수행 시간은,
상기 제1 메모리 주소와 상기 제2 메모리 주소에 상응하는 로우(row)에 포함된 데이터를 로우 단위로 로우 버퍼를 통하여 읽어오는 시간을 기초로 하는 것을 특징으로 하는 메모리 구조를 분석하는 장치.
The method of claim 9,
The operation execution time may be,
Wherein the first memory address and the second memory address are based on a time of reading data included in a row corresponding to the first memory address and the second memory address through a row buffer in units of rows.
청구항 13에 있어서,
상기 메모리 구조 판단부는,
상기 연산 수행 시간이 변화하는 패턴에 기반하여 로우 버퍼 충돌을 판단하는 것을 특징으로 하는 메모리 구조를 분석하는 장치.
14. The method of claim 13,
The memory structure determination unit determines,
And determining a row buffer conflict based on a pattern in which the operation execution time varies.
청구항 14에 있어서,
상기 메모리 구조 판단부는,
상기 연산 수행 시간이 증가하는 지점에 상응하는 상기 제1 메모리 주소와 상기 제2 메모리 주소에서 상기 로우 버퍼 충돌이 발생한 것으로 판단하는 것을 특징으로 하는 메모리 구조를 분석하는 장치.
15. The method of claim 14,
The memory structure determination unit determines,
And determines that the row buffer conflict has occurred in the first memory address and the second memory address corresponding to a point at which the operation execution time increases.
청구항 15에 있어서,
상기 메모리 구조 판단부는,
상기 로우 버퍼 충돌이 발생한 상기 제1 메모리 주소와 상기 제2 메모리 주소가 서로 다른 메모리 로우에 매핑되는 것으로 판단하는 것을 특징으로 하는 메모리 구조를 분석하는 장치.
16. The method of claim 15,
The memory structure determination unit determines,
And determines that the first memory address and the second memory address in which the row buffer conflict occurs are mapped to different memory rows.
KR1020130142153A 2013-03-04 2013-11-21 Method and apparatus for analyzing memory architecture KR101574394B1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
KR1020130022605 2013-03-04
KR20130022605 2013-03-04

Publications (2)

Publication Number Publication Date
KR20140109237A true KR20140109237A (en) 2014-09-15
KR101574394B1 KR101574394B1 (en) 2015-12-04

Family

ID=51755975

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020130142153A KR101574394B1 (en) 2013-03-04 2013-11-21 Method and apparatus for analyzing memory architecture

Country Status (1)

Country Link
KR (1) KR101574394B1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20160059643A (en) * 2014-11-19 2016-05-27 에스케이하이닉스 주식회사 Memory controller and operating method thereof

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20160059643A (en) * 2014-11-19 2016-05-27 에스케이하이닉스 주식회사 Memory controller and operating method thereof

Also Published As

Publication number Publication date
KR101574394B1 (en) 2015-12-04

Similar Documents

Publication Publication Date Title
JP6761873B2 (en) Self-refresh state machine MOP array
US7536530B2 (en) Method and apparatus for determining a dynamic random access memory page management implementation
US8977811B2 (en) Scalable schedulers for memory controllers
US11379381B2 (en) Main memory device having heterogeneous memories, computer system including the same, and data management method thereof
US11392488B2 (en) Optimizing storage of application data in memory
US8397100B2 (en) Managing memory refreshes
CN109952567B (en) Method and apparatus for bypassing internal caches of advanced DRAM memory controllers
KR102448999B1 (en) Interfaces for cache and memory with multiple independent arrays
US11194728B2 (en) Memory-aware pre-fetching and cache bypassing systems and methods
JP6231194B2 (en) Electronic devices, memory controllers, equipment
JP4395511B2 (en) Method and apparatus for improving memory access performance of multi-CPU system
KR20210025344A (en) Main memory device having heterogeneous memories, computer system including the same and data management method thereof
Zhang et al. DrMP: Mixed precision-aware DRAM for high performance approximate and precise computing
US6801982B2 (en) Read prediction algorithm to provide low latency reads with SDRAM cache
KR101574394B1 (en) Method and apparatus for analyzing memory architecture
US9496009B2 (en) Memory with bank-conflict-resolution (BCR) module including cache
CN113826083A (en) Processor-side transactional context memory interface systems and methods
CN115269199A (en) Data processing method and device, electronic equipment and computer readable storage medium
US20190179756A1 (en) Apparatuses and methods for determining efficient memory partitioning
US8639879B2 (en) Sorting movable memory hierarchies in a computer system
US9658976B2 (en) Data writing system and method for DMA
CN115114186A (en) Techniques for near data acceleration for multi-core architectures
Lin et al. DRAM-level prefetching for fully-buffered DIMM: Design, performance and power saving
Zhang Improving Data Movement Efficiency in the Memory Systems for Irregular Applications
Bhadauria et al. Optimizing thread throughput for multithreaded workloads on memory constrained CMPs

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
FPAY Annual fee payment

Payment date: 20181108

Year of fee payment: 4

FPAY Annual fee payment

Payment date: 20190925

Year of fee payment: 5