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

Unified Diff: runtime/vm/compiler.cc

Issue 1644793002: Replace intptr_t with TokenDescriptor (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/code_patcher_x64_test.cc ('k') | runtime/vm/compiler_stats.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/compiler.cc
diff --git a/runtime/vm/compiler.cc b/runtime/vm/compiler.cc
index df6aa15ec499a48ee1f99e0dd43b3c9b6ea0051c..c98bfe3074f91fadc80fd892922f9594419b7ab6 100644
--- a/runtime/vm/compiler.cc
+++ b/runtime/vm/compiler.cc
@@ -1217,7 +1217,8 @@ static void DisassembleCode(const Function& function, bool optimized) {
THR_Print(" context var '%s' level %d offset %d",
var_name.ToCString(), var_info.scope_id, var_info.index());
}
- THR_Print(" (valid %d-%d)\n", var_info.begin_pos, var_info.end_pos);
+ THR_Print(" (valid %s-%s)\n", var_info.begin_pos.ToCString(),
+ var_info.end_pos.ToCString());
}
}
THR_Print("}\n");
@@ -1313,12 +1314,14 @@ static RawError* CompileFunctionHelper(CompilationPipeline* pipeline,
ParsedFunction* parsed_function = new(zone) ParsedFunction(
thread, Function::ZoneHandle(zone, function.raw()));
if (trace_compiler) {
- THR_Print("Compiling %s%sfunction: '%s' @ token %" Pd ", size %" Pd "\n",
+ const intptr_t token_size = function.end_token_pos().Pos() -
+ function.token_pos().Pos();
+ THR_Print("Compiling %s%sfunction: '%s' @ token %s, size %" Pd "\n",
(osr_id == Compiler::kNoOSRDeoptId ? "" : "osr "),
(optimized ? "optimized " : ""),
function.ToFullyQualifiedCString(),
- function.token_pos(),
- (function.end_token_pos() - function.token_pos()));
+ function.token_pos().ToCString(),
+ token_size);
}
INC_STAT(thread, num_functions_compiled, 1);
if (optimized) {
@@ -1413,9 +1416,9 @@ RawError* Compiler::CompileFunction(Thread* thread,
TIMELINE_FUNCTION_COMPILATION_DURATION(thread, "Function", function);
if (!isolate->compilation_allowed()) {
- FATAL3("Precompilation missed function %s (%" Pd ", %s)\n",
+ FATAL3("Precompilation missed function %s (%s, %s)\n",
function.ToLibNamePrefixedQualifiedCString(),
- function.token_pos(),
+ function.token_pos().ToCString(),
Function::KindToCString(function.kind()));
}
« no previous file with comments | « runtime/vm/code_patcher_x64_test.cc ('k') | runtime/vm/compiler_stats.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698