IP Library Granted Patent US 12,061,802
Granted Patent B2
US 12,061,802 · App. 18/048,344 · Granted Aug 13, 2024

Dynamic memory management apparatus and method and computer-readable storage medium for the same

Inventors: Hong-Il Ju (Daejeon, KR); Dong-Wook Kang (Daejeon, KR); Gae-Il An (Daejeon, KR); Bo-Heung Chung (Daejeon, KR); Byeong-Cheol Choi (Daejeon, KR)
Assignee: ELECTRONICS AND TELECOMMUNICATIONS RESEARCH INSTITUTE
G06F3/0622G06F3/0631G06F3/0673G06F12/1458G06F21/78
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,061,802
App. No.
18/048,344
Granted
Aug 13, 2024
Kind
B2
Abstract

Disclosed herein are a dynamic memory management apparatus and method and a computer-readable storage medium for the same. The dynamic memory management method includes defining a shadow area mapped to a memory area, setting a coloring value in the shadow area, and permitting or denying access to the memory area based on the coloring value when accessing the memory area.

Claims (33)

1. A dynamic memory management method, comprising:

defining a shadow area mapped to a memory area;

setting a coloring value in the shadow area; and

permitting or denying access to the memory area based on the coloring value when accessing the memory area,

wherein permitting or denying the access to the memory area comprises:

when deallocation of a heap chunk from the memory area is completed by executing a free( ) function, denying access to a data area of the deallocated heap chunk based on the coloring value of the shadow area;

when the free( ) function is executed, storing information about the deallocated heap chunk in a memory management area (tcache_entry); and

storing a forward pointer (fd) and a backward pointer (bk) in the data area of the deallocated heap chunk, thus completing the deallocation of the heap chunk.

2. The dynamic memory management method of claim 1 , wherein permitting or denying the access to the memory area further comprises:

when allocation of a heap chunk to the memory area is requested by executing a malloc( ) function, permitting access to a data area of an allocated heap chunk based on the coloring value of the shadow area.

3. The dynamic memory management method of claim 1 , wherein the shadow area is physically separated from the memory area.

4. The dynamic memory management method of claim 1 , wherein the shadow area is configured such that 16 bytes of the memory area are assigned as 1 byte to the shadow area.

5. The dynamic memory management method of claim 1 , wherein an access authority setting area of the shadow area is defined by two bits.

6. A dynamic memory management apparatus, comprising:

a shadow area definition unit for defining a shadow area mapped to a memory area;

a coloring value setting unit for setting a coloring value in the shadow area; and

a memory access determination unit for permitting or denying access to the memory area based on the coloring value when accessing the memory area,

wherein the memory access determination unit is configured to:

when deallocation of a heap chunk from the memory area is completed by executing a free( ) function, deny access to a data area of the deallocated heap chunk based on the coloring value of the shadow area;

when the free( ) function is executed, store information about the deallocated heap chunk in a memory management area (tcache_entry); and

store a forward pointer (fd) and a backward pointer (bk) in the data area of the deallocated heap chunk, thus completing deallocation of the heap chunk.

7. The dynamic memory management apparatus of claim 6 , wherein the memory access determination unit is further configured to, when allocation of a heap chunk to the memory area is requested by executing a malloc( ) function, permit access to a data area of an allocated heap chunk based on the coloring value of the shadow area.

8. The dynamic memory management apparatus of claim 6 , wherein the shadow area is physically separated from the memory area.

9. The dynamic memory management apparatus of claim 6 , wherein the shadow area is configured such that 16 bytes of the memory area are assigned as 1 byte to the shadow area.

10. The dynamic memory management apparatus of claim 6 , wherein an access authority setting area of the shadow area is defined by two bits.

11. A computer-readable storage medium storing a computer program, the computer program comprising instructions allowing a processor to perform operations when executed by the processor, the operations comprising:

defining a shadow area mapped to a memory area;

setting a coloring value in the shadow area; and

permitting or denying access to the memory area based on the coloring value when accessing the memory area,

wherein permitting or denying the access to the memory area comprises:

when deallocation of a heap chunk from the memory area is completed by executing a free( ) function, denying access to a data area of the deallocated heap chunk based on the coloring value of the shadow area;

when the free( ) function is executed, storing information about the deallocated heap chunk in a memory management area (tcache_entry); and

storing a forward pointer (fd) and a backward pointer (bk) in the data area of the deallocated heap chunk, thus completing deallocation of the heap chunk.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 21, 2022
From: JU, HONG-IL; KANG, DONG-WOOK; AN, GAE-IL; CHUNG, BO-HEUNG; CHOI, BYEONG-CHEOL
To: ELECTRONICS AND TELECOMMUNICATIONS RESEARCH INSTITUTE
Reel/Frame 061495/0662 →
Priority Claims (1)
KR 10-2021-0185640 · Dec 23, 2021 · national
Continuity (1)
Related Publication 20230205431A1 · Jun 29, 2023