Changeset 38080 in webkit for trunk/JavaScriptCore/runtime/StructureID.cpp
- Timestamp:
- Nov 3, 2008, 2:43:00 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/runtime/StructureID.cpp
r38046 r38080 39 39 #endif 40 40 41 #define DUMP_STRUCTURE_ID_STATISTICS 0 42 41 43 #ifndef NDEBUG 42 44 #define DO_PROPERTYMAP_CONSTENCY_CHECK 0 … … 71 73 #if DUMP_STRUCTURE_ID_STATISTICS 72 74 static HashSet<StructureID*> liveStructureIDSet; 75 #endif 73 76 74 77 void StructureID::dumpStatistics() 75 78 { 79 #if DUMP_STRUCTURE_ID_STATISTICS 76 80 unsigned numberLeaf = 0; 77 81 unsigned numberUsingSingleSlot = 0; … … 93 97 94 98 if (structureID->m_propertyTable) 95 totalPropertyMapsSize += PropertyMapHashTable::allocationSize( m_propertyTable->size);;99 totalPropertyMapsSize += PropertyMapHashTable::allocationSize(structureID->m_propertyTable->size); 96 100 } 97 101 … … 104 108 printf("Size of sum of all property maps: %d\n", totalPropertyMapsSize); 105 109 printf("Size of average of all property maps: %f\n", static_cast<double>(totalPropertyMapsSize) / static_cast<double>(liveStructureIDSet.size())); 106 } 107 #endif 110 #else 111 printf("Dumping StructureID statistics is not enabled.\n"); 112 #endif 113 } 108 114 109 115 StructureID::StructureID(JSValue* prototype, const TypeInfo& typeInfo)
Note:
See TracChangeset
for help on using the changeset viewer.