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

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

Issue 1644793002: Replace intptr_t with TokenDescriptor (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 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_api_impl.cc ('k') | runtime/vm/exceptions.h » ('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) 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 "vm/deopt_instructions.h" 5 #include "vm/deopt_instructions.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.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/intermediate_language.h" 10 #include "vm/intermediate_language.h"
(...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after
349 349
350 // Since this is the only step where GC can occur during deoptimization, 350 // Since this is the only step where GC can occur during deoptimization,
351 // use it to report the source line where deoptimization occured. 351 // use it to report the source line where deoptimization occured.
352 if (FLAG_trace_deoptimization || FLAG_trace_deoptimization_verbose) { 352 if (FLAG_trace_deoptimization || FLAG_trace_deoptimization_verbose) {
353 DartFrameIterator iterator; 353 DartFrameIterator iterator;
354 StackFrame* top_frame = iterator.NextFrame(); 354 StackFrame* top_frame = iterator.NextFrame();
355 ASSERT(top_frame != NULL); 355 ASSERT(top_frame != NULL);
356 const Code& code = Code::Handle(top_frame->LookupDartCode()); 356 const Code& code = Code::Handle(top_frame->LookupDartCode());
357 const Function& top_function = Function::Handle(code.function()); 357 const Function& top_function = Function::Handle(code.function());
358 const Script& script = Script::Handle(top_function.script()); 358 const Script& script = Script::Handle(top_function.script());
359 const intptr_t token_pos = code.GetTokenIndexOfPC(top_frame->pc()); 359 const TokenPosition token_pos = code.GetTokenIndexOfPC(top_frame->pc());
360 intptr_t line, column; 360 intptr_t line, column;
361 script.GetTokenLocation(token_pos, &line, &column); 361 script.GetTokenLocation(token_pos, &line, &column);
362 String& line_string = String::Handle(script.GetLine(line)); 362 String& line_string = String::Handle(script.GetLine(line));
363 OS::PrintErr(" Function: %s\n", top_function.ToFullyQualifiedCString()); 363 OS::PrintErr(" Function: %s\n", top_function.ToFullyQualifiedCString());
364 char line_buffer[80]; 364 char line_buffer[80];
365 OS::SNPrint(line_buffer, sizeof(line_buffer), " Line %" Pd ": '%s'", 365 OS::SNPrint(line_buffer, sizeof(line_buffer), " Line %" Pd ": '%s'",
366 line, line_string.ToCString()); 366 line, line_string.ToCString());
367 OS::PrintErr("%s\n", line_buffer); 367 OS::PrintErr("%s\n", line_buffer);
368 OS::PrintErr(" Deopt args: %" Pd "\n", deopt_arg_count); 368 OS::PrintErr(" Deopt args: %" Pd "\n", deopt_arg_count);
369 } 369 }
(...skipping 934 matching lines...) Expand 10 before | Expand all | Expand 10 after
1304 Smi* offset, 1304 Smi* offset,
1305 TypedData* info, 1305 TypedData* info,
1306 Smi* reason) { 1306 Smi* reason) {
1307 intptr_t i = index * kEntrySize; 1307 intptr_t i = index * kEntrySize;
1308 *offset ^= table.At(i); 1308 *offset ^= table.At(i);
1309 *info ^= table.At(i + 1); 1309 *info ^= table.At(i + 1);
1310 *reason ^= table.At(i + 2); 1310 *reason ^= table.At(i + 2);
1311 } 1311 }
1312 1312
1313 } // namespace dart 1313 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/debugger_api_impl.cc ('k') | runtime/vm/exceptions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698