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

Unified Diff: runtime/vm/object.cc

Issue 2246083003: AOT: Optimize even large functions. Ensures all calls are optimized static calls, switchable calls … (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: . Created 4 years, 4 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/object.h ('k') | runtime/vm/precompiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index 1481f63969e3f279e2f0a3078a891d3cfa9666bd..1459aee4fa9e81ab48f6e364f80911800c36fd2e 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -5905,6 +5905,9 @@ bool Function::IsOptimizable() const {
// Native methods don't need to be optimized.
return false;
}
+ if (FLAG_precompiled_mode) {
+ return true;
+ }
const intptr_t function_length = end_token_pos().Pos() - token_pos().Pos();
if (is_optimizable() && (script() != Script::null()) &&
(function_length < FLAG_huge_method_cutoff_in_tokens)) {
@@ -12490,6 +12493,12 @@ bool DeoptInfo::VerifyDecompression(const GrowableArray<DeoptInstr*>& original,
}
+void ICData::ResetSwitchable(Zone* zone) const {
+ ASSERT(NumArgsTested() == 1);
+ set_ic_data_array(Array::Handle(zone, CachedEmptyICDataArray(1)));
+}
+
+
const char* ICData::ToCString() const {
const String& name = String::Handle(target_name());
const intptr_t num_args = NumArgsTested();
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/precompiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698