| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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_TRANSITIONS_H_ | 5 #ifndef V8_TRANSITIONS_H_ |
| 6 #define V8_TRANSITIONS_H_ | 6 #define V8_TRANSITIONS_H_ |
| 7 | 7 |
| 8 #include "src/checks.h" | 8 #include "src/checks.h" |
| 9 #include "src/elements-kind.h" | 9 #include "src/elements-kind.h" |
| 10 #include "src/heap/heap.h" | 10 #include "src/heap/heap.h" |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 | 163 |
| 164 static int Capacity(Object* raw_transitions); | 164 static int Capacity(Object* raw_transitions); |
| 165 | 165 |
| 166 inline static TransitionArray* cast(Object* object); | 166 inline static TransitionArray* cast(Object* object); |
| 167 | 167 |
| 168 // This field should be used only by GC. | 168 // This field should be used only by GC. |
| 169 inline void set_next_link(Object* next, WriteBarrierMode mode); | 169 inline void set_next_link(Object* next, WriteBarrierMode mode); |
| 170 inline Object* next_link(); | 170 inline Object* next_link(); |
| 171 | 171 |
| 172 static const int kTransitionSize = 2; | 172 static const int kTransitionSize = 2; |
| 173 static const int kEntrySize = kTransitionSize; |
| 173 static const int kProtoTransitionHeaderSize = 1; | 174 static const int kProtoTransitionHeaderSize = 1; |
| 174 | 175 |
| 175 #if defined(DEBUG) || defined(OBJECT_PRINT) | 176 #if defined(DEBUG) || defined(OBJECT_PRINT) |
| 176 // For our gdb macros, we should perhaps change these in the future. | 177 // For our gdb macros, we should perhaps change these in the future. |
| 177 void Print(); | 178 void Print(); |
| 178 | 179 |
| 179 // Print all the transitions. | 180 // Print all the transitions. |
| 180 static void PrintTransitions(std::ostream& os, Object* transitions, | 181 static void PrintTransitions(std::ostream& os, Object* transitions, |
| 181 bool print_header = true); // NOLINT | 182 bool print_header = true); // NOLINT |
| 182 #endif | 183 #endif |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 317 static void ZapTransitionArray(TransitionArray* transitions); | 318 static void ZapTransitionArray(TransitionArray* transitions); |
| 318 | 319 |
| 319 DISALLOW_IMPLICIT_CONSTRUCTORS(TransitionArray); | 320 DISALLOW_IMPLICIT_CONSTRUCTORS(TransitionArray); |
| 320 }; | 321 }; |
| 321 | 322 |
| 322 | 323 |
| 323 } // namespace internal | 324 } // namespace internal |
| 324 } // namespace v8 | 325 } // namespace v8 |
| 325 | 326 |
| 326 #endif // V8_TRANSITIONS_H_ | 327 #endif // V8_TRANSITIONS_H_ |
| OLD | NEW |