# US 2025/0094347 A1 · Cache memory controller for system including plurality of memory devices and operating method of cache memory controller

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2025/0094347 A1
- Document ID: US20250094347A1
- Status: Published application
- Kind: A1
- Application number: 18/883,239
- Filed: 2024-09-12
- Published: 2025-03-20
- Earliest claimed: 2023-09-18
- Assignees: Samsung Electronics Co., Ltd.
- Applicants: Samsung Electronics Co., Ltd.
- Inventors: Seungwon YANG
- Web page: https://patentgrep.com/patent/US20250094347A1

## CPC

- G06F 12/0802: Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
- G06F 12/0895: of parts of caches, e.g. directory or tag array
- G06F 2212/1024: Latency reduction
- G06F 2212/1028: Power efficiency
- G06F 2212/502: using adaptive policy
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A cache memory controller includes an internal memory configured to store a plurality of cost data sets and pieces of weight data on a plurality of internal elements included in the plurality of cost data sets, the plurality of cost data sets being related to data access, and a logic circuit configured to generate a first cost data set corresponding to data access to the first memory and a second cost data set corresponding to data access to the second memory, determine a target memory out of the first and second memory, based on a result of comparison of weighted sum of the first cost data set and a weighted sum of the second cost data set that are calculated based on the pieces of the weight data, and select a cache line to be replaced, out of cache lines in which data read from the target memory is stored.

## Claims

### Claim 1

A cache memory controller comprising:
an internal memory configured to store a plurality of cost data sets and pieces of weight data on a plurality of internal elements included in the plurality of cost data sets, the plurality of cost data sets being related to data access; and
a logic circuit configured to
generate a first cost data set corresponding to data access to a first memory and a second cost data set corresponding to data access to a second memory,
determine a target memory out of the first memory and the second memory, based on a weighted sum of the first cost data set and a weighted sum of the second cost data set that are calculated based on the pieces of the weight data, and
select a cache line to be replaced, out of cache lines in which data read from the target memory is stored, from among a plurality of cache lines included in a cache memory, when a cache miss occurs after the cache memory is full of data,
wherein the cache memory controller is configured to control the cache memory including the plurality of cache lines configured to temporarily store data from the first memory or the second memory.

### Claim 2 (depends on 1)

The cache memory controller of claim 1, wherein the plurality of internal elements included in the plurality of cost data sets includes at least two of latency data for data access, data on power consumption, overhead data, data on usage of common resources comprising buses and systems, and low-power policy data reflecting impacts on a low-power policy.

### Claim 3 (depends on 1)

The cache memory controller of claim 1, wherein the second memory is inside a second device, the second device being configured to be connected through a bus to a first device comprising the cache memory controller, the first memory, and the cache memory.

### Claim 4 (depends on 1)

The cache memory controller of claim 1, wherein the logic circuit is configured to control the cache memory to store an index together during the storing of data in the cache memory, the index corresponding to information about a read memory from which data is retrieved, and
wherein the cache line to be replaced is selected out of cache lines in which an index of the target memory is stored in the cache memory, when the cache miss occurs after the cache memory is full of data.

### Claim 5 (depends on 1)

The cache memory controller of claim 1, wherein the logic circuit is configured to
generate an N-th cost data set corresponding to data access to a memory in an N-th device connected to a first device through a bus,
compare the weighted sum of the first cost data set, the weighted sum of the second cost data set, and a weighted sum of the N-th cost data set, and
determine a target memory corresponding to a cost data set having a minimum weighted sum.

### Claim 6 (depends on 1)

The cache memory controller of claim 1, wherein the logic circuit is configured to select the cache line to be replaced, based on at least one a Least Recently Used (LRU) scheme, a Most Recently Used (MRU) scheme, a Last In First Out (LIFO) scheme, and a First In First Out (FIFO) scheme.

### Claim 7 (depends on 1)

The cache memory controller of claim 1, wherein the logic circuit is configured to update the pieces of weight data in response to an external command.

### Claim 8 (depends on 2)

