|Date:||November 8, 2004 / year-entry #387|
|Summary:||Now that you know how the 16-bit memory manager handled the global heap, it's time to see how this got transitioned to the new 32-bit world. The GlobalAlloc function continued to emulate all its previous moveability rules, but the return value of GlobalAlloc was no longer a selector since Win32 used the processor in "flat...|
Now that you know how the 16-bit memory manager handled the global heap, it's time to see how this got transitioned to the new 32-bit world.
This means that the old trick of caching a selector and reallocating the memory out from under it no longer worked.
Moveability semantics were preserved. Memory blocks still had a lock count, even though it didn't really accomplish anything since Win32 never compacted memory. (Recall that the purpose of the lock count was to prevent memory from moving during a compaction.)
Moveable memory and locking could have been eliminated completely, if it weren't for the
Aside from that, moveable memory gets you nothing aside from overhead.
Next time, an insight into how locking is implemented (even though it doesn't do anything).
<-- Back to Old New Thing Archive Index