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

Unified Diff: runtime/vm/compiler.cc

Issue 11418046: First part of static call cleanup: store static call targets into code object, referenced by code-o… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 1 month 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_generator.cc ('k') | runtime/vm/debugger.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/compiler.cc
===================================================================
--- runtime/vm/compiler.cc (revision 15090)
+++ runtime/vm/compiler.cc (working copy)
@@ -277,6 +277,7 @@
graph_compiler.FinalizeVarDescriptors(code);
graph_compiler.FinalizeExceptionHandlers(code);
graph_compiler.FinalizeComments(code);
+ graph_compiler.FinalizeStaticCallTargetsTable(code);
if (optimized) {
CodePatcher::PatchEntry(Code::Handle(function.CurrentCode()));
function.SetCode(code);
@@ -416,6 +417,25 @@
const ExceptionHandlers& handlers =
ExceptionHandlers::Handle(code.exception_handlers());
OS::Print("%s}\n", handlers.ToCString());
+
+ {
+ OS::Print("Static call target functions {\n");
+ const Array& table = Array::Handle(code.static_calls_target_table());
+ Smi& offset = Smi::Handle();
+ Function& function = Function::Handle();
+ Code& code = Code::Handle();
+ for (intptr_t i = 0; i < table.Length();
+ i += Code::kSCallTableEntryLength) {
+ offset ^= table.At(i + Code::kSCallTableOffsetEntry);
+ function ^= table.At(i + Code::kSCallTableFunctionEntry);
+ code ^= table.At(i + Code::kSCallTableCodeEntry);
+ OS::Print(" 0x%"Px": %s, %p\n",
+ start + offset.Value(),
+ function.ToFullyQualifiedCString(),
+ code.raw());
+ }
+ OS::Print("}\n");
+ }
}
« no previous file with comments | « runtime/vm/code_generator.cc ('k') | runtime/vm/debugger.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698