| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/object.h" | 5 #include "vm/object.h" |
| 6 | 6 |
| 7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 #include "vm/assembler.h" | 9 #include "vm/assembler.h" |
| 10 #include "vm/cpu.h" | 10 #include "vm/cpu.h" |
| (...skipping 21505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 21516 frame_strings.Add(chars); | 21516 frame_strings.Add(chars); |
| 21517 total_len += truncated_len; | 21517 total_len += truncated_len; |
| 21518 ASSERT(PcOffsetAtFrame(i) != Smi::null()); | 21518 ASSERT(PcOffsetAtFrame(i) != Smi::null()); |
| 21519 // To account for gap frames. | 21519 // To account for gap frames. |
| 21520 (*frame_index) += Smi::Value(PcOffsetAtFrame(i)); | 21520 (*frame_index) += Smi::Value(PcOffsetAtFrame(i)); |
| 21521 } | 21521 } |
| 21522 } else { | 21522 } else { |
| 21523 code = CodeAtFrame(i); | 21523 code = CodeAtFrame(i); |
| 21524 ASSERT(function.raw() == code.function()); | 21524 ASSERT(function.raw() == code.function()); |
| 21525 uword pc = code.EntryPoint() + Smi::Value(PcOffsetAtFrame(i)); | 21525 uword pc = code.EntryPoint() + Smi::Value(PcOffsetAtFrame(i)); |
| 21526 if (code.is_optimized() && expand_inlined() && !FLAG_precompiled_mode) { | 21526 if (code.is_optimized() && |
| 21527 expand_inlined() && |
| 21528 !FLAG_precompiled_runtime) { |
| 21527 // Traverse inlined frames. | 21529 // Traverse inlined frames. |
| 21528 for (InlinedFunctionsIterator it(code, pc); | 21530 for (InlinedFunctionsIterator it(code, pc); |
| 21529 !it.Done() && (*frame_index < max_frames); it.Advance()) { | 21531 !it.Done() && (*frame_index < max_frames); it.Advance()) { |
| 21530 function = it.function(); | 21532 function = it.function(); |
| 21531 if (function.is_visible() || FLAG_show_invisible_frames) { | 21533 if (function.is_visible() || FLAG_show_invisible_frames) { |
| 21532 code = it.code(); | 21534 code = it.code(); |
| 21533 ASSERT(function.raw() == code.function()); | 21535 ASSERT(function.raw() == code.function()); |
| 21534 uword pc = it.pc(); | 21536 uword pc = it.pc(); |
| 21535 ASSERT(pc != 0); | 21537 ASSERT(pc != 0); |
| 21536 ASSERT(code.EntryPoint() <= pc); | 21538 ASSERT(code.EntryPoint() <= pc); |
| (...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 21869 return UserTag::null(); | 21871 return UserTag::null(); |
| 21870 } | 21872 } |
| 21871 | 21873 |
| 21872 | 21874 |
| 21873 const char* UserTag::ToCString() const { | 21875 const char* UserTag::ToCString() const { |
| 21874 const String& tag_label = String::Handle(label()); | 21876 const String& tag_label = String::Handle(label()); |
| 21875 return tag_label.ToCString(); | 21877 return tag_label.ToCString(); |
| 21876 } | 21878 } |
| 21877 | 21879 |
| 21878 } // namespace dart | 21880 } // namespace dart |
| OLD | NEW |