Index: src/ia32/deoptimizer-ia32.cc |
diff --git a/src/ia32/deoptimizer-ia32.cc b/src/ia32/deoptimizer-ia32.cc |
index 667f1319cde10cbea37d02ffdf2164745097cba8..23dfbaedf009485fb3e83d4c8306d4ccc3d2574f 100644 |
--- a/src/ia32/deoptimizer-ia32.cc |
+++ b/src/ia32/deoptimizer-ia32.cc |
@@ -575,6 +575,10 @@ void Deoptimizer::DoComputeCompiledStubFrame(TranslationIterator* iterator, |
int caller_arg_count = 0; |
if (descriptor->stack_parameter_count_ != NULL) { |
+ // TODO(mvstanton): when a hydrogen stub with multiple arguments of any |
+ // complexity comes along this code will fail because the register is likely |
+ // consumed with another value. Retrieve the caller_arg_count from the |
+ // environment instead via iterator. |
caller_arg_count = |
input_->GetRegister(descriptor->stack_parameter_count_->code()); |
} |