Remove ENABLE_WORKERS

https://bugs.webkit.org/show_bug.cgi?id=105784

.:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* Source/autotools/SetupWebKitFeatures.m4:
* Source/cmake/WebKitFeatures.cmake:
* Source/cmakeconfig.h.cmake:

Source/WebCore:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

Source/WebKit:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:

Source/WebKit/efl:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* ewk/ewk_settings.cpp:
(ewk_settings_memory_cache_clear):

Source/WebKit/win:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* WebWorkersPrivate.cpp:
(WebWorkersPrivate::workerThreadCount):

Source/WTF:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* wtf/FeatureDefines.h:
* wtf/nix/FeatureDefinesNix.h:

Tools:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* Scripts/webkitperl/FeatureList.pm:

WebKitLibraries:

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-11-21
Reviewed by Darin Adler.

* win/tools/vsprops/FeatureDefines.props:
* win/tools/vsprops/FeatureDefinesCairo.props:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@159679 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent eca09750
2013-11-21 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
Remove ENABLE_WORKERS
https://bugs.webkit.org/show_bug.cgi?id=105784
Reviewed by Darin Adler.
* Source/autotools/SetupWebKitFeatures.m4:
* Source/cmake/WebKitFeatures.cmake:
* Source/cmakeconfig.h.cmake:
2013-11-20 Commit Queue <commit-queue@webkit.org>
Unreviewed, rolling out r159496.
......
2013-11-21 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
Remove ENABLE_WORKERS
https://bugs.webkit.org/show_bug.cgi?id=105784
Reviewed by Darin Adler.
* wtf/FeatureDefines.h:
* wtf/nix/FeatureDefinesNix.h:
2013-11-21 Mark Rowe <mrowe@apple.com>
<https://webkit.org/b/124701> Fix an error in a few Xcode configuration setting files.
......
......@@ -863,10 +863,6 @@
#define ENABLE_WEB_TIMING 0
#endif
#if !defined(ENABLE_WORKERS)
#define ENABLE_WORKERS 0
#endif
#if !defined(ENABLE_XHR_TIMEOUT)
#define ENABLE_XHR_TIMEOUT 0
#endif
......
......@@ -278,10 +278,6 @@
#define ENABLE_WEB_TIMING 1
#endif
#if !defined(ENABLE_WORKERS)
#define ENABLE_WORKERS 1
#endif
#if !defined(ENABLE_XHR_RESPONSE_BLOB)
#define ENABLE_XHR_RESPONSE_BLOB 1
#endif
......
......@@ -2605,7 +2605,7 @@ set(WebCore_LIBRARIES
WTF
)
if (ENABLE_SQL_DATABASE AND ENABLE_WORKERS)
if (ENABLE_SQL_DATABASE)
list(APPEND WebCore_SOURCES
Modules/webdatabase/WorkerGlobalScopeWebDatabase.cpp
)
......
2013-11-21 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
Remove ENABLE_WORKERS
https://bugs.webkit.org/show_bug.cgi?id=105784
Reviewed by Darin Adler.
2013-11-21 Alex Christensen <achristensen@webkit.org>
[Win] Unreviewed build fix after r159632.
......@@ -74,10 +74,6 @@ static bool isContextValid(ScriptExecutionContext* context)
Document* document = toDocument(context);
return document->frame() && document->page();
}
#if !ENABLE(WORKERS)
if (context->isWorkerGlobalScope())
return false;
#endif
return true;
}
......@@ -88,12 +84,10 @@ static String getIndexedDBDatabasePath(ScriptExecutionContext* context)
Document* document = toDocument(context);
return document->page()->group().groupSettings().indexedDBDatabasePath();
}
#if ENABLE(WORKERS)
WorkerGlobalScope* workerGlobalScope = static_cast<WorkerGlobalScope*>(context);
const GroupSettings* groupSettings = workerGlobalScope->groupSettings();
if (groupSettings)
return groupSettings->indexedDBDatabasePath();
#endif
return String();
}
}
......
......@@ -27,7 +27,7 @@
#include "config.h"
#if ENABLE(WORKERS) && ENABLE(INDEXED_DATABASE)
#if ENABLE(INDEXED_DATABASE)
#include "WorkerGlobalScopeIndexedDatabase.h"
......@@ -84,4 +84,4 @@ IDBFactory* WorkerGlobalScopeIndexedDatabase::indexedDB()
} // namespace WebCore
#endif // ENABLE(WORKERS) && ENABLE(INDEXED_DATABASE)
#endif // ENABLE(INDEXED_DATABASE)
......@@ -27,7 +27,7 @@
#ifndef WorkerGlobalScopeIndexedDatabase_h
#define WorkerGlobalScopeIndexedDatabase_h
#if ENABLE(WORKERS) && ENABLE(INDEXED_DATABASE)
#if ENABLE(INDEXED_DATABASE)
#include "Supplementable.h"
#include <wtf/text/WTFString.h>
......@@ -58,6 +58,6 @@ private:
} // namespace WebCore
#endif // ENABLE(WORKERS) && ENABLE(INDEXED_DATABASE)
#endif // ENABLE(INDEXED_DATABASE)
#endif // WorkerGlobalScopeIndexedDatabase_h
......@@ -27,7 +27,7 @@
#include "config.h"
#if ENABLE(SQL_DATABASE) && ENABLE(WORKERS)
#if ENABLE(SQL_DATABASE)
#include "WorkerGlobalScopeWebDatabase.h"
......@@ -73,4 +73,4 @@ PassRefPtr<DatabaseSync> WorkerGlobalScopeWebDatabase::openDatabaseSync(WorkerGl
} // namespace WebCore
#endif // ENABLE(SQL_DATABASE) && ENABLE(WORKERS)
#endif // ENABLE(SQL_DATABASE)
......@@ -27,7 +27,7 @@
#ifndef WorkerGlobalScopeWebDatabase_h
#define WorkerGlobalScopeWebDatabase_h
#if ENABLE(SQL_DATABASE) && ENABLE(WORKERS)
#if ENABLE(SQL_DATABASE)
#include "ExceptionCode.h"
#include <wtf/Forward.h>
......@@ -54,6 +54,6 @@ private:
} // namespace WebCore
#endif // ENABLE(SQL_DATABASE) && ENABLE(WORKERS)
#endif // ENABLE(SQL_DATABASE)
#endif // WorkerGlobalScopeWebDatabase_h
......@@ -25,7 +25,7 @@
*/
[
Conditional=SQL_DATABASE&WORKERS,
Conditional=SQL_DATABASE,
] partial interface WorkerGlobalScope {
[RaisesException] Database openDatabase(DOMString name, DOMString version, DOMString displayName, unsigned long estimatedSize, optional DatabaseCallback creationCallback);
......
......@@ -55,7 +55,6 @@ PassRefPtr<ThreadableWebSocketChannel> ThreadableWebSocketChannel::create(Script
ASSERT(context);
ASSERT(client);
#if ENABLE(WORKERS)
if (context->isWorkerGlobalScope()) {
WorkerGlobalScope* workerGlobalScope = static_cast<WorkerGlobalScope*>(context);
WorkerRunLoop& runLoop = workerGlobalScope->thread()->runLoop();
......@@ -63,7 +62,6 @@ PassRefPtr<ThreadableWebSocketChannel> ThreadableWebSocketChannel::create(Script
mode.append(String::number(runLoop.createUniqueId()));
return WorkerThreadableWebSocketChannel::create(workerGlobalScope, client, mode);
}
#endif // ENABLE(WORKERS)
return WebSocketChannel::create(toDocument(context), client);
}
......
......@@ -29,7 +29,7 @@
*/
#include "config.h"
#if ENABLE(WEB_SOCKETS) && ENABLE(WORKERS)
#if ENABLE(WEB_SOCKETS)
#include "ThreadableWebSocketChannelClientWrapper.h"
#include "CrossThreadCopier.h"
......
......@@ -31,7 +31,7 @@
#ifndef ThreadableWebSocketChannelClientWrapper_h
#define ThreadableWebSocketChannelClientWrapper_h
#if ENABLE(WEB_SOCKETS) && ENABLE(WORKERS)
#if ENABLE(WEB_SOCKETS)
#include "ScriptExecutionContext.h"
#include "ThreadableWebSocketChannel.h"
......
......@@ -30,7 +30,7 @@
#include "config.h"
#if ENABLE(WEB_SOCKETS) && ENABLE(WORKERS)
#if ENABLE(WEB_SOCKETS)
#include "WorkerThreadableWebSocketChannel.h"
......
......@@ -31,7 +31,7 @@
#ifndef WorkerThreadableWebSocketChannel_h
#define WorkerThreadableWebSocketChannel_h
#if ENABLE(WEB_SOCKETS) && ENABLE(WORKERS)
#if ENABLE(WEB_SOCKETS)
#include "ThreadableWebSocketChannel.h"
#include "WebSocketChannelClient.h"
......
......@@ -184,7 +184,6 @@ if (ENABLE_INDEXED_DATABASE)
)
endif ()
if (ENABLE_WORKERS)
list(APPEND WebCore_SOURCES
bindings/js/JSDedicatedWorkerGlobalScopeCustom.cpp
bindings/js/JSWorkerGlobalScopeBase.cpp
......@@ -193,7 +192,6 @@ if (ENABLE_WORKERS)
bindings/js/WorkerScriptController.cpp
bindings/js/WorkerScriptDebugServer.cpp
)
endif ()
if (ENABLE_VIDEO_TRACK)
list(APPEND WebCore_SOURCES
......
......@@ -241,6 +241,7 @@ __ZN7WebCore12TextIterator8subrangeEPNS_5RangeEii
__ZN7WebCore12TextIteratorC1EPKNS_5RangeENS_20TextIteratorBehaviorE
__ZN7WebCore12TextIteratorD1Ev
__ZN7WebCore12UTF8EncodingEv
__ZN7WebCore12WorkerThread17workerThreadCountEv
__ZN7WebCore12cacheStorageEv
__ZN7WebCore12deleteCookieERKNS_21NetworkStorageSessionERKNS_3URLERKN3WTF6StringE
__ZN7WebCore12gcControllerEv
......@@ -2881,10 +2882,6 @@ __ZNK7WebCore16HTMLMediaElement6pausedEv
__ZN7WebCore4Page11setViewModeENS0_8ViewModeE
#endif
#if ENABLE(WORKERS)
__ZN7WebCore12WorkerThread17workerThreadCountEv
#endif
#if ENABLE(VIDEO_TRACK)
__ZN7WebCore9PageGroup18captionPreferencesEv
#endif
......
......@@ -33,9 +33,11 @@
#include "ThreadCheck.h"
#include "WebDOMDOMApplicationCache.h"
#include "WebDOMDOMWindow.h"
#include "WebDOMDedicatedWorkerGlobalScope.h"
#include "WebDOMEventSource.h"
#include "WebDOMMessagePort.h"
#include "WebDOMNode.h"
#include "WebDOMWorker.h"
#include "WebDOMXMLHttpRequest.h"
#include "WebDOMXMLHttpRequestUpload.h"
#include "WebExceptionHandler.h"
......@@ -46,11 +48,6 @@
#include <wtf/RefPtr.h>
#if ENABLE(WORKERS)
#include "WebDOMDedicatedWorkerGlobalScope.h"
#include "WebDOMWorker.h"
#endif
#if ENABLE(SHARED_WORKERS)
#include "WebDOMSharedWorker.h"
#include "WebDOMSharedWorkerGlobalScope.h"
......@@ -112,11 +109,6 @@ WebDOM##type WebDOMEventTarget::to##type() \
ConvertTo(Node)
ConvertTo(DOMWindow)
#if ENABLE(WORKERS) && 0
ConvertTo(Worker)
ConvertTo(DedicatedWorkerGlobalScope)
#endif
#if ENABLE(SHARED_WORKERS)
ConvertTo(SharedWorker)
ConvertTo(SharedWorkerGlobalScope)
......@@ -150,14 +142,6 @@ WebDOMEventTarget toWebKit(WebCore::EventTarget* value)
return toWebKit(instance);
#endif
#if ENABLE(WORKERS) && 0
if (WebCore::Worker* worker = value->toWorker())
return toWebKit(worker);
if (WebCore::DedicatedWorkerGlobalScope* workerGlobalScope = value->toDedicatedWorkerGlobalScope())
return toWebKit(workerGlobalScope);
#endif
#if ENABLE(SHARED_WORKERS)
if (WebCore::SharedWorker* sharedWorker = value->toSharedWorker())
return toWebKit(sharedWorker);
......
......@@ -33,10 +33,7 @@
#include "ActiveDOMObject.h"
#include "ScriptExecutionContext.h"
#if ENABLE(WORKERS)
#include "WorkerGlobalScope.h"
#endif
namespace WebCore {
......
......@@ -31,9 +31,7 @@
#include "DOMWrapperWorld.h"
#include "Document.h"
#include "ScriptState.h"
#if ENABLE(WORKERS)
#include "WorkerGlobalScope.h"
#endif
#include <JavaScriptCore/APIShims.h>
......@@ -51,10 +49,8 @@ public:
Document* document = toDocument(m_scriptExecutionContext);
m_exec = execStateFromPage(mainThreadNormalWorld(), document->page());
} else {
#if ENABLE(WORKERS)
WorkerGlobalScope* workerGlobalScope = static_cast<WorkerGlobalScope*>(m_scriptExecutionContext);
m_exec = execStateFromWorkerGlobalScope(workerGlobalScope);
#endif
}
}
......
......@@ -30,11 +30,8 @@
#include "Document.h"
#include "JSDOMWindow.h"
#include "JSEventListener.h"
#if ENABLE(WORKERS)
#include "JSWorkerGlobalScope.h"
#include "WorkerGlobalScope.h"
#endif
using namespace JSC;
......@@ -71,10 +68,8 @@ ScriptExecutionContext* JSDOMGlobalObject::scriptExecutionContext() const
{
if (inherits(JSDOMWindowBase::info()))
return jsCast<const JSDOMWindowBase*>(this)->scriptExecutionContext();
#if ENABLE(WORKERS)
if (inherits(JSWorkerGlobalScopeBase::info()))
return jsCast<const JSWorkerGlobalScopeBase*>(this)->scriptExecutionContext();
#endif
ASSERT_NOT_REACHED();
return 0;
}
......@@ -116,10 +111,8 @@ JSDOMGlobalObject* toJSDOMGlobalObject(ScriptExecutionContext* scriptExecutionCo
if (scriptExecutionContext->isDocument())
return toJSDOMGlobalObject(toDocument(scriptExecutionContext), exec);
#if ENABLE(WORKERS)
if (scriptExecutionContext->isWorkerGlobalScope())
return static_cast<WorkerGlobalScope*>(scriptExecutionContext)->script()->workerGlobalScopeWrapper();
#endif
ASSERT_NOT_REACHED();
return 0;
......@@ -135,10 +128,8 @@ JSDOMGlobalObject* toJSDOMGlobalObject(ScriptExecutionContext* scriptExecutionCo
if (scriptExecutionContext->isDocument())
return toJSDOMGlobalObject(toDocument(scriptExecutionContext), world);
#if ENABLE(WORKERS)
if (scriptExecutionContext->isWorkerGlobalScope())
return static_cast<WorkerGlobalScope*>(scriptExecutionContext)->script()->workerGlobalScopeWrapper();
#endif
ASSERT_NOT_REACHED();
return 0;
......
......@@ -31,15 +31,12 @@
#include "JSHTMLOptionElement.h"
#include "JSImageConstructor.h"
#include "JSMessagePortCustom.h"
#include "JSWorker.h"
#include "Location.h"
#include "ScheduledAction.h"
#include "Settings.h"
#include "SharedWorkerRepository.h"
#if ENABLE(WORKERS)
#include "JSWorker.h"
#endif
#if ENABLE(SHARED_WORKERS)
#include "JSSharedWorker.h"
#endif
......
......@@ -30,9 +30,6 @@
*/
#include "config.h"
#if ENABLE(WORKERS)
#include "JSDedicatedWorkerGlobalScope.h"
#include "JSDOMBinding.h"
......@@ -48,5 +45,3 @@ JSC::JSValue JSDedicatedWorkerGlobalScope::postMessage(JSC::ExecState* exec)
}
} // namespace WebCore
#endif // ENABLE(WORKERS)
......@@ -137,13 +137,11 @@ void JSEventListener::handleEvent(ScriptExecutionContext* scriptExecutionContext
globalObject->setCurrentEvent(savedEvent);
#if ENABLE(WORKERS)
if (scriptExecutionContext->isWorkerGlobalScope()) {
bool terminatorCausedException = (exec->hadException() && isTerminatedExecutionException(exec->exception()));
if (terminatorCausedException || vm.watchdog.didFire())
static_cast<WorkerGlobalScope*>(scriptExecutionContext)->script()->forbidExecution();
}
#endif
if (exec->hadException()) {
event->target()->uncaughtExceptionInEventHandler();
......
......@@ -26,8 +26,6 @@
#include "config.h"
#if ENABLE(WORKERS)
#include "JSWorker.h"
#include "Document.h"
......@@ -72,5 +70,3 @@ EncodedJSValue JSC_HOST_CALL JSWorkerConstructor::constructJSWorker(ExecState* e
}
} // namespace WebCore
#endif // ENABLE(WORKERS)
......@@ -27,8 +27,6 @@
#include "config.h"
#if ENABLE(WORKERS)
#include "JSWorkerGlobalScopeBase.h"
#include "DOMWrapperWorld.h"
......@@ -157,5 +155,3 @@ JSWorkerGlobalScope* toJSWorkerGlobalScope(JSValue value)
}
} // namespace WebCore
#endif // ENABLE(WORKERS)
......@@ -27,8 +27,6 @@
#ifndef JSWorkerGlobalScopeBase_h
#define JSWorkerGlobalScopeBase_h
#if ENABLE(WORKERS)
#include "JSDOMGlobalObject.h"
namespace WebCore {
......@@ -85,6 +83,4 @@ namespace WebCore {
} // namespace WebCore
#endif // ENABLE(WORKERS)
#endif // JSWorkerGlobalScopeBase_h
......@@ -25,8 +25,6 @@
#include "config.h"
#if ENABLE(WORKERS)
#include "JSWorkerGlobalScope.h"
#include "ExceptionCode.h"
......@@ -118,5 +116,3 @@ JSValue JSWorkerGlobalScope::setInterval(ExecState* exec)
}
} // namespace WebCore
#endif // ENABLE(WORKERS)
......@@ -33,17 +33,14 @@
#include "JSDOMWindow.h"
#include "JSMainThreadExecState.h"
#include "JSMainThreadExecStateInstrumentation.h"
#include "JSWorkerGlobalScope.h"
#include "ScriptController.h"
#include "ScriptExecutionContext.h"
#include "ScriptSourceCode.h"
#include "ScriptValue.h"
#include <runtime/JSLock.h>
#if ENABLE(WORKERS)
#include "JSWorkerGlobalScope.h"
#include "WorkerGlobalScope.h"
#include "WorkerThread.h"
#endif
#include <runtime/JSLock.h>
using namespace JSC;
......@@ -79,14 +76,10 @@ void ScheduledAction::execute(ScriptExecutionContext* context)
{
if (context->isDocument())
execute(toDocument(context));
#if ENABLE(WORKERS)
else {
ASSERT_WITH_SECURITY_IMPLICATION(context->isWorkerGlobalScope());
execute(static_cast<WorkerGlobalScope*>(context));
}
#else
ASSERT(context->isDocument());
#endif
}
void ScheduledAction::executeFunctionInContext(JSGlobalObject* globalObject, JSValue thisValue, ScriptExecutionContext* context)
......@@ -135,7 +128,6 @@ void ScheduledAction::execute(Document* document)
frame->script().executeScriptInWorld(*m_isolatedWorld, m_code);
}
#if ENABLE(WORKERS)
void ScheduledAction::execute(WorkerGlobalScope* workerGlobalScope)
{
// In a Worker, the execution should always happen on a worker thread.
......@@ -151,6 +143,5 @@ void ScheduledAction::execute(WorkerGlobalScope* workerGlobalScope)
scriptController->evaluate(code);
}
}
#endif // ENABLE(WORKERS)
} // namespace WebCore
......@@ -61,9 +61,7 @@ namespace WebCore {
void executeFunctionInContext(JSC::JSGlobalObject*, JSC::JSValue thisValue, ScriptExecutionContext*);
void execute(Document*);
#if ENABLE(WORKERS)
void execute(WorkerGlobalScope*);
#endif
JSC::Strong<JSC::Unknown> m_function;
Vector<JSC::Strong<JSC::Unknown>> m_args;
......
......@@ -68,12 +68,10 @@ void ScriptProfiler::startForPage(Page* inspectedPage, const String& title)
start(scriptState, title);
}
#if ENABLE(WORKERS)
void ScriptProfiler::startForWorkerGlobalScope(WorkerGlobalScope* context, const String& title)
{
start(execStateFromWorkerGlobalScope(context), title);
}
#endif
PassRefPtr<ScriptProfile> ScriptProfiler::stop(JSC::ExecState* state, const String& title)
{
......@@ -87,12 +85,10 @@ PassRefPtr<ScriptProfile> ScriptProfiler::stopForPage(Page* inspectedPage, const
return stop(scriptState, title);
}
#if ENABLE(WORKERS)
PassRefPtr<ScriptProfile> ScriptProfiler::stopForWorkerGlobalScope(WorkerGlobalScope* context, const String& title)
{
return stop(execStateFromWorkerGlobalScope(context), title);
}
#endif
} // namespace WebCore
......
......@@ -61,14 +61,10 @@ public:
static unsigned getHeapObjectId(const ScriptValue&);
static void start(JSC::ExecState*, const String& title);
static void startForPage(Page*, const String& title);
#if ENABLE(WORKERS)
static void startForWorkerGlobalScope(WorkerGlobalScope*, const String& title);
#endif
static PassRefPtr<ScriptProfile> stop(JSC::ExecState*, const String& title);
static PassRefPtr<ScriptProfile> stopForPage(Page*, const String& title);
#if ENABLE(WORKERS)
static PassRefPtr<ScriptProfile> stopForWorkerGlobalScope(WorkerGlobalScope*, const String& title);
#endif
static PassRefPtr<ScriptHeapSnapshot> takeHeapSnapshot(const String&, HeapSnapshotProgress*) { return 0; }
static bool causesRecompilation() { return true; }
static bool isSampling() { return false; }
......