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

Side by Side Diff: src/objects.h

Issue 892843002: Add mistagging-readbarrier to weak cell Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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
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 9696 matching lines...) Expand 10 before | Expand all | Expand 10 after
9707 kSize> BodyDescriptor; 9707 kSize> BodyDescriptor;
9708 9708
9709 private: 9709 private:
9710 DECL_ACCESSORS(type_raw, Object) 9710 DECL_ACCESSORS(type_raw, Object)
9711 DISALLOW_IMPLICIT_CONSTRUCTORS(PropertyCell); 9711 DISALLOW_IMPLICIT_CONSTRUCTORS(PropertyCell);
9712 }; 9712 };
9713 9713
9714 9714
9715 class WeakCell : public HeapObject { 9715 class WeakCell : public HeapObject {
9716 public: 9716 public:
9717 inline Object* value() const; 9717 inline Object* value();
9718 inline Object* ValueNoReadBarrier();
9718 9719
9719 // This should not be called by anyone except GC. 9720 // This should not be called by anyone except GC.
9720 inline void clear(); 9721 inline void clear();
9721 9722
9722 // This should not be called by anyone except allocator. 9723 // This should not be called by anyone except allocator.
9723 inline void initialize(HeapObject* value); 9724 inline void initialize(HeapObject* value);
9724 9725
9725 inline bool cleared() const; 9726 inline bool cleared() const;
9726 9727
9727 DECL_ACCESSORS(next, Object) 9728 DECL_ACCESSORS(next, Object)
9728 9729
9729 DECLARE_CAST(WeakCell) 9730 DECLARE_CAST(WeakCell)
9730 9731
9731 DECLARE_PRINTER(WeakCell) 9732 DECLARE_PRINTER(WeakCell)
9732 DECLARE_VERIFIER(WeakCell) 9733 DECLARE_VERIFIER(WeakCell)
9733 9734
9734 // Layout description. 9735 // Layout description.
9735 static const int kValueOffset = HeapObject::kHeaderSize; 9736 static const int kValueOffsetDontForgetTheReadBarrier =
9736 static const int kNextOffset = kValueOffset + kPointerSize; 9737 HeapObject::kHeaderSize;
9738 static const int kNextOffset =
9739 kValueOffsetDontForgetTheReadBarrier + kPointerSize;
9737 static const int kSize = kNextOffset + kPointerSize; 9740 static const int kSize = kNextOffset + kPointerSize;
9738 9741
9739 typedef FixedBodyDescriptor<kValueOffset, kSize, kSize> BodyDescriptor; 9742 typedef FixedBodyDescriptor<kValueOffsetDontForgetTheReadBarrier, kSize,
9743 kSize> BodyDescriptor;
9740 9744
9741 private: 9745 private:
9742 DISALLOW_IMPLICIT_CONSTRUCTORS(WeakCell); 9746 DISALLOW_IMPLICIT_CONSTRUCTORS(WeakCell);
9743 }; 9747 };
9744 9748
9745 9749
9746 // The JSProxy describes EcmaScript Harmony proxies 9750 // The JSProxy describes EcmaScript Harmony proxies
9747 class JSProxy: public JSReceiver { 9751 class JSProxy: public JSReceiver {
9748 public: 9752 public:
9749 // [handler]: The handler property. 9753 // [handler]: The handler property.
(...skipping 1178 matching lines...) Expand 10 before | Expand all | Expand 10 after
10928 } else { 10932 } else {
10929 value &= ~(1 << bit_position); 10933 value &= ~(1 << bit_position);
10930 } 10934 }
10931 return value; 10935 return value;
10932 } 10936 }
10933 }; 10937 };
10934 10938
10935 } } // namespace v8::internal 10939 } } // namespace v8::internal
10936 10940
10937 #endif // V8_OBJECTS_H_ 10941 #endif // V8_OBJECTS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698