WebKit-https.git
7 years agoFix Windows build.
andersca@apple.com [Mon, 7 Oct 2013 23:33:14 +0000 (23:33 +0000)]
Fix Windows build.

* wtf/StdLibExtras.h:
(std::make_unique):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157066 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Live node lists always have an owner Node.
akling@apple.com [Mon, 7 Oct 2013 23:05:58 +0000 (23:05 +0000)]
CTTE: Live node lists always have an owner Node.
<https://webkit.org/b/122470>

Reviewed by Anders Carlsson.

Make LiveNodeListBase::m_ownerNode a Ref<Node> instead of a RefPtr
and have all constructors take Node&.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157065 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoReduce duplicated code in WebPageProxy
kov@webkit.org [Mon, 7 Oct 2013 23:01:31 +0000 (23:01 +0000)]
Reduce duplicated code in WebPageProxy
https://bugs.webkit.org/show_bug.cgi?id=122230

Patch by Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk> on 2013-10-07
Reviewed by Darin Adler.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::close): move duplicate code to resetState and call it.
(WebKit::WebPageProxy::resetState): new private method for code that is shared between
close and resetStateAfterProcessExited.
(WebKit::WebPageProxy::resetStateAfterProcessExited): move duplicate code to resetState
and call it.
* UIProcess/WebPageProxy.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157064 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFix test failures.
andersca@apple.com [Mon, 7 Oct 2013 22:58:20 +0000 (22:58 +0000)]
Fix test failures.

* Scripts/webkitpy/port/base.py:
(Port.to.start_helper):
* Scripts/webkitpy/port/mock_drt.py:
(MockDRTPort.start_helper):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157063 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFTL memory allocator should be able to allocate data sections in non-executable memory
fpizlo@apple.com [Mon, 7 Oct 2013 22:46:54 +0000 (22:46 +0000)]
FTL memory allocator should be able to allocate data sections in non-executable memory
https://bugs.webkit.org/show_bug.cgi?id=116189

Reviewed by Sam Weinig.

Use a RefCountedArray<int64_t> for data sections. This works out great because
RefCountedArray<> knows its own size and because the reference counting makes passing
it around very easy (you don't have to stress out about ownership).

* ftl/FTLCompile.cpp:
(JSC::FTL::mmAllocateDataSection):
(JSC::FTL::compile):
* ftl/FTLJITCode.cpp:
(JSC::FTL::JITCode::addDataSection):
* ftl/FTLJITCode.h:
(JSC::FTL::JITCode::dataSections):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157062 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoClean up ScriptExecutionContext::Task and subclasses
andersca@apple.com [Mon, 7 Oct 2013 22:37:25 +0000 (22:37 +0000)]
Clean up ScriptExecutionContext::Task and subclasses
https://bugs.webkit.org/show_bug.cgi?id=122469

Reviewed by Andreas Kling.

* Modules/webdatabase/Database.cpp:
(WebCore::DerefContextTask::DerefContextTask):
(WebCore::Database::~Database):
(WebCore::DeliverPendingCallbackTask::DeliverPendingCallbackTask):
(WebCore::Database::scheduleTransactionCallback):
* Modules/webdatabase/DatabaseManager.cpp:
(WebCore::DatabaseCreationCallbackTask::DatabaseCreationCallbackTask):
(WebCore::DatabaseManager::openDatabase):
* Modules/webdatabase/SQLCallbackWrapper.h:
(WebCore::SQLCallbackWrapper::clear):
(WebCore::SQLCallbackWrapper::SafeReleaseTask::SafeReleaseTask):
* Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
(WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
* Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
* Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
(WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::WorkerGlobalScopeDidInitializeTask):
(WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
* bindings/js/JSCallbackData.h:
(WebCore::DeleteCallbackDataTask::DeleteCallbackDataTask):
* bindings/js/JSDOMGlobalObjectTask.h:
* bindings/js/JSDOMWindowBase.cpp:
(WebCore::JSDOMWindowBase::queueTaskToEventLoop):
* bindings/js/JSWorkerGlobalScopeBase.cpp:
(WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateCallbackImplementation):
* dom/CrossThreadTask.h:
(WebCore::createCallbackTask):
* dom/Document.cpp:
(WebCore::Document::addConsoleMessage):
(WebCore::Document::addMessage):
(WebCore::PerformTaskContext::PerformTaskContext):
(WebCore::Document::postTask):
(WebCore::Document::pendingTasksTimerFired):
* dom/Document.h:
* dom/ScriptExecutionContext.cpp:
(WebCore::ProcessMessagesSoonTask::ProcessMessagesSoonTask):
(WebCore::ScriptExecutionContext::processMessagePortMessagesSoon):
* dom/ScriptExecutionContext.h:
* dom/StringCallback.cpp:
(WebCore::StringCallback::scheduleCallback):
* loader/appcache/ApplicationCacheGroup.cpp:
(WebCore::CallCacheListenerTask::CallCacheListenerTask):
(WebCore::ApplicationCacheGroup::postListenerTask):
* workers/DefaultSharedWorkerRepository.cpp:
(WebCore::SharedWorkerProxy::postTaskToLoader):
(WebCore::SharedWorkerProxy::postTaskForModeToWorkerGlobalScope):
(WebCore::DefaultSharedWorkerRepository::workerScriptLoaded):
(WebCore::DefaultSharedWorkerRepository::connectToWorker):
* workers/WorkerEventQueue.cpp:
(WebCore::WorkerEventQueue::enqueueEvent):
* workers/WorkerGlobalScope.cpp:
(WebCore::WorkerGlobalScope::close):
(WebCore::WorkerGlobalScope::postTask):
(WebCore::WorkerGlobalScope::addConsoleMessage):
(WebCore::WorkerGlobalScope::addMessage):
* workers/WorkerGlobalScope.h:
* workers/WorkerLoaderProxy.h:
* workers/WorkerMessagingProxy.cpp:
(WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
(WebCore::WorkerMessagingProxy::postMessageToWorkerGlobalScope):
(WebCore::WorkerMessagingProxy::postTaskForModeToWorkerGlobalScope):
(WebCore::WorkerMessagingProxy::postTaskToLoader):
(WebCore::WorkerMessagingProxy::postExceptionToWorkerObject):
(WebCore::WorkerMessagingProxy::workerThreadCreated):
(WebCore::WorkerMessagingProxy::notifyNetworkStateChange):
(WebCore::WorkerMessagingProxy::workerGlobalScopeDestroyed):
(WebCore::WorkerMessagingProxy::workerGlobalScopeClosed):
(WebCore::WorkerMessagingProxy::postMessageToPageInspector):
(WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
(WebCore::WorkerMessagingProxy::reportPendingActivity):
* workers/WorkerMessagingProxy.h:
* workers/WorkerRunLoop.cpp:
(WebCore::WorkerRunLoop::postTask):
(WebCore::WorkerRunLoop::postTaskAndTerminate):
(WebCore::WorkerRunLoop::postTaskForMode):
(WebCore::WorkerRunLoop::Task::Task):
* workers/WorkerRunLoop.h:
* workers/WorkerThread.cpp:
(WebCore::WorkerThreadShutdownFinishTask::WorkerThreadShutdownFinishTask):
(WebCore::WorkerThreadShutdownStartTask::performTask):
(WebCore::WorkerThread::stop):
(WebCore::WorkerThread::releaseFastMallocFreeMemoryInAllThreads):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157061 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoModify WTF and JavaScriptCore makefiles for x64 build.
roger_fong@apple.com [Mon, 7 Oct 2013 22:25:03 +0000 (22:25 +0000)]
Modify WTF and JavaScriptCore makefiles for x64 build.
https://bugs.webkit.org/show_bug.cgi?id=122467.
<rdar://problem/15169174>.

Reviewed by Brent Fulgham.

* WTF.vcxproj/WTF.make:
* JavaScriptCore.vcxproj/JavaScriptCore.make:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157060 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFTL: Optimize IsString(@2<String>) -> JSConst(true) + Phantom()
commit-queue@webkit.org [Mon, 7 Oct 2013 22:08:53 +0000 (22:08 +0000)]
FTL: Optimize IsString(@2<String>) -> JSConst(true) + Phantom()
https://bugs.webkit.org/show_bug.cgi?id=122363

Patch by Nadav Rotem <nrotem@apple.com> on 2013-10-07
Reviewed by Filip Pizlo.

* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157059 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Use references in and around DragController
commit-queue@webkit.org [Mon, 7 Oct 2013 20:34:35 +0000 (20:34 +0000)]
CTTE: Use references in and around DragController
https://bugs.webkit.org/show_bug.cgi?id=122427

Patch by Sam Weinig <sam@webkit.org> on 2013-10-07
Reviewed by Andreas Kling.

Source/WebCore:

Use references to indicate non-nullness of DragController related
objects.

Source/WebKit/efl:

* WebCoreSupport/DragClientEfl.cpp:
(WebCore::DragClientEfl::willPerformDragDestinationAction):
(WebCore::DragClientEfl::willPerformDragSourceAction):
(WebCore::DragClientEfl::actionMaskForDrag):
(WebCore::DragClientEfl::startDrag):
* WebCoreSupport/DragClientEfl.h:

Source/WebKit/gtk:

* WebCoreSupport/DragClientGtk.cpp:
(WebKit::DragClient::willPerformDragDestinationAction):
(WebKit::DragClient::willPerformDragSourceAction):
(WebKit::DragClient::actionMaskForDrag):
(WebKit::DragClient::startDrag):
* WebCoreSupport/DragClientGtk.h:
* webkit/webkitwebview.cpp:
(dragExitedCallback):
(webkit_web_view_drag_motion):
(webkit_web_view_drag_data_received):
(webkit_web_view_drag_drop):

Source/WebKit/mac:

* WebCoreSupport/WebDragClient.h:
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::actionMaskForDrag):
(WebDragClient::willPerformDragDestinationAction):
(WebDragClient::willPerformDragSourceAction):
(WebDragClient::startDrag):
(WebDragClient::declareAndWriteDragImage):
* WebView/WebFrame.mm:
(-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]):
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
* WebView/WebView.mm:
(-[WebView draggingEntered:]):
(-[WebView draggingUpdated:]):
(-[WebView draggingExited:]):
(-[WebView performDragOperation:]):

Source/WebKit/win:

* WebCoreSupport/WebDragClient.cpp:
(WebDragClient::actionMaskForDrag):
(WebDragClient::willPerformDragDestinationAction):
(WebDragClient::willPerformDragSourceAction):
(WebDragClient::startDrag):
* WebCoreSupport/WebDragClient.h:

Source/WebKit2:

* UIProcess/API/gtk/WebKitWebViewBase.cpp:
(webkitWebViewBaseDragDataReceived):
(webkitWebViewBaseDragMotion):
(dragExitedCallback):
(webkitWebViewBaseDragDrop):
* UIProcess/API/mac/WKView.mm:
(-[WKView draggingEntered:]):
(-[WKView draggingUpdated:]):
(-[WKView draggingExited:]):
(-[WKView performDragOperation:]):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::dragEntered):
(WebKit::WebPageProxy::dragUpdated):
(WebKit::WebPageProxy::dragExited):
(WebKit::WebPageProxy::performDrag):
(WebKit::WebPageProxy::performDragControllerAction):
* UIProcess/WebPageProxy.h:
* WebProcess/WebCoreSupport/WebDragClient.cpp:
(WebKit::WebDragClient::willPerformDragDestinationAction):
(WebKit::WebDragClient::willPerformDragSourceAction):
(WebKit::WebDragClient::actionMaskForDrag):
(WebKit::WebDragClient::dragSourceActionMaskForPoint):
(WebKit::WebDragClient::startDrag):
* WebProcess/WebCoreSupport/WebDragClient.h:
* WebProcess/WebCoreSupport/gtk/WebDragClientGtk.cpp:
(WebKit::WebDragClient::startDrag):
* WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
(WebKit::WebDragClient::startDrag):
(WebKit::cachedImage):
(WebKit::WebDragClient::declareAndWriteDragImage):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::performDragControllerAction):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157058 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAlways force discrete mode when running layout tests
andersca@apple.com [Mon, 7 Oct 2013 20:28:03 +0000 (20:28 +0000)]
Always force discrete mode when running layout tests
https://bugs.webkit.org/show_bug.cgi?id=122465

Reviewed by Tim Horton.

This should speed up WebGL tests and hopefully prevent race conditions that may cause window server crashes from happening.

* DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
Link with IOKit.

* DumpRenderTree/mac/LayoutTestHelper.m:
(installLayoutTestColorProfile):
Check installColorProfile.

(restoreUserColorProfile):
Check installColorProfile.

(lockDownDiscreteGraphics):
New function to force discrete graphics.

(main):
Add '--install-color-profile' option.

* Scripts/webkitpy/layout_tests/controllers/manager.py:
(Manager._set_up_run):
Always start the helper, but pass self._options.pixel_tests to it.

* Scripts/webkitpy/port/mac.py:
(MacPort.start_helper):
Pass --install-color-profile' to the helper if pixel_tests is true.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157057 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAnimated images are not restarted when page visibility changes
timothy_horton@apple.com [Mon, 7 Oct 2013 20:27:16 +0000 (20:27 +0000)]
Animated images are not restarted when page visibility changes
https://bugs.webkit.org/show_bug.cgi?id=122464
<rdar://problem/14293474>

Reviewed by Simon Fraser.

Always kickstart animated images when the page visibility changes,
which can occur via window occlusion, and which is independent of in-window
state, which we were previously using to advance animation.

No new tests; attempts to make a test have resulted only in a flaky, timing-dependent test.

* page/Frame.cpp:
(WebCore::Frame::resumeActiveDOMObjectsAndAnimations):
Move this call to resumeAnimatingImages() up to Page.

* page/FrameView.cpp:
(WebCore::FrameView::setIsInWindow):
Move this call to resumeAnimatingImages() up to Page.

* WebCore.exp.in
* page/FrameView.h:
* page/Page.h:
Move resumeAnimatingImages() itself up to Page.

* page/Page.cpp:
(WebCore::Page::setIsInWindow):
Resume animated images when we move in-window.

(WebCore::Page::setVisibilityState):
Resume animated images when we become visible.
This is the one we were previously missing.

(WebCore::Page::resumeActiveDOMObjectsAndAnimations):
Resume animated images when we're told to.

(WebCore::Page::resumeAnimatingImages):
Kickstart any animated images in all frames.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157056 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[Mac] Drawing video into canvas doesn't work on the first attempt
dino@apple.com [Mon, 7 Oct 2013 20:04:46 +0000 (20:04 +0000)]
[Mac] Drawing video into canvas doesn't work on the first attempt
https://bugs.webkit.org/show_bug.cgi?id=122404

Patch by Jer Noble <jer.noble@apple.com> on 2013-10-07
Reviewed by Eric Carlson.

Source/WebCore:

Test: media/video-canvas-drawing.html

If creating and painting from an AVPlayerItemVideoOutput fails, fall back
to the (much slower) AVAssetImageGenerator path. Make sure to revert to the
AVPlayerItemVideoOutput path when that object begins to have available
images, however.

To do so, remove the "__MAC_OS_X_VERSION_MIN_REQUIRED < 1080" check around
the AVAssetImageGenerator code, and allow both the image generator and video
output to exist simultaneously.

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::hasContextRenderer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::destroyContextVideoRenderer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::destroyImageGenerator):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paintCurrentFrameInContext):
(WebCore::MediaPlayerPrivateAVFoundationObjC::videoOutputHasAvailableFrame):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):

LayoutTests:

* media/video-canvas-drawing-expected.png: Added.
* media/video-canvas-drawing-expected.txt: Added.
* media/video-canvas-drawing.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157055 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoURLMediaSource.idl and URLMediaStream.idl are wrong
jer.noble@apple.com [Mon, 7 Oct 2013 19:12:14 +0000 (19:12 +0000)]
URLMediaSource.idl and URLMediaStream.idl are wrong
https://bugs.webkit.org/show_bug.cgi?id=122301

