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

Unified Diff: src/compiler/register-allocator.cc

Issue 2060673002: [turbofan] Retiring Greedy Allocator (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 6 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 | « src/compiler/register-allocator.h ('k') | src/flag-definitions.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/register-allocator.cc
diff --git a/src/compiler/register-allocator.cc b/src/compiler/register-allocator.cc
index 2bb0a8a49944a39d6d8e4185932522ec495289a8..119e11f031c372f8a49732dc8940975b33d180c4 100644
--- a/src/compiler/register-allocator.cc
+++ b/src/compiler/register-allocator.cc
@@ -413,11 +413,6 @@ std::ostream& operator<<(std::ostream& os, const LifetimePosition pos) {
return os;
}
-
-const float LiveRange::kInvalidWeight = -1;
-const float LiveRange::kMaxWeight = std::numeric_limits<float>::max();
-
-
LiveRange::LiveRange(int relative_id, MachineRepresentation rep,
TopLevelLiveRange* top_level)
: relative_id_(relative_id),
@@ -430,10 +425,7 @@ LiveRange::LiveRange(int relative_id, MachineRepresentation rep,
current_interval_(nullptr),
last_processed_use_(nullptr),
current_hint_position_(nullptr),
- splitting_pointer_(nullptr),
- size_(kInvalidSize),
- weight_(kInvalidWeight),
- group_(nullptr) {
+ splitting_pointer_(nullptr) {
DCHECK(AllocatedOperand::IsSupportedRepresentation(rep));
bits_ = AssignedRegisterField::encode(kUnassignedRegister) |
RepresentationField::encode(rep);
@@ -699,10 +691,6 @@ UsePosition* LiveRange::DetachAt(LifetimePosition position, LiveRange* result,
last_processed_use_ = nullptr;
current_interval_ = nullptr;
- // Invalidate size and weight of this range. The child range has them
- // invalid at construction.
- size_ = kInvalidSize;
- weight_ = kInvalidWeight;
#ifdef DEBUG
VerifyChildStructure();
result->VerifyChildStructure();
@@ -818,20 +806,6 @@ LifetimePosition LiveRange::FirstIntersection(LiveRange* other) const {
return LifetimePosition::Invalid();
}
-
-unsigned LiveRange::GetSize() {
- if (size_ == kInvalidSize) {
- size_ = 0;
- for (const UseInterval* interval = first_interval(); interval != nullptr;
- interval = interval->next()) {
- size_ += (interval->end().value() - interval->start().value());
- }
- }
-
- return static_cast<unsigned>(size_);
-}
-
-
void LiveRange::Print(const RegisterConfiguration* config,
bool with_children) const {
OFStream os(stdout);
« no previous file with comments | « src/compiler/register-allocator.h ('k') | src/flag-definitions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698