Bug 151464 - B3 should have a story for Ext/Trunc strength reduction
Summary: B3 should have a story for Ext/Trunc strength reduction
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Filip Pizlo
URL:
Keywords:
Depends on:
Blocks: 151428
  Show dependency treegraph
 
Reported: 2015-11-19 14:15 PST by Filip Pizlo
Modified: 2015-11-19 15:36 PST (History)
12 users (show)

See Also:


Attachments
the patch (13.95 KB, patch)
2015-11-19 14:56 PST, Filip Pizlo
ggaren: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Filip Pizlo 2015-11-19 14:15:45 PST
The LLVM shift operations require the shift amount to have the same type as the shift base. The B3 shift operations require the shift amount to be an Int32. DFG concurs with this. But the initial lowering will probably involve pretending the FTLOutput's shift operations still take an LLVM-style shift amount, and then on B3 they will emit a Trunc. That means that we'll want to be able to constant fold Trunc and be able to fold Trunc(ZExt).
Comment 1 Filip Pizlo 2015-11-19 14:56:11 PST
Created attachment 265907 [details]
the patch
Comment 2 WebKit Commit Bot 2015-11-19 15:08:27 PST
Attachment 265907 [details] did not pass style-queue:


ERROR: Source/JavaScriptCore/ftl/FTLB3Output.cpp:133:  Multi line control clauses should use braces.  [whitespace/braces] [4]
Total errors found: 1 in 7 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Geoffrey Garen 2015-11-19 15:18:38 PST
Comment on attachment 265907 [details]
the patch

r=me
Comment 4 Filip Pizlo 2015-11-19 15:36:13 PST
Landed in http://trac.webkit.org/changeset/192665