Reviewed by Philippe Normand.

Rename URLMediaSource and URLMediaStream to DOMURLMediaSource and DOMURLMediaStream,
respectively.

Update the build files:
* CMakeLists.txt: Rename URL -> DOMURL.
* DerivedSources.make: Ditto.
* GNUmakefile.list.am: Ditto.
* WebCore.xcodeproj/project.pbxproj: Ditto.

Rename the .idl and implementation files:
* Modules/mediasource/DOMURLMediaSource.cpp: Renamed from Source/WebCore/Modules/mediasource/URLMediaSource.cpp.
(WebCore::DOMURLMediaSource::createObjectURL):
* Modules/mediasource/DOMURLMediaSource.h: Renamed from Source/WebCore/Modules/mediasource/URLMediaSource.h.
* Modules/mediasource/DOMURLMediaSource.idl: Renamed from Source/WebCore/Modules/mediasource/URLMediaSource.idl.
* Modules/mediastream/DOMURLMediaStream.cpp: Renamed from Source/WebCore/Modules/mediastream/URLMediaStream.cpp.
(WebCore::DOMURLMediaStream::createObjectURL):
* Modules/mediastream/DOMURLMediaStream.h: Renamed from Source/WebCore/Modules/mediastream/URLMediaStream.h.
* Modules/mediastream/DOMURLMediaStream.idl: Renamed from Source/WebCore/Modules/mediastream/URLMediaStream.idl.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157054 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agocss3/images/cross-fade-svg-with-opacity.html fails with colorspace mismatch on Mounta...
timothy_horton@apple.com [Mon, 7 Oct 2013 18:58:51 +0000 (18:58 +0000)]
css3/images/cross-fade-svg-with-opacity.html fails with colorspace mismatch on Mountain Lion
https://bugs.webkit.org/show_bug.cgi?id=122456

* platform/mac-wk2/TestExpectations:
Mark the test as failing for now.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157053 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoProperly count binding test failures as failures.
timothy@apple.com [Mon, 7 Oct 2013 18:52:26 +0000 (18:52 +0000)]
Properly count binding test failures as failures.

Fix the total for multiple failures in different steps too by avoiding undefined.

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

Reviewed by Alexey Proskuryakov.

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTestResults.js:
(BuildbotTestResults):
* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js:
(BuildbotTesterQueueView.prototype.update.appendBuilderQueueStatus):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157052 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[CSSRegions] Move region styling tests into fast/regions/region-styling
mihnea@adobe.com [Mon, 7 Oct 2013 18:50:42 +0000 (18:50 +0000)]
[CSSRegions] Move region styling tests into fast/regions/region-styling
https://bugs.webkit.org/show_bug.cgi?id=122451

Reviewed by Sam Weinig.

Create region-styling folder under fast/regions and move related region styling tests.

* fast/regions/region-styling/parse-incomplete-region-rule-expected.txt: Renamed from LayoutTests/fast/regions/parse-incomplete-region-rule-expected.txt.
* fast/regions/region-styling/parse-incomplete-region-rule.html: Renamed from LayoutTests/fast/regions/parse-incomplete-region-rule.html.
* fast/regions/region-styling/parsing-region-style-rule-expected.txt: Renamed from LayoutTests/fast/regions/parsing-region-style-rule-expected.txt.
* fast/regions/region-styling/parsing-region-style-rule.html: Renamed from LayoutTests/fast/regions/parsing-region-style-rule.html.
* fast/regions/region-styling/region-rule-nested-region-rule-expected.html: Renamed from LayoutTests/fast/regions/region-rule-nested-region-rule-expected.html.
* fast/regions/region-styling/region-rule-nested-region-rule.html: Renamed from LayoutTests/fast/regions/region-rule-nested-region-rule.html.
* fast/regions/region-styling/region-style-block-background-color-expected.html: Renamed from LayoutTests/fast/regions/region-style-block-background-color-expected.html.
* fast/regions/region-styling/region-style-block-background-color.html: Renamed from LayoutTests/fast/regions/region-style-block-background-color.html.
* fast/regions/region-styling/region-style-block-background-color2-expected.html: Renamed from LayoutTests/fast/regions/region-style-block-background-color2-expected.html.
* fast/regions/region-styling/region-style-block-background-color2.html: Renamed from LayoutTests/fast/regions/region-style-block-background-color2.html.
* fast/regions/region-styling/region-style-color-expected.html: Renamed from LayoutTests/fast/regions/region-style-color-expected.html.
* fast/regions/region-styling/region-style-color.html: Renamed from LayoutTests/fast/regions/region-style-color.html.
* fast/regions/region-styling/region-style-image-background-color-expected.html: Renamed from LayoutTests/fast/regions/region-style-image-background-color-expected.html.
* fast/regions/region-styling/region-style-image-background-color.html: Renamed from LayoutTests/fast/regions/region-style-image-background-color.html.
* fast/regions/region-styling/region-style-in-columns-expected.html: Renamed from LayoutTests/fast/regions/region-style-in-columns-expected.html.
* fast/regions/region-styling/region-style-in-columns.html: Renamed from LayoutTests/fast/regions/region-style-in-columns.html.
* fast/regions/region-styling/region-style-inline-background-color-expected.html: Renamed from LayoutTests/fast/regions/region-style-inline-background-color-expected.html.
* fast/regions/region-styling/region-style-inline-background-color.html: Renamed from LayoutTests/fast/regions/region-style-inline-background-color.html.
* fast/regions/region-styling/region-style-not-supported-properties-expected.html: Renamed from LayoutTests/fast/regions/region-style-not-supported-properties-expected.html.
* fast/regions/region-styling/region-style-not-supported-properties.html: Renamed from LayoutTests/fast/regions/region-style-not-supported-properties.html.
* fast/regions/region-styling/region-style-rule-position-expected.html: Renamed from LayoutTests/fast/regions/region-style-rule-position-expected.html.
* fast/regions/region-styling/region-style-rule-position.html: Renamed from LayoutTests/fast/regions/region-style-rule-position.html.
* fast/regions/region-styling/region-style-rule-specificity-expected.html: Renamed from LayoutTests/fast/regions/region-style-rule-specificity-expected.html.
* fast/regions/region-styling/region-style-rule-specificity.html: Renamed from LayoutTests/fast/regions/region-style-rule-specificity.html.
* fast/regions/region-styling/region-styling-mediaquery-expected.html: Renamed from LayoutTests/fast/regions/region-styling-mediaquery-expected.html.
* fast/regions/region-styling/region-styling-mediaquery.html: Renamed from LayoutTests/fast/regions/region-styling-mediaquery.html.
* fast/regions/region-styling/remove-leftover-anon-block-crash-expected.txt: Renamed from LayoutTests/fast/regions/remove-leftover-anon-block-crash-expected.txt.
* fast/regions/region-styling/remove-leftover-anon-block-crash.html: Renamed from LayoutTests/fast/regions/remove-leftover-anon-block-crash.html.
* fast/regions/region-styling/removed-element-style-in-region-crash-expected.txt: Renamed from LayoutTests/fast/regions/removed-element-style-in-region-crash-expected.txt.
* fast/regions/region-styling/removed-element-style-in-region-crash.html: Renamed from LayoutTests/fast/regions/removed-element-style-in-region-crash.html.
* fast/regions/region-styling/render-region-custom-style-mark-expected.html: Renamed from LayoutTests/fast/regions/render-region-custom-style-mark-expected.html.
* fast/regions/region-styling/render-region-custom-style-mark.html: Renamed from LayoutTests/fast/regions/render-region-custom-style-mark.html.
* fast/regions/region-styling/set-box-style-in-region-crash-expected.txt: Renamed from LayoutTests/fast/regions/set-box-style-in-region-crash-expected.txt.
* fast/regions/region-styling/set-box-style-in-region-crash.html: Renamed from LayoutTests/fast/regions/set-box-style-in-region-crash.html.
* fast/regions/region-styling/webkit-region-rule-expected.txt: Renamed from LayoutTests/fast/regions/webkit-region-rule-expected.txt.
* fast/regions/region-styling/webkit-region-rule.html: Renamed from LayoutTests/fast/regions/webkit-region-rule.html.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157051 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTransition stack check JITStubs to CCallHelper functions
msaboff@apple.com [Mon, 7 Oct 2013 18:20:27 +0000 (18:20 +0000)]
Transition stack check JITStubs to CCallHelper functions
https://bugs.webkit.org/show_bug.cgi?id=122289

Reviewed by Filip Pizlo.

Replaced jit stubs cti_stack_check, cti_op_call_arityCheck and cti_op_construct_arityCheck with
jit operations operationStackCheck, operationCallArityCheck & operationConstructArityCheck.
Added new callOperationWithCallFrameRollbackOnException() in baseline and DFG JITs to call
these new functions.  Added code to unwind one frame in JIT::privateCompileExceptionHandlers()
and JITCompiler::compileExceptionHandlers() for these cases that need to throw exceptions in
their caller frame when the stack is exhausted.

* assembler/MacroAssembler.h:
(JSC::MacroAssembler::andPtr): Added to handle masking a pointer with a literal.
* assembler/MacroAssemblerX86_64.h:
(JSC::MacroAssemblerX86_64::and64): Added to handle masking a pointer with a literal.
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::compileExceptionHandlers):
(JSC::DFG::JITCompiler::compileFunction):
(JSC::DFG::JITCompiler::linkFunction):
* dfg/DFGJITCompiler.h:
(JSC::DFG::JITCompiler::exceptionCheckWithCallFrameRollback):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::callOperationWithCallFrameRollbackOnException):
(JSC::DFG::SpeculativeJIT::appendCallWithExceptionCheck):
(JSC::DFG::SpeculativeJIT::appendCallWithCallFrameRollbackOnException):
(JSC::DFG::SpeculativeJIT::appendCallWithExceptionCheckSetResult):
(JSC::DFG::SpeculativeJIT::appendCallWithCallFrameRollbackOnExceptionSetResult):
* ftl/FTLLink.cpp:
(JSC::FTL::link):
* interpreter/CallFrame.h:
(JSC::ExecState::hostCallFrameFlag):
* jit/AssemblyHelpers.cpp:
(JSC::AssemblyHelpers::jitAssertIsNull):
* jit/AssemblyHelpers.h:
(JSC::AssemblyHelpers::jitAssertIsNull):
* jit/JIT.cpp:
(JSC::JIT::privateCompile):
(JSC::JIT::privateCompileExceptionHandlers):
* jit/JIT.h:
(JSC::JIT::exceptionCheckWithCallFrameRollback):
* jit/JITInlines.h:
(JSC::JIT::appendCallWithCallFrameRollbackOnException):
(JSC::JIT::callOperationWithCallFrameRollbackOnException):
* jit/JITOperations.cpp:
* jit/JITOperations.h:
* jit/JITStubs.cpp:
* jit/JITStubs.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157050 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove passIn and passOut from HashTraits
andersca@apple.com [Mon, 7 Oct 2013 18:07:54 +0000 (18:07 +0000)]
Remove passIn and passOut from HashTraits
https://bugs.webkit.org/show_bug.cgi?id=122452

Reviewed by Sam Weinig.

Change RefPtrHashMap to not use passOut (just like the regular HashMap) and get rid of the
passIn and passOut functions and related typedefs.

* wtf/HashTraits.h:
* wtf/RefPtrHashMap.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157049 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoConditional support in bindings code generator for overloaded functions
commit-queue@webkit.org [Mon, 7 Oct 2013 17:45:42 +0000 (17:45 +0000)]
Conditional support in bindings code generator for overloaded functions
https://bugs.webkit.org/show_bug.cgi?id=122443

Patch by Philippe Normand <pnormand@igalia.com> on 2013-10-07
Reviewed by Darin Adler.

* bindings/scripts/CodeGeneratorJS.pm:
(GenerateOverloadedFunction): Generate conditional for overloaded
function, if it's present in the idl.
(GenerateImplementation): Close the last overloaded function
conditional before generating the distpatch function.
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::jsTestObjConstructorFunctionOverloadedMethod1):
Rebaseline overloaded function tests.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157048 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoASSERTION FAILED: isUInt32() in jsc-layout-tests.yaml/js/script-tests/dfg-uint32...
fpizlo@apple.com [Mon, 7 Oct 2013 17:42:20 +0000 (17:42 +0000)]
ASSERTION FAILED: isUInt32() in jsc-layout-tests.yaml/js/script-tests/dfg-uint32-to-number-in-middle-of-copy-propagation.js.layout-dfg-eager-no-cjit
https://bugs.webkit.org/show_bug.cgi?id=122419

Source/JavaScriptCore:

Reviewed by Oliver Hunt.

AI was using JSValue::asUInt32() incorrectly. That method presumes that the input is
both a int32 and a uint32 (it's in the range [0, 2^31)). The UInt32ToNumber node is
instead dealing with an input that is always represented as a int32 but that has the
meaning of a uint32 - so AI should use JSValue::asInt32() and then do the cast.

* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):

LayoutTests:

Reviewed by Oliver Hunt.

* js/script-tests/dfg-uint32-to-number-in-middle-of-copy-propagation.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157047 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[sh4] Jump over maxJumpReplacementSize in revertJumpToMove.
commit-queue@webkit.org [Mon, 7 Oct 2013 16:59:34 +0000 (16:59 +0000)]
[sh4] Jump over maxJumpReplacementSize in revertJumpToMove.
https://bugs.webkit.org/show_bug.cgi?id=120007

Patch by Julien Brianceau <jbriance@cisco.com> on 2013-10-07
Reviewed by Oliver Hunt.

Jump over maxJumpReplacementSize in revertJumpToMove, even if there is no constant
value within the area. This patch fixes debug ASSERTs failures for sh4 architecture.

* assembler/SH4Assembler.h:
(JSC::SH4Assembler::revertJumpToMove):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157046 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago-webkit-cross-fade paints SVGs at full opacity during cross-fade
timothy_horton@apple.com [Mon, 7 Oct 2013 16:48:09 +0000 (16:48 +0000)]
-webkit-cross-fade paints SVGs at full opacity during cross-fade
https://bugs.webkit.org/show_bug.cgi?id=122441
<rdar://problem/13973162>

Reviewed by Simon Fraser.

Test: css3/images/cross-fade-svg-with-opacity.html

* platform/graphics/CrossfadeGeneratedImage.cpp:
(WebCore::drawCrossfadeSubimage):
(WebCore::CrossfadeGeneratedImage::drawCrossfade):
Factor the image painting out into a function.
Conditionally use a transparency layer around painting if the image
we're drawing is an SVG (SVGImage is the only Image subclass that will
not respect the context's opacity).

Add a test that ensures that -cross-fade with SVG images draws correctly.

* css3/images/cross-fade-svg-with-opacity-expected.html: Added.
* css3/images/cross-fade-svg-with-opacity.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157045 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAdd OVERRIDE and virtual where appropriate
andersca@apple.com [Mon, 7 Oct 2013 16:26:16 +0000 (16:26 +0000)]
Add OVERRIDE and virtual where appropriate
https://bugs.webkit.org/show_bug.cgi?id=122439

Reviewed by Antti Koivisto.

Source/JavaScriptCore:

