Commit 04ba79eb authored by jochen's avatar jochen Committed by Commit bot

Create compiler-scheduler subdir and move existing scheduler there

BUG=v8:5215
R=marja@chromium.org

Review-Url: https://codereview.chromium.org/2161033003
Cr-Commit-Position: refs/heads/master@{#37906}
parent 0ae0fbce
......@@ -650,9 +650,13 @@ action("run_mksnapshot") {
action("run_mkpeephole") {
visibility = [ ":*" ] # Only targets in this file can depend on this.
deps = [ ":mkpeephole($v8_snapshot_toolchain)" ]
deps = [
":mkpeephole($v8_snapshot_toolchain)",
]
outputs = [ v8_generated_peephole_source ]
outputs = [
v8_generated_peephole_source,
]
sources = []
......@@ -915,6 +919,8 @@ v8_source_set("v8_base") {
"src/compilation-dependencies.h",
"src/compilation-statistics.cc",
"src/compilation-statistics.h",
"src/compiler-dispatcher/optimizing-compile-dispatcher.cc",
"src/compiler-dispatcher/optimizing-compile-dispatcher.h",
"src/compiler.cc",
"src/compiler.h",
"src/compiler/access-builder.cc",
......@@ -1407,8 +1413,6 @@ v8_source_set("v8_base") {
"src/objects-printer.cc",
"src/objects.cc",
"src/objects.h",
"src/optimizing-compile-dispatcher.cc",
"src/optimizing-compile-dispatcher.h",
"src/ostreams.cc",
"src/ostreams.h",
"src/parsing/expression-classifier.h",
......
......@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "src/optimizing-compile-dispatcher.h"
#include "src/compiler-dispatcher/optimizing-compile-dispatcher.h"
#include "src/base/atomicops.h"
#include "src/full-codegen/full-codegen.h"
......@@ -29,7 +29,6 @@ void DisposeCompilationJob(CompilationJob* job, bool restore_function_code) {
} // namespace
class OptimizingCompileDispatcher::CompileTask : public v8::Task {
public:
explicit CompileTask(Isolate* isolate) : isolate_(isolate) {
......@@ -76,7 +75,6 @@ class OptimizingCompileDispatcher::CompileTask : public v8::Task {
DISALLOW_COPY_AND_ASSIGN(CompileTask);
};
OptimizingCompileDispatcher::~OptimizingCompileDispatcher() {
#ifdef DEBUG
{
......@@ -120,7 +118,6 @@ void OptimizingCompileDispatcher::CompileNext(CompilationJob* job) {
isolate_->stack_guard()->RequestInstallCode();
}
void OptimizingCompileDispatcher::FlushOutputQueue(bool restore_function_code) {
for (;;) {
CompilationJob* job = NULL;
......@@ -135,7 +132,6 @@ void OptimizingCompileDispatcher::FlushOutputQueue(bool restore_function_code) {
}
}
void OptimizingCompileDispatcher::Flush() {
base::Release_Store(&mode_, static_cast<base::AtomicWord>(FLUSH));
if (FLAG_block_concurrent_recompilation) Unblock();
......@@ -150,7 +146,6 @@ void OptimizingCompileDispatcher::Flush() {
}
}
void OptimizingCompileDispatcher::Stop() {
base::Release_Store(&mode_, static_cast<base::AtomicWord>(FLUSH));
if (FLAG_block_concurrent_recompilation) Unblock();
......@@ -170,7 +165,6 @@ void OptimizingCompileDispatcher::Stop() {
}
}
void OptimizingCompileDispatcher::InstallOptimizedFunctions() {
HandleScope handle_scope(isolate_);
......@@ -214,7 +208,6 @@ void OptimizingCompileDispatcher::QueueForOptimization(CompilationJob* job) {
}
}
void OptimizingCompileDispatcher::Unblock() {
while (blocked_jobs_ > 0) {
V8::GetCurrentPlatform()->CallOnBackgroundThread(
......@@ -223,6 +216,5 @@ void OptimizingCompileDispatcher::Unblock() {
}
}
} // namespace internal
} // namespace v8
......@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef V8_OPTIMIZING_COMPILE_DISPATCHER_H_
#define V8_OPTIMIZING_COMPILE_DISPATCHER_H_
#ifndef V8_COMPILER_DISPATCHER_OPTIMIZING_COMPILE_DISPATCHER_H_
#define V8_COMPILER_DISPATCHER_OPTIMIZING_COMPILE_DISPATCHER_H_
#include <queue>
......@@ -99,4 +99,4 @@ class OptimizingCompileDispatcher {
} // namespace internal
} // namespace v8
#endif // V8_OPTIMIZING_COMPILE_DISPATCHER_H_
#endif // V8_COMPILER_DISPATCHER_OPTIMIZING_COMPILE_DISPATCHER_H_
......@@ -17,6 +17,7 @@
#include "src/base/hashmap.h"
#include "src/builtins/builtins.h"
#include "src/cancelable-task.h"
#include "src/compiler-dispatcher/optimizing-compile-dispatcher.h"
#include "src/contexts.h"
#include "src/date.h"
#include "src/execution.h"
......@@ -26,7 +27,6 @@
#include "src/handles.h"
#include "src/heap/heap.h"
#include "src/messages.h"
#include "src/optimizing-compile-dispatcher.h"
#include "src/regexp/regexp-stack.h"
#include "src/runtime-profiler.h"
#include "src/runtime/runtime.h"
......
......@@ -730,6 +730,8 @@
'compiler/wasm-linkage.cc',
'compiler/zone-pool.cc',
'compiler/zone-pool.h',
'compiler-dispatcher/optimizing-compile-dispatcher.cc',
'compiler-dispatcher/optimizing-compile-dispatcher.h',
'compiler.cc',
'compiler.h',
'context-measure.cc',
......@@ -1027,8 +1029,6 @@
'objects-printer.cc',
'objects.cc',
'objects.h',
'optimizing-compile-dispatcher.cc',
'optimizing-compile-dispatcher.h',
'ostreams.cc',
'ostreams.h',
'parsing/expression-classifier.h',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment