Bug 151423 - FTL should be able to compile a small function with B3
Summary: FTL should be able to compile a small function with B3
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: 150279
  Show dependency treegraph
 
Reported: 2015-11-18 16:24 PST by Filip Pizlo
Modified: 2015-11-18 18:48 PST (History)
6 users (show)

See Also:


Attachments
work in progress (57.66 KB, patch)
2015-11-18 16:25 PST, Filip Pizlo
no flags Details | Formatted Diff | Diff
work in progress (65.59 KB, patch)
2015-11-18 16:43 PST, Filip Pizlo
no flags Details | Formatted Diff | Diff
Patch (87.62 KB, patch)
2015-11-18 18:22 PST, Benjamin Poulain
no flags Details | Formatted Diff | Diff
Patch (87.57 KB, patch)
2015-11-18 18:41 PST, Benjamin Poulain
no flags 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-18 16:24:41 PST
...
Comment 1 Filip Pizlo 2015-11-18 16:25:15 PST
Created attachment 265805 [details]
work in progress
Comment 2 Filip Pizlo 2015-11-18 16:43:58 PST
Created attachment 265809 [details]
work in progress
Comment 3 Benjamin Poulain 2015-11-18 18:22:52 PST
Created attachment 265821 [details]
Patch
Comment 4 WebKit Commit Bot 2015-11-18 18:24:45 PST
Attachment 265821 [details] did not pass style-queue:


ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:9061:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
Total errors found: 1 in 15 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 5 Filip Pizlo 2015-11-18 18:31:31 PST
Comment on attachment 265821 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=265821&action=review

I think that we can have a better story for upsilons.  I think that having anchor() create one for you, and then making ValueFromBlock hold onto it, is the most natural.

> Source/JavaScriptCore/ftl/FTLB3Output.h:368
> +    ValueFromBlock anchor(LValue value)
> +    {
> +        return ValueFromBlock(value, m_block);
> +    }

Either this should create an Upsilon for you by simply appending it to m_block...

> Source/JavaScriptCore/ftl/FTLB3Output.h:407
> +inline void Output::addIncomingToPhi(LValue phi, ValueFromBlock value)
> +{
> +    value.value()->as<B3::UpsilonValue>()->setPhi(phi);
> +}

... or this should create an Upsilon for you by appending it to the block that your value came from.
Comment 6 Benjamin Poulain 2015-11-18 18:41:11 PST
Created attachment 265824 [details]
Patch
Comment 7 WebKit Commit Bot 2015-11-18 18:44:07 PST
Attachment 265824 [details] did not pass style-queue:


ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:9061:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
Total errors found: 1 in 15 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 8 Benjamin Poulain 2015-11-18 18:48:49 PST
Comment on attachment 265824 [details]
Patch

Clearing flags on attachment: 265824

Committed r192605: <http://trac.webkit.org/changeset/192605>
Comment 9 Benjamin Poulain 2015-11-18 18:48:54 PST
All reviewed patches have been landed.  Closing bug.