Revision: 16364
Author: [email protected]
Date: Tue Aug 27 14:09:26 2013 UTC
Log: Fixed HMul::Canonicalize() to support SMI
Same idea for HDiv when the right oeprand is 1
BUG=
[email protected]
Review URL: https://codereview.chromium.org/23176002
Patch from Weiliang Lin <[email protected]>.
http://code.google.com/p/v8/source/detail?r=16364
Modified:
/branches/bleeding_edge/src/hydrogen-instructions.cc
/branches/bleeding_edge/src/property-details.h
=======================================
--- /branches/bleeding_edge/src/hydrogen-instructions.cc Tue Aug 27
13:55:00 2013 UTC
+++ /branches/bleeding_edge/src/hydrogen-instructions.cc Tue Aug 27
14:09:26 2013 UTC
@@ -1243,6 +1243,7 @@
HValue* HDiv::Canonicalize() {
+ if (IsIdentityOperation(left(), right(), 1)) return left();
return this;
}
=======================================
--- /branches/bleeding_edge/src/property-details.h Wed Jul 24 12:34:50 2013
UTC
+++ /branches/bleeding_edge/src/property-details.h Tue Aug 27 14:09:26 2013
UTC
@@ -148,7 +148,7 @@
bool IsHeapObject() const { return kind_ == kHeapObject; }
bool IsExternal() const { return kind_ == kExternal; }
bool IsSpecialization() const {
- return kind_ == kInteger32 || kind_ == kDouble;
+ return kind_ == kInteger32 || kind_ == kDouble || kind_ == kSmi;
}
const char* Mnemonic() const;
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.