Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(397)

Issue 9379023: Tweaks for improving file manager performance (Closed)

Created:
8 years, 10 months ago by Rick Byers
Modified:
8 years, 9 months ago
CC:
chromium-reviews, rginda+watch_chromium.org, arv (Not doing code reviews), achuith+watch_chromium.org, bshe, Kevin Greer, Vladislav Kaznacheev
Visibility:
Public.

Description

Improving file manager js/css performance This change attempts to reduce the load time of the file manager (especially on slow Alex devices) by trimming unnecessary work done in javascript and reducing layouts. - Enable batch updating in cr.ui.Table (exactly how it's done in cr.ui.List). - Add more 'on complete' callbacks to some of the FileManager infrastructure so we know when to stop batch UI updates. - Use batch updates for some operations which profiling indicates causes non-trivial amounts of duplicated work. In particular, in my testing this reduces the number of (sometimes expensive) List.redraw() calls on startup for the table from 6 down to 1, and for the roots list from 4 down to 2. Measurements on alex are quite variable, but these changes result in about 70ms savings on startup (or about 17% of the time spent under 'v8.callChromeHiddenMethod' - i.e. JS callbacks through the extension system, which itself is about 1/3rd of total load time). The majority of file manager load time is spent inside of v8, and there are many more opportunities like these to trim various code paths. But it seems clear that major improvements are going to require more drastic approaches (eg. I'm experimenting with painting the initial UI after parsing/running a small fraction of the JS). BUG=105181 TEST= Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=124674

Patch Set 1 #

Patch Set 2 : Finish plumbing callbacks through #

Total comments: 4

Patch Set 3 : Fix comment typo #

Total comments: 8

Patch Set 4 : Style tweaks based on CR feedback from Arv #

Patch Set 5 : Non-trivial merge with trunk #

Total comments: 6

Patch Set 6 : Apply CR feedback #

Patch Set 7 : Fix merge #

Patch Set 8 : Fix comment typo #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+93 lines, -27 lines) Patch
M chrome/browser/resources/file_manager/js/directory_model.js View 1 2 3 4 5 6 chunks +29 lines, -12 lines 0 comments Download
M chrome/browser/resources/file_manager/js/file_manager.js View 1 2 3 4 5 6 7 7 chunks +39 lines, -15 lines 1 comment Download
M chrome/browser/resources/shared/js/cr/ui/table.js View 1 1 chunk +10 lines, -0 lines 0 comments Download
M chrome/browser/resources/shared/js/cr/ui/table/table_header.js View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download

Messages

