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

Side by Side Diff: vm/debugger.cc

Issue 10375059: Use a reserved stack local variable to store the Code object so that it can be looked up easily whe… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 7 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 | Annotate | Revision Log
OLDNEW
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/debugger.h" 5 #include "vm/debugger.h"
6 6
7 #include "vm/code_generator.h" 7 #include "vm/code_generator.h"
8 #include "vm/code_patcher.h" 8 #include "vm/code_patcher.h"
9 #include "vm/compiler.h" 9 #include "vm/compiler.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 line_number_(-1), 95 line_number_(-1),
96 var_descriptors_(NULL), 96 var_descriptors_(NULL),
97 desc_indices_(8) { 97 desc_indices_(8) {
98 } 98 }
99 99
100 100
101 const Function& ActivationFrame::DartFunction() { 101 const Function& ActivationFrame::DartFunction() {
102 if (function_.IsNull()) { 102 if (function_.IsNull()) {
103 Isolate* isolate = Isolate::Current(); 103 Isolate* isolate = Isolate::Current();
104 ASSERT(isolate != NULL); 104 ASSERT(isolate != NULL);
105 const Code& code = Code::Handle(StackFrame::LookupCode(isolate, pc_)); 105 const Code& code = Code::Handle(Code::LookupCode(pc_));
106 function_ = code.function(); 106 function_ = code.function();
107 } 107 }
108 return function_; 108 return function_;
109 } 109 }
110 110
111 111
112 const char* Debugger::QualifiedFunctionName(const Function& func) { 112 const char* Debugger::QualifiedFunctionName(const Function& func) {
113 const String& func_name = String::Handle(func.name()); 113 const String& func_name = String::Handle(func.name());
114 Class& func_class = Class::Handle(func.owner()); 114 Class& func_class = Class::Handle(func.owner());
115 String& class_name = String::Handle(func_class.Name()); 115 String& class_name = String::Handle(func_class.Name());
(...skipping 980 matching lines...) Expand 10 before | Expand all | Expand 10 after
1096 } 1096 }
1097 1097
1098 1098
1099 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { 1099 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) {
1100 ASSERT(bpt->next() == NULL); 1100 ASSERT(bpt->next() == NULL);
1101 bpt->set_next(code_breakpoints_); 1101 bpt->set_next(code_breakpoints_);
1102 code_breakpoints_ = bpt; 1102 code_breakpoints_ = bpt;
1103 } 1103 }
1104 1104
1105 } // namespace dart 1105 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698