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

Unified Diff: src/objects.cc

Issue 2448933002: [compiler] Make SFI "optimize" flag a "tier up" flag (Closed)
Patch Set: Do some renaming and remove a DCHECK Created 4 years, 2 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 | « src/objects.h ('k') | src/objects-inl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index 32b67b93f05c00fd5fb8dfa4804d79198b3d0211..d3ccb6d6a8c311c18f6651ddfa3b419d626abeef 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -12205,6 +12205,9 @@ void JSFunction::MarkForBaseline() {
set_code_no_write_barrier(
isolate->builtins()->builtin(Builtins::kCompileBaseline));
// No write barrier required, since the builtin is part of the root set.
+ if (FLAG_mark_shared_functions_for_tier_up) {
+ shared()->set_marked_for_tier_up(true);
+ }
}
void JSFunction::MarkForOptimization() {
@@ -12215,16 +12218,13 @@ void JSFunction::MarkForOptimization() {
set_code_no_write_barrier(
isolate->builtins()->builtin(Builtins::kCompileOptimized));
// No write barrier required, since the builtin is part of the root set.
+ if (FLAG_mark_shared_functions_for_tier_up) {
+ shared()->set_marked_for_tier_up(true);
+ }
}
void JSFunction::AttemptConcurrentOptimization() {
- if (FLAG_optimize_shared_functions) {
- // Mark the shared function for optimization regardless of whether the
- // optimization is concurrent or not.
- shared()->set_was_marked_for_optimization(true);
- }
-
Isolate* isolate = GetIsolate();
if (!isolate->concurrent_recompilation_enabled() ||
isolate->bootstrapper()->IsActive()) {
@@ -12245,6 +12245,11 @@ void JSFunction::AttemptConcurrentOptimization() {
set_code_no_write_barrier(
isolate->builtins()->builtin(Builtins::kCompileOptimizedConcurrent));
// No write barrier required, since the builtin is part of the root set.
+ if (FLAG_mark_shared_functions_for_tier_up) {
+ // TODO(leszeks): The compilation isn't concurrent if we trigger it using
+ // this bit.
+ shared()->set_marked_for_tier_up(true);
+ }
}
// static
« no previous file with comments | « src/objects.h ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698