[Sugar-devel] Research: 0.84 Launcher Cost

Dipankar Patro dipankar at seeta.in
Thu Oct 28 10:00:40 EDT 2010


Hello James,

I was going through the discussion over the bug #2080 handled currently by
Anurag.

I too was thinking of replacing the animation algo, which currently is sine
function.
I was having some questions in mind after looking at your research.
"When launcher is disabled, the time saving is more, as compared to SVG
complexity."

If we are not for removing animation, then why not use a simple integer
based algorithm instead of a floating based sine algorithm. In terms of
graphics, integer based algorithms (Bresenham, Mid-point, etc) work faster
than floating point based.

If we can use a 'Busy-Cursor' then its fine.
But if we still want to continue with the animation, why not change the
algorithm for the animation that is done?

Regards,
Dipankar

On Thu, Oct 28, 2010 at 9:04 AM, James Cameron <quozl at laptop.org> wrote:

> Earlier in the context of SL#2080 patch review, I had said "the
> launcher is stealing CPU cycles from the startup of the activity, the
> task run queue shows this during a launch.  I wonder if activities
> might start up faster if there was no launcher, just a busy cursor."
>
> Looks like activities would start faster; between one and four seconds,
> mostly depending on the activity, and slightly depending on the icon
> complexity.
>
> Details below.
>
> --
>
> Research: will activities start faster if there is no launcher?
>
> Method: using an XO-1, freshly installed with Sugar 0.84.22, as part
> of OLPC OS 10.1.2 build os852, test the startup time of three
> activities (Memorize, Moon and Chat), remove the launcher, retest,
> subtract.
>
> The launcher is implemented by source file launcher.py in
> /usr/lib/python2.6/site-packages/jarabe/view/ ... the modification
> made is attached as a patch.
>
> The times were captured with a stopwatch.  The timing began when "Start"
> was selected from the list view, and ended once the activity had
> completed display of the UI.
>
> Result:
>
> a.  unmodified launcher.py
>
> Memorize-34 9.43s, 9.56s, 9.51s
> Moon-11 11.58s, 11.60s, 11.65s
> Chat-65 6.65s, 6.54s, 6.59s
>
> b.  modified launcher.py (black background, no animation),
>
> Memorize-34 7.60s, 7.63s, 7.60s
> Moon-11 7.78s, 7.78s, 7.95s
> Chat-65 5.04s, 4.93s, 4.88s
>
> c.  calculated cost of launcher
>
> Memorize-34 1.89s
> Moon-11 3.73s
> Chat-65 1.64s
>
> Diagnosis: removing the launcher animation saved between one and four
> seconds of startup time.  The saving was greatest for the Moon activity.
>
> --
>
> Research: determine if the SVG icon for the Moon activity contributes
> to the delay.
>
> Method: swap the icons, restart Sugar, retest only Chat activity with
> Moon icon.
>
> Result:
>
> a.  unmodified launcher.py
>
> Chat-65 7.83s, 7.59s, 7.62s
>
> b.  modified launcher.py (black background, no animation),
>
> Chat-65 4.99s, 4.87s, 4.90s
>
> c.  calculated cost of launcher
>
> Chat-65 2.75s (greater than previous)
>
> d.  calculated cost of moon icon over chat icon
>
> Chat-65 1.09s
>
> Diagnosis: the degree of saving has a little to do with the SVG icon
> complexity.  The degree of saving has much to do with the mix of
> operations performed by the activity during startup.
>
> --
>
> So, between 23 and 92 wasted days of looking at the launcher across
> two million laptops.  Good time to think and plan, kids.
>
> --
> James Cameron
> http://quozl.linux.org.au/
>
> _______________________________________________
> Sugar-devel mailing list
> Sugar-devel at lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/sugar-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sugarlabs.org/archive/sugar-devel/attachments/20101028/c83bed40/attachment-0001.html>


More information about the Sugar-devel mailing list