Reviewers: Benedikt Meurer, titzer,
Message:
Not for landing yet, but I'd appreciate feedback before doing the rest of
the
platform ports.
Description:
[turbofan]: Implement tail calls with differing stack parameter counts
WORK IN PROGRESS, I'D APPRECIATE FEEDBACK BEFORE DOING THE OTHER PLATFORM
PORTS
This implementation loads as many parameters as possible before the tail
call
into registers and pushes the rest on the stack before deconstructing the
frame. As the frame is torn down, callee parameters are replaced for the
tail call by a mini parameter-handling interpreter, either by storing values
that are already in registers or by popping and storing the parameter values
from the stack.
The return address is handled specially. If the number of parameters
increases
in tail call tall, the parameter value that will replace the return address
must be in a register before the frame is deconstructed and frame
desconstruction
does a special value-swapping dance to make sure that the return address
ends up at the top of all parameters before finishing the tail call.
Please review this at https://codereview.chromium.org/1259203002/
Base URL: https://chromium.googlesource.com/v8/v8.git@master
Affected files (+514, -96 lines):
M src/compiler/ast-graph-builder.cc
M src/compiler/code-generator.h
M src/compiler/frame.h
M src/compiler/ia32/code-generator-ia32.cc
M src/compiler/ia32/instruction-selector-ia32.cc
M src/compiler/instruction.h
M src/compiler/instruction.cc
M src/compiler/instruction-selector.h
M src/compiler/js-intrinsic-lowering.cc
M src/compiler/js-operator.h
M src/compiler/js-operator.cc
M src/compiler/linkage.h
M src/compiler/linkage.cc
M src/compiler/pipeline.cc
M src/compiler/register-allocator.cc
M test/cctest/cctest.gyp
M test/cctest/compiler/test-instruction.cc
M test/cctest/compiler/test-jump-threading.cc
A test/cctest/compiler/test-tail-calls.cc
M test/mjsunit/call-runtime-tail.js
M test/unittests/compiler/instruction-selector-unittest.cc
M test/unittests/compiler/instruction-sequence-unittest.cc
M test/unittests/compiler/linkage-tail-call-unittest.cc
--
--
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.