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

Unified Diff: runtime/vm/object.cc

Issue 11312105: Do not inline static calls that have not been executed in unoptimized code: the inlined function do… (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/object.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
===================================================================
--- runtime/vm/object.cc (revision 14603)
+++ runtime/vm/object.cc (working copy)
@@ -7209,6 +7209,26 @@
}
+void Code::ExtractUncalledStaticCallDeoptIds(
+ GrowableArray<intptr_t>* deopt_ids) const {
+ ASSERT(deopt_ids != NULL);
+ deopt_ids->Clear();
+ const PcDescriptors& descriptors =
+ PcDescriptors::Handle(this->pc_descriptors());
+ Function& function = Function::Handle();
+ for (intptr_t i = 0; i < descriptors.Length(); i++) {
+ if (descriptors.DescriptorKind(i) == PcDescriptors::kFuncCall) {
+ // Static call.
+ uword target_addr;
+ CodePatcher::GetStaticCallAt(descriptors.PC(i), &function, &target_addr);
+ if (target_addr == StubCode::CallStaticFunctionEntryPoint()) {
+ deopt_ids->Add(descriptors.DeoptId(i));
+ }
+ }
+ }
+}
+
+
RawStackmap* Code::GetStackmap(uword pc, Array* maps, Stackmap* map) const {
// This code is used during iterating frames during a GC and hence it
// should not in turn start a GC.
« no previous file with comments | « runtime/vm/object.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698