| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/disassembler.h" | 5 #include "src/disassembler.h" |
| 6 | 6 |
| 7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
| 8 #include "src/codegen.h" | 8 #include "src/codegen.h" |
| 9 #include "src/debug/debug.h" | 9 #include "src/debug/debug.h" |
| 10 #include "src/deoptimizer.h" | 10 #include "src/deoptimizer.h" |
| (...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 relocinfo.data()); | 174 relocinfo.data()); |
| 175 } else { | 175 } else { |
| 176 out.AddFormatted(" ;; debug: position %" V8PRIdPTR, | 176 out.AddFormatted(" ;; debug: position %" V8PRIdPTR, |
| 177 relocinfo.data()); | 177 relocinfo.data()); |
| 178 } | 178 } |
| 179 } else if (rmode == RelocInfo::DEOPT_REASON) { | 179 } else if (rmode == RelocInfo::DEOPT_REASON) { |
| 180 Deoptimizer::DeoptReason reason = | 180 Deoptimizer::DeoptReason reason = |
| 181 static_cast<Deoptimizer::DeoptReason>(relocinfo.data()); | 181 static_cast<Deoptimizer::DeoptReason>(relocinfo.data()); |
| 182 out.AddFormatted(" ;; debug: deopt reason '%s'", | 182 out.AddFormatted(" ;; debug: deopt reason '%s'", |
| 183 Deoptimizer::GetDeoptReason(reason)); | 183 Deoptimizer::GetDeoptReason(reason)); |
| 184 } else if (rmode == RelocInfo::DEOPT_ID) { |
| 185 out.AddFormatted(" ;; debug: deopt inlining id %d", |
| 186 static_cast<int>(relocinfo.data())); |
| 184 } else if (rmode == RelocInfo::EMBEDDED_OBJECT) { | 187 } else if (rmode == RelocInfo::EMBEDDED_OBJECT) { |
| 185 HeapStringAllocator allocator; | 188 HeapStringAllocator allocator; |
| 186 StringStream accumulator(&allocator); | 189 StringStream accumulator(&allocator); |
| 187 relocinfo.target_object()->ShortPrint(&accumulator); | 190 relocinfo.target_object()->ShortPrint(&accumulator); |
| 188 base::SmartArrayPointer<const char> obj_name = accumulator.ToCString(); | 191 base::SmartArrayPointer<const char> obj_name = accumulator.ToCString(); |
| 189 out.AddFormatted(" ;; object: %s", obj_name.get()); | 192 out.AddFormatted(" ;; object: %s", obj_name.get()); |
| 190 } else if (rmode == RelocInfo::EXTERNAL_REFERENCE) { | 193 } else if (rmode == RelocInfo::EXTERNAL_REFERENCE) { |
| 191 const char* reference_name = ref_encoder.NameOfAddress( | 194 const char* reference_name = ref_encoder.NameOfAddress( |
| 192 isolate, relocinfo.target_external_reference()); | 195 isolate, relocinfo.target_external_reference()); |
| 193 out.AddFormatted(" ;; external reference (%s)", reference_name); | 196 out.AddFormatted(" ;; external reference (%s)", reference_name); |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 278 | 281 |
| 279 int Disassembler::Decode(Isolate* isolate, std::ostream* os, byte* begin, | 282 int Disassembler::Decode(Isolate* isolate, std::ostream* os, byte* begin, |
| 280 byte* end, Code* code) { | 283 byte* end, Code* code) { |
| 281 return 0; | 284 return 0; |
| 282 } | 285 } |
| 283 | 286 |
| 284 #endif // ENABLE_DISASSEMBLER | 287 #endif // ENABLE_DISASSEMBLER |
| 285 | 288 |
| 286 } // namespace internal | 289 } // namespace internal |
| 287 } // namespace v8 | 290 } // namespace v8 |
| OLD | NEW |