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

Unified Diff: src/hydrogen-instructions.cc

Issue 24205004: Rollback trunk to 3.21.16.2 (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 7 years, 3 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 | « src/hydrogen-instructions.h ('k') | src/hydrogen-load-elimination.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen-instructions.cc
diff --git a/src/hydrogen-instructions.cc b/src/hydrogen-instructions.cc
index 4936a16ca30c1f4bb74acff37a0b6bf2c90dc2b5..cca95b9b5f233198a59486586132dcf3c6d94606 100644
--- a/src/hydrogen-instructions.cc
+++ b/src/hydrogen-instructions.cc
@@ -2526,11 +2526,9 @@ void HConstant::Initialize(Representation r) {
bool HConstant::EmitAtUses() {
ASSERT(IsLinked());
- if (block()->graph()->has_osr() &&
- block()->graph()->IsStandardConstant(this)) {
- return true;
+ if (block()->graph()->has_osr()) {
+ return block()->graph()->IsStandardConstant(this);
}
- if (UseCount() == 0) return true;
if (IsCell()) return false;
if (representation().IsDouble()) return false;
return true;
@@ -2575,6 +2573,10 @@ Maybe<HConstant*> HConstant::CopyToTruncatedInt32(Zone* zone) {
Representation::Integer32(),
is_not_in_new_space_,
handle_);
+ } else {
+ ASSERT(!HasNumberValue());
+ Maybe<HConstant*> number = CopyToTruncatedNumber(zone);
+ if (number.has_value) return number.value->CopyToTruncatedInt32(zone);
}
return Maybe<HConstant*>(res != NULL, res);
}
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/hydrogen-load-elimination.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698