Changeset 119795 in webkit for trunk/Source/JavaScriptCore/runtime/JSObject.h
- Timestamp:
- Jun 7, 2012, 9:25:58 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/runtime/JSObject.h
r119568 r119795 237 237 static size_t offsetOfInlineStorage(); 238 238 static size_t offsetOfPropertyStorage(); 239 static size_t offsetOfInheritorID();240 239 241 240 static JS_EXPORTDATA const ClassInfo s_info; … … 265 264 JSObject(JSGlobalData&, Structure*, PropertyStorage inlineStorage); 266 265 267 void resetInheritorID( )268 { 269 m_inheritorID.clear();266 void resetInheritorID(JSGlobalData& globalData) 267 { 268 removeDirect(globalData, globalData.m_inheritorIDKey); 270 269 } 271 270 … … 304 303 305 304 StorageBarrier m_propertyStorage; 306 WriteBarrier<Structure> m_inheritorID; 305 306 #if USE(JSVALUE32_64) 307 // FIXME: keep the size of JSObject a multiple of 64-bits, so that the 308 // internal storage is aligned. We can remove this when we remove JSCell's 309 // direct ClassInfo pointer. 310 void* sixtyFourBitAlign; 311 #endif 307 312 }; 308 313 … … 312 317 #define JSFinalObject_inlineStorageCapacity 6 313 318 #else 314 #define JSNonFinalObject_inlineStorageCapacity 2315 #define JSFinalObject_inlineStorageCapacity 4319 #define JSNonFinalObject_inlineStorageCapacity 3 320 #define JSFinalObject_inlineStorageCapacity 5 316 321 #endif 317 322 … … 418 423 } 419 424 420 inline size_t JSObject::offsetOfInheritorID()421 {422 return OBJECT_OFFSETOF(JSObject, m_inheritorID);423 }424 425 425 inline bool JSObject::isGlobalObject() const 426 426 { … … 515 515 inline Structure* JSObject::inheritorID(JSGlobalData& globalData) 516 516 { 517 if (m_inheritorID) { 518 ASSERT(m_inheritorID->isEmpty()); 519 return m_inheritorID.get(); 517 if (WriteBarrierBase<Unknown>* location = getDirectLocation(globalData, globalData.m_inheritorIDKey)) { 518 Structure* inheritorID = jsCast<Structure*>(location->get()); 519 ASSERT(inheritorID->isEmpty()); 520 return inheritorID; 520 521 } 521 522 return createInheritorID(globalData);
Note:
See TracChangeset
for help on using the changeset viewer.