Dynamic Memory Managment in C++

Memory allocation is an important part of program optimization as well as of computer architecture. This thesis examines some of the concepts of memory allocation and tries to implement overrides for the standard new and delete functions in the c++ library using memory pools combined with other tech...

Full description

Bibliographic Details
Main Author: Sperens, Martin
Format: Others
Language:English
Published: Luleå tekniska universitet, Datavetenskap 2019
Subjects:
Online Access:http://urn.kb.se/resolve?urn=urn:nbn:se:ltu:diva-76611
Description
Summary:Memory allocation is an important part of program optimization as well as of computer architecture. This thesis examines some of the concepts of memory allocation and tries to implement overrides for the standard new and delete functions in the c++ library using memory pools combined with other techniques. The overrides are tested against the standard new and delete as well as a custom memory pool with perfect size for the allocations. The study finds that the overrides are slightly faster on a single thread but not on multiple. The study also finds that the biggest gain on performance is to create custom memory pools specific to the programs needs. Lastly, the study also lists a number of ways that the library could be improved