|
|
|
|
|
by DrJokepu
2591 days ago
|
|
It really does depend on the implementation. Only the logical address space needs to be contiguous, not the underlying physical memory. A clever enough implementation could work hand-in-hand with a clever enough allocator, so that realloc would just add new logical pages to the end of the underlying buffer when it’s time to double its size without having to copy anything. |
|
At any-rate, it’s not like copying will happen anyways during GC.