* API/JSAPIWrapperObject.mm:
* API/JSCallbackObject.h:
(JSC::JSCallbackObjectData::~JSCallbackObjectData):
* API/JSManagedValue.mm:
* API/JSScriptRef.cpp:
(OpaqueJSScript::~OpaqueJSScript):
* bytecode/CodeBlock.h:
* bytecode/StructureStubClearingWatchpoint.h:
* dfg/DFGArrayifySlowPathGenerator.h:
* dfg/DFGCallArrayAllocatorSlowPathGenerator.h:
* dfg/DFGFailedFinalizer.h:
* dfg/DFGJITCode.h:
* dfg/DFGJITFinalizer.h:
* dfg/DFGSaneStringGetByValSlowPathGenerator.h:
* dfg/DFGSlowPathGenerator.h:
* dfg/DFGSpeculativeJIT64.cpp:
* heap/Heap.h:
* heap/IncrementalSweeper.h:
* heap/SuperRegion.h:
* jit/ClosureCallStubRoutine.h:
* jit/ExecutableAllocatorFixedVMPool.cpp:
* jit/GCAwareJITStubRoutine.h:
* jit/JITCode.h:
* jit/JITStubs.cpp:
* jit/JITToDFGDeferredCompilationCallback.h:
* jit/JumpReplacementWatchpoint.h:
* parser/Nodes.h:
* runtime/DataView.h:
* runtime/GCActivityCallback.h:
* runtime/GenericTypedArrayView.h:
* runtime/RegExpCache.h:
* runtime/SimpleTypedArrayController.h:
* runtime/WeakMapData.h:

Source/WebCore:

* Modules/encryptedmedia/MediaKeys.h:
* Modules/webaudio/AnalyserNode.h:
* Modules/webaudio/AudioBasicInspectorNode.h:
* Modules/webaudio/AudioBasicProcessorNode.h:
* Modules/webaudio/AudioBufferSourceNode.h:
* Modules/webaudio/AudioContext.h:
* Modules/webaudio/AudioDestinationNode.h:
* Modules/webaudio/AudioProcessingEvent.h:
* Modules/webaudio/BiquadDSPKernel.h:
* Modules/webaudio/BiquadProcessor.h:
* Modules/webaudio/ChannelMergerNode.h:
* Modules/webaudio/ChannelSplitterNode.h:
* Modules/webaudio/ConvolverNode.h:
* Modules/webaudio/DelayDSPKernel.h:
* Modules/webaudio/DelayProcessor.h:
* Modules/webaudio/DynamicsCompressorNode.h:
* Modules/webaudio/GainNode.h:
* Modules/webaudio/MediaElementAudioSourceNode.h:
* Modules/webaudio/OfflineAudioCompletionEvent.h:
* Modules/webaudio/OfflineAudioDestinationNode.h:
* Modules/webaudio/OscillatorNode.h:
* Modules/webaudio/PannerNode.h:
* Modules/webaudio/ScriptProcessorNode.h:
* Modules/webaudio/WaveShaperProcessor.h:
* accessibility/AccessibilityARIAGrid.h:
* accessibility/AccessibilityARIAGridCell.h:
* accessibility/AccessibilityARIAGridRow.h:
* accessibility/AccessibilityImageMapLink.h:
* accessibility/AccessibilityList.h:
* accessibility/AccessibilityListBox.h:
* accessibility/AccessibilityListBoxOption.h:
* accessibility/AccessibilityMediaControls.h:
* accessibility/AccessibilityMenuList.h:
* accessibility/AccessibilityMenuListOption.h:
* accessibility/AccessibilityMenuListPopup.h:
* accessibility/AccessibilityMockObject.h:
* accessibility/AccessibilityNodeObject.h:
* accessibility/AccessibilityProgressIndicator.h:
* accessibility/AccessibilityRenderObject.h:
* accessibility/AccessibilitySVGRoot.h:
* accessibility/AccessibilityScrollView.h:
* accessibility/AccessibilityScrollbar.h:
* accessibility/AccessibilitySlider.h:
* accessibility/AccessibilitySpinButton.h:
* accessibility/AccessibilityTable.h:
* accessibility/AccessibilityTableCell.h:
* accessibility/AccessibilityTableColumn.h:
* accessibility/AccessibilityTableHeaderContainer.h:
* accessibility/AccessibilityTableRow.h:
* bindings/js/JSEventListener.h:
* bindings/js/WebCoreTypedArrayController.h:
* bridge/c/c_class.h:
* bridge/c/c_instance.h:
* bridge/c/c_runtime.h:
* bridge/runtime_root.h:
* css/CSSBasicShapes.h:
* css/CSSComputedStyleDeclaration.h:
* css/CSSStyleSheet.h:
* dom/Attr.h:
* dom/BeforeTextInsertedEvent.h:
* dom/CDATASection.h:
* dom/ChildNodeList.h:
* dom/DatasetDOMStringMap.h:
* dom/Document.h:
* dom/DocumentEventQueue.h:
* dom/DocumentFragment.h:
* dom/Element.h:
* dom/ErrorEvent.h:
* dom/KeyboardEvent.h:
* dom/Node.h:
* dom/PageTransitionEvent.h:
* dom/ProgressEvent.h:
* dom/PseudoElement.h:
* dom/ScriptExecutionContext.h:
* dom/ShadowRoot.h:
* dom/StyledElement.h:
* dom/TagNodeList.h:
* dom/Text.h:
* dom/TextEvent.h:
* dom/TransitionEvent.h:
* dom/UIEvent.h:
* dom/WebKitAnimationEvent.h:
* dom/WebKitTransitionEvent.h:
* editing/ApplyBlockElementCommand.h:
* editing/ApplyStyleCommand.h:
* editing/BreakBlockquoteCommand.h:
* editing/CompositeEditCommand.h:
* editing/SpellingCorrectionCommand.h:
* fileapi/File.h:
* fileapi/FileThreadTask.h:
* history/BackForwardList.h:
* html/BaseCheckableInputType.h:
* html/HTMLAnchorElement.h:
* html/HTMLAreaElement.h:
* html/HTMLCanvasElement.h:
* html/HTMLCollection.h:
* html/HTMLElement.h:
* html/HTMLFieldSetElement.h:
* html/HTMLFormControlElement.h:
* html/HTMLFormControlElementWithState.h:
* html/HTMLFormElement.h:
* html/HTMLFrameElementBase.h:
* html/HTMLImageElement.h:
* html/HTMLImageLoader.h:
* html/HTMLInputElement.h:
* html/HTMLLabelElement.h:
* html/HTMLLegendElement.h:
* html/HTMLMediaElement.h:
* html/HTMLMeterElement.h:
* html/HTMLOptGroupElement.h:
* html/HTMLOptionElement.h:
* html/HTMLPlugInElement.h:
* html/HTMLPlugInImageElement.h:
* html/HTMLProgressElement.h:
* html/HTMLSelectElement.h:
* html/HTMLTableElement.h:
* html/HTMLTextAreaElement.h:
* html/HTMLTextFormControlElement.h:
* html/HTMLVideoElement.h:
* html/canvas/CanvasRenderingContext2D.cpp:
* html/shadow/MediaControlElementTypes.h:
* html/shadow/MediaControlElements.h:
* html/shadow/SpinButtonElement.h:
* html/shadow/TextControlInnerElements.h:
* html/track/AudioTrackList.h:
* html/track/TextTrackList.h:
* html/track/TrackListBase.h:
* inspector/InspectorValues.h:
* loader/EmptyClients.h:
* loader/ImageLoader.h:
* loader/ResourceLoader.h:
* loader/SubresourceLoader.h:
* loader/appcache/ApplicationCacheGroup.cpp:
* loader/appcache/ApplicationCacheGroup.h:
* loader/appcache/DOMApplicationCache.h:
* loader/archive/cf/LegacyWebArchive.h:
* loader/cache/CachedCSSStyleSheet.h:
* loader/cache/CachedFont.h:
* loader/cache/CachedFontClient.h:
* loader/cache/CachedImageClient.h:
* loader/cache/CachedSVGDocumentClient.h:
* loader/cache/CachedStyleSheetClient.h:
* loader/cache/CachedXSLStyleSheet.h:
* page/Chrome.h:
* page/DOMWindow.h:
* page/FrameView.h:
* page/animation/ImplicitAnimation.h:
* platform/PODIntervalTree.h:
* platform/PODRedBlackTree.h:
* platform/ScrollView.h:
* platform/Scrollbar.h:
* platform/Timer.h:
* platform/animation/TimingFunction.h:
(WebCore::LinearTimingFunction::~LinearTimingFunction):
(WebCore::CubicBezierTimingFunction::~CubicBezierTimingFunction):
(WebCore::StepsTimingFunction::~StepsTimingFunction):
* platform/audio/AudioDSPKernelProcessor.h:
* platform/audio/HRTFPanner.h:
* platform/audio/mac/AudioDestinationMac.h:
* platform/graphics/SimpleFontData.h:
* platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
* platform/graphics/filters/FilterOperation.h:
* platform/network/ResourceHandle.h:
* rendering/AutoTableLayout.h:
* rendering/ClipPathOperation.h:
* rendering/InlineFlowBox.h:
* rendering/RenderBlock.h:
* rendering/RenderBox.h:
* rendering/RenderBoxModelObject.h:
* rendering/RenderButton.h:
* rendering/RenderFieldset.h:
* rendering/RenderFileUploadControl.h:
* rendering/RenderFlexibleBox.h:
* rendering/RenderFlowThread.h:
* rendering/RenderFullScreen.h:
* rendering/RenderImage.h:
* rendering/RenderLayer.h:
* rendering/RenderLineBreak.h:
* rendering/RenderListBox.h:
* rendering/RenderListItem.h:
* rendering/RenderListMarker.h:
* rendering/RenderMenuList.h:
* rendering/RenderMeter.h:
* rendering/RenderObject.h:
* rendering/RenderReplaced.h:
* rendering/RenderSlider.h:
* rendering/RenderTable.h:
* rendering/RenderTableCell.h:
* rendering/RenderText.h:
* rendering/RenderTextControl.h:
* rendering/RenderTextControlSingleLine.h:
* rendering/RenderTextFragment.h:
* rendering/RenderView.h:
* rendering/RootInlineBox.h:
* rendering/mathml/RenderMathMLBlock.h:
* rendering/mathml/RenderMathMLFraction.h:
* rendering/mathml/RenderMathMLOperator.h:
* rendering/style/BasicShapes.h:
* rendering/svg/RenderSVGModelObject.h:
* rendering/svg/RenderSVGShape.h:
* svg/SVGAnimatedBoolean.h:
* svg/SVGAnimatedString.h:
* svg/SVGAnimatedTransformList.h:
* svg/SVGDocument.h:
* svg/SVGElement.h:
* svg/SVGElementInstance.h:
* svg/SVGFontElement.h:
* svg/SVGGElement.h:
* svg/SVGGraphicsElement.h:
* svg/SVGTransformable.h:
* svg/properties/SVGAnimatedListPropertyTearOff.h:
* svg/properties/SVGAnimatedPropertyMacros.h:
* svg/properties/SVGAnimatedTransformListPropertyTearOff.h:
* svg/properties/SVGListPropertyTearOff.h:
* svg/properties/SVGPropertyTearOff.h:
* workers/WorkerGlobalScope.h:

Source/WTF:

* wtf/Compiler.h:
* wtf/FilePrintStream.h:
* wtf/StringPrintStream.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157044 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTrap 5 (most likely int $3) in jsc-layout-tests.yaml/js/script-tests/integer-division...
fpizlo@apple.com [Mon, 7 Oct 2013 15:50:24 +0000 (15:50 +0000)]
Trap 5 (most likely int $3) in jsc-layout-tests.yaml/js/script-tests/integer-division-neg2tothe32-by-neg1.js.layout-dfg-eager-no-cjit
https://bugs.webkit.org/show_bug.cgi?id=122420

Source/JavaScriptCore:

Reviewed by Michael Saboff.

For the (-2^31/-1)|0 case, we were returning the left operand (i.e. -2^31) but we were
failing to account for the possibility that this operand has high-bit garbage and
int32Result() requires that the high bits are zero.

* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileArithDiv):

LayoutTests:

Reviewed by Michael Saboff.

* js/script-tests/integer-division-neg2tothe32-by-neg1.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157043 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[GTK] UserMediaClientGtk needs API update
philn@webkit.org [Mon, 7 Oct 2013 15:47:49 +0000 (15:47 +0000)]
[GTK] UserMediaClientGtk needs API update
https://bugs.webkit.org/show_bug.cgi?id=122324

Reviewed by Martin Robinson.

Update UserMediaClientGtk API after changes made in the parent
class in r156473.

* WebCoreSupport/UserMediaClientGtk.cpp:
(WebKit::UserMediaClientGtk::requestPermission):
(WebKit::UserMediaClientGtk::cancelRequest):
* WebCoreSupport/UserMediaClientGtk.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157042 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoURLMediaStream is unguarded by ENABLE(MEDIA_STREAM)
philn@webkit.org [Mon, 7 Oct 2013 15:32:09 +0000 (15:32 +0000)]
URLMediaStream is unguarded by ENABLE(MEDIA_STREAM)
https://bugs.webkit.org/show_bug.cgi?id=122444

Reviewed by Martin Robinson.

* Modules/mediastream/URLMediaStream.cpp: Added missing
conditional guards.
* Modules/mediastream/URLMediaStream.h: Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157041 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[GTK] webkit_dom_html_style_element_{s,g}et_scoped was removed
philn@webkit.org [Mon, 7 Oct 2013 15:29:58 +0000 (15:29 +0000)]
[GTK] webkit_dom_html_style_element_{s,g}et_scoped was removed
https://bugs.webkit.org/show_bug.cgi?id=122446

Reviewed by Martin Robinson.

Added skeleton functions warning of removed functionality for
the <style scoped> GObject DOM binding.

* bindings/gobject/WebKitDOMCustom.cpp:
* bindings/gobject/WebKitDOMCustom.h:
* bindings/gobject/WebKitDOMCustom.symbols:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157040 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUnreviewed buildfix for GCC 4.6.
ossy@webkit.org [Mon, 7 Oct 2013 15:24:19 +0000 (15:24 +0000)]
Unreviewed buildfix for GCC 4.6.

Changed override to OVERRIDE and final to FINAL.

* page/PageSerializer.cpp:
* workers/AbstractWorker.h:
* workers/SharedWorker.h:
* workers/Worker.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157039 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAX: Facebook wrapped a file upload button in an unfocusable ARIA button, which doesn...
cfleizach@apple.com [Mon, 7 Oct 2013 15:10:15 +0000 (15:10 +0000)]
AX: Facebook wrapped a file upload button in an unfocusable ARIA button, which doesn't work with AXPress.
https://bugs.webkit.org/show_bug.cgi?id=122252

Reviewed by Mario Sanchez Prada.

Source/WebCore:

When an author uses a control-type ARIA role (like button), but then hides a native control-type inside,
AXPress needs to operate on the inside node if possible.

Test: accessibility/axpress-on-aria-button.html

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::isNodeActionElement):
(WebCore::nativeActionElement):
(WebCore::AccessibilityNodeObject::actionElement):

LayoutTests:

* accessibility/axpress-on-aria-button-expected.txt: Added.
* accessibility/axpress-on-aria-button.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157038 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[GTK] Fails to build with jhbuild with newer system glib
kov@webkit.org [Mon, 7 Oct 2013 14:51:30 +0000 (14:51 +0000)]
[GTK] Fails to build with jhbuild with newer system glib
https://bugs.webkit.org/show_bug.cgi?id=122132

Patch by Gustavo Noronha Silva <gustavo.noronha@collabora.com> on 2013-10-07
Reviewed by Martin Robinson.

Newer glib includes new symbols that some system libraries which we depend on, such as pango, have
started relying on. glib is not a dependency that should change test results, and is provided in
jhbuild with the intention of supporting the other bits that do, so using a newer stable release
should not be an issue.

* gtk/jhbuild.modules:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157037 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agorun-jsc-stress-tests shouldn't print its goofy progress meter when running on the...
fpizlo@apple.com [Mon, 7 Oct 2013 14:44:31 +0000 (14:44 +0000)]
run-jsc-stress-tests shouldn't print its goofy progress meter when running on the bots
https://bugs.webkit.org/show_bug.cgi?id=122437

Reviewed by Antoine Quint.

