Bug 150850 - Fix some inefficiencies in the baseline usage of JITAddGenerator.
Summary: Fix some inefficiencies in the baseline usage of JITAddGenerator.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Local Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Mark Lam
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-11-03 13:10 PST by Mark Lam
Modified: 2015-11-03 14:15 PST (History)
1 user (show)

See Also:


Attachments
the patch. (2.50 KB, patch)
2015-11-03 13:13 PST, Mark Lam
msaboff: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Lam 2015-11-03 13:10:00 PST
1. emit_op_add() was loading the operands twice.  Removed the redundant load.
2. The snippet may decide that it wants to go the slow path route all the time.  In that case, emit_op_add will end up emitting a branch to an out of line slow path followed by some dead code to store the result of the fast path on to the stack.  We now check if the snippet determined that there's no fast path, and just emit the slow path inline, and skip the dead store of the fast path result.
Comment 1 Mark Lam 2015-11-03 13:13:01 PST
Created attachment 264716 [details]
the patch.
Comment 2 Michael Saboff 2015-11-03 14:08:50 PST
Comment on attachment 264716 [details]
the patch.

r=me
Comment 3 Mark Lam 2015-11-03 14:15:23 PST
Thanks.  Landed in r191978: <http://trac.webkit.org/r191978>.