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

Unified Diff: src/hydrogen-instructions.h

Issue 13426006: Improvements for x87 stack handling (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Improvements Created 7 years, 8 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 | src/ia32/lithium-codegen-ia32.h » ('j') | src/ia32/lithium-codegen-ia32.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen-instructions.h
diff --git a/src/hydrogen-instructions.h b/src/hydrogen-instructions.h
index ad036871802b32b0ad9646e480fd43339444ce0f..a0d61add5d0f3b14f788fe42e2073e2297bb3739 100644
--- a/src/hydrogen-instructions.h
+++ b/src/hydrogen-instructions.h
@@ -3196,7 +3196,8 @@ class HConstant: public HTemplateInstruction<0> {
}
if (has_double_value_) {
if (BitCast<int64_t>(double_value_) == BitCast<int64_t>(-0.0) ||
- isnan(double_value_)) {
+ isnan(double_value_) ||
+ FixedDoubleArray::is_the_hole_nan(double_value_)) {
return true;
}
return false;
@@ -3227,7 +3228,9 @@ class HConstant: public HTemplateInstruction<0> {
return has_int32_value_;
}
- virtual bool EmitAtUses() { return !representation().IsDouble(); }
+ virtual bool EmitAtUses() {
+ return !representation().IsDouble() || ImmortalImmovable();
danno 2013/04/08 12:57:27 Maybe it's better to factor our the special cases
mvstanton 2013/04/08 16:10:14 I did this kind of refactoring but more in the met
+ }
virtual void PrintDataTo(StringStream* stream);
virtual HType CalculateInferredType();
bool IsInteger() { return handle()->IsSmi(); }
@@ -3246,6 +3249,10 @@ class HConstant: public HTemplateInstruction<0> {
ASSERT(HasDoubleValue());
return double_value_;
}
+ bool IsDoubleCanonicalHole() const {
+ ASSERT(HasDoubleValue());
+ return FixedDoubleArray::is_the_hole_nan(double_value_);
+ }
bool HasNumberValue() const { return has_double_value_; }
int32_t NumberValueAsInteger32() const {
ASSERT(HasNumberValue());
@@ -5677,6 +5684,11 @@ class HStoreKeyed
bool IsDehoisted() { return is_dehoisted_; }
void SetDehoisted(bool is_dehoisted) { is_dehoisted_ = is_dehoisted; }
+ bool IsConstantHoleStore() {
+ return value()->IsConstant() &&
+ HConstant::cast(value())->IsDoubleCanonicalHole();
danno 2013/04/08 12:57:27 This predicate seems misleading... it checks only
mvstanton 2013/04/08 16:10:14 Done.
+ }
+
virtual void SetSideEffectDominator(GVNFlag side_effect, HValue* dominator) {
ASSERT(side_effect == kChangesNewSpacePromotion);
new_space_dominator_ = dominator;
« no previous file with comments | « no previous file | src/ia32/lithium-codegen-ia32.h » ('j') | src/ia32/lithium-codegen-ia32.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698