cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Maj <...@adobe.com>
Subject Re: Plugin loading times - Android
Date Mon, 15 Jul 2013 18:41:07 GMT
Yep, Andrew's summary sounds about right.

Interesting that XHR vs. script tag injection leads to such differences.

I would be interested to see these same tests run on iOS, BB10, WP7+8
devices.

David did you happen to automate these steps somehow ? I wouldn't mind
running these tests on other devices/platforms that I have handy.

On 7/15/13 9:08 AM, "Andrew Grieve" <agrieve@chromium.org> wrote:

>Thanks for looking into this David!
>
>To summarize your results - it looks like:
>a) For some reason moving the script tag being injected instead of using
>an
>XHR made loading faster
>b) Having all plugin files being loaded separately *is* slowing our
>start-up time down, but not by enough that it's an urgent issue.
>
>
>On Mon, Jul 15, 2013 at 10:51 AM, David Kemp <drkemp@google.com> wrote:
>
>> The following are obtained by running the mobilespec suite - all tests
>> The tests were run on a physical nexus 7
>>
>> Summary:
>> * on Android , removing the xhr trims off about 250ms on load of
>> mobilespec.
>> * the multi-file plugin loading takes about 1.6 times as long as a
>>single
>> file
>>
>> Details
>> In each case below:
>> * the first log line is written immediately on load.
>> * the second line is written when you press 'Automatic Test'
>> * the third line is written when you press 'Run All Tests'
>> The times are different because of caching that takes place, so the
>>first
>> one is most interesting.
>>
>> Case 1: This case is manually constructed, lumping all plugin js files
>> together.
>> With plugins loaded in a single file + cordova_plugins.js(no xhr):
>> - plugin loading took 211ms
>> - plugin loading took 56ms
>> - plugin loading took 83ms
>>
>> Case 2: This case is what the 3.0 version did until:
>> CB-4016 /
>> https://git-wip-us.apache.org/repos/asf?p=cordova-js.git;h=0ce4718
>> With plugins loaded separately (about 60 files):
>> - plugin loading took 598ms
>> - plugin loading took 124ms
>> - plugin loading took 279ms
>>
>> Case 3: This case is what the 3.0 version does after:
>> CB-4016 /
>> https://git-wip-us.apache.org/repos/asf?p=cordova-js.git;h=0ce4718
>> With plugins loaded separately *withou*t xhr (about 60 files):
>> - plugin loading took 336ms
>> - plugin loading took 112ms
>> - plugin loading took 260ms
>>


Mime
View raw message