Changeset 126201 in webkit
- Timestamp:
- Aug 21, 2012 3:51:54 PM (12 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r126199 r126201 1 2012-08-21 Tab Atkins <tabatkins@google.com> 2 3 Track -webkit property usage. 4 https://bugs.webkit.org/show_bug.cgi?id=93420 5 6 Reviewed by Ojan Vafai. 7 8 First draft of an attempt to track all usage of -webkit prefixed properties across the web. 9 This attempt is dumb, but should provide useful data as a first-pass. 10 I plan to optimize this for better data collection in the future. 11 12 No tests added, as this is untestable currently. 13 It should have zero effect besides histogramming. 14 15 * css/CSSParser.cpp: 16 (WebCore::cssPropertyID): 17 1 18 2012-08-21 Alec Flett <alecflett@chromium.org> 2 19 -
trunk/Source/WebCore/css/CSSParser.cpp
r126192 r126201 63 63 #include "HTMLParserIdioms.h" 64 64 #include "HashTools.h" 65 #include "HistogramSupport.h" 65 66 #include "MediaList.h" 66 67 #include "MediaQueryExp.h" … … 10125 10126 10126 10127 const Property* hashTableEntry = findProperty(name, length); 10127 return hashTableEntry ? static_cast<CSSPropertyID>(hashTableEntry->id) : CSSPropertyInvalid; 10128 const CSSPropertyID propertyID = hashTableEntry ? static_cast<CSSPropertyID>(hashTableEntry->id) : CSSPropertyInvalid; 10129 10130 // 600 is comfortably larger than numCSSProperties to allow for growth 10131 static const int CSSPropertyHistogramSize = 600; 10132 COMPILE_ASSERT(CSSPropertyHistogramSize > numCSSProperties, number_of_css_properties_exceed_CSSPropertyHistogramSize); 10133 10134 if (hasPrefix(buffer, length, "-webkit-") && propertyID != CSSPropertyInvalid) 10135 HistogramSupport::histogramEnumeration("CSS.PrefixUsage", max(1, propertyID - firstCSSProperty), CSSPropertyHistogramSize); 10136 10137 return propertyID; 10128 10138 } 10129 10139
Note: See TracChangeset
for help on using the changeset viewer.