Tag Archives: virtualalloc

Hidden Costs of Memory Allocation

It’s important to understand the cost of memory allocations, but this cost can be surprisingly tricky to measure. It seems reasonable to measure this cost by wrapping calls to new[] and delete[] with timers. However, for large buffers these timers … Continue reading

Posted in Investigative Reporting, Performance, xperf | Tagged , | 34 Comments

Making VirtualAlloc Arbitrarily Slower

As part of my continuing exploration of things that are slower than they should be I recently came across a problem with VirtualAlloc. If you use the wrong flag with this function then, depending on how much memory you allocate, … Continue reading

Posted in Programming, Quadratic, xperf | Tagged | 20 Comments