Total messages: 19 (0 generated)
Rick Byers
Robert, can you please review these file manager changes? Erik, please review the small cr.ui.Table ...
8 years, 9 months ago (2012-02-28 18:16:59 UTC) #1
rginda
file_manager changes lgtm with one comment and a typo. http://codereview.chromium.org/9379023/diff/2001/chrome/browser/resources/file_manager/js/file_manager.js File chrome/browser/resources/file_manager/js/file_manager.js (right): http://codereview.chromium.org/9379023/diff/2001/chrome/browser/resources/file_manager/js/file_manager.js#newcode757 chrome/browser/resources/file_manager/js/file_manager.js:757: ...
8 years, 9 months ago (2012-02-28 18:38:35 UTC) #2
Rick Byers
Thanks Robert! http://codereview.chromium.org/9379023/diff/2001/chrome/browser/resources/file_manager/js/file_manager.js File chrome/browser/resources/file_manager/js/file_manager.js (right): http://codereview.chromium.org/9379023/diff/2001/chrome/browser/resources/file_manager/js/file_manager.js#newcode757 chrome/browser/resources/file_manager/js/file_manager.js:757: self.rootsList_.endBatchUpdates(); On 2012/02/28 18:38:35, rginda wrote: > ...
8 years, 9 months ago (2012-02-28 19:56:26 UTC) #3
arv (Not doing code reviews)
LGTM with nits http://codereview.chromium.org/9379023/diff/9001/chrome/browser/resources/file_manager/js/directory_model.js File chrome/browser/resources/file_manager/js/directory_model.js (right): http://codereview.chromium.org/9379023/diff/9001/chrome/browser/resources/file_manager/js/directory_model.js#newcode533 chrome/browser/resources/file_manager/js/directory_model.js:533: * @param {function} opt_loadedCallback Invoked when ...
8 years, 9 months ago (2012-02-28 20:26:32 UTC) #4
Rick Byers
Thanks Erik. http://codereview.chromium.org/9379023/diff/9001/chrome/browser/resources/file_manager/js/directory_model.js File chrome/browser/resources/file_manager/js/directory_model.js (right): http://codereview.chromium.org/9379023/diff/9001/chrome/browser/resources/file_manager/js/directory_model.js#newcode533 chrome/browser/resources/file_manager/js/directory_model.js:533: * @param {function} opt_loadedCallback Invoked when the ...
8 years, 9 months ago (2012-02-28 20:35:00 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rbyers@chromium.org/9379023/10003
8 years, 9 months ago (2012-02-29 14:41:31 UTC) #6
commit-bot: I haz the power
Can't apply patch for file chrome/browser/resources/file_manager/js/directory_model.js. While running patch -p1 --forward --force; patching file chrome/browser/resources/file_manager/js/directory_model.js ...
8 years, 9 months ago (2012-02-29 14:41:40 UTC) #7
rginda
On 2012/02/28 19:56:26, Rick Byers wrote: > Thanks Robert! > > http://codereview.chromium.org/9379023/diff/2001/chrome/browser/resources/file_manager/js/file_manager.js > File chrome/browser/resources/file_manager/js/file_manager.js ...
8 years, 9 months ago (2012-02-29 19:32:36 UTC) #8
Rick Byers
+kaznacheev Vladislav, I merged this with your related change that went in this morning. The ...
8 years, 9 months ago (2012-02-29 20:37:11 UTC) #9
Vladislav Kaznacheev
Hi Rick, I am sorry my commit got in the way. You are doing wonderful ...
8 years, 9 months ago (2012-02-29 21:04:48 UTC) #10
SeRya
This code may reduce time of initial directory scan but potentially significantly increase time when ...
8 years, 9 months ago (2012-03-01 09:59:47 UTC) #11
Rick Byers
On 2012/03/01 09:59:47, SeRya wrote: > This code may reduce time of initial directory scan ...
8 years, 9 months ago (2012-03-01 22:00:09 UTC) #12
Rick Byers
Thanks for the feedback Vlad - please take another look. Regarding the incremental updates issue ...
8 years, 9 months ago (2012-03-02 00:19:45 UTC) #13
SeRya
On 2012/03/01 22:00:09, Rick Byers wrote: > On 2012/03/01 09:59:47, SeRya wrote: > > This ...
8 years, 9 months ago (2012-03-02 12:10:08 UTC) #14
Rick Byers
On 2012/03/02 12:10:08, SeRya wrote: > On 2012/03/01 22:00:09, Rick Byers wrote: > > On ...
8 years, 9 months ago (2012-03-02 15:12:02 UTC) #15
Vladislav Kaznacheev
lgtm
8 years, 9 months ago (2012-03-02 15:31:08 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rbyers@chromium.org/9379023/26009
8 years, 9 months ago (2012-03-02 15:48:37 UTC) #17
commit-bot: I haz the power
Change committed as 124674
8 years, 9 months ago (2012-03-02 17:20:26 UTC) #18
zel
8 years, 9 months ago (2012-03-03 00:31:58 UTC) #19
On 2012/03/02 17:20:26, I haz the power (commit-bot) wrote:
> Change committed as 124674

Reverted - caused regression
http://code.google.com/p/chromium-os/issues/detail?id=27241

Powered by Google App Engine
This is Rietveld 408576698