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

Unified Diff: src/compiler/greedy-allocator.h

Issue 1328783002: [turbofan] Greedy: split around calls heuristic. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 3 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 | « no previous file | src/compiler/greedy-allocator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/greedy-allocator.h
diff --git a/src/compiler/greedy-allocator.h b/src/compiler/greedy-allocator.h
index c4e330eb97cc0425d4ec7de4fdb7e0fe5d938fb9..7b808cf8fb31fe3d6786b8a04e10b3aededdc0f5 100644
--- a/src/compiler/greedy-allocator.h
+++ b/src/compiler/greedy-allocator.h
@@ -125,6 +125,22 @@ class GreedyAllocator final : public RegisterAllocator {
// This is the extension point for splitting heuristics.
void SplitOrSpillBlockedRange(LiveRange* range);
+ // Find a good position where to fill, after a range was spilled after a call.
+ LifetimePosition FindSplitPositionAfterCall(const LiveRange* range,
+ int call_index);
+ // Split a range around all calls it passes over. Returns true if any changes
+ // were made, or false if no calls were found.
+ bool TrySplitAroundCalls(LiveRange* range);
+
+ // Finds the first call instruction in the path of this range. Splits before
+ // and requeues that segment (if any), spills the section over the call, and
+ // returns the section after the call. The return is:
+ // - same range, if no call was found
+ // - nullptr, if the range finished at the call and there's no "after the
+ // call" portion.
+ // - the portion after the call.
+ LiveRange* GetRemainderAfterSplittingAroundFirstCall(LiveRange* range);
+
// Necessary heuristic: spill when all else failed.
void SpillRangeAsLastResort(LiveRange* range);
« no previous file with comments | « no previous file | src/compiler/greedy-allocator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698