RESOLVED FIXED 161729
We should inline operationConvertJSValueToBoolean into JIT code
https://bugs.webkit.org/show_bug.cgi?id=161729
Summary We should inline operationConvertJSValueToBoolean into JIT code
Saam Barati
Reported 2016-09-07 19:23:40 PDT
Speedometer spends around 1% of its time in this function. Lets inline it to not pay for the overhead of the call.
Attachments
WIP (26.20 KB, patch)
2016-09-07 19:26 PDT, Saam Barati
no flags
patch (26.45 KB, patch)
2016-09-08 14:43 PDT, Saam Barati
no flags
patch (25.55 KB, patch)
2016-09-08 14:44 PDT, Saam Barati
fpizlo: review-
patch (26.96 KB, patch)
2016-09-08 14:59 PDT, Saam Barati
no flags
Saam Barati
Comment 1 2016-09-07 19:26:49 PDT
Created attachment 288226 [details] WIP This patch has some other stuff for HasOwnProperty that I was experimenting with. The interesting bits related to this bug are the AssemblyHelpers function: convertValueToBoolean
Saam Barati
Comment 2 2016-09-07 19:27:09 PDT
I still need to make masqueradesAsUndefined work as expected.
Saam Barati
Comment 3 2016-09-08 14:43:10 PDT
Saam Barati
Comment 4 2016-09-08 14:44:24 PDT
WebKit Commit Bot
Comment 5 2016-09-08 14:46:04 PDT
Attachment 288329 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/jit/AssemblyHelpers.h:1530: The parameter name "value" adds no information, so it should be removed. [readability/parameter_name] [5] Total errors found: 1 in 9 files If any of these errors are false positives, please file a bug against check-webkit-style.
Filip Pizlo
Comment 6 2016-09-08 14:47:20 PDT
Comment on attachment 288329 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=288329&action=review > Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp:1694 > + bool shouldCheckMasqueradesAsUndefined = !masqueradesAsUndefinedWatchpointIsStillValid(); Where do you register the MasqueradesAsUndefined watchpoint? Hint: everyone else seems to do it in FixupPhase. > Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp:1840 > + bool shouldCheckMasqueradesAsUndefined = !masqueradesAsUndefinedWatchpointIsStillValid(); Ditto. > Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp:1843 > + bool shouldCheckMasqueradesAsUndefined = !masqueradesAsUndefinedWatchpointIsStillValid(); Ditto. > Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp:2002 > + bool shouldCheckMasqueradesAsUndefined = !masqueradesAsUndefinedWatchpointIsStillValid(); Ditto.
Saam Barati
Comment 7 2016-09-08 14:59:42 PDT
Created attachment 288332 [details] patch Nice catch. Fixed.
WebKit Commit Bot
Comment 8 2016-09-08 15:01:41 PDT
Attachment 288332 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/jit/AssemblyHelpers.h:1530: The parameter name "value" adds no information, so it should be removed. [readability/parameter_name] [5] Total errors found: 1 in 10 files If any of these errors are false positives, please file a bug against check-webkit-style.
WebKit Commit Bot
Comment 9 2016-09-08 16:21:39 PDT
Comment on attachment 288332 [details] patch Clearing flags on attachment: 288332 Committed r205675: <http://trac.webkit.org/changeset/205675>
WebKit Commit Bot
Comment 10 2016-09-08 16:21:45 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.