| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 <setjmp.h> // NOLINT | 5 #include <setjmp.h> // NOLINT |
| 6 #include <stdlib.h> | 6 #include <stdlib.h> |
| 7 | 7 |
| 8 #include "vm/globals.h" | 8 #include "vm/globals.h" |
| 9 #if defined(TARGET_ARCH_ARM) | 9 #if defined(TARGET_ARCH_ARM) |
| 10 | 10 |
| (...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 script.GetTokenLocation(token_pos, &line, &column); | 274 script.GetTokenLocation(token_pos, &line, &column); |
| 275 } | 275 } |
| 276 OS::Print( | 276 OS::Print( |
| 277 "pc=0x%" Px " fp=0x%" Px " sp=0x%" Px " %s%s (%s:%" Pd ":%" Pd ")\n", pc, | 277 "pc=0x%" Px " fp=0x%" Px " sp=0x%" Px " %s%s (%s:%" Pd ":%" Pd ")\n", pc, |
| 278 fp, sp, is_optimized ? (is_inlined ? "inlined " : "optimized ") : "", | 278 fp, sp, is_optimized ? (is_inlined ? "inlined " : "optimized ") : "", |
| 279 func_name.ToCString(), url.ToCString(), line, column); | 279 func_name.ToCString(), url.ToCString(), line, column); |
| 280 } | 280 } |
| 281 | 281 |
| 282 | 282 |
| 283 void SimulatorDebugger::PrintBacktrace() { | 283 void SimulatorDebugger::PrintBacktrace() { |
| 284 StackFrameIterator frames(sim_->get_register(FP), sim_->get_register(SP), | 284 StackFrameIterator frames( |
| 285 sim_->get_pc(), | 285 sim_->get_register(FP), sim_->get_register(SP), sim_->get_pc(), |
| 286 StackFrameIterator::kDontValidateFrames); | 286 StackFrameIterator::kDontValidateFrames, Thread::Current(), false); |
| 287 StackFrame* frame = frames.NextFrame(); | 287 StackFrame* frame = frames.NextFrame(); |
| 288 ASSERT(frame != NULL); | 288 ASSERT(frame != NULL); |
| 289 Function& function = Function::Handle(); | 289 Function& function = Function::Handle(); |
| 290 Function& inlined_function = Function::Handle(); | 290 Function& inlined_function = Function::Handle(); |
| 291 Code& code = Code::Handle(); | 291 Code& code = Code::Handle(); |
| 292 Code& unoptimized_code = Code::Handle(); | 292 Code& unoptimized_code = Code::Handle(); |
| 293 while (frame != NULL) { | 293 while (frame != NULL) { |
| 294 if (frame->IsDartFrame()) { | 294 if (frame->IsDartFrame()) { |
| 295 code = frame->LookupDartCode(); | 295 code = frame->LookupDartCode(); |
| 296 function = code.function(); | 296 function = code.function(); |
| (...skipping 3625 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3922 set_register(CODE_REG, code); | 3922 set_register(CODE_REG, code); |
| 3923 set_register(PP, pp); | 3923 set_register(PP, pp); |
| 3924 buf->Longjmp(); | 3924 buf->Longjmp(); |
| 3925 } | 3925 } |
| 3926 | 3926 |
| 3927 } // namespace dart | 3927 } // namespace dart |
| 3928 | 3928 |
| 3929 #endif // defined(USING_SIMULATOR) | 3929 #endif // defined(USING_SIMULATOR) |
| 3930 | 3930 |
| 3931 #endif // defined TARGET_ARCH_ARM | 3931 #endif // defined TARGET_ARCH_ARM |
| OLD | NEW |