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

Side by Side Diff: src/compiler/register-allocator.h

Issue 1415833002: [turbofan] Alternative splintering mechanism. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 2 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 unified diff | Download patch
« no previous file with comments | « src/compiler/live-range-separator.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_REGISTER_ALLOCATOR_H_ 5 #ifndef V8_REGISTER_ALLOCATOR_H_
6 #define V8_REGISTER_ALLOCATOR_H_ 6 #define V8_REGISTER_ALLOCATOR_H_
7 7
8 #include "src/compiler/instruction.h" 8 #include "src/compiler/instruction.h"
9 #include "src/ostreams.h" 9 #include "src/ostreams.h"
10 #include "src/register-configuration.h" 10 #include "src/register-configuration.h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 51
52 // Returns the index of the instruction to which this lifetime position 52 // Returns the index of the instruction to which this lifetime position
53 // corresponds. 53 // corresponds.
54 int ToInstructionIndex() const { 54 int ToInstructionIndex() const {
55 DCHECK(IsValid()); 55 DCHECK(IsValid());
56 return value_ / kStep; 56 return value_ / kStep;
57 } 57 }
58 58
59 // Returns true if this lifetime position corresponds to a START value 59 // Returns true if this lifetime position corresponds to a START value
60 bool IsStart() const { return (value_ & (kHalfStep - 1)) == 0; } 60 bool IsStart() const { return (value_ & (kHalfStep - 1)) == 0; }
61 // Returns true if this lifetime position corresponds to an END value
62 bool IsEnd() const { return (value_ & (kHalfStep - 1)) == 1; }
61 // Returns true if this lifetime position corresponds to a gap START value 63 // Returns true if this lifetime position corresponds to a gap START value
62 bool IsFullStart() const { return (value_ & (kStep - 1)) == 0; } 64 bool IsFullStart() const { return (value_ & (kStep - 1)) == 0; }
63 65
64 bool IsGapPosition() const { return (value_ & 0x2) == 0; } 66 bool IsGapPosition() const { return (value_ & 0x2) == 0; }
65 bool IsInstructionPosition() const { return !IsGapPosition(); } 67 bool IsInstructionPosition() const { return !IsGapPosition(); }
66 68
67 // Returns the lifetime position for the current START. 69 // Returns the lifetime position for the current START.
68 LifetimePosition Start() const { 70 LifetimePosition Start() const {
69 DCHECK(IsValid()); 71 DCHECK(IsValid());
70 return LifetimePosition(value_ & ~(kHalfStep - 1)); 72 return LifetimePosition(value_ & ~(kHalfStep - 1));
(...skipping 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after
1086 RegisterAllocationData* const data_; 1088 RegisterAllocationData* const data_;
1087 1089
1088 DISALLOW_COPY_AND_ASSIGN(LiveRangeConnector); 1090 DISALLOW_COPY_AND_ASSIGN(LiveRangeConnector);
1089 }; 1091 };
1090 1092
1091 } // namespace compiler 1093 } // namespace compiler
1092 } // namespace internal 1094 } // namespace internal
1093 } // namespace v8 1095 } // namespace v8
1094 1096
1095 #endif // V8_REGISTER_ALLOCATOR_H_ 1097 #endif // V8_REGISTER_ALLOCATOR_H_
OLDNEW
« no previous file with comments | « src/compiler/live-range-separator.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698