| Index: src/crankshaft/ppc/lithium-ppc.cc
|
| diff --git a/src/crankshaft/ppc/lithium-ppc.cc b/src/crankshaft/ppc/lithium-ppc.cc
|
| index 0dbe7309e7d08fc253fab9eedc221a66bc3c7076..f7a7413247bdd8827c98e1f867f56d7bf46a166b 100644
|
| --- a/src/crankshaft/ppc/lithium-ppc.cc
|
| +++ b/src/crankshaft/ppc/lithium-ppc.cc
|
| @@ -892,10 +892,12 @@ void LChunkBuilder::AddInstruction(LInstruction* instr,
|
| DCHECK_NOT_NULL(hydrogen_env);
|
| if (instr->IsSyntacticTailCall()) {
|
| // If it was a syntactic tail call we need to drop the current frame and
|
| - // an arguments adaptor frame on top of it (if the latter is present).
|
| + // all the frames on top of it that are either an arguments adaptor frame
|
| + // or a tail caller frame.
|
| hydrogen_env = hydrogen_env->outer();
|
| - if (hydrogen_env != nullptr &&
|
| - hydrogen_env->frame_type() == ARGUMENTS_ADAPTOR) {
|
| + while (hydrogen_env != nullptr &&
|
| + (hydrogen_env->frame_type() == ARGUMENTS_ADAPTOR ||
|
| + hydrogen_env->frame_type() == TAIL_CALLER_FUNCTION)) {
|
| hydrogen_env = hydrogen_env->outer();
|
| }
|
| if (hydrogen_env != nullptr) {
|
|
|