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

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

Issue 11473016: Fix crash during hydrogen trace. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years 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 | 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 1014 matching lines...) Expand 10 before | Expand all | Expand 10 after
1025 1025
1026 if (CanTruncateToInt32()) stream->Add(" truncating-int32"); 1026 if (CanTruncateToInt32()) stream->Add(" truncating-int32");
1027 if (CheckFlag(kBailoutOnMinusZero)) stream->Add(" -0?"); 1027 if (CheckFlag(kBailoutOnMinusZero)) stream->Add(" -0?");
1028 if (CheckFlag(kDeoptimizeOnUndefined)) stream->Add(" deopt-on-undefined"); 1028 if (CheckFlag(kDeoptimizeOnUndefined)) stream->Add(" deopt-on-undefined");
1029 } 1029 }
1030 1030
1031 1031
1032 void HJSArrayLength::PrintDataTo(StringStream* stream) { 1032 void HJSArrayLength::PrintDataTo(StringStream* stream) {
1033 value()->PrintNameTo(stream); 1033 value()->PrintNameTo(stream);
1034 stream->Add(" "); 1034 stream->Add(" ");
1035 typecheck()->PrintNameTo(stream); 1035 if (typecheck() != NULL)
1036 typecheck()->PrintNameTo(stream);
1037 else
1038 stream->Add("no_typecheck");
1036 } 1039 }
1037 1040
1038 1041
1039 HValue* HUnaryMathOperation::Canonicalize() { 1042 HValue* HUnaryMathOperation::Canonicalize() {
1040 if (op() == kMathFloor) { 1043 if (op() == kMathFloor) {
1041 // If the input is integer32 then we replace the floor instruction 1044 // If the input is integer32 then we replace the floor instruction
1042 // with its input. This happens before the representation changes are 1045 // with its input. This happens before the representation changes are
1043 // introduced. 1046 // introduced.
1044 if (value()->representation().IsInteger32()) return value(); 1047 if (value()->representation().IsInteger32()) return value();
1045 1048
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
1138 return; 1141 return;
1139 default: 1142 default:
1140 UNREACHABLE(); 1143 UNREACHABLE();
1141 } 1144 }
1142 } 1145 }
1143 1146
1144 1147
1145 void HLoadElements::PrintDataTo(StringStream* stream) { 1148 void HLoadElements::PrintDataTo(StringStream* stream) {
1146 value()->PrintNameTo(stream); 1149 value()->PrintNameTo(stream);
1147 stream->Add(" "); 1150 stream->Add(" ");
1148 typecheck()->PrintNameTo(stream); 1151 if (typecheck() != NULL)
1152 typecheck()->PrintNameTo(stream);
1153 else
1154 stream->Add("no_typecheck");
1149 } 1155 }
1150 1156
1151 1157
1152 void HCheckMaps::PrintDataTo(StringStream* stream) { 1158 void HCheckMaps::PrintDataTo(StringStream* stream) {
1153 value()->PrintNameTo(stream); 1159 value()->PrintNameTo(stream);
1154 stream->Add(" [%p", *map_set()->first()); 1160 stream->Add(" [%p", *map_set()->first());
1155 for (int i = 1; i < map_set()->length(); ++i) { 1161 for (int i = 1; i < map_set()->length(); ++i) {
1156 stream->Add(",%p", *map_set()->at(i)); 1162 stream->Add(",%p", *map_set()->at(i));
1157 } 1163 }
1158 stream->Add("]"); 1164 stream->Add("]");
(...skipping 854 matching lines...) Expand 10 before | Expand all | Expand 10 after
2013 } 2019 }
2014 2020
2015 stream->Add("["); 2021 stream->Add("[");
2016 key()->PrintNameTo(stream); 2022 key()->PrintNameTo(stream);
2017 if (IsDehoisted()) { 2023 if (IsDehoisted()) {
2018 stream->Add(" + %d] ", index_offset()); 2024 stream->Add(" + %d] ", index_offset());
2019 } else { 2025 } else {
2020 stream->Add("] "); 2026 stream->Add("] ");
2021 } 2027 }
2022 2028
2023 dependency()->PrintNameTo(stream); 2029 if (dependency() != NULL)
2030 dependency()->PrintNameTo(stream);
2031 else
2032 stream->Add("no_dep");
2024 if (RequiresHoleCheck()) { 2033 if (RequiresHoleCheck()) {
2025 stream->Add(" check_hole"); 2034 stream->Add(" check_hole");
2026 } 2035 }
2027 } 2036 }
2028 2037
2029 2038
2030 bool HLoadKeyed::RequiresHoleCheck() const { 2039 bool HLoadKeyed::RequiresHoleCheck() const {
2031 if (IsFastPackedElementsKind(elements_kind())) { 2040 if (IsFastPackedElementsKind(elements_kind())) {
2032 return false; 2041 return false;
2033 } 2042 }
(...skipping 731 matching lines...) Expand 10 before | Expand all | Expand 10 after
2765 2774
2766 2775
2767 void HCheckFunction::Verify() { 2776 void HCheckFunction::Verify() {
2768 HInstruction::Verify(); 2777 HInstruction::Verify();
2769 ASSERT(HasNoUses()); 2778 ASSERT(HasNoUses());
2770 } 2779 }
2771 2780
2772 #endif 2781 #endif
2773 2782
2774 } } // namespace v8::internal 2783 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698