Bug 86696 - [Performance test] Support "description" for PerfTestRunner.run and PerfTestRunner.runPerSecond
Summary: [Performance test] Support "description" for PerfTestRunner.run and PerfTestR...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Kentaro Hara
URL:
Keywords:
Depends on:
Blocks: 86582
  Show dependency treegraph
 
Reported: 2012-05-16 19:13 PDT by Kentaro Hara
Modified: 2012-05-17 04:07 PDT (History)
6 users (show)

See Also:


Attachments
Patch (6.62 KB, patch)
2012-05-16 19:19 PDT, Kentaro Hara
no flags Details | Formatted Diff | Diff
patch for landing (5.82 KB, patch)
2012-05-16 19:32 PDT, Kentaro Hara
no flags Details | Formatted Diff | Diff
Patch (1.56 KB, patch)
2012-05-17 00:30 PDT, Kentaro Hara
no flags Details | Formatted Diff | Diff
patch for landing (1.83 KB, patch)
2012-05-17 00:43 PDT, Kentaro Hara
no flags Details | Formatted Diff | Diff
Patch (3.21 KB, patch)
2012-05-17 03:04 PDT, Kentaro Hara
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kentaro Hara 2012-05-16 19:13:34 PDT
We want to add some description for each run, so that people can know what each run is testing.
Comment 1 Kentaro Hara 2012-05-16 19:19:31 PDT
Created attachment 142394 [details]
Patch
Comment 2 Ryosuke Niwa 2012-05-16 19:23:00 PDT
Comment on attachment 142394 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=142394&action=review

> Tools/ChangeLog:16
> +        DESCRIPTION: Benchmark for DOM attributes that return a Node object.

Nice!

> Tools/Scripts/webkitpy/performance_tests/perftest.py:98
> +        description_regex = re.compile(r'^description (?P<description>.*)$')

We should probably ignore cases here :)

> PerformanceTests/resources/runner.js:97
> +        this.log("description " + description);

Why don't we capitalize description and put a comma as in: "Description: ~~~"

> PerformanceTests/resources/runner.js:126
> +        this.logStatistics(this._results, this._description);

It seems odd that a function named logStatistics also prints description. Why don't we put the code here instead?
Comment 3 Kentaro Hara 2012-05-16 19:32:18 PDT
Created attachment 142397 [details]
patch for landing
Comment 4 Kentaro Hara 2012-05-16 19:32:49 PDT
(In reply to comment #2)
> > Tools/Scripts/webkitpy/performance_tests/perftest.py:98
> > +        description_regex = re.compile(r'^description (?P<description>.*)$')
> 
> We should probably ignore cases here :)

Done.

> > PerformanceTests/resources/runner.js:97
> > +        this.log("description " + description);
> 
> Why don't we capitalize description and put a comma as in: "Description: ~~~"

Done.

> > PerformanceTests/resources/runner.js:126
> > +        this.logStatistics(this._results, this._description);
> 
> It seems odd that a function named logStatistics also prints description. Why don't we put the code here instead?

Done.
Comment 5 WebKit Review Bot 2012-05-16 22:15:31 PDT
Comment on attachment 142397 [details]
patch for landing

Clearing flags on attachment: 142397

