Bug 19116

Summary: SquirrelFish shouldn't regress on variable lookups
Product: WebKit Reporter: Anthony Ricaud <rik>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: mjs, mrowe, oliver
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
URL: http://flesler.webs.com/Benchmark/vars/

Anthony Ricaud
Reported 2008-05-18 15:50:45 PDT
Nightlies have great performance improvements compared to Safari 3.1. SquirellFish shouldn't regress on that point. It's a test to compare lookups performance with variables in different scopes For the record, here are the results I have on my machine : FF3ß5 global : average : 44ms local1 : average : 57.6ms local2 : average : 55.8ms local3 : average : 36.4ms Opera 9.27 global : average : 79ms local1 : average : 78.4ms local2 : average : 79.2ms local3 : average : 74.8ms Opera 9.5 global : average : 51.4ms local1 : average : 26.8ms local2 : average : 35.6ms local3 : average : 24ms Safari 3.1 global : average : 90.8ms local1 : average : 54.8ms local2 : average : 44.8ms local3 : average : 34.4ms Webkit r33561 global : average : 17.8ms local1 : average : 17.4ms local2 : average : 16.4ms local3 : average : 16ms
Attachments
Anthony Ricaud
Comment 1 2008-05-18 16:06:07 PDT
The original blog post of the author for more information : http://flesler.blogspot.com/2008/04/benchmarking-javascript-variables-and.html
Mark Rowe (bdash)
Comment 2 2008-05-19 03:57:49 PDT
Are there measurements that suggest SquirrelFish is a regression over trunk on this microbenchmark?
Oliver Hunt
Comment 3 2008-05-19 04:01:54 PDT
Mark, this is basically the tracking bug for the multiscope optimisation, squirrelfish performance is currently effectively a faster version of S3.1 -- basically resolve time for an out of scope var is O(N) wrt to closure depth, vs. effectively O(1) on trunk
Oliver Hunt
Comment 4 2008-05-19 04:02:12 PDT
(I'm actually working on this atm)
Oliver Hunt
Comment 5 2008-05-21 01:50:32 PDT
resolve is corrected Committing to http://svn.webkit.org/repository/webkit/branches/squirrelfish ... M JavaScriptCore/ChangeLog M JavaScriptCore/VM/CodeBlock.cpp M JavaScriptCore/VM/CodeBlock.h M JavaScriptCore/VM/CodeGenerator.cpp M JavaScriptCore/VM/CodeGenerator.h M JavaScriptCore/VM/Machine.cpp M JavaScriptCore/VM/Opcode.h M JavaScriptCore/kjs/JSVariableObject.h Committed r33958 Looks to be twice as fast as in trunk, still have base resolution to go
Anthony Ricaud
Comment 6 2008-05-21 11:00:17 PDT
Squirellfish branch r33967: global : average : 9.6ms local1 : average : 8.8ms local2 : average : 8.4ms local3 : average : 8ms I think it's not regressing :)
Oliver Hunt
Comment 7 2008-05-22 12:38:02 PDT
Last fix (for read/write/modify operations) Committing to http://svn.webkit.org/repository/webkit/trunk ... M JavaScriptCore/ChangeLog M JavaScriptCore/kjs/nodes.cpp Committed r34030
Oliver Hunt
Comment 8 2008-05-25 22:01:19 PDT
*** Bug 18645 has been marked as a duplicate of this bug. ***
Oliver Hunt
Comment 9 2008-05-25 22:01:32 PDT
*** Bug 18823 has been marked as a duplicate of this bug. ***
Note You need to log in before you can comment on or make changes to this bug.