* Scripts/run-jsc-stress-tests:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157036 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoASSERTION FAILED: bitwise_cast<WriteBarrier<Unknown>*>(callFrame) == m_registers...
fpizlo@apple.com [Mon, 7 Oct 2013 14:36:49 +0000 (14:36 +0000)]
ASSERTION FAILED: bitwise_cast<WriteBarrier<Unknown>*>(callFrame) == m_registers in jsc-layout-tests.yaml/js/script-tests/dfg-inline-arguments-capture-throw-exception.js.layout-dfg-eager-no-cjit
https://bugs.webkit.org/show_bug.cgi?id=122418

Reviewed by Oliver Hunt.

Source/JavaScriptCore:

This is pretty awesome. With stack compression, Arguments created in the DFG will point
their m_registers pointers into a different slab of stack than they would have in byte
code.

Hence OSR exit must repoint any Arguments objects' m_registers pointers. It previously
neglected to do so. This patch fixes that.

Fixing this unveiled another bug: the stack reversal broke the reification of inlined
phantom arguments.

* dfg/DFGOSRExitCompiler32_64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompilerCommon.cpp:
(JSC::DFG::reifyInlinedCallFrames):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileGetByValOnArguments):
(JSC::DFG::SpeculativeJIT::compileGetArgumentsLength):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* runtime/Arguments.h:
(JSC::Arguments::offsetOfNumArguments):
(JSC::Arguments::offsetOfRegisters):
(JSC::Arguments::offsetOfSlowArgumentData):
(JSC::Arguments::offsetOfOverrodeLength):

LayoutTests:

* js/script-tests/dfg-arguments-osr-exit-multiple-blocks-before-exit.js:
* js/script-tests/dfg-arguments-osr-exit-multiple-blocks.js:
* js/script-tests/dfg-arguments-osr-exit.js:
* js/script-tests/dfg-inline-arguments-capture-throw-exception.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157035 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agocontext-menu-suggestions-multiword-selection.html and context-menu-suggestions-subwor...
g.czajkowski@samsung.com [Mon, 7 Oct 2013 11:37:26 +0000 (11:37 +0000)]
context-menu-suggestions-multiword-selection.html and context-menu-suggestions-subword-selection.html are flaky after r156901.
https://bugs.webkit.org/show_bug.cgi?id=122414

Unreviewed gardening.

* platform/mac/TestExpectations:
Similarly to r156990, mark context-menu-suggestions-subword-selection.html as flaky.

Change-Id: I787b1d5a5a328f747799434fd7b984eec6947cd1

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157034 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUnreviewed debug build fix for ports enabling the <template> element support.
zandobersek@gmail.com [Mon, 7 Oct 2013 09:01:24 +0000 (09:01 +0000)]
Unreviewed debug build fix for ports enabling the <template> element support.

* html/HTMLTagNames.in: Generate type helpers for the <template> element as they're required
by the assertions in the Element type casts for HTMLTemplateElement.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157033 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[EFL] Build fix after r157002
ryuan.choi@samsung.com [Mon, 7 Oct 2013 07:48:33 +0000 (07:48 +0000)]
[EFL] Build fix after r157002
https://bugs.webkit.org/show_bug.cgi?id=122434

Reviewed by Sam Weinig.

* editing/markup.cpp: Changed override to OVERRIDE.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157032 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoMediaStreamTrack can't be FINAL
philn@webkit.org [Mon, 7 Oct 2013 07:29:09 +0000 (07:29 +0000)]
MediaStreamTrack can't be FINAL
https://bugs.webkit.org/show_bug.cgi?id=122322

Reviewed by Darin Adler.

Marked the MediaStreamTrack subclasses as final.

* Modules/mediastream/AudioStreamTrack.h:
* Modules/mediastream/MediaStreamTrack.h:
* Modules/mediastream/VideoStreamTrack.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157030 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoGenerate toCSSFooValue() for CSSCursorImageValue, CSSCubicBezierTimingFunctionValue...
gyuyoung.kim@samsung.com [Mon, 7 Oct 2013 06:39:42 +0000 (06:39 +0000)]
Generate toCSSFooValue() for CSSCursorImageValue, CSSCubicBezierTimingFunctionValue, CSSStepsTimingFunctionValue and CSSUnicodeRangeValue
https://bugs.webkit.org/show_bug.cgi?id=122408

Reviewed by Andreas Kling.

As a step to use toCSSFooValue, this patch generates toCSSFooValue() for CSSCursorImageValue,
CSSCubicBezierTimingFunctionValue, CSSStepsTimingFunctionValue and CSSUnicodeRangeValue.
This will help to detect bad type cast.

No new tests, no behavior changes.

* css/CSSCursorImageValue.h:
* css/CSSTimingFunctionValue.h:
* css/CSSToStyleMap.cpp:
(WebCore::CSSToStyleMap::mapAnimationTimingFunction):
* css/CSSUnicodeRangeValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/DeprecatedStyleBuilder.cpp:
(WebCore::ApplyPropertyCursor::applyValue):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::styleImage):
(WebCore::StyleResolver::styleShader):
* rendering/style/StylePendingImage.h:
(WebCore::StylePendingImage::cssCursorImageValue):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157024 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoNo? Okay, let's try that again..
akling@apple.com [Mon, 7 Oct 2013 04:48:15 +0000 (04:48 +0000)]
No? Okay, let's try that again..

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

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157023 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAttempt to fix the Windows build.
akling@apple.com [Mon, 7 Oct 2013 04:35:23 +0000 (04:35 +0000)]
Attempt to fix the Windows build.

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

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157022 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove an unnecessary test expectation, as the test was removed
timothy_horton@apple.com [Mon, 7 Oct 2013 04:34:44 +0000 (04:34 +0000)]
Remove an unnecessary test expectation, as the test was removed
along with the code it tested.

* platform/mac/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157021 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoresults.html doesn't support non-HTML reference tests or references with external...
timothy_horton@apple.com [Mon, 7 Oct 2013 04:00:01 +0000 (04:00 +0000)]
results.html doesn't support non-HTML reference tests or references with external resources
https://bugs.webkit.org/show_bug.cgi?id=122426

Reviewed by Ryosuke Niwa.

* fast/harness/results.html:
Factor splitExtension() out of stripExtension(), so we can retrieve
the extension as well as strip it.

Factor layoutTestsBasePath() out of testLink(), so we can use it for
ref test expectation files as well.

Use layoutTestsBasePath() to link to ref test expectation files, and
use the extension of the test for the expectation, instead of hardcoding
HTML reference files.

This will work on the bots because we already use the same mechanism for
the link to the test itself.

* fast/harness/resources/results-test.js:
Update the harness result viewer test results.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157020 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoBuild against the Xcode default toolchain when targeting OS X 10.8.
mitz@apple.com [Mon, 7 Oct 2013 03:46:33 +0000 (03:46 +0000)]
Build against the Xcode default toolchain when targeting OS X 10.8.

This fixes the build after r156632 in configurations that use another toolchain
by default.

* gtest/xcode/Config/General.xcconfig:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157019 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRange constructors should take a Document&.
akling@apple.com [Mon, 7 Oct 2013 03:39:12 +0000 (03:39 +0000)]
Range constructors should take a Document&.
<https://webkit.org/b/122435>

Reviewed by Sam Weinig.

Source/WebCore:

Make all Range constructors take Document& instead of a PassRefPtr.
This removes one null check at every call site.

Also use a Ref<Document> for storage in Range.

Source/WTF:

Give Ref an assignment operator.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157018 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agojsc-layout-tests.yaml/js/script-tests/dfg-arguments-osr-exit.js.layout-dfg-eager...
fpizlo@apple.com [Mon, 7 Oct 2013 03:37:54 +0000 (03:37 +0000)]
jsc-layout-tests.yaml/js/script-tests/dfg-arguments-osr-exit.js.layout-dfg-eager-no-cjit fails in release mode on the bots
https://bugs.webkit.org/show_bug.cgi?id=122436

Unreviewed, green the bots by not running the eager variants of these tests.

Will unskip when I land the fix for https://bugs.webkit.org/show_bug.cgi?id=122418.

* js/script-tests/dfg-arguments-osr-exit-multiple-blocks-before-exit.js:
* js/script-tests/dfg-arguments-osr-exit-multiple-blocks.js:
* js/script-tests/dfg-arguments-osr-exit.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157017 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUnreviewed, fix build on old Rubies.
fpizlo@apple.com [Mon, 7 Oct 2013 02:37:32 +0000 (02:37 +0000)]
Unreviewed, fix build on old Rubies.

* Scripts/run-jsc-stress-tests:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157016 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFactor text paint style computation out from InlineTextBox
antti@apple.com [Mon, 7 Oct 2013 02:17:02 +0000 (02:17 +0000)]
Factor text paint style computation out from InlineTextBox
https://bugs.webkit.org/show_bug.cgi?id=122433

Reviewed by Andreas Kling.

Move it to TextPaintStyle.h/cpp. Other parts of the code may use it in the future.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157015 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUnified test infrastructure via the jsc shell
fpizlo@apple.com [Mon, 7 Oct 2013 02:14:52 +0000 (02:14 +0000)]
Unified test infrastructure via the jsc shell
https://bugs.webkit.org/show_bug.cgi?id=120696

Source/JavaScriptCore:

Reviewed by Oliver Hunt.

Add a mozilla-tests.yaml list. This is autogenerated by create-mozilla-js-test-list.
I think it's better to leave this checked in; we may even just edit it directly in
the future. Also generating it is not cheap.

Fix some low-hanging fruit bugs that I caught by introducing more test coverage.

- We were not emitting labels for CFA-unreachable blocks, which caused link errors.
  It's possible for a CFA-unreachable block to be jumped to, if the thing that causes
  it to be unreachable is a speculation in a Branch or peephole compare.

- The register allocation assertions didn't handle peephole branches correctly. Since
  the peephole branch handling returns early from compile(), the clearBlahbittyBlah()
  method wasn't being called.

* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileCurrentBlock):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* tests/mozilla/mozilla-tests.yaml: Added.

Tools:

Reviewed by Oliver Hunt.

Make run-jsc-stress-tests smart enough to be able to handle different styles of test
output (silent or noisy) and different styles of test failure (just bad exit code,
text diff, filtering for some magical text, etc.). This allows me to get rid of the
layout-test-helper. It also allows me to switch all of the old Mozilla tests to
running in run-jsc-stress-tests.

Also removes all of the code paths that defended against not having shellwords. Just
install the shellwords gem if you want to run tests.

Also removes the non-parallel test running code. No reason for it to exist anymore.

This is a massive increase in test coverage. It uncovered bugs. I fixed two of them
as part of this patch, and left three more as new bugzillas.

* Scripts/create-mozilla-js-test-list: Added.
* Scripts/jsc-stress-test-helpers/check-mozilla-failure: Added.
* Scripts/jsc-stress-test-helpers/layout-test-helper: Removed.
* Scripts/run-javascriptcore-tests:
* Scripts/run-jsc-stress-tests:

LayoutTests:

Reviewed by Oliver Hunt.

Suppress running the no-cjit and dfg-eager variants of these tests because there are
still some hard bugs to fix; they were revealed by the increase in test coverage.

* js/script-tests/dfg-inline-arguments-capture-throw-exception.js:
* js/script-tests/dfg-uint32-to-number-in-middle-of-copy-propagation.js:
* js/script-tests/integer-division-neg2tothe32-by-neg1.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157014 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[GTK] Get rid of use of deleteAllValues in GtkDragAndDropHelper
darin@apple.com [Mon, 7 Oct 2013 00:43:55 +0000 (00:43 +0000)]
[GTK] Get rid of use of deleteAllValues in GtkDragAndDropHelper
https://bugs.webkit.org/show_bug.cgi?id=122417

Reviewed by Andreas Kling.

* platform/gtk/GtkDragAndDropHelper.cpp: Removed unneeded typedefs.
(WebCore::GtkDragAndDropHelper::~GtkDragAndDropHelper): Removed call to
deleteAllValues.
(WebCore::GtkDragAndDropHelper::handleDragEnd): Use remove directly instead
of using find then remove. I believe this fixes a storage leak.
(WebCore::GtkDragAndDropHelper::handleGetDragData): Use get instead of find.
(WebCore::GtkDragAndDropHelper::handleDragLeaveLater): Remove the explicit
delete since remove will automatically delete.
(WebCore::GtkDragAndDropHelper::handleDragLeave): Use get instead of find.
(WebCore::GtkDragAndDropHelper::handleDragMotion): Use add instead of a
combination of find and set. Also user nullptr instead of 0.
(WebCore::GtkDragAndDropHelper::handleDragDataReceived): Use get instead of find.
(WebCore::GtkDragAndDropHelper::handleDragDrop): Use get instead of find.

* platform/gtk/GtkDragAndDropHelper.h: Use nullptr instead of 0. Change value
type of m_droppingContexts to be a std::unique_ptr.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157013 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoWindows build fix attempt.
akling@apple.com [Sun, 6 Oct 2013 23:26:22 +0000 (23:26 +0000)]
Windows build fix attempt.

* page/win/DragControllerWin.cpp:
(WebCore::DragController::declareAndWriteDragImage):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157012 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoMove paint() to RenderElement
antti@apple.com [Sun, 6 Oct 2013 22:55:54 +0000 (22:55 +0000)]
Move paint() to RenderElement
https://bugs.webkit.org/show_bug.cgi?id=122371

Reviewed by Darin Adler.

RenderText does not paint itself (text is painted by line boxes). We can move paint() down
to RenderElement.

This also requires some type tightening elsewhere in the code.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157011 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoDon't try to dispatch resize events for SVG images
antti@apple.com [Sun, 6 Oct 2013 22:28:35 +0000 (22:28 +0000)]
Don't try to dispatch resize events for SVG images
https://bugs.webkit.org/show_bug.cgi?id=122410

Reviewed by Darin Adler.

Tested by avoiding assertion in svg/custom/large-image-pattern-crash.html

* page/FrameView.cpp:
(WebCore::FrameView::sendResizeEventIfNeeded):

    Bail out for SVG images. They have scripting disabled so the event wouldn't do anything anyway.
    Use of FrameView mechanisms is just an implementation detail for SVG images, they are not
    meant to act like real frames.

* rendering/svg/RenderSVGResourcePattern.cpp:
(WebCore::RenderSVGResourcePattern::createTileImage):

    Switch to Element iterator. This will take NoEventDispatchAssertion verifying the change.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157010 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoDoYouEvenBench: Make it work on Internet Explorer 11 Release Preview
rniwa@webkit.org [Sun, 6 Oct 2013 22:07:48 +0000 (22:07 +0000)]
DoYouEvenBench: Make it work on Internet Explorer 11 Release Preview
https://bugs.webkit.org/show_bug.cgi?id=122406

Reviewed by Darin Adler.

On Internet Explorer 11, $(elem).closest('li').data('id') fails to find the containig li of elem once
the first item is marked complete or deleted until we get back to the event loop in the jQuery/TodoMVC.
Worked around this limitation by overriding app.getTodo to use each item's id computed in advance.

Also use $.text instead of execCommand('InsertText') in FlightJS/MailClient since Internet Explorer
doesn't support execCommand('InsertText'). Also select the recipient to avoid exceptions.

* DoYouEvenBench/benchmark.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157009 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoElement ancestor iterator should have a first() for convenience.
akling@apple.com [Sun, 6 Oct 2013 21:29:36 +0000 (21:29 +0000)]
Element ancestor iterator should have a first() for convenience.
<https://webkit.org/b/122425>

Reviewed by Antti Koivisto.

Added an easy way to get the first element ancestor of a certain type
and put it to use in a few places.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157008 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: FrameLoader::notifier() should return a reference.
akling@apple.com [Sun, 6 Oct 2013 21:07:29 +0000 (21:07 +0000)]
CTTE: FrameLoader::notifier() should return a reference.
<https://webkit.org/b/122424>

