RESOLVED FIXED158050
[JSC] Allow JSBench to use precise time
https://bugs.webkit.org/show_bug.cgi?id=158050
Summary [JSC] Allow JSBench to use precise time
Yusuke Suzuki
Reported 2016-05-24 19:27:05 PDT
[JSC] Allow JSBench to use precise time
Attachments
Patch (26.04 KB, patch)
2016-05-24 19:58 PDT, Yusuke Suzuki
no flags
Patch (46.38 KB, patch)
2016-05-26 03:34 PDT, Yusuke Suzuki
ggaren: review+
Yusuke Suzuki
Comment 1 2016-05-24 19:58:02 PDT
Geoffrey Garen
Comment 2 2016-05-25 09:46:27 PDT
Comment on attachment 279736 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=279736&action=review > Tools/Scripts/run-jsc-benchmarks:1034 > + doublePuts($stderr,file,"function currentTimeInMS(msg)") Perhaps I missed it, but I don't see an implementation of currentTimeInMS outside the run-jsc-benchmarks script. We'd like these tests to support running in DRT or Safari as well. Can you add an implementation of currentTimeInMS to harness.html? performance.now() is probably the best thing to use in the browser.
Yusuke Suzuki
Comment 3 2016-05-26 03:29:56 PDT
Comment on attachment 279736 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=279736&action=review >> Tools/Scripts/run-jsc-benchmarks:1034 >> + doublePuts($stderr,file,"function currentTimeInMS(msg)") > > Perhaps I missed it, but I don't see an implementation of currentTimeInMS outside the run-jsc-benchmarks script. We'd like these tests to support running in DRT or Safari as well. Can you add an implementation of currentTimeInMS to harness.html? performance.now() is probably the best thing to use in the browser. Oh, thanks! I thought these tests are only used from run-jsc-benchmark. I've added currentTimeInMS implementaiton in JSBench/harness.js and each html files. HTML files implementation is required when it is not executed under the harness. If it is executed in JSBench's harness, harness.js's implementation is required. And run-jsc-benchmark's implementation is required when it is executed with run-jsc-benchmark.
Yusuke Suzuki
Comment 4 2016-05-26 03:34:17 PDT
Geoffrey Garen
Comment 5 2016-05-26 12:28:18 PDT
Comment on attachment 279875 [details] Patch r=me
Yusuke Suzuki
Comment 6 2016-05-26 17:39:04 PDT
Note You need to log in before you can comment on or make changes to this bug.