Changeset 39956 in webkit for trunk/JavaScriptCore/runtime
- Timestamp:
- Jan 15, 2009, 4:53:41 PM (16 years ago)
- Location:
- trunk/JavaScriptCore/runtime
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/runtime/Collector.cpp
r39954 r39956 1006 1006 size_t Heap::objectCount() 1007 1007 { 1008 return primaryHeap.numLiveObjects + numberHeap.numLiveObjects ;1008 return primaryHeap.numLiveObjects + numberHeap.numLiveObjects - m_globalData->smallStrings.count(); 1009 1009 } 1010 1010 -
trunk/JavaScriptCore/runtime/SmallStrings.cpp
r39815 r39956 100 100 } 101 101 } 102 102 103 unsigned SmallStrings::count() const 104 { 105 unsigned count = 0; 106 if (m_emptyString) 107 ++count; 108 for (unsigned i = 0; i < numCharactersToStore; ++i) { 109 if (m_singleCharacterStrings[i]) 110 ++count; 111 } 112 return count; 113 } 114 103 115 void SmallStrings::createEmptyString(JSGlobalData* globalData) 104 116 { -
trunk/JavaScriptCore/runtime/SmallStrings.h
r39815 r39956 59 59 void mark(); 60 60 61 unsigned count() const; 62 61 63 private: 62 64 void createEmptyString(JSGlobalData*);
Note:
See TracChangeset
for help on using the changeset viewer.