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

Side by Side Diff: src/objects-body-descriptors.h

Issue 1479483004: Allow in-object properties in JSArrayBuffer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@in-obj-data-view-and-array-buffer-view
Patch Set: Test updated Created 5 years 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/objects.cc ('k') | src/objects-body-descriptors-inl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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_BODY_DESCRIPTORS_H_ 5 #ifndef V8_OBJECTS_BODY_DESCRIPTORS_H_
6 #define V8_OBJECTS_BODY_DESCRIPTORS_H_ 6 #define V8_OBJECTS_BODY_DESCRIPTORS_H_
7 7
8 #include "src/objects.h" 8 #include "src/objects.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 int start_offset, int end_offset); 44 int start_offset, int end_offset);
45 45
46 template <typename ObjectVisitor> 46 template <typename ObjectVisitor>
47 static inline void IteratePointer(HeapObject* obj, int offset, 47 static inline void IteratePointer(HeapObject* obj, int offset,
48 ObjectVisitor* v); 48 ObjectVisitor* v);
49 49
50 template <typename StaticVisitor> 50 template <typename StaticVisitor>
51 static inline void IteratePointer(Heap* heap, HeapObject* obj, int offset); 51 static inline void IteratePointer(Heap* heap, HeapObject* obj, int offset);
52 52
53 protected: 53 protected:
54 // Returns true for all header fields. 54 // Returns true for all header and internal fields.
55 static inline bool IsValidSlotImpl(HeapObject* obj, int offset); 55 static inline bool IsValidSlotImpl(HeapObject* obj, int offset);
56 56
57 // Treats all header and internal fields in the range as tagged.
57 template <typename ObjectVisitor> 58 template <typename ObjectVisitor>
58 static inline void IterateBodyImpl(HeapObject* obj, int start_offset, 59 static inline void IterateBodyImpl(HeapObject* obj, int start_offset,
59 int end_offset, ObjectVisitor* v); 60 int end_offset, ObjectVisitor* v);
60 61
62 // Treats all header and internal fields in the range as tagged.
61 template <typename StaticVisitor> 63 template <typename StaticVisitor>
62 static inline void IterateBodyImpl(Heap* heap, HeapObject* obj, 64 static inline void IterateBodyImpl(Heap* heap, HeapObject* obj,
63 int start_offset, int end_offset); 65 int start_offset, int end_offset);
64 }; 66 };
65 67
66 68
67 // This class describes a body of an object of a fixed size 69 // This class describes a body of an object of a fixed size
68 // in which all pointer fields are located in the [start_offset, end_offset) 70 // in which all pointer fields are located in the [start_offset, end_offset)
69 // interval. 71 // interval.
70 template <int start_offset, int end_offset, int size> 72 template <int start_offset, int end_offset, int size>
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 static inline int SizeOf(Map* map, HeapObject* object); 132 static inline int SizeOf(Map* map, HeapObject* object);
131 }; 133 };
132 134
133 135
134 typedef FlexibleBodyDescriptor<HeapObject::kHeaderSize> StructBodyDescriptor; 136 typedef FlexibleBodyDescriptor<HeapObject::kHeaderSize> StructBodyDescriptor;
135 137
136 } // namespace internal 138 } // namespace internal
137 } // namespace v8 139 } // namespace v8
138 140
139 #endif // V8_OBJECTS_BODY_DESCRIPTORS_H_ 141 #endif // V8_OBJECTS_BODY_DESCRIPTORS_H_
OLDNEW
« no previous file with comments | « src/objects.cc ('k') | src/objects-body-descriptors-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698