Committed r117397: <http://trac.webkit.org/changeset/117397>
Comment 6 Csaba Osztrogonác 2012-05-17 00:22:40 PDT
(In reply to comment #5)
> (From update of attachment 142397 [details])
> Clearing flags on attachment: 142397
> 
> Committed r117397: <http://trac.webkit.org/changeset/117397>

It broke perf tests on the bot:

Running PageLoad/svg/files/42450-under the see.svg (53 of 71)
Traceback (most recent call last):
  File "./Tools/Scripts/run-perf-tests", line 39, in <module>
    sys.exit(PerfTestsRunner().run())
  File "/home/webkitbuildbot/slaves/release64bitWebKit2-perf/buildslave/qt-linux-64-release-wk2-perf-tests/build/Tools/Scripts/webkitpy/performance_tests/perftestsrunner.py", line 138, in run
    unexpected = self._run_tests_set(sorted(list(tests), key=lambda test: test.test_name()), self._port)
  File "/home/webkitbuildbot/slaves/release64bitWebKit2-perf/buildslave/qt-linux-64-release-wk2-perf-tests/build/Tools/Scripts/webkitpy/performance_tests/perftestsrunner.py", line 226, in _run_tests_set
    if self._run_single_test(test, driver):
  File "/home/webkitbuildbot/slaves/release64bitWebKit2-perf/buildslave/qt-linux-64-release-wk2-perf-tests/build/Tools/Scripts/webkitpy/performance_tests/perftestsrunner.py", line 240, in _run_single_test
    new_results = test.run(driver, self._options.time_out_ms)
  File "/home/webkitbuildbot/slaves/release64bitWebKit2-perf/buildslave/qt-linux-64-release-wk2-perf-tests/build/Tools/Scripts/webkitpy/performance_tests/perftest.py", line 194, in run
    self.output_statistics(self.test_name(), results)
  File "/home/webkitbuildbot/slaves/release64bitWebKit2-perf/buildslave/qt-linux-64-release-wk2-perf-tests/build/Tools/Scripts/webkitpy/performance_tests/perftest.py", line 132, in output_statistics
    if results['description']:
KeyError: 'description'
Comment 7 Kentaro Hara 2012-05-17 00:23:41 PDT
(In reply to comment #6)
> It broke perf tests on the bot:

looking
Comment 8 Ryosuke Niwa 2012-05-17 00:26:54 PDT
Comment on attachment 142397 [details]
patch for landing

View in context: https://bugs.webkit.org/attachment.cgi?id=142397&action=review

> Tools/Scripts/webkitpy/performance_tests/perftest.py:132
> +        if results['description']:

Oops, you can't assume that results['description'] is always yet :(
Comment 9 Kentaro Hara 2012-05-17 00:30:39 PDT
Reopening to attach new patch.
Comment 10 Kentaro Hara 2012-05-17 00:30:43 PDT
Created attachment 142431 [details]
Patch
Comment 11 Ryosuke Niwa 2012-05-17 00:31:55 PDT
Comment on attachment 142431 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=142431&action=review

> Tools/Scripts/webkitpy/performance_tests/perftest.py:193
> +            'description': '',

How about ChromiumStylePerfTest ?
Comment 12 Kentaro Hara 2012-05-17 00:37:13 PDT
(In reply to comment #11)
> How about ChromiumStylePerfTest ?

I want to fix it and confirm the bahavior, but how can I run ChromiumStylePerfTest?
Comment 13 Ryosuke Niwa 2012-05-17 00:40:27 PDT
(In reply to comment #12)
> (In reply to comment #11)
> > How about ChromiumStylePerfTest ?
> 
> I want to fix it and confirm the bahavior, but how can I run ChromiumStylePerfTest?

Tests in PerformanceTests/Inspector. However, they're skipped now.
Comment 14 Kentaro Hara 2012-05-17 00:43:58 PDT
Created attachment 142434 [details]
patch for landing
Comment 15 Kentaro Hara 2012-05-17 00:45:24 PDT
Committed r117410: <http://trac.webkit.org/changeset/117410>
Comment 16 Csaba Osztrogonác 2012-05-17 02:47:16 PDT
(In reply to comment #15)
> Committed r117410: <http://trac.webkit.org/changeset/117410>

perf test is still broken, but with another error message:
Uploaded JSON but got a bad response:
The payload doesn't contain results or results are malformed
Comment 17 Kentaro Hara 2012-05-17 02:52:14 PDT
It seems that we need to fix the server side too. Just a moment...
Comment 18 Kentaro Hara 2012-05-17 03:04:01 PDT
Reopening to attach new patch.
Comment 19 Kentaro Hara 2012-05-17 03:04:05 PDT
Created attachment 142446 [details]
Patch
Comment 20 Csaba Osztrogonác 2012-05-17 03:07:26 PDT
Comment on attachment 142446 [details]
Patch

LGTM, r=me.
Comment 21 Kentaro Hara 2012-05-17 03:09:17 PDT
Committed r117422: <http://trac.webkit.org/changeset/117422>
Comment 22 Csaba Osztrogonác 2012-05-17 03:53:19 PDT
And I realized that unit tests are bleeding too: http://build.webkit.org/builders/Qt%20Linux%20Release/builds/47128/steps/webkitpy-test/logs/stdio
Comment 23 Kentaro Hara 2012-05-17 04:00:50 PDT
(In reply to comment #22)
> And I realized that unit tests are bleeding too: http://build.webkit.org/builders/Qt%20Linux%20Release/builds/47128/steps/webkitpy-test/logs/stdio

Is this failure still happening even after landing r117422? Now 'results' does not have 'description'.
Comment 24 Csaba Osztrogonác 2012-05-17 04:07:09 PDT
(In reply to comment #23)
> (In reply to comment #22)
> > And I realized that unit tests are bleeding too: http://build.webkit.org/builders/Qt%20Linux%20Release/builds/47128/steps/webkitpy-test/logs/stdio
> 
> Is this failure still happening even after landing r117422? Now 'results' does not have 'description'.

Oh, sorry for the noise r117422 fixed all of them, but bots are in late.