Reviewed by Anders Carlsson.

It was just returning the address of an inline member, so we should
use a reference instead. Also made the backpointer to Frame in
ResourceLoadNotifier a reference.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157007 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAvoid layout in window.scroll{Y,X} when at topmost/leftmost position.
akling@apple.com [Sun, 6 Oct 2013 20:53:25 +0000 (20:53 +0000)]
Avoid layout in window.scroll{Y,X} when at topmost/leftmost position.
<https://webkit.org/b/122423>

Reviewed by Antti Koivisto.

Add a fast path for these properties to skip synchronous layout when
we are just going to return 0 anyway.

* page/DOMWindow.cpp:
(WebCore::DOMWindow::scrollX):
(WebCore::DOMWindow::scrollY):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157006 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoClean up ContentData
andersca@apple.com [Sun, 6 Oct 2013 20:11:38 +0000 (20:11 +0000)]
Clean up ContentData
https://bugs.webkit.org/show_bug.cgi?id=122421

Reviewed by Andreas Kling.

Replace uses of OwnPtr with std::unique_ptr and get rid of the ContentData::create overloads.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):
* rendering/style/ContentData.cpp:
(WebCore::ContentData::clone):
* rendering/style/ContentData.h:
(WebCore::ContentData::setNext):
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::appendContent):
(WebCore::RenderStyle::setContent):
* rendering/style/RenderStyle.h:
* rendering/style/StyleRareNonInheritedData.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157005 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoBe a bit shouty about final classes while we look into why the bots don't like it.
weinig@apple.com [Sun, 6 Oct 2013 19:48:07 +0000 (19:48 +0000)]
Be a bit shouty about final classes while we look into why the bots don't like it.

* dom/Comment.h:
* dom/ProcessingInstruction.h:
* editing/markup.cpp:
* page/PageSerializer.cpp:
* workers/SharedWorker.h:
* workers/Worker.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157004 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFix windows build.
weinig@apple.com [Sun, 6 Oct 2013 19:35:47 +0000 (19:35 +0000)]
Fix windows build.

* platform/win/ClipboardUtilitiesWin.cpp:
(WebCore::fragmentFromCFHTML):
(WebCore::fragmentFromHTML):
* platform/win/PasteboardWin.cpp:
(WebCore::Pasteboard::writeRangeToDataObject):
(WebCore::Pasteboard::writeSelection):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157003 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Thread references through markup.h
weinig@apple.com [Sun, 6 Oct 2013 19:18:54 +0000 (19:18 +0000)]
CTTE: Thread references through markup.h
https://bugs.webkit.org/show_bug.cgi?id=122403

Reviewed by Darin Adler and Andreas Kling.

Source/WebCore:

Highlights:
- Removed createFragmentFromMarkupWithContext(), it was unused.
- Moved createFragmentFromNodes() into its one caller (in WebKit/mac)
- Add a bunch more toFoo() overloads.

Source/WebKit/mac:

* DOM/WebDOMOperations.mm:
(-[DOMNode markupString]):
(-[DOMRange markupString]):
* WebView/WebFrame.mm:
(-[WebFrame _documentFragmentWithMarkupString:baseURLString:]):
(-[WebFrame _documentFragmentWithNodesAsParagraphs:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157002 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[WebIDL] Annotate IDL interfaces under Source/WebCore/Modules/ with the OperationsNot...
zandobersek@gmail.com [Sun, 6 Oct 2013 19:01:38 +0000 (19:01 +0000)]
[WebIDL] Annotate IDL interfaces under Source/WebCore/Modules/ with the OperationsNotDeletable attribute
https://bugs.webkit.org/show_bug.cgi?id=122281

Before changing the JSC bindings generator to enforce WebIDL operations to be configurable, all the
interfaces are being annotated with the OperationsNotDeletable attribute. The attribute currently
doesn't have any effect, but will keep the operations not configurable after the generator is modified
to preserve the original behavior. The attribute will be removed from each interface after checking
conformity with other browsers (in terms of configurability of operations of that interface) and the
WebKit's existing test suites.

This patch covers IDL interfaces under Source/WebCore/Modules/.

* Modules/battery/BatteryManager.idl:
* Modules/encryptedmedia/MediaKeySession.idl:
* Modules/encryptedmedia/MediaKeys.idl:
* Modules/gamepad/GamepadList.idl:
* Modules/geolocation/Geolocation.idl:
* Modules/indexeddb/IDBCursor.idl:
* Modules/indexeddb/IDBDatabase.idl:
* Modules/indexeddb/IDBFactory.idl:
* Modules/indexeddb/IDBIndex.idl:
* Modules/indexeddb/IDBKeyRange.idl:
* Modules/indexeddb/IDBObjectStore.idl:
* Modules/indexeddb/IDBTransaction.idl:
* Modules/indexeddb/IDBVersionChangeEvent.idl:
* Modules/mediacontrols/MediaControlsHost.idl:
* Modules/mediasource/MediaSource.idl:
* Modules/mediasource/SourceBuffer.idl:
* Modules/mediasource/SourceBufferList.idl:
* Modules/mediasource/WebKitMediaSource.idl:
* Modules/mediasource/WebKitSourceBuffer.idl:
* Modules/mediasource/WebKitSourceBufferList.idl:
* Modules/mediastream/MediaStream.idl:
* Modules/mediastream/MediaStreamTrack.idl:
* Modules/mediastream/RTCDTMFSender.idl:
* Modules/mediastream/RTCDataChannel.idl:
* Modules/mediastream/RTCPeerConnection.idl:
* Modules/mediastream/RTCStatsReport.idl:
* Modules/mediastream/RTCStatsResponse.idl:
* Modules/networkinfo/NetworkInfoConnection.idl:
* Modules/notifications/Notification.idl:
* Modules/notifications/NotificationCenter.idl:
* Modules/proximity/DeviceProximityEvent.idl:
* Modules/quota/StorageInfo.idl:
* Modules/quota/StorageQuota.idl:
* Modules/speech/SpeechGrammarList.idl:
* Modules/speech/SpeechRecognition.idl:
* Modules/speech/SpeechRecognitionResult.idl:
* Modules/speech/SpeechRecognitionResultList.idl:
* Modules/speech/SpeechSynthesis.idl:
* Modules/webaudio/AnalyserNode.idl:
* Modules/webaudio/AudioBuffer.idl:
* Modules/webaudio/AudioBufferSourceNode.idl:
* Modules/webaudio/AudioContext.idl:
* Modules/webaudio/AudioListener.idl:
* Modules/webaudio/AudioNode.idl:
* Modules/webaudio/AudioParam.idl:
* Modules/webaudio/BiquadFilterNode.idl:
* Modules/webaudio/OscillatorNode.idl:
* Modules/webaudio/PannerNode.idl:
* Modules/webdatabase/Database.idl:
* Modules/webdatabase/DatabaseSync.idl:
* Modules/webdatabase/SQLResultSetRowList.idl:
* Modules/webdatabase/SQLTransaction.idl:
* Modules/webdatabase/SQLTransactionSync.idl:
* Modules/websockets/WebSocket.idl:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157001 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTighten AbstractWorker and subclasses a bit.
akling@apple.com [Sun, 6 Oct 2013 18:47:32 +0000 (18:47 +0000)]
Tighten AbstractWorker and subclasses a bit.
<https://webkit.org/b/122402>

Reviewed by Darin Adler.

- Make the Worker and SharedWorker classes final.
- Have constructors take ScriptExecutionContext by reference.
- Remove unnecessary AbstractWorker::contextDestroyed() override.
- Make eventTargetInterface() inline.

Inlining eventTargetInterface() is quite neat - since we only ever
call this on tightly typed pointers from generated code, combining
final and inline turns the virtual call into a compile-time constant.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@157000 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[WebIDL] Annotate IDL interfaces under Source/WebCore/html/ with the OperationsNotDel...
zandobersek@gmail.com [Sun, 6 Oct 2013 18:18:48 +0000 (18:18 +0000)]
[WebIDL] Annotate IDL interfaces under Source/WebCore/html/ with the OperationsNotDeletable attribute
https://bugs.webkit.org/show_bug.cgi?id=122280

Reviewed by Darin Adler.

Before changing the JSC bindings generator to enforce WebIDL operations to be configurable, all the
interfaces are being annotated with the OperationsNotDeletable attribute. The attribute currently
doesn't have any effect, but will keep the operations not configurable after the generator is modified
to preserve the original behavior. The attribute will be removed from each interface after checking
conformity with other browsers (in terms of configurability of operations of that interface) and the
WebKit's existing test suites.

This patch covers IDL interfaces under Source/WebCore/html/.

* html/DOMFormData.idl:
* html/DOMSettableTokenList.idl:
* html/DOMTokenList.idl:
* html/DOMURL.idl:
* html/HTMLAllCollection.idl:
* html/HTMLAnchorElement.idl:
* html/HTMLButtonElement.idl:
* html/HTMLCanvasElement.idl:
* html/HTMLCollection.idl:
* html/HTMLDocument.idl:
* html/HTMLElement.idl:
* html/HTMLEmbedElement.idl:
* html/HTMLFieldSetElement.idl:
* html/HTMLFormControlsCollection.idl:
* html/HTMLFormElement.idl:
* html/HTMLFrameElement.idl:
* html/HTMLIFrameElement.idl:
* html/HTMLInputElement.idl:
* html/HTMLKeygenElement.idl:
* html/HTMLMarqueeElement.idl:
* html/HTMLMediaElement.idl:
* html/HTMLObjectElement.idl:
* html/HTMLOptionsCollection.idl:
* html/HTMLOutputElement.idl:
* html/HTMLSelectElement.idl:
* html/HTMLTableElement.idl:
* html/HTMLTableRowElement.idl:
* html/HTMLTableSectionElement.idl:
* html/HTMLTextAreaElement.idl:
* html/HTMLVideoElement.idl:
* html/MediaController.idl:
* html/RadioNodeList.idl:
* html/TimeRanges.idl:
* html/canvas/CanvasGradient.idl:
* html/canvas/CanvasRenderingContext2D.idl:
* html/canvas/DOMPath.idl:
* html/canvas/EXTDrawBuffers.idl:
* html/canvas/OESVertexArrayObject.idl:
* html/canvas/WebGLDebugShaders.idl:
* html/canvas/WebGLLoseContext.idl:
* html/canvas/WebGLRenderingContext.idl:
* html/track/AudioTrackList.idl:
* html/track/TextTrack.idl:
* html/track/TextTrackCue.idl:
* html/track/TextTrackCueList.idl:
* html/track/TextTrackList.idl:
* html/track/TextTrackRegionList.idl:
* html/track/VideoTrackList.idl:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156999 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoPass VM instead of ExecState to StringObject constructor.
akling@apple.com [Sun, 6 Oct 2013 18:16:48 +0000 (18:16 +0000)]
Pass VM instead of ExecState to StringObject constructor.
<https://webkit.org/b/122395>

Reviewed by Sam Weinig.

StringObject() only uses the ExecState to find the VM.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156998 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[WebIIDL] Annotate IDL interfaces under Source/WebCore/svg/ with the OperationsNotDel...
zandobersek@gmail.com [Sun, 6 Oct 2013 18:10:48 +0000 (18:10 +0000)]
[WebIIDL] Annotate IDL interfaces under Source/WebCore/svg/ with the OperationsNotDeletable attribute
https://bugs.webkit.org/show_bug.cgi?id=122279

Reviewed by Darin Adler.

Before changing the JSC bindings generator to enforce WebIDL operations to be configurable, all the
interfaces are being annotated with the OperationsNotDeletable attribute. The attribute currently
doesn't have any effect, but will keep the operations not configurable after the generator is modified
to preserve the original behavior. The attribute will be removed from each interface after checking
conformity with other browsers (in terms of configurability of operations of that interface) and the
WebKit's existing test suites.

This patch covers IDL interfaces under Source/WebCore/svg/.

* svg/SVGAngle.idl:
* svg/SVGAnimationElement.idl:
* svg/SVGColor.idl:
* svg/SVGCursorElement.idl:
* svg/SVGDocument.idl:
* svg/SVGElement.idl:
* svg/SVGElementInstanceList.idl:
* svg/SVGException.idl:
* svg/SVGFEDropShadowElement.idl:
* svg/SVGFEGaussianBlurElement.idl:
* svg/SVGFEMorphologyElement.idl:
* svg/SVGFilterElement.idl:
* svg/SVGGraphicsElement.idl:
* svg/SVGLength.idl:
* svg/SVGLengthList.idl:
* svg/SVGMarkerElement.idl:
* svg/SVGMaskElement.idl:
* svg/SVGMatrix.idl:
* svg/SVGNumberList.idl:
* svg/SVGPaint.idl:
* svg/SVGPathElement.idl:
* svg/SVGPathSegList.idl:
* svg/SVGPatternElement.idl:
* svg/SVGPoint.idl:
* svg/SVGPointList.idl:
* svg/SVGSVGElement.idl:
* svg/SVGStringList.idl:
* svg/SVGTests.idl:
* svg/SVGTextContentElement.idl:
* svg/SVGTransform.idl:
* svg/SVGTransformList.idl:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156997 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[WebIDL] Annotate IDL interfaces under Source/WebCore/page/ with the OperationsNotDel...
zandobersek@gmail.com [Sun, 6 Oct 2013 18:07:25 +0000 (18:07 +0000)]
[WebIDL] Annotate IDL interfaces under Source/WebCore/page/ with the OperationsNotDeletable attribute
https://bugs.webkit.org/show_bug.cgi?id=122278

Before changing the JSC bindings generator to enforce WebIDL operations to be configurable, all the
interfaces are being annotated with the OperationsNotDeletable attribute. The attribute currently
doesn't have any effect, but will keep the operations not configurable after the generator is modified
to preserve the original behavior. The attribute will be removed from each interface after checking
conformity with other browsers (in terms of configurability of operations of that interface) and the
WebKit's existing test suites.

This patch covers IDL interfaces under Source/WebCore/page/.

* page/Console.idl:
* page/Crypto.idl:
* page/DOMSecurityPolicy.idl:
* page/DOMSelection.idl:
* page/DOMWindow.idl:
* page/EventSource.idl:
* page/History.idl:
* page/Location.idl:
* page/Navigator.idl:
* page/Performance.idl:
* page/PerformanceEntryList.idl:
* page/SpeechInputResultList.idl:
* page/WindowBase64.idl:
* page/WindowTimers.idl:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156996 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[CSSRegions] Rename parsing tests to match current css properties
mihnea@adobe.com [Sun, 6 Oct 2013 17:58:54 +0000 (17:58 +0000)]
[CSSRegions] Rename parsing tests to match current css properties
https://bugs.webkit.org/show_bug.cgi?id=122413

Reviewed by Sam Weinig.

Simple renaming of files, inline with the current stable version of properties.

* fast/regions/script-tests/webkit-flow-from-parsing.js: Renamed from LayoutTests/fast/regions/script-tests/content-webkit-from-flow-parsing.js.
* fast/regions/script-tests/webkit-flow-into-parsing.js: Renamed from LayoutTests/fast/regions/script-tests/webkit-flow-parsing.js.
* fast/regions/webkit-flow-from-parsing-expected.txt: Renamed from LayoutTests/fast/regions/content-webkit-from-flow-parsing-expected.txt.
* fast/regions/webkit-flow-from-parsing.html: Renamed from LayoutTests/fast/regions/content-webkit-from-flow-parsing.html.
* fast/regions/webkit-flow-into-parsing-expected.txt: Renamed from LayoutTests/fast/regions/webkit-flow-parsing-expected.txt.
* fast/regions/webkit-flow-into-parsing.html: Renamed from LayoutTests/fast/regions/webkit-flow-parsing.html.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156995 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago* rendering/RenderButton.cpp:
darin@apple.com [Sun, 6 Oct 2013 17:52:59 +0000 (17:52 +0000)]
* rendering/RenderButton.cpp:
(WebCore::RenderButton::setupInnerStyle): Added a comment possibly relevant
to current failures seen on Windows bot.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156994 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUnreviewed, rolling out r156988.
commit-queue@webkit.org [Sun, 6 Oct 2013 17:44:48 +0000 (17:44 +0000)]
Unreviewed, rolling out r156988.
http://trac.webkit.org/changeset/156988
https://bugs.webkit.org/show_bug.cgi?id=122415

Broke debug build (Requested by ap on #webkit).

* css/CSSCursorImageValue.h:
* css/CSSTimingFunctionValue.h:
* css/CSSToStyleMap.cpp:
(WebCore::CSSToStyleMap::mapAnimationTimingFunction):
* css/CSSUnicodeRangeValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/DeprecatedStyleBuilder.cpp:
(WebCore::ApplyPropertyCursor::applyValue):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::styleImage):
(WebCore::StyleResolver::styleShader):
* rendering/style/StylePendingImage.h:
(WebCore::StylePendingImage::cssCursorImageValue):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156993 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTry to fix the Windows build.
darin@apple.com [Sun, 6 Oct 2013 17:41:48 +0000 (17:41 +0000)]
Try to fix the Windows build.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:
Removed export of non-existent Node::treeScope function returning
a TreeScope*. Probably will have to add an export to fix the next failure.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156992 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAdd *CSS* prefix to ShadowValue to generate toCSSShadowValue
gyuyoung.kim@samsung.com [Sun, 6 Oct 2013 17:37:59 +0000 (17:37 +0000)]
Add *CSS* prefix to ShadowValue to generate toCSSShadowValue
https://bugs.webkit.org/show_bug.cgi?id=122409

Reviewed by Darin Adler.

To generate toCSSShadowValue(), we need to add *CSS* prefix to ShadowValue.
It is also to be sync with a naming rule of CSS child value.

No new tests, no behavior changes.

* CMakeLists.txt:
* GNUmakefile.list.am:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::valueForShadow):
* css/CSSParser.cpp:
(WebCore::ShadowParseContext::commitValue):
* css/CSSShadowValue.cpp: Renamed from Source/WebCore/css/ShadowValue.cpp.
(WebCore::CSSShadowValue::CSSShadowValue):
(WebCore::CSSShadowValue::customCSSText):
(WebCore::CSSShadowValue::equals):
* css/CSSShadowValue.h: Renamed from Source/WebCore/css/ShadowValue.h.
(WebCore::CSSShadowValue::create):
* css/CSSValue.cpp:
(WebCore::CSSValue::equals):
(WebCore::CSSValue::cssText):
(WebCore::CSSValue::destroy):
* css/SVGCSSStyleSelector.cpp:
(WebCore::StyleResolver::applySVGProperty):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):
(WebCore::StyleResolver::createFilterOperations):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156991 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoLayout Test editing/spelling/context-menu-suggestions-multiword-selection.html is...
ap@apple.com [Sun, 6 Oct 2013 17:29:09 +0000 (17:29 +0000)]
Layout Test editing/spelling/context-menu-suggestions-multiword-selection.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=122414

