Unbreak --deopt-every-n-times.

Review URL: https://codereview.chromium.org/13779003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14160 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent ffe7f6a1
......@@ -851,7 +851,9 @@ void LCodeGen::DeoptimizeIf(Condition cc, LEnvironment* environment) {
}
ASSERT(FLAG_deopt_every_n_times < 2); // Other values not supported on ARM.
if (FLAG_deopt_every_n_times == 1 && info_->opt_count() == id) {
if (FLAG_deopt_every_n_times == 1 &&
!info()->IsStub() &&
info()->opt_count() == id) {
__ Jump(entry, RelocInfo::RUNTIME_ENTRY);
return;
}
......
......@@ -858,8 +858,8 @@ void LCodeGen::DeoptimizeIf(Condition cc, LEnvironment* environment) {
return;
}
if (FLAG_deopt_every_n_times != 0) {
Handle<SharedFunctionInfo> shared(info_->shared_info());
if (FLAG_deopt_every_n_times != 0 && !info()->IsStub()) {
Handle<SharedFunctionInfo> shared(info()->shared_info());
Label no_deopt;
__ pushfd();
__ push(eax);
......
......@@ -828,7 +828,9 @@ void LCodeGen::DeoptimizeIf(Condition cc,
}
ASSERT(FLAG_deopt_every_n_times < 2); // Other values not supported on MIPS.
if (FLAG_deopt_every_n_times == 1 && info_->opt_count() == id) {
if (FLAG_deopt_every_n_times == 1 &&
!info()->IsStub() &&
info()->opt_count() == id) {
__ Jump(entry, RelocInfo::RUNTIME_ENTRY);
return;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment