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

Unified Diff: runtime/bin/main.cc

Issue 1731743003: Move precompilation-related flags to flags list. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: make print_stop_message default false to fix build Created 4 years, 10 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/bin/gen_snapshot.cc ('k') | runtime/lib/regexp.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/main.cc
diff --git a/runtime/bin/main.cc b/runtime/bin/main.cc
index 464248693688501638eaa5d9c2a8d0de69cc6c3e..bb21b9f3cee09c503911b63dff4409f99acf72f2 100644
--- a/runtime/bin/main.cc
+++ b/runtime/bin/main.cc
@@ -340,7 +340,10 @@ static bool ProcessGenPrecompiledSnapshotOption(
precompiled_snapshot_directory = arg;
}
gen_precompiled_snapshot = true;
+#if !defined(DART_PRECOMPILED_RUNTIME)
+ // The precompiled runtime has FLAG_precompilation set as const.
vm_options->AddArgument("--precompilation");
+#endif
return true;
}
@@ -355,7 +358,10 @@ static bool ProcessRunPrecompiledSnapshotOption(
precompiled_snapshot_directory = &precompiled_snapshot_directory[1];
}
run_precompiled_snapshot = true;
+#if !defined(DART_PRECOMPILED_RUNTIME)
+ // The precompiled runtime has FLAG_precompilation set as const.
vm_options->AddArgument("--precompilation");
+#endif
return true;
}
@@ -1556,11 +1562,14 @@ void main(int argc, char** argv) {
Platform::Exit(kErrorExitCode);
}
+#if !defined(PRODUCT)
+ // Constant true in PRODUCT mode.
if (generate_script_snapshot ||
generate_full_snapshot_after_run ||
run_full_snapshot) {
vm_options.AddArgument("--load_deferred_eagerly");
}
+#endif
#if defined(DART_PRECOMPILER) && !defined(DART_NO_SNAPSHOT)
// Always set --precompilation with dart_noopt.
« no previous file with comments | « runtime/bin/gen_snapshot.cc ('k') | runtime/lib/regexp.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698