* platform/mac/TestExpectations: Marked as such.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156990 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove unneeded ScriptGCEvent class
darin@apple.com [Sun, 6 Oct 2013 17:15:26 +0000 (17:15 +0000)]
Remove unneeded ScriptGCEvent class
https://bugs.webkit.org/show_bug.cgi?id=122390

Reviewed by Anders Carlsson.

Source/ThirdParty:

* gtest/xcode/gtest.xcodeproj/project.pbxproj: Let Xcode update this file.
Not really part of this bug fix, but good to land anyway.

Source/WebCore:

* GNUmakefile.list.am: Removed ScriptGCEvent files.
* Target.pri: Ditto.
* UseJSC.cmake: Ditto.
* WebCore.exp.in: Ditto.
* WebCore.vcxproj/WebCore.vcxproj: Ditto.
* WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
* WebCore.xcodeproj/project.pbxproj: Ditto.
* bindings/js/JSBindingsAllInOne.cpp: Ditto.
* bindings/js/ScriptGCEvent.cpp: Removed.
* bindings/js/ScriptGCEvent.h: Removed.

* inspector/InspectorMemoryAgent.cpp: Removed include.

* inspector/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::start): Removed GC event listening.
Some day we might add it back, but for now it is dead code.
(WebCore::InspectorTimelineAgent::stop): Ditto.
(WebCore::usedHeapSize): Renamed from getUsedHeapSize and put the
implementation here instead of indirecting through ScriptGCEvent.
(WebCore::InspectorTimelineAgent::setDOMCounters): Updated for above changes.
(WebCore::InspectorTimelineAgent::didCompleteCurrentRecord): Ditto.
(WebCore::InspectorTimelineAgent::pushCurrentRecord): Ditto.

* inspector/InspectorTimelineAgent.h: Removed include.

* inspector/ScriptGCEventListener.h: Removed.

* testing/MemoryInfo.h: Updated to get heap capacity and size directly
instead of going through ScriptGCEvent.

Source/WebKit:

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:
Replaced symbol from ScriptGCEvent with symbol from JSDOMWindowBase.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156989 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoGenerate toCSSFooValue() for CSSCursorImageValue, CSSCubicBezierTimingFunctionValue...
gyuyoung.kim@samsung.com [Sun, 6 Oct 2013 17:03:35 +0000 (17:03 +0000)]
Generate toCSSFooValue() for CSSCursorImageValue, CSSCubicBezierTimingFunctionValue, CSSStepsTimingFunctionValue and CSSUnicodeRangeValue
https://bugs.webkit.org/show_bug.cgi?id=122408

Reviewed by Darin Adler.

As a step to use toCSSFooValue, this patch generates toCSSFooValue() for CSSCursorImageValue,
CSSCubicBezierTimingFunctionValue, CSSStepsTimingFunctionValue and CSSUnicodeRangeValue.
This will help to detect bad type cast.

No new tests, no behavior changes.

* css/CSSCursorImageValue.h:
* css/CSSTimingFunctionValue.h:
* css/CSSToStyleMap.cpp:
(WebCore::CSSToStyleMap::mapAnimationTimingFunction):
* css/CSSUnicodeRangeValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/DeprecatedStyleBuilder.cpp:
(WebCore::ApplyPropertyCursor::applyValue):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::styleImage):
(WebCore::StyleResolver::styleShader):
* rendering/style/StylePendingImage.h:
(WebCore::StylePendingImage::cssCursorImageValue):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156988 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Teach CompositeEditCommand that link Nodes are always Elements.
akling@apple.com [Sun, 6 Oct 2013 08:37:29 +0000 (08:37 +0000)]
CTTE: Teach CompositeEditCommand that link Nodes are always Elements.
<https://webkit.org/b/122400>

Reviewed by Sam Weinig.

Make pushAnchorElementDown() take an Element& instead of a Node* and
tweak the surrounding code a tiny bit.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156987 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Node::enclosingLinkEventParentOrSelf() should return an Element.
akling@apple.com [Sun, 6 Oct 2013 08:37:02 +0000 (08:37 +0000)]
CTTE: Node::enclosingLinkEventParentOrSelf() should return an Element.
<https://webkit.org/b/122401>

Reviewed by Sam Weinig.

Only Elements are ever linked, so make enclosingLinkEventParentOrSelf()
return an Element* instead of a Node*. The only call site was already
doing toElement() on the return value without checking, so this makes
things look a bit nicer.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156986 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAdd *CSS* prefix to FontFeatureValue to generate toCSSFontFeatureValue(), and use it
gyuyoung.kim@samsung.com [Sun, 6 Oct 2013 07:33:19 +0000 (07:33 +0000)]
Add *CSS* prefix to FontFeatureValue to generate toCSSFontFeatureValue(), and use it
https://bugs.webkit.org/show_bug.cgi?id=122204

Reviewed by Darin Adler.

*CSS* prefix needs to be added to FontFeatureValue class in order to generate toCSSFontFeatureValue().
static_cast<FontFeatureValue*> is changed with toCSSFontFeatureValue() by using this change.

No new tests, no behavior changes.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::propertyValue):
* css/CSSFontFeatureValue.cpp: Renamed from Source/WebCore/css/FontFeatureValue.cpp.
(WebCore::CSSFontFeatureValue::CSSFontFeatureValue):
(WebCore::CSSFontFeatureValue::customCSSText):
(WebCore::CSSFontFeatureValue::equals):
* css/CSSFontFeatureValue.h: Renamed from Source/WebCore/css/FontFeatureValue.h.
(WebCore::CSSFontFeatureValue::create):
(WebCore::CSSFontFeatureValue::tag):
(WebCore::CSSFontFeatureValue::value):
* css/CSSParser.cpp:
(WebCore::CSSParser::parseFontFeatureTag):
* css/CSSValue.cpp:
(WebCore::CSSValue::equals):
(WebCore::CSSValue::cssText):
(WebCore::CSSValue::destroy):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156985 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCompress DFG stack layout
fpizlo@apple.com [Sun, 6 Oct 2013 04:22:43 +0000 (04:22 +0000)]
Compress DFG stack layout
https://bugs.webkit.org/show_bug.cgi?id=122024

Reviewed by Oliver Hunt.

The DFG needs to be able to store things at a known offset from frame pointer so that
the runtime can read those things. Prior to this patch, the DFG would use the exact
offsets that the bytecode asked for, even in the case of inlining, where it would use
the callsite stack offset to shift all of the inlined function's variables over just as
they would have been if a bytecode interpreter had really made the call.

But this won't work once WebKit-LLVM integration is complete. LLVM has no notion of
storing things at a fixed offset from the frame pointer. We could try to hack LLVM to do
that, but it would seriously complicate LLVM's stack layout. But what we might be able
to do is have LLVM tell us (via an addressof intrinsic and a side-channel) where some
alloca landed relative to the frame pointer. Hence if the DFG can put all of its flushed
variables in a contiguous range that can be expressed to LLVM as a struct that we
alloca, then all of this can still work just fine.

Previously the flushed variables didn't fit in a contiguous range, but this patch makes
them contiguous by allowing the stack layout to be compressed.

What this really means is that there is now a distinction between where the DFG saw a
variable stored in bytecode and where it will actually store it in the resulting machine
code. Henceforth when the DFG says "local" or "virtual register" it means the variable
according to bytecode (with the stack offsetting for inlined code as before), but when
it says "machine local" or "machine virtual register" it means the actual place where it
will store things in the resulting machine code. All of the OSR exit, inlined arguments,
captured variables, and various stack unwinding machine now knows about all of this.

Note that the DFG's abstract interpretation still uses bytecode variables rather than
machine variables. Same for CSE and abstract heaps. This makes sense since it means that
we don't have to decide on machine variable allocation just to do those optimizations.

The decision of what a local's machine location becomes is deferred to very late in
compilation. We only need to assign machine locations to variables that must be stored
to the stack. It's now mandatory to run some kind of "stack layout phase" that makes the
decision and updates all data structures.

