Commit 30addb3e authored by Georg Neis's avatar Georg Neis Committed by Commit Bot

[turbofan] Remove ConcurrentOptimizationPrepPhase.

Part of it was already obsolete. The other part, concerned with
typing, is moved to the TyperPhase.

Bug: v8:7790
Change-Id: If728b36d88d19ded26d818eb805d093942576fcd
Reviewed-on: https://chromium-review.googlesource.com/1242884Reviewed-by: 's avatarJaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56193}
parent 3815ad6d
......@@ -1045,7 +1045,6 @@ class PipelineWasmCompilationJob final : public OptimizedCompilationJob {
PipelineWasmCompilationJob::Status PipelineWasmCompilationJob::PrepareJobImpl(
Isolate* isolate) {
UNREACHABLE(); // Prepare should always be skipped for WasmCompilationJob.
return SUCCEEDED;
}
PipelineWasmCompilationJob::Status
......@@ -1125,7 +1124,6 @@ PipelineWasmCompilationJob::ExecuteJobImpl() {
PipelineWasmCompilationJob::Status PipelineWasmCompilationJob::FinalizeJobImpl(
Isolate* isolate) {
UNREACHABLE(); // Finalize should always be skipped for WasmCompilationJob.
return SUCCEEDED;
}
template <typename Phase>
......@@ -1260,6 +1258,11 @@ struct TyperPhase {
void Run(PipelineData* data, Zone* temp_zone, Typer* typer) {
NodeVector roots(temp_zone);
data->jsgraph()->GetCachedNodes(&roots);
// Make sure we always type True and False. Needed for escape analysis.
roots.push_back(data->jsgraph()->TrueConstant());
roots.push_back(data->jsgraph()->FalseConstant());
LoopVariableOptimizer induction_vars(data->jsgraph()->graph(),
data->common(), temp_zone);
if (FLAG_turbo_loop_variable) induction_vars.Run();
......@@ -1409,32 +1412,6 @@ struct LoopExitEliminationPhase {
}
};
struct ConcurrentOptimizationPrepPhase {
static const char* phase_name() { return "concurrency preparation"; }
void Run(PipelineData* data, Zone* temp_zone) {
// Make sure we cache these code stubs.
data->jsgraph()->CEntryStubConstant(1);
data->jsgraph()->CEntryStubConstant(2);
// TODO(turbofan): Remove this line once the Array constructor code
// is a proper builtin and no longer a CodeStub.
data->jsgraph()->ArrayConstructorStubConstant();
// This is needed for escape analysis.
NodeProperties::SetType(
data->jsgraph()->FalseConstant(),
Type::HeapConstant(data->js_heap_broker(),
data->isolate()->factory()->false_value(),
data->jsgraph()->zone()));
NodeProperties::SetType(
data->jsgraph()->TrueConstant(),
Type::HeapConstant(data->js_heap_broker(),
data->isolate()->factory()->true_value(),
data->jsgraph()->zone()));
}
};
struct GenericLoweringPhase {
static const char* phase_name() { return "generic lowering"; }
......@@ -2056,10 +2033,6 @@ bool PipelineImpl::CreateGraph() {
Run<TyperPhase>(data->CreateTyper(flags));
RunPrintAndVerify(TyperPhase::phase_name());
// Do some hacky things to prepare for the optimization phase.
// (caching handles, etc.).
Run<ConcurrentOptimizationPrepPhase>();
if (FLAG_concurrent_compiler_frontend) {
Run<CopyMetadataForConcurrentCompilePhase>();
} else {
......
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