POV-Ray : Newsgroups : povray.off-topic : Trolltech doesn't know how amortized time works : Re: Trolltech doesn't know how amortized time works Server Time
4 Sep 2024 21:21:15 EDT (-0400)
  Re: Trolltech doesn't know how amortized time works  
From: Kevin Wampler
Date: 2 Nov 2009 22:29:38
Message: <4aefa3a2$1@news.povray.org>
Darren New wrote:
> 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.


In general my experience with using Qt has been extremely positive, so I 
  would have been surprised had they made a mistake of that magnitude. 
Still, I certainly didn't anticipate that the algorithm they use would 
actually be O(1), so it was quite cool to see that it was.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.