[WTF] Drop Thread::create(obsolete things) API since we can use lambda
authorutatane.tea@gmail.com <utatane.tea@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Jun 2017 18:19:36 +0000 (18:19 +0000)
committerutatane.tea@gmail.com <utatane.tea@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Jun 2017 18:19:36 +0000 (18:19 +0000)
commitaf3cb96948b1112921731f5249fd961ccd7751cb
tree36d91b94491989f2fea57f61f37fe3f626510eab
parent06aec906e79048553a64075ece5a9c0eac200b9b
[WTF] Drop Thread::create(obsolete things) API since we can use lambda
https://bugs.webkit.org/show_bug.cgi?id=173825

Reviewed by Saam Barati.

Source/JavaScriptCore:

* jsc.cpp:
(startTimeoutThreadIfNeeded):
(timeoutThreadMain): Deleted.

Source/WebCore:

No behavior change.

* Modules/indexeddb/server/IDBServer.cpp:
(WebCore::IDBServer::IDBServer::IDBServer):
(WebCore::IDBServer::IDBServer::databaseThreadEntry): Deleted.
* Modules/indexeddb/server/IDBServer.h:
* Modules/webaudio/AsyncAudioDecoder.cpp:
(WebCore::AsyncAudioDecoder::AsyncAudioDecoder):
(WebCore::AsyncAudioDecoder::threadEntry): Deleted.
* Modules/webaudio/AsyncAudioDecoder.h:
* Modules/webaudio/OfflineAudioDestinationNode.cpp:
(WebCore::OfflineAudioDestinationNode::startRendering):
(WebCore::OfflineAudioDestinationNode::offlineRenderEntry): Deleted.
* Modules/webaudio/OfflineAudioDestinationNode.h:
* Modules/webdatabase/DatabaseThread.cpp:
(WebCore::DatabaseThread::start):
(WebCore::DatabaseThread::databaseThreadStart): Deleted.
* Modules/webdatabase/DatabaseThread.h:
* bindings/js/GCController.cpp:
(WebCore::collect):
(WebCore::GCController::gcTimerFired):
(WebCore::GCController::garbageCollectOnAlternateThreadForDebugging):
* loader/icon/IconDatabase.cpp:
(WebCore::IconDatabase::open):
(WebCore::IconDatabase::iconDatabaseSyncThreadStart): Deleted.
* loader/icon/IconDatabase.h:
* page/ResourceUsageThread.cpp:
(WebCore::ResourceUsageThread::createThreadIfNeeded):
(WebCore::ResourceUsageThread::threadCallback): Deleted.
* page/ResourceUsageThread.h:
* page/scrolling/ScrollingThread.cpp:
(WebCore::ScrollingThread::createThreadIfNeeded):
(WebCore::ScrollingThread::threadCallback): Deleted.
(WebCore::ScrollingThread::threadBody): Deleted.
* page/scrolling/ScrollingThread.h:
* platform/audio/HRTFDatabaseLoader.cpp:
(WebCore::HRTFDatabaseLoader::loadAsynchronously):
(WebCore::databaseLoaderEntry): Deleted.
* platform/audio/HRTFDatabaseLoader.h:
* platform/audio/ReverbConvolver.cpp:
(WebCore::ReverbConvolver::ReverbConvolver):
(WebCore::backgroundThreadEntry): Deleted.
* platform/audio/ReverbConvolver.h:
(WebCore::ReverbConvolver::useBackgroundThreads):
* platform/network/cf/LoaderRunLoopCF.cpp:
(WebCore::loaderRunLoop):
(WebCore::runLoaderThread): Deleted.
* platform/network/curl/CurlManager.cpp:
(WebCore::CurlManager::startThreadIfNeeded):
(WebCore::CurlManager::workerThread):
* platform/network/curl/CurlManager.h:
* workers/WorkerThread.cpp:
(WebCore::WorkerThread::start):
(WebCore::WorkerThread::workerThreadStart): Deleted.
* workers/WorkerThread.h:

Source/WebKit:

* Storage/StorageThread.cpp:
(WebCore::StorageThread::start):
(WebCore::StorageThread::threadEntryPointCallback): Deleted.
* Storage/StorageThread.h:

Source/WTF:

Thread::create(ThreadFunction, void* data, const char* name) is a bit old API.
Since we have C++ lambda, the above API is simply unnecessary. And C++ lambda
based one is better since the above API needs casting data to and from void*.

* wtf/Function.h:
Avoid ambiguity.
* wtf/ParallelJobsGeneric.cpp:
(WTF::ParallelEnvironment::ThreadPrivate::tryLockFor):
(WTF::ParallelEnvironment::ThreadPrivate::workerThread): Deleted.
* wtf/ParallelJobsGeneric.h:
* wtf/Threading.cpp:
* wtf/ThreadingWin.cpp:
(WTF::createThread):

Tools:

* DumpRenderTree/JavaScriptThreading.cpp:
(runJavaScriptThread):
(startJavaScriptThreads):
* DumpRenderTree/mac/DumpRenderTree.mm:
(runThread):
(runPthread):
(testThreadIdentifierMap):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@218816 268f45cc-cd09-0410-ab3c-d52691b4dbfc
39 files changed:
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/jsc.cpp
Source/WTF/ChangeLog
Source/WTF/wtf/Function.h
Source/WTF/wtf/ParallelJobsGeneric.cpp
Source/WTF/wtf/ParallelJobsGeneric.h
Source/WTF/wtf/Threading.cpp
Source/WTF/wtf/ThreadingWin.cpp
Source/WebCore/ChangeLog
Source/WebCore/Modules/indexeddb/server/IDBServer.cpp
Source/WebCore/Modules/indexeddb/server/IDBServer.h
Source/WebCore/Modules/webaudio/AsyncAudioDecoder.cpp
Source/WebCore/Modules/webaudio/AsyncAudioDecoder.h
Source/WebCore/Modules/webaudio/OfflineAudioDestinationNode.cpp
Source/WebCore/Modules/webaudio/OfflineAudioDestinationNode.h
Source/WebCore/Modules/webdatabase/DatabaseThread.cpp
Source/WebCore/Modules/webdatabase/DatabaseThread.h
Source/WebCore/bindings/js/GCController.cpp
Source/WebCore/loader/icon/IconDatabase.cpp
Source/WebCore/loader/icon/IconDatabase.h
Source/WebCore/page/ResourceUsageThread.cpp
Source/WebCore/page/ResourceUsageThread.h
Source/WebCore/page/scrolling/ScrollingThread.cpp
Source/WebCore/page/scrolling/ScrollingThread.h
Source/WebCore/platform/audio/HRTFDatabaseLoader.cpp
Source/WebCore/platform/audio/HRTFDatabaseLoader.h
Source/WebCore/platform/audio/ReverbConvolver.cpp
Source/WebCore/platform/audio/ReverbConvolver.h
Source/WebCore/platform/network/cf/LoaderRunLoopCF.cpp
Source/WebCore/platform/network/curl/CurlManager.cpp
Source/WebCore/platform/network/curl/CurlManager.h
Source/WebCore/workers/WorkerThread.cpp
Source/WebCore/workers/WorkerThread.h
Source/WebKit/ChangeLog
Source/WebKit/Storage/StorageThread.cpp
Source/WebKit/Storage/StorageThread.h
Tools/ChangeLog
Tools/DumpRenderTree/JavaScriptThreading.cpp
Tools/DumpRenderTree/mac/DumpRenderTree.mm