Abstract:
Disclosed herein are a memory management apparatus and method for threads of Data Distribution Service middleware. The apparatus includes a memory area management unit, one or more thread heaps, and a queue. The memory area management unit partitions a memory chunk allocated for the DDS middleware by a Cyber-Physical System on a memory page basis, manages the partitioned memory pages, and allocates the partitioned memory pages to the threads of the DDS middleware that have requested memory. The thread heaps are provided with the memory pages allocated to threads of the DDS middleware by the memory area management unit, and manage the provided memory pages. The queue receives memory used pages returned by the thread heaps. The thread heaps are provided with the memory pages for the threads by the queue if a memory page is not present in the memory area management unit when the threads request memory.