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

Unified Diff: runtime/vm/compiler.cc

Issue 1459443002: VM: Add dart_precompiled build target, a standalone VM without the JIT compiler. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: merge Created 5 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/guard_field_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/compiler.cc
diff --git a/runtime/vm/compiler.cc b/runtime/vm/compiler.cc
index 3ce52e1a5cc8d4679bd39af77aabf9bfc211d777..a0d9df859384fc4750695f895d3122e3a2c2f680 100644
--- a/runtime/vm/compiler.cc
+++ b/runtime/vm/compiler.cc
@@ -77,6 +77,7 @@ DECLARE_FLAG(bool, trace_irregexp);
bool Compiler::always_optimize_ = false;
bool Compiler::allow_recompilation_ = true;
+#ifndef DART_PRECOMPILED
Ivan Posva 2015/11/20 05:14:50 if !defined(DART_PRECOMPILED)
// TODO(zerny): Factor out unoptimizing/optimizing pipelines and remove
// separate helpers functions & `optimizing` args.
@@ -1731,9 +1732,7 @@ void BackgroundCompiler::VisitPointers(ObjectPointerVisitor* visitor) {
void BackgroundCompiler::Stop(BackgroundCompiler* task) {
ASSERT(Isolate::Current()->background_compiler() == task);
- if (task == NULL) {
- return;
- }
+ ASSERT(task != NULL);
BackgroundCompilationQueue* function_queue = task->function_queue();
Monitor* queue_monitor = task->queue_monitor_;
@@ -1792,4 +1791,112 @@ void BackgroundCompiler::EnsureInit(Thread* thread) {
}
}
+
+#else // DART_PRECOMPILED
+
+
+DEFINE_RUNTIME_ENTRY(CompileFunction, 1) {
+ UNREACHABLE();
+}
+
+
+bool Compiler::IsBackgroundCompilation() {
+ UNREACHABLE();
+ return false;
+}
+
+
+RawError* Compiler::Compile(const Library& library, const Script& script) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+RawError* Compiler::CompileClass(const Class& cls) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+RawError* Compiler::CompileFunction(Thread* thread,
+ const Function& function) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+RawError* Compiler::EnsureUnoptimizedCode(Thread* thread,
+ const Function& function) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+RawError* Compiler::CompileOptimizedFunction(Thread* thread,
+ const Function& function,
+ intptr_t osr_id) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+RawError* Compiler::CompileParsedFunction(
+ ParsedFunction* parsed_function) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+void Compiler::ComputeLocalVarDescriptors(const Code& code) {
+ UNREACHABLE();
+}
+
+
+RawError* Compiler::CompileAllFunctions(const Class& cls) {
+ UNREACHABLE();
+ return Error::null();
+}
+
+
+void Compiler::CompileStaticInitializer(const Field& field) {
+ UNREACHABLE();
+}
+
+
+RawObject* Compiler::EvaluateStaticInitializer(const Field& field) {
+ ASSERT(field.HasPrecompiledInitializer());
+ const Function& initializer =
+ Function::Handle(field.PrecompiledInitializer());
+ return DartEntry::InvokeFunction(initializer, Object::empty_array());
+}
+
+
+
+RawObject* Compiler::ExecuteOnce(SequenceNode* fragment) {
+ UNREACHABLE();
+ return Object::null();
+}
+
+
+void BackgroundCompiler::CompileOptimized(const Function& function) {
+ UNREACHABLE();
+}
+
+
+void BackgroundCompiler::VisitPointers(ObjectPointerVisitor* visitor) {
+ UNREACHABLE();
+}
+
+
+void BackgroundCompiler::Stop(BackgroundCompiler* task) {
+ UNREACHABLE();
+}
+
+
+void BackgroundCompiler::EnsureInit(Thread* thread) {
+ UNREACHABLE();
+}
+
+#endif // DART_PRECOMPILED
+
} // namespace dart
« no previous file with comments | « runtime/vm/code_generator.cc ('k') | runtime/vm/guard_field_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698