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

Issue 105163003: Cache length in ElementData::getAttributeItemIndex() for performance (Closed)

Created:
7 years ago by Inactive
Modified:
7 years ago
CC:
blink-reviews, dglazkov+blink, eae+blinkwatch, adamk+blink_chromium.org, atreat
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

Cache length in ElementData::getAttributeItemIndex() for performance Cache length in ElementData::getAttributeItemIndex() for performance. We should avoid to call ElementData::length() in a loop as it hides an if check to see if the ElementData is unique or not. I see a 2.8% improvement on Bindings/id-setter.html performance test on Linux desktop. This minimizes the performance regression caused by r157508. R=arv, esprehn BUG=293663 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=163216

Patch Set 1 #

Total comments: 1

Patch Set 2 : Add comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -1 line) Patch
M Source/core/dom/ElementData.h View 1 2 chunks +4 lines, -1 line 0 comments Download

Messages

Total messages: 8 (0 generated)
Inactive
https://codereview.chromium.org/105163003/diff/1/Source/core/dom/ElementData.h File Source/core/dom/ElementData.h (right): https://codereview.chromium.org/105163003/diff/1/Source/core/dom/ElementData.h#newcode201 Source/core/dom/ElementData.h:201: unsigned len = length(); Note that we already cache ...
7 years ago (2013-12-04 19:14:30 UTC) #1
arv (Not doing code reviews)
LGTM
7 years ago (2013-12-04 19:43:47 UTC) #2
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ch.dumez@samsung.com/105163003/1
7 years ago (2013-12-04 19:45:26 UTC) #3
commit-bot: I haz the power
Retried try job too often on linux_blink for step(s) blink_platform_unittests, webkit_lint, webkit_python_tests, webkit_tests, webkit_unit_tests, wtf_unittests ...
7 years ago (2013-12-04 20:31:46 UTC) #4
esprehn
Can you add a comment before landing? Someone is just going to remove this in ...
7 years ago (2013-12-04 20:35:37 UTC) #5
Inactive
On 2013/12/04 20:35:37, esprehn wrote: > Can you add a comment before landing? Someone is ...
7 years ago (2013-12-04 20:40:17 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ch.dumez@samsung.com/105163003/20001
7 years ago (2013-12-05 00:49:03 UTC) #7
commit-bot: I haz the power
7 years ago (2013-12-05 04:13:11 UTC) #8
Message was sent while issue was closed.
Change committed as 163216

Powered by Google App Engine
This is Rietveld 408576698