So far the way that this is being used is just to compress the DFG stack layout, which
is something that we should have done anyway, a long time ago. And the compression isn't
even that good - the current StackLayoutPhase just identifies local indices that are
unused in machine code and slides all other variables towards zero. This doesn't achieve
particularly good compression but it is better than nothing. Note that this phase makes
it seem like the bytecode-machine mapping is based on bytecode local indices; for
example if bytecode local 4 is mapped to machine local 3 then it always will be. That's
true for the current StackLayoutPhase but it _will not_ be true for all possible stack
layout phases and it would be incorrect to assume that it should be true. This is why
the current data structures have each VariableAccessData hold its own copy of the
machine virtual register, and also have each InlineCallFrame report their own machine
virtual registers for the various things. The DFG backend is likely to always use the
dumb StackLayoutPhase since it is very cheap to run, but the FTL backend is likely to
eventually get a better one, where we do some kind of constraint-based coloring: we
institute constraints where some VariableAccessData's must have the same indices as some
other ones, and also must be right next to some other ones; then we process all
VariableAccessData's and attempt to assign them machine locals while preserving those
constraints. This could lead to two VariableAccessDatas for the same bytecode local
ending up with different machine locals.

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.xcodeproj/project.pbxproj:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::isCaptured):
(JSC::CodeBlock::framePointerOffsetToGetActivationRegisters):
(JSC::CodeBlock::machineSlowArguments):
* bytecode/CodeBlock.h:
(JSC::CodeBlock::hasSlowArguments):
* bytecode/CodeOrigin.cpp:
(JSC::CodeOrigin::dump):
(JSC::InlineCallFrame::calleeForCallFrame):
(JSC::InlineCallFrame::dumpInContext):
* bytecode/CodeOrigin.h:
(JSC::InlineCallFrame::InlineCallFrame):
(JSC::InlineCallFrame::calleeConstant):
* bytecode/Operands.h:
(JSC::Operands::indexForOperand):
* dfg/DFGBasicBlock.cpp:
(JSC::DFG::BasicBlock::SSAData::SSAData):
* dfg/DFGBasicBlock.h:
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::ByteCodeParser):
(JSC::DFG::ByteCodeParser::get):
(JSC::DFG::ByteCodeParser::getLocal):
(JSC::DFG::ByteCodeParser::flushDirect):
(JSC::DFG::ByteCodeParser::flush):
(JSC::DFG::ByteCodeParser::handleInlining):
(JSC::DFG::ByteCodeParser::InlineStackEntry::InlineStackEntry):
(JSC::DFG::ByteCodeParser::parse):
* dfg/DFGCommon.h:
* dfg/DFGCommonData.h:
(JSC::DFG::CommonData::CommonData):
* dfg/DFGDesiredWriteBarriers.cpp:
(JSC::DFG::DesiredWriteBarrier::trigger):
* dfg/DFGDesiredWriteBarriers.h:
* dfg/DFGFlushLivenessAnalysisPhase.cpp:
(JSC::DFG::FlushLivenessAnalysisPhase::run):
(JSC::DFG::FlushLivenessAnalysisPhase::process):
(JSC::DFG::FlushLivenessAnalysisPhase::reportError):
* dfg/DFGFlushedAt.cpp: Added.
(JSC::DFG::FlushedAt::dump):
(JSC::DFG::FlushedAt::dumpInContext):
* dfg/DFGFlushedAt.h: Added.
(JSC::DFG::FlushedAt::FlushedAt):
(JSC::DFG::FlushedAt::operator!):
(JSC::DFG::FlushedAt::format):
(JSC::DFG::FlushedAt::virtualRegister):
(JSC::DFG::FlushedAt::operator==):
(JSC::DFG::FlushedAt::operator!=):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::Graph):
(JSC::DFG::Graph::dump):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::bytecodeRegisterForArgument):
(JSC::DFG::Graph::argumentsRegisterFor):
(JSC::DFG::Graph::machineArgumentsRegisterFor):
(JSC::DFG::Graph::uncheckedArgumentsRegisterFor):
(JSC::DFG::Graph::activationRegister):
(JSC::DFG::Graph::uncheckedActivationRegister):
(JSC::DFG::Graph::machineActivationRegister):
(JSC::DFG::Graph::uncheckedMachineActivationRegister):
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::link):
* dfg/DFGJITCompiler.h:
(JSC::DFG::JITCompiler::noticeOSREntry):
* dfg/DFGNode.h:
(JSC::DFG::Node::convertToGetLocalUnlinked):
(JSC::DFG::Node::convertToGetLocal):
(JSC::DFG::Node::machineLocal):
(JSC::DFG::Node::hasUnlinkedMachineLocal):
(JSC::DFG::Node::setUnlinkedMachineLocal):
(JSC::DFG::Node::unlinkedMachineLocal):
(JSC::DFG::Node::hasInlineStartData):
(JSC::DFG::Node::inlineStartData):
* dfg/DFGNodeFlags.cpp:
(JSC::DFG::dumpNodeFlags):
* dfg/DFGOSREntry.cpp:
(JSC::DFG::prepareOSREntry):
* dfg/DFGOSREntry.h:
(JSC::DFG::OSREntryReshuffling::OSREntryReshuffling):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompilerCommon.cpp:
(JSC::DFG::reifyInlinedCallFrames):
* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
* dfg/DFGPlan.cpp:
(JSC::DFG::Plan::compileInThreadImpl):
* dfg/DFGScoreBoard.h:
(JSC::DFG::ScoreBoard::ScoreBoard):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileInlineStart):
(JSC::DFG::SpeculativeJIT::compileCurrentBlock):
(JSC::DFG::SpeculativeJIT::createOSREntries):
(JSC::DFG::SpeculativeJIT::compileGetByValOnArguments):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::calleeFrameOffset):
(JSC::DFG::SpeculativeJIT::callFrameSlot):
(JSC::DFG::SpeculativeJIT::argumentSlot):
(JSC::DFG::SpeculativeJIT::callFrameTagSlot):
(JSC::DFG::SpeculativeJIT::callFramePayloadSlot):
(JSC::DFG::SpeculativeJIT::argumentTagSlot):
(JSC::DFG::SpeculativeJIT::argumentPayloadSlot):
(JSC::DFG::SpeculativeJIT::framePointerOffsetToGetActivationRegisters):
(JSC::DFG::SpeculativeJIT::callOperation):
(JSC::DFG::SpeculativeJIT::recordSetLocal):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::emitCall):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::emitCall):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGStackLayoutPhase.cpp: Added.
(JSC::DFG::StackLayoutPhase::StackLayoutPhase):
(JSC::DFG::StackLayoutPhase::run):
(JSC::DFG::performStackLayout):
* dfg/DFGStackLayoutPhase.h: Added.
* dfg/DFGValidate.cpp:
(JSC::DFG::Validate::validate):
* dfg/DFGVariableAccessData.h:
(JSC::DFG::VariableAccessData::machineLocal):
(JSC::DFG::VariableAccessData::flushedAt):
* dfg/DFGVirtualRegisterAllocationPhase.cpp:
(JSC::DFG::VirtualRegisterAllocationPhase::run):
* ftl/FTLExitValue.h:
(JSC::FTL::ExitValue::inJSStack):
(JSC::FTL::ExitValue::inJSStackAsInt32):
(JSC::FTL::ExitValue::inJSStackAsInt52):
(JSC::FTL::ExitValue::inJSStackAsDouble):
(JSC::FTL::ExitValue::virtualRegister):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileGetArgument):
(JSC::FTL::LowerDFGToLLVM::compileGetLocal):
(JSC::FTL::LowerDFGToLLVM::compileSetLocal):
(JSC::FTL::LowerDFGToLLVM::initializeOSRExitStateForBlock):
(JSC::FTL::LowerDFGToLLVM::emitOSRExitCall):
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileStub):
* ftl/FTLValueSource.cpp:
(JSC::FTL::ValueSource::dump):
* ftl/FTLValueSource.h:
(JSC::FTL::ValueSource::ValueSource):
(JSC::FTL::ValueSource::kind):
(JSC::FTL::ValueSource::operator!):
(JSC::FTL::ValueSource::node):
(JSC::FTL::ValueSource::virtualRegister):
* interpreter/Interpreter.cpp:
(JSC::unwindCallFrame):
* interpreter/StackVisitor.cpp:
(JSC::StackVisitor::readInlinedFrame):
(JSC::StackVisitor::Frame::createArguments):
(JSC::StackVisitor::Frame::existingArguments):
* interpreter/StackVisitor.h:
* jit/AssemblyHelpers.h:
(JSC::AssemblyHelpers::addressFor):
(JSC::AssemblyHelpers::tagFor):
(JSC::AssemblyHelpers::payloadFor):
(JSC::AssemblyHelpers::offsetOfArgumentsIncludingThis):
* runtime/Arguments.cpp:
(JSC::Arguments::tearOff):
* runtime/Arguments.h:
(JSC::Arguments::allocateSlowArguments):
(JSC::Arguments::tryDeleteArgument):
(JSC::Arguments::isDeletedArgument):
(JSC::Arguments::isArgument):
(JSC::Arguments::argument):
(JSC::Arguments::finishCreation):
* runtime/JSActivation.h:
(JSC::JSActivation::create):
(JSC::JSActivation::JSActivation):
* runtime/JSFunction.cpp:
(JSC::RetrieveArgumentsFunctor::operator()):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156984 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agorun-jsc-stress-tests should be less verbose
fpizlo@apple.com [Sun, 6 Oct 2013 03:16:38 +0000 (03:16 +0000)]
run-jsc-stress-tests should be less verbose
https://bugs.webkit.org/show_bug.cgi?id=122397

Reviewed by Sam Weinig.

It now just prints something like:

 965/1831 ....

Where the first number is the number of tests that completed, the second number is the
number of tests total, and the dots are the number of tests running right now - which is
useful towards the end when you're waiting for the last slow tests to finish.

It will also print out the output from failing tests and it will print a line for skipped
tests (to annoy you into getting them into a shape where they can be unskipped). For
example, for LayoutTests, it will print just the diff, if the test fails. It's cool.

* Scripts/run-jsc-stress-tests:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156983 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFrameSelection: Remove two unused member functions.
akling@apple.com [Sun, 6 Oct 2013 02:32:32 +0000 (02:32 +0000)]
FrameSelection: Remove two unused member functions.

Rubber-stamped by Anders Carlsson.

- rootEditableElementOrTreeScopeRootNode()
- rootEditableElementRespectingShadowTree()

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156982 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Node::treeScope() should return a reference.
akling@apple.com [Sun, 6 Oct 2013 02:30:52 +0000 (02:30 +0000)]
CTTE: Node::treeScope() should return a reference.
<https://webkit.org/b/122399>

Reviewed by Superlative Sam.

Every Node belongs to a TreeScope. To enforce this, I've made
treeScope() return a TreeScope&, and setTreeScope() now takes a
TreeScope& so there is no way to clear it.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156981 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Use references more for the Document parser
weinig@apple.com [Sun, 6 Oct 2013 01:08:17 +0000 (01:08 +0000)]
CTTE: Use references more for the Document parser
https://bugs.webkit.org/show_bug.cgi?id=122398

Reviewed by Andreas Kling.

Clarify the construction semantics of Document parsers.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156980 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[iOS] Default initialize Settings::setFixedPositionCreatesStackingContext() to true
dbates@webkit.org [Sun, 6 Oct 2013 00:34:04 +0000 (00:34 +0000)]
[iOS] Default initialize Settings::setFixedPositionCreatesStackingContext() to true
https://bugs.webkit.org/show_bug.cgi?id=122338
<rdar://problem/14908151>

Reviewed by Darin Adler.

On iOS we always want an element with a fixed position to create a stacking context.
See <rdar://problem/9813262> for more details.

* page/Settings.cpp: Define constant defaultFixedPositionCreatesStackingContext to
be true when building for iOS and false otherwise.
* page/Settings.in: Initialize the setting fixedPositionCreatesStackingContext with
the value of the constant defaultFixedPositionCreatesStackingContext.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156979 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCTTE: Pass DocumentWriter around as a reference
weinig@apple.com [Sat, 5 Oct 2013 23:59:58 +0000 (23:59 +0000)]
CTTE: Pass DocumentWriter around as a reference
https://bugs.webkit.org/show_bug.cgi?id=122396

Reviewed by Andreas Kling.

../WebCore:

* bindings/js/ScriptController.cpp:
(WebCore::ScriptController::executeIfJavaScriptURL):
* dom/DecodedDataDocumentParser.cpp:
(WebCore::DecodedDataDocumentParser::appendBytes):
(WebCore::DecodedDataDocumentParser::flush):
* dom/DecodedDataDocumentParser.h:
* dom/DocumentParser.h:
* dom/RawDataDocumentParser.h:
(WebCore::RawDataDocumentParser::flush):
* html/ImageDocument.cpp:
(WebCore::ImageDocumentParser::appendBytes):
* html/MediaDocument.cpp:
(WebCore::MediaDocumentParser::appendBytes):
(WebCore::MediaDocument::replaceMediaElementTimerFired):
* html/PluginDocument.cpp:
(WebCore::PluginDocumentParser::createDocumentStructure):
(WebCore::PluginDocumentParser::appendBytes):
* inspector/InspectorOverlay.cpp:
(WebCore::InspectorOverlay::overlayPage):
* loader/DocumentLoader.h:
(WebCore::DocumentLoader::writer):
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::addData):
(WebCore::DocumentWriter::end):
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::transitionToCommitted):
* loader/SinkDocument.cpp:
(WebCore::SinkDocumentParser::appendBytes):
* svg/graphics/SVGImage.cpp:
(WebCore::SVGImage::dataChanged):

../WebKit/mac:

* WebView/WebFrame.mm:
(-[WebFrame _canProvideDocumentSource]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156978 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoFrameView: Remove code for disabling repaints.
akling@apple.com [Sat, 5 Oct 2013 23:56:12 +0000 (23:56 +0000)]
FrameView: Remove code for disabling repaints.
<https://webkit.org/b/122393>

Reviewed by Sam Weinig.

Nobody uses this mode for anything so let's just remove it.

It was added back in r110469 to fix an issue with SVGImageCache
and its only user disappeard in the cache overhaul in r142765.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156977 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAllow skipping of run-jsc-stress-tests that are configured using yaml files
fpizlo@apple.com [Sat, 5 Oct 2013 23:53:54 +0000 (23:53 +0000)]
Allow skipping of run-jsc-stress-tests that are configured using yaml files
https://bugs.webkit.org/show_bug.cgi?id=122385

Tools:

Reviewed by Sam Wieinig.

Make tests run via YAML be able to do the parse-for-commands trick that allows
us to skip tests and do other custom per-test stuff.

* Scripts/jsc-stress-test-helpers/layout-test-helper:
* Scripts/run-jsc-stress-tests:

LayoutTests:

Reviewed by Sam Weinig.

The way that we "skip" tests is by having a custom command at the top using //@ notation,
and then use "//@ skip". But the machinery to do that also allows us to do things like
run tests in a no-concurrent-JIT mode - so I've also implemented that in this patch.

Use the skip machinery to skip large-expressions.js.

* js/script-tests/large-expressions.js:
* jsc-layout-tests.yaml:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156976 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove IFrameShimSupport, it was only used by dead ports.
akling@apple.com [Sat, 5 Oct 2013 23:02:42 +0000 (23:02 +0000)]
Remove IFrameShimSupport, it was only used by dead ports.

Rubber-stamped by Anders Carlsson.

* plugins/IFrameShimSupport.cpp: Removed.
* plugins/IFrameShimSupport.h: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156975 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove remaining Qt files.
akling@apple.com [Sat, 5 Oct 2013 22:57:07 +0000 (22:57 +0000)]
Remove remaining Qt files.

Rubber-stamped by Anders Carlsson.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156974 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTry to fix the GTK+ build.
andersca@apple.com [Sat, 5 Oct 2013 21:57:23 +0000 (21:57 +0000)]
Try to fix the GTK+ build.

* UIProcess/gtk/WebPageProxyGtk.cpp:
(WebKit::WebPageProxy::platformInitialize):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156973 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoClean up MessageQueue.h
andersca@apple.com [Sat, 5 Oct 2013 21:53:59 +0000 (21:53 +0000)]
Clean up MessageQueue.h
https://bugs.webkit.org/show_bug.cgi?id=122392

Reviewed by Andreas Kling.

Source/WebCore:

Update for changes to MessageQueue, mostly changing create functions to return std::unique_ptr.
I intentionally avoided using std::make_unique in a couple of places because I didn't want to make nested classes
public, and I believe that we can change some of this code to use std::function.

* Modules/webaudio/AsyncAudioDecoder.cpp:
(WebCore::AsyncAudioDecoder::decodeAsync):
(WebCore::AsyncAudioDecoder::runLoop):
(WebCore::AsyncAudioDecoder::DecodingTask::create):
* Modules/webaudio/AsyncAudioDecoder.h:
* Modules/webdatabase/Database.cpp:
(WebCore::Database::markAsDeletedAndClose):
(WebCore::Database::tableNames):
* Modules/webdatabase/DatabaseBackend.cpp:
(WebCore::DatabaseBackend::openAndVerifyVersion):
(WebCore::DatabaseBackend::scheduleTransaction):
(WebCore::DatabaseBackend::scheduleTransactionStep):
* Modules/webdatabase/DatabaseTask.h:
(WebCore::DatabaseBackend::DatabaseOpenTask::create):
(WebCore::DatabaseBackend::DatabaseCloseTask::create):
(WebCore::DatabaseBackend::DatabaseTransactionTask::create):
(WebCore::DatabaseBackend::DatabaseTableNamesTask::create):
* Modules/webdatabase/DatabaseThread.cpp:
(WebCore::DatabaseThread::databaseThread):
(WebCore::DatabaseThread::scheduleTask):
(WebCore::DatabaseThread::scheduleImmediateTask):
(WebCore::SameDatabasePredicate::operator()):
* Modules/webdatabase/DatabaseThread.h:
* dom/default/PlatformMessagePortChannel.cpp:
(WebCore::PlatformMessagePortChannel::EventData::create):
(WebCore::MessagePortChannel::tryGetMessageFromRemote):
* dom/default/PlatformMessagePortChannel.h:
(WebCore::PlatformMessagePortChannel::MessagePortQueue::tryGetMessage):
(WebCore::PlatformMessagePortChannel::MessagePortQueue::appendAndCheckEmpty):
* fileapi/FileThread.cpp:
(WebCore::FileThread::postTask):
(WebCore::SameInstancePredicate::operator()):
(WebCore::FileThread::runLoop):
* fileapi/FileThread.h:
* fileapi/FileThreadTask.h:
(WebCore::createFileThreadTask):
* storage/StorageThread.cpp:
(WebCore::StorageThread::threadEntryPoint):
(WebCore::StorageThread::dispatch):
(WebCore::StorageThread::terminate):
* workers/WorkerRunLoop.cpp:
(WebCore::ModePredicate::operator()):
(WebCore::WorkerRunLoop::runInMode):
(WebCore::WorkerRunLoop::runCleanupTasks):
(WebCore::WorkerRunLoop::Task::create):
* workers/WorkerRunLoop.h:

Source/WTF:

Make MessageQueue use std::unique_ptr and change findIf and removeIf to take const references.

* wtf/Deque.h:
Change findIf to take an rvalue reference.

* wtf/MessageQueue.h:
(WTF::::append):
(WTF::::appendAndKill):
(WTF::::appendAndCheckEmpty):
(WTF::::prepend):
(WTF::::removeIf):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156972 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[WebGL] program should not be able to link if a bad shader is attached
dino@apple.com [Sat, 5 Oct 2013 19:27:35 +0000 (19:27 +0000)]
[WebGL] program should not be able to link if a bad shader is attached
https://bugs.webkit.org/show_bug.cgi?id=94036

Reviewed by Darin Adler.

If you attempt to link a program when bad shaders are attached, the
link should fail. WebGL also requires that the previously linked
program should remain intact. We were doing the former, but not
the latter.

Fix this by not calling glLinkProgram if we know we have bad
shaders, and synthesize a bad link status instead.

Test: WebGL conformance test conformance/programs/program-test.html
(found in LayoutTests/webgl)

* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::compileShader): Mark a shader as valid
if it compiled ok.
(WebCore::WebGLRenderingContext::linkProgram): Don't call into GraphicsContext3D::linkProgram
if we know that we don't have valid shaders.
* html/canvas/WebGLShader.cpp:
(WebCore::WebGLShader::WebGLShader): Initialize m_isValid.
* html/canvas/WebGLShader.h:
(WebCore::WebGLShader::isValid): New member variable getter and setter.
(WebCore::WebGLShader::setValid):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156971 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUndo texture unit code refactoring - it is ok to bind a texture to multiple locations
dino@apple.com [Sat, 5 Oct 2013 19:21:04 +0000 (19:21 +0000)]
Undo texture unit code refactoring - it is ok to bind a texture to multiple locations
https://bugs.webkit.org/show_bug.cgi?id=122369
<rdar://problem/15158465>

