cwindowsmemory-managementmemory-pool

Memory Pool in C for windows application (Not interested in C++)


I am trying to understand memory pool concept in C. I understand memory pool is a pre-allocated memory space with a fixed size. But I want know is there any standard Library or API that can help to implement memory pool in C ?

I Don't want to implement memory pool my self in C , I am in search of some STANDARD API or LIB for my C program that can do memory pool operation.


Solution

  • Windows API offers that you can create your own heap (block of virtual memory):

    HeapCreate. Then you use HeapAlloc and HeapFree within that.