Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(59)

Unified Diff: src/code-stubs.cc

Issue 26805004: Fix potential deopt-loop introduced in r17143. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stubs.cc
diff --git a/src/code-stubs.cc b/src/code-stubs.cc
index 1b9826ee42ea0c786a10855573009f63a80c1974..2283f847bab674029ae9e6d1f881e431589a60fc 100644
--- a/src/code-stubs.cc
+++ b/src/code-stubs.cc
@@ -584,11 +584,18 @@ void BinaryOpStub::UpdateStatus(Handle<Object> left,
op_ == Token::ADD);
if (old_state == GetExtraICState()) {
- // Since the fpu is to precise, we might bail out on numbers which
- // actually would truncate with 64 bit precision.
- ASSERT(!CpuFeatures::IsSupported(SSE2) &&
- result_state_ <= INT32);
- result_state_ = NUMBER;
+ // Tagged operations can lead to non-truncating HChanges
+ if (left->IsUndefined()) {
+ left_state_ = GENERIC;
+ } else if (right->IsUndefined()) {
+ right_state_ = GENERIC;
+ } else {
+ // Since the fpu is to precise, we might bail out on numbers which
+ // actually would truncate with 64 bit precision.
+ ASSERT(!CpuFeatures::IsSupported(SSE2) &&
+ result_state_ <= INT32);
+ result_state_ = NUMBER;
+ }
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698