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

Issue 219153002: Optimize named property access on CSSStyleDeclaration objects (Closed)

Created:
6 years, 8 months ago by Jens Widell
Modified:
6 years, 8 months ago
CC:
blink-reviews, Nils Barth (inactive), kojih, arv+blink, jsbell+bindings_chromium.org, sof, kouhei+bindings_chromium.org, abarth-chromium, marja+watch_chromium.org, adamk+blink_chromium.org, haraken, Nate Chapin, Inactive
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

Optimize named property access on CSSStyleDeclaration objects When reading property on a CSSStyleDeclaration object, the property name is transformed into a possible CSS property name and looked up as such. This transformation involves copying the property name to a StringBuilder while converting from camelCase to dash-separated. Positive matches are cached in a local static hash map, but negative matches were not. A script reading properties like "getPropertyValue" would trigger the conversion to "get-property-value" and CSS property lookup every time. Optimize by caching negative matches as well as positive ones. BUG= Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=170490

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+132 lines, -47 lines) Patch
A PerformanceTests/CSS/CSSPropertySetterGetterMethods.html View 1 chunk +82 lines, -0 lines 0 comments Download
M Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp View 2 chunks +50 lines, -47 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Jens Widell
Found while investigating why a random site triggered lots of realloc() calls; turned out to ...
6 years, 8 months ago (2014-03-31 10:41:36 UTC) #1
abarth-chromium
lgtm
6 years, 8 months ago (2014-03-31 21:02:18 UTC) #2
abarth-chromium
The CQ bit was checked by abarth@chromium.org
6 years, 8 months ago (2014-03-31 21:02:26 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jl@opera.com/219153002/1
6 years, 8 months ago (2014-03-31 21:02:33 UTC) #4
commit-bot: I haz the power
6 years, 8 months ago (2014-04-01 00:00:29 UTC) #5
Message was sent while issue was closed.
Change committed as 170490

Powered by Google App Engine
This is Rietveld 408576698