Changeset 175443 in webkit
- Timestamp:
- Oct 31, 2014, 5:26:36 PM (11 years ago)
- Location:
- trunk/Source
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r175426 r175443 1 2014-10-31 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Use std::unique_ptr for TypeCountSet 4 https://bugs.webkit.org/show_bug.cgi?id=138242 5 6 Reviewed by Andreas Kling. 7 8 * heap/Heap.cpp: 9 (JSC::Heap::protectedObjectTypeCounts): 10 Use std::unique_ptr<> instead of PassOwnPtr|OwnPtr. 11 (JSC::Heap::objectTypeCounts): ditto. 12 * heap/Heap.h: 13 1 14 2014-10-31 Michael Saboff <msaboff@apple.com> 2 15 -
trunk/Source/JavaScriptCore/heap/Heap.cpp
r174789 r175443 255 255 class RecordType { 256 256 public: 257 typedef PassOwnPtr<TypeCountSet> ReturnType;257 typedef std::unique_ptr<TypeCountSet> ReturnType; 258 258 259 259 RecordType(); … … 263 263 private: 264 264 const char* typeName(JSCell*); 265 OwnPtr<TypeCountSet> m_typeCountSet;265 std::unique_ptr<TypeCountSet> m_typeCountSet; 266 266 }; 267 267 268 268 inline RecordType::RecordType() 269 : m_typeCountSet( adoptPtr(new TypeCountSet))269 : m_typeCountSet(std::make_unique<TypeCountSet>()) 270 270 { 271 271 } … … 284 284 } 285 285 286 inline PassOwnPtr<TypeCountSet> RecordType::returnValue()287 { 288 return m_typeCountSet.release();286 inline std::unique_ptr<TypeCountSet> RecordType::returnValue() 287 { 288 return WTF::move(m_typeCountSet); 289 289 } 290 290 … … 862 862 } 863 863 864 PassOwnPtr<TypeCountSet> Heap::protectedObjectTypeCounts()864 std::unique_ptr<TypeCountSet> Heap::protectedObjectTypeCounts() 865 865 { 866 866 return forEachProtectedCell<RecordType>(); 867 867 } 868 868 869 PassOwnPtr<TypeCountSet> Heap::objectTypeCounts()869 std::unique_ptr<TypeCountSet> Heap::objectTypeCounts() 870 870 { 871 871 HeapIterationScope iterationScope(*this); -
trunk/Source/JavaScriptCore/heap/Heap.h
r174795 r175443 172 172 JS_EXPORT_PRIVATE size_t protectedObjectCount(); 173 173 JS_EXPORT_PRIVATE size_t protectedGlobalObjectCount(); 174 JS_EXPORT_PRIVATE PassOwnPtr<TypeCountSet> protectedObjectTypeCounts();175 JS_EXPORT_PRIVATE PassOwnPtr<TypeCountSet> objectTypeCounts();174 JS_EXPORT_PRIVATE std::unique_ptr<TypeCountSet> protectedObjectTypeCounts(); 175 JS_EXPORT_PRIVATE std::unique_ptr<TypeCountSet> objectTypeCounts(); 176 176 void showStatistics(); 177 177 -
trunk/Source/WebKit/mac/ChangeLog
r175425 r175443 1 2014-10-31 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Use std::unique_ptr for TypeCountSet 4 https://bugs.webkit.org/show_bug.cgi?id=138242 5 6 Reviewed by Andreas Kling. 7 8 * Misc/WebCoreStatistics.mm: 9 (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]): Use std::unique_ptr<> instead of OwnPtr. 10 (+[WebCoreStatistics javaScriptObjectTypeCounts]): ditto. 11 1 12 2014-10-31 Beth Dakin <bdakin@apple.com> 2 13 -
trunk/Source/WebKit/mac/Misc/WebCoreStatistics.mm
r173251 r175443 87 87 NSCountedSet *result = [NSCountedSet set]; 88 88 89 OwnPtr<TypeCountSet> counts(JSDOMWindow::commonVM().heap.protectedObjectTypeCounts());89 std::unique_ptr<TypeCountSet> counts(JSDOMWindow::commonVM().heap.protectedObjectTypeCounts()); 90 90 HashCountedSet<const char*>::iterator end = counts->end(); 91 91 for (HashCountedSet<const char*>::iterator it = counts->begin(); it != end; ++it) … … 102 102 NSCountedSet *result = [NSCountedSet set]; 103 103 104 OwnPtr<TypeCountSet> counts(JSDOMWindow::commonVM().heap.objectTypeCounts());104 std::unique_ptr<TypeCountSet> counts(JSDOMWindow::commonVM().heap.objectTypeCounts()); 105 105 HashCountedSet<const char*>::iterator end = counts->end(); 106 106 for (HashCountedSet<const char*>::iterator it = counts->begin(); it != end; ++it) -
trunk/Source/WebKit/win/ChangeLog
r175406 r175443 1 2014-10-31 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Use std::unique_ptr for TypeCountSet 4 https://bugs.webkit.org/show_bug.cgi?id=138242 5 6 Reviewed by Andreas Kling. 7 8 * WebCoreStatistics.cpp: 9 (WebCoreStatistics::javaScriptProtectedObjectTypeCounts): Use std::unique_ptr<> instead of OwnPtr. 10 (WebCoreStatistics::javaScriptObjectTypeCounts): ditto. 11 1 12 2014-10-30 Darin Adler <darin@apple.com> 2 13 -
trunk/Source/WebKit/win/WebCoreStatistics.cpp
r173988 r175443 146 146 { 147 147 JSLockHolder lock(JSDOMWindow::commonVM()); 148 OwnPtr<TypeCountSet> jsObjectTypeNames(JSDOMWindow::commonVM().heap.protectedObjectTypeCounts());148 std::unique_ptr<TypeCountSet> jsObjectTypeNames(JSDOMWindow::commonVM().heap.protectedObjectTypeCounts()); 149 149 typedef TypeCountSet::const_iterator Iterator; 150 150 Iterator end = jsObjectTypeNames->end(); … … 164 164 165 165 JSLockHolder lock(JSDOMWindow::commonVM()); 166 OwnPtr<TypeCountSet> jsObjectTypeNames(JSDOMWindow::commonVM().heap.objectTypeCounts());166 std::unique_ptr<TypeCountSet> jsObjectTypeNames(JSDOMWindow::commonVM().heap.objectTypeCounts()); 167 167 typedef TypeCountSet::const_iterator Iterator; 168 168 Iterator end = jsObjectTypeNames->end(); -
trunk/Source/WebKit2/ChangeLog
r175430 r175443 1 2014-10-31 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Use std::unique_ptr for TypeCountSet 4 https://bugs.webkit.org/show_bug.cgi?id=138242 5 6 Reviewed by Andreas Kling. 7 8 * WebProcess/WebProcess.cpp: 9 (WebKit::WebProcess::getWebCoreStatistics): Use std::unique_ptr<> instead of OwnPtr. 10 1 11 2014-10-30 Jer Noble <jer.noble@apple.com> 2 12 -
trunk/Source/WebKit2/WebProcess/WebProcess.cpp
r175430 r175443 901 901 data.statisticsNumbers.set(ASCIILiteral("JavaScriptProtectedGlobalObjectsCount"), JSDOMWindow::commonVM().heap.protectedGlobalObjectCount()); 902 902 903 OwnPtr<TypeCountSet> protectedObjectTypeCounts(JSDOMWindow::commonVM().heap.protectedObjectTypeCounts());903 std::unique_ptr<TypeCountSet> protectedObjectTypeCounts(JSDOMWindow::commonVM().heap.protectedObjectTypeCounts()); 904 904 fromCountedSetToHashMap(protectedObjectTypeCounts.get(), data.javaScriptProtectedObjectTypeCounts); 905 905 906 OwnPtr<TypeCountSet> objectTypeCounts(JSDOMWindow::commonVM().heap.objectTypeCounts());906 std::unique_ptr<TypeCountSet> objectTypeCounts(JSDOMWindow::commonVM().heap.objectTypeCounts()); 907 907 fromCountedSetToHashMap(objectTypeCounts.get(), data.javaScriptObjectTypeCounts); 908 908
Note:
See TracChangeset
for help on using the changeset viewer.