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

Unified Diff: src/types.cc

Issue 187353005: Use Representation::Integer32() for smi types on 32-bit-tagged systems. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed nit Created 6 years, 9 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.cc ('k') | test/mjsunit/regress/regress-crbug-349079.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/types.cc
diff --git a/src/types.cc b/src/types.cc
index 3840e6fd223f72c0210b49a386e3ca4462ef4a0b..dedfeadb46ac0003f032e9cc0276e8fd1a2171d3 100644
--- a/src/types.cc
+++ b/src/types.cc
@@ -568,7 +568,8 @@ typename TypeImpl<Config>::TypeHandle TypeImpl<Config>::Convert(
// TODO(rossberg): this does not belong here.
Representation Representation::FromType(Type* type) {
if (type->Is(Type::None())) return Representation::None();
- if (type->Is(Type::Smi())) return Representation::Smi();
+ if (type->Is(Type::Smi())) return SmiValuesAre31Bits()
+ ? Representation::Smi() : Representation::Integer32();
if (type->Is(Type::Signed32())) return Representation::Integer32();
if (type->Is(Type::Number())) return Representation::Double();
return Representation::Tagged();
« no previous file with comments | « src/hydrogen-instructions.cc ('k') | test/mjsunit/regress/regress-crbug-349079.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698