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

Unified Diff: src/compiler/pipeline.cc

Issue 1256313003: [turbofan] Preprocessing live ranges before register allocation. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 5 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 | « BUILD.gn ('k') | src/compiler/preprocess-live-ranges.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/pipeline.cc
diff --git a/src/compiler/pipeline.cc b/src/compiler/pipeline.cc
index d2c5fa6f35c3e2b465df7d6d07daab2b52df8187..f55b4d35125e2380bc1d94106c531ba548aa8c65 100644
--- a/src/compiler/pipeline.cc
+++ b/src/compiler/pipeline.cc
@@ -42,6 +42,7 @@
#include "src/compiler/move-optimizer.h"
#include "src/compiler/osr.h"
#include "src/compiler/pipeline-statistics.h"
+#include "src/compiler/preprocess-live-ranges.h"
#include "src/compiler/register-allocator.h"
#include "src/compiler/register-allocator-verifier.h"
#include "src/compiler/schedule.h"
@@ -785,6 +786,17 @@ struct BuildLiveRangesPhase {
};
+struct PreprocessLiveRangesPhase {
+ static const char* phase_name() { return "preprocess live ranges"; }
+
+ void Run(PipelineData* data, Zone* temp_zone) {
+ PreprocessLiveRanges live_range_preprocessor(
+ data->register_allocation_data(), temp_zone);
+ live_range_preprocessor.PreprocessRanges();
+ }
+};
+
+
template <typename RegAllocator>
struct AllocateGeneralRegistersPhase {
static const char* phase_name() { return "allocate general registers"; }
@@ -1320,6 +1332,11 @@ void Pipeline::AllocateRegisters(const RegisterConfiguration* config,
if (verifier != nullptr) {
CHECK(!data->register_allocation_data()->ExistsUseWithoutDefinition());
}
+
+ if (FLAG_turbo_preprocess_ranges) {
+ Run<PreprocessLiveRangesPhase>();
+ }
+
if (FLAG_turbo_greedy_regalloc) {
Run<AllocateGeneralRegistersPhase<GreedyAllocator>>();
Run<AllocateDoubleRegistersPhase<GreedyAllocator>>();
« no previous file with comments | « BUILD.gn ('k') | src/compiler/preprocess-live-ranges.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698