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

Side by Side Diff: runtime/vm/disassembler.cc

Issue 2686813006: Reapply "Use CodeSourceMap for stack traces (still JIT only)." (Closed)
Patch Set: Created 3 years, 10 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
« no previous file with comments | « runtime/vm/debugger.cc ('k') | runtime/vm/exceptions.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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/disassembler.h" 5 #include "vm/disassembler.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 #include "vm/deopt_instructions.h" 8 #include "vm/deopt_instructions.h"
9 #include "vm/globals.h" 9 #include "vm/globals.h"
10 #include "vm/il_printer.h" 10 #include "vm/il_printer.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 comments.PCOffsetAt(comment_finger) <= offset) { 122 comments.PCOffsetAt(comment_finger) <= offset) {
123 formatter->Print( 123 formatter->Print(
124 " ;; %s\n", 124 " ;; %s\n",
125 String::Handle(comments.CommentAt(comment_finger)).ToCString()); 125 String::Handle(comments.CommentAt(comment_finger)).ToCString());
126 comment_finger++; 126 comment_finger++;
127 } 127 }
128 if (old_comment_finger != comment_finger) { 128 if (old_comment_finger != comment_finger) {
129 char str[4000]; 129 char str[4000];
130 BufferFormatter f(str, sizeof(str)); 130 BufferFormatter f(str, sizeof(str));
131 // Comment emitted, emit inlining information. 131 // Comment emitted, emit inlining information.
132 code.GetInlinedFunctionsAt(offset, &inlined_functions, &token_positions); 132 code.GetInlinedFunctionsAtInstruction(offset, &inlined_functions,
133 &token_positions);
133 // Skip top scope function printing (last entry in 'inlined_functions'). 134 // Skip top scope function printing (last entry in 'inlined_functions').
134 bool first = true; 135 bool first = true;
135 for (intptr_t i = 1; i < inlined_functions.length(); i++) { 136 for (intptr_t i = 1; i < inlined_functions.length(); i++) {
136 const char* name = inlined_functions[i]->ToQualifiedCString(); 137 const char* name = inlined_functions[i]->ToQualifiedCString();
137 if (first) { 138 if (first) {
138 f.Print(" ;; Inlined [%s", name); 139 f.Print(" ;; Inlined [%s", name);
139 first = false; 140 first = false;
140 } else { 141 } else {
141 f.Print(" -> %s", name); 142 f.Print(" -> %s", name);
142 } 143 }
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 bool optimized) { 312 bool optimized) {
312 const char* function_fullname = function.ToFullyQualifiedCString(); 313 const char* function_fullname = function.ToFullyQualifiedCString();
313 const Code& code = Code::Handle(function.unoptimized_code()); 314 const Code& code = Code::Handle(function.unoptimized_code());
314 DisassembleCodeHelper(function_fullname, code, optimized); 315 DisassembleCodeHelper(function_fullname, code, optimized);
315 } 316 }
316 317
317 318
318 #endif // !PRODUCT 319 #endif // !PRODUCT
319 320
320 } // namespace dart 321 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/debugger.cc ('k') | runtime/vm/exceptions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698