From 3dd88c4067953aaf28a521b2d944726b678b4e66 Mon Sep 17 00:00:00 2001 From: "verwaest@chromium.org" Date: Fri, 20 Sep 2013 11:34:05 +0000 Subject: [PATCH] Pad the environment with 0 rather than the receiver to avoid influencing the representation of the join. R=titzer@chromium.org Review URL: https://chromiumcodereview.appspot.com/23707055 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16861 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/hydrogen.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/hydrogen.cc b/src/hydrogen.cc index caa595bfeb..50882a8a7f 100644 --- a/src/hydrogen.cc +++ b/src/hydrogen.cc @@ -6153,7 +6153,8 @@ void HOptimizedGraphBuilder::HandlePolymorphicCallNamed( // Because the deopt may be the only path in the polymorphic call, make sure // that the environment stack matches the depth on deopt that it otherwise // would have had after a successful call. - Drop(argument_count - (ast_context()->IsEffect() ? 0 : 1)); + Drop(argument_count); + if (!ast_context()->IsEffect()) Push(graph()->GetConstant0()); FinishExitWithHardDeoptimization("Unknown map in polymorphic call", join); } else { HValue* context = environment()->context();