OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 8174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8185 ElementsKind boilerplate_elements_kind); | 8185 ElementsKind boilerplate_elements_kind); |
8186 static inline AllocationSiteMode GetMode(ElementsKind from, ElementsKind to); | 8186 static inline AllocationSiteMode GetMode(ElementsKind from, ElementsKind to); |
8187 static inline bool CanTrack(InstanceType type); | 8187 static inline bool CanTrack(InstanceType type); |
8188 | 8188 |
8189 static const int kTransitionInfoOffset = HeapObject::kHeaderSize; | 8189 static const int kTransitionInfoOffset = HeapObject::kHeaderSize; |
8190 static const int kNestedSiteOffset = kTransitionInfoOffset + kPointerSize; | 8190 static const int kNestedSiteOffset = kTransitionInfoOffset + kPointerSize; |
8191 static const int kDependentCodeOffset = kNestedSiteOffset + kPointerSize; | 8191 static const int kDependentCodeOffset = kNestedSiteOffset + kPointerSize; |
8192 static const int kWeakNextOffset = kDependentCodeOffset + kPointerSize; | 8192 static const int kWeakNextOffset = kDependentCodeOffset + kPointerSize; |
8193 static const int kSize = kWeakNextOffset + kPointerSize; | 8193 static const int kSize = kWeakNextOffset + kPointerSize; |
8194 | 8194 |
| 8195 // During mark compact we need to take special care for the dependent code |
| 8196 // field. |
| 8197 static const int kPointerFieldsBeginOffset = kTransitionInfoOffset; |
| 8198 static const int kPointerFieldsEndOffset = kDependentCodeOffset; |
| 8199 |
| 8200 // For other visitors, use the fixed body descriptor below. |
8195 typedef FixedBodyDescriptor<HeapObject::kHeaderSize, | 8201 typedef FixedBodyDescriptor<HeapObject::kHeaderSize, |
8196 kDependentCodeOffset + kPointerSize, | 8202 kDependentCodeOffset + kPointerSize, |
8197 kSize> BodyDescriptor; | 8203 kSize> BodyDescriptor; |
8198 | 8204 |
8199 private: | 8205 private: |
8200 inline DependentCode::DependencyGroup ToDependencyGroup(Reason reason); | 8206 inline DependentCode::DependencyGroup ToDependencyGroup(Reason reason); |
8201 DISALLOW_IMPLICIT_CONSTRUCTORS(AllocationSite); | 8207 DISALLOW_IMPLICIT_CONSTRUCTORS(AllocationSite); |
8202 }; | 8208 }; |
8203 | 8209 |
8204 | 8210 |
(...skipping 2362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10567 } else { | 10573 } else { |
10568 value &= ~(1 << bit_position); | 10574 value &= ~(1 << bit_position); |
10569 } | 10575 } |
10570 return value; | 10576 return value; |
10571 } | 10577 } |
10572 }; | 10578 }; |
10573 | 10579 |
10574 } } // namespace v8::internal | 10580 } } // namespace v8::internal |
10575 | 10581 |
10576 #endif // V8_OBJECTS_H_ | 10582 #endif // V8_OBJECTS_H_ |
OLD | NEW |