OLD | NEW |
1 // Copyright 2017 the V8 project authors. All rights reserved. | 1 // Copyright 2017 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_OBJECTS_DESCRIPTOR_ARRAY_H_ | 5 #ifndef V8_OBJECTS_DESCRIPTOR_ARRAY_H_ |
6 #define V8_OBJECTS_DESCRIPTOR_ARRAY_H_ | 6 #define V8_OBJECTS_DESCRIPTOR_ARRAY_H_ |
7 | 7 |
8 #include "src/objects.h" | 8 #include "src/objects.h" |
9 | 9 |
10 // Has to be the last include (doesn't have include guards): | 10 // Has to be the last include (doesn't have include guards): |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 INLINE(int SearchWithCache(Isolate* isolate, Name* name, Map* map)); | 109 INLINE(int SearchWithCache(Isolate* isolate, Name* name, Map* map)); |
110 | 110 |
111 bool IsEqualUpTo(DescriptorArray* desc, int nof_descriptors); | 111 bool IsEqualUpTo(DescriptorArray* desc, int nof_descriptors); |
112 | 112 |
113 // Allocates a DescriptorArray, but returns the singleton | 113 // Allocates a DescriptorArray, but returns the singleton |
114 // empty descriptor array object if number_of_descriptors is 0. | 114 // empty descriptor array object if number_of_descriptors is 0. |
115 static Handle<DescriptorArray> Allocate( | 115 static Handle<DescriptorArray> Allocate( |
116 Isolate* isolate, int number_of_descriptors, int slack, | 116 Isolate* isolate, int number_of_descriptors, int slack, |
117 PretenureFlag pretenure = NOT_TENURED); | 117 PretenureFlag pretenure = NOT_TENURED); |
118 | 118 |
119 DECLARE_CAST(DescriptorArray) | 119 DECL_CAST(DescriptorArray) |
120 | 120 |
121 // Constant for denoting key was not found. | 121 // Constant for denoting key was not found. |
122 static const int kNotFound = -1; | 122 static const int kNotFound = -1; |
123 | 123 |
124 static const int kDescriptorLengthIndex = 0; | 124 static const int kDescriptorLengthIndex = 0; |
125 static const int kEnumCacheBridgeIndex = 1; | 125 static const int kEnumCacheBridgeIndex = 1; |
126 static const int kFirstIndex = 2; | 126 static const int kFirstIndex = 2; |
127 | 127 |
128 // The length of the "bridge" to the enum cache. | 128 // The length of the "bridge" to the enum cache. |
129 static const int kEnumCacheBridgeLength = 2; | 129 static const int kEnumCacheBridgeLength = 2; |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
197 | 197 |
198 DISALLOW_IMPLICIT_CONSTRUCTORS(DescriptorArray); | 198 DISALLOW_IMPLICIT_CONSTRUCTORS(DescriptorArray); |
199 }; | 199 }; |
200 | 200 |
201 } // namespace internal | 201 } // namespace internal |
202 } // namespace v8 | 202 } // namespace v8 |
203 | 203 |
204 #include "src/objects/object-macros-undef.h" | 204 #include "src/objects/object-macros-undef.h" |
205 | 205 |
206 #endif // V8_OBJECTS_DESCRIPTOR_ARRAY_H_ | 206 #endif // V8_OBJECTS_DESCRIPTOR_ARRAY_H_ |
OLD | NEW |