Bug 152468 - FTL B3 should do vararg calls
Summary: FTL B3 should do vararg calls
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-12-20 12:33 PST by Filip Pizlo
Modified: 2015-12-21 14:48 PST (History)
13 users (show)

See Also:


Attachments
it begins (9.33 KB, patch)
2015-12-20 12:33 PST, Filip Pizlo
no flags Details | Formatted Diff | Diff
a bit more (15.01 KB, patch)
2015-12-20 17:00 PST, Filip Pizlo
no flags Details | Formatted Diff | Diff
almost done (17.22 KB, patch)
2015-12-20 17:35 PST, Filip Pizlo
no flags Details | Formatted Diff | Diff
it compiles (18.27 KB, patch)
2015-12-20 22:39 PST, Filip Pizlo
no flags Details | Formatted Diff | Diff
it seems to work (24.66 KB, patch)
2015-12-21 10:28 PST, Filip Pizlo
benjamin: 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-12-20 12:33:00 PST
Patch forthcoming.
Comment 1 Filip Pizlo 2015-12-20 12:33:50 PST
Created attachment 267723 [details]
it begins
Comment 2 Filip Pizlo 2015-12-20 17:00:04 PST
Created attachment 267727 [details]
a bit more
Comment 3 Filip Pizlo 2015-12-20 17:35:45 PST
Created attachment 267728 [details]
almost done
Comment 4 Filip Pizlo 2015-12-20 22:39:19 PST
Created attachment 267737 [details]
it compiles
Comment 5 Filip Pizlo 2015-12-21 10:28:01 PST
Created attachment 267754 [details]
it seems to work
Comment 6 WebKit Commit Bot 2015-12-21 10:29:35 PST
Attachment 267754 [details] did not pass style-queue:


ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5139:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5227:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5233:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5322:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
Total errors found: 4 in 7 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 7 Benjamin Poulain 2015-12-21 10:47:58 PST
Comment on attachment 267754 [details]
it seems to work

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

I am not familiar with the JS calling convention but nothing looks crazy here.

> Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5112
> +            // different register for the late for the post-clobbering version of the value. This gives
> +            // the compiler to spill these values without having to burn any callee-saves.

"to spill"->"a chance to spill"?
Comment 8 Filip Pizlo 2015-12-21 10:53:24 PST
(In reply to comment #7)
> Comment on attachment 267754 [details]
> it seems to work
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=267754&action=review
> 
> I am not familiar with the JS calling convention but nothing looks crazy
> here.
> 
> > Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5112
> > +            // different register for the late for the post-clobbering version of the value. This gives
> > +            // the compiler to spill these values without having to burn any callee-saves.
> 
> "to spill"->"a chance to spill"?

Yeah, that's what I meant!
Comment 9 Filip Pizlo 2015-12-21 10:57:35 PST
Landed in http://trac.webkit.org/changeset/194334
Comment 10 Csaba Osztrogonác 2015-12-21 13:23:53 PST
(In reply to comment #9)
> Landed in http://trac.webkit.org/changeset/194334

It broke the EFL build:
https://build.webkit.org/builders/EFL%20Linux%2064-bit%20Release%20WK2/builds/26013

../../Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp: In member function ‘void JSC::FTL::{anonymous}::LowerDFGToLLVM::compileCallOrConstructVarargs()’:
../../Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:5084:14: error: variable ‘forwarding’ set but not used [-Werror=unused-but-set-variable]
         bool forwarding = false;
Comment 11 Csaba Osztrogonác 2015-12-21 13:24:38 PST
Fix landed in https://trac.webkit.org/changeset/194347
Comment 12 Filip Pizlo 2015-12-21 14:48:26 PST
(In reply to comment #11)
> Fix landed in https://trac.webkit.org/changeset/194347

Thanks!