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

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

Issue 218613002: Set kTruncatingToSmi for HChange only when To rep is Smi (Closed) Base URL: git://github.com/v8/v8.git@master
Patch Set: Created 6 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 unified diff | Download patch
« no previous file with comments | « src/hydrogen-instructions.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 1543 matching lines...) Expand 10 before | Expand all | Expand 10 after
1554 void HForceRepresentation::PrintDataTo(StringStream* stream) { 1554 void HForceRepresentation::PrintDataTo(StringStream* stream) {
1555 stream->Add("%s ", representation().Mnemonic()); 1555 stream->Add("%s ", representation().Mnemonic());
1556 value()->PrintNameTo(stream); 1556 value()->PrintNameTo(stream);
1557 } 1557 }
1558 1558
1559 1559
1560 void HChange::PrintDataTo(StringStream* stream) { 1560 void HChange::PrintDataTo(StringStream* stream) {
1561 HUnaryOperation::PrintDataTo(stream); 1561 HUnaryOperation::PrintDataTo(stream);
1562 stream->Add(" %s to %s", from().Mnemonic(), to().Mnemonic()); 1562 stream->Add(" %s to %s", from().Mnemonic(), to().Mnemonic());
1563 1563
1564 if (CanTruncateToSmi()) stream->Add(" truncating-smi");
1564 if (CanTruncateToInt32()) stream->Add(" truncating-int32"); 1565 if (CanTruncateToInt32()) stream->Add(" truncating-int32");
1565 if (CheckFlag(kBailoutOnMinusZero)) stream->Add(" -0?"); 1566 if (CheckFlag(kBailoutOnMinusZero)) stream->Add(" -0?");
1566 if (CheckFlag(kAllowUndefinedAsNaN)) stream->Add(" allow-undefined-as-nan"); 1567 if (CheckFlag(kAllowUndefinedAsNaN)) stream->Add(" allow-undefined-as-nan");
1567 } 1568 }
1568 1569
1569 1570
1570 HValue* HUnaryMathOperation::Canonicalize() { 1571 HValue* HUnaryMathOperation::Canonicalize() {
1571 if (op() == kMathRound || op() == kMathFloor) { 1572 if (op() == kMathRound || op() == kMathFloor) {
1572 HValue* val = value(); 1573 HValue* val = value();
1573 if (val->IsChange()) val = HChange::cast(val)->value(); 1574 if (val->IsChange()) val = HChange::cast(val)->value();
(...skipping 3121 matching lines...) Expand 10 before | Expand all | Expand 10 after
4695 break; 4696 break;
4696 case kExternalMemory: 4697 case kExternalMemory:
4697 stream->Add("[external-memory]"); 4698 stream->Add("[external-memory]");
4698 break; 4699 break;
4699 } 4700 }
4700 4701
4701 stream->Add("@%d", offset()); 4702 stream->Add("@%d", offset());
4702 } 4703 }
4703 4704
4704 } } // namespace v8::internal 4705 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/hydrogen-instructions.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698