Review Request: Four simple patches for kdecore
Dawit Alemayehu
adawit at kde.org
Sun Nov 7 18:04:03 GMT 2010
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://svn.reviewboard.kde.org/r/5775/#review8543
-----------------------------------------------------------
I am personally not conveinced the need for changing from usleep to nanosleep in this particular instance. IOW, usleep is sufficient in this case to warrant a change regardless of when that system call was made available...
/trunk/KDE/kdelibs/kdecore/util/kshareddatacache.cpp
<http://svn.reviewboard.kde.org/r/5775/#comment8911>
Hmm... why do unnecessary calculations in fast loops ? Surely "1<<21*10" can be hard coded with a #define.
/trunk/KDE/kdelibs/kdecore/util/kshareddatacache.cpp
<http://svn.reviewboard.kde.org/r/5775/#comment8912>
And of course if speed is an issue, which seemed to be the case since a left shift arithmetic was done above, this can be changed to a equivalent left shift operation:
usecSleepTime.tv_nsec = usecSleepTime.tv_nsec << 1;
- Dawit
On 2010-11-07 14:17:29, Jaime Torres wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://svn.reviewboard.kde.org/r/5775/
> -----------------------------------------------------------
>
> (Updated 2010-11-07 14:17:29)
>
>
> Review request for kdelibs.
>
>
> Summary
> -------
>
> As I do not know if that kind of patches are allowed in the freeze period, I ask for them together. I'll submit them individually.
>
> 1. ktimezone. Include a comment with the real use of refCount.
> 2. klocale_kde. From 469 queries to paths.end() to 1 (from 0.01% to 0% in callgrind)
> 3. netsupp. Remove a memory leak.
> 4. ksharedDataCache. Change the obsolete usleep (since 2001 or before) to nanosleep.
>
>
> Diffs
> -----
>
> /trunk/KDE/kdelibs/kdecore/date/ktimezone.cpp 1193582
> /trunk/KDE/kdelibs/kdecore/localization/klocale_kde.cpp 1193582
> /trunk/KDE/kdelibs/kdecore/network/netsupp.cpp 1193582
> /trunk/KDE/kdelibs/kdecore/util/kshareddatacache.cpp 1193582
>
> Diff: http://svn.reviewboard.kde.org/r/5775/diff
>
>
> Testing
> -------
>
> No regressions in the unit tests.
> Working with them.
>
>
> Thanks,
>
> Jaime
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20101107/8b822f65/attachment.htm>
More information about the kde-core-devel
mailing list