Changes between Version 1 and Version 2 of Performance Tests


Ignore:
Timestamp:
Dec 17, 2012, 11:30:01 AM (12 years ago)
Author:
eric@webkit.org
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Performance Tests

    v1 v2  
    160160
    161161If python exceptions or other serious errors persist, or the ratio of standard deviation to mean is consistently higher than 7-10%, don't add the URL as a replay test regardless of how important that website is because we can't make a use of performance tests that have 10% variance.
     162
     163
     164= Profiling Performance Tests =
     165
     166{{{run-perf-tests --profile}}} can be used to attach and run the default platform CPU profiler against the provided test(s).
     167
     168Additionally, the {{{--profiler=PROFILER}}} option can select which profiler to use from the built-in profilers:
     169
     170|| perf || linux (default) ||
     171|| iprofiler || mac (default) ||
     172|| sample || mac ||
     173|| pprof || mac, linux (chromium-only, requires using tcmalloc) ||
     174
     175For perf and pprof profilers {{{--profile}}} provides per-test "10 hottest functions" output, which is useful for obtaining a high level overview of where the test is spending it's time.  This has been surprisingly helpful for finding hot non-inlined functions, or other low-hanging fruit.
     176
     177{{{
     178% run-perf-tests --profile
     179Running 113 tests
     180Running Animation/balls.html (1 of 113)
     181Finished: 3.079851 s
     182
     183[ perf record: Woken up 3 times to write data ]
     184[ perf record: Captured and wrote 0.678 MB /src/WebKit/Source/WebKit/chromium/webkit/Release/layout-test-results/test-44.data (~29642 samples) ]
     185     5.99%  DumpRenderTree  perf-5981.map            [.] 0x250f5ef06321 
     186     2.46%  DumpRenderTree  DumpRenderTree           [.] v8::internal::FastDtoa(double, v8::internal::FastDtoaMode, int, v8::internal::Vector<char>, int*, int*)
     187     1.86%  DumpRenderTree  DumpRenderTree           [.] WebCore::Length::initFromLength(WebCore::Length const&)
     188     1.74%  DumpRenderTree  DumpRenderTree           [.] WebCore::RenderStyle::diff(WebCore::RenderStyle const*, unsigned int&) const
     189     1.69%  DumpRenderTree  libfreetype.so.6.8.0     [.] 0x493ab         
     190     1.35%  DumpRenderTree  DumpRenderTree           [.] tc_free
     191     1.30%  DumpRenderTree  [kernel.kallsyms]        [k] 0xffffffff8103b51a
     192     1.27%  DumpRenderTree  DumpRenderTree           [.] tc_malloc
     193     1.25%  DumpRenderTree  DumpRenderTree           [.] v8::internal::JSObject::SetPropertyWithInterceptor(v8::internal::String*, v8::internal::Object*, PropertyAttributes, v8::internal::StrictModeFlag)
     194     1.22%  DumpRenderTree  DumpRenderTree           [.] WTF::double_conversion::Strtod(WTF::double_conversion::Vector<char const>, int)
     195
     196To view the full profile, run:
     197perf report -i /src/WebKit/Source/WebKit/chromium/webkit/Release/layout-test-results/test-44.data
     198}}}
     199(Note: perf prints out a bunch of kernel-related warnings which I've stripped from the above output sample.)
     200
     201For more in-depth analysis, all profilers print instructions after profiling as to how to explore the full sample data, as shown above.