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

Side by Side Diff: runtime/vm/freelist.h

Issue 2953753002: Revert "Inline instance object hash code into object header on 64 bit." (Closed)
Patch Set: Created 3 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 | « runtime/vm/clustered_snapshot.cc ('k') | runtime/vm/freelist.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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef RUNTIME_VM_FREELIST_H_ 5 #ifndef RUNTIME_VM_FREELIST_H_
6 #define RUNTIME_VM_FREELIST_H_ 6 #define RUNTIME_VM_FREELIST_H_
7 7
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/allocation.h" 9 #include "vm/allocation.h"
10 #include "vm/bit_set.h" 10 #include "vm/bit_set.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 static const ClassId kClassId = kFreeListElement; 49 static const ClassId kClassId = kFreeListElement;
50 static bool IsInstance() { return true; } 50 static bool IsInstance() { return true; }
51 51
52 private: 52 private:
53 DISALLOW_ALLOCATION(); 53 DISALLOW_ALLOCATION();
54 DISALLOW_COPY_AND_ASSIGN(FakeInstance); 54 DISALLOW_COPY_AND_ASSIGN(FakeInstance);
55 }; 55 };
56 56
57 private: 57 private:
58 // This layout mirrors the layout of RawObject. 58 // This layout mirrors the layout of RawObject.
59 uint32_t tags_; 59 uword tags_;
60 #if defined(HASH_IN_OBJECT_HEADER)
61 uint32_t hash_;
62 #endif
63 FreeListElement* next_; 60 FreeListElement* next_;
64 61
65 // Returns the address of the embedded size. 62 // Returns the address of the embedded size.
66 intptr_t* SizeAddress() const { 63 intptr_t* SizeAddress() const {
67 uword addr = reinterpret_cast<uword>(&next_) + kWordSize; 64 uword addr = reinterpret_cast<uword>(&next_) + kWordSize;
68 return reinterpret_cast<intptr_t*>(addr); 65 return reinterpret_cast<intptr_t*>(addr);
69 } 66 }
70 67
71 // FreeListElements cannot be allocated. Instead references to them are 68 // FreeListElements cannot be allocated. Instead references to them are
72 // created using the AsElement factory method. 69 // created using the AsElement factory method.
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 125
129 // The largest available small size in bytes, or negative if there is none. 126 // The largest available small size in bytes, or negative if there is none.
130 intptr_t last_free_small_size_; 127 intptr_t last_free_small_size_;
131 128
132 DISALLOW_COPY_AND_ASSIGN(FreeList); 129 DISALLOW_COPY_AND_ASSIGN(FreeList);
133 }; 130 };
134 131
135 } // namespace dart 132 } // namespace dart
136 133
137 #endif // RUNTIME_VM_FREELIST_H_ 134 #endif // RUNTIME_VM_FREELIST_H_
OLDNEW
« no previous file with comments | « runtime/vm/clustered_snapshot.cc ('k') | runtime/vm/freelist.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698