|
|
Kevin Wampler wrote:
> "This makes sense because modern operating systems don't copy the entire
> data when reallocating a buffer; the physical memory pages are simply
> reordered, and only the data on the first and last pages actually needs
> to be copied"
Well, yes, there is that. Hmmm... OK, it seems they do know what that's
about. I guess if you don't copy the pages in the middle of the string,
there's no need to double the size each time to get O(1) amortized growth.
--
Darren New, San Diego CA, USA (PST)
I ordered stamps from Zazzle that read "Place Stamp Here".
Post a reply to this message
|
|