[KPhotoAlbum] Big performance problem with QDateTime

Robert Krawitz rlk at alum.mit.edu
Sun Sep 20 22:43:26 BST 2020


On 9/20/20 5:29 PM, Johannes Zarl-Zierl wrote:
> Hi,
> 
> Am Sonntag, 20. September 2020, 17:38:25 CEST schrieb Robert Krawitz:
>>> And adding the ms representation since the epoch of the date and time as a
>>> member variable, along with a boolean one that indicates if the cache
>>> should be recomputed next time it's requested should be trivial to add.
>>> Without breaking the API.
>>>
>>> Thanks for tracking this down :-)
>>
>> I'd like to get the patch in anyway, if you and Johannes don't object.  Even
>> if Qt fixes it, it's going to take a while for the fix there to make it
>> out, and in the interim it's drastically slowing things down here.
> 
> I'll sleep on it and see if we can encapsulate this a little better or make it 
> nicer to read - I fear that by the time Qt catches up and removes the 
> performance bottleneck we have no idea why we convert to seconds since epoch 
> in the first place.
> 
> Apart from that, I concur that we should fix this on our side for now...

Does this comment help?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: qdatetime-perf-1.patch
Type: text/x-patch
Size: 5129 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kphotoalbum/attachments/20200920/79c9f920/attachment.bin>


More information about the Kphotoalbum mailing list