"Vladimir Panteleev" <vladi...@thecybershadow.net> wrote in message news:op.vfvdtwgwtuz...@89-28-59-99.starnet.md... > > If you see anything that can be improved, feel free to fork the github > repo, or post patches, or just comment on it.
VirtualAlloc returns chunks that have 'dwAllocationGranularity' granularity, which is 64K on every Windows OS I've used. So allocating a page, 4K, will actualy get you 64K. So using VirtualAlloc as a replacement for malloc is very wasteful unless the allocations are larger that 64K. You might want to look at HeapCreate and it's siblings. (on windows anyway)