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

Side by Side Diff: src/objects.h

Issue 1176263004: Introduce a base pointer field in FixedTypedArrayBase and teach GC about it (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 unified diff | Download patch
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/objects.cc » ('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 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_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 4575 matching lines...) Expand 10 before | Expand all | Expand 10 after
4586 DECLARE_PRINTER(ExternalFloat64Array) 4586 DECLARE_PRINTER(ExternalFloat64Array)
4587 DECLARE_VERIFIER(ExternalFloat64Array) 4587 DECLARE_VERIFIER(ExternalFloat64Array)
4588 4588
4589 private: 4589 private:
4590 DISALLOW_IMPLICIT_CONSTRUCTORS(ExternalFloat64Array); 4590 DISALLOW_IMPLICIT_CONSTRUCTORS(ExternalFloat64Array);
4591 }; 4591 };
4592 4592
4593 4593
4594 class FixedTypedArrayBase: public FixedArrayBase { 4594 class FixedTypedArrayBase: public FixedArrayBase {
4595 public: 4595 public:
4596 // [base_pointer]: For now, points to the FixedTypedArrayBase itself.
4597 DECL_ACCESSORS(base_pointer, Object)
4598
4599 // Dispatched behavior.
4600 inline void FixedTypedArrayBaseIterateBody(ObjectVisitor* v);
4601
4602 template <typename StaticVisitor>
4603 inline void FixedTypedArrayBaseIterateBody();
4604
4596 DECLARE_CAST(FixedTypedArrayBase) 4605 DECLARE_CAST(FixedTypedArrayBase)
4597 4606
4607 static const int kBasePointerOffset =
4608 FixedArrayBase::kHeaderSize + kPointerSize;
4609 static const int kHeaderSize = kBasePointerOffset + kPointerSize;
4610
4598 static const int kDataOffset = DOUBLE_POINTER_ALIGN(kHeaderSize); 4611 static const int kDataOffset = DOUBLE_POINTER_ALIGN(kHeaderSize);
4599 4612
4600 inline int size(); 4613 inline int size();
4601 4614
4602 static inline int TypedArraySize(InstanceType type, int length); 4615 static inline int TypedArraySize(InstanceType type, int length);
4603 inline int TypedArraySize(InstanceType type); 4616 inline int TypedArraySize(InstanceType type);
4604 4617
4605 // Use with care: returns raw pointer into heap. 4618 // Use with care: returns raw pointer into heap.
4606 inline void* DataPtr(); 4619 inline void* DataPtr();
4607 4620
(...skipping 6242 matching lines...) Expand 10 before | Expand all | Expand 10 after
10850 } else { 10863 } else {
10851 value &= ~(1 << bit_position); 10864 value &= ~(1 << bit_position);
10852 } 10865 }
10853 return value; 10866 return value;
10854 } 10867 }
10855 }; 10868 };
10856 10869
10857 } } // namespace v8::internal 10870 } } // namespace v8::internal
10858 10871
10859 #endif // V8_OBJECTS_H_ 10872 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698