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

Side by Side Diff: src/hydrogen-instructions.cc

Issue 6262005: Merge changes to LTemplateInstruction to X64 (Issue 1048). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge/build-x64
Patch Set: Created 9 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 978 matching lines...) Expand 10 before | Expand all | Expand 10 after
989 : handle_(handle), 989 : handle_(handle),
990 constant_type_(HType::TypeFromValue(handle)), 990 constant_type_(HType::TypeFromValue(handle)),
991 has_int32_value_(false), 991 has_int32_value_(false),
992 int32_value_(0), 992 int32_value_(0),
993 has_double_value_(false), 993 has_double_value_(false),
994 double_value_(0) { 994 double_value_(0) {
995 set_representation(r); 995 set_representation(r);
996 SetFlag(kUseGVN); 996 SetFlag(kUseGVN);
997 if (handle_->IsNumber()) { 997 if (handle_->IsNumber()) {
998 double n = handle_->Number(); 998 double n = handle_->Number();
999 has_int32_value_ = static_cast<double>(static_cast<int32_t>(n)) == n; 999 double roundtrip_value = static_cast<double>(static_cast<int32_t>(n));
1000 has_int32_value_ = BitCast<int64_t>(roundtrip_value) == BitCast<int64_t>(n);
1000 if (has_int32_value_) int32_value_ = static_cast<int32_t>(n); 1001 if (has_int32_value_) int32_value_ = static_cast<int32_t>(n);
1001 double_value_ = n; 1002 double_value_ = n;
1002 has_double_value_ = true; 1003 has_double_value_ = true;
1003 } 1004 }
1004 } 1005 }
1005 1006
1006 1007
1007 HConstant* HConstant::CopyToRepresentation(Representation r) const { 1008 HConstant* HConstant::CopyToRepresentation(Representation r) const {
1008 if (r.IsInteger32() && !has_int32_value_) return NULL; 1009 if (r.IsInteger32() && !has_int32_value_) return NULL;
1009 if (r.IsDouble() && !has_double_value_) return NULL; 1010 if (r.IsDouble() && !has_double_value_) return NULL;
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after
1442 1443
1443 1444
1444 void HCheckPrototypeMaps::Verify() const { 1445 void HCheckPrototypeMaps::Verify() const {
1445 HInstruction::Verify(); 1446 HInstruction::Verify();
1446 ASSERT(HasNoUses()); 1447 ASSERT(HasNoUses());
1447 } 1448 }
1448 1449
1449 #endif 1450 #endif
1450 1451
1451 } } // namespace v8::internal 1452 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698