Reviewed by Darin Adler.

The optimisation in r152351 (http://webkit.org/b/117868) incorrectly
assumes that a texture cannot be bound to more than one location.
That's true only within the same program object. It's legal to
address TEXTURE_BINDING_2D and TEXTURE_BINDING_CUBE_MAP with the
same texture in different programs.

See https://github.com/KhronosGroup/WebGL/pull/391 for more information.

This change reverts the optimisation, but also does some minor
cleanup (0 -> nullptr, class -> struct).

Covered by the following Khronos WebGL 1.0.1 tests, which
now pass:
- conformance/more/functions/texImage2DHTML.html
- conformance/more/functions/texSubImage2D.html
- conformance/more/functions/texSubImage2DHTML.html

* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::~WebGLRenderingContext):
(WebCore::WebGLRenderingContext::reshape):
(WebCore::WebGLRenderingContext::bindTexture):
(WebCore::WebGLRenderingContext::deleteTexture):
(WebCore::WebGLRenderingContext::getParameter):
(WebCore::WebGLRenderingContext::handleNPOTTextures):
(WebCore::WebGLRenderingContext::validateTextureBinding):
(WebCore::WebGLRenderingContext::restoreCurrentTexture2D):
* html/canvas/WebGLRenderingContext.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156970 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTry to #define final to sealed when building with MSVC
andersca@apple.com [Sat, 5 Oct 2013 19:02:54 +0000 (19:02 +0000)]
Try to #define final to sealed when building with MSVC
https://bugs.webkit.org/show_bug.cgi?id=122386

Reviewed by Darin Adler.

* wtf/Compiler.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156969 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove createOwned
andersca@apple.com [Sat, 5 Oct 2013 18:59:00 +0000 (18:59 +0000)]
Remove createOwned
https://bugs.webkit.org/show_bug.cgi?id=122388

Reviewed by Darin Adler.

Source/JavaScriptCore:

* profiler/ProfilerDatabase.cpp:
(JSC::Profiler::Database::save):

Source/WebCore:

* dom/Document.cpp:
(WebCore::Document::Document):
(WebCore::Document::~Document):
(WebCore::Document::createRenderTree):
(WebCore::Document::destroyRenderTree):
* dom/Document.h:
* page/Frame.cpp:
(WebCore::Frame::Frame):
* page/Frame.h:
* page/animation/AnimationController.cpp:
(WebCore::AnimationController::AnimationController):
* page/animation/AnimationController.h:
* platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.h:
* platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.h:
* platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
(WebCore::AudioTrackPrivateAVFObjC::AudioTrackPrivateAVFObjC):
(WebCore::AudioTrackPrivateAVFObjC::setPlayerItemTrack):
* platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.cpp:
(WebCore::VideoTrackPrivateAVFObjC::VideoTrackPrivateAVFObjC):
(WebCore::VideoTrackPrivateAVFObjC::setPlayerItemTrack):
* platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.h:
* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::applyClippingToContext):
* rendering/svg/RenderSVGResourceClipper.h:
* rendering/svg/RenderSVGResourceFilter.cpp:
(WebCore::RenderSVGResourceFilter::applyResource):
* rendering/svg/RenderSVGResourceFilter.h:
* rendering/svg/RenderSVGResourceMasker.cpp:
(WebCore::RenderSVGResourceMasker::applyResource):
* rendering/svg/RenderSVGResourceMasker.h:

Source/WebKit2:

* UIProcess/API/mac/WKView.mm:
(-[WKView _setFindIndicator:fadeOut:animate:]):
* WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
(WKBundlePageOverlayCreate):

Source/WTF:

Since we're going with std::unique_ptr instead of OwnPtr, there's no need for makeOwned to exist.
Get rid of it and replace it with calls to std::make_unique.

* wtf/FilePrintStream.cpp:
(WTF::FilePrintStream::open):
* wtf/FilePrintStream.h:
* wtf/HashTable.h:
(WTF::::HashTable):
* wtf/ListHashSet.h:
(WTF::::ListHashSet):
* wtf/OwnPtr.h:
* wtf/Threading.cpp:
(WTF::compatEntryPoint):
(WTF::createThread):
* wtf/ThreadingPthreads.cpp:
(WTF::wtfThreadEntryPoint):
(WTF::createThreadInternal):
* wtf/unicode/Collator.h:
* wtf/unicode/CollatorDefault.cpp:
(WTF::Collator::userDefault):
* wtf/unicode/icu/CollatorICU.cpp:
(WTF::Collator::userDefault):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156968 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoRemove COMPILER_SUPPORTS(CXX_RVALUE_REFERENCES) since it's required now
darin@apple.com [Sat, 5 Oct 2013 18:32:37 +0000 (18:32 +0000)]
Remove COMPILER_SUPPORTS(CXX_RVALUE_REFERENCES) since it's required now
https://bugs.webkit.org/show_bug.cgi?id=122387

Reviewed by Anders Carlsson.

Source/WebCore:

* html/canvas/CanvasStyle.h: Take out conditionals.

Source/WebKit2:

* UIProcess/API/cpp/WKRetainPtr.h: Take out conditionals.

Source/WTF:

* wtf/RefPtr.h:
* wtf/RetainPtr.h:
* wtf/Vector.h:
* wtf/text/AtomicString.h:
* wtf/text/WTFString.h:
Take out conditionals.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156967 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoUnreviewed GTK build fix after r156946. The framePolicyFunction is an attribute
zandobersek@gmail.com [Sat, 5 Oct 2013 18:31:23 +0000 (18:31 +0000)]
Unreviewed GTK build fix after r156946. The framePolicyFunction is an attribute
on the WebKitWebPolicyDecisionPrivate object.

* webkit/webkitwebpolicydecision.cpp:
(webkit_web_policy_decision_use):
(webkit_web_policy_decision_ignore):
(webkit_web_policy_decision_download):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156966 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAdd AtomicString::number and use it
darin@apple.com [Sat, 5 Oct 2013 18:22:39 +0000 (18:22 +0000)]
Add AtomicString::number and use it
https://bugs.webkit.org/show_bug.cgi?id=122384

Reviewed by Anders Carlsson.

Source/WebCore:

* css/CSSGrammar.y.in: Use AtomicString::number instead of String::number since
we are creating an AtomicString. This can save a memory allocation if the string
happens to already be in the atomic string table.
* dom/Element.cpp:
(WebCore::Element::setIntegralAttribute): Ditto.
(WebCore::Element::setUnsignedIntegralAttribute): Ditto.
* editing/BreakBlockquoteCommand.cpp:
(WebCore::BreakBlockquoteCommand::doApply): Ditto.
* html/HTMLBodyElement.cpp:
(WebCore::HTMLBodyElement::insertedInto): Use setIntegralAttribute instead of
a local homegrown equivalent.
* html/HTMLCanvasElement.cpp:
(WebCore::HTMLCanvasElement::setHeight): Ditto.
(WebCore::HTMLCanvasElement::setWidth): Ditto.
* html/HTMLElement.cpp:
(WebCore::HTMLElement::setTabIndex): Ditto.
* html/HTMLImageElement.cpp:
(WebCore::HTMLImageElement::setHeight): Ditto.
(WebCore::HTMLImageElement::setWidth): Ditto.
* html/HTMLInputElement.cpp:
(WebCore::HTMLInputElement::setMaxLength): Ditto.
(WebCore::HTMLInputElement::setSize): Same, but setUnsignedIntegralAttribute.
(WebCore::HTMLInputElement::setHeight): Ditto.
(WebCore::HTMLInputElement::setWidth): Ditto.
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::mediaPlayerSetSize): Ditto.
* html/HTMLMeterElement.cpp:
(WebCore::HTMLMeterElement::setMin): More of the same.
(WebCore::HTMLMeterElement::setMax): Ditto.
(WebCore::HTMLMeterElement::setValue): Ditto.
(WebCore::HTMLMeterElement::setLow): Ditto.
(WebCore::HTMLMeterElement::setHigh): Ditto.
(WebCore::HTMLMeterElement::setOptimum): Ditto.
* html/HTMLOListElement.cpp:
(WebCore::HTMLOListElement::setStart): Ditto.
* html/HTMLProgressElement.cpp:
(WebCore::HTMLProgressElement::setValue): Ditto.
(WebCore::HTMLProgressElement::setMax): Ditto.
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::parseAttribute): Ditto.
(WebCore::HTMLSelectElement::setSize): Ditto.
* html/HTMLTableCellElement.cpp:
(WebCore::HTMLTableCellElement::setColSpan): Ditto.
(WebCore::HTMLTableCellElement::setRowSpan): Ditto.
* html/HTMLTableColElement.cpp:
(WebCore::HTMLTableColElement::setSpan): Ditto.
* html/HTMLTextAreaElement.cpp:
(WebCore::HTMLTextAreaElement::setMaxLength): Ditto.
(WebCore::HTMLTextAreaElement::setCols): Ditto.
(WebCore::HTMLTextAreaElement::setRows): Ditto.
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlTimelineElement::setDuration): Ditto.

Source/WTF:

* wtf/text/AtomicString.cpp:
(WTF::AtomicString::number): Added.
* wtf/text/AtomicString.h: Ditto.

* wtf/text/IntegerToStringConversion.h: Simplify includes, renamed ConversionTrait to
IntegerToStringConversionTrait. Changed String version to use String since we no longer
need to use PassRefPtr to efficiently handle return values. Replaced UnsignedIntegerTrait
with std::make_unsigned. Added AtomicString support. Use nullptr instead of 0.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156965 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoCut down on use of String::number
darin@apple.com [Sat, 5 Oct 2013 18:04:40 +0000 (18:04 +0000)]
Cut down on use of String::number
https://bugs.webkit.org/show_bug.cgi?id=122382

Reviewed by Anders Carlsson.

Source/JavaScriptCore:

* API/JSCallbackObjectFunctions.h:
(JSC::JSCallbackObject::putByIndex): Use Identifier::from instead of calling
String::number and creating an identifier from that. Can save creating and then
destroying a string if an identifier already exists.
* runtime/Arguments.cpp:
(JSC::Arguments::getOwnPropertySlotByIndex): Ditto.
(JSC::Arguments::getOwnPropertyNames): Ditto.
(JSC::Arguments::putByIndex): Ditto.
* runtime/JSGenericTypedArrayViewInlines.h:
(JSC::::getOwnPropertyNames): Ditto.
* runtime/StringObject.cpp:
(JSC::StringObject::getOwnPropertyNames): Ditto.

Source/WebCore:

* css/CSSGradientValue.cpp:
(WebCore::CSSLinearGradientValue::customCSSText): Use StringBuilder::appendNumber,
instead of creating a string and then appending it.
(WebCore::CSSRadialGradientValue::customCSSText): Ditto.
* css/CSSParser.cpp:
(WebCore::CSSParser::createKeyframe): Ditto.
* editing/DeleteButtonController.cpp:
(WebCore::DeleteButtonController::createDeletionUI): Use ASCII literals instead of
converting numeric constants to strings at runtime with String::number.
(WebCore::DeleteButtonController::show): Ditto.
* svg/SVGNumberList.cpp:
(WebCore::SVGNumberList::valueAsString): Use StringBuilder::appendNumber.
* svg/SVGPointList.cpp:
(WebCore::SVGPointList::valueAsString): Ditto.
* svg/SVGRect.h: Ditto.

Source/WebKit2:

* Shared/mac/RemoteLayerTreeTransaction.mm:
(WebKit::dumpChangedLayers): Use StringBuilder::appendNumber.

Source/WTF:

* wtf/DateMath.cpp:
(WTF::appendTwoDigitNumber): Added. Replaces twoDigitStringFromNumber, which returned a
String and also allocated a temporary string for any number 10 or higher.
(WTF::makeRFC2822DateString): Updated to use the new function.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156964 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoTest the waters and begin using lambdas
andersca@apple.com [Sat, 5 Oct 2013 17:45:38 +0000 (17:45 +0000)]
Test the waters and begin using lambdas
https://bugs.webkit.org/show_bug.cgi?id=121809

Reviewed by Andreas Kling.

Source/WebCore:

Use lambdas instead of static functions and function objects.

* css/MediaQuery.cpp:
(WebCore::MediaQuery::MediaQuery):
* dom/MutationObserver.cpp:
(WebCore::MutationObserver::deliverAllMutations):
* page/CaptionUserPreferences.cpp:
(WebCore::CaptionUserPreferences::sortedTrackListForMenu):

Source/WTF:

* wtf/ListDump.h:
(WTF::sortedListDump):
Use std::less instead of a custom lessThan function.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156963 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years ago[CSS Regions] Layout Test for selecting text ignoring region content
rego@igalia.com [Sat, 5 Oct 2013 17:07:25 +0000 (17:07 +0000)]
[CSS Regions] Layout Test for selecting text ignoring region content
https://bugs.webkit.org/show_bug.cgi?id=122353

Reviewed by Darin Adler.

Add new reftests for selecting text in texts wrapping a region, where
the region content is ignored. It compares the behavior (highlighted
text and selected content) in regions and absolute positions.

Absolute positioned elements do not fill the gaps on the right during
the selection, unlike regular elements. This is the reason why some
regular elements are floated in order to avoid such problems in the
reftests.

Provided layout tests for different writing models.

* fast/regions/resources/region-style.css: New CSS classes required for these tests.
* fast/regions/selection/selecting-text-ignoring-region-expected.html: Added.
* fast/regions/selection/selecting-text-ignoring-region-horiz-bt-expected.html: Added.
* fast/regions/selection/selecting-text-ignoring-region-horiz-bt.html: Added.
* fast/regions/selection/selecting-text-ignoring-region-vert-lr-expected.html: Added.
* fast/regions/selection/selecting-text-ignoring-region-vert-lr.html: Added.
* fast/regions/selection/selecting-text-ignoring-region-vert-rl-expected.html: Added.
* fast/regions/selection/selecting-text-ignoring-region-vert-rl.html: Added.
* fast/regions/selection/selecting-text-ignoring-region.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156962 268f45cc-cd09-0410-ab3c-d52691b4dbfc

7 years agoAdd *CSS* prefix to FontValue to generate toCSSFontValue()
gyuyoung.kim@samsung.com [Sat, 5 Oct 2013 17:06:13 +0000 (17:06 +0000)]
Add *CSS* prefix to FontValue to generate toCSSFontValue()
https://bugs.webkit.org/show_bug.cgi?id=122201

Reviewed by Darin Adler.

*CSS* prefix needs to be added to FontValue class in order to generate toCSSFontValue().
static_cast<FontValue*> is changed with toCSSFontValue() by this change.

No new tests, no behavior changes.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::propertyValue):
* css/CSSFontValue.cpp: Renamed from Source/WebCore/css/FontValue.cpp.
(WebCore::CSSFontValue::customCSSText):
(WebCore::CSSFontValue::equals):
* css/CSSFontValue.h: Renamed from Source/WebCore/css/FontValue.h.
(WebCore::CSSFontValue::create):
(WebCore::CSSFontValue::CSSFontValue):
* css/CSSParser.cpp:
* css/CSSValue.cpp:
(WebCore::CSSValue::equals):
(WebCore::CSSValue::cssText):
(WebCore::CSSValue::destroy):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@156961 268f45cc-cd09-0410-ab3c-d52691b4dbfc