The cache memory controller of claim 2, wherein the logic circuit is configured to calculate latency data for access to a read memory from which data is retrieved, together with data access, based on whether the cache miss has occurred or whether a cycle has been reached, or according to an external command, and the logic circuit is further configured to update latency data corresponding to the read memory based on the calculated latency data.

### Claim 9 (depends on 8)

The cache memory controller of claim 8, wherein the logic circuit is configured to compare the weighted sum of the first cost data set and the weighted sum of the second cost data set again, based on a cost data set comprising the updated latency data, and the logic circuit is further configured to update the target memory.

### Claim 10

An operating method of a cache memory controller, the method comprising:
generating a first cost data set corresponding to data access to a first memory;
generating a second cost data set corresponding to data access to a second memory;
determining a target memory out of the first memory and the second memory, based on a weighted sum of the first cost data set and a weighted sum of the second cost data set that are calculated based on pieces of weight data; and
selecting a cache line to be replaced, out of cache lines in which data read from the target memory is stored, from among cache lines included in a cache memory, when a cache miss occurs after the cache memory is full of data,
wherein the cache memory controller is configured to control the cache memory which is configured to temporarily store data from the first memory or the second memory.

### Claim 11 (depends on 10)

The method of claim 10, wherein the pieces of weight data determine weights of a plurality of internal elements included in a plurality of cost data sets, and
wherein the plurality of internal elements include at least two of latency data for data access, data on power consumption, overhead data, data on usage of common resources comprising buses and systems, and low-power policy data reflecting impacts on a low-power policy.

### Claim 12 (depends on 10)

The method of claim 10, wherein the second memory is inside a second device, the second device being configured to be connected through a bus to a first device comprising the cache memory controller, the first memory, and the cache memory.

### Claim 13 (depends on 10)

The method of claim 10, further comprising storing an index together during the storing of data in the cache memory, the index corresponding to information about a read memory from which data is retrieved,
wherein the selecting of the cache line to be replaced includes selecting the cache line to be replaced, out of cache lines in which an index of the target memory is stored in the cache memory.

### Claim 14 (depends on 10)

The method of claim 10, further comprising generating an N-th cost data set corresponding to data access to a memory in an N-th device connected to a first device through a bus,
wherein the determining of the target memory includes
comparing the weighted sum of the first cost data set, the weighted sum of the second cost data set, and a weighted sum of the N-th cost data set, and
determining a target memory corresponding to a cost data set having a minimum weighted sum.

### Claim 15 (depends on 10)

The method of claim 10, wherein the selecting of the cache line to be replaced is performed based on at least one a Least Recently Used (LRU) scheme, a Most Recently Used (MRU) scheme, a Last In First Out (LIFO) scheme, and a First In First Out (FIFO) scheme.

### Claim 16 (depends on 10)

The method of claim 10, further comprising updating the pieces of weight data in response to an external command.

### Claim 17 (depends on 11)

The method of claim 11, further comprising:
calculating latency data for access to a read memory from which data is retrieved, together with data access, based on whether the cache miss has occurred or whether a cycle has been reached, or according to an external command; and
updating latency data corresponding to the read memory, based on the calculated latency data.

### Claim 18 (depends on 17)

The method of claim 17, further comprising comparing the weighted sum of the first cost data set and the weighted sum of the second cost data set again, based on a cost data set including the updated latency data, and updating the target memory.

### Claim 19

A cache memory controller, the cache memory controller comprising:
an internal memory configured to store an index corresponding to information of a read memory from which data is retrieved, from among a first memory and a second memory; and
a logic circuit configured to
control a cache memory to store the index corresponding to the information of the read memory together during the storing of data in a cache memory,
determine a target memory by using a Least Recently Used (LRU) scheme, and
select a cache line to be replaced, from among cache lines in which an index of the target memory is stored in the cache memory, when a cache miss occurs after the cache memory is full of data,
wherein the cache memory controller is configured to control the cache memory including a plurality of cache lines configured to temporarily store data from the first memory or the second memory.

### Claim 20 (depends on 19)

The cache memory controller of claim 19, wherein the second memory is inside a second device, the second device being configured to be connected through a bus to a first device comprising the cache memory controller, the first memory, and the cache memory.
