Timeline



Dec 7, 2019:

9:59 PM Changeset in webkit [253268] by commit-queue@webkit.org
  • 42 edits in trunk

Make ColorSpace an enum class
https://bugs.webkit.org/show_bug.cgi?id=204970

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-12-07
Reviewed by Sam Weinig.

Source/WebCore:

So it can be encoded and decoded through the IPC messages.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::parseColorFunctionParameters):

  • html/CustomPaintCanvas.cpp:

(WebCore::CustomPaintCanvas::copiedImage const):

  • html/HTMLCanvasElement.cpp:

(WebCore::HTMLCanvasElement::createImageBuffer const):

  • html/canvas/CanvasRenderingContext2D.cpp:

(WebCore::CanvasRenderingContext2D::drawTextInternal):

  • html/canvas/CanvasRenderingContext2DBase.cpp:

(WebCore::CanvasRenderingContext2DBase::drawImage):

  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::drawPattern):

  • platform/graphics/Color.cpp:

(WebCore::operator<<):

  • platform/graphics/Color.h:

(WebCore::Color::Color):

  • platform/graphics/ColorSpace.h:

(): Deleted.

  • platform/graphics/CustomPaintImage.cpp:

(WebCore::CustomPaintImage::drawPattern):

  • platform/graphics/ExtendedColor.cpp:

(WebCore::ExtendedColor::create):
(WebCore::ExtendedColor::cssText const):

  • platform/graphics/ExtendedColor.h:
  • platform/graphics/GradientImage.cpp:

(WebCore::GradientImage::drawPattern):

  • platform/graphics/ImageBuffer.cpp:

(WebCore::ImageBuffer::transformColorSpace):

  • platform/graphics/ImageBuffer.h:
  • platform/graphics/cairo/ImageBufferCairo.cpp:

(WebCore::ImageBuffer::createCompatibleBuffer):

  • platform/graphics/cg/ColorCG.cpp:

(WebCore::leakCGColor):

  • platform/graphics/cg/GraphicsContextCG.h:

(WebCore::cachedCGColorSpace):

  • platform/graphics/filters/FEFlood.h:
  • platform/graphics/filters/FELighting.cpp:

(WebCore::FELighting::drawLighting):

  • platform/graphics/filters/FETile.cpp:

(WebCore::FETile::platformApplySoftware):

  • platform/graphics/filters/FilterEffect.h:
  • platform/graphics/filters/SourceGraphic.h:

(WebCore::SourceGraphic::SourceGraphic):

  • platform/graphics/win/ImageBufferDirect2D.cpp:

(WebCore::ImageBuffer::createCompatibleBuffer):

  • platform/mac/ThemeMac.mm:

(WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext):

  • rendering/CSSFilter.cpp:

(WebCore::CSSFilter::buildReferenceFilter):
(WebCore::CSSFilter::build):
(WebCore::CSSFilter::apply):

  • rendering/RenderBoxModelObject.cpp:

(WebCore::RenderBoxModelObject::paintFillLayerExtended):

  • rendering/RenderLayerBacking.cpp:

(WebCore::patternForTouchAction):

  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::paintProgressBar):

  • rendering/svg/RenderSVGResourceClipper.cpp:

(WebCore::RenderSVGResourceClipper::applyClippingToContext):

  • rendering/svg/RenderSVGResourceFilter.cpp:

(WebCore::RenderSVGResourceFilter::buildPrimitives const):
(WebCore::RenderSVGResourceFilter::applyResource):
(WebCore::RenderSVGResourceFilter::postApplyResource):

  • rendering/svg/RenderSVGResourceGradient.cpp:

(WebCore::createMaskAndSwapContextForTextGradient):

  • rendering/svg/RenderSVGResourceMasker.cpp:

(WebCore::RenderSVGResourceMasker::applyResource):
(WebCore::RenderSVGResourceMasker::drawContentIntoMaskImage):

  • rendering/svg/RenderSVGResourcePattern.cpp:

(WebCore::RenderSVGResourcePattern::createTileImage const):

  • rendering/svg/SVGRenderingContext.cpp:

(WebCore::SVGRenderingContext::bufferForeground):

  • svg/graphics/SVGImage.cpp:

(WebCore::SVGImage::drawPatternForContainer):

  • svg/graphics/filters/SVGFEImage.cpp:

(WebCore::FEImage::platformApplySoftware):

Source/WebKit:

  • Shared/WebCoreArgumentCoders.h:

Tools:

  • TestWebKitAPI/Tests/WebCore/ExtendedColor.cpp:

(TestWebKitAPI::TEST):
(TestWebKitAPI::makeColor):

7:57 PM Changeset in webkit [253267] by Wenson Hsieh
  • 24 edits
    4 adds in trunk

[iOS] WKWebView touch event gesture recognition should not block the application process main thread when possible
https://bugs.webkit.org/show_bug.cgi?id=204664
<rdar://problem/38670692>

Reviewed by Tim Horton.

Source/WebKit:

Adds a mechanism that allows some sync touch events on iOS to be sent asynchronously. To do this, we use the
deferring gesture mechanism introduced in trac.webkit.org/r253005 to defer all gestures under WKContentView (and
WebKit-owned scroll views) when a touch starts, such that they will not recognize until we know that the page
has either prevented default or not (assuming that the touch was over an active listener). See below for more
details.

Tests: fast/events/touch/ios/prevent-default-on-touch-start-with-slow-event-listener.html

fast/events/touch/ios/scroll-on-touch-start-with-slow-event-listener.html

  • UIProcess/GenericCallback.h:
  • UIProcess/PageClient.h:
  • UIProcess/RemoteLayerTree/ios/RemoteLayerTreeViews.mm:

(-[WKChildScrollView gestureRecognizer:shouldRequireFailureOfGestureRecognizer:]):
(-[WKChildScrollView gestureRecognizer:shouldBeRequiredToFailByGestureRecognizer:]):

Implement gesture recognizer delegate hooks to add dynamic failure requirements between a child scroll view's
gestures and the new deferring gesture recognizers on WKContentView. This allows pan gestures over a scrollable
container to hold off on recognizing while the deferring gesture recognizer has not failed yet.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::handlePreventableTouchEvent):
(WebKit::WebPageProxy::handleUnpreventableTouchEvent):

Rename handleTouchEventSynchronously and handleTouchEventAsynchronously to handlePreventableTouchEvent and
handleUnpreventableTouchEvent, respectively. Instead of always sending touchstart events that may prevent native
gestures synchronously, we may now go through the same EventDispatcher::TouchEvent codepath used when
dispatching touch events in passive tracking regions. However, in the case of preventable touchstarts, we
additionally store a completion callback that is invoked after the touch event has been handled by the page; we
then either un-defer or prevent native gestures here (depending on whether the page prevented default) by
calling PageClient::doneDeferringNativeGestures.

Non-touchstart events are still dispatched synchronously, to ensure that calling preventDefault() on touchmove
and touchend continue to prevent default gestures from recognizing.

(WebKit::WebPageProxy::boolCallback):
(WebKit::WebPageProxy::handleTouchEventSynchronously): Deleted.
(WebKit::WebPageProxy::handleTouchEventAsynchronously): Deleted.

See above.

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::isHandlingPreventableTouchStart const):

This is used in WKContentView to determine whether deferring gestures need to remain active after the touch
ends. See below for more detail.

  • UIProcess/WebPageProxy.messages.in:
  • UIProcess/ios/PageClientImplIOS.h:
  • UIProcess/ios/PageClientImplIOS.mm:

(WebKit::PageClientImpl::doneDeferringNativeGestures):

  • UIProcess/ios/WKContentViewInteraction.h:
  • UIProcess/ios/WKContentViewInteraction.mm:

(-[UIGestureRecognizer _wk_cancel]):
(-[WKContentView setupInteraction]):
(-[WKContentView cleanupInteraction]):
(-[WKContentView _removeDefaultGestureRecognizers]):
(-[WKContentView _addDefaultGestureRecognizers]):

Add and remove the new deferring gesture recognizers here.

(-[WKContentView _webTouchEventsRecognized:]):
(-[WKContentView _webTouchEvent:preventsNativeGestures:]):
(-[WKContentView _doneDeferringNativeGestures:]):
(-[WKContentView gestureRecognizer:shouldRecognizeSimultaneouslyWithGestureRecognizer:]):
(-[WKContentView ensurePositionInformationIsUpToDate:]):

Drive-by fix: add a missing hasRunningProcess check that causes a flaky assertion under
AuxiliaryProcessProxy::connection() in layout tests.

(-[WKContentView gestureRecognizer:shouldRequireFailureOfGestureRecognizer:]):
(-[WKContentView gestureRecognizer:shouldBeRequiredToFailByGestureRecognizer:]):

Add dynamic failure requirements between WKContentView's gestures (including all text interaction, context menu,
and drag and drop gestures) and the new deferring gesture recognizers.

(-[WKContentView _didStartProvisionalLoadForMainFrame]):

Force the two-finger double tap gesture recognizer to reset when loading a new page. Without this, the layout
test fast/events/ios/click-event-while-editing-node.html will rarely fail when run after a test that dispatches
a two-finger tap, such as fast/events/ios/click-event-two-finger-single-tap-meta-key.html. This is because the
new deferring gestures will temporarily unite multi-finger tap gestures with one-finger double tap gestures in
the same subgraph when performing a tap gesture with more than one finger. This means that there's a 300 ms
delay before a normal single tap can be recognized again, which (without forcing the two-finger double tap to
reset) would cause a subsequent test that loads in under 300 ms and attempts to send a tap to fail.

(-[WKContentView deferringGestureRecognizer:shouldDeferGesturesAfterBeginningTouchesWithEvent:]):

Avoid deferring native gestures if the scroll view is decelerating; this matches behavior of the web touch event
gesture recognizer.

(-[WKContentView deferringGestureRecognizer:shouldDeferGesturesAfterEndingTouchesWithEvent:]):

Normally, after -touchesEnded:withEvent:, we stop deferring native gesture recognizers by failing the deferring
gestures. However, if we're still waiting for a response from the web process, then let
-_doneDeferringNativeGestures: handle this instead.

(-[WKContentView deferringGestureRecognizer:shouldDeferOtherGestureRecognizer:]):
(-[WKContentView deferringGestureRecognizer:shouldDeferGesturesWithEvent:]): Deleted.

Renamed to -shouldDeferGesturesAfterBeginningTouchesWithEvent:.

  • UIProcess/ios/WKDeferringGestureRecognizer.h:
  • UIProcess/ios/WKDeferringGestureRecognizer.mm:

(-[WKDeferringGestureRecognizer touchesBegan:withEvent:]):
(-[WKDeferringGestureRecognizer touchesEnded:withEvent:]):

Override this and add a new delegate hook to determine whether we want the deferring gesture recognizer to
immediately fail when touches end. It's important to override this and transition to failure state in this case,
since not doing so could mean that the deferring gestures stay in Possible state forever; this may lead to the
gesture subgraph containing these deferring gestures being unable to reset, since it's waiting for the deferring
gesture to either fail or end.

  • UIProcess/ios/WKScrollView.mm:

(-[WKScrollView gestureRecognizer:shouldRequireFailureOfGestureRecognizer:]):
(-[WKScrollView gestureRecognizer:shouldBeRequiredToFailByGestureRecognizer:]):

Defer more scroll view gestures.

  • WebProcess/WebPage/EventDispatcher.cpp:

(WebKit::EventDispatcher::touchEvent):

Add an optional CallbackID parameter to this IPC message. If a callback ID is given, then we avoid coalescing
the touch event. To implement this, we additionally refactor the queued touch events map to contain lists of
<WebTouchEvent, Optional<CallbackID>> pairs; if a queued touch event has a corresponding CallbackID, then we
fire the callback corresponding to the ID, indicating whether the touch event was handled by the page.

  • WebProcess/WebPage/EventDispatcher.h:
  • WebProcess/WebPage/EventDispatcher.messages.in:
  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::dispatchAsynchronousTouchEvents):

LayoutTests:

  • fast/events/touch/ios/prevent-default-on-touch-start-with-slow-event-listener-expected.txt: Added.
  • fast/events/touch/ios/prevent-default-on-touch-start-with-slow-event-listener.html: Added.
  • fast/events/touch/ios/scroll-on-touch-start-with-slow-event-listener-expected.txt: Added.
  • fast/events/touch/ios/scroll-on-touch-start-with-slow-event-listener.html: Added.

Add new layout tests to cover behaviors when panning over active touchstart handlers that spin for an extended
length of time (in this case, 400 milliseconds) in overflow scrolling containers. A touchstart handler that
prevents default should still block scrolling, and a touchstart handler that does not should still allow the
user to scroll.

  • fast/events/touch/ios/show-modal-alert-during-touch-start.html:
  • http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt:
  • http/tests/security/anchor-download-block-crossorigin-expected.txt:

Rebaseline these tests by changing some line numbers.

  • resources/ui-helper.js:

(window.UIHelper.sendEventStream.return.new.Promise):
(window.UIHelper.sendEventStream):

Add a new UIHelper method to send a JSON object as an event stream.

(UIHelper.EventStreamBuilder.prototype._reset):
(UIHelper.EventStreamBuilder.prototype.begin):
(UIHelper.EventStreamBuilder.prototype.move):
(UIHelper.EventStreamBuilder.prototype.end):
(UIHelper.EventStreamBuilder.prototype.takeResult):

Add a new helper class to make it easier to construct event streams, for the purposes of sending to
UIScriptController::sendEventStream.

7:00 PM Changeset in webkit [253266] by Alan Bujtas
  • 6 edits in trunk/Source/WebCore

[LFC][IFC] Convert InlineLayoutUnit/Point/Rect to LayoutUnit/Point/Rect when crossing inline/block boundary
https://bugs.webkit.org/show_bug.cgi?id=204991
<rdar://problem/57730383>

Reviewed by Sam Weinig.

Float -> LayoutUnit requires explicit conversion due to precision loss. Use these functions when
feeding inline box geometry information back to block layout.

Implicit floor will do for now (might need to call round though).

This is in preparation for using float based types in IFC. See webkit.org/b/204986 for more info.

  • layout/LayoutUnits.h:

(WebCore::Layout::toLayoutUnit):
(WebCore::Layout::toLayoutPoint):
(WebCore::Layout::toLayoutRect):

  • layout/blockformatting/BlockFormattingContextGeometry.cpp:

(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):

  • layout/displaytree/DisplayInlineContent.cpp:

(WebCore::Display:: const):

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computedIntrinsicWidthConstraints):
(WebCore::Layout::InlineFormattingContext::constraintsForLine):
(WebCore::Layout::InlineFormattingContext::setDisplayBoxesForLine):

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::paint):

4:41 PM Changeset in webkit [253265] by rniwa@webkit.org
  • 13 edits
    9 adds in trunk

Unique origin's window must get its own event loop
https://bugs.webkit.org/show_bug.cgi?id=204978

Reviewed by Antti Koivisto.

Source/WebCore:

This patch fixes the bug that unique origin documents and documents of the same registrable domains
with different schemes / protocols were sharing the same event loop. Note that we continue to share
the event loop across file URI documents.

We now use the agent cluster key to looking up the event loop to better match the HTML5 spec:
https://html.spec.whatwg.org/multipage/webappapis.html#obtain-agent-cluster-key

Tests: fast/eventloop/data-uri-document-has-its-own-event-loop.html

fast/eventloop/queue-task-across-frames-in-file-uri.html
http/tests/eventloop/documents-with-different-protocols-do-not-share-event-loop.html

  • dom/Document.cpp:

(WebCore::Document::eventLoop):

  • dom/EventLoop.h:

(WebCore::EventLoopTaskGroup::hasSameEventLoopAs): Added for testing purposes.

  • dom/WindowEventLoop.cpp:

(WebCore::agentClusterKeyOrNullIfUnique): Added.
(WebCore::WindowEventLoop::eventLoopForSecurityOrigin): Replaced ensureForRegistrableDomain.
(WebCore::WindowEventLoop::create): Added.
(WebCore::WindowEventLoop::WindowEventLoop):
(WebCore::WindowEventLoop::~WindowEventLoop):

  • dom/WindowEventLoop.h:
  • testing/Internals.cpp:

(WebCore::Internals::hasSameEventLoopAs): Added for testing purposes.

  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

Added tests to make sure data URI documents continue to use the same event loop but documents of
unique origin and of different schemes will use distinct event loops using newly added internals
method (hasSameEventLoopAs). Also added assertions to the existing tests using this new method.

  • fast/eventloop: Added.
  • fast/eventloop/data-uri-document-has-its-own-event-loop-expected.txt: Added.
  • fast/eventloop/data-uri-document-has-its-own-event-loop.html: Added.
  • fast/eventloop/queue-task-across-frames-in-file-uri-expected.txt: Added.
  • fast/eventloop/queue-task-across-frames-in-file-uri.html: Added.
  • fast/eventloop/resources: Added.
  • fast/eventloop/resources/eventloop-helper.html: Added.
  • http/tests/eventloop/documents-with-different-protocols-do-not-share-event-loop-expected.txt: Added.
  • http/tests/eventloop/documents-with-different-protocols-do-not-share-event-loop.html: Added.
  • http/tests/eventloop/queue-task-across-cross-site-frames-expected.txt:
  • http/tests/eventloop/queue-task-across-cross-site-frames.html:
  • http/tests/eventloop/queue-task-across-frames-expected.txt:
  • http/tests/eventloop/queue-task-across-frames.html:
2:57 PM Changeset in webkit [253264] by mark.lam@apple.com
  • 3 edits
    1 add in trunk

Object.prototype.isPrototypeOf() should check if the passed in value is a non-object first.
https://bugs.webkit.org/show_bug.cgi?id=204971
<rdar://problem/57730080>

Reviewed by Saam Barati.

JSTests:

  • stress/object-prototype-isPrototypeOf-should-check-for-non-object-first.js: Added.

Source/JavaScriptCore:

The spec says Object.prototype.isPrototypeOf() should do checks in the following
order:

  1. If Type(V) is not Object, return false.
  2. Let O be ? ToObject(this value).

...
We were previously checking (2) before (1). This patch fixes this order.

Ref: http://www.ecma-international.org/ecma-262/10.0/index.html#sec-object.prototype.isprototypeof

  • runtime/ObjectPrototype.cpp:

(JSC::objectProtoFuncIsPrototypeOf):

2:25 PM Changeset in webkit [253263] by sbarati@apple.com
  • 13 edits
    1 add
    1 delete in trunk/Source/JavaScriptCore

Unreviewed. Roll out r253201. It was not a progression on any benchmarks, and was 8% slower on JetStream 2 ML.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • bytecode/BytecodeList.rb:
  • bytecode/GetByValHistory.h: Added.

(JSC::GetByValHistory::observeNonUID):
(JSC::GetByValHistory::observe):
(JSC::GetByValHistory::count const):
(JSC::GetByValHistory::filter const):
(JSC::GetByValHistory::update):

  • bytecode/PointerHistory.h: Removed.
  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::parseGetById):
(JSC::DFG::ByteCodeParser::parseBlock):

  • dfg/DFGGraph.h:
  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileGetById):

  • dfg/DFGSpeculativeJIT32_64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileGetById):
(JSC::FTL::DFG::LowerDFGToB3::compileGetByVal):

  • generator/DSL.rb:
  • jit/JITPropertyAccess.cpp:

(JSC::JIT::emit_op_try_get_by_id):
(JSC::JIT::emitSlow_op_try_get_by_id):
(JSC::JIT::emit_op_get_by_id_direct):
(JSC::JIT::emitSlow_op_get_by_id_direct):
(JSC::JIT::emit_op_get_by_id):
(JSC::JIT::emitSlow_op_get_by_id):

  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::LLINT_SLOW_PATH_DECL):

  • runtime/OptionsList.h:
2:20 PM Changeset in webkit [253262] by Alan Bujtas
  • 5 edits in trunk/Source/WebCore

[LFC][IFC] Display::LineBox should adopt to InlineLayoutUnit
https://bugs.webkit.org/show_bug.cgi?id=204990
<rdar://problem/57730105>

Reviewed by Sam Weinig.

This is in preparation for using float based types in IFC. See webkit.org/b/204986 for more info.

  • layout/displaytree/DisplayLineBox.h:

(WebCore::Display::LineBox::logicalTopLeft const):
(WebCore::Display::LineBox::setLogicalTopLeft):

  • layout/displaytree/DisplayRun.h:

(WebCore::Display::Run::logicalTopLeft const):
(WebCore::Display::Run::logicalLeft const):
(WebCore::Display::Run::logicalRight const):
(WebCore::Display::Run::logicalTop const):
(WebCore::Display::Run::logicalBottom const):
(WebCore::Display::Run::logicalWidth const):
(WebCore::Display::Run::logicalHeight const):
(WebCore::Display::Run::setLogicalWidth):
(WebCore::Display::Run::setLogicalTop):
(WebCore::Display::Run::setLogicalLeft):
(WebCore::Display::Run::moveVertically):
(WebCore::Display::Run::moveHorizontally):
(WebCore::Display::Run::expandVertically):
(WebCore::Display::Run::expandHorizontally):

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::constraintsForLine):

  • layout/inlineformatting/InlineFormattingContext.h:
12:34 PM Changeset in webkit [253261] by Andres Gonzalez
  • 22 edits in trunk

Implementation of additional attribute caching in the IsolatedTree.
https://bugs.webkit.org/show_bug.cgi?id=204918

Reviewed by Chris Fleizach.

Source/WebCore:

No new tests, no new functionality. Updated several tests to fixed
expected output.

  • Implementation of around 200 methods in the AXIsolatedObject class.
  • The pending method implementations have an ASSERT_NOT_REACHED.
  • Support for dispatching to the main thread some

WebAccessibilityObjectWrapper methods that cannot be run in the
secondary thread.

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::createIsolatedTreeHierarchy):
(WebCore::AXObjectCache::generateIsolatedTree):

  • accessibility/AXObjectCache.h:
  • accessibility/AccessibilityNodeObject.cpp:

(WebCore::AccessibilityNodeObject::ariaLabeledByText const):

  • accessibility/AccessibilityObject.cpp:

(WebCore::AccessibilityObject::actionVerb const):
(WebCore::AccessibilityObject::datetimeAttributeValue const):
(WebCore::AccessibilityObject::linkRelValue const):
(WebCore::AccessibilityObject::isInlineText const):
(WebCore::AccessibilityObject::identifierAttribute const):
(WebCore::AccessibilityObject::documentURI const):
(WebCore::AccessibilityObject::documentEncoding const):
(WebCore::AccessibilityObject::sessionID const):
(WebCore::AccessibilityObject::tagName const):

  • accessibility/AccessibilityObject.h:

(WebCore::AccessibilityText::AccessibilityText):
(WebCore::AccessibilityObject::actionVerb const):

  • accessibility/AccessibilityObjectInterface.h: Base implementation for

several isXXX methods that rely on the object roleValue.
(WebCore::AXCoreObject::isImageMap const):
(WebCore::AXCoreObject::isWebArea const):
(WebCore::AXCoreObject::isCheckbox const):
(WebCore::AXCoreObject::isRadioButton const):
(WebCore::AXCoreObject::isListBox const):
(WebCore::AXCoreObject::isSpinButton const):
(WebCore::AXCoreObject::isSwitch const):
(WebCore::AXCoreObject::isToggleButton const):
(WebCore::AXCoreObject::isTabList const):
(WebCore::AXCoreObject::isTabItem const):
(WebCore::AXCoreObject::isRadioGroup const):
(WebCore::AXCoreObject::isComboBox const):
(WebCore::AXCoreObject::isTree const):
(WebCore::AXCoreObject::isTreeGrid const):
(WebCore::AXCoreObject::isTreeItem const):
(WebCore::AXCoreObject::isScrollbar const):
(WebCore::AXCoreObject::isListItem const):
(WebCore::AXCoreObject::isCheckboxOrRadio const):
(WebCore::AXCoreObject::isScrollView const):
(WebCore::AXCoreObject::isCanvas const):
(WebCore::AXCoreObject::isPopUpButton const):
(WebCore::AXCoreObject::isColorWell const):
(WebCore::AXCoreObject::isSplitter const):
(WebCore::AXCoreObject::isToolbar const):
(WebCore::AXCoreObject::isSummary const):

  • accessibility/AccessibilityRenderObject.cpp:

(WebCore::AccessibilityRenderObject::accessKey const):
(WebCore::AccessibilityRenderObject::actionVerb const):

  • accessibility/AccessibilityRenderObject.h:
  • accessibility/AccessibilitySpinButton.h:
  • accessibility/isolatedtree/AXIsolatedTree.cpp:

(WebCore::AXIsolatedTree::setRootNode):
(WebCore::AXIsolatedTree::setRoot): Renamed setRootNode.

  • accessibility/isolatedtree/AXIsolatedTree.h:
  • accessibility/isolatedtree/AXIsolatedTreeNode.cpp: Implementation of

around 200 methods in the AXIsolatedObject class. The methods that are
pending, have a stub implemetation with an ASSERT_NOT_REACHED.
(WebCore::AXIsolatedObject::AXIsolatedObject):
(WebCore::AXIsolatedObject::create):
(WebCore::AXIsolatedObject::initializeAttributeData):
(WebCore::AXIsolatedObject::setMathscripts):
(WebCore::AXIsolatedObject::setObjectVectorProperty):
(WebCore::AXIsolatedObject::isDetached const):
(WebCore::AXIsolatedObject::isDetachedFromParent):
(WebCore::AXIsolatedObject::accessibilityText const):
(WebCore::AXIsolatedObject::classList const):
(WebCore::AXIsolatedObject::sessionID const):
(WebCore::AXIsolatedObject::documentURI const):
(WebCore::AXIsolatedObject::preventKeyboardDOMEventDispatch const):
(WebCore::AXIsolatedObject::documentEncoding const):
(WebCore::AXIsolatedObject::insertMathPairs):
(WebCore::AXIsolatedObject::mathPrescripts):
(WebCore::AXIsolatedObject::mathPostscripts):
(WebCore::AXIsolatedObject::scrollBar):
(WebCore::AXIsolatedObject::colorValue const):
(WebCore::AXIsolatedObject::intPointAttributeValue const):
(WebCore::AXIsolatedObject::vectorAttributeValue const):
(WebCore::AXIsolatedObject::optionSetAttributeValue const):
(WebCore::AXIsolatedObject::uint64AttributeValue const):
(WebCore::AXIsolatedObject::urlAttributeValue const):
(WebCore::AXIsolatedObject::colorAttributeValue const):
(WebCore::AXIsolatedObject::floatAttributeValue const):
(WebCore::AXIsolatedObject::fillChildrenVectorForProperty const):
(WebCore::AXIsolatedObject::replaceTextInRange):
(WebCore::AXIsolatedObject::insertText):
(WebCore::AXIsolatedObject::press):
(WebCore::AXIsolatedObject::performDefaultAction):
(WebCore::AXIsolatedObject::isAccessibilityObject const):
(WebCore::AXIsolatedObject::isAccessibilityNodeObject const):
(WebCore::AXIsolatedObject::isAccessibilityRenderObject const):
(WebCore::AXIsolatedObject::isAccessibilityScrollbar const):
(WebCore::AXIsolatedObject::isAccessibilityScrollView const):
(WebCore::AXIsolatedObject::isAccessibilitySVGRoot const):
(WebCore::AXIsolatedObject::isAccessibilitySVGElement const):
(WebCore::AXIsolatedObject::containsText const):
(WebCore::AXIsolatedObject::isAttachmentElement const):
(WebCore::AXIsolatedObject::isNativeImage const):
(WebCore::AXIsolatedObject::isImageButton const):
(WebCore::AXIsolatedObject::isContainedByPasswordField const):
(WebCore::AXIsolatedObject::passwordFieldOrContainingPasswordField):
(WebCore::AXIsolatedObject::isNativeTextControl const):
(WebCore::AXIsolatedObject::isNativeListBox const):
(WebCore::AXIsolatedObject::isListBoxOption const):
(WebCore::AXIsolatedObject::isSliderThumb const):
(WebCore::AXIsolatedObject::isInputSlider const):
(WebCore::AXIsolatedObject::isLabel const):
(WebCore::AXIsolatedObject::isDataTable const):
(WebCore::AXIsolatedObject::isImageMapLink const):
(WebCore::AXIsolatedObject::isNativeSpinButton const):
(WebCore::AXIsolatedObject::isSpinButtonPart const):
(WebCore::AXIsolatedObject::isMockObject const):
(WebCore::AXIsolatedObject::isMediaObject const):
(WebCore::AXIsolatedObject::isARIATextControl const):
(WebCore::AXIsolatedObject::isNonNativeTextControl const):
(WebCore::AXIsolatedObject::isBlockquote const):
(WebCore::AXIsolatedObject::isLandmark const):
(WebCore::AXIsolatedObject::isFigureElement const):
(WebCore::AXIsolatedObject::isKeyboardFocusable const):
(WebCore::AXIsolatedObject::isHovered const):
(WebCore::AXIsolatedObject::isIndeterminate const):
(WebCore::AXIsolatedObject::isLoaded const):
(WebCore::AXIsolatedObject::isOnScreen const):
(WebCore::AXIsolatedObject::isOffScreen const):
(WebCore::AXIsolatedObject::isPressed const):
(WebCore::AXIsolatedObject::isUnvisited const):
(WebCore::AXIsolatedObject::isLinked const):
(WebCore::AXIsolatedObject::isVisible const):
(WebCore::AXIsolatedObject::isCollapsed const):
(WebCore::AXIsolatedObject::isSelectedOptionActive const):
(WebCore::AXIsolatedObject::hasBoldFont const):
(WebCore::AXIsolatedObject::hasItalicFont const):
(WebCore::AXIsolatedObject::hasMisspelling const):
(WebCore::AXIsolatedObject::hasPlainText const):
(WebCore::AXIsolatedObject::hasSameFont const):
(WebCore::AXIsolatedObject::hasSameFontColor const):
(WebCore::AXIsolatedObject::hasSameStyle const):
(WebCore::AXIsolatedObject::isStaticText const):
(WebCore::AXIsolatedObject::hasUnderline const):
(WebCore::AXIsolatedObject::hasHighlighting const):
(WebCore::AXIsolatedObject::element const):
(WebCore::AXIsolatedObject::node const):
(WebCore::AXIsolatedObject::renderer const):
(WebCore::AXIsolatedObject::defaultObjectInclusion const):
(WebCore::AXIsolatedObject::accessibilityIsIgnoredByDefault const):
(WebCore::AXIsolatedObject::stepValueForRange const):
(WebCore::AXIsolatedObject::selectedListItem):
(WebCore::AXIsolatedObject::ariaActiveDescendantReferencingElements const):
(WebCore::AXIsolatedObject::ariaControlsReferencingElements const):
(WebCore::AXIsolatedObject::ariaDescribedByElements const):
(WebCore::AXIsolatedObject::ariaDescribedByReferencingElements const):
(WebCore::AXIsolatedObject::ariaDetailsReferencingElements const):
(WebCore::AXIsolatedObject::ariaErrorMessageReferencingElements const):
(WebCore::AXIsolatedObject::ariaFlowToReferencingElements const):
(WebCore::AXIsolatedObject::ariaLabelledByElements const):
(WebCore::AXIsolatedObject::ariaLabelledByReferencingElements const):
(WebCore::AXIsolatedObject::ariaOwnsReferencingElements const):
(WebCore::AXIsolatedObject::hasDatalist const):
(WebCore::AXIsolatedObject::supportsHasPopup const):
(WebCore::AXIsolatedObject::supportsPressed const):
(WebCore::AXIsolatedObject::supportsChecked const):
(WebCore::AXIsolatedObject::ignoredFromModalPresence const):
(WebCore::AXIsolatedObject::isModalDescendant const):
(WebCore::AXIsolatedObject::isModalNode const):
(WebCore::AXIsolatedObject::elementAccessibilityHitTest const):
(WebCore::AXIsolatedObject::firstChild const):
(WebCore::AXIsolatedObject::lastChild const):
(WebCore::AXIsolatedObject::previousSibling const):
(WebCore::AXIsolatedObject::nextSibling const):
(WebCore::AXIsolatedObject::nextSiblingUnignored const):
(WebCore::AXIsolatedObject::previousSiblingUnignored const):
(WebCore::AXIsolatedObject::parentObjectIfExists const):
(WebCore::AXIsolatedObject::isDescendantOfBarrenParent const):
(WebCore::AXIsolatedObject::isDescendantOfRole const):
(WebCore::AXIsolatedObject::observableObject const):
(WebCore::AXIsolatedObject::correspondingLabelForControlElement const):
(WebCore::AXIsolatedObject::correspondingControlForLabelElement const):
(WebCore::AXIsolatedObject::isPresentationalChildOfAriaRole const):
(WebCore::AXIsolatedObject::ariaRoleHasPresentationalChildren const):
(WebCore::AXIsolatedObject::inheritsPresentationalRole const):
(WebCore::AXIsolatedObject::setAccessibleName):
(WebCore::AXIsolatedObject::hasAttributesRequiredForInclusion const):
(WebCore::AXIsolatedObject::accessibilityDescription const):
(WebCore::AXIsolatedObject::title const):
(WebCore::AXIsolatedObject::helpText const):
(WebCore::AXIsolatedObject::isARIAStaticText const):
(WebCore::AXIsolatedObject::stringValue const):
(WebCore::AXIsolatedObject::text const):
(WebCore::AXIsolatedObject::ariaLabeledByAttribute const):
(WebCore::AXIsolatedObject::ariaDescribedByAttribute const):
(WebCore::AXIsolatedObject::accessibleNameDerivesFromContent const):
(WebCore::AXIsolatedObject::elementsFromAttribute const):
(WebCore::AXIsolatedObject::axObjectCache const):
(WebCore::AXIsolatedObject::anchorElement const):
(WebCore::AXIsolatedObject::actionElement const):
(WebCore::AXIsolatedObject::elementPath const):
(WebCore::AXIsolatedObject::supportsPath const):
(WebCore::AXIsolatedObject::textIteratorBehaviorForTextRange const):
(WebCore::AXIsolatedObject::widget const):
(WebCore::AXIsolatedObject::widgetForAttachmentView const):
(WebCore::AXIsolatedObject::page const):
(WebCore::AXIsolatedObject::document const):
(WebCore::AXIsolatedObject::documentFrameView const):
(WebCore::AXIsolatedObject::frame const):
(WebCore::AXIsolatedObject::mainFrame const):
(WebCore::AXIsolatedObject::topDocument const):
(WebCore::AXIsolatedObject::scrollViewAncestor const):
(WebCore::AXIsolatedObject::childrenChanged):
(WebCore::AXIsolatedObject::textChanged):
(WebCore::AXIsolatedObject::updateAccessibilityRole):
(WebCore::AXIsolatedObject::addChildren):
(WebCore::AXIsolatedObject::addChild):
(WebCore::AXIsolatedObject::insertChild):
(WebCore::AXIsolatedObject::shouldIgnoreAttributeRole const):
(WebCore::AXIsolatedObject::canHaveChildren const):
(WebCore::AXIsolatedObject::hasChildren const):
(WebCore::AXIsolatedObject::setNeedsToUpdateChildren):
(WebCore::AXIsolatedObject::setNeedsToUpdateSubtree):
(WebCore::AXIsolatedObject::clearChildren):
(WebCore::AXIsolatedObject::needsToUpdateChildren const):
(WebCore::AXIsolatedObject::detachFromParent):
(WebCore::AXIsolatedObject::shouldFocusActiveDescendant const):
(WebCore::AXIsolatedObject::activeDescendant const):
(WebCore::AXIsolatedObject::handleActiveDescendantChanged):
(WebCore::AXIsolatedObject::handleAriaExpandedChanged):
(WebCore::AXIsolatedObject::isDescendantOfObject const):
(WebCore::AXIsolatedObject::isAncestorOfObject const):
(WebCore::AXIsolatedObject::firstAnonymousBlockChild const):
(WebCore::AXIsolatedObject::hasAttribute const):
(WebCore::AXIsolatedObject::getAttribute const):
(WebCore::AXIsolatedObject::hasTagName const):
(WebCore::AXIsolatedObject::stringValueForMSAA const):
(WebCore::AXIsolatedObject::stringRoleForMSAA const):
(WebCore::AXIsolatedObject::nameForMSAA const):
(WebCore::AXIsolatedObject::descriptionForMSAA const):
(WebCore::AXIsolatedObject::roleValueForMSAA const):
(WebCore::AXIsolatedObject::passwordFieldValue const):
(WebCore::AXIsolatedObject::liveRegionAncestor const):
(WebCore::AXIsolatedObject::hasContentEditableAttributeSet const):
(WebCore::AXIsolatedObject::supportsReadOnly const):
(WebCore::AXIsolatedObject::supportsAutoComplete const):
(WebCore::AXIsolatedObject::supportsARIAAttributes const):
(WebCore::AXIsolatedObject::scrollByPage const):
(WebCore::AXIsolatedObject::scrollPosition const):
(WebCore::AXIsolatedObject::scrollContentsSize const):
(WebCore::AXIsolatedObject::scrollVisibleContentRect const):
(WebCore::AXIsolatedObject::scrollToMakeVisible const):
(WebCore::AXIsolatedObject::lastKnownIsIgnoredValue):
(WebCore::AXIsolatedObject::setLastKnownIsIgnoredValue):
(WebCore::AXIsolatedObject::notifyIfIgnoredValueChanged):
(WebCore::AXIsolatedObject::isMathScriptObject const):
(WebCore::AXIsolatedObject::isMathMultiscriptObject const):
(WebCore::AXIsolatedObject::isAXHidden const):
(WebCore::AXIsolatedObject::isDOMHidden const):
(WebCore::AXIsolatedObject::isHidden const):
(WebCore::AXIsolatedObject::overrideAttachmentParent):
(WebCore::AXIsolatedObject::accessibilityIgnoreAttachment const):
(WebCore::AXIsolatedObject::accessibilityPlatformIncludesObject const):
(WebCore::AXIsolatedObject::hasApplePDFAnnotationAttribute const):
(WebCore::AXIsolatedObject::ancestorAccessibilityScrollView const):
(WebCore::AXIsolatedObject::setIsIgnoredFromParentData):
(WebCore::AXIsolatedObject::clearIsIgnoredFromParentData):
(WebCore::AXIsolatedObject::setIsIgnoredFromParentDataForChild):

  • accessibility/isolatedtree/AXIsolatedTreeNode.h:
  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm: Added

dispatching to the main thread some of the methods that cannot be run
in the secondary thread.
(performAccessibilityFunctionOnMainThread):
(retrieveAccessibilityValueFromMainThread):
(-[WebAccessibilityObjectWrapper attachmentView]):
(-[WebAccessibilityObjectWrapper screenToContents:]):
(-[WebAccessibilityObjectWrapper renderWidgetChildren]):
(-[WebAccessibilityObjectWrapper remoteAccessibilityParentObject]):
(-[WebAccessibilityObjectWrapper associatedPluginParent]):
(-[WebAccessibilityObjectWrapper subrole]):
(-[WebAccessibilityObjectWrapper scrollViewParent]):
(-[WebAccessibilityObjectWrapper windowElement:]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
(-[WebAccessibilityObjectWrapper ALLOW_DEPRECATED_IMPLEMENTATIONS_END]):
(-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
(-[WebAccessibilityObjectWrapper _accessibilityShowContextMenu]):
(-[WebAccessibilityObjectWrapper _convertToNSRange:]):
(-[WebAccessibilityObjectWrapper _textMarkerForIndex:]):

LayoutTests:

The AXStart/EndTextMarker attributes were being computed for
AccessibilityObjects that had a renderer object. With this change,
AXStart/EndTextMarker are computed for all AccessibilityObjects. Thus
the expected output for the following tests changed from null value for
these attributes to valid object values.

  • accessibility/image-map2-expected.txt:
  • accessibility/mac/document-links-expected.txt:
  • accessibility/table-attributes-expected.txt:
  • accessibility/table-sections-expected.txt:
12:16 PM Changeset in webkit [253260] by mark.lam@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Remove invalid assertion in FTL's allocateJSArray().
https://bugs.webkit.org/show_bug.cgi?id=204987
<rdar://problem/57280725>

Reviewed by Saam Barati.

The assertion (in the compiler thread) does not take into account that the mutator
may be in the process of transiting to HavingABadTime. As a result, the assertion
may fail intermittently. This patch fixes this issue by removing this bad
assertion.

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::allocateJSArray):

11:53 AM Changeset in webkit [253259] by Alan Bujtas
  • 7 edits in trunk/Source/WebCore

[LFC][IFC] Initialize InlineLayoutUnit variables to 0
https://bugs.webkit.org/show_bug.cgi?id=204989

Reviewed by Antti Koivisto.

This is in preparation for using float based types in IFC. See webkit.org/b/204986 for more info.

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computedIntrinsicWidthForConstraint const):

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::wordBreakingBehavior const):

  • layout/inlineformatting/InlineLineBreaker.h:
  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::initialize):
(WebCore::Layout::LineBuilder::alignContentVertically):
(WebCore::Layout::LineBuilder::justifyRuns const):
(WebCore::Layout::LineBuilder::TrimmableContent::append):
(WebCore::Layout::LineBuilder::TrimmableContent::trim):
(WebCore::Layout::LineBuilder::TrimmableContent::trimTrailingRun):

  • layout/inlineformatting/InlineLineBuilder.h:
  • layout/inlineformatting/text/TextUtil.h:
11:04 AM Changeset in webkit [253258] by Alan Bujtas
  • 7 edits
    1 add in trunk/Source/WebCore

[LFC][IFC] Introduce InlineRect
https://bugs.webkit.org/show_bug.cgi?id=204988
<rdar://problem/57729049>

Reviewed by Antti Koivisto.

This is in preparation for using float based types in IFC. See webkit.org/b/204986 for more info.

  • WebCore.xcodeproj/project.pbxproj:
  • layout/LayoutUnits.h:
  • layout/displaytree/DisplayInlineRect.h: Added.

(WebCore::Display::InlineRect::expandHorizontally):
(WebCore::Display::InlineRect::expandVertically):
(WebCore::Display::InlineRect::invalidateTop):
(WebCore::Display::InlineRect::invalidateLeft):
(WebCore::Display::InlineRect::invalidateWidth):
(WebCore::Display::InlineRect::invalidateHeight):
(WebCore::Display::InlineRect::hasValidPosition const):
(WebCore::Display::InlineRect::hasValidSize const):
(WebCore::Display::InlineRect::hasValidGeometry const):
(WebCore::Display::InlineRect::InlineRect):
(WebCore::Display::InlineRect::invalidatePosition):
(WebCore::Display::InlineRect::setHasValidPosition):
(WebCore::Display::InlineRect::setHasValidSize):
(WebCore::Display::InlineRect::top const):
(WebCore::Display::InlineRect::left const):
(WebCore::Display::InlineRect::bottom const):
(WebCore::Display::InlineRect::right const):
(WebCore::Display::InlineRect::topLeft const):
(WebCore::Display::InlineRect::size const):
(WebCore::Display::InlineRect::width const):
(WebCore::Display::InlineRect::height const):
(WebCore::Display::InlineRect::setTopLeft):
(WebCore::Display::InlineRect::setTop):
(WebCore::Display::InlineRect::setLeft):
(WebCore::Display::InlineRect::setWidth):
(WebCore::Display::InlineRect::setHeight):
(WebCore::Display::InlineRect::moveHorizontally):
(WebCore::Display::InlineRect::moveVertically):
(WebCore::Display::InlineRect::expand):
(WebCore::Display::InlineRect::operator InlineLayoutRect const):

  • layout/displaytree/DisplayLineBox.h:

(WebCore::Display::LineBox::LineBox):

  • layout/displaytree/DisplayRun.h:

(WebCore::Display::Run::logicalRect const):
(WebCore::Display::Run::setLogicalLeft):
(WebCore::Display::Run::Run):
(WebCore::Display::Run::setLogicalRight): Deleted.

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::ContinousContent::close):
(WebCore::Layout::LineBuilder::Run::Run):
(WebCore::Layout::LineBuilder::initialize):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::Run::logicalRect const):

10:56 AM Changeset in webkit [253257] by mark.lam@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Build fix for: The compiler thread should not adjust Identifier refCounts.
https://bugs.webkit.org/show_bug.cgi?id=204919
<rdar://problem/57426861>

Not reviewed.

  • bytecode/GetByStatus.cpp:

(JSC::GetByStatus::computeFor):

10:46 AM Changeset in webkit [253256] by david_quesada@apple.com
  • 6 edits in trunk/Source/WebKit

REGRESSION(r253231): Debug assertion failures under ~WebDeviceOrientationUpdateProvider(Proxy)
https://bugs.webkit.org/show_bug.cgi?id=204977
rdar://problem/57724251

Reviewed by Per Arne Vollan.

In the UI process, have the WebPageProxy swap out its WebDeviceOrientationUpdateProviderProxy whenever
it connects to a new process, instead of creating one on construction and holding onto it for the rest
of the WebPageProxy lifetime. The …UpdateProviderProxy assumes that its page will have the same ID
at the time of registering as a message receiver and later unregistering, but the page ID could change
if the WebPageProxy swaps web processes. Using a new instance per web page ID ensures that the
updater is always able to successfully remove itself as a message receiver when deallocating.

In the Web process, ~WebDeviceOrientationUpdateProvider() should remove itself as a message receiver
specifically for its page ID, rather than as a global message receiver.

No new tests -- existing tests (at least the ProcessSwap API tests) revealed the regression.

  • UIProcess/WebPageProxy.cpp:

(WebKit::m_tryCloseTimeoutTimer):
(WebKit::WebPageProxy::didAttachToRunningProcess):
(WebKit::WebPageProxy::resetState):
(WebKit::m_webDeviceOrientationUpdateProviderProxy): Deleted.

  • UIProcess/WebPageProxy.h:
  • UIProcess/ios/WebDeviceOrientationUpdateProviderProxy.h:
  • WebProcess/WebCoreSupport/WebDeviceOrientationUpdateProvider.cpp:

(WebKit::WebDeviceOrientationUpdateProvider::WebDeviceOrientationUpdateProvider):
(WebKit::WebDeviceOrientationUpdateProvider::~WebDeviceOrientationUpdateProvider):

  • WebProcess/WebCoreSupport/WebDeviceOrientationUpdateProvider.h:
10:18 AM Changeset in webkit [253255] by Alan Bujtas
  • 15 edits in trunk/Source/WebCore

[LFC][IFC] Introduce InlineLayoutUnit
https://bugs.webkit.org/show_bug.cgi?id=204986
<rdar://problem/57728333>

Reviewed by Antti Koivisto.

While IFC uses LayoutUnit type solely to compute inline geometry, complex line layout (CLL) has
adopted several different types over time (int, float and LayoutUnit). These types all have different precisions.
In order to match CLL's output (inline tree geometry) IFC needs to use a type that has
roughly the same precision as what CLL uses.
LayoutUnit currently does not have high enough precision (1/64) to produce matching results.
This patch introduces InlineLayoutUnit. It is going to be mapped to 'float' for now (in a subsequent patch).
It helps to keep one uniform type across the IFC codebase and we could also just re-map it to something
more appropriate in the future.

  • layout/LayoutUnits.h:
  • layout/displaytree/DisplayLineBox.h:

(WebCore::Display::LineBox::Baseline::height const):
(WebCore::Display::LineBox::logicalLeft const):
(WebCore::Display::LineBox::logicalRight const):
(WebCore::Display::LineBox::logicalTop const):
(WebCore::Display::LineBox::logicalBottom const):
(WebCore::Display::LineBox::logicalWidth const):
(WebCore::Display::LineBox::logicalHeight const):
(WebCore::Display::LineBox::setLogicalHeight):
(WebCore::Display::LineBox::setLogicalWidth):
(WebCore::Display::LineBox::moveHorizontally):
(WebCore::Display::LineBox::expandHorizontally):
(WebCore::Display::LineBox::shrinkHorizontally):
(WebCore::Display::LineBox::expandVertically):
(WebCore::Display::LineBox::shrinkVertically):
(WebCore::Display::LineBox::LineBox):
(WebCore::Display::LineBox::setLogicalHeightIfGreater):
(WebCore::Display::LineBox::setBaselineOffsetIfGreater):
(WebCore::Display::LineBox::setAscentIfGreater):
(WebCore::Display::LineBox::setDescentIfGreater):
(WebCore::Display::LineBox::baselineOffset const):
(WebCore::Display::LineBox::Baseline::Baseline):
(WebCore::Display::LineBox::Baseline::setAscent):
(WebCore::Display::LineBox::Baseline::setDescent):
(WebCore::Display::LineBox::Baseline::ascent const):
(WebCore::Display::LineBox::Baseline::descent const):

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computedIntrinsicWidthConstraints):
(WebCore::Layout::InlineFormattingContext::computedIntrinsicWidthForConstraint const):
(WebCore::Layout::InlineFormattingContext::constraintsForLine):

  • layout/inlineformatting/InlineFormattingContext.h:
  • layout/inlineformatting/InlineFormattingContextQuirks.cpp:

(WebCore::Layout::InlineFormattingContext::Quirks::lineHeightConstraints const):

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::shouldWrapFloatBox):
(WebCore::Layout::LineBreaker::wordBreakingBehavior const):
(WebCore::Layout::LineBreaker::tryBreakingTextRun const):
(WebCore::Layout::LineBreaker::Content::append):

  • layout/inlineformatting/InlineLineBreaker.h:

(WebCore::Layout::LineBreaker::Content::width const):
(WebCore::Layout::LineBreaker::Content::nonTrimmableWidth const):

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::Run::setComputedHorizontalExpansion):
(WebCore::Layout::LineBuilder::initialize):
(WebCore::Layout::LineBuilder::alignContentVertically):
(WebCore::Layout::LineBuilder::justifyRuns const):
(WebCore::Layout::LineBuilder::alignContentHorizontally const):
(WebCore::Layout::LineBuilder::moveLogicalLeft):
(WebCore::Layout::LineBuilder::moveLogicalRight):
(WebCore::Layout::LineBuilder::append):
(WebCore::Layout::LineBuilder::appendNonBreakableSpace):
(WebCore::Layout::LineBuilder::appendInlineContainerStart):
(WebCore::Layout::LineBuilder::appendInlineContainerEnd):
(WebCore::Layout::LineBuilder::appendTextContent):
(WebCore::Layout::LineBuilder::appendNonReplacedInlineBox):
(WebCore::Layout::LineBuilder::appendReplacedInlineBox):
(WebCore::Layout::LineBuilder::runContentHeight const):
(WebCore::Layout::LineBuilder::halfLeadingMetrics):
(WebCore::Layout::LineBuilder::TrimmableContent::append):
(WebCore::Layout::LineBuilder::TrimmableContent::trim):
(WebCore::Layout::LineBuilder::TrimmableContent::trimTrailingRun):
(WebCore::Layout::LineBuilder::InlineItemRun::InlineItemRun):
(WebCore::Layout::LineBuilder::InlineItemRun::trailingLetterSpacing const):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::availableWidth const):
(WebCore::Layout::LineBuilder::trailingTrimmableWidth const):
(WebCore::Layout::LineBuilder::Run::adjustLogicalTop):
(WebCore::Layout::LineBuilder::Run::moveHorizontally):
(WebCore::Layout::LineBuilder::Run::moveVertically):
(WebCore::Layout::LineBuilder::Run::setLogicalHeight):
(WebCore::Layout::LineBuilder::logicalTop const):
(WebCore::Layout::LineBuilder::logicalBottom const):
(WebCore::Layout::LineBuilder::logicalLeft const):
(WebCore::Layout::LineBuilder::logicalRight const):
(WebCore::Layout::LineBuilder::logicalWidth const):
(WebCore::Layout::LineBuilder::logicalHeight const):
(WebCore::Layout::LineBuilder::contentLogicalWidth const):
(WebCore::Layout::LineBuilder::contentLogicalRight const):
(WebCore::Layout::LineBuilder::baselineOffset const):
(WebCore::Layout::LineBuilder::InlineItemRun::logicalLeft const):
(WebCore::Layout::LineBuilder::InlineItemRun::logicalWidth const):
(WebCore::Layout::LineBuilder::InlineItemRun::moveHorizontally):
(WebCore::Layout::LineBuilder::TrimmableContent::width const):

  • layout/inlineformatting/InlineTextItem.cpp:

(WebCore::Layout::InlineTextItem::createAndAppendTextItems):
(WebCore::Layout::InlineTextItem::createWhitespaceItem):
(WebCore::Layout::InlineTextItem::createNonWhitespaceItem):
(WebCore::Layout::InlineTextItem::InlineTextItem):

  • layout/inlineformatting/InlineTextItem.h:

(WebCore::Layout::InlineTextItem::width const):

  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::inlineItemWidth):

  • layout/inlineformatting/text/TextUtil.cpp:

(WebCore::Layout::TextUtil::width):
(WebCore::Layout::TextUtil::fixedPitchWidth):
(WebCore::Layout::TextUtil::split):

  • layout/inlineformatting/text/TextUtil.h:
7:21 AM Changeset in webkit [253254] by Antti Koivisto
  • 10 edits
    1 move
    1 add in trunk/Source/WebCore

[LFC][IFC] Move LineBox to Display namespace
https://bugs.webkit.org/show_bug.cgi?id=204984

Reviewed by Zalan Bujtas.

It is a display type, like Display::Run.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/displaytree/DisplayInlineContent.cpp: Added.

Also added a cpp for Display::InlineContent.

(WebCore::Display:: const):

  • layout/displaytree/DisplayInlineContent.h:

(WebCore::Display::InlineContent::lineBoxForRun const):
(WebCore::Display:: const): Deleted.

  • layout/displaytree/DisplayLineBox.h: Renamed from Source/WebCore/layout/inlineformatting/InlineLineBox.h.

(WebCore::Display::LineBox::LineBox):

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::setDisplayBoxesForLine):

  • layout/inlineformatting/InlineFormattingContextQuirks.cpp:

(WebCore::Layout::InlineFormattingContext::Quirks::lineHeightConstraints const):

  • layout/inlineformatting/InlineFormattingState.h:
  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::initialize):
(WebCore::Layout::LineBuilder::halfLeadingMetrics):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::lineBox const):

  • layout/inlineformatting/LineLayoutContext.h:
6:49 AM Changeset in webkit [253253] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Add support for breaking at previous breaking opportunities when the overflown content is unbreakable
https://bugs.webkit.org/show_bug.cgi?id=204985
<rdar://problem/57727436>

Reviewed by Antti Koivisto.

<span>first</span><span style="word-break: break-all">second</span><span>third</span

In case of multiple runs in one commit content [firstsecondthrid], if the overflown run [thrid] does not have
a breaking opportunity, we need to backtrack the last breakable run [second] and break right there. ->

"firstsecond
third"

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::isContentWrappingAllowed):
(WebCore::Layout::LineBreaker::breakingContextForInlineContent):
(WebCore::Layout::LineBreaker::wordBreakingBehavior const):

6:02 AM Changeset in webkit [253252] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Fix css1/formatting_model/floating_elements.html
https://bugs.webkit.org/show_bug.cgi?id=204983
<rdar://problem/57727197>

Reviewed by Antti Koivisto.

Adjacent non-whitespace inline items are guaranteed to be on commit boundary when they both belong
to the same layout box (<div>text-content</div> [text-][content] vs <div>textcontent</div> [textcontent]).

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::Content::isAtContentBoundary):

5:56 AM Changeset in webkit [253251] by Antti Koivisto
  • 5 edits in trunk/Source/WebCore

[LFC][Integration] Layout test assert and crash fixes
https://bugs.webkit.org/show_bug.cgi?id=204982

Reviewed by Zalan Bujtas.

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::firstLineBaseline const):
(WebCore::LayoutIntegration::LineLayout::lastLineBaseline const):
(WebCore::LayoutIntegration::LineLayout::textBoxesFor const):

Don't 0-initialize Optional.

  • layout/integration/LayoutIntegrationLineLayout.h:
  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::createLayoutBox):

Remember to add line break renderer to the renderer->layout box map.

  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::markLinesDirtyInBlockRange):

Invalidate layout path with LFC.

(WebCore::RenderBlockFlow::firstLineBaseline const):
(WebCore::RenderBlockFlow::inlineBlockBaseline const):

Call LFC baseline functions.

5:46 AM Changeset in webkit [253250] by jh718.park@samsung.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed. Remove the build warning below since r250009.
warning: comparison between signed and unsigned integer expressions [-Wsign-compare]

This patch typecasts the "maybe signed" one as unsigned, which is the
same what the compilers would do, but making the typecast explicit
so that the warning go away.

  • b3/air/testair.cpp:
5:30 AM Changeset in webkit [253249] by timothy_horton@apple.com
  • 29 edits in trunk/Source

Implement encoding for DrawImage and DrawRoundedRect display list items
https://bugs.webkit.org/show_bug.cgi?id=204881

Reviewed by Simon Fraser.

Source/WebCore:

Make InterpolationQuality an enum class.
Make ImagePaintingOptions and all of its children encodable.
Make DrawImage and DrawRoundedRect encodable.
Add ImageHandle, which right now just wraps WebCore::Image, but
later could carry identifiers. This allows us to implement image encoding
in WebKit code, which can then use ShareableBitmap to A) decode the image
in the Web Content process and B) use shared memory to transmit the
decoded image data to the GPU process.

  • html/CanvasBase.cpp:
  • html/ImageBitmap.cpp:

(WebCore::interpolationQualityForResizeQuality):

  • html/canvas/CanvasRenderingContext2DBase.cpp:

(WebCore::smoothingToInterpolationQuality):
(WebCore::CanvasRenderingContext2DBase::setImageSmoothingEnabled):

  • platform/graphics/DecodingOptions.h:
  • platform/graphics/GraphicsContext.h:

(WebCore::InterpolationQualityMaintainer::InterpolationQualityMaintainer):

  • platform/graphics/GraphicsTypes.h:
  • platform/graphics/ImageOrientation.h:
  • platform/graphics/ImagePaintingOptions.h:

(WebCore::ImagePaintingOptions::ImagePaintingOptions):
(WebCore::ImagePaintingOptions::encode const):
(WebCore::ImagePaintingOptions::decode):

  • platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:

(WebCore::MediaPlayerPrivateAVFoundationCF::paint):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:

(WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithImageGenerator):

  • platform/graphics/cairo/CairoOperations.cpp:

(WebCore::Cairo::drawSurface):

  • platform/graphics/cg/GraphicsContext3DCG.cpp:

(WebCore::GraphicsContext3D::paintToCanvas):

  • platform/graphics/cg/GraphicsContextCG.cpp:

(WebCore::convertInterpolationQuality):
(WebCore::GraphicsContext::setPlatformImageInterpolationQuality):

  • platform/graphics/displaylists/DisplayListItems.cpp:

(WebCore::DisplayList::FillRoundedRect::FillRoundedRect):

  • platform/graphics/displaylists/DisplayListItems.h:

(WebCore::DisplayList::DrawImage::encode const):
(WebCore::DisplayList::DrawImage::decode):
(WebCore::DisplayList::FillRoundedRect::create):
(WebCore::DisplayList::FillRoundedRect::encode const):
(WebCore::DisplayList::FillRoundedRect::decode):
(WebCore::DisplayList::Item::encode const):
(WebCore::DisplayList::Item::decode):
(WebCore::DisplayList::FillRoundedRect::FillRoundedRect): Deleted.

  • platform/graphics/ios/IconIOS.mm:

(WebCore::Icon::paint):

  • platform/graphics/texmap/BitmapTexture.cpp:

(WebCore::BitmapTexture::updateContents):

  • platform/graphics/win/GraphicsContextDirect2D.cpp:

(WebCore::GraphicsContext::setPlatformImageInterpolationQuality):

  • platform/ios/wak/WAKView.mm:

(toCGInterpolationQuality):

  • platform/mock/MockRealtimeVideoSource.cpp:

(WebCore::MockRealtimeVideoSource::imageBuffer const):

  • rendering/ImageQualityController.cpp:

(WebCore::ImageQualityController::interpolationQualityFromStyle):
(WebCore::ImageQualityController::chooseInterpolationQuality):

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::paintIntoRect):

Source/WebKit:

  • Shared/WebCoreArgumentCoders.cpp:

(IPC::ArgumentCoder<DisplayList::ImageHandle>::encode):
(IPC::ArgumentCoder<DisplayList::ImageHandle>::decode):

  • Shared/WebCoreArgumentCoders.h:

Source/WebKitLegacy/mac:

  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):

3:22 AM Changeset in webkit [253248] by timothy_horton@apple.com
  • 9 edits in trunk/Source/WebCore

macCatalyst: REGRESSION (r251320): WebKit-native media controls do not respond to hover or click
https://bugs.webkit.org/show_bug.cgi?id=204543
<rdar://problem/57208621>

Reviewed by Antoine Quint.

Adopt pointer events for media controls, in order to make them input-device agnostic.

  • Modules/modern-media-controls/controls/auto-hide-controller.js:

(AutoHideController):
(AutoHideController.prototype.set fadesWhileIdle):
(AutoHideController.prototype.handleEvent):
(AutoHideController.prototype._autoHideTimerFired):
Instead of tracking state in a single bit (_disableAutoHiding), keep track
of sets of pointers that are active, for hover and for actual touch/click.

  • Modules/modern-media-controls/controls/slider.js:

(Slider.prototype.handleEvent):
(Slider.prototype._handlePointerdownEvent):
(Slider.prototype._handlePointerupEvent):
(Slider.prototype._handleMousedownEvent): Deleted.
(Slider.prototype._handleTouchstartEvent): Deleted.
(Slider.prototype._handleMouseupEvent): Deleted.
(Slider.prototype._handleTouchendEvent): Deleted.
Adopt pointer events.

  • Modules/modern-media-controls/gesture-recognizers/gesture-recognizer.js:

(GestureRecognizer):
(GestureRecognizer.prototype.get numberOfTouches):
(GestureRecognizer.prototype.locationInElement):
(GestureRecognizer.prototype.locationInClient):
(GestureRecognizer.prototype.touchesBegan):
(GestureRecognizer.prototype.handleEvent):
(GestureRecognizer.prototype._updateBaseListeners):
(GestureRecognizer.prototype._removeTrackingListeners):
(GestureRecognizer.prototype._updateTargetTouches):
(GestureRecognizer.prototype.locationOfTouchInElement): Deleted.
Instead of keeping track of Touches, keep track of the currently-active set of PointerEvents.
We just store events by pointerId, and update them when they change, so we can
later retrieve e.g. points.
Remove locationOfTouchInElement which seems to not be used.

  • html/RangeInputType.cpp:
  • html/RangeInputType.h:
  • html/shadow/SliderThumbElement.cpp:

(WebCore::SliderThumbElement::dragFrom):
(WebCore::SliderThumbElement::defaultEventHandler):

  • html/shadow/SliderThumbElement.h:

Allow range inputs to accept mouse events everywhere.

  • WebCore.xcodeproj/project.pbxproj:

Add some missing files to the project.

2:00 AM Changeset in webkit [253247] by ysuzuki@apple.com
  • 12 edits in trunk/Source/JavaScriptCore

[JSC] Put JSWrapperObject derived classes in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204976

Reviewed by Mark Lam.

Put JSWrapperObject derived classes in IsoSubspace.

  1. StringObject
  2. NumberObject
  3. SymbolObject
  4. BigIntObject
  5. BooleanObject
  • runtime/BigIntObject.h:
  • runtime/BooleanObject.h:

(JSC::BooleanObject::subspaceFor):

  • runtime/BooleanPrototype.h:
  • runtime/JSWrapperObject.h:

(JSC::JSWrapperObject::subspaceFor):

  • runtime/NumberObject.h:

(JSC::NumberObject::subspaceFor):

  • runtime/NumberPrototype.h:
  • runtime/StringObject.h:

(JSC::StringObject::subspaceFor):

  • runtime/StringPrototype.h:
  • runtime/SymbolObject.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
1:28 AM Changeset in webkit [253246] by Devin Rousso
  • 8 edits in trunk/Source

Web Inspector: non-regex Local Overrides and Script Blackboxing shouldn't apply to scripts that just contain the URL
https://bugs.webkit.org/show_bug.cgi?id=204954

Reviewed by Joseph Pecoraro.

If isRegex is false, add ^ and $ to the beginning and end of the search string to
ensure that the search string is exactly matched, not just contained within the potentially
intercepted URL.

This doesn't actually change functionality because the Web Inspector frontend wouldn't
replace the network response for these containing matches, as the frontend JavaScript
already correctly performed this logic, and would therefore Network.interceptContinue.

Source/JavaScriptCore:

  • inspector/ContentSearchUtilities.h:
  • inspector/ContentSearchUtilities.cpp:

(Inspector::ContentSearchUtilities::escapeStringForRegularExpressionSource): Added.
(Inspector::ContentSearchUtilities::createRegularExpressionForSearchString): Added.
(Inspector::ContentSearchUtilities::searchInTextByLines):
(Inspector::ContentSearchUtilities::createSearchRegexSource): Deleted.
(Inspector::ContentSearchUtilities::createSearchRegex): Deleted.
Rename functions for clarity.

  • inspector/agents/InspectorDebuggerAgent.cpp:

(Inspector::InspectorDebuggerAgent::shouldBlackboxURL const):

Source/WebCore:

  • inspector/agents/InspectorNetworkAgent.cpp:

(WebCore::InspectorNetworkAgent::shouldIntercept):

  • inspector/agents/InspectorDOMAgent.cpp:

(WebCore::InspectorDOMDebuggerAgent::breakOnURLIfNeeded):

  • inspector/agents/InspectorPageAgent.cpp:

(WebCore::InspectorPageAgent::searchInResources):
Use renamed ContentSearchUtilities function.

12:42 AM Changeset in webkit [253245] by basuke.suzuki@sony.com
  • 2 edits in trunk/Source/bmalloc

[bmalloc] Decommit unused region in chunk metadata.
https://bugs.webkit.org/show_bug.cgi?id=204810

Reviewed by Yusuke Suzuki.

There is an unused memory region from just after Chunk object to next page border.
We can decommit those memory to kernel at the initialization of Chunk.

  • bmalloc/Heap.cpp:

(bmalloc::Heap::allocateSmallChunk):

Dec 6, 2019:

11:50 PM Changeset in webkit [253244] by zandobersek@gmail.com
  • 6 edits in trunk/Source

[GTK][WPE] Use bmalloc's memory footprint API for JSC heap growth management
https://bugs.webkit.org/show_bug.cgi?id=204576

Reviewed by Saam Barati.

Source/JavaScriptCore:

Use the new USE(BMALLOC_MEMORY_FOOTPRINT_API) build guard to enable
bmalloc-based JSC heap growth management on iOS family ports as well
as additionally the Linux-based ports, if the configuration allows it
(i.e. system malloc enforcement kept disabled).

  • heap/Heap.cpp:

(JSC::Heap::overCriticalMemoryThreshold):
(JSC::Heap::updateAllocationLimits):
(JSC::Heap::collectIfNecessaryOrDefer):

  • heap/Heap.h:

Initialize the two member variables and fix a typo in one of them.

  • runtime/Options.cpp:

(JSC::overrideDefaults):
Also guard two default overrides with the new flag.

Source/WTF:

Add the new USE_BMALLOC_MEMORY_FOOTPRINT_API, enabled for the iOS-family
ports and the Linux ports, as long as system malloc enforcement is
disabled and bmalloc is subsequently built and used. The flag is used in
JavaScriptCore to enable usage of bmalloc's memory footprint API for
JSC heap growth control.

  • wtf/Platform.h:
10:07 PM Changeset in webkit [253243] by mark.lam@apple.com
  • 14 edits
    1 add in trunk

The compiler thread should not adjust Identifier refCounts.
https://bugs.webkit.org/show_bug.cgi?id=204919
<rdar://problem/57426861>

Reviewed by Saam Barati.

JSTests:

  • stress/compiler-thread-should-not-ref-identifiers.js: Added.

Source/JavaScriptCore:

  1. Previously, in the compiler thread, we would get a Symbol uid via Symbol::privateName().uid(). Symbol::privateName() returns a copy of its PrivateName, which in turn results in ref'ing the underlying SymbolImpl. This results in a race between the mutator and compiler threads to adjust the SymbolImpl's refCount, which may result in corruption.

This patch fixes this by adding Symbol::uid() which return the underlying
SymbolImpl without ref'ing it.

  1. Previously, in the compiler thread, we also create Box<Identifier> via its copy constructor. The original Box<Identifier> is instantiated in the mutator. The Box<Identifier> refs its internal Data, which is ThreadSafeRefCounted and shared by all Box<Identifier> for the same underlying Identifier. This ensures that the compiler thread does not ref the underlying Identifier.

However, when the Box<Identifier> is destructed, it will also check if it holds
the last ref to its internal Data. If so, it will destruct its Data, and the
Identifier that it embeds. This results in the compiler thread trying to deref
the StringImpl referenced by the Identifier in a race against the mutator.

This patch fixes this by ensuring that for any Box<Identifier> instance used
by the compiler thread, we will register another instance in the DFG::Plan
m_identifiersKeptAliveForCleanUp list, and let the mutator destruct that
Box<Identifier> later in the mutator. This ensures that the compiler thread
will never see the last reference to a Box<Identifier>'s internal Data and
avoid the race.

  1. This patch also fixes the DFG::Worklist code to ensure that a DFG::Plan is always destructed in the mutator, even if the Plan was cancelled.

This, in turn, enables us to assert that the Plan is never destructed in the
compiler thread.

  • bytecode/GetByStatus.cpp:

(JSC::GetByStatus::computeFor):
(JSC::GetByStatus::computeForStubInfoWithoutExitSiteFeedback):

  • bytecode/GetByStatus.h:
  • debugger/Debugger.cpp:

(JSC::Debugger::detach):

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::parseGetById):
(JSC::DFG::ByteCodeParser::parseBlock):

  • dfg/DFGConstantFoldingPhase.cpp:

(JSC::DFG::ConstantFoldingPhase::foldConstants):

  • dfg/DFGPlan.cpp:

(JSC::DFG::Plan::~Plan):
(JSC::DFG::Plan::computeCompileTimes const):
(JSC::DFG::Plan::cancel):

  • dfg/DFGPlan.h:

(JSC::DFG::Plan::unnukedVM const):
(JSC::DFG::Plan::keepAliveIdentifier):
(JSC::DFG::Plan::nuke):
(JSC::DFG::Plan::unnuke):

  • dfg/DFGSafepoint.cpp:

(JSC::DFG::Safepoint::cancel):

  • dfg/DFGWorklist.cpp:

(JSC::DFG::Worklist::deleteCancelledPlansForVM):
(JSC::DFG::Worklist::removeAllReadyPlansForVM):
(JSC::DFG::Worklist::removeDeadPlans):
(JSC::DFG::Worklist::removeNonCompilingPlansForVM):

  • dfg/DFGWorklist.h:
  • runtime/Symbol.h:
10:06 PM Changeset in webkit [253242] by Devin Rousso
  • 67 edits in trunk

Web Inspector: Uncaught Exception: Missing node for given nodeId
https://bugs.webkit.org/show_bug.cgi?id=204519

Reviewed by Timothy Hatcher.

Source/WebInspectorUI:

When a DOM node is removed from the main DOM tree, the InspectorDOMAgent invalidates the
DOM.NodeId that was previously assigned to that DOM node, meaning that any future commands
sent by the frontend with that DOM.NodeId will fail.

Add logic to mark WI.DOMNode as being destroyed when this happens so the frontend can
decide to not invoke any commands with that DOM.NodeId.

Many functions have also switched to expecting a WI.DOMNode instead of a DOM.NodeId or
have been moved to WI.DOMNode.prototype in order to also be able to use destroyed.

This issue will eventually be mitigated by <https://webkit.org/b/189687>.

  • UserInterface/Models/DOMNode.js:

(WI.DOMNode):
(WI.DOMNode.prototype.get destroyed): Added.
(WI.DOMNode.prototype.get attached):
(WI.DOMNode.prototype.markDestroyed): Added.
(WI.DOMNode.prototype.setNodeName):
(WI.DOMNode.prototype.setNodeValue):
(WI.DOMNode.prototype.setAttribute):
(WI.DOMNode.prototype.setAttributeValue):
(WI.DOMNode.prototype.querySelector): Added.
(WI.DOMNode.prototype.querySelectorAll): Added.
(WI.DOMNode.prototype.highlight): Added.
(WI.DOMNode.prototype.getOuterHTML):
(WI.DOMNode.prototype.setOuterHTML):
(WI.DOMNode.prototype.removeNode):
(WI.DOMNode.prototype.getEventListeners):

  • UserInterface/Base/DOMUtilities.js:

(WI.bindInteractionsForNodeToElement):

  • UserInterface/Controllers/DOMManager.js:

(WI.DOMManager.buildHighlightConfig):
(WI.DOMManager.wrapClientCallback):
(WI.DOMManager.prototype._loadNodeAttributes):
(WI.DOMManager.prototype._setDocument):
(WI.DOMManager.prototype._unbind):
(WI.DOMManager.prototype.highlightDOMNodeList):
(WI.DOMManager.prototype.highlightSelector):
(WI.DOMManager.prototype.hideDOMNodeHighlight):
(WI.DOMManager.prototype.highlightDOMNodeForTwoSeconds):
(WI.DOMManager.prototype.set inspectModeEnabled):
(WI.DOMManager.prototype.setInspectedNode):
(WI.DOMManager.prototype.setEventListenerDisabled):
(WI.DOMManager.prototype._wrapClientCallback): Deleted.
(WI.DOMManager.prototype.querySelector): Deleted.
(WI.DOMManager.prototype.querySelectorAll): Deleted.
(WI.DOMManager.prototype.highlightDOMNode): Deleted.
(WI.DOMManager.prototype._buildHighlightConfig): Deleted.

  • UserInterface/Models/AuditTestCaseResult.js:

(WI.AuditTestCaseResult.async fromPayload):

  • UserInterface/Models/MediaTimelineRecord.js:

(WI.MediaTimelineRecord.async fromJSON):

  • UserInterface/Protocol/RemoteObject.js:

(WI.RemoteObject.resolveNode):

  • UserInterface/Views/BoxModelDetailsSectionRow.js:

(WI.BoxModelDetailsSectionRow.prototype._highlightDOMNode):

  • UserInterface/Views/CanvasOverviewContentView.js:

(WI.CanvasOverviewContentView.prototype._contentViewMouseEnter):

  • UserInterface/Views/CanvasTreeElement.js:

(WI.CanvasTreeElement.prototype._handleMouseOver):

  • UserInterface/Views/ContextMenuUtilities.js:

(WI.appendContextMenuItemsForDOMNode):

  • UserInterface/Views/DOMNodeDetailsSidebarPanel.js:

(WI.DOMNodeDetailsSidebarPanel.prototype.layout):

  • UserInterface/Views/DOMTreeContentView.js:

(WI.DOMTreeContentView.prototype._domTreeSelectionDidChange):

  • UserInterface/Views/DOMTreeElement.js:

(WI.DOMTreeElement.prototype.get editable):
(WI.DOMTreeElement.prototype.populateDOMNodeContextMenu):

  • UserInterface/Views/DOMTreeElementPathComponent.js:

(WI.DOMTreeElementPathComponent.prototype.mouseOver):

  • UserInterface/Views/DOMTreeOutline.js:

(WI.DOMTreeOutline.prototype.get editable):
(WI.DOMTreeOutline.prototype.populateContextMenu):
(WI.DOMTreeOutline.prototype._onmousemove):
(WI.DOMTreeOutline.prototype._ondragstart):
(WI.DOMTreeOutline.prototype._ondragover):
(WI.DOMTreeOutline.prototype._ondragleave):
(WI.DOMTreeOutline.prototype._ondragend):
(WI.DOMTreeOutline.prototype._hideElements):

  • UserInterface/Views/FormattedValue.js:

(WI.FormattedValue.createElementForNodePreview):

  • UserInterface/Views/GeneralStyleDetailsSidebarPanel.js:

(WI.GeneralStyleDetailsSidebarPanel.prototype.layout):

  • UserInterface/Views/LayerDetailsSidebarPanel.js:

(WI.LayerDetailsSidebarPanel.prototype._dataGridMouseMove):

  • UserInterface/Views/LayerTreeDetailsSidebarPanel.js:

(WI.LayerTreeDetailsSidebarPanel.prototype.layout):
(WI.LayerTreeDetailsSidebarPanel.prototype._highlightSelectedNode):

  • UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:

(WI.SpreadsheetCSSStyleDeclarationSection.prototype._highlightNodesWithSelector):

LayoutTests:

  • http/tests/inspector/dom/cross-domain-inspected-node-access.html:
  • http/tests/inspector/dom/didFireEvent.html:
  • http/tests/inspector/network/resource-initiatorNode.html:
  • inspector/console/command-line-api.html:
  • inspector/css/add-css-property.html:
  • inspector/css/css-property.html:
  • inspector/css/force-page-appearance.html:
  • inspector/css/generateCSSRuleString.html:
  • inspector/css/matched-style-properties.html:
  • inspector/css/modify-css-property-race.html:
  • inspector/css/modify-css-property.html:
  • inspector/css/modify-inline-style.html:
  • inspector/css/modify-rule-selector.html:
  • inspector/css/overridden-property.html:
  • inspector/css/pseudo-element-matches-for-pseudo-element-node.html:
  • inspector/css/pseudo-element-matches.html:
  • inspector/css/resolve-variable-value.html:
  • inspector/css/selector-dynamic-specificity.html:
  • inspector/css/selector-specificity.html:
  • inspector/css/shadow-scoped-style.html:
  • inspector/css/stylesheet-with-mutations.html:
  • inspector/dom-debugger/attribute-modified-style.html:
  • inspector/dom-debugger/dom-breakpoints.html:
  • inspector/dom/attributeModified.html:
  • inspector/dom/breakpoint-for-event-listener.html:
  • inspector/dom/csp-big5-hash.html:
  • inspector/dom/csp-hash.html:
  • inspector/dom/customElementState.html:
  • inspector/dom/domutilities-csspath.html:
  • inspector/dom/domutilities-path-dump.html:
  • inspector/dom/domutilities-xpath.html:
  • inspector/dom/event-listener-inspected-node.html:
  • inspector/dom/getEventListenersForNode.html:
  • inspector/dom/getOuterHTML.html:
  • inspector/dom/insertAdjacentHTML.html:
  • inspector/dom/pseudo-element-dynamic.html:
  • inspector/dom/pseudo-element-static.html:
  • inspector/dom/setAllowEditingUserAgentShadowTrees.html:
  • inspector/dom/setInspectedNode.html:
  • inspector/dom/setOuterHTML.html:
  • inspector/dom/shadow-and-non-shadow-children.html:
  • inspector/dom/shadowRootType.html:
  • inspector/dom/template-content.html:
  • inspector/model/dom-node.html:
  • inspector/page/hidpi-snapshot-size.html:
10:04 PM Changeset in webkit [253241] by Devin Rousso
  • 16 edits in trunk/Source/WebInspectorUI

Web Inspector: saving a file with the url "/" suggest the name "Untitled"
https://bugs.webkit.org/show_bug.cgi?id=204910

Reviewed by Timothy Hatcher.

  • UserInterface/Base/FileUtilities.js:

(WI.FileUtilities.save):
Allow callers to specify a suggestedName that is used if possible.

  • UserInterface/Views/ContextMenuUtilities.js:

(WI.appendContextMenuItemsForSourceCode):
(WI.appendContextMenuItemsForDOMNode):

  • UserInterface/Views/TextResourceContentView.js:

(WI.TextResourceContentView.prototype.get saveData):

  • UserInterface/Views/ResourceContentView.js:

(WI.ResourceContentView.prototype.get saveData):
If the path of the selected source code is just "/", set the suggestedName to "index" and
use an extension derived from the MIME type (if able).

  • UserInterface/Controllers/AuditManager.js:

(WI.AuditManager.prototype.export):

  • UserInterface/Views/ConsoleMessageView.js:

(WI.ConsoleMessageView.prototype._handleContextMenu):

  • UserInterface/Views/HeapSnapshotContentView.js:

(WI.HeapSnapshotContentView.prototype._exportSnapshot):

  • UserInterface/Views/LogContentView.js:

(WI.LogContentView.prototype.get saveData):
(WI.LogContentView.prototype._handleContextMenuEvent):

  • UserInterface/Views/NetworkTableContentView.js:

(WI.NetworkTableContentView.prototype._exportHAR):

  • UserInterface/Views/RecordingContentView.js:

(WI.RecordingContentView.prototype._exportRecording):
(WI.RecordingContentView.prototype._exportReduction):

  • UserInterface/Views/ScriptContentView.js:

(WI.ScriptContentView.prototype.get saveData):

  • UserInterface/Views/ShaderProgramContentView.js:

(WI.ShaderProgramContentView.prototype.get saveData):

  • UserInterface/Views/TextContentView.js:

(WI.TextContentView.prototype.get saveData):

  • UserInterface/Views/TimelineRecordingContentView.js:

(WI.TimelineRecordingContentView.prototype._exportTimelineRecording):

  • UserInterface/Debug/ProtocolTrace.js:

(WI.ProtocolTrace.prototype.get saveData):
Prefer suggestedName vs WI.FileUtilities.inspectorURLForFilename, which is now always
called inside WI.FileUtilities.save anyways.

9:48 PM Changeset in webkit [253240] by ysuzuki@apple.com
  • 6 edits in trunk/Source/JavaScriptCore

[JSC] Put JSModuleNamespaceObject in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204973

Reviewed by Mark Lam.

We found that we do not need to embed AbstractModuleRecord vector inside JSModuleNamespaceObject: we can just put it
in ExportEntry. So we can make it non-variable-sized cell. Further, this patch puts it in IsoSubspace.

  • runtime/CellSize.h:

(JSC::isDynamicallySizedType):
(JSC::cellSize):

  • runtime/JSModuleNamespaceObject.cpp:

(JSC::JSModuleNamespaceObject::finishCreation):
(JSC::JSModuleNamespaceObject::visitChildren):
(JSC::JSModuleNamespaceObject::getOwnPropertySlotCommon):

  • runtime/JSModuleNamespaceObject.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
9:16 PM Changeset in webkit [253239] by pvollan@apple.com
  • 2 edits in trunk/LayoutTests

Layout Test http/tests/xmlhttprequest/sync-xhr-in-unload.html is failing
https://bugs.webkit.org/show_bug.cgi?id=204974

Unreviewed test gardening.

  • platform/win/TestExpectations:
8:35 PM Changeset in webkit [253238] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

[LFC][IFC] Rename ContentBreak to ContentWrappingRule and ContentBreak::wrap to ContentWrappingRule::push
https://bugs.webkit.org/show_bug.cgi?id=204966
<rdar://problem/57717049>

Reviewed by Sam Weinig.

Use the term "push" instead of "wrap" to move a run to the next line without breaking it.
This is mainly to avoid spec term confusion.
ContentWrappingRule::Keep -> keep the run (or continuous runs) on the current line.
ContentWrappingRule::Split -> keep the run (or continuous runs) partially on the current line (see BreakingContext::PartialTrailingContent).
ContentWrappingRule::Push -> move the run (or continuous runs) completely to the next line.

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::breakingContextForInlineContent):

  • layout/inlineformatting/InlineLineBreaker.h:
  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::LineLayoutContext::processUncommittedContent):

8:20 PM Changeset in webkit [253237] by ysuzuki@apple.com
  • 7 edits in trunk/Source/JavaScriptCore

[JSC] Put ModuleRecords in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204972

Reviewed by Mark Lam.

This patch is putting JSModuleRecord and WebAssemblyModuleRecord in IsoSubspace.

  • runtime/AbstractModuleRecord.cpp:

(JSC::AbstractModuleRecord::destroy): Deleted.

  • runtime/AbstractModuleRecord.h:

(JSC::AbstractModuleRecord::subspaceFor):

  • runtime/JSModuleRecord.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
  • wasm/js/WebAssemblyModuleRecord.h:
7:50 PM Changeset in webkit [253236] by pvollan@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed build fix. Initialize local variable.

  • API/tests/testapi.cpp:

(TestAPI::promiseUnhandledRejection):

6:49 PM Changeset in webkit [253235] by jh718.park@samsung.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed. Change the format string portable by using "%" PRIx64
instead of "%llx" for uint64_t argument.

This patch removes the build warning below since r252978.

warning: format ‘%llx’ expects argument of type ‘long long unsigned int’,
but argument 3 has type ‘JSC::SpeculatedType {aka long unsigned int}’ [-Wformat=]

  • runtime/PredictionFileCreatingFuzzerAgent.cpp:

(JSC::PredictionFileCreatingFuzzerAgent::getPredictionInternal):

5:14 PM Changeset in webkit [253234] by commit-queue@webkit.org
  • 4 edits
    4 adds in trunk/Source

Unreviewed, rolling out r253218.
https://bugs.webkit.org/show_bug.cgi?id=204968

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

Reverted changeset:

"Remove various .order files."
https://bugs.webkit.org/show_bug.cgi?id=204959
https://trac.webkit.org/changeset/253218

4:33 PM Changeset in webkit [253233] by ysuzuki@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

[JSC] JSCallee should be in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204961

Reviewed by Mark Lam.

We should put JSCallee in IsoSubspace. Currently, we are also putting JSToWasmICCallee in IsoSusbapce
since it is a derived class of JSCallee, but I think we can remove this class completely. We are tracking
it in [1].

[1]: https://bugs.webkit.org/show_bug.cgi?id=204960

  • debugger/DebuggerScope.h:
  • interpreter/Interpreter.cpp:

(JSC::Interpreter::executeProgram):
(JSC::Interpreter::execute):

  • runtime/JSCallee.h:

(JSC::JSCallee::subspaceFor):

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::globalCallee):

  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
  • wasm/js/JSToWasmICCallee.h:

(JSC::JSToWasmICCallee::function): Deleted.
(JSC::JSToWasmICCallee::JSToWasmICCallee): Deleted.

4:24 PM Changeset in webkit [253232] by Chris Dumez
  • 4 edits in trunk/Source/WebKit

[IPC] MESSAGE_CHECK() parameters for AddPlugInAutoStartOriginHash / PlugInDidReceiveUserInteraction IPCs
https://bugs.webkit.org/show_bug.cgi?id=204962

Reviewed by Ryosuke Niwa.

MESSAGE_CHECK() parameters for AddPlugInAutoStartOriginHash / PlugInDidReceiveUserInteraction IPCs. Those parameters
are used as keys in HashMaps.

  • UIProcess/Plugins/PlugInAutoStartProvider.cpp:

(WebKit::PlugInAutoStartProvider::PlugInAutoStartProvider):
(WebKit::PlugInAutoStartProvider::addAutoStartOriginHash):
(WebKit::PlugInAutoStartProvider::setAutoStartOriginsTableWithItemsPassingTest):
(WebKit::PlugInAutoStartProvider::didReceiveUserInteraction):

  • UIProcess/Plugins/PlugInAutoStartProvider.h:
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::addPlugInAutoStartOriginHash):
(WebKit::WebProcessProxy::plugInDidReceiveUserInteraction):

4:19 PM Changeset in webkit [253231] by pvollan@apple.com
  • 19 edits
    1 copy
    7 adds in trunk/Source

[iOS] Calls to device orientation API should be done in the UI process
https://bugs.webkit.org/show_bug.cgi?id=204720

Reviewed by Alex Christensen.

Source/WebCore:

The device orientation API on iOS is communicating with locationd. Since mach lookup to this daemon
will be closed, the calls to this API should be moved from the WebContent process to the UI process.
This patch implements forwarding of the device orientation requests to the UI process through a new
class, DeviceOrientationUpdateProvider, which is subclassed by WebDeviceOrientationUpdateProvider in
modern WebKit. This class implements forwarding of the requests to the UI process, and receives
device orientation updates from the UI process. An instance of this class will be shared by all
device orientation clients on a page, and passed as part of the page configuration parameters. On
the UI process side, a new class WebDeviceOrientationUpdateProviderProxy attached to the Web page
proxy is taking care of calling the device orientation API through the existing WebCoreMotionManager
Objective-C class, and send device orientation updates back to the Web process. Also, use a weak
hash set of orientation clients in WebCoreMotionManager.

  • WebCore.xcodeproj/project.pbxproj:
  • dom/DeviceOrientationClient.h:
  • dom/Document.cpp:
  • page/Page.cpp:

(WebCore::m_deviceOrientationUpdateProvider):
(WebCore::m_applicationManifest): Deleted.

  • page/Page.h:

(WebCore::Page::deviceOrientationUpdateProvider const):

  • page/PageConfiguration.h:
  • platform/ios/DeviceOrientationClientIOS.h:
  • platform/ios/DeviceOrientationClientIOS.mm:

(WebCore::DeviceOrientationClientIOS::DeviceOrientationClientIOS):
(WebCore::DeviceOrientationClientIOS::startUpdating):
(WebCore::DeviceOrientationClientIOS::stopUpdating):
(WebCore::DeviceOrientationClientIOS::deviceOrientationControllerDestroyed):

  • platform/ios/WebCoreMotionManager.h:
  • platform/ios/WebCoreMotionManager.mm:

(-[WebCoreMotionManager addOrientationClient:]):
(-[WebCoreMotionManager removeOrientationClient:]):
(-[WebCoreMotionManager checkClientStatus]):
(-[WebCoreMotionManager sendMotionData:withHeading:]):

Source/WebKit:

Add a new class, WebDeviceOrientationUpdateProviderProxy, to handle messages to start and stop updating device orientation
in the UI process. Also, add a message to update the device orientation in the WebContent process. In the UI process, the
device orientation API is called through the already existing WebCoreMotionManager class.

  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • UIProcess/WebPageProxy.cpp:

(WebKit::m_webDeviceOrientationUpdateProviderProxy):
(WebKit::m_resetRecentCrashCountTimer): Deleted.

  • UIProcess/WebPageProxy.h:
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_overriddenMediaType):

4:11 PM Changeset in webkit [253230] by Jonathan Bedard
  • 2 edits in trunk/Tools

Python 3: Add support in webkitpy.tool (Follow-up, part 2)
https://bugs.webkit.org/show_bug.cgi?id=204838

Unreviewed follow-up fix.

  • Scripts/webkitpy/common/net/bugzilla/bugzilla_unittest.py:
4:04 PM Changeset in webkit [253229] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: REGRESSION(r252652): Local Overrides: creating a local override for a resource loaded before Web Inspector was opened shows NaN for the Status Code
https://bugs.webkit.org/show_bug.cgi?id=204965

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/LocalResourceOverridePopover.js:

(WI.LocalResourceOverridePopover.prototype.show):
Make sure to update the object that holds the resource's original data in addition to the
object that holds the current edited values.
Drive-by: update the popover once all of the CodeMirrors have updated to hide scrollbars.

3:56 PM Changeset in webkit [253228] by sihui_liu@apple.com
  • 4 edits in trunk/Source/WebCore

IndexedDB: pass along error of IDBBackingStore::renameIndex
https://bugs.webkit.org/show_bug.cgi?id=204900

Reviewed by Brady Eidson.

We ignored error of IDBBackingStore::renameIndex, so the operation may fail silently. This covered up two bugs
in our code as we were unaware of the failure.
One was in MemoryIDBBackingStore that we did not update objectStoreInfo properly when createIndex/deleteIndex;
another was in IDBObjectStoreInfo that we did not copy its members correctly.

Covered by existing test: storage/indexeddbmodern/index-rename-1-private.html

  • Modules/indexeddb/server/MemoryIDBBackingStore.cpp:

(WebCore::IDBServer::MemoryIDBBackingStore::createIndex):
(WebCore::IDBServer::MemoryIDBBackingStore::deleteIndex):

  • Modules/indexeddb/server/UniqueIDBDatabase.cpp:

(WebCore::IDBServer::UniqueIDBDatabase::performRenameIndex):

  • Modules/indexeddb/shared/IDBObjectStoreInfo.cpp: If some index is deleted from IDBObjectStoreInfo, then

m_maxIndexID could be bigger than maximum index ID in m_indexMap, because we don't decrease m_maxIndexID for
deletion. Therefore, the assertion here is incorrect.
(WebCore::IDBObjectStoreInfo::isolatedCopy const):

3:38 PM Changeset in webkit [253227] by don.olmstead@sony.com
  • 5 edits in trunk/Source/WebCore

[MathML] Should support conditional compilation
https://bugs.webkit.org/show_bug.cgi?id=204958

Reviewed by Ross Kirsling.

No new tests. No change in behavior.

Add missing checks for ENABLE_MATHML in the idl and cpp files.

  • bindings/js/JSElementCustom.cpp:

(WebCore::createNewElementWrapper):

  • bindings/js/JSNodeCustom.cpp:

(WebCore::createWrapperInline):

  • mathml/MathMLElement.idl:
  • mathml/MathMLMathElement.idl:
3:20 PM Changeset in webkit [253226] by Devin Rousso
  • 11 edits in trunk/Source

Web Inspector: add compiler UNLIKELY hints when checking if developer extras are enabled
https://bugs.webkit.org/show_bug.cgi?id=204875

Reviewed by Joseph Pecoraro.

Source/JavaScriptCore:

Move the check for whether developer extras are enabled from the agent to the client so that
when inspecting a webpage, we don't check for it twice, since InspectorInstrumentation
already checks for it too.

  • inspector/agents/InspectorConsoleAgent.h:
  • inspector/agents/InspectorConsoleAgent.cpp:

(Inspector::InspectorConsoleAgent::developerExtrasEnabled const): Added.
(Inspector::InspectorConsoleAgent::addMessageToConsole):
(Inspector::InspectorConsoleAgent::startTiming):
(Inspector::InspectorConsoleAgent::logTiming):
(Inspector::InspectorConsoleAgent::stopTiming):
(Inspector::InspectorConsoleAgent::takeHeapSnapshot):
(Inspector::InspectorConsoleAgent::count):
(Inspector::InspectorConsoleAgent::countReset):
(Inspector::InspectorConsoleAgent::addConsoleMessage):

  • inspector/JSGlobalObjectConsoleClient.cpp:

(Inspector::JSGlobalObjectConsoleClient::messageWithTypeAndLevel):
(Inspector::JSGlobalObjectConsoleClient::count):
(Inspector::JSGlobalObjectConsoleClient::countReset):
(Inspector::JSGlobalObjectConsoleClient::profile):
(Inspector::JSGlobalObjectConsoleClient::profileEnd):
(Inspector::JSGlobalObjectConsoleClient::takeHeapSnapshot):
(Inspector::JSGlobalObjectConsoleClient::time):
(Inspector::JSGlobalObjectConsoleClient::timeLog):
(Inspector::JSGlobalObjectConsoleClient::timeEnd):
(Inspector::JSGlobalObjectConsoleClient::timeStamp):
(Inspector::JSGlobalObjectConsoleClient::record):
(Inspector::JSGlobalObjectConsoleClient::recordEnd):
(Inspector::JSGlobalObjectConsoleClient::screenshot):

Source/WebCore:

  • inspector/InspectorInstrumentation.h:

(WebCore::InspectorInstrumentation::consoleStartRecordingCanvas):
(WebCore::InspectorInstrumentation::consoleStopRecordingCanvas): Added.

  • inspector/InspectorInstrumentation.cpp:

(WebCore::InspectorInstrumentation::frameWindowDiscardedImpl):
(WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
(WebCore::InspectorInstrumentation::didFailLoadingImpl):
(WebCore::InspectorInstrumentation::didCommitLoadImpl):
(WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
(WebCore::InspectorInstrumentation::consoleCountImpl):
(WebCore::InspectorInstrumentation::consoleCountResetImpl):
(WebCore::InspectorInstrumentation::startConsoleTimingImpl):
(WebCore::InspectorInstrumentation::logConsoleTimingImpl):
(WebCore::InspectorInstrumentation::stopConsoleTimingImpl):
(WebCore::InspectorInstrumentation::consoleStopRecordingCanvasImpl): Added.

  • inspector/agents/WebConsoleAgent.cpp:

(WebCore::WebConsoleAgent::frameWindowDiscarded):
(WebCore::WebConsoleAgent::didReceiveResponse):
(WebCore::WebConsoleAgent::didFailLoading):
Remove the redundant check for whether developer extras are enabled since it's already
checked by InspectorInstrumentation.

  • page/PageConsoleClient.cpp:

(WebCore::PageConsoleClient::record):
(WebCore::PageConsoleClient::recordEnd):

  • inspector/agents/InspectorCanvasAgent.h:
  • inspector/agents/InspectorCanvasAgent.cpp:

(WebCore::InspectorCanvasAgent::consoleStopRecordingCanvas): Added.
Add checks for InspectorInstrumentation::hasFrontends() to avoid doing extra work when Web
Inspector isn't open.

3:17 PM Changeset in webkit [253225] by Alan Bujtas
  • 9 edits in trunk/Source/WebCore

[LFC][IFC] Use explicit 0_lu value instead of LayoutUnit { }
https://bugs.webkit.org/show_bug.cgi?id=204964
<rdar://problem/57714095>

Reviewed by Antti Koivisto.

From geometry computation point of view, it is really the 0 value and not an empty value.

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computedIntrinsicWidthConstraints):

  • layout/inlineformatting/InlineFormattingContextQuirks.cpp:

(WebCore::Layout::InlineFormattingContext::Quirks::lineHeightConstraints const):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::resetDescent):
(WebCore::Layout::LineBox::resetBaseline):
(WebCore::Layout::LineBox::Baseline::reset):

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::wordBreakingBehavior const):
(WebCore::Layout::LineBreaker::Content::reset):
(WebCore::Layout::LineBreaker::Content::TrailingTrimmableContent::reset):

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::ContinousContent::close):
(WebCore::Layout::LineBuilder::Run::Run):
(WebCore::Layout::LineBuilder::initialize):
(WebCore::Layout::LineBuilder::close):
(WebCore::Layout::LineBuilder::alignContentVertically):
(WebCore::Layout::LineBuilder::appendLineBreak):
(WebCore::Layout::LineBuilder::adjustBaselineAndLineHeight):
(WebCore::Layout::LineBuilder::TrimmableContent::trimTrailingRun):
(WebCore::Layout::LineBuilder::InlineItemRun::trailingLetterSpacing const):
(WebCore::Layout::LineBuilder::InlineItemRun::setCollapsesToZeroAdvanceWidth):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::TrimmableContent::reset):

  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::inlineItemWidth):

  • layout/inlineformatting/text/TextUtil.h:

(WebCore::Layout::TextUtil::width): Deleted.

3:02 PM Changeset in webkit [253224] by Chris Dumez
  • 3 edits in trunk/Source/WebKit

Reduce timeout for page to handle beforeunload events when trying to close a page
https://bugs.webkit.org/show_bug.cgi?id=204950
<rdar://problem/57700419>

Reviewed by Ryosuke Niwa.

Reduce timeout for page to handle beforeunload events when trying to close a page. It would previously
take up to 3 seconds to actually close a tab after the user would click on the "X" to close it. This
is because we would wait for the page to fire and handle the beforeunload events and only give up after
3 seconds. This patch reduces this timeout to something more reasonable from a user standpoint (500ms).

  • UIProcess/WebPageProxy.cpp:

(WebKit::m_tryCloseTimeoutTimer):
(WebKit::WebPageProxy::tryClose):
(WebKit::WebPageProxy::tryCloseTimedOut):
(WebKit::WebPageProxy::closePage):
(WebKit::m_resetRecentCrashCountTimer): Deleted.

  • UIProcess/WebPageProxy.h:
3:01 PM Changeset in webkit [253223] by Alan Coon
  • 7 edits in tags/Safari-609.1.11.1/Source

Versioning.

3:00 PM Changeset in webkit [253222] by Jonathan Bedard
  • 4 edits in trunk/Tools

Python 3: Add support in webkitpy.tool (Follow-up, part 1)
https://bugs.webkit.org/show_bug.cgi?id=204838

Reviewed by Stephanie Lewis.

As I've been using webkit-patch with Python 3, I've encountered a handful of other
compatibility bugs.

  • Scripts/webkit-patch:

(ForgivingUTF8Writer): Only apple the ForgivingUTF8Writer when our string type isn't unicode.
(ForgivingUTF8Writer.write): Use standardized decoding functions.

  • Scripts/webkitpy/common/net/bugzilla/bugzilla.py:

(Bugzilla.authenticate): Use byte regex.

  • Scripts/webkitpy/tool/steps/editchangelog.py:

(EditChangeLog.run): Convert map to list.

2:58 PM Changeset in webkit [253221] by Alan Coon
  • 1 copy in tags/Safari-609.1.11.1

New tag.

2:49 PM Changeset in webkit [253220] by Dewei Zhu
  • 2 edits in trunk/Websites/perf.webkit.org

Custom analysis task page should allow schedule any triggerable accepted tests.
https://bugs.webkit.org/show_bug.cgi?id=204925

Reviewed by Ryosuke Niwa.

Fix a bug that subtest will not show on custom analysis task page if both itself and parent test are
accepted by triggerable.
Order test list in alphabetical order.

  • public/v3/components/custom-analysis-task-configurator.js:

(CustomAnalysisTaskConfigurator.prototype._renderTriggerableTests):

2:45 PM Changeset in webkit [253219] by Jonathan Bedard
  • 19 edits in trunk

Python 3: Add support in webkitpy.test
https://bugs.webkit.org/show_bug.cgi?id=204952

Reviewed by Stephanie Lewis.

Source/WebKit:

Tested by test-webkitpy.

  • Scripts/webkit/messages_unittest.py: Use Python 2/3 compatible StringIO.

Tools:

  • Scripts/test-webkitpy-python3: Add webkitpy.tool.
  • Scripts/webkitpy/layout_tests/lint_test_expectations_unittest.py: Use Python 2/3

compatible StringIO objects.

  • Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py: Ditto.
  • Scripts/webkitpy/performance_tests/perftest_unittest.py: Ditto.
  • Scripts/webkitpy/performance_tests/perftestsrunner_integrationtest.py: Ditto.
  • Scripts/webkitpy/performance_tests/perftestsrunner_unittest.py: Ditto.
  • Scripts/webkitpy/test/finder.py:

(Finder._exclude): Convert filter to list.

  • Scripts/webkitpy/test/main.py:

(Tester._log_exception): Use Python 2/3 compatible StringIO object.
(_Loader.getTestCaseNames): Convert filter to list.

  • Scripts/webkitpy/test/main_unittest.py:

(TesterTest.test_no_tests_found): Use Python 2/3 compatible StringIO.
(TesterTest.test_integration_tests_are_found): Sort serial tests before comparing.

  • Scripts/webkitpy/test/printer.py: Use Python 2/3 compatible StringIO.
  • Scripts/webkitpy/test/runner_unittest.py: Ditto.
  • Scripts/webkitpy/test/skip.py:

(_skipped_method._skip): Fix class inspection on instance method.

  • Scripts/webkitpy/test/skip_unittest.py: Use Python 2/3 compatible StringIO.
  • Scripts/webkitpy/w3c/test_converter.py: Use Python 2/3 compatible HTMLParser.
  • Scripts/webkitpy/w3c/wpt_runner.py:

(main): Fix Python 3 syntax errors.

  • lldb/dump_class_layout_unittest.py:

(TestDumpClassLayout.setUpClass): Fix Python 3 syntax errors.

2:43 PM Changeset in webkit [253218] by keith_miller@apple.com
  • 4 edits
    4 deletes in trunk/Source

Remove various .order files.
https://bugs.webkit.org/show_bug.cgi?id=204959

Reviewed by Yusuke Suzuki.

These files are all super out of date and likely don't do anything anymore.
The signatures of the functions have changed thus the mangled name has changed.

Source/JavaScriptCore:

Source/WebCore:

  • WebCore.order: Removed.

Source/WebKit:

  • mac/WebKit2.order: Removed.

Source/WebKitLegacy/mac:

  • WebKit.order: Removed.
2:22 PM Changeset in webkit [253217] by dino@apple.com
  • 2 edits in trunk/Source/ThirdParty/ANGLE

Restrict libANGLE to link only with WebCore
https://bugs.webkit.org/show_bug.cgi?id=204957
<rdar://problem/57708644>

Reviewed by Brian Burg.

Restrict to WebCore and WebCoreTestSupport.

  • Configurations/ANGLE.xcconfig:
2:07 PM Changeset in webkit [253216] by mitz@apple.com
  • 2 edits in trunk/Source/WebKit

Address <https://bugs.webkit.org/show_bug.cgi?id=189222#c3>

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView valueForUndefinedKey:]): Added a newline.

1:45 PM Changeset in webkit [253215] by Jonathan Bedard
  • 13 edits in trunk

Unreviewed, rolling out r253148.

This caused fast/mediastream/stream-switch.html to timeout on
Mac.

Reverted changeset:

"WPT test MediaStream-MediaElement-srcObject.https.html times
out"
https://bugs.webkit.org/show_bug.cgi?id=204762
https://trac.webkit.org/changeset/253148

1:42 PM Changeset in webkit [253214] by Alan Bujtas
  • 8 edits in trunk/Source/WebCore

[LFC][IFC] Paint partial trailing run with hyphen when needed
https://bugs.webkit.org/show_bug.cgi?id=204953
<rdar://problem/57705169>

Reviewed by Antti Koivisto.

When LineBreaker comes back with a partial content that needs hyphen, we need to make sure this information
ends up in the final Display::Run so that the rendered content includes the hyphen string. Note that this only needs to
be done when the content does _not_ have the hyphen already (opportunity vs. oppor-tunity).
(This patch also renames trailingPartial to partialTrailing because the fact that it is partial run is more important than that it is trailing run.)

  • layout/displaytree/DisplayRun.h:

(WebCore::Display::Run::TextContext::TextContext):
(WebCore::Display::Run::TextContext::needsHyphen const):
(WebCore::Display::Run::TextContext::setNeedsHyphen):
(WebCore::Display::Run::textContext):

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::lineLayout):
(WebCore::Layout::InlineFormattingContext::setDisplayBoxesForLine):

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::breakingContextForInlineContent):
(WebCore::Layout::LineBreaker::wordBreakingBehavior const):

  • layout/inlineformatting/InlineLineBreaker.h:
  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::LineLayoutContext::layoutLine):
(WebCore::Layout::LineLayoutContext::close):
(WebCore::Layout::LineLayoutContext::processUncommittedContent):

  • layout/inlineformatting/LineLayoutContext.h:
  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::paint):

1:05 PM Changeset in webkit [253213] by Chris Dumez
  • 8 edits
    7 adds in trunk

Prevent synchronous XHR in beforeunload / unload event handlers
https://bugs.webkit.org/show_bug.cgi?id=204912
<rdar://problem/57676394>

Reviewed by Darin Adler.

Source/WebCore:

Prevent synchronous XHR in beforeunload / unload event handlers. They are terrible for performance
and the Beacon API (or Fetch keepalive) are more efficient & supported alternatives.

In particular, this would cause hangs when trying to navigate away from a site or when closing
attempt, which would result in terrible user experience.

Chrome and Edge have expressed public support for this. Chrome has actually been testing this behavior
for a while now:
https://www.chromestatus.com/feature/4664843055398912

I added this new behavior behind an experimental feature flag, enabled by default.

Tests: http/tests/xmlhttprequest/sync-xhr-in-beforeunload.html

http/tests/xmlhttprequest/sync-xhr-in-unload.html

  • loader/DocumentThreadableLoader.cpp:

(WebCore::DocumentThreadableLoader::DocumentThreadableLoader):

  • loader/FrameLoader.cpp:

(WebCore::PageLevelForbidScope::PageLevelForbidScope):
(WebCore::ForbidPromptsScope::ForbidPromptsScope):
(WebCore::ForbidPromptsScope::~ForbidPromptsScope):
(WebCore::ForbidSynchronousLoadsScope::ForbidSynchronousLoadsScope):
(WebCore::ForbidSynchronousLoadsScope::~ForbidSynchronousLoadsScope):
(WebCore::FrameLoader::dispatchUnloadEvents):
(WebCore::FrameLoader::dispatchBeforeUnloadEvent):

  • page/Page.cpp:

(WebCore::Page::forbidSynchronousLoads):
(WebCore::Page::allowSynchronousLoads):
(WebCore::Page::areSynchronousLoadsAllowed):

  • page/Page.h:

LayoutTests:

Add layout test coverage.

  • http/tests/xmlhttprequest/resources/sync-xhr-in-beforeunload-window.html: Added.
  • http/tests/xmlhttprequest/resources/sync-xhr-in-unload-window.html: Added.
  • http/tests/xmlhttprequest/sync-xhr-in-beforeunload-expected.txt: Added.
  • http/tests/xmlhttprequest/sync-xhr-in-beforeunload.html: Added.
  • http/tests/xmlhttprequest/sync-xhr-in-unload-expected.txt: Added.
  • http/tests/xmlhttprequest/sync-xhr-in-unload.html: Added.
1:03 PM Changeset in webkit [253212] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

Drop support for NSURLCache callbacks in NetworkProcess
https://bugs.webkit.org/show_bug.cgi?id=203344

Patch by Benjamin Nham <Ben Nham> on 2019-12-06
Reviewed by Alex Christensen.

Remove the NSURLSession caching policy callback in NetworkProcess. It's no longer necessary since
we don't use NSURLCache in NetworkProcess (https://bugs.webkit.org/show_bug.cgi?id=185990).

  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(-[WKNetworkSessionDelegate URLSession:dataTask:willCacheResponse:completionHandler:]): Deleted.

11:34 AM Changeset in webkit [253211] by BJ Burg
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: TabActivity diagnostic event should sample the active tab uniformly
https://bugs.webkit.org/show_bug.cgi?id=204531

Reviewed by Devin Rousso.

Rewrite this class to use a uniform sampling approach. Every n seconds, a timer fires and
samples what the current tab is. If the last user interaction happened up to n seconds ago,
report a TabActivity diagnostic event. Keeping with the previous implementation, samples
are taken every n=60 seconds.

To account for bias in the initial sample when Web Inspector is open, wait m seconds for
the first sample. This accounts for the time between opening Web Inspector and choosing the
desired tab. In my testing, m=10 is enough time to load Web Inspector and switch
immediately to a different tab. In that case, the initial tab would not be sampled as the
active tab even if the last user interaction (clicking tab bar) happened while the initial
tab was displayed. If the recorder's setup() method is called some time after Web Inspector is
opened, then the initial delay will shrink to ensure at least 10s has elapsed since the frontend
finished loading.

  • UserInterface/Base/Main.js:

(WI.contentLoaded): Keep a timestamp of when the frontend finished loading.

  • UserInterface/Controllers/TabActivityDiagnosticEventRecorder.js:

(WI.TabActivityDiagnosticEventRecorder):
(WI.TabActivityDiagnosticEventRecorder.prototype.setup):
(WI.TabActivityDiagnosticEventRecorder.prototype.teardown):
(WI.TabActivityDiagnosticEventRecorder.prototype._startInitialDelayBeforeSamplingTimer):
(WI.TabActivityDiagnosticEventRecorder.prototype._stopInitialDelayBeforeSamplingTimer):
(WI.TabActivityDiagnosticEventRecorder.prototype._startEventSamplingTimer):
(WI.TabActivityDiagnosticEventRecorder.prototype._stopEventSamplingTimer):
(WI.TabActivityDiagnosticEventRecorder.prototype._sampleCurrentTabActivity):
(WI.TabActivityDiagnosticEventRecorder.prototype._didObserveUserInteraction):
(WI.TabActivityDiagnosticEventRecorder.prototype._handleWindowFocus):
(WI.TabActivityDiagnosticEventRecorder.prototype._handleWindowBlur):
(WI.TabActivityDiagnosticEventRecorder.prototype._handleWindowKeyDown):
(WI.TabActivityDiagnosticEventRecorder.prototype._handleWindowMouseDown):
(WI.TabActivityDiagnosticEventRecorder.prototype._didInteractWithTabContent): Deleted.
(WI.TabActivityDiagnosticEventRecorder.prototype._clearTabActivityTimeout): Deleted.
(WI.TabActivityDiagnosticEventRecorder.prototype._beginTabActivityTimeout): Deleted.
(WI.TabActivityDiagnosticEventRecorder.prototype._stopTrackingTabActivity): Deleted.
(WI.TabActivityDiagnosticEventRecorder.prototype._handleTabBrowserSelectedTabContentViewDidChange): Deleted.

11:18 AM Changeset in webkit [253210] by Antti Koivisto
  • 13 edits
    2 adds in trunk

Support for resolving highlight pseudo element style
https://bugs.webkit.org/show_bug.cgi?id=204937

Reviewed by Simon Fraser.

Source/WebCore:

Test: highlight/highlight-pseudo-element-style.html

  • css/SelectorChecker.cpp:

(WebCore::SelectorChecker::checkOne const):

Returns always true when checked without pseudoId, so it gets added to the set of seen pseudo elements.
Match argument with the provided highlight name otherwise.

  • css/SelectorChecker.h:
  • css/parser/CSSSelectorParser.cpp:

(WebCore::CSSSelectorParser::consumePseudo):

  • rendering/style/RenderStyle.h:
  • style/ElementRuleCollector.cpp:

(WebCore::Style::ElementRuleCollector::ruleMatches):

  • style/ElementRuleCollector.h:

(WebCore::Style::PseudoElementRequest::PseudoElementRequest):

Add the requested highlight name.

  • style/StyleResolver.h:
  • style/StyleScope.h:
  • testing/Internals.cpp:

(WebCore::Internals::highlightPseudoElementColor):

Testing support.

  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

  • highlight/highlight-pseudo-element-style-expected.txt: Added.
  • highlight/highlight-pseudo-element-style.html: Added.
10:08 AM Changeset in webkit [253209] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

[LFC][Integration] Fix DisplayRunPath offsets
https://bugs.webkit.org/show_bug.cgi?id=204949

Reviewed by Zalan Bujtas.

Fixes output of tests like fast/text/system-font-zero-size.html with LFC integration enabled.

  • rendering/line/LineLayoutTraversalDisplayRunPath.h:

(WebCore::LineLayoutTraversal::DisplayRunPath::DisplayRunPath):
(WebCore::LineLayoutTraversal::DisplayRunPath::localStartOffset const):
(WebCore::LineLayoutTraversal::DisplayRunPath::localEndOffset const):

Display::Run offsets are already local.

(WebCore::LineLayoutTraversal::DisplayRunPath::length const):
(WebCore::LineLayoutTraversal::DisplayRunPath::runs const):
(WebCore::LineLayoutTraversal::DisplayRunPath::firstRun const): Deleted.

9:15 AM Changeset in webkit [253208] by jh718.park@samsung.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed. Revert r253207 because it causes compile error in Mac and ios build.

  • runtime/PredictionFileCreatingFuzzerAgent.cpp:

(JSC::PredictionFileCreatingFuzzerAgent::getPredictionInternal):

9:08 AM Changeset in webkit [253207] by jh718.park@samsung.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed. Remove build warning below since r252978.

warning: format ‘%llx’ expects argument of type ‘long long unsigned int’,
but argument 3 has type ‘JSC::SpeculatedType {aka long unsigned int}’ [-Wformat=]

  • runtime/PredictionFileCreatingFuzzerAgent.cpp:

(JSC::PredictionFileCreatingFuzzerAgent::getPredictionInternal):

8:06 AM Changeset in webkit [253206] by Chris Dumez
  • 5 edits in trunk/Source

Stop using reserveCapacity() / reserveInitialCapacity() in IPC decoders
https://bugs.webkit.org/show_bug.cgi?id=204930
<rdar://problem/57682737>

Reviewed by Ryosuke Niwa.

This is IPC hardening since the size we use to reserve the capacity is encoded over IPC
and cannot be trusted in some cases.

Source/WebCore:

  • page/csp/ContentSecurityPolicyResponseHeaders.h:

(WebCore::ContentSecurityPolicyResponseHeaders::decode):

Source/WebKit:

  • Platform/IPC/ArgumentCoders.h:
  • Shared/WebCoreArgumentCoders.cpp:

(IPC::ArgumentCoder<Vector<RefPtr<SecurityOrigin>>>::decode):

6:37 AM Changeset in webkit [253205] by Antti Koivisto
  • 7 edits in trunk/Source/WebCore

[LFC][Integration] Wire line counting functions in RenderBlockFlow
https://bugs.webkit.org/show_bug.cgi?id=204943

Reviewed by Zalan Bujtas.

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::lineCount const):

  • layout/integration/LayoutIntegrationLineLayout.h:
  • rendering/ComplexLineLayout.cpp:

(WebCore::ComplexLineLayout::layoutRunsAndFloatsInRange):
(WebCore::ComplexLineLayout::lineCount const):
(WebCore::ComplexLineLayout::lineCountUntil const):

Move complex path specific code to ComplexLineLayout.

  • rendering/ComplexLineLayout.h:
  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::adjustLinePositionForPagination):
(WebCore::RenderBlockFlow::lineCount const):
(WebCore::RenderBlockFlow::hasLines const):

Support all paths.

  • rendering/RenderBlockFlow.h:
6:34 AM Changeset in webkit [253204] by Antti Koivisto
  • 3 edits in trunk/Source/WebCore

[LFC][Integration] Support isLineBreak() in iterator
https://bugs.webkit.org/show_bug.cgi?id=204941

Reviewed by Zalan Bujtas.

  • layout/displaytree/DisplayRun.h:

(WebCore::Display::Run::isLineBreak const):

  • rendering/line/LineLayoutTraversalDisplayRunPath.h:

(WebCore::LineLayoutTraversal::DisplayRunPath::isLineBreak const):
(WebCore::LineLayoutTraversal::DisplayRunPath::traverseNextTextBoxInVisualOrder):

Also remove unneeded skipping of runs without text context. All runs generated from text nodes now have them.

1:25 AM Changeset in webkit [253203] by youenn@apple.com
  • 11 edits
    2 adds in trunk

Protect WebRTC network monitoring to wait forever in edge cases
https://bugs.webkit.org/show_bug.cgi?id=204846
Source/WebKit:

Reviewed by Eric Carlson.

We were limiting the number of IPC message sent to network process by only sending the start monitoring event for the first client.
The issue is that, if network process crashes for instance while having not yet given the list of networks, all clients will be hanging
waiting for the completion of network list.
We are now sending an IPC message for every client and the network process will ignore the ones that are not useful.
In addition, in case of network process crash, we send a signal that network list has changed to make sure clients will never hang.
They might still fail connecting, which is ok since network process crashed.

Test: webrtc/datachannel/gather-candidates-networkprocess-crash.html

  • NetworkProcess/webrtc/NetworkRTCMonitor.cpp:

(WebKit::NetworkRTCMonitor::startUpdatingIfNeeded):

  • NetworkProcess/webrtc/NetworkRTCMonitor.h:
  • NetworkProcess/webrtc/NetworkRTCMonitor.messages.in:
  • WebProcess/Network/webrtc/LibWebRTCNetwork.h:

(WebKit::LibWebRTCNetwork::networkProcessCrashed):

  • WebProcess/Network/webrtc/WebRTCMonitor.cpp:

(WebKit::WebRTCMonitor::StartUpdating):
(WebKit::WebRTCMonitor::StopUpdating):
(WebKit::WebRTCMonitor::networksChanged):
(WebKit::WebRTCMonitor::networkProcessCrashed):

  • WebProcess/Network/webrtc/WebRTCMonitor.h:
  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::networkProcessConnectionClosed):

LayoutTests:

<rdar://problem/57618773>

Reviewed by Eric Carlson.

  • webrtc/datachannel/gather-candidates-networkprocess-crash-expected.txt: Added.
  • webrtc/datachannel/gather-candidates-networkprocess-crash.html: Added.
1:24 AM Changeset in webkit [253202] by youenn@apple.com
  • 2 edits in trunk/Source/WebKit

Output libwebrtc logging from Network Process as release logging
https://bugs.webkit.org/show_bug.cgi?id=204853

Reviewed by Eric Carlson.

This will help debugging WebRTC networking issues.
No observable change of behavior.

  • NetworkProcess/webrtc/NetworkRTCProvider.cpp:

(WebKit::doReleaseLogging):
(WebKit::NetworkRTCProvider::NetworkRTCProvider):

Dec 5, 2019:

11:33 PM Changeset in webkit [253201] by sbarati@apple.com
  • 13 edits
    1 move in trunk/Source/JavaScriptCore

get_by_id ICs should have a structure history used to indicate when we should skip generating an IC
https://bugs.webkit.org/show_bug.cgi?id=204904
<rdar://problem/57631437>

Reviewed by Yusuke Suzuki and Tadeu Zagallo.

I implemented a similar policy for get_by_val for the number of unique seen
identifiers. This allows us to create a heuristic to directly call the slow
path when profiling information tells us if inline caching might not be
profitable. This patch implements a similar policy for get_by_id where we
profile the seen base value structures. If the LLInt observes enough
unique structures, we omit emitting the inline cache in the upper
tiers.

The goal here was to try to speed up Speedometer2. Local testing showed
this patch to repeatedly be 0.5% faster, but all the P values I got were
insignificant. So it appears it's either neutral or slightly faster.

This patch also adjusts the policy of seeing a non-identifier inside
the PointerHistory data structure. Instead of increasing it to reach the
limit when we see a non-identifier, we just treat each execution with
a non-identifier to increment the count by 1.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • bytecode/BytecodeList.rb:
  • bytecode/GetByValHistory.h: Removed.
  • bytecode/PointerHistory.h: Copied from Source/JavaScriptCore/bytecode/GetByValHistory.h.

(JSC::PointerHistory::observe):
(JSC::PointerHistory::observeNull):
(JSC::GetByValHistory::observeNonUID): Deleted.
(JSC::GetByValHistory::observe): Deleted.
(JSC::GetByValHistory::count const): Deleted.
(JSC::GetByValHistory::filter const): Deleted.
(JSC::GetByValHistory::update): Deleted.

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::parseGetById):
(JSC::DFG::ByteCodeParser::parseBlock):

  • dfg/DFGGraph.h:
  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileGetById):

  • dfg/DFGSpeculativeJIT32_64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileGetById):
(JSC::FTL::DFG::LowerDFGToB3::compileGetByVal):

  • generator/DSL.rb:
  • jit/JITPropertyAccess.cpp:

(JSC::JIT::emit_op_try_get_by_id):
(JSC::JIT::emitSlow_op_try_get_by_id):
(JSC::JIT::emit_op_get_by_id_direct):
(JSC::JIT::emitSlow_op_get_by_id_direct):
(JSC::JIT::emit_op_get_by_id):
(JSC::JIT::emitSlow_op_get_by_id):

  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::LLINT_SLOW_PATH_DECL):

  • runtime/OptionsList.h:
7:46 PM Changeset in webkit [253200] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Fix css1/basic/containment.html
https://bugs.webkit.org/show_bug.cgi?id=204931
<rdar://problem/57682871>

Reviewed by Simon Fraser.

moveToNextBreakablePosition jumped over all the positions that came back as the current position.
e.g --- <- first 2 breakable positions are at: 1 2 but we skipped over the first one.

  • layout/inlineformatting/InlineTextItem.cpp:

(WebCore::Layout::moveToNextBreakablePosition):

6:14 PM Changeset in webkit [253199] by yousuke.kimoto@sony.com
  • 2 edits in trunk/Source/WebKit

[WinCairo] Improve Inspectable Target Page to adapt a long title and URL
https://bugs.webkit.org/show_bug.cgi?id=204874

Reviewed by Fujii Hironori.

Add some CSS atributes to make such long titles and URLs fit the width
of a window size. Then "Inspector" button is shown at the visible area.
No new tests, since there is no change in behavior.

  • UIProcess/socket/RemoteInspectorProtocolHandler.cpp:

(WebKit::RemoteInspectorProtocolHandler::platformStartTask):

6:11 PM Changeset in webkit [253198] by Alan Coon
  • 1 copy in tags/Safari-608.5.0.2.1

Tag Safari-608.5.0.2.1.

6:10 PM Changeset in webkit [253197] by Alan Coon
  • 2 edits in branches/safari-608.5.0.2-branch/Source/JavaScriptCore

Cherry-pick r252674. rdar://problem/57609333

[JSC] MetadataTable::sizeInBytes should not touch m_rawBuffer in UnlinkedMetadataTable unless MetadataTable is linked to that UnlinkedMetadataTable
https://bugs.webkit.org/show_bug.cgi?id=204390

Reviewed by Mark Lam.

We have a race issue here. When calling MetadataTable::sizeInBytes, we call UnlinkedMetadataTable::sizeInBytes since we change the result based on
whether this MetadataTable is linked to this UnlinkedMetadataTable or not. The problem is that we are calling UnlinkedMetadataTable::totalSize
unconditionally in UnlinkedMetadataTable::sizeInBytes, and this is touching m_rawBuffer unconditionally. This is not correct since it is possible
that this m_rawBuffer is realloced while we are calling MetadataTable::sizeInBytes in GC thread.

  1. The GC thread is calling MetadataTable::sizeInBytes for MetadataTable "A".
  2. The main thread is destroying MetadataTable "B".
  3. MetadataTable "B" is linked to UnlinkedMetadataTable "C".
  4. MetadataTable "A" is pointing to UnlinkedMetadataTable "C".
  5. "A" is touching UnlinkedMetadataTable::m_rawBuffer in "C", called from MetadataTable::sizeInBytes.
  6. (2) destroys MetadataTable "B", and realloc UnlinkedMetadataTable::m_rawBuffer in "C".
  7. (5) can touch already freed buffer.

This patch fixes UnlinkedMetadataTable::sizeInBytes: not touching m_rawBuffer unless it is owned by the caller's MetadataTable. We need to call
UnlinkedMetadataTable::sizeInBytes anyway since we need to adjust the result based on whether the caller MetadataTable is linked to this UnlinkedMetadataTable.

  • bytecode/UnlinkedMetadataTableInlines.h: (JSC::UnlinkedMetadataTable::sizeInBytes):

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

6:07 PM Changeset in webkit [253196] by Alan Coon
  • 7 edits in branches/safari-608.5.0.2-branch/Source

Versioning.

5:58 PM Changeset in webkit [253195] by Fujii Hironori
  • 10 edits in trunk/Source/WebKit

[WebKit] Fix compilation warnings for MSVC
https://bugs.webkit.org/show_bug.cgi?id=204661

Reviewed by Don Olmstead.

No behavior changes.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp:

(WebKit::makeDescription):

  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::cleanup):

  • NetworkProcess/cache/NetworkCacheIOChannelCurl.cpp:

(WebKit::NetworkCache::IOChannel::IOChannel):

  • Shared/API/c/WKSharedAPICast.h:

(WebKit::toAPI):
(WebKit::toDiagnosticLoggingResultType):

  • UIProcess/WebURLSchemeTask.cpp:

(WebKit::WebURLSchemeTask::didReceiveData):

  • WebProcess/Storage/WebServiceWorkerFetchTaskClient.cpp:

(WebKit::WebServiceWorkerFetchTaskClient::didReceiveData):

  • WebProcess/WebCoreSupport/WebEditorClient.cpp:

(WebKit::WebEditorClient::registerAttachmentIdentifier):

5:54 PM Changeset in webkit [253194] by Alan Coon
  • 1 copy in branches/safari-608.5.0.2-branch

New branch.

5:53 PM Changeset in webkit [253193] by Alan Coon
  • 1 delete in branches/safari-608.5.0.2-branch

Delete tag.

5:33 PM Changeset in webkit [253192] by commit-queue@webkit.org
  • 179 edits
    1 move
    24 adds
    2 deletes in trunk/Source/ThirdParty/ANGLE

Finish ANGLE update
https://bugs.webkit.org/show_bug.cgi?id=204911

The last ANGLE update patch didn't include all the changed files.
This patch updates the rest of the files.

Patch by James Darpinian <James Darpinian> on 2019-12-05
Reviewed by Alex Christensen.

  • src/tests: Lots of changed files from upstream ANGLE.
  • src/third_party/compiler/README.chromium:
  • third_party/VK-GL-CTS/README.angle: Added.
  • third_party/deqp/README.angle: Removed.
  • third_party/googletest/README.angle: Removed.
  • third_party/libpng/BUILD.gn:
  • third_party/spirv-cross/README.angle: Added.
  • util/OSWindow.h:
  • util/egl_loader_autogen.cpp:

(angle::LoadEGL):

  • util/egl_loader_autogen.h:
  • util/fuchsia/ScenicWindow.cpp:

(ScenicWindow::resetNativeWindow):

  • util/fuchsia/ScenicWindow.h:
  • util/gles_loader_autogen.cpp:

(angle::LoadGLES):

  • util/gles_loader_autogen.h:
  • util/osx/OSXWindow.h:
  • util/osx/OSXWindow.mm:

(OSXWindow::initialize):

  • util/ozone/OzoneWindow.h:
  • util/posix/crash_handler_posix.cpp:

(angle::InitCrashHandler):

  • util/posix/test_utils_posix.cpp:

(angle::GetTempDir):
(angle::CreateTemporaryFileInDir):
(angle::DeleteFile):
(angle::LaunchProcess):
(angle::NumberOfProcessors):

  • util/shader_utils.cpp:

(CompileShaderFromFile):
(CompileProgramFromFiles):

  • util/test_utils.cpp: Added.

(angle::CreateTemporaryFile):
(angle::GetFileSize):
(angle::ReadEntireFileToString):
(angle::ProcessHandle::ProcessHandle):
(angle::ProcessHandle::~ProcessHandle):
(angle::ProcessHandle::operator=):
(angle::ProcessHandle::reset):

  • util/test_utils.h:
  • util/test_utils_unittest.cpp: Added.

(angle::NormalizeNewLines):
(angle::TEST):

  • util/test_utils_unittest_helper.cpp: Added.

(main):

  • util/test_utils_unittest_helper.h: Added.
  • util/util.gni:
  • util/windows/WGLWindow.cpp:
  • util/windows/test_utils_win.cpp:

(angle::InitCrashHandler):
(angle::TerminateCrashHandler):
(angle::LaunchProcess):
(angle::GetTempDir):
(angle::CreateTemporaryFileInDir):
(angle::DeleteFile):
(angle::NumberOfProcessors):

  • util/windows/win32/Win32Window.cpp:

(Win32Window::initialize):

  • util/windows/win32/test_utils_win32.cpp:

(angle::StabilizeCPUForBenchmarking):

  • util/x11/X11Window.h:
5:29 PM Changeset in webkit [253191] by Alan Coon
  • 1 copy in branches/safari-608.5.0.2-branch

New branch.

5:27 PM Changeset in webkit [253190] by Megan Gardner
  • 2 edits in trunk/Source/WebCore

Move member variable that should be private
https://bugs.webkit.org/show_bug.cgi?id=204913

Reviewed by Wenson Hsieh.

These member variables should be in the correct section.

No changing functionality, no tests needed.

  • page/EventHandler.h:
5:12 PM Changeset in webkit [253189] by BJ Burg
  • 3 edits in trunk/Source/WebKit

[Cocoa] _WKInspector uses wrong WKWebView in -setDiagnosticLoggingDelegate:
https://bugs.webkit.org/show_bug.cgi?id=204928

Reviewed by Timothy Hatcher.

I feel like I've made this mistake before. To make the right thing more obvious,
add a property named inspectorWebView that returns the Inspector WKWebView.

  • UIProcess/API/Cocoa/_WKInspector.mm:

(-[_WKInspector inspectorWebView]):
(-[_WKInspector _setDiagnosticLoggingDelegate:]):

  • UIProcess/WebInspectorProxy.h:

(WebKit::WebInspectorProxy::inspectorPage const):

5:08 PM Changeset in webkit [253188] by Tadeu Zagallo
  • 8 edits in trunk/Source/JavaScriptCore

[WebAssembly] Fix LLIntCallee's ownership
https://bugs.webkit.org/show_bug.cgi?id=204929

Reviewed by Saam Barati.

Currently, after the LLIntPlan finished generating bytecode, the Module takes ownership of the Vector
of LLIntCallee's and passes a pointer to the Vector's storage to the CodeBlock. However, while we're
tiering up, the module might be destroyed and we'll try to access the LLIntCallee after we finish
compiling through the pointer held by the CodeBlock, which is now stale, since the Vector was owned
by the Module. In order to fix this, we move the Vector into a reference counted wrapper class, LLIntCallees,
and both the Module and the CodeBlock hold references to the wrapper.

  • wasm/WasmBBQPlan.cpp:

(JSC::Wasm::BBQPlan::work):

  • wasm/WasmCallee.h:

(JSC::Wasm::LLIntCallees::create):
(JSC::Wasm::LLIntCallees::at const):
(JSC::Wasm::LLIntCallees::data const):
(JSC::Wasm::LLIntCallees::LLIntCallees):

  • wasm/WasmCodeBlock.cpp:

(JSC::Wasm::CodeBlock::create):
(JSC::Wasm::CodeBlock::CodeBlock):

  • wasm/WasmCodeBlock.h:

(JSC::Wasm::CodeBlock::wasmEntrypointCalleeFromFunctionIndexSpace):

  • wasm/WasmModule.cpp:

(JSC::Wasm::Module::Module):
(JSC::Wasm::Module::getOrCreateCodeBlock):

  • wasm/WasmModule.h:
  • wasm/WasmOMGPlan.cpp:

(JSC::Wasm::OMGPlan::work):

4:35 PM Changeset in webkit [253187] by Chris Dumez
  • 8 edits in trunk/Source/WebKit

Use sendWithAsyncReply() for WebPage::TryClose IPC
https://bugs.webkit.org/show_bug.cgi?id=204926

Reviewed by Alex Christensen.

Use sendWithAsyncReply() for WebPage::TryClose IPC, instead of 2 separate IPCs.

  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::closeBrowsingContext):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::tryClose):
(WebKit::WebPageProxy::closePage):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebPageProxy.messages.in:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::tryClose):
(WebKit::WebPage::sendClose):

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/WebPage.messages.in:
4:34 PM Changeset in webkit [253186] by Chris Dumez
  • 2 edits in trunk/Source/WTF

[IPC] Fail ObjectIdentifier decoding if the decoded integer is not a valid ID
https://bugs.webkit.org/show_bug.cgi?id=204921
<rdar://problem/57677747>

Reviewed by Ryosuke Niwa.

  • wtf/ObjectIdentifier.h:

(WTF::ObjectIdentifier::decode):

4:26 PM Changeset in webkit [253185] by wilander@apple.com
  • 12 edits in trunk/Source

Resource Load Statistics (experimental): Add fast mode for non-cookie website data deletion
https://bugs.webkit.org/show_bug.cgi?id=204858
<rdar://problem/57639851>

Reviewed by Alex Christensen.

Source/WebCore:

This change adds two internal flags:

  • "Live-On Testing" with a one hour timeout instead of seven days.
  • "Repro Testing" with an instant timeout (bar ITP's regular delays) instead of seven days.

These internal flags should be removed once testing is complete: <rdar://problem/57673418>

No new tests. This change just adds new opt-in settings for manual testing.

  • page/Settings.yaml:
  • platform/network/NetworkStorageSession.h:

The FirstPartyWebsiteDataRemovalMode enum now has two new values:

  • AllButCookiesLiveOnTestingTimeout
  • AllButCookiesReproTestingTimeout

Source/WebKit:

The purpose of this change is to allow for dedicated testing of the change in
https://trac.webkit.org/changeset/253082/webkit. Waiting seven days just isn't a good
starting point.

This change adds two internal flags:

  • "Live-On Testing" with a one hour timeout instead of seven days.
  • "Repro Testing" with an instant timeout (bar ITP's regular delays) instead of seven days.

The change also makes sure that hasHadUnexpiredRecentUserInteraction() in
ResourceLoadStatisticsDatabaseStore and ResourceLoadStatisticsMemoryStore only
age out the user interaction timestamp if the OperatingDatesWindow is Long so
that we don't age out timestamps early with the shorter OperatingDatesWindows.

This change changes the default value of IsFirstPartyWebsiteDataRemovalEnabled to true.

These internal flags should be removed once testing is complete: <rdar://problem/57673418>

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:
  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.cpp:

(WebKit::ResourceLoadStatisticsMemoryStore::hasHadUnexpiredRecentUserInteraction const):
(WebKit::ResourceLoadStatisticsMemoryStore::shouldRemoveAllButCookiesFor const):

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.cpp:

(WebKit::ResourceLoadStatisticsStore::hasStatisticsExpired const):

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::setFirstPartyWebsiteDataRemovalMode):

  • NetworkProcess/NetworkProcess.messages.in:
  • Shared/WebPreferences.yaml:
  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::WebsiteDataStore::parameters):

4:01 PM Changeset in webkit [253184] by Jonathan Bedard
  • 5 edits in trunk/Tools

Python 3: Add support to webkitpy.browserperfdash
https://bugs.webkit.org/show_bug.cgi?id=204887

Reviewed by Stephanie Lewis.

  • Scripts/test-webkitpy-python3: Add webkitpy.browserperfdash.
  • Scripts/webkitpy/benchmark_runner/benchmark_runner.py: Remove urlparse dependency.
  • Scripts/webkitpy/benchmark_runner/webdriver_benchmark_runner.py: Use explicit import.
  • Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py:

(WebServerBenchmarkRunner._run_one_test): Use Python 2/3 compatible urljoin.

3:56 PM Changeset in webkit [253183] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Optimize IPC::Connection::SyncMessageState methods
https://bugs.webkit.org/show_bug.cgi?id=204890

Reviewed by Alex Christensen.

Optimize IPC::Connection::SyncMessageState methods. We are seeing lock contention on some (app launch)
benchmarks, resulting in the main thread yielding for 10ms.

  • Platform/IPC/Connection.cpp:

(IPC::Connection::SyncMessageState): Make constructor private since this is a singleton class.
(IPC::Connection::ConnectionAndIncomingMessage): Add convenience dispatch() method.

(IPC::Connection::SyncMessageState::processIncomingMessage):
Drop the lock as early as possible, *before* calling RunLoop::main().dispatch().

(IPC::Connection::SyncMessageState::dispatchMessages):
Drop allowedConnection parameter and simplify the code a lot as a result. Only dispatchMessagesAndResetDidScheduleDispatchMessagesForConnection()
needed the pass an allowedConnection but having dispatchMessagesAndResetDidScheduleDispatchMessagesForConnection() call dispatchMessages() was
inefficient since it would cause us to grab the lock in dispatchMessagesAndResetDidScheduleDispatchMessagesForConnection() to update
m_didScheduleDispatchMessagesWorkSet, then release it, then grab the lock again in dispatchMessages() for m_messagesToDispatchWhileWaitingForSyncReply.

(IPC::Connection::SyncMessageState::dispatchMessagesAndResetDidScheduleDispatchMessagesForConnection):
Grab the lock only once to update m_didScheduleDispatchMessagesWorkSet and m_messagesToDispatchWhileWaitingForSyncReply, instead of doing it in 2
separate steps, each one taking the lock.

(IPC::Connection::waitForMessage):
(IPC::Connection::waitForSyncReply):
(IPC::Connection::dispatchSyncMessage):
stop passing a null allowedConnection when calling dispatchMessages().

3:55 PM Changeset in webkit [253182] by Chris Dumez
  • 21 edits in trunk/Source

PageConfiguration::dragClient should use a smart pointer
https://bugs.webkit.org/show_bug.cgi?id=204816

Reviewed by Alex Christensen.

Source/WebCore:

  • loader/EmptyClients.cpp:

(WebCore::pageConfigurationWithEmptyClients):

  • page/DragClient.h:
  • page/DragController.cpp:

(WebCore::DragController::DragController):
(WebCore::DragController::~DragController):
(WebCore::DragController::dragEnded):
(WebCore::DragController::performDragOperation):
(WebCore::DragController::delegateDragSourceAction):
(WebCore::DragController::concludeEditDrag):
(WebCore::DragController::startDrag):
(WebCore::DragController::beginDrag):
(WebCore::DragController::doSystemDrag):

  • page/DragController.h:

(WebCore::DragController::client const):

  • page/Page.cpp:

(WebCore::Page::Page):

  • page/PageConfiguration.cpp:
  • page/PageConfiguration.h:
  • page/mac/DragControllerMac.mm:

(WebCore::DragController::declareAndWriteDragImage):

Source/WebKit:

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_overriddenMediaType):

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):

Source/WebKitLegacy/win:

  • WebView.cpp:

(WebView::initWithFrame):

3:53 PM Changeset in webkit [253181] by Chris Dumez
  • 5 edits in trunk/Source

[IPC] Fail BackForwardItemIdentifier decoding if the decoded integer is not a valid ID
https://bugs.webkit.org/show_bug.cgi?id=204920
<rdar://problem/57677453>

Reviewed by Ryosuke Niwa.

Source/WebCore:

  • history/BackForwardItemIdentifier.h:

(WebCore::BackForwardItemIdentifier::decode):

Source/WebKit:

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::willGoToBackForwardListItem):
(WebKit::WebPageProxy::backForwardGoToItemShared):

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::updateBackForwardItem):

3:52 PM Changeset in webkit [253180] by Chris Dumez
  • 2 edits in trunk/Source/WebCore/PAL

[IPC] Fail PAL::SessionID decoding if the decoded integer is not a valid session ID
https://bugs.webkit.org/show_bug.cgi?id=204917
<rdar://problem/53418119>

Reviewed by Ryosuke Niwa.

Fail PAL::SessionID IPC decoding if the decoded integer is not a valid session ID.
This makes our IPC more robust to bad input and makes sure we don't try to lookup
an invalid sessionID from a HashMap as a result of a bad IPC.

  • pal/SessionID.h:

(PAL::SessionID::decode):

3:48 PM Changeset in webkit [253179] by yurys@chromium.org
  • 3 edits in trunk/LayoutTests

Web Inspector: http/tests/inspector/target/pause-on-inline-debugger-statement.html is crashing in debug
https://bugs.webkit.org/show_bug.cgi?id=204901

Reviewed by Devin Rousso.

Restructured the test to avoid inadvertent alert() when navigating to a new
process. New logs are printed after inspected page has navigated.

  • http/tests/inspector/target/pause-on-inline-debugger-statement-expected.txt:
  • http/tests/inspector/target/pause-on-inline-debugger-statement.html:
3:40 PM Changeset in webkit [253178] by sihui_liu@apple.com
  • 18 edits
    1 move
    1 add
    1 delete in trunk/Source

Move InProcessIDBServer to WebKitLegacy
https://bugs.webkit.org/show_bug.cgi?id=204896

Reviewed by Brady Eidson.

Source/WebCore:

We only use InProcessIDBServer in WebKitLegacy now.

No behavior change.

  • Headers.cmake:
  • Modules/indexeddb/server/IDBServer.h:
  • Modules/indexeddb/shared/IDBRequestData.h:
  • Modules/indexeddb/shared/IDBTransactionInfo.h:
  • Modules/indexeddb/shared/InProcessIDBServer.h: Removed.
  • Modules/mediastream/MediaStreamTrack.cpp:
  • Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • loader/EmptyClients.cpp:
  • page/Page.cpp:

Source/WebKit:

  • WebProcess/Databases/WebDatabaseProvider.h:

Source/WebKitLegacy:

  • CMakeLists.txt:
  • Storage/InProcessIDBServer.cpp: Renamed from Source/WebCore/Modules/indexeddb/shared/InProcessIDBServer.cpp.

(InProcessIDBServer::create):
(InProcessIDBServer::quotaManager):
(storageQuotaManagerSpaceRequester):
(InProcessIDBServer::InProcessIDBServer):
(InProcessIDBServer::identifier const):
(InProcessIDBServer::connectionToServer const):
(InProcessIDBServer::connectionToClient const):
(InProcessIDBServer::deleteDatabase):
(InProcessIDBServer::didDeleteDatabase):
(InProcessIDBServer::openDatabase):
(InProcessIDBServer::didOpenDatabase):
(InProcessIDBServer::didAbortTransaction):
(InProcessIDBServer::didCommitTransaction):
(InProcessIDBServer::didCreateObjectStore):
(InProcessIDBServer::didDeleteObjectStore):
(InProcessIDBServer::didRenameObjectStore):
(InProcessIDBServer::didClearObjectStore):
(InProcessIDBServer::didCreateIndex):
(InProcessIDBServer::didDeleteIndex):
(InProcessIDBServer::didRenameIndex):
(InProcessIDBServer::didPutOrAdd):
(InProcessIDBServer::didGetRecord):
(InProcessIDBServer::didGetAllRecords):
(InProcessIDBServer::didGetCount):
(InProcessIDBServer::didDeleteRecord):
(InProcessIDBServer::didOpenCursor):
(InProcessIDBServer::didIterateCursor):
(InProcessIDBServer::abortTransaction):
(InProcessIDBServer::commitTransaction):
(InProcessIDBServer::didFinishHandlingVersionChangeTransaction):
(InProcessIDBServer::createObjectStore):
(InProcessIDBServer::deleteObjectStore):
(InProcessIDBServer::renameObjectStore):
(InProcessIDBServer::clearObjectStore):
(InProcessIDBServer::createIndex):
(InProcessIDBServer::deleteIndex):
(InProcessIDBServer::renameIndex):
(InProcessIDBServer::putOrAdd):
(InProcessIDBServer::getRecord):
(InProcessIDBServer::getAllRecords):
(InProcessIDBServer::getCount):
(InProcessIDBServer::deleteRecord):
(InProcessIDBServer::openCursor):
(InProcessIDBServer::iterateCursor):
(InProcessIDBServer::establishTransaction):
(InProcessIDBServer::fireVersionChangeEvent):
(InProcessIDBServer::didStartTransaction):
(InProcessIDBServer::didCloseFromServer):
(InProcessIDBServer::notifyOpenDBRequestBlocked):
(InProcessIDBServer::databaseConnectionPendingClose):
(InProcessIDBServer::databaseConnectionClosed):
(InProcessIDBServer::abortOpenAndUpgradeNeeded):
(InProcessIDBServer::didFireVersionChangeEvent):
(InProcessIDBServer::openDBRequestCancelled):
(InProcessIDBServer::confirmDidCloseFromServer):
(InProcessIDBServer::getAllDatabaseNames):
(InProcessIDBServer::didGetAllDatabaseNames):

  • Storage/InProcessIDBServer.h: Added.
  • Storage/WebDatabaseProvider.cpp:

(WebDatabaseProvider::idbConnectionToServerForSession):
(WebDatabaseProvider::deleteAllDatabases):

  • Storage/WebDatabaseProvider.h:
  • WebKitLegacy.xcodeproj/project.pbxproj:
3:28 PM Changeset in webkit [253177] by sihui_liu@apple.com
  • 3 edits in trunk/Source/WebKit

Add ThreadMessageReceiver to IPC::Connection
https://bugs.webkit.org/show_bug.cgi?id=204908

Reviewed by Brady Eidson.

ThreadMesageReceiver is similar to WorkQueueMessageReceiver, but it should handle messages (dispatched from IPC
thread) on a specific thread, while WorkQueueMessageReceiver may handle messages on different threads.

  • Platform/IPC/Connection.cpp:

(IPC::Connection::addThreadMessageReceiver):
(IPC::Connection::removeThreadMessageReceiver):
(IPC::Connection::dispatchThreadMessageReceiverMessage):
(IPC::Connection::processIncomingMessage):
(IPC::Connection::dispatchMessageToThreadReceiver):

  • Platform/IPC/Connection.h:

(IPC::Connection::ThreadMessageReceiver::dispatchToThread):

3:28 PM Changeset in webkit [253176] by Simon Fraser
  • 6 edits in trunk/Source

Fix inspector/css test assertions after r253158
https://bugs.webkit.org/show_bug.cgi?id=204924

Reviewed by Devin Rousso.
Source/JavaScriptCore:

Teach the inspector protocol about the ::highlight pseudoelement.

  • inspector/protocol/CSS.json:

Source/WebCore:

  • inspector/agents/InspectorCSSAgent.cpp:

(WebCore::protocolValueForPseudoId):

Source/WebInspectorUI:

  • UserInterface/Controllers/CSSManager.js:

(WI.CSSManager.displayNameForPseudoId):

3:24 PM Changeset in webkit [253175] by Alan Coon
  • 1 copy in tags/Safari-608.5.4

Tag Safari-608.5.4.

3:06 PM Changeset in webkit [253174] by sihui_liu@apple.com
  • 6 edits in trunk/Source/WebCore

Rename IDBDatabaseIdentifier::debugString to IDBDatabaseIdentifier::loggingString
https://bugs.webkit.org/show_bug.cgi?id=204898

Reviewed by Brady Eidson.

We use loggingString everywhere in IDB code but IDBDatabaseIdentifier, so rename it for consistency.

No behavior change.

  • Modules/indexeddb/IDBDatabaseIdentifier.cpp:

(WebCore::IDBDatabaseIdentifier::loggingString const):
(WebCore::IDBDatabaseIdentifier::debugString const): Deleted.

  • Modules/indexeddb/IDBDatabaseIdentifier.h:
  • Modules/indexeddb/client/IDBConnectionToServer.cpp:

(WebCore::IDBClient::IDBConnectionToServer::deleteDatabase):
(WebCore::IDBClient::IDBConnectionToServer::openDatabase):

  • Modules/indexeddb/server/IDBServer.cpp:

(WebCore::IDBServer::IDBServer::deleteDatabase):

  • Modules/indexeddb/server/UniqueIDBDatabase.cpp:

(WebCore::IDBServer::UniqueIDBDatabase::UniqueIDBDatabase):
(WebCore::IDBServer::UniqueIDBDatabase::~UniqueIDBDatabase):
(WebCore::IDBServer::UniqueIDBDatabase::performCurrentDeleteOperation):
(WebCore::IDBServer::UniqueIDBDatabase::deleteBackingStore):

2:55 PM Changeset in webkit [253173] by Devin Rousso
  • 5 edits in trunk/Source/WebInspectorUI

Web Inspector: REGRESSION(r242604): Console: unread indicator overlaps selection background of previous scope bar item
https://bugs.webkit.org/show_bug.cgi?id=204630

Reviewed by Timothy Hatcher.

When a new message is added that is immediately filtered, such as from an existing filter or
previously selected scope bar items, rather than show a blinking circle next to the level of
the new message in the scope bar (which doesn't cover the case where there's a filter and
was often hard to notice), add a dismissable warning banner explaning that the message had
been filtered with a button to clear all filters.

  • UserInterface/Views/LogContentView.js:

(WI.LogContentView):
(WI.LogContentView.prototype.didAppendConsoleMessageView):
(WI.LogContentView.prototype._previousMessageRepeatCountUpdated):
(WI.LogContentView.prototype._logCleared):
(WI.LogContentView.prototype._messageSourceBarSelectionDidChange):
(WI.LogContentView.prototype._scopeBarSelectionDidChange):
(WI.LogContentView.prototype._filterMessageElements):
(WI.LogContentView.prototype._showHiddenMessagesBannerIfNeeded): Added.
(WI.LogContentView.prototype._markScopeBarItemUnread): Deleted.
(WI.LogContentView.prototype._markScopeBarItemForMessageLevelUnread): Deleted.

  • UserInterface/Views/LogContentView.css:

(.content-view.log):
(.content-view.log > .hidden-messages-banner): Added.
(.content-view.log > .hidden-messages-banner > button): Added.
(.content-view.log > .hidden-messages-banner > .dismiss): Added.
(body[dir=ltr] .content-view.log > .hidden-messages-banner > .dismiss): Added.
(body[dir=rtl] .content-view.log > .hidden-messages-banner > .dismiss): Added.
(.console-messages):
(.log-scope-bar > li:not(.unread) > .indicator): Deleted.
(.log-scope-bar > li.unread > .indicator): Deleted.
(.log-scope-bar > li.unread:hover > .indicator): Deleted.
(.log-scope-bar > li.unread.evaluations > .indicator): Deleted.
(.log-scope-bar > li.unread.errors > .indicator): Deleted.
(.log-scope-bar > li.unread.warnings > .indicator): Deleted.
(.log-scope-bar > li.unread.logs > .indicator): Deleted.
(@keyframes unread-background-pulse): Deleted.

  • UserInterface/Views/FindBanner.js:

(WI.FindBanner):
(WI.FindBanner.prototype.clearAndBlur): Added.
(WI.FindBanner.prototype._clearAndBlur): Deleted.
Expose a public way to clear the find banner.

  • Localizations/en.lproj/localizedStrings.js:
2:48 PM Changeset in webkit [253172] by Devin Rousso
  • 17 edits in trunk/Source/WebInspectorUI

Web Inspector: add WI.EngineeringSetting and WI.DebugSetting to avoid callsite checking
https://bugs.webkit.org/show_bug.cgi?id=204785

Reviewed by Timothy Hatcher.

  • UserInterface/Base/Setting.js:

(WI.Setting.prototype.get defaultValue): Added.
(WI.EngineeringSetting.prototype.get value): Added.
(WI.EngineeringSetting.prototype.set value): Added.
(WI.DebugSetting.prototype.get value): Added.
(WI.DebugSetting.prototype.set value): Added.
(WI.Setting.prototype.get valueRespectingDebugUIAvailability): Deleted.
Only get/set the _value if the WI.isEngineeringBuild/WI.isDebugUIEnabled().

  • UserInterface/Base/Main.js:

(WI.resolvedLayoutDirection):

  • UserInterface/Protocol/RemoteObject.js:

(WI.RemoteObject.prototype.findFunctionSourceCodeLocation):

  • UserInterface/Models/CSSProperty.js:

(WI.CSSProperty.prototype._updateOwnerStyleText):

  • UserInterface/Models/CSSStyleDeclaration.js:

(WI.CSSStyleDeclaration.prototype.update):

  • UserInterface/Proxies/HeapSnapshotEdgeProxy.js:

(WI.HeapSnapshotEdgeProxy.prototype.isPrivateSymbol):

  • UserInterface/Controllers/DOMManager.js:

(WI.DOMManager.prototype.supportsEditingUserAgentShadowTrees):

  • UserInterface/Controllers/DebuggerManager.js:

(WI.DebuggerManager.prototype.get knownNonResourceScripts):
(WI.DebuggerManager.prototype.debuggerDidPause):
(WI.DebuggerManager.prototype.scriptDidParse):

  • UserInterface/Controllers/DiagnosticController.js:

(WI.DiagnosticController):
(WI.DiagnosticController.prototype._debugAutoLogDiagnosticEventsSettingDidChange):
(WI.DiagnosticController.prototype._updateRecorderStates):

  • UserInterface/Views/ConsoleMessageView.js:

(WI.ConsoleMessageView.prototype._appendLocationLink):

  • UserInterface/Views/HeapSnapshotDataGridTree.js:

(WI.HeapSnapshotInstancesDataGridTree.prototype.populateTopLevel):

  • UserInterface/Views/OpenResourceDialog.js:

(WI.OpenResourceDialog.prototype._addScriptsForTarget):

  • UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:

(WI.SpreadsheetCSSStyleDeclarationEditor):

  • UserInterface/Views/StackTraceView.js:

(WI.StackTraceView):

  • UserInterface/Views/View.js:

(WI.View.prototype._layoutSubtree):

  • UserInterface/Debug/UncaughtExceptionReporter.js:

(handleUncaughtExceptionRecord):

2:32 PM Changeset in webkit [253171] by Tadeu Zagallo
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION(r253140): Wasm::FunctionParser needs to bounds check in SetLocal/TeeLocal
https://bugs.webkit.org/show_bug.cgi?id=204909

Reviewed by Keith Miller.

When moving the code from WasmValidate.cpp to WasmFunctionParser.h, I missed that SetLocal and
TeeLocal used to call Wasm::Validate::getLocal, which would perform the bounds check. I just
added back the checks to the parser before accessing the local's type from m_locals.

  • wasm/WasmFunctionParser.h:

(JSC::Wasm::FunctionParser<Context>::parseExpression):

1:22 PM Changeset in webkit [253170] by Alan Bujtas
  • 12 edits
    1 copy in trunk/Source/WebCore

[LFC][IFC] Introduce InlineSoftLineBreakItem
https://bugs.webkit.org/show_bug.cgi?id=204905
<rdar://problem/57672472>

Reviewed by Antti Koivisto.

Preserved line breaks apparently require text-line inline boxes with position information.
This patch provides this position information by introducing InlineSoftLineBreakItem.
InlineSoftLineBreakItem is a non-text like subclass of InlineItem which is created when
the text content has a preserved line break.

<pre>text content
</pre>
-> [InlineTextItem(text)][InlineTextItem( )][InlineTextItem(content)][InlineSoftLineBreakItem]

  • WebCore.xcodeproj/project.pbxproj:
  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::collectInlineContentIfNeeded):
(WebCore::Layout::InlineFormattingContext::setDisplayBoxesForLine):

  • layout/inlineformatting/InlineFormattingContextQuirks.cpp:

(WebCore::Layout::InlineFormattingContext::Quirks::lineDescentNeedsCollapsing const):

  • layout/inlineformatting/InlineItem.cpp:
  • layout/inlineformatting/InlineItem.h:

(WebCore::Layout::InlineItem::isLineBreak const):
(WebCore::Layout::InlineItem::isSoftLineBreak const):
(WebCore::Layout::InlineItem::isHardLineBreak const):
(WebCore::Layout::InlineItem::isForcedLineBreak const): Deleted.

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::Content::isAtContentBoundary):
(WebCore::Layout::LineBreaker::Content::append):

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::alignContentVertically):
(WebCore::Layout::LineBuilder::append):
(WebCore::Layout::LineBuilder::appendLineBreak):
(WebCore::Layout::LineBuilder::adjustBaselineAndLineHeight):
(WebCore::Layout::LineBuilder::runContentHeight const):
(WebCore::Layout::LineBuilder::isVisuallyNonEmpty const):
(WebCore::Layout::LineBuilder::TrimmableContent::trim):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::Run::isLineBreak const):
(WebCore::Layout::LineBuilder::InlineItemRun::isLineBreak const):
(WebCore::Layout::LineBuilder::Run::isForcedLineBreak const): Deleted.
(WebCore::Layout::LineBuilder::InlineItemRun::isForcedLineBreak const): Deleted.

  • layout/inlineformatting/InlineSoftLineBreakItem.h: Copied from Source/WebCore/layout/inlineformatting/InlineItem.cpp.

(WebCore::Layout::InlineSoftLineBreakItem::position const):
(WebCore::Layout::InlineSoftLineBreakItem::createSoftLineBreakItem):
(WebCore::Layout::InlineSoftLineBreakItem::InlineSoftLineBreakItem):

  • layout/inlineformatting/InlineTextItem.cpp:

(WebCore::Layout::InlineTextItem::createAndAppendTextItems):
(WebCore::Layout::InlineTextItem::createSegmentBreakItem): Deleted.

  • layout/inlineformatting/InlineTextItem.h:

(WebCore::Layout::InlineTextItem::isWhitespace const):
(WebCore::Layout::InlineTextItem::isCollapsible const):
(WebCore::Layout::InlineTextItem::isSegmentBreak const): Deleted.

  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::inlineItemWidth):
(WebCore::Layout::LineLayoutContext::placeInlineItem):

1:18 PM Changeset in webkit [253169] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Console: copying an evaluation result shouldn't include the saved variable index
https://bugs.webkit.org/show_bug.cgi?id=204906

Reviewed by Timothy Hatcher.

  • UserInterface/Views/ConsoleMessageView.js:

(WI.ConsoleMessageView.prototype.toClipboardString):

1:05 PM Changeset in webkit [253168] by Tadeu Zagallo
  • 2 edits in trunk/Source/JavaScriptCore

[WebAssembly] Fix bad assertion in LLIntPlan
https://bugs.webkit.org/show_bug.cgi?id=204893

Reviewed by Mark Lam.

Before landing r253140 I introduced an assertion in Wasm::LLIntPlan that the pointer to previously
compiled callees must be non-null. However, it's perfectly valid for the pointer to be null when the
module has no functions.

  • wasm/WasmLLIntPlan.cpp:

(JSC::Wasm::LLIntPlan::LLIntPlan):

1:03 PM Changeset in webkit [253167] by Devin Rousso
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: the Classes toggle is drawn on top of other content with no other way of scrolling to it
https://bugs.webkit.org/show_bug.cgi?id=204690

Reviewed by Timothy Hatcher.

Use a vertical flexbox for the contents of sidebar panels instead of absolute positioning so
that the variable height Classes "drawer" can have it's own scroll area and doesn't take up
any space from the rest of the panel's contents.

  • UserInterface/Views/GeneralStyleDetailsSidebarPanel.js:

(WI.GeneralStyleDetailsSidebarPanel.prototype.initialLayout):

  • UserInterface/Views/GeneralStyleDetailsSidebarPanel.css:

(.sidebar > .panel.details.css-style > .content):
(.sidebar > .panel.details.css-style > .content ~ :matches(.options-container, .class-list-container)):
(.sidebar > .panel.details.css-style > .content ~ .options-container):
(.sidebar > .panel.details.css-style > .content ~ .class-list-container):
(.sidebar > .panel.details.css-style > .content.has-filter-bar): Deleted.

  • UserInterface/Views/Sidebar.css:

(.sidebar > .panel):
(.sidebar > .panel.selected): Deleted.

12:35 PM Changeset in webkit [253166] by yurys@chromium.org
  • 5 edits
    2 adds in trunk

Web Inspector: Avoid using Runtime.executionContextCreated to figure out the iframe's contentDocument node.
https://bugs.webkit.org/show_bug.cgi?id=122764
<rdar://problem/15222136>

Reviewed by Devin Rousso.

Source/WebCore:

Force execution context creation on frame navigation similar to what inspector already
does for all known contexts when Runtime.enable is called. This is a prerequisite for
the injected script to work.

Test: inspector/runtime/execution-context-in-scriptless-page.html

  • inspector/InspectorInstrumentation.cpp:

(WebCore::InspectorInstrumentation::didCommitLoadImpl):

  • inspector/agents/page/PageRuntimeAgent.cpp:

(WebCore::PageRuntimeAgent::frameNavigated):

  • inspector/agents/page/PageRuntimeAgent.h:

LayoutTests:

Test that execution context is created and reported for pages without JavaScript.

  • inspector/runtime/execution-context-in-scriptless-page-expected.txt: Added.
  • inspector/runtime/execution-context-in-scriptless-page.html: Added.
12:33 PM Changeset in webkit [253165] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Search: there should be some default content when there is no search string
https://bugs.webkit.org/show_bug.cgi?id=204631

Reviewed by Timothy Hatcher.

It's very odd to switch to the Search Tab and find it completely empty, especially if you've
never used it before.

Add basic "No Search String" and "No Search Results" text with a clickable help navigation
item that reveals and focuses the sidebar search input.

  • UserInterface/Views/SearchSidebarPanel.js:

(WI.SearchSidebarPanel.prototype.showDefaultContentView): Added.
(WI.SearchSidebarPanel.prototype.performSearch):
(WI.SearchSidebarPanel.prototype._handleDefaultContentViewSearchNavigationItemClicked): Added.

  • Localizations/en.lproj/localizedStrings.js:
12:23 PM Changeset in webkit [253164] by mark.lam@apple.com
  • 5 edits in trunk/Source/JavaScriptCore

computeIfUsingFuzzerAgent() is called before parsing command line arguments.
https://bugs.webkit.org/show_bug.cgi?id=204886

Reviewed by Saam Barati.

Rolling out r253015 which introduced computeIfUsingFuzzerAgent().

  • runtime/Options.cpp:

(JSC::Options::initialize):
(JSC::computeIfUsingFuzzerAgent): Deleted.

  • runtime/Options.h:

(JSC::Options::isUsingFuzzerAgent): Deleted.

  • runtime/OptionsList.h:

(JSC::OptionRange::operator bool const): Deleted.

  • runtime/VM.cpp:

(JSC::VM::VM):

12:20 PM Changeset in webkit [253163] by Chris Dumez
  • 7 edits
    1 add in trunk/Source

MESSAGE_CHECK BackForwardItemIdentifier on incoming IPC from the WebProcess
https://bugs.webkit.org/show_bug.cgi?id=204899

Reviewed by Ryosuke Niwa.

Source/WebCore:

  • Sources.txt:
  • history/BackForwardItemIdentifier.cpp: Added.

(WebCore::BackForwardItemIdentifier::isValid const):

  • history/BackForwardItemIdentifier.h:

(WebCore::operator!=):

Source/WebKit:

MESSAGE_CHECK BackForwardItemIdentifier on incoming IPC from the WebProcess. This is important since we use this identifier
to look up the WebBackForwardListItem in a HashMap, and looking up a bad ID could corrupt said HashMap.

  • Shared/WebBackForwardListItem.cpp:

Make sure the WebBackForwardListItem is always constructed and destroyed on the main thread, to avoid corrupting
the allItems() HashMap.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::willGoToBackForwardListItem):
(WebKit::WebPageProxy::backForwardGoToItemShared):

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::updateBackForwardItem):

12:18 PM Changeset in webkit [253162] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: move the "Add Breakpoint" context menu to be next to the blackboxing context menu item
https://bugs.webkit.org/show_bug.cgi?id=204833

Reviewed by Timothy Hatcher.

Both items are related to JavaScript debugging, so they should be closer together.

  • UserInterface/Views/ContextMenuUtilities.js:

(WI.appendContextMenuItemsForSourceCode):

12:16 PM Changeset in webkit [253161] by Devin Rousso
  • 6 edits in trunk/Source/WebInspectorUI

Web Inspector: Support search on IndexedDB stores and indexes
https://bugs.webkit.org/show_bug.cgi?id=129208
<rdar://problem/16142046>

Reviewed by Timothy Hatcher.

Add filter bars to the navigation bars for IndexedDB, LocalStorage, and SessionStorage.

  • UserInterface/Views/StorageTabContentView.js:

(WI.StorageTabContentView.prototype.get canHandleFindEvent): Added.
(WI.StorageTabContentView.prototype.handleFindEvent): Added.

  • UserInterface/Views/DOMStorageContentView.js:

(WI.DOMStorageContentView):
(WI.DOMStorageContentView.prototype.get navigationItems): Added.
(WI.DOMStorageContentView.prototype.get canFocusFilterBar): Added.
(WI.DOMStorageContentView.prototype.focusFilterBar): Added.
(WI.DOMStorageContentView.prototype._handleFilterBarFilterDidChange): Added.

  • UserInterface/Views/IndexedDatabaseObjectStoreContentView.js:

(WI.IndexedDatabaseObjectStoreContentView):
(WI.IndexedDatabaseObjectStoreContentView.prototype.get navigationItems):
(WI.IndexedDatabaseObjectStoreContentView.prototype.get canFocusFilterBar): Added.
(WI.IndexedDatabaseObjectStoreContentView.prototype.focusFilterBar): Added.
(WI.IndexedDatabaseObjectStoreContentView.prototype.dataGridMatchNodeAgainstCustomFilters): Added.
(WI.IndexedDatabaseObjectStoreContentView.prototype._handleFilterBarFilterDidChange): Added.
Check against the textContent of each cell for a given WI.DataGridNode to see if it
matches the filter text as all of the pieces of data are WI.RemoteObjects.

  • UserInterface/Views/FilterBar.css:

(.filter-bar):

  • UserInterface/Views/NetworkTableContentView.css:

(.content-view.network .navigation-bar .filter-bar): Deleted.
Remove the background-color to let it match the background content.

11:55 AM Changeset in webkit [253160] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Network: pressing ⌘F when no network item is selected should focus the filter bar
https://bugs.webkit.org/show_bug.cgi?id=204862

Reviewed by Timothy Hatcher.

  • UserInterface/Views/NetworkTabContentView.js:

(WI.NetworkTabContentView.prototype.get canHandleFindEvent): Added.
(WI.NetworkTabContentView.prototype.handleFindEvent): Added.

  • UserInterface/Views/NetworkTableContentView.js:

(WI.NetworkTableContentView.prototype.get canFocusFilterBar): Added.
(WI.NetworkTableContentView.prototype.focusFilterBar): Added.

11:53 AM Changeset in webkit [253159] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Quick Console: pressing ⌘F shows a second find banner
https://bugs.webkit.org/show_bug.cgi?id=204861

Reviewed by Timothy Hatcher.

  • UserInterface/Views/LogContentView.js:

(WI.LogContentView.prototype.get supportsCustomFindBanner):

11:26 AM Changeset in webkit [253158] by Simon Fraser
  • 6 edits in trunk/Source/WebCore

Add CSS parser support for the highlight pseudoelement
https://bugs.webkit.org/show_bug.cgi?id=204902

Reviewed by Antti Koivisto.

Add basic CSS parsing support for ::highlight(), per
https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/master/highlight/explainer.md

  • css/CSSSelector.cpp:

(WebCore::CSSSelector::pseudoId):
(WebCore::CSSSelector::parsePseudoElementType):

  • css/CSSSelector.h:
  • css/SelectorPseudoElementTypeMap.in:
  • css/parser/CSSSelectorParser.cpp:

(WebCore::CSSSelectorParser::consumePseudo):

  • rendering/style/RenderStyleConstants.h:
11:26 AM Changeset in webkit [253157] by Simon Fraser
  • 6 edits in trunk/Source/WebKit

Minor RemoteLayerTree logging cleanup
https://bugs.webkit.org/show_bug.cgi?id=204865

Reviewed by Tim Horton.

Have the ::description() methods return Strings like everything else does.
Use LOG_WITH_STREAM() so we don't call description() unless the log channel is on.

  • Shared/RemoteLayerTree/RemoteLayerTreeTransaction.h:
  • Shared/RemoteLayerTree/RemoteLayerTreeTransaction.mm:

(WebKit::RemoteLayerTreeTransaction::dump const):
(WebKit::RemoteLayerTreeTransaction::description const):

  • Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.cpp:

(WebKit::RemoteScrollingCoordinatorTransaction::description const):
(WebKit::RemoteScrollingCoordinatorTransaction::dump const):

  • Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.h:
  • UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.mm:

(WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):

10:56 AM Changeset in webkit [253156] by sihui_liu@apple.com
  • 2 edits in trunk/Tools

Fix a Typo in IndexedDBInPageCache.html
https://bugs.webkit.org/show_bug.cgi?id=204897

Reviewed by Chris Dumez.

  • TestWebKitAPI/Tests/WebKitCocoa/IndexedDBInPageCache.html:
10:29 AM Changeset in webkit [253155] by Kate Cheney
  • 2 edits in trunk/Source/WebKit

[MSVC] WebResourceLoadStatisticsStore.h is reporting warning C4804: '/': unsafe use of type 'bool' in operation
https://bugs.webkit.org/show_bug.cgi?id=204870

Reviewed by Darin Adler.

This patch converts storageAccessGranted to a char since makeString()
does not explicitly accept bool types.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:

(WebKit::ThirdPartyDataForSpecificFirstParty::toString const):

10:10 AM Changeset in webkit [253154] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Trim trailing letter-spacing at inline container boundary
https://bugs.webkit.org/show_bug.cgi?id=204895
<rdar://problem/57666898>

Reviewed by Antti Koivisto.

According to https://www.w3.org/TR/css-text-3/#letter-spacing-property, "An inline box only
includes letter spacing between characters completely contained within that element".
This patch enables this behavior by trimming the trailing letter spacing at [container end].

<div>1<span style="letter-spacing: 100px;">2</span>3</div> ->
[1][container start][2][container end][3]
vs.
[1][container start][2<-----100px----->][container end][3]

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::removeTrailingTrimmableContent):
(WebCore::Layout::LineBuilder::appendInlineContainerEnd):
(WebCore::Layout::LineBuilder::TrimmableContent::trim):
(WebCore::Layout::LineBuilder::TrimmableContent::trimTrailingRun):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::TrimmableContent::isTrailingRunPartiallyTrimmable const):

9:44 AM Changeset in webkit [253153] by youenn@apple.com
  • 18 edits
    1 copy
    4 adds in trunk

maplike should define a set method
https://bugs.webkit.org/show_bug.cgi?id=204877

Reviewed by Chris Dumez.

Source/WebCore:

maplike implementation was defining an add method instead of a set method.
Update implementation to define and use a set method.
Add an InternalsMapLike to allow testing.

Test: js/dom/maplike.html

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Modules/highlight/HighlightMap.cpp:

(WebCore::HighlightMap::addFromMapLike):

  • Modules/highlight/HighlightMap.h:
  • Modules/highlight/HighlightMap.idl:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSDOMMapLike.h:

(WebCore::DOMMapLike::set):
(WebCore::forwardSetToMapLike):

  • bindings/scripts/IDLParser.pm:

(parseMapLikeProperties):

  • bindings/scripts/test/JS/JSMapLike.cpp:

(WebCore::jsMapLikePrototypeFunctionSetBody):
(WebCore::jsMapLikePrototypeFunctionSet):
(WebCore::jsMapLikePrototypeFunctionAddBody): Deleted.
(WebCore::jsMapLikePrototypeFunctionAdd): Deleted.

  • testing/Internals.cpp:

(WebCore::Internals::createInternalsMapLike):

  • testing/Internals.h:
  • testing/Internals.idl:
  • testing/InternalsMapLike.cpp: Added.
  • testing/InternalsMapLike.h: Added.
  • testing/InternalsMapLike.idl: Added.

LayoutTests:

  • highlight/highlight-interfaces-expected.txt:
  • highlight/highlight-interfaces.html:
  • js/dom/maplike-expected.txt: Added.
  • js/dom/maplike.html: Added.
9:26 AM Changeset in webkit [253152] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

[LFC][Integration] Disable LFC when floats are present for now
https://bugs.webkit.org/show_bug.cgi?id=204892

Reviewed by Zalan Bujtas.

Diasable until we start synthesizing the required structures.

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::canUseFor):

9:11 AM Changeset in webkit [253151] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Many render tree dump tests show 1px too narrow runs
https://bugs.webkit.org/show_bug.cgi?id=204885

Reviewed by Zalan Bujtas.

Width measurement is currently clamping the measured (float) text widths to layout units. Use rounding instead.

This doesn't solve the fundamental problem of loss of precision but it allows many more render tree dump
based layout tests to pass.

  • layout/inlineformatting/text/TextUtil.cpp:

(WebCore::Layout::TextUtil::width):
(WebCore::Layout::TextUtil::fixedPitchWidth):

7:33 AM Changeset in webkit [253150] by Philippe Normand
  • 2 edits in trunk/Source/WebKit

[GLib] Display GStreamer version in about:gpu page

Rubber-stamped by Carlos Garcia Campos.

  • UIProcess/API/glib/WebKitProtocolHandler.cpp:

(WebKit::WebKitProtocolHandler::handleGPU):

7:24 AM Changeset in webkit [253149] by youenn@apple.com
  • 21 edits in trunk

inspector/page/overrideSetting-MockCaptureDevicesEnabled.html is failing after removal of internals.setMockMediaCaptureDevicesEnabled API
https://bugs.webkit.org/show_bug.cgi?id=204849

Reviewed by Eric Carlson.

Source/WebCore:

Add API and internals to check which center is used in WebProcess.
Covered by updated test.

  • platform/mock/MockRealtimeMediaSourceCenter.cpp:

(WebCore::MockRealtimeMediaSourceCenter::setMockRealtimeMediaSourceCenterEnabled):
(WebCore::MockRealtimeMediaSourceCenter::mockRealtimeMediaSourceCenterEnabled):

  • platform/mock/MockRealtimeMediaSourceCenter.h:
  • testing/Internals.cpp:

(WebCore::Internals::isMockRealtimeMediaSourceCenterEnabled):

  • testing/Internals.h:
  • testing/Internals.idl:

Source/WebKit:

Synchronize the center with the preferences when the value might be updated.
Add API to check which center is used in UIProcess.

  • UIProcess/API/C/WKPage.cpp:

(WKPageIsMockRealtimeMediaSourceCenterEnabled):

  • UIProcess/API/C/WKPagePrivate.h:
  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::UserMediaPermissionRequestManagerProxy):
(WebKit::UserMediaPermissionRequestManagerProxy::setMockCaptureDevicesEnabledOverride):

  • UIProcess/UserMediaPermissionRequestManagerProxy.h:

(WebKit::UserMediaPermissionRequestManagerProxy::setMockCaptureDevicesEnabledOverride): Deleted.

Tools:

Add test runner API to check which center (mock or not) is used in UIProcess side.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::isMockRealtimeMediaSourceCenterEnabled):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::isMockRealtimeMediaSourceCenterEnabled const):

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

LayoutTests:

Update test to use center state getters.

  • inspector/page/overrideSetting-MockCaptureDevicesEnabled-expected.txt:
  • inspector/page/overrideSetting-MockCaptureDevicesEnabled.html:
6:27 AM Changeset in webkit [253148] by eric.carlson@apple.com
  • 13 edits in trunk

WPT test MediaStream-MediaElement-srcObject.https.html times out
https://bugs.webkit.org/show_bug.cgi?id=204762
<rdar://problem/57567671>

Reviewed by youenn fablet.

LayoutTests/imported/w3c:

  • web-platform-tests/mediacapture-streams/MediaStream-MediaElement-firstframe.https-expected.txt:
  • web-platform-tests/mediacapture-streams/MediaStream-MediaElement-srcObject.https-expected.txt:
  • web-platform-tests/mediacapture-streams/MediaStream-MediaElement-srcObject.https.html:

Source/WebCore:

No new tests, these changes fix existing tests.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::prepareForLoad): Check hasMediaStreamSrcObject() instead of
m_mediaStreamSrcObject so we behave correctly when a MediaStream is cleared by setting srcObject to null.
(WebCore::HTMLMediaElement::loadResource): Ditto.
(WebCore::HTMLMediaElement::seekWithTolerance): Return early if seeking isn't allowed.
(WebCore::HTMLMediaElement::defaultPlaybackRate const): Check hasMediaStreamSrcObject() instead
of m_mediaStreamSrcObject.
(WebCore::HTMLMediaElement::setDefaultPlaybackRate): Ditto.
(WebCore::HTMLMediaElement::playbackRate const): Ditto.
(WebCore::HTMLMediaElement::setPlaybackRate): Ditto.
(WebCore::HTMLMediaElement::ended const): Ditto.
(WebCore::HTMLMediaElement::preload const): Ditto.
(WebCore::HTMLMediaElement::setPreload): Ditto.
(WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Don't send an 'ended' event for a MediaStream.
(WebCore::HTMLMediaElement::clearMediaPlayer): Don't check m_settingMediaStreamSrcObject, it
is never set.

  • html/HTMLMediaElement.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h: Add m_lastReportedTime.
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::durationMediaTime const): Return last reported
time after the stream ends.
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentMediaTime const): Ditto. Set m_lastReportedTime.
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentReadyState): Don't return HaveNothing
for an inactive stream. Return HaveMetadata for an stream that has either ended or is waiting
for the first video frame.
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::activeStatusChanged): Send duration changed when
a stream ends.

LayoutTests:

  • TestExpectations: Mark imported/w3c/web-platform-tests/mediacapture-streams/MediaStream-MediaElement-srcObject.https.html

as expected to fail because the failure message logs media times as floats, so the values
logged are always different.

6:11 AM Changeset in webkit [253147] by Alan Bujtas
  • 8 edits in trunk

[LFC][IFC] Move trailing trimming logic to LineBuilder::TrimmableContent
https://bugs.webkit.org/show_bug.cgi?id=204872
<rdar://problem/57652365>

Reviewed by Antti Koivisto.

Source/WebCore:

Move trimming logic from LineBuilder::removeTrailingTrimmableContent to inside TrimmableContent.
This is also in preparation for adding partial trimming at inline container boundary.

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::breakingContextForInlineContent):

  • layout/inlineformatting/InlineLineBreaker.h:
  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::LineBuilder):
(WebCore::Layout::LineBuilder::initialize):
(WebCore::Layout::LineBuilder::removeTrailingTrimmableContent):
(WebCore::Layout::LineBuilder::appendTextContent):
(WebCore::Layout::LineBuilder::appendNonReplacedInlineBox):
(WebCore::Layout::LineBuilder::TrimmableContent::TrimmableContent):
(WebCore::Layout::LineBuilder::TrimmableContent::append):
(WebCore::Layout::LineBuilder::TrimmableContent::trim):

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::isTrailingRunFullyTrimmable const):
(WebCore::Layout::LineBuilder::TrimmableContent::isTrailingRunFullyTrimmable const):
(WebCore::Layout::LineBuilder::TrimmableContent::reset):
(WebCore::Layout::LineBuilder::isTrailingContentFullyTrimmable const): Deleted.
(WebCore::Layout::LineBuilder::TrimmableContent::isTrailingContentFullyTrimmable const): Deleted.
(WebCore::Layout::LineBuilder::TrimmableContent::clear): Deleted.

  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::LineLayoutContext::processUncommittedContent):

Tools:

  • LayoutReloaded/misc/LFC-passing-tests.txt:
4:56 AM Changeset in webkit [253146] by youenn@apple.com
  • 10 edits in trunk

getStats() promise never rejects nor resolves when peer connection state is closed.
https://bugs.webkit.org/show_bug.cgi?id=204842
<rdar://problem/57617107>

Reviewed by Eric Carlson.

Source/WebCore:

Instead of closing and nulling the backend when closing the peer connection,
we only close it. This allows calling getStats to retrieve the last gathered stats from the backend.
Covered by updated test.

  • Modules/mediastream/PeerConnectionBackend.h:
  • Modules/mediastream/RTCPeerConnection.cpp:

(WebCore::RTCPeerConnection::close):
(WebCore::RTCPeerConnection::stop):

  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:

(WebCore::LibWebRTCMediaEndpoint::close):

  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h:
  • Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp:

(WebCore::LibWebRTCPeerConnectionBackend::close):

  • Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h:

LayoutTests:

  • webrtc/video-stats-expected.txt:
  • webrtc/video-stats.html:

Dec 4, 2019:

11:17 PM Changeset in webkit [253145] by jh718.park@samsung.com
  • 3 edits in trunk/Source/WebKit

Unreviewed. Remove build warnings below since r253025.
warning: unused variable ‘iter’ [-Wunused-variable]
warning: unused variable ‘isNewEntry’ [-Wunused-variable]

No new tests, no new behavioral changes.

Patch by Joonghun Park <jh718.park@samsung.com> on 2019-12-04

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::addSessionStorageQuotaManager):

  • NetworkProcess/NetworkProcess.h:

(WebKit::NetworkProcess::SessionStorageQuotaManager::ensureOriginStorageQuotaManager):

10:26 PM Changeset in webkit [253144] by ysuzuki@apple.com
  • 3 edits
    2 adds in trunk

[JSC] AI should convert IsCellWithType to constant when Structure set is finite
https://bugs.webkit.org/show_bug.cgi?id=204141

Reviewed by Mark Lam.

JSTests:

  • stress/generator-cell-with-type.js: Added.

(shouldBe):
(shouldThrow):
(test):
(i.shouldThrow):

  • stress/is-cell-with-type-should-check-non-cell-cases.js: Added.

(getter):
(foo):

Source/JavaScriptCore:

We should fold IsCellWithType if Structure set is finite since we have a chance to know what JSType is.
The difference from the last patch is that we have if (!(child.m_type & ~SpecCell)) check. Even if
structures meet the requirement, this structures do not guarantee that non cell types never come. We
should ensure it by using proven type.

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

10:19 PM Changeset in webkit [253143] by ysuzuki@apple.com
  • 11 edits in trunk/Source/JavaScriptCore

[JSC] Put TypedArrays in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204867

Reviewed by Mark Lam.

This patch puts TypedArrays in IsoSubspace.

  • JSArrayBuffer
  • JSDataView
  • JSInt8Array
  • JSInt16Array
  • JSInt32Array
  • JSUint8Array
  • JSUint8ClampedArray
  • JSUint16Array
  • JSUint32Array
  • JSFloat32Array
  • JSFloat64Array
  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileNewTypedArrayWithSize):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileNewTypedArray):

  • runtime/JSArrayBuffer.h:
  • runtime/JSArrayBufferView.h:

(JSC::JSArrayBufferView::subspaceFor):

  • runtime/JSDataView.h:
  • runtime/JSGenericTypedArrayView.h:
  • runtime/JSTypedArrays.h:
  • runtime/TypedArrayAdaptors.h:
  • runtime/VM.cpp:
  • runtime/VM.h:
9:02 PM Changeset in webkit [253142] by Fujii Hironori
  • 2 edits in trunk/Tools

run-javascriptcore-tests is failing to run testmasm of 64bit AppleWin on Buildbot
https://bugs.webkit.org/show_bug.cgi?id=204869

Reviewed by Per Arne Vollan.

testmasm is compiled only when DEVELOPER_MODE.
Enable DEVELOPER_MODE for all 64bit Windows builds.

  • Scripts/webkitdirs.pm:
(generateBuildSystemFromCMakeProject): Replaced "isFTW()
isWinCairo()" with isWin64()

in the condition of enabling DEVELOPER_MODE.

8:51 PM Changeset in webkit [253141] by rniwa@webkit.org
  • 9 edits
    4 deletes in trunk/Source/WebCore

Remove DocumentEventQueue and WorkerEventQueue
https://bugs.webkit.org/show_bug.cgi?id=204841

Reviewed by Sam Weinig.

Delete DocumentEventQueue and WorkerEventQueue since we don't use them after r252824.

  • Headers.cmake:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • dom/Document.h:
  • dom/DocumentEventQueue.cpp: Removed.
  • dom/DocumentEventQueue.h: Removed.
  • page/VisualViewport.cpp:
  • rendering/RenderLayer.cpp:
  • rendering/RenderListBox.cpp:
  • workers/WorkerEventQueue.cpp: Removed.
  • workers/WorkerEventQueue.h: Removed.
  • worklets/WorkletGlobalScope.h:
8:41 PM Changeset in webkit [253140] by Tadeu Zagallo
  • 33 edits
    1 delete in trunk/Source/JavaScriptCore

[WebAssembly] Validate and generate bytecode in one pass
https://bugs.webkit.org/show_bug.cgi?id=204474

Reviewed by Saam Barati.

Currently, we traverse the WebAssembly code twice:

  • a first serial pass that validates all functions
  • a second concurrent pass that compiles all functions.

In this patch, we move the validation into the parser and update the LLIntPlan so that we no longer have
the first pass. Instead, we now validate concurrently at the same time we generate bytecode.

As a result, when we call WebAssembly.validate, we'll still generate bytecode for the module, but it will
be thrown away. If the module is constructed with new WebAssembly.Module, we'll also eagerly generate
bytecode, but in this case the bytecode is kept and shared across all instantiations of this module.

This is a 1.5x speedup when compiling the ZenGarden demo.

  • DerivedSources.make:
  • wasm/WasmAirIRGenerator.cpp:

(JSC::Wasm::AirIRGenerator::ControlData::ControlData):
(JSC::Wasm::AirIRGenerator::ControlData::isIf):
(JSC::Wasm::AirIRGenerator::ControlData::isTopLevel):
(JSC::Wasm::AirIRGenerator::ControlData::branchTargetArity const):
(JSC::Wasm::AirIRGenerator::ControlData::branchTargetType const):
(JSC::Wasm::AirIRGenerator::emptyExpression):
(JSC::Wasm::AirIRGenerator::emitCallPatchpoint):
(JSC::Wasm::AirIRGenerator::tmpsForSignature):
(JSC::Wasm::AirIRGenerator::emitPatchpoint):
(JSC::Wasm::AirIRGenerator::AirIRGenerator):
(JSC::Wasm::AirIRGenerator::addRefIsNull):
(JSC::Wasm::AirIRGenerator::addTableGet):
(JSC::Wasm::AirIRGenerator::addTableSet):
(JSC::Wasm::AirIRGenerator::addTableGrow):
(JSC::Wasm::AirIRGenerator::addTableFill):
(JSC::Wasm::AirIRGenerator::emitLoopTierUpCheck):
(JSC::Wasm::AirIRGenerator::addLoop):
(JSC::Wasm::AirIRGenerator::addBlock):
(JSC::Wasm::AirIRGenerator::addIf):
(JSC::Wasm::AirIRGenerator::addReturn):
(JSC::Wasm::AirIRGenerator::addEndToUnreachable):
(JSC::Wasm::AirIRGenerator::addCall):
(JSC::Wasm::AirIRGenerator::addCallIndirect):
(JSC::Wasm::AirIRGenerator::unify):
(JSC::Wasm::dumpExpressionStack):
(JSC::Wasm::AirIRGenerator::dump):
(JSC::Wasm::parseAndCompileAir):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncUF64>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncUF32>):

  • wasm/WasmAirIRGenerator.h:
  • wasm/WasmB3IRGenerator.cpp:

(JSC::Wasm::B3IRGenerator::ControlData::ControlData):
(JSC::Wasm::B3IRGenerator::ControlData::isIf):
(JSC::Wasm::B3IRGenerator::ControlData::isTopLevel):
(JSC::Wasm::B3IRGenerator::ControlData::signature const):
(JSC::Wasm::B3IRGenerator::ControlData::hasNonVoidresult const):
(JSC::Wasm::B3IRGenerator::ControlData::branchTargetArity const):
(JSC::Wasm::B3IRGenerator::ControlData::branchTargetType const):
(JSC::Wasm::B3IRGenerator::emptyExpression):
(JSC::Wasm::B3IRGenerator::B3IRGenerator):
(JSC::Wasm::B3IRGenerator::addRefIsNull):
(JSC::Wasm::B3IRGenerator::addTableGet):
(JSC::Wasm::B3IRGenerator::addTableSet):
(JSC::Wasm::B3IRGenerator::addTableGrow):
(JSC::Wasm::B3IRGenerator::addTableFill):
(JSC::Wasm::B3IRGenerator::emitLoopTierUpCheck):
(JSC::Wasm::B3IRGenerator::addLoop):
(JSC::Wasm::B3IRGenerator::addBlock):
(JSC::Wasm::B3IRGenerator::addIf):
(JSC::Wasm::B3IRGenerator::addReturn):
(JSC::Wasm::B3IRGenerator::endBlock):
(JSC::Wasm::B3IRGenerator::addEndToUnreachable):
(JSC::Wasm::dumpExpressionStack):
(JSC::Wasm::B3IRGenerator::dump):
(JSC::Wasm::parseAndCompile):

  • wasm/WasmB3IRGenerator.h:
  • wasm/WasmBBQPlan.cpp:

(JSC::Wasm::BBQPlan::BBQPlan):
(JSC::Wasm::BBQPlan::work):
(JSC::Wasm::BBQPlan::compileFunction):
(JSC::Wasm::BBQPlan::initializeCallees):
(JSC::Wasm::BBQPlan::didReceiveFunctionData):

  • wasm/WasmBBQPlan.h:
  • wasm/WasmCodeBlock.cpp:

(JSC::Wasm::CodeBlock::create):
(JSC::Wasm::CodeBlock::CodeBlock):

  • wasm/WasmCodeBlock.h:

(JSC::Wasm::CodeBlock::wasmEntrypointCalleeFromFunctionIndexSpace):

  • wasm/WasmEntryPlan.cpp:

(JSC::Wasm::EntryPlan::EntryPlan):
(JSC::Wasm::EntryPlan::parseAndValidateModule):
(JSC::Wasm::EntryPlan::prepare):
(JSC::Wasm::EntryPlan::compileFunctions):
(JSC::Wasm::EntryPlan::complete):

  • wasm/WasmEntryPlan.h:
  • wasm/WasmFunctionParser.h:

(JSC::Wasm::splitStack):
(JSC::Wasm::FunctionParser::TypedExpression::TypedExpression):
(JSC::Wasm::FunctionParser::TypedExpression::type const):
(JSC::Wasm::FunctionParser::TypedExpression::value const):
(JSC::Wasm::FunctionParser::TypedExpression::operator ExpressionType const):
(JSC::Wasm::FunctionParser::TypedExpression::operator-> const):
(JSC::Wasm::FunctionParser::controlStack):
(JSC::Wasm::FunctionParser::validationFail const):
(JSC::Wasm::FunctionParser<Context>::parse):
(JSC::Wasm::FunctionParser<Context>::binaryCase):
(JSC::Wasm::FunctionParser<Context>::unaryCase):
(JSC::Wasm::FunctionParser<Context>::load):
(JSC::Wasm::FunctionParser<Context>::store):
(JSC::Wasm::FunctionParser<Context>::checkBranchTarget):
(JSC::Wasm::FunctionParser<Context>::unify):
(JSC::Wasm::FunctionParser<Context>::parseExpression):
(JSC::Wasm::FunctionParser<Context>::parseUnreachableExpression):

  • wasm/WasmLLIntGenerator.cpp:

(JSC::Wasm::LLIntGenerator::ControlType::topLevel):
(JSC::Wasm::LLIntGenerator::ControlType::loop):
(JSC::Wasm::LLIntGenerator::ControlType::isIf):
(JSC::Wasm::LLIntGenerator::ControlType::isTopLevel):
(JSC::Wasm::LLIntGenerator::ControlType::stackSize const):
(JSC::Wasm::LLIntGenerator::ControlType::signature const):
(JSC::Wasm::LLIntGenerator::ControlType::branchTargetArity const):
(JSC::Wasm::LLIntGenerator::ControlType::branchTargetType const):
(JSC::Wasm::LLIntGenerator::emptyExpression):
(JSC::Wasm::LLIntGenerator::dump):
(JSC::Wasm::LLIntGenerator::getDropKeepCount):
(JSC::Wasm::LLIntGenerator::materializeConstantsAndLocals):
(JSC::Wasm::LLIntGenerator::splitStack):
(JSC::Wasm::parseAndCompileBytecode):
(JSC::Wasm::LLIntGenerator::LLIntGenerator):
(JSC::Wasm::LLIntGenerator::callInformationForCaller):
(JSC::Wasm::LLIntGenerator::addLocal):
(JSC::Wasm::LLIntGenerator::setLocal):
(JSC::Wasm::LLIntGenerator::addLoop):
(JSC::Wasm::LLIntGenerator::addBlock):
(JSC::Wasm::LLIntGenerator::addIf):
(JSC::Wasm::LLIntGenerator::addEndToUnreachable):
(JSC::Wasm::LLIntGenerator::addCall):
(JSC::Wasm::LLIntGenerator::addCallIndirect):

  • wasm/WasmLLIntGenerator.h:
  • wasm/WasmLLIntPlan.cpp:

(JSC::Wasm::LLIntPlan::LLIntPlan):
(JSC::Wasm::LLIntPlan::compileFunction):
(JSC::Wasm::LLIntPlan::didCompleteCompilation):
(JSC::Wasm::LLIntPlan::work):
(JSC::Wasm::LLIntPlan::didReceiveFunctionData):

  • wasm/WasmLLIntPlan.h:
  • wasm/WasmModule.cpp:

(JSC::Wasm::Module::Module):
(JSC::Wasm::makeValidationResult):
(JSC::Wasm::makeValidationCallback):
(JSC::Wasm::Module::validateSync):
(JSC::Wasm::Module::validateAsync):
(JSC::Wasm::Module::getOrCreateCodeBlock):
(JSC::Wasm::Module::compileSync):
(JSC::Wasm::Module::compileAsync):

  • wasm/WasmModule.h:

(JSC::Wasm::Module::create):

  • wasm/WasmOMGPlan.cpp:

(JSC::Wasm::OMGPlan::work):

  • wasm/WasmPlan.cpp:

(JSC::Wasm::Plan::Plan):

  • wasm/WasmPlan.h:

(JSC::Wasm::Plan::dontFinalize):

  • wasm/WasmSlowPaths.cpp:

(JSC::LLInt::slow_path_wasm_throw_exception):

  • wasm/WasmThunks.cpp:

(JSC::Wasm::throwExceptionFromWasmThunkGenerator):

  • wasm/WasmThunks.h:
  • wasm/WasmValidate.cpp:

(JSC::Wasm::Validate::ControlData::isIf):
(JSC::Wasm::Validate::ControlData::isTopLevel):
(JSC::Wasm::Validate::ControlData::blockType const):
(JSC::Wasm::Validate::ControlData::signature const):
(JSC::Wasm::Validate::ControlData::branchTargetArity const):
(JSC::Wasm::Validate::ControlData::branchTargetType const):
(JSC::Wasm::Validate::emptyExpression):
(JSC::Wasm::Validate::addConstant):
(JSC::Wasm::Validate::Validate):
(JSC::Wasm::Validate::addArguments):
(JSC::Wasm::Validate::addTableGet):
(JSC::Wasm::Validate::addTableSet):
(JSC::Wasm::Validate::addTableSize):
(JSC::Wasm::Validate::addTableGrow):
(JSC::Wasm::Validate::addTableFill):
(JSC::Wasm::Validate::addRefIsNull):
(JSC::Wasm::Validate::addRefFunc):
(JSC::Wasm::Validate::addLocal):
(JSC::Wasm::Validate::getLocal):
(JSC::Wasm::Validate::setLocal):
(JSC::Wasm::Validate::getGlobal):
(JSC::Wasm::Validate::setGlobal):
(JSC::Wasm::Validate::addBlock):
(JSC::Wasm::Validate::addLoop):
(JSC::Wasm::Validate::addSelect):
(JSC::Wasm::Validate::addIf):
(JSC::Wasm::Validate::addElse):
(JSC::Wasm::Validate::addElseToUnreachable):
(JSC::Wasm::Validate::addReturn):
(JSC::Wasm::Validate::addBranch):
(JSC::Wasm::Validate::addSwitch):
(JSC::Wasm::Validate::addGrowMemory):
(JSC::Wasm::Validate::addCurrentMemory):
(JSC::Wasm::Validate::endBlock):
(JSC::Wasm::Validate::addEndToUnreachable):
(JSC::Wasm::Validate::addCall):
(JSC::Wasm::Validate::addCallIndirect):
(JSC::Wasm::Validate::load):
(JSC::Wasm::Validate::store):
(JSC::Wasm::Validate::addOp):
(JSC::Wasm::dumpExpressionStack):
(JSC::Wasm::Validate::dump):
(JSC::Wasm::validateFunction):

  • wasm/WasmWorklist.cpp:

(JSC::Wasm::Worklist::enqueue):

  • wasm/generateWasmOpsHeader.py:

(cppType):
(cppMacro):
(opcodeMacroizer):
(opcodeWithTypesMacroizer):
(opcodeWithTypesMacroizer.modifier):
(memoryLoadMacroizer):
(memoryLoadMacroizer.modifier):
(memoryStoreMacroizer):
(memoryStoreMacroizer.modifier):

  • wasm/generateWasmValidateInlinesHeader.py: Removed.
  • wasm/js/JSWebAssembly.cpp:

(JSC::instantiate):
(JSC::webAssemblyValidateFunc):

  • wasm/js/WebAssemblyInstanceConstructor.cpp:

(JSC::constructJSWebAssemblyInstance):

8:29 PM Changeset in webkit [253139] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Nullptr crash in RenderLayoutState::pageLogicalHeight const via RenderGrid::computeIntrinsicLogicalWidths inside RenderMarquee::updateMarqueePosition
https://bugs.webkit.org/show_bug.cgi?id=204527

Patch by Jack Lee <Jack Lee> on 2019-12-04
Reviewed by Ryosuke Niwa.

Source/WebCore:

Test: fast/table/crash-empty-layoutStateStack.html

  • rendering/RenderTable.cpp:

(WebCore::RenderTable::layout):
(WebCore::RenderTable::markForPaginationRelayoutIfNeeded):

LayoutTests:

  • fast/table/crash-empty-layoutStateStack-expected.txt: Added.
  • fast/table/crash-empty-layoutStateStack.html: Added.
8:13 PM Changeset in webkit [253138] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

IPC messages may get processed out of order in some cases
https://bugs.webkit.org/show_bug.cgi?id=204864

Reviewed by Ryosuke Niwa.

IPC messages may get processed out of order in some cases. Connection::SyncMessageState::dispatchMessages()
puts messages it did not process back at the end of the queue, instead of the beginning. This means that
messages added to the queue while Connection::SyncMessageState::dispatchMessages() was running will
incorrectly run *before* the ones dispatchMessages() did not process.

  • Platform/IPC/Connection.cpp:

(IPC::Connection::SyncMessageState::dispatchMessages):

7:20 PM Changeset in webkit [253137] by mark.lam@apple.com
  • 3 edits
    1 add in trunk

Fix missing exception check in ArrayPrototype's fastJoin().
https://bugs.webkit.org/show_bug.cgi?id=204868
<rdar://problem/57516684>

Reviewed by Saam Barati.

JSTests:

  • stress/missing-exception-check-in-array-prototype-fastJoin.js: Added.

Source/JavaScriptCore:

  • runtime/ArrayPrototype.cpp:

(JSC::fastJoin):

5:37 PM Changeset in webkit [253136] by mark.lam@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

Fix a broken assertion in GetByStatus::computeForStubInfoWithoutExitSiteFeedback().
https://bugs.webkit.org/show_bug.cgi?id=204866

Reviewed by Saam Barati.

The assertion wrong assumes that access.offset() cannot be invalid unless the
access.type() is a Miss. However, if the AccessCase is a Custom value or accessor,
the offset is always invalid. This patch fixes this assertion.

  • bytecode/AccessCase.h:

(JSC::AccessCase::isCustom const):

  • bytecode/GetByStatus.cpp:

(JSC::GetByStatus::computeForStubInfoWithoutExitSiteFeedback):

5:24 PM Changeset in webkit [253135] by Chris Dumez
  • 22 edits
    2 adds in trunk/Source

PageConfiguration::progressTrackerClient should use a smart pointer
https://bugs.webkit.org/show_bug.cgi?id=204854

Reviewed by Alex Christensen.

Source/WebCore:

  • loader/EmptyClients.cpp:

(WebCore::pageConfigurationWithEmptyClients):

  • loader/ProgressTracker.cpp:

(WebCore::ProgressTracker::ProgressTracker):
(WebCore::ProgressTracker::progressStarted):
(WebCore::ProgressTracker::progressCompleted):
(WebCore::ProgressTracker::finalProgressComplete):
(WebCore::ProgressTracker::incrementProgress):
(WebCore::ProgressTracker::~ProgressTracker): Deleted.

  • loader/ProgressTracker.h:

(WebCore::ProgressTracker::client):

  • loader/ProgressTrackerClient.h:

(WebCore::ProgressTrackerClient::progressTrackerDestroyed): Deleted.

  • page/Page.cpp:

(WebCore::Page::Page):

  • page/PageConfiguration.cpp:

(WebCore::PageConfiguration::PageConfiguration):

  • page/PageConfiguration.h:

Source/WebKit:

  • WebProcess/WebCoreSupport/WebProgressTrackerClient.cpp:

(WebKit::WebProgressTrackerClient::progressTrackerDestroyed): Deleted.

  • WebProcess/WebCoreSupport/WebProgressTrackerClient.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_overriddenMediaType):

Source/WebKitLegacy:

  • PlatformWin.cmake:

Source/WebKitLegacy/mac:

  • WebCoreSupport/WebProgressTrackerClient.h:
  • WebCoreSupport/WebProgressTrackerClient.mm:

(WebProgressTrackerClient::progressTrackerDestroyed): Deleted.

  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):

Source/WebKitLegacy/win:

  • WebCoreSupport/WebFrameLoaderClient.cpp:

(WebFrameLoaderClient::progressStarted): Deleted.
(WebFrameLoaderClient::progressEstimateChanged): Deleted.
(WebFrameLoaderClient::progressFinished): Deleted.

  • WebCoreSupport/WebFrameLoaderClient.h:
  • WebCoreSupport/WebProgressTrackerClient.cpp: Added.

(WebProgressTrackerClient::progressStarted):
(WebProgressTrackerClient::progressEstimateChanged):
(WebProgressTrackerClient::progressFinished):

  • WebCoreSupport/WebProgressTrackerClient.h: Added.
  • WebView.cpp:

(WebView::initWithFrame):

5:19 PM Changeset in webkit [253134] by Jonathan Bedard
  • 3 edits in trunk/Tools

results.webkit.org: Decrease ttl for archives
https://bugs.webkit.org/show_bug.cgi?id=204806
<rdar://problem/57527644>

Unreviewed infrastructure fix.

  • resultsdbpy/resultsdbpy/controller/archive_controller_unittest.py:

(ArchiveControllerUnittest.setup_webserver): Disable time-to-live.

  • resultsdbpy/resultsdbpy/model/mock_model_factory.py:

(MockModelFactory.create): Ensure time-to-live is longer than the oldest commit.

4:48 PM Changeset in webkit [253133] by eric.carlson@apple.com
  • 10 edits in trunk/Source/WebCore

Make MediaPlayer::client() private
https://bugs.webkit.org/show_bug.cgi?id=204856
<rdar://problem/57633186>

Reviewed by Jer Noble.

Make MediaPlayer::client private and create accessors for all of the client methods
that were being accessed directly. Also remove the MediaPlayer* parameters from
the client methods since none of them were used.

No new tests, no behavioral change.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::mediaPlayerActiveSourceBuffersChanged):
(WebCore::HTMLMediaElement::mediaPlayerNetworkStateChanged):
(WebCore::HTMLMediaElement::mediaPlayerReadyStateChanged):
(WebCore::HTMLMediaElement::mediaPlayerKeyNeeded):
(WebCore::HTMLMediaElement::mediaPlayerTimeChanged):
(WebCore::HTMLMediaElement::mediaPlayerVolumeChanged):
(WebCore::HTMLMediaElement::mediaPlayerMuteChanged):
(WebCore::HTMLMediaElement::mediaPlayerDurationChanged):
(WebCore::HTMLMediaElement::mediaPlayerRateChanged):
(WebCore::HTMLMediaElement::mediaPlayerPlaybackStateChanged):
(WebCore::HTMLMediaElement::mediaPlayerSawUnsupportedTracks):
(WebCore::HTMLMediaElement::mediaPlayerResourceNotSupported):
(WebCore::HTMLMediaElement::mediaPlayerRepaint):
(WebCore::HTMLMediaElement::mediaPlayerSizeChanged):
(WebCore::HTMLMediaElement::mediaPlayerRenderingCanBeAccelerated):
(WebCore::HTMLMediaElement::mediaPlayerRenderingModeChanged):
(WebCore::HTMLMediaElement::mediaPlayerEngineUpdated):
(WebCore::HTMLMediaElement::mediaPlayerFirstVideoFrameAvailable):
(WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged):
(WebCore::HTMLMediaElement::mediaPlayerCurrentPlaybackTargetIsWirelessChanged):

  • html/HTMLMediaElement.h:
  • platform/graphics/MediaPlayer.cpp:

(WebCore::MediaPlayer::loadWithNextMediaEngine):
(WebCore::MediaPlayer::currentPlaybackTargetIsWirelessChanged):
(WebCore::MediaPlayer::networkStateChanged):
(WebCore::MediaPlayer::readyStateChanged):
(WebCore::MediaPlayer::volumeChanged):
(WebCore::MediaPlayer::muteChanged):
(WebCore::MediaPlayer::timeChanged):
(WebCore::MediaPlayer::sizeChanged):
(WebCore::MediaPlayer::repaint):
(WebCore::MediaPlayer::durationChanged):
(WebCore::MediaPlayer::rateChanged):
(WebCore::MediaPlayer::playbackStateChanged):
(WebCore::MediaPlayer::firstVideoFrameAvailable):
(WebCore::MediaPlayer::characteristicChanged):
(WebCore::MediaPlayer::keyNeeded):
(WebCore::MediaPlayer::graphicsDeviceAdapter const):

  • platform/graphics/MediaPlayer.h:

(WebCore::MediaPlayerClient::mediaPlayerNetworkStateChanged):
(WebCore::MediaPlayerClient::mediaPlayerReadyStateChanged):
(WebCore::MediaPlayerClient::mediaPlayerVolumeChanged):
(WebCore::MediaPlayerClient::mediaPlayerMuteChanged):
(WebCore::MediaPlayerClient::mediaPlayerTimeChanged):
(WebCore::MediaPlayerClient::mediaPlayerDurationChanged):
(WebCore::MediaPlayerClient::mediaPlayerRateChanged):
(WebCore::MediaPlayerClient::mediaPlayerPlaybackStateChanged):
(WebCore::MediaPlayerClient::mediaPlayerSawUnsupportedTracks):
(WebCore::MediaPlayerClient::mediaPlayerResourceNotSupported):
(WebCore::MediaPlayerClient::mediaPlayerRepaint):
(WebCore::MediaPlayerClient::mediaPlayerSizeChanged):
(WebCore::MediaPlayerClient::mediaPlayerEngineUpdated):
(WebCore::MediaPlayerClient::mediaPlayerFirstVideoFrameAvailable):
(WebCore::MediaPlayerClient::mediaPlayerCharacteristicChanged):
(WebCore::MediaPlayerClient::mediaPlayerRenderingCanBeAccelerated):
(WebCore::MediaPlayerClient::mediaPlayerRenderingModeChanged):
(WebCore::MediaPlayerClient::mediaPlayerActiveSourceBuffersChanged):
(WebCore::MediaPlayerClient::mediaPlayerGraphicsDeviceAdapter const):
(WebCore::MediaPlayerClient::mediaPlayerKeyNeeded):
(WebCore::MediaPlayerClient::mediaPlayerCurrentPlaybackTargetIsWirelessChanged):
(WebCore::MediaPlayer::renderingCanBeAccelerated const):
(WebCore::MediaPlayer::renderingModeChanged const):
(WebCore::MediaPlayer::acceleratedCompositingEnabled):
(WebCore::MediaPlayer::activeSourceBuffersChanged):
(WebCore::MediaPlayer::playerContentBoxRect const):
(WebCore::MediaPlayer::playerContentsScale const):
(WebCore::MediaPlayer::shouldUsePersistentCache const):
(WebCore::MediaPlayer::mediaCacheDirectory const):
(WebCore::MediaPlayer::isVideoPlayer const):
(WebCore::MediaPlayer::mediaEngineUpdated):
(WebCore::MediaPlayer::isLooping const):
(WebCore::MediaPlayer::requestInstallMissingPlugins):
(WebCore::MediaPlayer::client const):

  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:

(WebCore::MediaPlayerPrivateAVFoundation::preferredRenderingMode const):
(WebCore::MediaPlayerPrivateAVFoundation::setUpVideoRendering):
(WebCore::MediaPlayerPrivateAVFoundation::prepareForRendering):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:

(WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL):
(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::notifyActiveSourceBuffersChanged):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureLayer):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::destroyLayer):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureDecompressionSession):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::ensureLayers):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateRenderingMode):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::acceleratedRenderingStateChanged):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:

(WebCore::MediaPlayerPrivateGStreamer::setAudioStreamProperties):
(WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo):
(WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideoCaps):
(WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio):
(WebCore::MediaPlayerPrivateGStreamer::updateTracks):
(WebCore::MediaPlayerPrivateGStreamer::handleMessage):
(WebCore::MediaPlayerPrivateGStreamer::didEnd):
(WebCore::MediaPlayerPrivateGStreamer::acceleratedRenderingStateChanged):

4:39 PM Changeset in webkit [253132] by Jonathan Bedard
  • 3 edits in trunk/Tools

results.webkit.org: Handle duplicate archives
https://bugs.webkit.org/show_bug.cgi?id=204860

Reviewed by Stephanie Lewis.

  • resultsdbpy/resultsdbpy/controller/archive_controller.py:

(ArchiveController): Pass test time to ArchiveContext, de-duplicate any
identical archives.

  • resultsdbpy/resultsdbpy/model/archive_context.py:

(ArchiveContext): Only upack identical archives once, pass digest to caller.

4:35 PM Changeset in webkit [253131] by timothy_horton@apple.com
  • 2 edits
    1 add in trunk/Source/WebKit

Fix the iOS build

  • Resources/SandboxProfiles/ios/com.apple.WebKit.GPU.sb: Added.
  • WebKit.xcodeproj/project.pbxproj:
4:27 PM Changeset in webkit [253130] by pvollan@apple.com
  • 3 edits in trunk/Source/WebKit

Unreviewed fix for failure to create sandbox extension on macOS after r253011. This should be iOS only.

  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::finishGrantingRequest):

  • UIProcess/UserMediaPermissionRequestManagerProxy.h:
4:23 PM Changeset in webkit [253129] by Jonathan Bedard
  • 21 edits in trunk/Tools

Python 3: Add support in webkitpy.benchmark_runner
https://bugs.webkit.org/show_bug.cgi?id=204784

Reviewed by Stephanie Lewis.

  • Scripts/test-webkitpy-python3: Add webkitpy.benchmark_runner.
  • Scripts/webkitpy/benchmark_runner/benchmark_results.py:

(BenchmarkResults): Arithmetic aggregator should use integer division.
(BenchmarkResults._format_values): Convert map to list.
(BenchmarkResults._aggregate_results): Ditto.
(BenchmarkResults._aggregate_results_for_test): Use Python 2/3 compatible iteritems.
(BenchmarkResults._subtest_values_by_config_iteration): Ditto.
(BenchmarkResults._lint_subtest_results): Ditto.
(BenchmarkResults._lint_configuration): Ditto.

  • Scripts/webkitpy/benchmark_runner/benchmark_results_unittest.py: Use explicit imports.
  • Scripts/webkitpy/benchmark_runner/benchmark_runner.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/init.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_browser_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_chrome_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_cog_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_epiphany_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_firefox_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_minibrowsergtk_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/linux_minibrowserwpe_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/osx_browser_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/osx_chrome_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/osx_firefox_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/browser_driver/osx_safari_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/http_server_driver/init.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/http_server_driver/simple_http_server_driver.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/run_benchmark.py: Ditto.
  • Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py: Ditto.
4:10 PM Changeset in webkit [253128] by Jonathan Bedard
  • 40 edits in trunk/Tools

Python 3: Add support in webkitpy.tool
https://bugs.webkit.org/show_bug.cgi?id=204838

Reviewed by Stephanie Lewis.

  • Scripts/test-webkitpy-python3: Add webkitpy.tool.
  • Scripts/webkit-patch: Remove version check.
  • Scripts/webkitpy/common/net/bugzilla/bug.py:

(Bug.reviewed_patches): Convert filter to list.
(Bug.commit_queued_patches): Ditto.

  • Scripts/webkitpy/common/net/bugzilla/bugzilla_mock.py:

(MockBugzillaQueries.fetch_bug_ids_from_commit_queue): Convert map to list.
(MockBugzillaQueries.fetch_attachment_ids_from_review_queue): Ditto.
(MockBugzillaQueries.fetch_bug_ids_from_pending_commit_list): Ditto.
(MockBugzilla.post_comment_to_bug): Sort cc list before printing.

  • Scripts/webkitpy/common/net/statusserver.py:

(StatusServer.set_api_key): Convert filter to list.

  • Scripts/webkitpy/common/net/web.py:

(Web.get_binary): Use Python 2/3 compatible urlopen.
(Web.request): Use Python 2/3 compatible Request.

  • Scripts/webkitpy/common/prettypatch.py:

(PrettyPatch.pretty_diff_file): Encode diff before printing.

  • Scripts/webkitpy/common/system/executive_mock.py:

(MockExecutive.run_and_throw_if_fail): Sort environment before printing.
(MockExecutive.run_command): Convert input to string before printing.

  • Scripts/webkitpy/tool/bot/commitqueuetask_unittest.py:

(FailingTestCommitQueue.test_results): Convert map to list.
(MockSimpleTestPlanCommitQueue.test_results): Ditto.

  • Scripts/webkitpy/tool/bot/feeders.py:

(CommitQueueFeeder.feed): Use Python 2/3 compatible sort.
(CommitQueueFeeder._patch_cmp): Deleted.

  • Scripts/webkitpy/tool/bot/flakytestreporter.py:

(FlakyTestReporter._lookup_bug_for_flaky_test): Convert filter to list.

  • Scripts/webkitpy/tool/bot/irc_command.py:

(Whois.execute): Convert map to list.

  • Scripts/webkitpy/tool/bot/retrylogic_unittest.py:

(JSCEarlyWarningSystemTest._create_task): Convert map to list.

  • Scripts/webkitpy/tool/bot/sheriff.py:
  • Scripts/webkitpy/tool/commands/applywatchlistlocal_unittest.py: Use sorted lists

Instead of sets.

  • Scripts/webkitpy/tool/commands/download.py:

(AbstractPatchSequencingCommand.init): Use Python 2/3 compatible sort.

  • Scripts/webkitpy/tool/commands/download_unittest.py: Sort environment.
  • Scripts/webkitpy/tool/commands/earlywarningsystem.py:

(AbstractEarlyWarningSystem.load_ews_classes): str.translate differs between Python 2
and Python 3.

  • Scripts/webkitpy/tool/commands/newcommitbot.py:

(NewCommitBot._summarize_commit_log): Convert filter to list.

  • Scripts/webkitpy/tool/commands/queues.py:

(AbstractQueue.should_continue_work_queue): Handle case where iterations is a MagicMock.
(AbstractQueue._log_from_script_error_for_upload): Explicitly use BytesIO

  • Scripts/webkitpy/tool/commands/queues_unittest.py: Use explicit import paths.
  • Scripts/webkitpy/tool/commands/rebaseline_unittest.py: Sort lists before comparing them.
  • Scripts/webkitpy/tool/commands/stepsequence.py:

(StepSequence.options): Use Python 2/3 compatible sort.

  • Scripts/webkitpy/tool/commands/suggestnominations.py:

(AbstractCommitLogCommand.init): Use Python 2/3 compatible sort.
(SuggestNominations._print_nominations): Ditto.
(SuggestNominations._print_counts): Ditto.
(SuggestNominations._print_nominations.nomination_cmp): Deleted.
(SuggestNominations._print_counts.counter_cmp): Deleted.

  • Scripts/webkitpy/tool/mocktool_unittest.py: Use explicit import paths.
  • Scripts/webkitpy/tool/multicommandtool.py:

(HelpCommand._help_epilog): Convert filter to list, use Python 2/3 compatible sort.
(MultiCommandTool._find_all_commands): Use Python 2/3 compatible sort.

  • Scripts/webkitpy/tool/servers/gardeningserver.py:

(GardeningHTTPServer): Use Python 2/3 compatible HTTPServers.

  • Scripts/webkitpy/tool/servers/rebaselineserver.py:

(get_test_baselines.AllPlatformsPort.baseline_search_path): Use list instead of utterable keys.
(RebaselineHTTPServer): Use Python 2/3 compatible HTTPServers.
(RebaselineHTTPServer.init): Ditto.

  • Scripts/webkitpy/tool/servers/rebaselineserver_unittest.py:

(GetActualResultFilesTest.test): Use assertEqual instead of assertItemsEqual.

  • Scripts/webkitpy/tool/servers/reflectionhandler.py:

(ReflectionHandler): Use Python 2/3 compatible HTTPServers.

  • Scripts/webkitpy/tool/steps/applywatchlist.py:

(ApplyWatchList.run): Sort cc_emails before printing.

  • Scripts/webkitpy/tool/steps/applywatchlist_unittest.py: Print sorted list instead

of set.

  • Scripts/webkitpy/tool/steps/confirmdiff.py:

(ConfirmDiff._show_pretty_diff): Use Python 2/3 compatible pathname2url.

  • Scripts/webkitpy/tool/steps/haslanded.py:

(HasLanded.convert_to_svn): Use Python 2/3 compatible StringIO.
(HasLanded.strip_change_log): Ditto.

  • Scripts/webkitpy/tool/steps/preparechangelog.py:

(PrepareChangeLog._resolve_existing_entry): Convert zip object to list.

  • Scripts/webkitpy/tool/steps/promptforbugortitle.py: Use Python 2/3 compatible urlparse.
  • Scripts/webkitpy/tool/steps/steps_unittest.py: Sort environment.
  • Scripts/webkitpy/w3c/test_exporter.py: Use Python 2/3 compatible HTTPError.
  • Scripts/webkitpy/w3c/wpt_github.py:

(WPTGitHub.remove_label): Use Python 2/3 compatible urllib.quote.
(WPTGitHub.is_pr_merged): Use Python 2/3 compatible HTTPError.
(WPTGitHub.merge_pr): Ditto.
(JSONResponse.init):

4:07 PM Changeset in webkit [253127] by pvollan@apple.com
  • 6 edits in trunk/Source/WebKit

[iOS] The UI process should issue mach sandbox extension to "com.apple.AGXCompilerService"
https://bugs.webkit.org/show_bug.cgi?id=203915

Reviewed by Brent Fulgham.

Only a few iPad models need access to "com.apple.AGXCompilerService” in the WebContent process.
The UI process should issue this mach extension for these iPad models.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
  • Shared/WebProcessCreationParameters.cpp:

(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::deviceHasAGXCompilerService):
(WebKit::WebProcessPool::platformInitializeWebProcess):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

3:34 PM Changeset in webkit [253126] by Alan Coon
  • 5 edits in branches/safari-608-branch/Tools

Cherry-pick r252050. rdar://problem/56900657

REGRESSION(r252031): layout tests fail to run in non apple ports after r252031
https://bugs.webkit.org/show_bug.cgi?id=203844

Patch by Carlos Garcia Campos <cgarcia@igalia.com> on 2019-11-05
Reviewed by Žan Doberšek.

Since r252032 Port.check_image_diff() assumes that ImageDiff binary is built in the build path, which is not
true for all ports. This patch adds Port._path_to_default_image_diff() to be used instead of the build_path()
and overriden by ports not building the ImageDiff in the build path.

  • Scripts/webkitpy/port/base.py: (Port.check_image_diff): (Port._path_to_default_image_diff): (Port._path_to_image_diff):
  • Scripts/webkitpy/port/gtk.py: (GtkPort._path_to_default_image_diff):
  • Scripts/webkitpy/port/win.py: (WinPort._path_to_default_image_diff):
  • Scripts/webkitpy/port/wpe.py: (WPEPort._path_to_default_image_diff):

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

3:24 PM Changeset in webkit [253125] by Alan Coon
  • 3 edits
    1 delete in tags/Safari-609.1.11

Cherry-pick r253124. rdar://problem/57596734

Unreviewed, rolling out r252416, vimeo does not work
https://bugs.webkit.org/show_bug.cgi?id=204141

JSTests:

  • stress/generator-cell-with-type.js: Removed.

Source/JavaScriptCore:

  • dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

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

3:01 PM Changeset in webkit [253124] by ysuzuki@apple.com
  • 3 edits
    1 delete in trunk

Unreviewed, rolling out r252416, vimeo does not work
https://bugs.webkit.org/show_bug.cgi?id=204141

JSTests:

  • stress/generator-cell-with-type.js: Removed.

Source/JavaScriptCore:

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

2:24 PM Changeset in webkit [253123] by commit-queue@webkit.org
  • 12 edits in trunk

Non-callable "handleEvent" property is silently ignored
https://bugs.webkit.org/show_bug.cgi?id=200066

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-12-04
Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

  • web-platform-tests/IndexedDB/fire-error-event-exception-expected.txt:
  • web-platform-tests/IndexedDB/fire-success-event-exception-expected.txt:
  • web-platform-tests/IndexedDB/fire-upgradeneeded-event-exception-expected.txt:
  • web-platform-tests/dom/events/EventListener-handleEvent-expected.txt:
  • web-platform-tests/html/webappapis/scripting/events/event-handler-handleEvent-ignored-expected.txt:
  • web-platform-tests/websockets/interfaces/WebSocket/events/013-expected.txt:
  • web-platform-tests/workers/interfaces/DedicatedWorkerGlobalScope/onmessage.worker-expected.txt:

Source/WebCore:

This patch prevents "handleEvent" property from being looked up on event handlers
and also reports TypeError exception if "handleEvent" value is not callable.
Web IDL spec: https://heycam.github.io/webidl/#call-a-user-objects-operation (step 10.4)

Tests: fast/dom/exception-getting-event-handler.html

imported/w3c/web-platform-tests/IndexedDB/fire-error-event-exception.html
imported/w3c/web-platform-tests/IndexedDB/fire-success-event-exception.html
imported/w3c/web-platform-tests/IndexedDB/fire-upgradeneeded-event-exception.html
imported/w3c/web-platform-tests/dom/events/EventListener-handleEvent.html
imported/w3c/web-platform-tests/html/webappapis/scripting/events/event-handler-handleEvent-ignored.html
imported/w3c/web-platform-tests/websockets/interfaces/WebSocket/events/013.html
imported/w3c/web-platform-tests/workers/interfaces/DedicatedWorkerGlobalScope/onmessage.worker.html

  • bindings/js/JSEventListener.cpp:

(WebCore::JSEventListener::handleEvent):

LayoutTests:

  • fast/dom/exception-getting-event-handler-expected.txt:
2:19 PM Changeset in webkit [253122] by Alan Coon
  • 8 edits in trunk/Source

Versioning.

1:50 PM Changeset in webkit [253121] by ysuzuki@apple.com
  • 16 edits
    1 add in trunk

[JSC] JSWebAssemblyGlobal creation should have exception check
https://bugs.webkit.org/show_bug.cgi?id=204857
<rdar://problem/57618579>

Reviewed by Mark Lam.

JSTests:

  • wasm/regress/wasm-global-creation-can-throw-an-exception.js: Added.

Source/JavaScriptCore:

Each WebAssembly cells have a path throwing an exception if WebAssembly is disabled. We lack exception checking after calling JSWebAssemblyGlobal::create
in WebAssemblyModuleRecord linking phase. While exception is never thrown in this place since this happens only when WebAssembly is enabled, we should put
scope.assertNoException() to satisfy exception verifier requirement. We also rename factory function of Wasm cells from "create" to "tryCreate" since it
can fail potentially.

  • wasm/js/JSWebAssembly.cpp:

(JSC::instantiate):

  • wasm/js/JSWebAssemblyGlobal.cpp:

(JSC::JSWebAssemblyGlobal::tryCreate):
(JSC::JSWebAssemblyGlobal::create): Deleted.

  • wasm/js/JSWebAssemblyGlobal.h:
  • wasm/js/JSWebAssemblyInstance.cpp:

(JSC::JSWebAssemblyInstance::tryCreate):
(JSC::JSWebAssemblyInstance::create): Deleted.

  • wasm/js/JSWebAssemblyInstance.h:
  • wasm/js/JSWebAssemblyMemory.cpp:

(JSC::JSWebAssemblyMemory::tryCreate):
(JSC::JSWebAssemblyMemory::create): Deleted.

  • wasm/js/JSWebAssemblyMemory.h:
  • wasm/js/JSWebAssemblyTable.cpp:

(JSC::JSWebAssemblyTable::tryCreate):
(JSC::JSWebAssemblyTable::create): Deleted.

  • wasm/js/JSWebAssemblyTable.h:
  • wasm/js/WebAssemblyGlobalConstructor.cpp:

(JSC::constructJSWebAssemblyGlobal):

  • wasm/js/WebAssemblyInstanceConstructor.cpp:

(JSC::constructJSWebAssemblyInstance):

  • wasm/js/WebAssemblyMemoryConstructor.cpp:

(JSC::constructJSWebAssemblyMemory):

  • wasm/js/WebAssemblyModuleRecord.cpp:

(JSC::WebAssemblyModuleRecord::link):

  • wasm/js/WebAssemblyTableConstructor.cpp:

(JSC::constructJSWebAssemblyTable):

1:50 PM Changeset in webkit [253120] by Wenson Hsieh
  • 6 edits in trunk/LayoutTests

Adopt UIHelper in a few more layout tests in fast/events
https://bugs.webkit.org/show_bug.cgi?id=204855

Reviewed by Darin Adler.

Fixes and cleans up some more layout tests; see below for details.

  • fast/events/ios/touch-events-during-scroll-deceleration-in-overflow.html:

Use async-await here, as well as UIHelper.dragFromPointToPoint.

  • fast/events/ios/viewport-device-width-at-initial-scale-fast-clicks-expected.txt:
  • fast/events/ios/viewport-device-width-at-initial-scale-fast-clicks.html:

This test sometimes times out when run in rapid succession, due to touches being dispatched while the test is
finishing. Fix this (and also simplify the test) by using UIHelper instead to synthesize taps, and only finish
the layout test after the expected number of clicks have been observed and all tap gestures have been sent.

  • fast/events/touch/ios/passive-by-default-overridden-on-document-and-window-expected.txt:
  • fast/events/touch/ios/passive-by-default-overridden-on-document-and-window.html:

This test currently fails due to finishing too early, before the touchend event is observed; fix this by waiting
for touchend events before finishing the test.

12:28 PM Changeset in webkit [253119] by ysuzuki@apple.com
  • 2 edits in trunk/LayoutTests

imported/w3c/web-platform-tests/wasm/jsapi/interface.any.worker.html is a flakey failure, WebAssembly.Global is not implemented
https://bugs.webkit.org/show_bug.cgi?id=200258

Reviewed by Saam Barati.

We implemented WebAssembly.Global now. So let's unmark it.

  • platform/mac/TestExpectations:
12:06 PM Changeset in webkit [253118] by Kate Cheney
  • 17 edits
    8 adds in trunk

Expose basic ITP data from the database for future API/SPI use
https://bugs.webkit.org/show_bug.cgi?id=203432
<rdar://problem/56085040>

Reviewed John Wilander.

Source/WebCore:

Tests: http/tests/resourceLoadStatistics/user-interface-data-no-storage-access-database.html

http/tests/resourceLoadStatistics/user-interface-data-no-storage-access.html
http/tests/storageAccess/user-interface-data-with-storage-access-database.html
http/tests/storageAccess/user-interface-data-with-storage-access.html

Updated the toString() to report only if mostRecentUserInteractionTime
was in the last 24 hours as opposed to reporting an actual time since
mostRecentUserInteractionTime changes with each test run.

  • loader/ResourceLoadStatistics.cpp:

(WebCore::hasHadRecentUserInteraction):
(WebCore::ResourceLoadStatistics::toString const):

Source/WebKit:

Tests: http/tests/resourceLoadStatistics/user-interface-data-no-storage-access-database.html

http/tests/resourceLoadStatistics/user-interface-data-no-storage-access.html
http/tests/storageAccess/user-interface-data-with-storage-access-database.html
http/tests/storageAccess/user-interface-data-with-storage-access.html

Adds the ability to collect sorted ITP data for displaying in a
user interface.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::ResourceLoadStatisticsDatabaseStore):
(WebKit::ResourceLoadStatisticsDatabaseStore::prepareStatements):
Added new queries to the database store to check for storage access in
the database and aggregate topFrames with the same
subframe/subresource so easily create the struct for collecting data
for the UI.

(WebKit::ResourceLoadStatisticsDatabaseStore::relationshipExists const):
Fixed an incorrect function name in the error message.

(WebKit::ResourceLoadStatisticsDatabaseStore::joinSubStatisticsForSorting):
Renamed unclear SQL variable names and added a bind parameter to
specify whether resource is prevalent or not, which allows
this function to be used to collect sorted ITP data
for the UI.

(WebKit::ResourceLoadStatisticsDatabaseStore::getFirstPartyDataForDomain const):
(WebKit::ResourceLoadStatisticsDatabaseStore::gatherDataForUserInterface const):

(WebKit::buildQueryStartAndEnd):
(WebKit::getMedianOfPrevalentResourcesWithUserInteraction):
(WebKit::ResourceLoadStatisticsDatabaseStore::getTopPrevelentResourceDaysSinceUI const):
(WebKit::getMedianOfPrevalentResourceWithoutUserInteraction):
(WebKit::getNumberOfPrevalentResourcesInTopResources):
Changed sql query variable names to make them more clear and added a
new bind parameter to allow for more general use of substatistic
sorting query.

(WebKit::ResourceLoadStatisticsDatabaseStore::hasStorageAccess const):
(WebKit::ResourceLoadStatisticsDatabaseStore::dumpResourceLoadStatistics const):
Combined UI data with dumpResourceLoadStatistics() data to keep the testing aspect
of this patch simpler.

(WebKit::ResourceLoadStatisticsDatabaseStore::resourceToString const):
Since mostRecentUserInteractionTime changes with each test run, I
updated the dumping to report only if it was in the last 24 hours as
opposed to reporting an actual time.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.cpp:

(WebKit::ensureFirstPartyStatistic):
(WebKit::getFirstPartyDataForDomain):
(WebKit::hasBeenThirdParty):
(WebKit::ResourceLoadStatisticsMemoryStore::gatherDataForUserInterface const):
(WebKit::ResourceLoadStatisticsMemoryStore::dumpResourceLoadStatistics):

  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::gatherDataForUserInterface):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:

(WebKit::FirstPartyData::toString const):
(WebKit::FirstPartyData::operator== const):
(WebKit::ThirdPartyData::toString const):
(WebKit::ThirdPartyData::operator< const):
The toString methods allow the structs to be printed for testing
purposes. The equals methods allow the return vectors to use
appendIfNotContains.

LayoutTests:

Added new tests to check if basic ITP data is properly
collected and sorted for both the database store and the memory store.
Also edited any tests which use dumpResourceLoadStatistics() to also
expect the new aggregated data to be displayed.

  • http/tests/resourceLoadStatistics/count-third-party-script-import-in-worker-database-expected.txt:
  • http/tests/resourceLoadStatistics/count-third-party-script-import-in-worker-expected.txt:
  • http/tests/resourceLoadStatistics/count-third-party-script-loads-database-expected.txt:
  • http/tests/resourceLoadStatistics/count-third-party-script-loads-expected.txt:
  • http/tests/resourceLoadStatistics/dont-count-third-party-image-as-third-party-script-database-expected.txt:
  • http/tests/resourceLoadStatistics/dont-count-third-party-image-as-third-party-script-expected.txt:
  • http/tests/resourceLoadStatistics/user-interface-data-no-storage-access-database-expected.txt: Added.
  • http/tests/resourceLoadStatistics/user-interface-data-no-storage-access-database.html: Added.
  • http/tests/resourceLoadStatistics/user-interface-data-no-storage-access-expected.txt: Added.
  • http/tests/resourceLoadStatistics/user-interface-data-no-storage-access.html: Added.
  • http/tests/storageAccess/user-interface-data-with-storage-access-database-expected.txt: Added.
  • http/tests/storageAccess/user-interface-data-with-storage-access-database.html: Added.
  • http/tests/storageAccess/user-interface-data-with-storage-access-expected.txt: Added.
  • http/tests/storageAccess/user-interface-data-with-storage-access.html: Added.
11:02 AM Changeset in webkit [253117] by Jonathan Bedard
  • 2 edits in trunk/Tools

Unreviewed, rolling out r253069.

requests not handling certificate chain correctly in Catalina

Reverted changeset:

"results.webkit.org: Sort out certificates on Catalina"
https://bugs.webkit.org/show_bug.cgi?id=202837
https://trac.webkit.org/changeset/253069

10:49 AM Changeset in webkit [253116] by ysuzuki@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

[JSC] Put more cells into IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204845

Reviewed by Saam Barati.

This patch puts following cells in IsoSubspace.

  • ClonedArguments
  • JSMap
  • JSSet
  • RegExpObject
  • runtime/ClonedArguments.h:
  • runtime/JSMap.h:
  • runtime/JSSet.h:
  • runtime/RegExpObject.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
  • runtime/WeakMapImpl.h:

(JSC::WeakMapImpl::subspaceFor):

10:46 AM Changeset in webkit [253115] by ysuzuki@apple.com
  • 49 edits
    12 adds in trunk/JSTests

[JSC] Update Wasm spec-tests
https://bugs.webkit.org/show_bug.cgi?id=204844

Reviewed by Keith Miller.

To get broader coverage, we update Wasm spec-tests to the latest one[1].

[1]: 3e5fdc6b51ca2cde537bb8ecb1ba25c1ee366833

  • wasm.yaml:
  • wasm/spec-tests/address.wast.js:
  • wasm/spec-tests/align.wast.js:
  • wasm/spec-tests/binary-leb128.wast.js: Added.
  • wasm/spec-tests/binary.wast.js:
  • wasm/spec-tests/block.wast.js:
  • wasm/spec-tests/br.wast.js:
  • wasm/spec-tests/br_if.wast.js:
  • wasm/spec-tests/br_table.wast.js:
  • wasm/spec-tests/call_indirect.wast.js:
  • wasm/spec-tests/const.wast.js:
  • wasm/spec-tests/conversions.wast.js:
  • wasm/spec-tests/custom.wast.js: Added.
  • wasm/spec-tests/data.wast.js: Added.
  • wasm/spec-tests/elem.wast.js: Added.
  • wasm/spec-tests/endianness.wast.js:
  • wasm/spec-tests/f32.wast.js:
  • wasm/spec-tests/f32_bitwise.wast.js:
  • wasm/spec-tests/f32_cmp.wast.js:
  • wasm/spec-tests/f64.wast.js:
  • wasm/spec-tests/f64_bitwise.wast.js:
  • wasm/spec-tests/f64_cmp.wast.js:
  • wasm/spec-tests/fac.wast.js:
  • wasm/spec-tests/float_exprs.wast.js:
  • wasm/spec-tests/float_literals.wast.js:
  • wasm/spec-tests/float_memory.wast.js:
  • wasm/spec-tests/func.wast.js:
  • wasm/spec-tests/func_ptrs.wast.js:
  • wasm/spec-tests/i32.wast.js:
  • wasm/spec-tests/i64.wast.js:
  • wasm/spec-tests/imports.wast.js:
  • wasm/spec-tests/int_exprs.wast.js:
  • wasm/spec-tests/int_literals.wast.js:
  • wasm/spec-tests/labels.wast.js:
  • wasm/spec-tests/left-to-right.wast.js:
  • wasm/spec-tests/load.wast.js: Added.
  • wasm/spec-tests/local_get.wast.js: Added.
  • wasm/spec-tests/local_set.wast.js: Added.
  • wasm/spec-tests/local_tee.wast.js: Added.
  • wasm/spec-tests/loop.wast.js:
  • wasm/spec-tests/memory_grow.wast.js: Added.
  • wasm/spec-tests/memory_size.wast.js: Added.
  • wasm/spec-tests/memory_trap.wast.js:
  • wasm/spec-tests/names.wast.js:
  • wasm/spec-tests/nop.wast.js:
  • wasm/spec-tests/return.wast.js:
  • wasm/spec-tests/select.wast.js:
  • wasm/spec-tests/stack.wast.js:
  • wasm/spec-tests/start.wast.js:
  • wasm/spec-tests/store.wast.js: Added.
  • wasm/spec-tests/switch.wast.js:
  • wasm/spec-tests/traps.wast.js:
  • wasm/spec-tests/type.wast.js:
  • wasm/spec-tests/unreachable.wast.js:
  • wasm/spec-tests/unreached-invalid.wast.js:
  • wasm/spec-tests/unwind.wast.js:
  • wasm/spec-tests/utf8-custom-section-id.wast.js:
  • wasm/spec-tests/utf8-import-field.wast.js:
  • wasm/spec-tests/utf8-import-module.wast.js:
  • wasm/spec-tests/utf8-invalid-encoding.wast.js: Added.
10:45 AM Changeset in webkit [253114] by timothy_horton@apple.com
  • 2 edits in branches/safari-608-branch/Tools

Fix the TestWebKitAPI 608-branch build

  • TestWebKitAPI/Configurations/Base.xcconfig:

We didn't merge this line from trunk, but merged other things that depend on it being there.

10:39 AM Changeset in webkit [253113] by ysuzuki@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Remove m_sharingMode field from JSArrayBufferPrototype and make it plain object
https://bugs.webkit.org/show_bug.cgi?id=204832

Reviewed by Saam Barati.

m_sharingMode field is not necessary. Just remove it and make JSArrayBufferPrototype a plain object.

  • runtime/JSArrayBufferPrototype.cpp:

(JSC::JSArrayBufferPrototype::JSArrayBufferPrototype):
(JSC::JSArrayBufferPrototype::finishCreation):
(JSC::JSArrayBufferPrototype::create):

  • runtime/JSArrayBufferPrototype.h:
10:36 AM Changeset in webkit [253112] by commit-queue@webkit.org
  • 9 edits in trunk

Add exclusion rule for text manipulation SPI to exclude based on element class
https://bugs.webkit.org/show_bug.cgi?id=204754
<rdar://problem/57398802>

Patch by Louie Livon-Bemel <Louie Livon-Bemel> on 2019-12-04
Reviewed by Ryosuke Niwa.

Source/WebCore:

Tests: TextManipulation.StartTextManipulationApplyInclusionExclusionRulesForClass

TextManipulation.StartTextManipulationApplyInclusionExclusionRulesForClassAndAttribute

  • editing/TextManipulationController.cpp:

(WebCore::TextManipulationController::ExclusionRule::match const):

When matching a ClassRule, check that the element has at least one class, and that the classList contains
the rule's class name. Checking it this way rather than checking if the ClassList contains the rule allows
us to avoid mutating the element in this function.

  • editing/TextManipulationController.h:

Add a new rule type for a ClassRule.

(WebCore::TextManipulationController::ExclusionRule::ClassRule::encode const):
(WebCore::TextManipulationController::ExclusionRule::ClassRule::decode):

Source/WebKit:

Give clients another option for adding an exclusion for text manipulation; allow them to exclude based on an
element having a certain class.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _startTextManipulationsWithConfiguration:completion:]):

If the rule doesn't have an attribute but does have a class name, treat it as a ClassRule exclusion.

  • UIProcess/API/Cocoa/_WKTextManipulationExclusionRule.h:

Add an initializer for excluding based on a class name. Also add a getter for the className.

  • UIProcess/API/Cocoa/_WKTextManipulationExclusionRule.mm:

(-[_WKTextManipulationExclusionRule initExclusion:forClass:]):
(-[_WKTextManipulationExclusionRule className]):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:

(TestWebKitAPI::TEST):

  • When matching a class, it should work even with other class names on the element.
  • All children elements should get the same exclusion rule, unless overridden by another rule.
10:19 AM Changeset in webkit [253111] by Alan Coon
  • 7 edits in tags/Safari-609.1.11/Source

Revert r252755. rdar://problem/57607890

10:17 AM Changeset in webkit [253110] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r252811. rdar://problem/57609336

[iOS] Copy assertions before iterating over them in _notifyAssertionsOfImminentSuspension
https://bugs.webkit.org/show_bug.cgi?id=204524
<rdar://problem/57265830>

Reviewed by Alexey Proskuryakov.

Copy assertions before iterating over them in _notifyAssertionsOfImminentSuspension and use WeakPtr
to make sure the assertions are still alive before calling uiAssertionWillExpireImminently() on
them. It is common for process assertions to get released when uiAssertionWillExpireImminently()
gets called, which would remove them from the _assertionsNeedingBackgroundTask vector we were
iterating on.

  • UIProcess/ios/ProcessAssertionIOS.mm: (-[WKProcessAssertionBackgroundTaskManager _notifyAssertionsOfImminentSuspension]):

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

10:16 AM Changeset in webkit [253109] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/JavaScriptCore

Cherry-pick r252674. rdar://problem/57609333

[JSC] MetadataTable::sizeInBytes should not touch m_rawBuffer in UnlinkedMetadataTable unless MetadataTable is linked to that UnlinkedMetadataTable
https://bugs.webkit.org/show_bug.cgi?id=204390

Reviewed by Mark Lam.

We have a race issue here. When calling MetadataTable::sizeInBytes, we call UnlinkedMetadataTable::sizeInBytes since we change the result based on
whether this MetadataTable is linked to this UnlinkedMetadataTable or not. The problem is that we are calling UnlinkedMetadataTable::totalSize
unconditionally in UnlinkedMetadataTable::sizeInBytes, and this is touching m_rawBuffer unconditionally. This is not correct since it is possible
that this m_rawBuffer is realloced while we are calling MetadataTable::sizeInBytes in GC thread.

  1. The GC thread is calling MetadataTable::sizeInBytes for MetadataTable "A".
  2. The main thread is destroying MetadataTable "B".
  3. MetadataTable "B" is linked to UnlinkedMetadataTable "C".
  4. MetadataTable "A" is pointing to UnlinkedMetadataTable "C".
  5. "A" is touching UnlinkedMetadataTable::m_rawBuffer in "C", called from MetadataTable::sizeInBytes.
  6. (2) destroys MetadataTable "B", and realloc UnlinkedMetadataTable::m_rawBuffer in "C".
  7. (5) can touch already freed buffer.

This patch fixes UnlinkedMetadataTable::sizeInBytes: not touching m_rawBuffer unless it is owned by the caller's MetadataTable. We need to call
UnlinkedMetadataTable::sizeInBytes anyway since we need to adjust the result based on whether the caller MetadataTable is linked to this UnlinkedMetadataTable.

  • bytecode/UnlinkedMetadataTableInlines.h: (JSC::UnlinkedMetadataTable::sizeInBytes):

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

10:04 AM Changeset in webkit [253108] by dino@apple.com
  • 6 edits in trunk/Source

Enable WebGL's ASTC extension all the time
https://bugs.webkit.org/show_bug.cgi?id=202836
<rdar://problem/57627592>

Patch by Kenneth Russell <kbr@chromium.org> on 2019-12-04
Reviewed by Dean Jackson.

Remove the run-time flag - no longer necessary.

Source/WebCore:

  • html/canvas/WebGLCompressedTextureASTC.cpp:

(WebCore::WebGLCompressedTextureASTC::supported):

  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::extensionIsEnabled):

  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setWebGLCompressedTextureASTCSupportEnabled): Deleted.
(WebCore::RuntimeEnabledFeatures::webGLCompressedTextureASTCSupportEnabled const): Deleted.

Source/WebKit:

  • Shared/WebPreferences.yaml:
10:00 AM Changeset in webkit [253107] by Antti Koivisto
  • 5 edits
    2 adds in trunk

[LFC][Integration] Paint with TextPainter
https://bugs.webkit.org/show_bug.cgi?id=204852

Reviewed by Zalan Bujtas.

Source/WebCore:

Display::Painter is very rudimentary and turning it into a full painting implementation
requires lot of refactoring. Instead, for now use separate painting code in the integration
layer that invokes the existing render tree based painting helpers.

This also enables writing reftests for intergrated LFC layout.

Test: fast/layoutformattingcontext/flow-integration-basic-paint.html

  • layout/displaytree/DisplayInlineContent.h:

(WebCore::Display:: const):

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::computeOverflow):
(WebCore::LayoutIntegration::LineLayout::paint):

Adopted from SimpleLineLayout::paintFlow with support for per-run style added.

(WebCore::LayoutIntegration::LineLayout::debugTextShadow):

  • layout/integration/LayoutIntegrationLineLayout.h:

LayoutTests:

  • fast/layoutformattingcontext/flow-integration-basic-paint-expected.html: Added.
  • fast/layoutformattingcontext/flow-integration-basic-paint.html: Added.
9:46 AM Changeset in webkit [253106] by ysuzuki@apple.com
  • 9 edits in trunk/Source/JavaScriptCore

[JSC] Place Wasm cells in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=204829

Reviewed by Saam Barati.

This patch places Wasm cells in IsoSubspace. We remove JSDestructibleObject inheritance in wasm cells since we
can call destructor through HeapCellType's specialization. We do not need to rely on m_classInfo->methodTable->destroy.
This patch does not include JSToWasmICCallee since now I'm exploring the way to remove it completely.

  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
  • wasm/js/JSWebAssemblyInstance.h:
  • wasm/js/JSWebAssemblyMemory.cpp:

(JSC::JSWebAssemblyMemory::destroy):

  • wasm/js/JSWebAssemblyMemory.h:
  • wasm/js/JSWebAssemblyModule.h:
  • wasm/js/JSWebAssemblyTable.h:
  • wasm/js/WebAssemblyGlobalConstructor.h:
9:12 AM Changeset in webkit [253105] by Simon Fraser
  • 11 edits in trunk

Implement the CSS clamp() function
https://bugs.webkit.org/show_bug.cgi?id=203310
<rdar://problem/56551088>

Reviewed by Antti Koivisto.
LayoutTests/imported/w3c:

  • web-platform-tests/css/css-values/clamp-length-computed-expected.txt:
  • web-platform-tests/css/css-values/clamp-length-serialize-expected.txt:

Source/WebCore:

Implement the CSS clamp() function, of the form clamp(min, value, max):
https://drafts.csswg.org/css-values-4/#funcdef-clamp

This is a natural extension of min() and max(), the main difference being
that it takes exactly three arguments.

Tests: fast/css/calc-parsing.html

web-platform-tests/css/css-values/clamp-length-computed-expected.txt:
web-platform-tests/css/css-values/clamp-length-serialize-expected.txt:

  • css/CSSCalculationValue.cpp:

(WebCore::functionFromOperator):
(WebCore::determineCategory):
(WebCore::resolvedTypeForMinOrMaxOrClamp):
(WebCore::CSSCalcOperationNode::createMinOrMaxOrClamp):
(WebCore::functionPrefixForOperator):
(WebCore::CSSCalcOperationNode::evaluateOperator):
(WebCore::CSSCalcExpressionNodeParser::parseCalcFunction):
(WebCore::createCSS):
(WebCore::CSSCalcValue::isCalcFunction):
(WebCore::resolvedTypeForMinOrMax): Deleted.
(WebCore::CSSCalcOperationNode::createMinOrMax): Deleted.

  • css/CSSValueKeywords.in:
  • platform/CalculationValue.cpp:

(WebCore::CalcExpressionOperation::evaluate const):
(WebCore::operator<<):

  • platform/CalculationValue.h:

LayoutTests:

Some basic clamp() parsing tests (valid and invalid inputs).

  • fast/css/calc-parsing-expected.txt:
  • fast/css/calc-parsing.html:
7:43 AM Changeset in webkit [253104] by youenn@apple.com
  • 234 edits
    13 copies
    2 moves
    105 adds
    21 deletes in trunk/LayoutTests

Update WPT tools directory
https://bugs.webkit.org/show_bug.cgi?id=204728

LayoutTests/imported/w3c:

Reviewed by Simon Fraser.

  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-add.https-expected.txt:
  • web-platform-tests/service-workers/cache-storage/window/cache-add.https-expected.txt:
  • web-platform-tests/service-workers/cache-storage/worker/cache-add.https-expected.txt:
  • web-platform-tests/tools: Refreshed

LayoutTests:

Reviewed by Simon Fraser.

6:16 AM Changeset in webkit [253103] by youenn@apple.com
  • 17 edits in trunk

WebProcessPool::terminateServiceWorkerProcess should be renamed terminateServiceWorkers
https://bugs.webkit.org/show_bug.cgi?id=204792

Reviewed by Chris Dumez.

Source/WebKit:

Make use of disableServiceWorkers in terminateServiceWorkers as we might need to handle the case of a service worker in a process containing a page.
Renaming API accordingly.
Covered by existing tests.

  • UIProcess/API/C/WKContext.cpp:

(WKContextTerminateServiceWorkers):

  • UIProcess/API/C/WKContextPrivate.h:
  • UIProcess/API/Cocoa/WKProcessPool.mm:

(-[WKProcessPool _terminateServiceWorkers]):

  • UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::establishWorkerContextConnectionToNetworkProcess):
(WebKit::WebProcessPool::createWebPage):
(WebKit::WebProcessPool::updateServiceWorkerUserAgent):
(WebKit::WebProcessPool::terminateNetworkProcess):
(WebKit::WebProcessPool::terminateServiceWorkers):
(WebKit::WebProcessPool::updateProcessAssertions):
(WebKit::WebProcessPool::isServiceWorkerPageID const):

  • UIProcess/WebProcessPool.h:

Tools:

Renaming testRunner API from terminateServiceWorkerProcess to terminateServiceWorkers.

  • TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::terminateServiceWorkers):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::terminateServiceWorkers):

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

LayoutTests:

  • http/tests/workers/service/resources/postmessage-after-sw-process-crash.js:
5:47 AM Changeset in webkit [253102] by youenn@apple.com
  • 37 edits
    2 adds in trunk

Move soft update handling to network process
https://bugs.webkit.org/show_bug.cgi?id=204678

Reviewed by Chris Dumez.

Source/WebCore:

  • workers/WorkerScriptLoader.cpp:

(WebCore::WorkerScriptLoader::validateResponse):
(WebCore::WorkerScriptLoader::didReceiveResponse):

  • workers/WorkerScriptLoader.h:
  • workers/service/ServiceWorkerJobData.cpp:

(WebCore::ServiceWorkerJobData::isEquivalent const):

  • workers/service/ServiceWorkerJobData.h:
  • workers/service/ServiceWorkerRegistration.cpp:

(WebCore::ServiceWorkerRegistration::ServiceWorkerRegistration):

  • workers/service/ServiceWorkerRegistration.h:
  • workers/service/context/SWContextManager.cpp:
  • workers/service/context/SWContextManager.h:
  • workers/service/context/ServiceWorkerFetch.cpp:

(WebCore::ServiceWorkerFetch::dispatchFetchEvent):

  • workers/service/context/ServiceWorkerThread.cpp:
  • workers/service/context/ServiceWorkerThread.h:
  • workers/service/server/SWServer.cpp:

(WebCore::SWServer::Connection::didResolveRegistrationPromise):
(WebCore::SWServer::SWServer):
(WebCore::SWServer::scheduleJob):
(WebCore::SWServer::resolveRegistrationJob):
(WebCore::originURL):
(WebCore::SWServer::startScriptFetch):
(WebCore::SWServer::scriptFetchFinished):
(WebCore::SWServer::didResolveRegistrationPromise):
(WebCore::SWServer::softUpdate):

  • workers/service/server/SWServer.h:

(WebCore::SWServer::getRegistration):

  • workers/service/server/SWServerJobQueue.cpp:

(WebCore::SWServerJobQueue::runUpdateJob):

  • workers/service/server/SWServerJobQueue.h:

(WebCore::SWServerJobQueue::enqueueJob):

  • workers/service/server/SWServerRegistration.cpp:

(WebCore::SWServerRegistration::SWServerRegistration):
(WebCore::SWServerRegistration::setUpdateViaCache):
(WebCore::SWServerRegistration::softUpdate):
(WebCore::SWServerRegistration::scheduleSoftUpdate):

  • workers/service/server/SWServerRegistration.h:

(WebCore::SWServerRegistration::scopeURLWithoutFragment const):
(WebCore::SWServerRegistration::scriptURL const):

  • workers/service/server/SWServerToContextConnection.h:

Source/WebKit:

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::swServerForSession):

  • NetworkProcess/NetworkSession.h:

(WebKit::NetworkSession::addSoftUpdateLoader):
(WebKit::NetworkSession::removeSoftUpdateLoader):

  • NetworkProcess/ServiceWorker/ServiceWorkerFetchTask.cpp:

(WebKit::ServiceWorkerFetchTask::ServiceWorkerFetchTask):
(WebKit::ServiceWorkerFetchTask::didReceiveRedirectResponse):
(WebKit::ServiceWorkerFetchTask::didReceiveResponse):
(WebKit::ServiceWorkerFetchTask::didFail):
(WebKit::ServiceWorkerFetchTask::didNotHandle):
(WebKit::ServiceWorkerFetchTask::continueFetchTaskWith):
(WebKit::ServiceWorkerFetchTask::timeoutTimerFired):
(WebKit::ServiceWorkerFetchTask::softUpdateIfNeeded):

  • NetworkProcess/ServiceWorker/ServiceWorkerFetchTask.h:
  • NetworkProcess/ServiceWorker/ServiceWorkerSoftUpdateLoader.cpp: Added.

(WebKit::ServiceWorkerSoftUpdateLoader::start):
(WebKit::ServiceWorkerSoftUpdateLoader::ServiceWorkerSoftUpdateLoader):
(WebKit::ServiceWorkerSoftUpdateLoader::~ServiceWorkerSoftUpdateLoader):
(WebKit::ServiceWorkerSoftUpdateLoader::fail):
(WebKit::ServiceWorkerSoftUpdateLoader::loadWithCacheEntry):
(WebKit::ServiceWorkerSoftUpdateLoader::loadFromNetwork):
(WebKit::ServiceWorkerSoftUpdateLoader::willSendRedirectedRequest):
(WebKit::ServiceWorkerSoftUpdateLoader::didReceiveResponse):
(WebKit::ServiceWorkerSoftUpdateLoader::didReceiveBuffer):
(WebKit::ServiceWorkerSoftUpdateLoader::didFinishLoading):
(WebKit::ServiceWorkerSoftUpdateLoader::didFailLoading):
(WebKit::ServiceWorkerSoftUpdateLoader::didComplete):

  • NetworkProcess/ServiceWorker/ServiceWorkerSoftUpdateLoader.h: Added.
  • NetworkProcess/ServiceWorker/WebSWServerConnection.cpp:

(WebKit::WebSWServerConnection::createFetchTask):

  • NetworkProcess/ServiceWorker/WebSWServerToContextConnection.cpp:
  • NetworkProcess/ServiceWorker/WebSWServerToContextConnection.h:
  • Shared/Authentication/AuthenticationManager.cpp:

(WebKit::AuthenticationManager::didReceiveAuthenticationChallenge):

  • Sources.txt:
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/Storage/WebSWContextManagerConnection.cpp:
  • WebProcess/Storage/WebSWContextManagerConnection.h:
  • WebProcess/Storage/WebSWContextManagerConnection.messages.in:
5:12 AM Changeset in webkit [253101] by Patrick Griffis
  • 3 edits in trunk/Tools

[GTK][WPE] Add libuuid to install-dependencies
https://bugs.webkit.org/show_bug.cgi?id=204705

Reviewed by Adrian Perez de Castro.

  • gtk/install-dependencies:
  • wpe/install-dependencies:
4:06 AM Changeset in webkit [253100] by youenn@apple.com
  • 15 edits
    13 adds in trunk

Add support for WebIDL setlike
https://bugs.webkit.org/show_bug.cgi?id=159140

Reviewed by Chris Dumez.

Source/WebCore:

Add preliminary support for https://heycam.github.io/webidl/#idl-setlike in the binding generator and IDL parser.
A setlike JS wrapper owns a JSSet as a private slot that mirrors values owned by the wrapped object.
forEach support is still missing.

A DOM class implementing setlike must currently implement the following methods:

  • initializeSetLike
  • addFromSetLike
  • removeFromSetLike

Added an internals class implementing setlike to test it.
Also covered by binding tests.

Test: js/dom/setlike.html

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSDOMSetLike.cpp: Added.

(WebCore::getBackingSet):
(WebCore::clearBackingSet):
(WebCore::addToBackingSet):
(WebCore::forwardAttributeGetterToBackingSet):
(WebCore::forwardFunctionCallToBackingSet):

  • bindings/js/JSDOMSetLike.h: Added.

(WebCore::DOMSetAdapter::DOMSetAdapter):
(WebCore::DOMSetAdapter::add):
(WebCore::DOMSetAdapter::clear):
(WebCore::DOMSetAdapter::globalObject const):
(WebCore::getAndInitializeBackingSet):
(WebCore::forwardSizeToSetLike):
(WebCore::forwardEntriesToSetLike):
(WebCore::forwardKeysToSetLike):
(WebCore::forwardValuesToSetLike):
(WebCore::forwardHasToSetLike):
(WebCore::forwardClearToSetLike):
(WebCore::forwardAddToSetLike):
(WebCore::forwardDeleteToSetLike):

  • bindings/js/WebCoreBuiltinNames.h:
  • bindings/scripts/CodeGeneratorJS.pm:

(GetFullyQualifiedImplementationCallName):
(AddAdditionalArgumentsForImplementationCall):
(IsAcceleratedDOMAttribute):
(PrototypeOperationCount):
(GeneratePropertiesHashTable):
(InterfaceNeedsIterator):
(GenerateImplementation):
(GenerateAttributeGetterBodyDefinition):
(GenerateOperationBodyDefinition):
(GetRuntimeEnabledStaticProperties):

  • bindings/scripts/IDLParser.pm:

(cloneOperation):
(applyTypedefs):
(parseOperationOrReadWriteAttributeOrMaplike):
(parseReadOnlyMember):
(parseOperation):
(parseSetLikeRest):
(parseSetLikeProperties):
(applyMemberList):

  • bindings/scripts/test/JS/JSReadOnlySetLike.cpp: Added.

(WebCore::JSReadOnlySetLikePrototype::create):
(WebCore::JSReadOnlySetLikePrototype::createStructure):
(WebCore::JSReadOnlySetLikePrototype::JSReadOnlySetLikePrototype):
(WebCore::JSReadOnlySetLikeConstructor::prototypeForStructure):
(WebCore::JSReadOnlySetLikeConstructor::initializeProperties):
(WebCore::JSReadOnlySetLikePrototype::finishCreation):
(WebCore::JSReadOnlySetLike::JSReadOnlySetLike):
(WebCore::JSReadOnlySetLike::finishCreation):
(WebCore::JSReadOnlySetLike::createPrototype):
(WebCore::JSReadOnlySetLike::prototype):
(WebCore::JSReadOnlySetLike::getConstructor):
(WebCore::JSReadOnlySetLike::destroy):
(WebCore::IDLAttribute<JSReadOnlySetLike>::cast):
(WebCore::IDLOperation<JSReadOnlySetLike>::cast):
(WebCore::jsReadOnlySetLikeConstructor):
(WebCore::setJSReadOnlySetLikeConstructor):
(WebCore::jsReadOnlySetLikeSizeGetter):
(WebCore::jsReadOnlySetLikeSize):
(WebCore::jsReadOnlySetLikePrototypeFunctionHasBody):
(WebCore::jsReadOnlySetLikePrototypeFunctionHas):
(WebCore::jsReadOnlySetLikePrototypeFunctionEntriesBody):
(WebCore::jsReadOnlySetLikePrototypeFunctionEntries):
(WebCore::jsReadOnlySetLikePrototypeFunctionKeysBody):
(WebCore::jsReadOnlySetLikePrototypeFunctionKeys):
(WebCore::jsReadOnlySetLikePrototypeFunctionValuesBody):
(WebCore::jsReadOnlySetLikePrototypeFunctionValues):
(WebCore::JSReadOnlySetLike::analyzeHeap):
(WebCore::JSReadOnlySetLikeOwner::isReachableFromOpaqueRoots):
(WebCore::JSReadOnlySetLikeOwner::finalize):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSReadOnlySetLike::toWrapped):

  • bindings/scripts/test/JS/JSReadOnlySetLike.h: Added.

(WebCore::JSReadOnlySetLike::create):
(WebCore::JSReadOnlySetLike::createStructure):
(WebCore::wrapperOwner):
(WebCore::wrapperKey):
(WebCore::toJS):
(WebCore::toJSNewlyCreated):

  • bindings/scripts/test/JS/JSSetLike.cpp: Added.

(WebCore::JSSetLikePrototype::create):
(WebCore::JSSetLikePrototype::createStructure):
(WebCore::JSSetLikePrototype::JSSetLikePrototype):
(WebCore::JSSetLikeConstructor::prototypeForStructure):
(WebCore::JSSetLikeConstructor::initializeProperties):
(WebCore::JSSetLikePrototype::finishCreation):
(WebCore::JSSetLike::JSSetLike):
(WebCore::JSSetLike::finishCreation):
(WebCore::JSSetLike::createPrototype):
(WebCore::JSSetLike::prototype):
(WebCore::JSSetLike::getConstructor):
(WebCore::JSSetLike::destroy):
(WebCore::IDLAttribute<JSSetLike>::cast):
(WebCore::IDLOperation<JSSetLike>::cast):
(WebCore::jsSetLikeConstructor):
(WebCore::setJSSetLikeConstructor):
(WebCore::jsSetLikeSizeGetter):
(WebCore::jsSetLikeSize):
(WebCore::jsSetLikePrototypeFunctionHasBody):
(WebCore::jsSetLikePrototypeFunctionHas):
(WebCore::jsSetLikePrototypeFunctionEntriesBody):
(WebCore::jsSetLikePrototypeFunctionEntries):
(WebCore::jsSetLikePrototypeFunctionKeysBody):
(WebCore::jsSetLikePrototypeFunctionKeys):
(WebCore::jsSetLikePrototypeFunctionValuesBody):
(WebCore::jsSetLikePrototypeFunctionValues):
(WebCore::jsSetLikePrototypeFunctionAddBody):
(WebCore::jsSetLikePrototypeFunctionAdd):
(WebCore::jsSetLikePrototypeFunctionClearBody):
(WebCore::jsSetLikePrototypeFunctionClear):
(WebCore::jsSetLikePrototypeFunctionDeleteBody):
(WebCore::jsSetLikePrototypeFunctionDelete):
(WebCore::JSSetLike::analyzeHeap):
(WebCore::JSSetLikeOwner::isReachableFromOpaqueRoots):
(WebCore::JSSetLikeOwner::finalize):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSSetLike::toWrapped):

  • bindings/scripts/test/JS/JSSetLike.h: Added.

(WebCore::JSSetLike::create):
(WebCore::JSSetLike::createStructure):
(WebCore::wrapperOwner):
(WebCore::wrapperKey):
(WebCore::toJS):
(WebCore::toJSNewlyCreated):

  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:

(WebCore::jsTestGlobalObjectTestReadOnlySetLikeConstructorGetter):
(WebCore::jsTestGlobalObjectTestReadOnlySetLikeConstructor):
(WebCore::setJSTestGlobalObjectTestReadOnlySetLikeConstructorSetter):
(WebCore::setJSTestGlobalObjectTestReadOnlySetLikeConstructor):
(WebCore::jsTestGlobalObjectTestSetLikeConstructorGetter):
(WebCore::jsTestGlobalObjectTestSetLikeConstructor):
(WebCore::setJSTestGlobalObjectTestSetLikeConstructorSetter):
(WebCore::setJSTestGlobalObjectTestSetLikeConstructor):

  • bindings/scripts/test/TestReadOnlySetLike.idl: Added.
  • bindings/scripts/test/TestSetLike.idl: Added.
  • testing/Internals.cpp:

(WebCore::Internals::createInternalsSetLike):

  • testing/Internals.h:
  • testing/Internals.idl:
  • testing/InternalsSetLike.cpp: Added.

(WebCore::InternalsSetLike::InternalsSetLike):
(WebCore::InternalsSetLike::initializeSetLike):

  • testing/InternalsSetLike.h: Added.

(WebCore::InternalsSetLike::create):
(WebCore::InternalsSetLike::clearFromSetLike):
(WebCore::InternalsSetLike::removeFromSetLike):
(WebCore::InternalsSetLike::items const):
(WebCore::InternalsSetLike::addToSetLike):

  • testing/InternalsSetLike.idl: Added.

LayoutTests:

  • js/dom/setlike-expected.txt: Added.
  • js/dom/setlike.html: Added.
3:53 AM Changeset in webkit [253099] by commit-queue@webkit.org
  • 10 edits
    1 add in trunk

Implement OffscreenCanvas.transferToImageBitmap
https://bugs.webkit.org/show_bug.cgi?id=202572

Patch by Zan Dobersek <zdobersek@igalia.com> and Chris Lord <Chris Lord> on 2019-12-04
Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

  • web-platform-tests/offscreen-canvas/filter/offscreencanvas.filter.w-expected.txt:
  • web-platform-tests/offscreen-canvas/the-offscreen-canvas/offscreencanvas.resize-expected.txt:
  • web-platform-tests/offscreen-canvas/the-offscreen-canvas/offscreencanvas.transfer.to.imagebitmap-expected.txt:
  • web-platform-tests/offscreen-canvas/the-offscreen-canvas/offscreencanvas.transfer.to.imagebitmap.w-expected.txt:

Source/WebCore:

No new tests. Covered by existing tests.

  • html/CanvasBase.cpp:

(WebCore::CanvasBase::setImageBuffer const):

  • html/CanvasBase.h:
  • html/OffscreenCanvas.cpp:

(WebCore::OffscreenCanvas::size const):
(WebCore::OffscreenCanvas::setSize):
(WebCore::requiresAcceleratedCompositingForWebGL):
(WebCore::shouldEnableWebGL):
(WebCore::OffscreenCanvas::isWebGLType):
(WebCore::OffscreenCanvas::createContextWebGL):
(WebCore::OffscreenCanvas::getContext):

  • html/OffscreenCanvas.h:
  • html/OffscreenCanvas.idl:
1:58 AM Changeset in webkit [253098] by timothy_horton@apple.com
  • 41 edits
    7 copies
    24 adds in trunk

Introduce a GPU process
https://bugs.webkit.org/show_bug.cgi?id=204343

Reviewed by Simon Fraser.

Source/JavaScriptCore:

  • Configurations/FeatureDefines.xcconfig:

Add ENABLE(GPU_PROCESS).

Source/WebCore:

  • Configurations/FeatureDefines.xcconfig:

Add ENABLE(GPU_PROCESS).

  • en.lproj/Localizable.strings:

Add a string for the user-visible name of the GPU process.

Source/WebCore/PAL:

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit:

Add a GPU process. This process is destined to be used as a proxy between
WebKit and the underlying graphics mechanisms; in the case of the Cocoa
ports, it will specifically gate access to IOKit and a few media-related
daemons.

In this patch, the process is a UI-process singleton; the WebKit client
application gets a single GPU process for all rendering, regardless of
the number of Web Content processes, process pools, or web views.

For now, it is just a shell of a process; functionality will be added
in future patches!

  • Configurations/FeatureDefines.xcconfig:

Add ENABLE(GPU_PROCESS).

  • Configurations/GPUService.xcconfig: Added.
  • GPUProcess/EntryPoint/Cocoa/XPCService/GPUService/Info-OSX.plist: Added.
  • GPUProcess/EntryPoint/Cocoa/XPCService/GPUService/Info-iOS.plist: Added.
  • GPUProcess/EntryPoint/Cocoa/XPCService/GPUServiceEntryPoint.mm: Added.
  • Shared/AuxiliaryProcess.h:
  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceEntryPoint.h:
  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:
  • Platform/ExtraPrivateSymbolsForTAPI.h:
  • Shared/mac/AuxiliaryProcessMac.mm:
  • Sources.txt:
  • SourcesCocoa.txt:
  • WebKit.xcodeproj/project.pbxproj:
  • Configurations/WebKit.xcconfig:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • UIProcess/AuxiliaryProcessProxy.cpp:

(WebKit::AuxiliaryProcessProxy::getLaunchOptions):

  • UIProcess/Launcher/ProcessLauncher.h:
  • UIProcess/Launcher/mac/ProcessLauncherMac.mm:

(WebKit::serviceName):
(WebKit::shouldLeakBoost):
Add a new target for the XPC service, and do the paperwork to launch it.

  • GPUProcess/GPUConnectionToWebProcess.cpp: Added.
  • GPUProcess/GPUConnectionToWebProcess.h: Added.
  • GPUProcess/GPUConnectionToWebProcess.messages.in: Added.

On the GPU process side, the incoming connection from the Web Content process.

  • GPUProcess/GPUProcess.cpp: Added.
  • GPUProcess/GPUProcess.h: Added.
  • GPUProcess/GPUProcess.messages.in: Added.
  • GPUProcess/GPUProcessCreationParameters.cpp: Added.
  • GPUProcess/GPUProcessCreationParameters.h: Added.
  • GPUProcess/cocoa/GPUProcessCocoa.mm: Added.
  • GPUProcess/ios/GPUProcessIOS.mm: Added.
  • GPUProcess/mac/GPUProcessMac.mm: Added.

Add the shell of the GPU process. Mostly stolen from the Networking process.

  • UIProcess/GPU/GPUProcessProxy.cpp: Added.

(WebKit::GPUProcessProxy::singleton):
(WebKit::GPUProcessProxy::GPUProcessProxy):
(WebKit::GPUProcessProxy::~GPUProcessProxy):
(WebKit::GPUProcessProxy::getLaunchOptions):
(WebKit::GPUProcessProxy::connectionWillOpen):
(WebKit::GPUProcessProxy::processWillShutDown):
(WebKit::GPUProcessProxy::getGPUProcessConnection):
(WebKit::GPUProcessProxy::openGPUProcessConnection):
(WebKit::GPUProcessProxy::gpuProcessCrashed):
(WebKit::GPUProcessProxy::didReceiveMessage):
(WebKit::GPUProcessProxy::didReceiveSyncMessage):
(WebKit::GPUProcessProxy::didClose):
(WebKit::GPUProcessProxy::didReceiveInvalidMessage):
(WebKit::GPUProcessProxy::didFinishLaunching):
(WebKit::GPUProcessProxy::updateProcessAssertion):

  • UIProcess/GPU/GPUProcessProxy.h: Added.
  • UIProcess/GPU/GPUProcessProxy.messages.in: Added.

On the UI process side, the GPUProcessProxy is the singleton that
owns the GPU process for the process.

  • GPUProcess/mac/com.apple.WebKit.GPUProcess.sb.in: Added.

This sandbox profile is copied from the Web Content process.
We will cut it down in the future, but this is a sensible starting point,
since the code that is moving to the GPU process is code that currently
lives in the Web Content process.

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::updateProcessAssertion):
Fix a logging typo I stumbled upon.

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::getGPUProcessConnection):

  • UIProcess/WebProcessPool.h:
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::getGPUProcessConnection):

  • UIProcess/WebProcessProxy.h:
  • UIProcess/WebProcessProxy.messages.in:

Add a message from Web->UI to retrieve the GPU process connection.
In the future, we should send this along with the Web Content process
initialization message, but this mechanism doesn't exist yet.

  • WebProcess/GPU/GPUProcessConnection.cpp: Added.

(WebKit::GPUProcessConnection::GPUProcessConnection):
(WebKit::GPUProcessConnection::~GPUProcessConnection):
(WebKit::GPUProcessConnection::didReceiveMessage):
(WebKit::GPUProcessConnection::didReceiveSyncMessage):
(WebKit::GPUProcessConnection::didClose):
(WebKit::GPUProcessConnection::didReceiveInvalidMessage):

  • WebProcess/GPU/GPUProcessConnection.h: Added.

(WebKit::GPUProcessConnection::create):
(WebKit::GPUProcessConnection::connection):

  • WebProcess/GPU/GPUProcessConnection.messages.in: Added.
  • WebProcess/GPU/GPUProcessConnectionInfo.h: Added.

(WebKit::GPUProcessConnectionInfo::identifier):
(WebKit::GPUProcessConnectionInfo::releaseIdentifier):
(WebKit::GPUProcessConnectionInfo::encode const):
(WebKit::GPUProcessConnectionInfo::decode):
In the Web Content process, GPUProcessConnection is the process-wide
connection to the GPU process. All pages in a given Web Content process
use the same connection to talk to the singleton GPU process.

  • WebProcess/WebProcess.cpp:

(WebKit::getGPUProcessConnection):
(WebKit::WebProcess::ensureGPUProcessConnection):
(WebKit::WebProcess::gpuProcessConnectionClosed):

  • WebProcess/WebProcess.h:

(WebKit::WebProcess::existingGPUProcessConnection):
In the Web Content process, make it possible for clients to retrieve
the GPU process connection.

Source/WebKitLegacy/mac:

  • Configurations/FeatureDefines.xcconfig:

Tools:

  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
12:24 AM Changeset in webkit [253097] by yurys@chromium.org
  • 22 edits
    7 adds in trunk

Web Inspector: allow inspector to pause provisional page load and restore its state
https://bugs.webkit.org/show_bug.cgi?id=204170

Reviewed by Devin Rousso.

Source/JavaScriptCore:

Added an option to Target domain to pause all new targets on start waiting for
explicit 'resume' command from the inspector front-end. This allows to configure
inspector backend (including user agent overrides, breakpoints and instrumentation)
before navigation starts.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Sources.txt:
  • inspector/InspectorTarget.cpp: Added.

(Inspector::InspectorTarget::pause):
(Inspector::InspectorTarget::resume):
(Inspector::InspectorTarget::setResumeCallback):

  • inspector/InspectorTarget.h:
  • inspector/agents/InspectorTargetAgent.cpp:

(Inspector::InspectorTargetAgent::willDestroyFrontendAndBackend):
(Inspector::InspectorTargetAgent::setPauseOnStart):
(Inspector::InspectorTargetAgent::resume):
(Inspector::buildTargetInfoObject):
(Inspector::InspectorTargetAgent::targetCreated):
(Inspector::InspectorTargetAgent::targetDestroyed):

  • inspector/agents/InspectorTargetAgent.h:
  • inspector/protocol/Target.json:

Source/WebInspectorUI:

All new targets are now automatically paused on start. For such provisional targets target
manager will run regular initilization code (enable agents etc.) and then resume loading of
the target. Responses and events from the target are defferred until the target is committed
and becomes current main target. When the target manager receives event that the provisional
target has been committed all accumulated protocol messages are replayed and going forward all
new missages will be dispatched as usual.

  • UserInterface/Controllers/TargetManager.js:

(WI.TargetManager):
(WI.TargetManager.prototype.targetCreated):
(WI.TargetManager.prototype.didCommitProvisionalTarget):
(WI.TargetManager.prototype.targetDestroyed):
(WI.TargetManager.prototype.dispatchMessageFromTarget):
(WI.TargetManager.prototype._createTarget):
(WI.TargetManager.prototype._checkAndHandlePageTargetTransition):
(WI.TargetManager.prototype._checkAndHandlePageTargetTermination):

  • UserInterface/Protocol/Connection.js:

(InspectorBackend.Connection):
(InspectorBackend.Connection.prototype.addProvisionalMessage):
(InspectorBackend.Connection.prototype.dispatchProvisionalMessages):

  • UserInterface/Protocol/MultiplexingBackendTarget.js:

(WI.MultiplexingBackendTarget.prototype.initialize):

  • UserInterface/Protocol/PageTarget.js:

(WI.PageTarget):

  • UserInterface/Protocol/Target.js:

(WI.Target.prototype.initialize):
(WI.Target.prototype.get isProvisional):
(WI.Target.prototype.get isPaused):
(WI.Target.prototype.didCommitProvisionalTarget):

  • UserInterface/Protocol/WorkerTarget.js:

Source/WebKit:

Provisional page loading can be deffered if inspector front-end is connected. This
allows to configure inspector backend in the provisional page before load request
is sent. If inspector front-end is not connected provisional loading will conitinue
exactly as before.

Tests: http/tests/inspector/target/pause-on-inline-debugger-statement.html

http/tests/inspector/target/provisional-load-cancels-previous-load.html

  • UIProcess/InspectorTargetProxy.cpp:

(WebKit::InspectorTargetProxy::disconnect):

  • UIProcess/WebPageInspectorController.cpp:

(WebKit::WebPageInspectorController::shouldPauseLoading const):
(WebKit::WebPageInspectorController::setContinueLoadingCallback):

  • UIProcess/WebPageInspectorController.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::continueNavigationInNewProcess):

LayoutTests:

Test that provisional loading which starts before previos provisional loading
commits will be correctly handled by the insepctor.

Test that script execution will break on debugger statement in inline scripts in
case of cross origin navigation and PSON.

  • http/tests/inspector/target/pause-on-inline-debugger-statement-expected.txt: Added.
  • http/tests/inspector/target/pause-on-inline-debugger-statement.html: Added.
  • http/tests/inspector/target/provisional-load-cancels-previous-load-expected.txt: Added.
  • http/tests/inspector/target/provisional-load-cancels-previous-load.html: Added.
  • http/tests/inspector/target/resources/inline-debugger-statement.html: Added.
  • http/tests/inspector/target/target-events-for-provisional-page-expected.txt:
  • http/tests/inspector/target/target-events-for-provisional-page.html:
12:07 AM Changeset in webkit [253096] by rniwa@webkit.org
  • 2 edits in trunk/Source/WebCore

Nullptr crash in Node::setTextContent via Document::setTitle if title element is removed before setTextContent call.
https://bugs.webkit.org/show_bug.cgi?id=204332

Added periods at the end of each comment added in r252667 as Simon pointed out.

  • dom/Document.cpp:

(WebCore::Document::setTitle):

12:02 AM Changeset in webkit [253095] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebCore

Fix the build

  • platform/graphics/displaylists/DisplayListItems.h:

(WebCore::DisplayList::DrawRect::decode):
(WebCore::DisplayList::DrawPath::decode):
(WebCore::DisplayList::FillRect::decode):
(WebCore::DisplayList::FillRectWithColor::decode):
(WebCore::DisplayList::FillCompositedRect::decode):
(WebCore::DisplayList::FillPath::decode):
(WebCore::DisplayList::ClearRect::decode):
Some deleted stuff leaked into the patch.

Dec 3, 2019:

10:30 PM Changeset in webkit [253094] by dbates@webkit.org
  • 2 edits in trunk/Source/WebCore

Remove unused DragController::client()
https://bugs.webkit.org/show_bug.cgi?id=204837

Reviewed by Wenson Hsieh.

It has never been used since its inception in r19039. Moreover it exposes DragController's
internals, which diminishes its encapsulation capabilities.

  • page/DragController.h:

(WebCore::DragController::client const): Deleted.

9:48 PM Changeset in webkit [253093] by Megan Gardner
  • 28 edits
    10 adds in trunk

Add disabled highlight API skeleton
https://bugs.webkit.org/show_bug.cgi?id=204809

Reviewed by Ryosuke Niwa.

Source/WebCore:

Beginning implementation of https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/master/highlight/explainer.md
Spec not written yet, starting from the explainer for now.

Test: highlight/highlight-interfaces.html

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Modules/highlight/HighlightMap.cpp: Added.

(WebCore::HighlightMap::addHighlightGroup):
(WebCore::HighlightMap::addFromMapLike):
(WebCore::HighlightMap::remove):
(WebCore::HighlightMap::namedItem const):
(WebCore::HighlightMap::setNamedItem):
(WebCore::HighlightMap::deleteNamedProperty):
(WebCore::HighlightMap::set):

  • Modules/highlight/HighlightMap.h: Added.

(WebCore::HighlightMap::create):
(WebCore::HighlightMap::synchronizeBackingMap):
(WebCore::HighlightMap::backingMap):
(WebCore::HighlightMap::clear):

  • Modules/highlight/HighlightMap.idl: Added.
  • Modules/highlight/HighlightRangeGroup.cpp: Added.

(WebCore::HighlightRangeGroup::HighlightRangeGroup):
(WebCore::HighlightRangeGroup::create):
(WebCore::HighlightRangeGroup::addRange):
(WebCore::HighlightRangeGroup::removeRange):
(WebCore::HighlightRangeGroup::Iterator::Iterator):
(WebCore::HighlightRangeGroup::Iterator::next):

  • Modules/highlight/HighlightRangeGroup.h: Added.

(WebCore::HighlightRangeGroup::createIterator):

  • Modules/highlight/HighlightRangeGroup.idl: Added.
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/WebCoreBuiltinNames.h:
  • css/DOMCSSNamespace.cpp:

(WebCore::DOMCSSNamespace::highlights):

  • css/DOMCSSNamespace.h:
  • css/DOMCSSNamespace.idl:
  • dom/Document.cpp:

(WebCore::Document::highlightMap):

  • dom/Document.h:
  • dom/Range.idl:
  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setHighlightAPIEnabled):
(WebCore::RuntimeEnabledFeatures::highlightAPIEnabled const):

Source/WebKit:

  • Shared/WebPreferences.yaml:
  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesSetHighlightAPIEnabled):
(WKPreferencesGetHighlightAPIEnabled):

  • UIProcess/API/C/WKPreferencesRefPrivate.h:

Source/WebKitLegacy/mac:

  • WebView/WebPreferenceKeysPrivate.h:
  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):
(-[WebPreferences highlightAPIEnabled]):
(-[WebPreferences setHighlightAPIEnabled:]):

  • WebView/WebPreferencesPrivate.h:
  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Tools:

  • DumpRenderTree/mac/DumpRenderTree.mm:

(enableExperimentalFeatures):

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetPreferencesToConsistentValues):

LayoutTests:

  • highlight/highlight-interfaces-expected.txt: Added.
  • highlight/highlight-interfaces.html: Added.
9:30 PM Changeset in webkit [253092] by Simon Fraser
  • 3 edits
    4 adds in trunk/LayoutTests/imported/w3c

Update css/css-values WPT
https://bugs.webkit.org/show_bug.cgi?id=204835

Reviewed by Zalan Bujtas.

Update css/css-values to WPT 3f1485cc2793f55236076dfffc3c3fa69315e101.

  • web-platform-tests/css/css-values/animations/calc-interpolation-expected.txt: Added.
  • web-platform-tests/css/css-values/animations/calc-interpolation.html: Added.
  • web-platform-tests/css/css-values/animations/w3c-import.log: Added.
  • web-platform-tests/css/css-values/minmax-length-percent-serialize.html:
9:22 PM Changeset in webkit [253091] by rniwa@webkit.org
  • 16 edits
    2 adds in trunk

Perform microtask checkpoint after each task as spec'ed
https://bugs.webkit.org/show_bug.cgi?id=204546
<rdar://problem/57449333>

Reviewed by Chris Dumez.

Source/WebCore:

This patch makes EventLoop perform a microtask checkpoint after each task as spec'ed:
https://html.spec.whatwg.org/multipage/webappapis.html#event-loop-processing-model
and removes the timer in MicrotaskQueue.

Because we always perform a microtask checkpoint after executing JavaScript in
JSExecState::didLeaveScriptContext, there isn't a good way of testing this code change
from the existing API and the infrastructure. This patch, therefore, also introduces
internals.queueMicrotaskInTask, which schedules a new task within which a new microtask
to invoke the callback is scheduled.

This patch also stops including Microtasks.h from most places as only event loop
implementations need to access MicrotaskQueue object now after r252820.

Test: http/tests/eventloop/perform-microtask-checkpoint-at-end-of-task.html

  • animation/DocumentTimeline.cpp:
  • animation/WebAnimation.cpp:
  • bindings/js/JSExecState.cpp:
  • dom/CustomElementReactionQueue.cpp:
  • dom/Document.cpp:
  • dom/EventLoop.cpp:

(WebCore::EventLoop::queueMicrotask):
(WebCore::EventLoop::run):

  • dom/Microtasks.cpp:

(WebCore::MicrotaskQueue::MicrotaskQueue):
(WebCore::MicrotaskQueue::append):
(WebCore::MicrotaskQueue::timerFired): Deleted.

  • dom/Microtasks.h:
  • dom/MutationObserver.cpp:
  • testing/Internals.cpp:

(WebCore::taskSourceFromString): Extracted from Internals::queueTask.
(WebCore::Internals::queueTask):
(WebCore::Internals::queueMicrotaskInTask): Added.

  • testing/Internals.h:
  • testing/Internals.idl:
  • workers/WorkerGlobalScope.cpp:
  • workers/service/SWClientConnection.cpp:

LayoutTests:

Added a regresion test using newly added internals methods.

  • http/tests/eventloop/perform-microtask-checkpoint-at-end-of-task-expected.txt: Added.
  • http/tests/eventloop/perform-microtask-checkpoint-at-end-of-task.html: Added.
8:28 PM Changeset in webkit [253090] by rniwa@webkit.org
  • 17 edits in trunk

Replace customJavaScriptUserAgentAsSiteSpecificQuirks with customUserAgentAsSiteSpecificQuirks
https://bugs.webkit.org/show_bug.cgi?id=204824

Reviewed by Brent Fulgham.

Source/WebCore:

This patch renames customJavaScriptUserAgentAsSiteSpecificQuirks to customUserAgentAsSiteSpecificQuirks,
and make it apply to network requests as well as JavaScript API.

Tests: WebKit.WebsitePoliciesCustomUserAgentAsSiteSpecificQuirksDisabled

WebKit.WebsitePoliciesCustomUserAgentAsSiteSpecificQuirks

  • loader/DocumentLoader.h:

(WebCore::DocumentLoader::setCustomUserAgentAsSiteSpecificQuirks): Renamed from setCustomJavaScriptUserAgentAsSiteSpecificQuirks.
(WebCore::DocumentLoader::customUserAgentAsSiteSpecificQuirks const): Renamed from customJavaScriptUserAgentAsSiteSpecificQuirks.

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::userAgent const):
(WebCore::FrameLoader::userAgentForJavaScript const): Deleted.

  • loader/FrameLoader.h:
  • page/Navigator.cpp:

(WebCore::Navigator::userAgent const):

  • page/Quirks.cpp:

(WebCore::Quirks::shouldOpenAsAboutBlank const):

Source/WebKit:

This patch replaces _WKWebsitePolicies's customJavaScriptUserAgentAsSiteSpecificQuirks with
customUserAgentAsSiteSpecificQuirks and makes it apply to network requests as well as JS API.

  • Shared/WebsitePoliciesData.cpp:

(WebKit::WebsitePoliciesData::encode const):
(WebKit::WebsitePoliciesData::decode):
(WebKit::WebsitePoliciesData::applyToDocumentLoader):

  • Shared/WebsitePoliciesData.h:
  • UIProcess/API/APIWebsitePolicies.cpp:

(API::WebsitePolicies::copy const):
(API::WebsitePolicies::data):

  • UIProcess/API/APIWebsitePolicies.h:
  • UIProcess/API/Cocoa/WKWebpagePreferences.mm:

(-[WKWebpagePreferences _setCustomUserAgentAsSiteSpecificQuirks:]): Renamed from _setCustomJavaScriptUserAgentAsSiteSpecificQuirks.
(-[WKWebpagePreferences _customUserAgentAsSiteSpecificQuirks]): Renamed from _customJavaScriptUserAgentAsSiteSpecificQuirks.

  • UIProcess/API/Cocoa/WKWebpagePreferencesPrivate.h:
  • UIProcess/API/Cocoa/_WKWebsitePolicies.h:
  • UIProcess/API/Cocoa/_WKWebsitePolicies.mm:

(-[_WKWebsitePolicies setCustomUserAgentAsSiteSpecificQuirks:]): Renamed from setCustomJavaScriptUserAgentAsSiteSpecificQuirks.
(-[_WKWebsitePolicies customUserAgentAsSiteSpecificQuirks]): Renamed from customJavaScriptUserAgentAsSiteSpecificQuirks.

Tools:

Replaced WebKit.WebsitePoliciesCustomJavaScriptUserAgent and WebKit.WebsitePoliciesCustomUserAgents
with WebKit.WebsitePoliciesCustomUserAgentAsSiteSpecificQuirksDisabled, which tests that the UA string
specified by customUserAgentAsSiteSpecificQuirks is not used when site specific quirks is disabled,
and WebKit.WebsitePoliciesCustomUserAgentAsSiteSpecificQuirks, which tests that new property sets
UA string for both network requests and JS API.

  • TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:

(-[CustomJavaScriptUserAgentDelegate _webView:decidePolicyForNavigationAction:userInfo:decisionHandler:]):

8:11 PM Changeset in webkit [253089] by Simon Fraser
  • 3 edits in trunk/LayoutTests

Unreviewed test gardening.

Update legacy-animation-engine/fast/css/calc-with-angle-time-frequency.html to match fast/css/calc-with-angle-time-frequency.html
for new calc() behavior.

  • legacy-animation-engine/fast/css/calc-with-angle-time-frequency-expected.txt:
  • legacy-animation-engine/fast/css/calc-with-angle-time-frequency.html:
7:44 PM Changeset in webkit [253088] by Andres Gonzalez
  • 9 edits in trunk

Focus tracking support in the accessibility isolatedtree.
https://bugs.webkit.org/show_bug.cgi?id=204535

Reviewed by Chris Fleizach.

Source/WebCore:

The AXIsolatedTree focused object is now set during the tree generation.
It is updated on handleFocusedUIElementChanged.

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::focusedImageMapUIElement):
(WebCore::AXObjectCache::focusedObject):
(WebCore::AXObjectCache::isolatedTreeFocusedObject):
(WebCore::AXObjectCache::setIsolatedTreeFocusedObject):
(WebCore::AXObjectCache::focusedUIElementForPage):
(WebCore::AXObjectCache::isolatedTreeRootObject):
(WebCore::AXObjectCache::handleFocusedUIElementChanged):
(WebCore::AXObjectCache::createIsolatedTreeHierarchy):
(WebCore::AXObjectCache::generateIsolatedTree):

  • accessibility/AXObjectCache.h:
  • accessibility/AccessibilityObject.cpp:

(WebCore::AccessibilityObject::focusedUIElement const):

Source/WebKit:

  • WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:

(WKAccessibilityFocusedObject):

Tools:

FocusElement can run on the secondary AXThread.

  • WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:

(WTR::AccessibilityController::focusedElement):

7:31 PM Changeset in webkit [253087] by Devin Rousso
  • 7 edits in trunk/Source/WebInspectorUI

Web Inspector: prefer non-blackboxed scripts when showing a source code location link
https://bugs.webkit.org/show_bug.cgi?id=204811

Reviewed by Timothy Hatcher.

  • UserInterface/Models/StackTrace.js:

(WI.StackTrace.prototype.get firstNonNativeNonAnonymousNotBlackboxedCallFrame): Added.
(WI.StackTrace.prototype.get firstNonNativeCallFrame): Deleted.
(WI.StackTrace.prototype.get firstNonNativeNonAnonymousCallFrame): Deleted.
Include logic to skip call frames that are blackboxed, unless there are no non-blackboxed
call frames, in which case fall back to the first non-native non-anonymous call frame.
Drive-by: remove unused function.

  • UserInterface/Views/ConsoleMessageView.js:

(WI.ConsoleMessageView.prototype.render):
(WI.ConsoleMessageView.prototype.clearSessionState): Added.
(WI.ConsoleMessageView.prototype._appendLocationLink):
(WI.ConsoleMessageView.prototype._handleDebuggerBlackboxChanged): Added.
(WI.ConsoleMessageView.prototype.clearSavedVariableState): Deleted.

  • UserInterface/Views/LogContentView.js:

(WI.LogContentView.prototype._sessionStarted):
(WI.LogContentView.prototype._logCleared):
Listen for changes to the debugger blackbox to re-render the location link.

  • UserInterface/Views/StackTraceView.js:

(WI.StackTraceView):

  • UserInterface/Views/CallFrameView.js:

(WI.CallFrameView):

  • UserInterface/Views/CallFrameView.css:

(.call-frame.blackboxed > .title, .call-frame.blackboxed:not(:hover, :focus) > .subtitle): Added.
Add a constructor option to control whether blackboxed frames are indicated visually.

7:30 PM Changeset in webkit [253086] by rniwa@webkit.org
  • 2 edits in trunk/Source/WebCore

Use the event loop instead of DocumentEventQueue and WorkerEventQueue
https://bugs.webkit.org/show_bug.cgi?id=204447

  • page/PointerCaptureController.cpp:

(WebCore::PointerCaptureController::elementWasRemoved): Fixed a typo.

7:26 PM Changeset in webkit [253085] by Devin Rousso
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: Uncaught Exception: undefined is not an object (evaluating 'navigationItem.parentNavigationBar')
https://bugs.webkit.org/show_bug.cgi?id=204830

Reviewed by Timothy Hatcher.

  • UserInterface/Controllers/CSSManager.js:

(WI.CSSManager.prototype._mainResourceDidChange):
When the main resource changes, make sure to clear the _forcedAppearance member variable.
This way, when the main WI.DOMTreeContentView reloads, it isn't left in an unknown state.

  • UserInterface/Views/DOMTreeContentView.js:

(WI.DOMTreeContentView):
(WI.DOMTreeContentView.prototype._defaultAppearanceDidChange):
(WI.DOMTreeContentView.prototype._toggleAppearance):
Always create the Force Appearance navigation item, rather than destroying and recreating it
each time the page navigates. Instead, just update the tooltip (which was all that really
changed) whenever the default appearance changes. Depending on the timing of events during a
page navigation, _forceAppearanceButtonNavigationItem could be null.

  • UserInterface/Views/ActivateButtonNavigationItem.js:

(WI.ActivateButtonNavigationItem.prototype.set defaultToolTip): Added.
(WI.ActivateButtonNavigationItem.prototype.set activatedToolTip): Added.
Allow the various tooltips to be updated after creation.

7:06 PM Changeset in webkit [253084] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Timelines: stopping time marker is permanently removed when the current recording is cleared
https://bugs.webkit.org/show_bug.cgi?id=204827

Reviewed by Timothy Hatcher.

  • UserInterface/Views/TimelineOverview.js:

(WI.TimelineOverview.prototype._recordingReset):
Re-add the marker (and ensure that it's hidden) when the active recording is reset.

7:04 PM Changeset in webkit [253083] by sbarati@apple.com
  • 9 edits in trunk/Source/JavaScriptCore

Remove "patch" struct from StructureStubInfo because it adds unnecessary padding
https://bugs.webkit.org/show_bug.cgi?id=204392

Reviewed by Tadeu Zagallo.

By doing this, we reduce the size of StructureStubInfo from 120 bytes to 112
bytes.

  • bytecode/AccessCase.cpp:

(JSC::AccessCase::generateWithGuard):
(JSC::AccessCase::generateImpl):

  • bytecode/GetterSetterAccessCase.cpp:

(JSC::GetterSetterAccessCase::emitDOMJITGetter):

  • bytecode/InlineAccess.cpp:

(JSC::linkCodeInline):
(JSC::InlineAccess::generateSelfPropertyAccess):
(JSC::getScratchRegister):
(JSC::InlineAccess::generateSelfPropertyReplace):
(JSC::InlineAccess::generateArrayLength):
(JSC::InlineAccess::generateStringLength):
(JSC::InlineAccess::generateSelfInAccess):
(JSC::InlineAccess::rewireStubAsJump):

  • bytecode/PolymorphicAccess.cpp:

(JSC::PolymorphicAccess::regenerate):

  • bytecode/StructureStubInfo.h:

(JSC::StructureStubInfo::inlineSize const):
(JSC::StructureStubInfo::patchableJump):
(JSC::StructureStubInfo::valueRegs const):
(JSC::StructureStubInfo::propertyRegs const):
(JSC::StructureStubInfo::baseRegs const):
(JSC::StructureStubInfo::baseGPR const): Deleted.
(JSC::StructureStubInfo::slowPathCallLocation): Deleted.
(JSC::StructureStubInfo::doneLocation): Deleted.
(JSC::StructureStubInfo::slowPathStartLocation): Deleted.

  • dfg/DFGOSRExitCompilerCommon.cpp:

(JSC::DFG::callerReturnPC):

  • jit/JITInlineCacheGenerator.cpp:

(JSC::JITInlineCacheGenerator::JITInlineCacheGenerator):
(JSC::JITInlineCacheGenerator::finalize):
(JSC::JITByIdGenerator::JITByIdGenerator):
(JSC::JITGetByIdWithThisGenerator::JITGetByIdWithThisGenerator):
(JSC::JITPutByIdGenerator::JITPutByIdGenerator):
(JSC::JITInstanceOfGenerator::JITInstanceOfGenerator):
(JSC::JITGetByValGenerator::JITGetByValGenerator):

  • jit/Repatch.cpp:

(JSC::tryCacheGetBy):
(JSC::repatchGetBy):
(JSC::repatchArrayGetByVal):
(JSC::tryCachePutByID):
(JSC::repatchPutByID):
(JSC::tryCacheInByID):
(JSC::repatchInByID):
(JSC::repatchInstanceOf):
(JSC::resetGetBy):
(JSC::resetPutByID):
(JSC::resetPatchableJump):
(JSC::resetInByID):

6:41 PM Changeset in webkit [253082] by wilander@apple.com
  • 39 edits
    4 copies
    4 adds in trunk

Resource Load Statistics (experimental): Delete non-cookie website data after 7 days of no user interaction
https://bugs.webkit.org/show_bug.cgi?id=204779
<rdar://problem/57578989>

Reviewed by Alex Christensen.

Source/WebCore:

Trackers are continuing to move cross-site tracking IDs into first-party storage.
This change ages out script-writable non-cookie website data in alignment with the
7-day cap on client-side cookies.

Tests: http/tests/resourceLoadStatistics/website-data-removal-for-site-with-user-interaction-database.html

http/tests/resourceLoadStatistics/website-data-removal-for-site-with-user-interaction.html
http/tests/resourceLoadStatistics/website-data-removal-for-site-without-user-interaction-database.html
http/tests/resourceLoadStatistics/website-data-removal-for-site-without-user-interaction.html

  • page/Settings.yaml:

New experimental feature, off by default.

  • platform/network/NetworkStorageSession.h:

Added a boolean enum WebCore::FirstPartyWebsiteDataRemovalMode.

Source/WebKit:

Trackers are continuing to move cross-site tracking IDs into first-party storage.
This change ages out script-writable non-cookie website data in alignment with the
7-day cap on client-side cookies.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::shouldRemoveAllButCookiesFor const):

Now makes use of the set WebCore::FirstPartyWebsiteDataRemovalMode.

  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.cpp:

(WebKit::ResourceLoadStatisticsMemoryStore::shouldRemoveAllButCookiesFor const):

Now makes use of the set WebCore::FirstPartyWebsiteDataRemovalMode.

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:

(WebKit::ResourceLoadStatisticsStore::setFirstPartyWebsiteDataRemovalMode):
(WebKit::ResourceLoadStatisticsStore::firstPartyWebsiteDataRemovalMode const):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::setFirstPartyWebsiteDataRemovalMode):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::setFirstPartyWebsiteDataRemovalModeForTesting):

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/NetworkSession.cpp:

(WebKit::NetworkSession::setResourceLoadStatisticsEnabled):
(WebKit::NetworkSession::recreateResourceLoadStatisticStore):
(WebKit::NetworkSession::forwardResourceLoadStatisticsSettings):

New convenience function to avoid code duplication in
NetworkSession::setResourceLoadStatisticsEnabled() and
NetworkSession::forwardResourceLoadStatisticsSettings().

  • NetworkProcess/NetworkSession.h:
  • NetworkProcess/NetworkSessionCreationParameters.cpp:

(WebKit::NetworkSessionCreationParameters::encode const):
(WebKit::NetworkSessionCreationParameters::decode):

  • NetworkProcess/NetworkSessionCreationParameters.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):

  • Scripts/webkit/messages.py:

Makes sure the WebCore::FirstPartyWebsiteDataRemovalMode is found in WebCore/NetworkStorageSession.h.

  • Shared/WebPreferences.yaml:

New experimental feature, off by default.

  • UIProcess/API/C/WKWebsiteDataStoreRef.cpp:

(WKWebsiteDataStoreSetResourceLoadStatisticsFirstPartyWebsiteDataRemovalModeForTesting):
(WKWebsiteDataStoreStatisticsResetToConsistentState):

  • UIProcess/API/C/WKWebsiteDataStoreRef.h:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::setFirstPartyWebsiteDataRemovalModeForTesting):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::ensureNetworkProcess):

  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::WebsiteDataStore::parameters):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::setResourceLoadStatisticsFirstPartyWebsiteDataRemovalModeForTesting):

  • UIProcess/WebsiteData/WebsiteDataStore.h:

Tools:

These changes are test infrastructure so that TestRunner can
control the new setting.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:

(WTR::InjectedBundle::didReceiveMessageToPage):

  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::setStatisticsFirstPartyWebsiteDataRemovalMode):
(WTR::TestRunner::statisticsCallDidSetFirstPartyWebsiteDataRemovalModeCallback):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::setStatisticsFirstPartyWebsiteDataRemovalMode):

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
(WTR::TestInvocation::didSetFirstPartyWebsiteDataRemovalMode):

  • WebKitTestRunner/TestInvocation.h:

LayoutTests:

  • http/tests/resourceLoadStatistics/website-data-removal-for-site-navigated-to-with-link-decoration-database.html:
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-navigated-to-with-link-decoration.html:

Fixed some minor stuff in these two test cases to make any failures more clear.

  • http/tests/resourceLoadStatistics/website-data-removal-for-site-with-user-interaction-database-expected.txt: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-with-user-interaction-database.html: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-with-user-interaction-expected.txt: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-with-user-interaction.html: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-without-user-interaction-database-expected.txt: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-without-user-interaction-database.html: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-without-user-interaction-expected.txt: Added.
  • http/tests/resourceLoadStatistics/website-data-removal-for-site-without-user-interaction.html: Added.
6:36 PM Changeset in webkit [253081] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

The animation of returning to inline from PiP targets wrong destination rectangle
https://bugs.webkit.org/show_bug.cgi?id=204819

Patch by Peng Liu <Peng Liu> on 2019-12-03
Reviewed by Jer Noble.

We have to force AVPlayerViewController's view (which is hidden when it is returning to inline in another tab) to run layout
after we set its target size and position to make sure all layers inside the view have the correct information.
Otherwise, the return to inline animation will be incorrect.

  • platform/ios/VideoFullscreenInterfaceAVKit.mm:

(VideoFullscreenInterfaceAVKit::preparedToReturnToInline):

6:33 PM Changeset in webkit [253080] by ysuzuki@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

Unreviewed, fix build failure
https://bugs.webkit.org/show_bug.cgi?id=186552

  • wasm/WasmAirIRGenerator.cpp:

(JSC::Wasm::AirIRGenerator::getGlobal):

  • wasm/WasmB3IRGenerator.cpp:

(JSC::Wasm::B3IRGenerator::setGlobal):

6:22 PM Changeset in webkit [253079] by Simon Fraser
  • 73 edits
    4 adds in trunk

calc() serialization doesn't match the spec
https://bugs.webkit.org/show_bug.cgi?id=203442
LayoutTests/imported/w3c:

<rdar://problem/56639402>

Reviewed by Dean Jackson.

New results. Current WPT don't reflect the new serialization rules yet, so we expect
some failing results here.

  • web-platform-tests/css/css-align/gaps/column-gap-parsing-001-expected.txt:
  • web-platform-tests/css/css-align/gaps/gap-parsing-001-expected.txt:
  • web-platform-tests/css/css-align/gaps/grid-column-gap-parsing-001-expected.txt:
  • web-platform-tests/css/css-align/gaps/grid-gap-parsing-001-expected.txt:
  • web-platform-tests/css/css-align/gaps/grid-row-gap-parsing-001-expected.txt:
  • web-platform-tests/css/css-align/gaps/row-gap-parsing-001-expected.txt:
  • web-platform-tests/css/css-box/parsing/padding-valid-expected.txt:
  • web-platform-tests/css/css-shapes/animation/shape-outside-interpolation-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-margin-003-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-circle-010-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-circle-011-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-ellipse-010-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-ellipse-011-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-inset-008-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-inset-009-expected.txt:
  • web-platform-tests/css/css-shapes/shape-outside/values/shape-outside-polygon-006-expected.txt:
  • web-platform-tests/css/css-values/calc-background-position-002-expected.txt:
  • web-platform-tests/css/css-values/calc-background-position-003-expected.txt:
  • web-platform-tests/css/css-values/calc-nesting-002-expected.txt:
  • web-platform-tests/css/css-values/calc-serialization-002-expected.txt:
  • web-platform-tests/css/css-values/calc-serialization-expected.txt:
  • web-platform-tests/css/css-values/minmax-angle-computed-expected.txt:
  • web-platform-tests/css/css-values/minmax-angle-serialize-expected.txt:
  • web-platform-tests/css/css-values/minmax-length-percent-serialize-expected.txt:
  • web-platform-tests/css/css-values/minmax-length-serialize-expected.txt:
  • web-platform-tests/css/css-values/minmax-percentage-serialize-expected.txt:
  • web-platform-tests/css/css-values/minmax-time-computed-expected.txt:
  • web-platform-tests/css/css-values/minmax-time-serialize-expected.txt:

Source/WebCore:

<rdar://problem/56639402>

Reviewed by Dean Jackson.

These changes implement the calc() simplification and serialization rules described in
https://drafts.csswg.org/css-values-4/#calc-internal. They also make it easy to add the
new math functions in future.

The major changes are:

  1. Create Negate and Invert nodes to handle subtraction and division, so that Product and Sum are the only math operators that are tracked, which makes it possible to sort child nodes for simplification.
  1. After parsing, do a bottom-up simplification parse following <https://drafts.csswg.org/css-values-4/#calc-simplification>, which sorts child nodes according to <https://drafts.csswg.org/css-values-4/#sort-a-calculations-children>, combines child nodes where possible, and hoists child nodes up to their parents were possible. Simplification always preserves a calc-like function at the root.

This simplification also does unit canonicalization (e.g. all absolute lengths get px units).
To make unit conversion more explicit, pass a CSSUnitType into doubleValue() methods so that
it's clear what units the resulting value is in.

  1. Serialize according to <https://drafts.csswg.org/css-values-4/#calc-serialize> which fixes bugs with nested parentheses.

This patch does not completely implement the type checking and conversion rules described in <https://drafts.csswg.org/css-values-4/#calc-type-checking>
and <https://drafts.css-houdini.org/css-typed-om-1/#numeric-typing>.

Tests: fast/css/calc-parsing-limits.html

fast/css/calc-parsing.html

  • css/CSSCalculationValue.cpp:

(WebCore::calculationCategoryForCombination):
(WebCore::canonicalUnitTypeForCalculationCategory):
(WebCore::functionFromOperator):
(WebCore::CSSCalcPrimitiveValueNode::isNumericValue const):
(WebCore::CSSCalcPrimitiveValueNode::isNegative const):
(WebCore::CSSCalcPrimitiveValueNode::negate):
(WebCore::CSSCalcPrimitiveValueNode::invert):
(WebCore::CSSCalcPrimitiveValueNode::add):
(WebCore::CSSCalcPrimitiveValueNode::multiply):
(WebCore::CSSCalcPrimitiveValueNode::convertToUnitType):
(WebCore::CSSCalcPrimitiveValueNode::canonicalizeUnit):
(WebCore::CSSCalcPrimitiveValueNode::doubleValue const):
(WebCore::CSSCalcNegateNode::createCalcExpression const):
(WebCore::CSSCalcNegateNode::dump const):
(WebCore::CSSCalcInvertNode::createCalcExpression const):
(WebCore::CSSCalcInvertNode::dump const):
(WebCore::categoryForInvert):
(WebCore::determineCategory):
(WebCore::CSSCalcOperationNode::create):
(WebCore::CSSCalcOperationNode::createSum):
(WebCore::CSSCalcOperationNode::createProduct):
(WebCore::CSSCalcOperationNode::hoistChildrenWithOperator):
(WebCore::sortingCategoryForType):
(WebCore::sortingCategory):
(WebCore::primitiveTypeForCombination):
(WebCore::conversionToAddValuesWithTypes):
(WebCore::CSSCalcOperationNode::canCombineAllChildren const):
(WebCore::CSSCalcOperationNode::combineChildren):
(WebCore::CSSCalcOperationNode::simplify):
(WebCore::CSSCalcOperationNode::simplifyRecursive):
(WebCore::CSSCalcOperationNode::simplifyNode):
(WebCore::CSSCalcOperationNode::primitiveType const):
(WebCore::CSSCalcOperationNode::doubleValue const):
(WebCore::CSSCalcOperationNode::computeLengthPx const):
(WebCore::CSSCalcOperationNode::buildCSSText):
(WebCore::functionPrefixForOperator):
(WebCore::CSSCalcOperationNode::buildCSSTextRecursive):
(WebCore::CSSCalcOperationNode::evaluateOperator):
(WebCore::CSSCalcExpressionNodeParser::parseCalc):
(WebCore::checkDepthAndIndex):
(WebCore::CSSCalcExpressionNodeParser::parseCalcFunction):
(WebCore::CSSCalcExpressionNodeParser::parseValue):
(WebCore::CSSCalcExpressionNodeParser::parseCalcValue):
(WebCore::CSSCalcExpressionNodeParser::parseCalcProduct):
(WebCore::CSSCalcExpressionNodeParser::parseCalcSum):
(WebCore::createCSS):
(WebCore::CSSCalcValue::customCSSText const):
(WebCore::CSSCalcValue::doubleValue const):
(WebCore::CSSCalcValue::create):
(WebCore::CSSCalcOperationNode::createSimplified): Deleted.
(WebCore::CSSCalcOperationNode::buildCssText): Deleted.
(WebCore::CSSCalcOperationNode::customCSSText const): Deleted.
(WebCore::CSSCalcExpressionNodeParser::parseValueTerm): Deleted.
(WebCore::CSSCalcExpressionNodeParser::parseValueMultiplicativeExpression): Deleted.
(WebCore::CSSCalcExpressionNodeParser::parseAdditiveValueExpression): Deleted.
(WebCore::CSSCalcExpressionNodeParser::parseMinMaxExpression): Deleted.
(WebCore::CSSCalcExpressionNodeParser::parseValueExpression): Deleted.

  • css/CSSCalculationValue.h:
  • css/CSSPrimitiveValue.cpp:

(WebCore::CSSPrimitiveValue::unitTypeString):

  • css/CSSPrimitiveValue.h:
  • platform/CalculationValue.cpp:

(WebCore::CalcExpressionNegation::evaluate const):
(WebCore::CalcExpressionNegation::operator== const):
(WebCore::CalcExpressionNegation::dump const):
(WebCore::operator==):
(WebCore::CalcExpressionInversion::evaluate const):
(WebCore::CalcExpressionInversion::dump const):
(WebCore::CalcExpressionInversion::operator== const):
(WebCore::CalcExpressionOperation::evaluate const):
(WebCore::operator<<):

  • platform/CalculationValue.h:

LayoutTests:

Reviewed by Dean Jackson.

New results, mainly because of new simplification rules.

  • css3/calc/cssom-expected.txt:
  • css3/calc/simplification-expected.txt:
  • css3/flexbox/flex-property-parsing-expected.txt:
  • css3/flexbox/flex-property-parsing.html:
  • css3/scroll-snap/scroll-snap-property-computed-style-expected.txt:
  • css3/scroll-snap/scroll-snap-property-computed-style.js:
  • css3/scroll-snap/scroll-snap-property-parsing-expected.txt:
  • css3/scroll-snap/scroll-snap-property-parsing.js:
  • css3/shapes/shape-outside/values/support/parsing-utils.js:
  • fast/css-grid-layout/grid-columns-rows-get-set-expected.txt:
  • fast/css-grid-layout/grid-columns-rows-get-set-multiple-expected.txt:
  • fast/css-grid-layout/non-grid-columns-rows-get-set-expected.txt:
  • fast/css-grid-layout/non-grid-columns-rows-get-set-multiple-expected.txt:
  • fast/css-grid-layout/resources/grid-columns-rows-get-set-multiple.js:
  • fast/css-grid-layout/resources/grid-columns-rows-get-set.js:
  • fast/css-grid-layout/resources/non-grid-columns-rows-get-set-multiple.js:
  • fast/css-grid-layout/resources/non-grid-columns-rows-get-set.js:
  • fast/css/calc-parsing-expected.txt: Added.
  • fast/css/calc-parsing-limits-expected.txt: Added.
  • fast/css/calc-parsing-limits.html: Added.
  • fast/css/calc-parsing.html: Added.
  • fast/css/calc-with-angle-time-frequency-expected.txt:
  • fast/css/calc-with-angle-time-frequency.html:
  • fast/css/column-width-calculated-value-expected.txt:
  • fast/css/column-width-calculated-value.html:
  • fast/css/turn-angle-double-expected.txt:
  • fast/css/turn-angle-double.html:
  • fast/shapes/parsing/parsing-shape-outside-expected.txt:
  • fast/shapes/parsing/parsing-test-utils.js:
6:10 PM Changeset in webkit [253078] by Alan Coon
  • 3 edits in tags/Safari-609.1.11/Source/WebCore

Cherry-pick r253062. rdar://problem/57576474

Experimental support for HDR media query
https://bugs.webkit.org/show_bug.cgi?id=204422
<rdar://problem/56799662>

Reviewed by Eric Carlson.

Follow-up to r252762 for platforms that don't have MediaToolbox.framework.

  • platform/ios/PlatformScreenIOS.mm: (WebCore::screenSupportsHighDynamicRange):
  • platform/mac/PlatformScreenMac.mm: (WebCore::collectScreenProperties): (WebCore::screenSupportsHighDynamicRange):

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

6:10 PM Changeset in webkit [253077] by Alan Coon
  • 2 edits in tags/Safari-609.1.11/Source/WebCore

Cherry-pick r252881. rdar://problem/57487005

Document::needsStyleRecalc() shouldn't return true for fragment scrolling (m_gotoAnchorNeededAfterStylesheetsLoad)
https://bugs.webkit.org/show_bug.cgi?id=204593

Reviewed by Antti Koivisto.

After r252761, we no longer triggers a fragment scrolling as a part of style resolution.
Consequently, there is no need for Document::needsStyleRecalc() to return true
even when m_gotoAnchorNeededAfterStylesheetsLoad is set and there are no more pending stylesheets.

No new tests since there shouldn't really be any observable behavior difference.

  • dom/Document.cpp: (WebCore::Document::needsStyleRecalc const):

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

6:04 PM Changeset in webkit [253076] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

[iOS] Unable to interact with the view after a back swipe until lifting the finger off the screen
https://bugs.webkit.org/show_bug.cgi?id=204821

Reviewed by Tim Horton.

If you swipe back on iOS and then put your finger on the screen before the view gesture snapshot is taken down,
your gestures will not be recognized, even after the snapshot is taken down, until after you lift your finger
off the screen and back on. This makes MobileSafari look more unresponsive than it needs to be.

To address the issue, disable user interactions for the snapshot view, so that interactions go through to the
actual view underneath.

  • UIProcess/ios/ViewGestureControllerIOS.mm:

(WebKit::ViewGestureController::beginSwipeGesture):

5:42 PM Changeset in webkit [253075] by ysuzuki@apple.com
  • 19 edits
    2 deletes in trunk/Source/JavaScriptCore

[JSC] Remove WebAssemblyToJSCallee
https://bugs.webkit.org/show_bug.cgi?id=204808

Reviewed by Tadeu Zagallo.

This patch drops WebAssemblyToJSCallee. It was originally required to put small cell to retrieve VM from callee.
But now this limitation is removed. We can just put JSWebAssemblyModule in callee place instead.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Sources.txt:
  • interpreter/CallFrame.cpp:

(JSC::CallFrame::isAnyWasmCallee):

  • interpreter/StackVisitor.cpp:

(JSC::StackVisitor::Frame::calleeSaveRegistersForUnwinding):

  • jit/Repatch.cpp:

(JSC::webAssemblyOwner):
(JSC::linkFor):
(JSC::linkPolymorphicCall):

  • runtime/JSCast.h:
  • runtime/JSCell.cpp:
  • runtime/JSCellInlines.h:

(JSC::isWebAssemblyModule):
(JSC::isWebAssemblyToJSCallee): Deleted.

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::visitChildren):

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::webAssemblyWrapperFunctionStructure const):
(JSC::JSGlobalObject::webAssemblyToJSCalleeStructure const): Deleted.

  • runtime/JSType.cpp:

(WTF::printInternal):

  • runtime/JSType.h:
  • wasm/WasmOperations.cpp:

(JSC::Wasm::operationWasmToJSException):

  • wasm/js/JSWebAssemblyInstance.cpp:

(JSC::JSWebAssemblyInstance::finishCreation):
(JSC::JSWebAssemblyInstance::visitChildren):

  • wasm/js/JSWebAssemblyInstance.h:
  • wasm/js/JSWebAssemblyModule.cpp:

(JSC::JSWebAssemblyModule::createStructure):
(JSC::JSWebAssemblyModule::finishCreation):
(JSC::JSWebAssemblyModule::visitChildren):
(JSC::JSWebAssemblyModule::callee const): Deleted.

  • wasm/js/JSWebAssemblyModule.h:
  • wasm/js/WasmToJS.cpp:

(JSC::Wasm::handleBadI64Use):
(JSC::Wasm::wasmToJS):

  • wasm/js/WebAssemblyToJSCallee.cpp: Removed.
  • wasm/js/WebAssemblyToJSCallee.h: Removed.
5:36 PM Changeset in webkit [253074] by ysuzuki@apple.com
  • 73 edits
    5 copies
    1 move
    17 adds in trunk

Adopt the new WebAssembly.Global system
https://bugs.webkit.org/show_bug.cgi?id=186552

Reviewed by Keith Miller.

JSTests:

  1. Update spec-harness to accept newer tests. And we update several tests that does not work with the old harness.
  2. Add WebAssembly.Global tests.
  • wasm/js-api/global-error.js:

(assert.throws.new.WebAssembly.Module.bin):
(new.WebAssembly.Module):
(assert.throws):

  • wasm/js-api/global-external-init-from-import.js:
  • wasm/js-api/globals-export.js:
  • wasm/modules/js-wasm-global-namespace.js:

(assert.throws):

  • wasm/modules/js-wasm-global.js:

(assert.throws):

  • wasm/modules/wasm-import-wasm-export-i64-error.js:
  • wasm/references/anyref_globals.js:
  • wasm/references/func_ref.js:

(assert.eq.instance.exports.fix):

  • wasm/spec-harness.js:

(getGlobal):
(let.console.log):

  • wasm/spec-harness/sync_index.js: Renamed from JSTests/wasm/spec-harness/index.js.

(reinitializeRegistry.let.handler.get return):
(module):

  • wasm/spec-tests/call.wast.js:
  • wasm/spec-tests/exports.wast.js:
  • wasm/spec-tests/globals.wast.js:
  • wasm/spec-tests/if.wast.js:
  • wasm/spec-tests/imports.wast.js:
  • wasm/spec-tests/linking.wast.js:
  • wasm/spec-tests/memory.wast.js:
  • wasm/stress/immutable-globals.js: Added.

(import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.i.assert.eq.instance.exports.getI32):
(import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.i.assert.eq):

  • wasm/stress/mutable-globals-cross.js: Added.

(import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.const.instance1):
(import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.const.instance2):

  • wasm/stress/mutable-globals.js: Added.

(import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.i.instance.exports.setI32AsI64):

LayoutTests/imported/w3c:

  • web-platform-tests/wasm/jsapi/constructor/instantiate-bad-imports.any-expected.txt:
  • web-platform-tests/wasm/jsapi/constructor/instantiate-bad-imports.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/global/constructor.any-expected.txt:
  • web-platform-tests/wasm/jsapi/global/constructor.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/global/toString.any-expected.txt:
  • web-platform-tests/wasm/jsapi/global/toString.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/global/value-set.any-expected.txt:
  • web-platform-tests/wasm/jsapi/global/value-set.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/global/valueOf.any-expected.txt:
  • web-platform-tests/wasm/jsapi/global/valueOf.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/instance/constructor-bad-imports.any-expected.txt:
  • web-platform-tests/wasm/jsapi/instance/constructor-bad-imports.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/instance/constructor.any-expected.txt:
  • web-platform-tests/wasm/jsapi/instance/constructor.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/interface.any-expected.txt:
  • web-platform-tests/wasm/jsapi/interface.any.worker-expected.txt:
  • web-platform-tests/wasm/jsapi/module/exports.any-expected.txt:
  • web-platform-tests/wasm/jsapi/module/exports.any.worker-expected.txt:

Source/JavaScriptCore:

This patch adds WebAssembly.Global implementation. It is already included in the Wasm spec (this means, it is not in
staging right now: it was stage-4, and included in the spec). WebAssembly.Global is a wrapper object around
"global" binding. This object can hold "immutable" and "mutable" global binding, and we can access Wasm globals through
this object. Furthermore, we can share mutable global binding through this object across WebAssembly modules.

To implement it efficiently, this patch introduces BindingMode to Wasm globals. If the mode is EmbeddedInInstance,
we continue using the current existing mechanism. If the mode is Portable, we store a pointer to actual value in
Wasm globals array in Wasm::Instance, so that we can access it through one additional dereference.
And we mark all immutable globals as EmbeddedInInstance. If the binding is immutable, internally we do not need to
have one binding. We can just continue using the current mechanism since users cannot observe whether immutable bindings'
storage is shared or not. If the global is mutable, and it is exported outside of the module, we use Portable mode.
So, all the previously used wasm global bindings are EmbeddedInInstance. Only newly added "mutable" "exported" bindings
are Portable and requires one additional dereference.

To access portable bindings efficiently, we add new Wasm bytecodes, get_global_portable_binding, set_global_portable_binding,
and set_global_ref_portable_binding.

This patch improves WPT wasm coverage significantly.

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Sources.txt:
  • bytecode/BytecodeList.rb:
  • heap/HeapCell.cpp:

(JSC::keepAlive):
(JSC::HeapCell::use const): Deleted.

  • heap/HeapCell.h:

(JSC::keepAlive):
(JSC::HeapCell::use const):

  • llint/WebAssembly.asm:
  • runtime/JSGlobalObject.cpp:
  • runtime/JSGlobalObject.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
  • wasm/WasmAirIRGenerator.cpp:

(JSC::Wasm::AirIRGenerator::getGlobal):
(JSC::Wasm::AirIRGenerator::setGlobal):

  • wasm/WasmB3IRGenerator.cpp:

(JSC::Wasm::B3IRGenerator::getGlobal):
(JSC::Wasm::B3IRGenerator::setGlobal):

  • wasm/WasmFormat.h:
  • wasm/WasmGlobal.cpp: Added.

(JSC::Wasm::Global::get const):
(JSC::Wasm::Global::set):
(JSC::Wasm::Global::visitAggregate):

  • wasm/WasmGlobal.h: Added.
  • wasm/WasmInstance.cpp:

(JSC::Wasm::Instance::Instance):
(JSC::Wasm::Instance::setGlobal):
(JSC::Wasm::Instance::linkGlobal):

  • wasm/WasmInstance.h:

(JSC::Wasm::Instance::loadI32Global const):
(JSC::Wasm::Instance::loadI64Global const):
(JSC::Wasm::Instance::setGlobal):
(JSC::Wasm::Instance::globalsToBinding):
(JSC::Wasm::Instance::getGlobalBinding):

  • wasm/WasmLLIntGenerator.cpp:

(JSC::Wasm::LLIntGenerator::getGlobal):
(JSC::Wasm::LLIntGenerator::setGlobal):

  • wasm/WasmModuleInformation.h:
  • wasm/WasmOperations.cpp:

(JSC::Wasm::operationWasmWriteBarrierSlowPath):

  • wasm/WasmOperations.h:
  • wasm/WasmSectionParser.cpp:

(JSC::Wasm::SectionParser::parseImport):
(JSC::Wasm::SectionParser::parseGlobal):
(JSC::Wasm::SectionParser::parseExport):
(JSC::Wasm::SectionParser::parseInitExpr):
(JSC::Wasm::SectionParser::parseGlobalType):

  • wasm/WasmSectionParser.h:
  • wasm/WasmSlowPaths.cpp:

(JSC::LLInt::WASM_SLOW_PATH_DECL):

  • wasm/WasmSlowPaths.h:
  • wasm/WasmValidate.cpp:

(JSC::Wasm::Validate::setGlobal):

  • wasm/js/JSWebAssembly.cpp:
  • wasm/js/JSWebAssemblyGlobal.cpp: Added.

(JSC::JSWebAssemblyGlobal::create):
(JSC::JSWebAssemblyGlobal::createStructure):
(JSC::JSWebAssemblyGlobal::JSWebAssemblyGlobal):
(JSC::JSWebAssemblyGlobal::finishCreation):
(JSC::JSWebAssemblyGlobal::destroy):
(JSC::JSWebAssemblyGlobal::visitChildren):

  • wasm/js/JSWebAssemblyGlobal.h: Copied from Source/JavaScriptCore/wasm/js/JSWebAssemblyMemory.h.
  • wasm/js/JSWebAssemblyInstance.cpp:

(JSC::JSWebAssemblyInstance::visitChildren):

  • wasm/js/JSWebAssemblyInstance.h:
  • wasm/js/JSWebAssemblyMemory.cpp:

(JSC::JSWebAssemblyMemory::destroy):

  • wasm/js/JSWebAssemblyMemory.h:
  • wasm/js/JSWebAssemblyModule.h:
  • wasm/js/JSWebAssemblyTable.h:
  • wasm/js/WebAssemblyGlobalConstructor.cpp: Added.

(JSC::constructJSWebAssemblyGlobal):
(JSC::callJSWebAssemblyGlobal):
(JSC::WebAssemblyGlobalConstructor::create):
(JSC::WebAssemblyGlobalConstructor::createStructure):
(JSC::WebAssemblyGlobalConstructor::finishCreation):
(JSC::WebAssemblyGlobalConstructor::WebAssemblyGlobalConstructor):

  • wasm/js/WebAssemblyGlobalConstructor.h: Copied from Source/JavaScriptCore/wasm/js/JSWebAssemblyMemory.h.
  • wasm/js/WebAssemblyGlobalPrototype.cpp: Added.

(JSC::getGlobal):
(JSC::webAssemblyGlobalProtoFuncValueOf):
(JSC::webAssemblyGlobalProtoGetterFuncValue):
(JSC::webAssemblyGlobalProtoSetterFuncValue):
(JSC::WebAssemblyGlobalPrototype::create):
(JSC::WebAssemblyGlobalPrototype::createStructure):
(JSC::WebAssemblyGlobalPrototype::finishCreation):
(JSC::WebAssemblyGlobalPrototype::WebAssemblyGlobalPrototype):

  • wasm/js/WebAssemblyGlobalPrototype.h: Copied from Source/JavaScriptCore/wasm/js/JSWebAssemblyMemory.h.
  • wasm/js/WebAssemblyModuleRecord.cpp:

(JSC::WebAssemblyModuleRecord::link):

5:33 PM Changeset in webkit [253073] by Jonathan Bedard
  • 2 edits in trunk/Tools

Python 3: Add support in webkitpy.bindings
https://bugs.webkit.org/show_bug.cgi?id=204783

Reviewed by Stephanie Lewis.

Allow Tools/Scripts/run-bindings-tests to support Python 3.

  • Scripts/webkitpy/bindings/main.py:

(BindingsTests.generate_supplemental_dependency): Encode unicode strings before
writing to file as bytes.

5:27 PM Changeset in webkit [253072] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

Enable security assertions on all ASAN builds
https://bugs.webkit.org/show_bug.cgi?id=204802

Patch by Sunny He <sunny_he@apple.com> on 2019-12-03
Reviewed by Ryosuke Niwa.

  • wtf/FeatureDefines.h:
4:34 PM Changeset in webkit [253071] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Use a 3 second timeout for the view gesture snapshot on macOS
https://bugs.webkit.org/show_bug.cgi?id=204818

Reviewed by Tim Horton.

Use a 3 second timeout for the view gesture snapshot on macOS, for consistency with iOS.
It used to be 5 seconds on macOS.

  • UIProcess/ViewGestureController.cpp:
4:16 PM Changeset in webkit [253070] by Truitt Savell
  • 2 edits in trunk/LayoutTests

6 fast/text/emoji-gender are expected to fail on Catalina 10.15.1 and newer
https://bugs.webkit.org/show_bug.cgi?id=204820

Unreviewed test gardening.

  • platform/mac/TestExpectations:
3:59 PM Changeset in webkit [253069] by Jonathan Bedard
  • 2 edits in trunk/Tools

results.webkit.org: Sort out certificates on Catalina
https://bugs.webkit.org/show_bug.cgi?id=202837

Unreviewed infrastructure repair.

Reverting the active parts of r250997 now that the certificates are sorted out.

  • Scripts/webkitpy/results/upload.py:

(Upload.upload):
(Upload.upload_archive):

3:41 PM Changeset in webkit [253068] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Assertion when encountering U_OTHER_NEUTRAL in createBidiRunsForLine at end of run
https://bugs.webkit.org/show_bug.cgi?id=204485

Patch by Doug Kelly <Doug Kelly> on 2019-12-03
Reviewed by Ryosuke Niwa.

Source/WebCore:

Comment out the assert for the default case when setting direction at
the end of a bidirectional run. The current algorithm may not fully
support UAX #9, but this assert also isn't helpful in development.

Test: fast/text/international/unicode-bidi-other-neutrals.html

  • platform/text/BidiResolver.h:

(WebCore::DerivedClass>::createBidiRunsForLine):

LayoutTests:

Add a simple test case which illustrates a neutral at the end of a
Unicode bidirectional run.

  • fast/text/international/unicode-bidi-other-neutrals-expected.html: Added.
  • fast/text/international/unicode-bidi-other-neutrals.html: Added.
3:34 PM Changeset in webkit [253067] by commit-queue@webkit.org
  • 5 edits
    2 adds in trunk/LayoutTests/imported/w3c

Re-sync web-platform-tests/html/webappapis/scripting/events from upstream
https://bugs.webkit.org/show_bug.cgi?id=204814

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-12-03
Reviewed by Ryosuke Niwa.

Re-sync web-platform-tests/html/webappapis/scripting/events from upstream 033bf248c8fa.
Basically, this patch syncs https://github.com/web-platform-tests/wpt/pull/20421 and also
unskips "event-handler-processing-algorithm-error" directory as it is already synced.

  • resources/import-expectations.json:
  • web-platform-tests/html/webappapis/scripting/events/*: Updated.
3:25 PM Changeset in webkit [253066] by Jonathan Bedard
  • 3 edits in trunk/Tools

results.webkit.org: Decrease ttl for archives
https://bugs.webkit.org/show_bug.cgi?id=204806
<rdar://problem/57527644>

Reviewed by Aakash Jain.

Make the ttl on the archive tables shorter, drop the existing table and create new ones
with a shorter ttl.

  • resultsdbpy/resultsdbpy/model/archive_context.py:

(ArchiveContext.ArchiveMetaDataByCommit): Define new ArchiveMetaDataByCommit table.
(ArchiveContext.ArchiveChunks): Ditto.

  • resultsdbpy/resultsdbpy/model/model.py:

(Model.init): Add archive ttl, 8 weeks by default.

3:17 PM Changeset in webkit [253065] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

REGRESSION (r252778): ASSERT(!m_networkLoad); in ~SpeculativeLoad()
https://bugs.webkit.org/show_bug.cgi?id=204813
<rdar://problem/57581082>

Reviewed by Antti Koivisto.

After r252778, SpeculativeLoadManager::revalidateSubresource() may delay the revalidation until we receive
the response for the main resource. We can hit the assertion in the SpeculativeLoad destructor if a speculative
revalidation for the SAME resource gets scheduled while we're waiting for the main resource response. When we
eventually receive the main resource response, we would call revalidateSubresource() again, which would create
a SpeculativeLoad and try to add it to m_pendingPreloads. Because m_pendingPreloads would already contain a
preload for this same resource, the SpeculativeLoad would not get added to the map and it would get destroyed
right away, before completing (thus hitting the assert). This unnecessary creation of the SpeculativeLoad is
inefficient and it is thus best to avoid it.

To address the issue, when we receive the response, we now make sure that m_pendingPreloads does not already
contain a preload for this resource before calling revalidateSubresource() again, similarly to what was
already done at the beginning of SpeculativeLoadManager::preloadEntry().

No new tests, unknown how to reproduce.

  • NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:

(WebKit::NetworkCache::SpeculativeLoadManager::revalidateSubresource):

3:03 PM Changeset in webkit [253064] by jer.noble@apple.com
  • 8 edits in trunk/Source/WebCore

Adopt AVContentKeyReportGroup
https://bugs.webkit.org/show_bug.cgi?id=204765

Reviewed by Eric Carlson.

Source/WebCore:

Adopt a new class, AVContentKeyReportGroup, which allows muliple MediaKeySessions to share
an AVContentKeySession, while allowing independent expiration and persistent key usage
tokens. However, this has to be runtime detected, so that existing usage of
AVContentKeySession continues to work on platform versions without report group support.

  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/avfoundation/objc/CDMInstanceFairPlayStreamingAVFObjC.h:
  • platform/graphics/avfoundation/objc/CDMInstanceFairPlayStreamingAVFObjC.mm:

(-[WebCoreFPSContentKeySessionDelegate initWithParent:]):
(-[WebCoreFPSContentKeySessionDelegate contentKeySession:contentProtectionSessionIdentifierDidChangeForKeyGroup:]):
(-[WebCoreFPSContentKeySessionDelegate contentKeySession:contentProtectionSessionIdentifierDidChangeForReportGroup:]):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::CDMInstanceFairPlayStreamingAVFObjC):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::ensureSession):
(WebCore::groupForRequest):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::didProvideRequest):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::didProvideRequests):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::didProvideRenewingRequest):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::didProvidePersistableRequest):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::didFailToProvideRequest):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::requestDidSucceed):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::shouldRetryRequestForReason):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::sessionIdentifierChanged):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::groupSessionIdentifierChanged):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::sessionForGroup const):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::CDMInstanceSessionFairPlayStreamingAVFObjC):
(WebCore::initTypeForRequest):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::requestLicense):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::removeSessionData):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::groupSessionIdentifierChanged):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::ensureSessionOrGroup):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::ensureSession): Deleted.

Source/WebCore/PAL:

  • pal/cocoa/AVFoundationSoftLink.h:
  • pal/cocoa/AVFoundationSoftLink.mm:
  • pal/spi/mac/AVFoundationSPI.h:
2:56 PM Changeset in webkit [253063] by eric.carlson@apple.com
  • 10 edits in trunk/Source

Add a runtime setting for media in the GPU process
https://bugs.webkit.org/show_bug.cgi?id=204801
<rdar://problem/57596199>

Reviewed by Jer Noble.

Source/WebCore:

  • page/Settings.yaml:

Source/WebKit:

  • Shared/WebPreferences.yaml:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

Source/WebKitLegacy/mac:

  • WebView/WebPreferenceKeysPrivate.h:
  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):
(-[WebPreferences outOfProcessMediaEnabled]):
(-[WebPreferences setOutOfProcessMediaEnabled:]):

  • WebView/WebPreferencesPrivate.h:
  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

2:35 PM Changeset in webkit [253062] by jer.noble@apple.com
  • 3 edits in trunk/Source/WebCore

Experimental support for HDR media query
https://bugs.webkit.org/show_bug.cgi?id=204422
<rdar://problem/56799662>

Reviewed by Eric Carlson.

Follow-up to r252762 for platforms that don't have MediaToolbox.framework.

  • platform/ios/PlatformScreenIOS.mm:

(WebCore::screenSupportsHighDynamicRange):

  • platform/mac/PlatformScreenMac.mm:

(WebCore::collectScreenProperties):
(WebCore::screenSupportsHighDynamicRange):

2:07 PM Changeset in webkit [253061] by chris.reid@sony.com
  • 6 edits
    2 adds in trunk

Regular expression hangs in Safari only
https://bugs.webkit.org/show_bug.cgi?id=202882
<rdar://problem/56236654>

Reviewed by Yusuke Suzuki.

JSTests:

  • stress/regress-202882.js: Added.

Source/WTF:

BumpPointerPool::ensureCapacityCrossPool can cause an infinite loop
if multiple large pools are deallocated and a new capacity does not
fit in the deallocated pools. BumpPointerPool should try using
more pools if the next one isn't large enough.

  • wtf/BumpPointerAllocator.h:

(WTF::BumpPointerPool::ensureCapacityCrossPool):

Tools:

  • TestWebKitAPI/CMakeLists.txt:
  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WTF/BumpPointerAllocator.cpp: Added.
12:34 PM Changeset in webkit [253060] by Jonathan Bedard
  • 2 edits in trunk/Tools

https://bugs.webkit.org/show_bug.cgi?id=204804
<rdar://problem/57595666>

Reviewed by Tim Horton.

  • Scripts/webkitpy/port/mac.py:

(MacCatalystPort):
(MacCatalystPort._build_driver_flags): Add SDKVARIANT=iosmac to build flags.

12:12 PM Changeset in webkit [253059] by pvollan@apple.com
  • 3 edits in trunk/Source/WebKit

Unreviewed assertion fix for older macOS versions after r253011.

  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::finishGrantingRequest):

  • UIProcess/UserMediaPermissionRequestManagerProxy.h:
12:06 PM Changeset in webkit [253058] by timothy_horton@apple.com
  • 3 edits in trunk/Source/WebCore

Start adding encoding support for DisplayList and some DisplayListItems
https://bugs.webkit.org/show_bug.cgi?id=204740

  • platform/graphics/GraphicsContext.cpp:

(WebCore::GraphicsContextStateChange::changesFromState const):

  • platform/graphics/GraphicsContext.h:

Remove GraphicsContextState::NoChange, which is not needed with OptionSet
and in fact causes assertions to fire.

11:33 AM Changeset in webkit [253057] by Alan Coon
  • 3 edits in tags/Safari-609.1.11/Source/WebCore

Cherry-pick r252956. rdar://problem/57438874

MockAudioSharedUnit should reset its last render time on start/stop/reconfigure
https://bugs.webkit.org/show_bug.cgi?id=204600
<rdar://problem/57438874>

Reviewed by Eric Carlson.

MockAudioSharedUnit was not resetting its last render time on stop/start/reconfigure.
If stopping for a long time and then restarting, the unit would flood the audio pipe with lots of data
and confuse the pipe.
Remove some member variables inherited from MockRealtimeAudioSource which are no longer needed.

Covered by imported/w3c/web-platform-tests/webrtc/RTCRtpReceiver-getSynchronizationSources.https.html being no longer flaky.

  • platform/mediastream/mac/MockAudioSharedUnit.h:
  • platform/mediastream/mac/MockAudioSharedUnit.mm: (WebCore::MockAudioSharedUnit::reconfigureAudioUnit): (WebCore::MockAudioSharedUnit::startInternal):

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

11:28 AM Changeset in webkit [253056] by commit-queue@webkit.org
  • 20 edits in trunk

[Web Animations] Add a runtime flag for Web Animations composite operations
https://bugs.webkit.org/show_bug.cgi?id=204718

Patch by Antoine Quint <Antoine Quint> on 2019-12-03
Reviewed by Dean Jackson.

Source/WebCore:

While we support parsing and output of composite modes via KeyframeEffect::getKeyframes(), we don't support them for blending properties.
We now have a runtime flag for that feature so that we can continue working on it but not necessarily expose the feature by default.

  • animation/KeyframeEffect.cpp:

(WebCore::processKeyframeLikeObject):
(WebCore::processIterableKeyframes):
(WebCore::processPropertyIndexedKeyframes):
(WebCore::KeyframeEffect::getKeyframes):

  • animation/KeyframeEffect.idl:
  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setWebAnimationsCompositeOperationsEnabled):
(WebCore::RuntimeEnabledFeatures::webAnimationsCompositeOperationsEnabled const):

Source/WebKit:

  • Shared/WebPreferences.yaml:

Source/WebKitLegacy/mac:

  • WebView/WebPreferenceKeysPrivate.h:
  • WebView/WebPreferences.mm:

(-[WebPreferences webAnimationsCompositeOperationsEnabled]):
(-[WebPreferences setWebAnimationsCompositeOperationsEnabled:]):

  • WebView/WebPreferencesPrivate.h:
  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Source/WebKitLegacy/win:

  • Interfaces/IWebPreferencesPrivate.idl:
  • WebPreferenceKeysPrivate.h:
  • WebPreferences.cpp:

(WebPreferences::initializeDefaultSettings):
(WebPreferences::setWebAnimationsCompositeOperationsEnabled):
(WebPreferences::webAnimationsCompositeOperationsEnabled):

  • WebPreferences.h:
  • WebView.cpp:

(WebView::notifyPreferencesChanged):

Tools:

  • DumpRenderTree/mac/DumpRenderTree.mm:

(enableExperimentalFeatures):

  • DumpRenderTree/win/DumpRenderTree.cpp:

(enableExperimentalFeatures):

11:08 AM Changeset in webkit [253055] by youenn@apple.com
  • 3 edits in trunk/Source/WebKit

UserMediaCaptureManager should have independent capture factories
https://bugs.webkit.org/show_bug.cgi?id=204786

Reviewed by Eric Carlson.

Refactor the code to make UserMediaCaptureManager have 3 different factories.
This allows having 3 potential active sources which are used on iOS.
We cannot test right now on iOS as audio capture in UIProcess is not yet ready.

  • WebProcess/cocoa/UserMediaCaptureManager.cpp:

(WebKit::UserMediaCaptureManager::Source::Source):
(WebKit::UserMediaCaptureManager::Source::~Source):
(WebKit::UserMediaCaptureManager::UserMediaCaptureManager):
(WebKit::UserMediaCaptureManager::~UserMediaCaptureManager):
(WebKit::UserMediaCaptureManager::initialize):
(WebKit::UserMediaCaptureManager::createCaptureSource):
(WebKit::UserMediaCaptureManager::AudioFactory::setAudioCapturePageState):
(WebKit::UserMediaCaptureManager::VideoFactory::setVideoCapturePageState):
(WebKit::UserMediaCaptureManager::setAudioCapturePageState): Deleted.
(WebKit::UserMediaCaptureManager::setVideoCapturePageState): Deleted.

  • WebProcess/cocoa/UserMediaCaptureManager.h:

(WebKit::UserMediaCaptureManager::AudioFactory::AudioFactory):
(WebKit::UserMediaCaptureManager::VideoFactory::VideoFactory):
(WebKit::UserMediaCaptureManager::DisplayFactory::DisplayFactory):

10:39 AM Changeset in webkit [253054] by Wenson Hsieh
  • 3 edits in trunk/LayoutTests

fast/events/touch/ios/passive-by-default-on-document-and-window.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=204797
<rdar://problem/57591431>

Reviewed by Tim Horton.

Fix the layout test by waiting for touchend events before finishing the test, such that passive touchend events
that were queued up via EventDispatcher::touchEvent have a chance to be dispatched to the page. Also, make the
test a bit more modern by replacing the UI script in the test with a call to a UIHelper method.

  • fast/events/touch/ios/passive-by-default-on-document-and-window-expected.txt:
  • fast/events/touch/ios/passive-by-default-on-document-and-window.html:
10:24 AM Changeset in webkit [253053] by jh718.park@samsung.com
  • 2 edits in trunk/Source/WebCore

Unreviewed. Remove build warning below since r252987.
warning: unused variable ‘currentTrack’ [-Wunused-variable]

No new tests, no behavioral changes.

  • Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.cpp:

(WebCore::LibWebRTCRtpSenderBackend::replaceTrack):

10:22 AM Changeset in webkit [253052] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Move trailing trimmable content logic to InlineItemRun
https://bugs.webkit.org/show_bug.cgi?id=204798
<rdar://problem/57593248>

Reviewed by Antti Koivisto.

Trailing letter spacing/fully trimmable whitespace logic should be internal to InlineItemRun.

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::removeTrailingTrimmableContent):
(WebCore::Layout::LineBuilder::appendTextContent):
(WebCore::Layout::LineBuilder::runContentHeight const):
(WebCore::Layout::LineBuilder::InlineItemRun::isTrimmableWhitespace const):
(WebCore::Layout::LineBuilder::InlineItemRun::hasTrailingLetterSpacing const):
(WebCore::Layout::LineBuilder::InlineItemRun::trailingLetterSpacing const):
(WebCore::Layout::LineBuilder::InlineItemRun::removeTrailingLetterSpacing):
(WebCore::Layout::shouldPreserveTrailingContent): Deleted.

  • layout/inlineformatting/InlineLineBuilder.h:

(WebCore::Layout::LineBuilder::Run::style const):
(WebCore::Layout::LineBuilder::InlineItemRun::style const):

10:17 AM Changeset in webkit [253051] by Chris Dumez
  • 9 edits in trunk/Source

PageConfiguration::pluginClient should use a smart pointer
https://bugs.webkit.org/show_bug.cgi?id=204780

Reviewed by Anders Carlsson.

Source/WebCore:

  • page/Page.cpp:

(WebCore::Page::Page):
(WebCore::Page::~Page):

  • page/Page.h:

(WebCore::Page::plugInClient const):

  • page/PageConfiguration.h:
  • page/PlugInClient.h:

Source/WebKit:

  • WebProcess/WebCoreSupport/WebPlugInClient.cpp:
  • WebProcess/WebCoreSupport/WebPlugInClient.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_overriddenMediaType):

10:13 AM Changeset in webkit [253050] by dino@apple.com
  • 2 edits in trunk/Source/WebCore

Fix MacCatalyst build.

  • platform/graphics/GraphicsContext3D.h:
9:56 AM Changeset in webkit [253049] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

Do not retry the EWS build due to flaky failures in layout-test
https://bugs.webkit.org/show_bug.cgi?id=204769

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py:

(AnalyzeLayoutTestsResults.start): Do not retry the build due to flaky tests failures.

  • BuildSlaveSupport/ews-build/steps_unittest.py:

(test_flaky_and_inconsistent_failures_without_clean_tree_failures): expected outcome changed from RETRY to SUCCESS.
(test_flaky_and_inconsistent_failures_with_clean_tree_failures): Ditto.
(test_flaky_and_consistent_failures_with_clean_tree_failures): Ditto.
(test_mildly_flaky_patch_with_some_tree_redness_and_flakiness): Ditto.

9:34 AM Changeset in webkit [253048] by Chris Dumez
  • 13 edits in trunk/Source

PageConfiguration::alternativeTextClient should use a smart pointer
https://bugs.webkit.org/show_bug.cgi?id=204777

Reviewed by Anders Carlsson.

Source/WebCore:

  • page/AlternativeTextClient.h:
  • page/Page.cpp:

(WebCore::Page::Page):
(WebCore::Page::~Page):

  • page/Page.h:

(WebCore::Page::alternativeTextClient const):

  • page/PageConfiguration.h:

Source/WebKit:

  • WebProcess/WebCoreSupport/WebAlternativeTextClient.h:
  • WebProcess/WebCoreSupport/mac/WebAlternativeTextClient.cpp:

(WebKit::WebAlternativeTextClient::pageDestroyed): Deleted.

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_overriddenMediaType):

Source/WebKitLegacy/mac:

  • WebCoreSupport/WebAlternativeTextClient.h:
  • WebCoreSupport/WebAlternativeTextClient.mm:

(WebAlternativeTextClient::pageDestroyed): Deleted.

  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):

9:12 AM Changeset in webkit [253047] by Kate Cheney
  • 2 edits in trunk/Source/WebKit

Activate the SQLite database as an on-by-default feature
https://bugs.webkit.org/show_bug.cgi?id=204774
<rdar://problem/56117706>

Reviewed by Brent Fulgham.

The flag to use the ITP Database backend should be set to true by default.

  • Shared/WebPreferences.yaml:
8:50 AM Changeset in webkit [253046] by timothy_horton@apple.com
  • 11 edits in trunk/Source/WebCore

Start adding encoding support for DisplayList and some DisplayListItems
https://bugs.webkit.org/show_bug.cgi?id=204740

Reviewed by Simon Fraser.

To be used in a later patch.

Start encoding and decoding DisplayList, and its child items. We
currently support only a subset of the item subclasses.

  • platform/graphics/GraphicsContext.cpp:

(WebCore::GraphicsContextStateChange::changesFromState const):
(WebCore::GraphicsContextStateChange::accumulate):
(WebCore::GraphicsContextStateChange::apply const):

  • platform/graphics/GraphicsContext.h:

Adopt OptionSet for GraphicsContextState::StateChangeFlags.

  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/Pattern.h:
  • platform/graphics/displaylists/DisplayList.h:

(WebCore::DisplayList::DisplayList::encode const):
(WebCore::DisplayList::DisplayList::decode):

  • platform/graphics/displaylists/DisplayListItems.cpp:

(WebCore::DisplayList::Item::Item):
(WebCore::DisplayList::DrawingItem::DrawingItem):
(WebCore::DisplayList::Save::Save):
(WebCore::DisplayList::Restore::Restore):
(WebCore::DisplayList::Translate::Translate):
(WebCore::DisplayList::Rotate::Rotate):
(WebCore::DisplayList::Scale::Scale):
(WebCore::DisplayList::SetState::SetState):
(WebCore::DisplayList::DrawRect::DrawRect):
(WebCore::DisplayList::DrawPath::DrawPath):
(WebCore::DisplayList::FillRect::FillRect):
(WebCore::DisplayList::FillRectWithColor::FillRectWithColor):
(WebCore::DisplayList::FillCompositedRect::FillCompositedRect):
(WebCore::DisplayList::FillPath::FillPath):
(WebCore::DisplayList::ClearRect::ClearRect):

  • platform/graphics/displaylists/DisplayListItems.h:

(WebCore::DisplayList::Item::isStateItemType):
(WebCore::DisplayList::Save::encode const):
(WebCore::DisplayList::Save::decode):
(WebCore::DisplayList::Restore::encode const):
(WebCore::DisplayList::Restore::decode):
(WebCore::DisplayList::Translate::encode const):
(WebCore::DisplayList::Translate::decode):
(WebCore::DisplayList::Rotate::encode const):
(WebCore::DisplayList::Rotate::decode):
(WebCore::DisplayList::Scale::encode const):
(WebCore::DisplayList::Scale::decode):
(WebCore::DisplayList::ConcatenateCTM::encode const):
(WebCore::DisplayList::ConcatenateCTM::decode):
(WebCore::DisplayList::SetState::create):
(WebCore::DisplayList::SetState::encode const):
(WebCore::DisplayList::SetState::decode):
(WebCore::DisplayList::DrawRect::encode const):
(WebCore::DisplayList::DrawRect::decode):
(WebCore::DisplayList::DrawPath::encode const):
(WebCore::DisplayList::DrawPath::decode):
(WebCore::DisplayList::FillRect::encode const):
(WebCore::DisplayList::FillRect::decode):
(WebCore::DisplayList::FillRectWithColor::encode const):
(WebCore::DisplayList::FillRectWithColor::decode):
(WebCore::DisplayList::FillCompositedRect::encode const):
(WebCore::DisplayList::FillCompositedRect::decode):
(WebCore::DisplayList::FillPath::encode const):
(WebCore::DisplayList::FillPath::decode):
(WebCore::DisplayList::ClearRect::encode const):
(WebCore::DisplayList::ClearRect::decode):
(WebCore::DisplayList::Item::encode const):
(WebCore::DisplayList::Item::decode):
(WebCore::DisplayList::Item::Item): Deleted.
(WebCore::DisplayList::DrawingItem::DrawingItem): Deleted.
(WebCore::DisplayList::Save::Save): Deleted.
(WebCore::DisplayList::Restore::Restore): Deleted.
(WebCore::DisplayList::Translate::Translate): Deleted.
(WebCore::DisplayList::Rotate::Rotate): Deleted.
(WebCore::DisplayList::Scale::Scale): Deleted.
(WebCore::DisplayList::SetState::SetState): Deleted.
(WebCore::DisplayList::DrawRect::DrawRect): Deleted.
(WebCore::DisplayList::DrawPath::DrawPath): Deleted.
(WebCore::DisplayList::FillRect::FillRect): Deleted.
(WebCore::DisplayList::FillRectWithColor::FillRectWithColor): Deleted.
(WebCore::DisplayList::FillCompositedRect::FillCompositedRect): Deleted.
(WebCore::DisplayList::FillPath::FillPath): Deleted.
(WebCore::DisplayList::ClearRect::ClearRect): Deleted.

  • platform/graphics/displaylists/DisplayListRecorder.h:
  • platform/graphics/displaylists/DisplayListReplayer.h:

(WebCore::DisplayList::Replayer::replay):

8:28 AM Changeset in webkit [253045] by youenn@apple.com
  • 18 edits in trunk

Add support for camera rotation when capturing in UIProcess
https://bugs.webkit.org/show_bug.cgi?id=204750

Reviewed by Eric Carlson.

Source/WebKit:

Make UserMediaCaptureManagerProxy have an OrientationNotifier.
It is updated by each web page of the web process being notified of a device orientation change.
Whenever a rotation happens, UIProcess sources are now notified to correctly compute the frame rotations.

Covered by existing tests.

  • UIProcess/API/C/WKPage.cpp:

(WKPageSetMockCameraOrientation):

  • UIProcess/API/C/WKPagePrivate.h:
  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.cpp:

(WebKit::UserMediaCaptureManagerProxy::createMediaSourceForCaptureDeviceWithConstraints):
(WebKit::UserMediaCaptureManagerProxy::setOrientation):

  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::setOrientationForMediaCapture):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebProcessProxy.h:

(WebKit::WebProcessProxy::userMediaCaptureManagerProxy):

  • UIProcess/ios/WebPageProxyIOS.mm:

(WebKit::WebPageProxy::setDeviceOrientation):

Tools:

Add test runner API to set the device rotation specifically for mock camera devices.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::setMockCameraOrientation):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::setMockCameraOrientation):

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

LayoutTests:

  • webrtc/video-rotation.html:

Capture in UIProcess on Cocoa port and make use of test runner API to simulate device rotation.

7:46 AM Changeset in webkit [253044] by pvollan@apple.com
  • 2 edits in trunk/LayoutTests

Layout Test fast/layoutformattingcontext/flow-integration-basic.html is failing
https://bugs.webkit.org/show_bug.cgi?id=204795

Unreviewed test gardening.

  • platform/win/TestExpectations:
7:42 AM Changeset in webkit [253043] by pvollan@apple.com
  • 2 edits in trunk/LayoutTests

The test webanimations/accelerated-animation-removal-upon-transition-completion.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=204794

Unreviewed test gardening.

  • platform/win/TestExpectations:
7:41 AM Changeset in webkit [253042] by Antti Koivisto
  • 6 edits
    2 moves in trunk/Source/WebCore

[LFC][Integration] Rename RenderBlockFlowLineLayout and move it to LayoutIntegration namespace
https://bugs.webkit.org/show_bug.cgi?id=204791

Reviewed by Sam Weinig.

Layout::RenderBlockFlowLineLayout -> LayoutIntegration::LineLayout

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/integration/LayoutIntegrationLineLayout.cpp: Renamed from Source/WebCore/layout/integration/RenderBlockFlowLineLayout.cpp.

(WebCore::LayoutIntegration::LineLayout::LineLayout):
(WebCore::LayoutIntegration::LineLayout::canUseFor):
(WebCore::LayoutIntegration::LineLayout::layout):
(WebCore::LayoutIntegration::LineLayout::prepareRootGeometryForLayout):
(WebCore::LayoutIntegration::LineLayout::displayInlineContent const):
(WebCore::LayoutIntegration::LineLayout::paint):
(WebCore::LayoutIntegration::LineLayout::textBoxesFor const):
(WebCore::LayoutIntegration::LineLayout::elementBoxFor const):
(WebCore::LayoutIntegration::LineLayout::rootLayoutBox const):

  • layout/integration/RenderBlockFlowLineLayout.h: Removed.
  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::layoutInlineChildren):
(WebCore::RenderBlockFlow::paintInlineChildren):
(WebCore::RenderBlockFlow::invalidateLineLayoutPath):
(WebCore::RenderBlockFlow::layoutLFCLines):

  • rendering/RenderBlockFlow.h:

(WebCore::RenderBlockFlow::hasLayoutFormattingContextLineLayout const):
(WebCore::RenderBlockFlow::layoutFormattingContextLineLayout const):
(WebCore::RenderBlockFlow::layoutFormattingContextLineLayout):
(WebCore::RenderBlockFlow::hasLFCLineLayout const): Deleted.
(WebCore::RenderBlockFlow::lfcLineLayout const): Deleted.
(WebCore::RenderBlockFlow::lfcLineLayout): Deleted.

  • rendering/line/LineLayoutTraversal.cpp:

(WebCore::LineLayoutTraversal::firstTextBoxFor):
(WebCore::LineLayoutTraversal::elementBoxFor):

7:20 AM Changeset in webkit [253041] by Antti Koivisto
  • 8 edits in trunk

[LFC][Integration] Shorten feature flag name
https://bugs.webkit.org/show_bug.cgi?id=204788

Reviewed by Sam Weinig.

Source/WebCore:

LayoutFormattingContextRenderTreeIntegrationEnabled -> LayoutFormattingContextIntegrationEnabled

  • layout/integration/RenderBlockFlowLineLayout.cpp:

(WebCore::Layout::RenderBlockFlowLineLayout::canUseFor):

  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setLayoutFormattingContextIntegrationEnabled):
(WebCore::RuntimeEnabledFeatures::layoutFormattingContextIntegrationEnabled const):
(WebCore::RuntimeEnabledFeatures::setLayoutFormattingContextRenderTreeIntegrationEnabled): Deleted.
(WebCore::RuntimeEnabledFeatures::layoutFormattingContextRenderTreeIntegrationEnabled const): Deleted.

Source/WebKit:

  • Shared/WebPreferences.yaml:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

LayoutTests:

  • fast/layoutformattingcontext/flow-integration-basic.html:
7:01 AM Changeset in webkit [253040] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

MediaRecorderPrivateWriter should not be destroyed until finishing its writing task completion handler is called
https://bugs.webkit.org/show_bug.cgi?id=204789
<rdar://problem/57561143>

Reviewed by Eric Carlson.

When stopping the recorder, we might stop recording the private writer without calling fetchData.
In that case, we do not wait for the writing completion handler.
Fix this by using the semaphore at the end of stopRecording.
Covered by existing test.

  • platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:

(WebCore::MediaRecorderPrivateWriter::stopRecording):
(WebCore::MediaRecorderPrivateWriter::fetchData):

6:52 AM Changeset in webkit [253039] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] TextUtil::width should not overflow when word/letter-spacing is larger than LayoutUnit::max
https://bugs.webkit.org/show_bug.cgi?id=204782
<rdar://problem/57580285>

Reviewed by Antti Koivisto.

LayoutUnit width = font.width(run) and width -= (font.spaceWidth() + font.wordSpacing()) could produce a negative width value.

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::InlineItemRun::removeTrailingLetterSpacing):

  • layout/inlineformatting/text/TextUtil.cpp:

(WebCore::Layout::TextUtil::width):
(WebCore::Layout::TextUtil::fixedPitchWidth):

6:49 AM Changeset in webkit [253038] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

[LFC][IFC] Try to fit content on the current line when the line has trimmable trailing content
https://bugs.webkit.org/show_bug.cgi?id=204781
<rdar://problem/57580138>

Reviewed by Antti Koivisto.

Let's expand the available space when the line has trailing trimmable whitespace and we try to fit some empty inline containers.
"text content <span style="padding: 1px"></span>" <- the <span></span> runs should fit after trimming the trailing whitespace.

  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::breakingContextForInlineContent):
(WebCore::Layout::LineBreaker::Content::hasNonContentRunsOnly const):

  • layout/inlineformatting/InlineLineBreaker.h:
  • layout/inlineformatting/LineLayoutContext.cpp:

(WebCore::Layout::LineLayoutContext::processUncommittedContent):

6:45 AM Changeset in webkit [253037] by youenn@apple.com
  • 6 edits in trunk

Expose WKWebView API to stop ongoing capture
https://bugs.webkit.org/show_bug.cgi?id=204787

Reviewed by Eric Carlson.

Source/WebKit:

Covered by API test.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _stopMediaCapture]):

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:

Tools:

  • TestWebKitAPI/Tests/WebKit/GetUserMedia.mm:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKit/getUserMedia.html:
5:37 AM Changeset in webkit [253036] by calvaris@igalia.com
  • 2 edits in trunk/Source/WebCore

Unreviewed, fix build warning.

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:

durationMediaTime should be marked as override.

4:32 AM Changeset in webkit [253035] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[WPE] Some WebGL 1.0.3 conformance tests are marked as failing but have been consistently passing
https://bugs.webkit.org/show_bug.cgi?id=204790

Patch by Chris Lord <Chris Lord> on 2019-12-03
Reviewed by Alejandro G. Castro.

  • platform/wpe/TestExpectations:
3:25 AM Changeset in webkit [253034] by Fujii Hironori
  • 4 edits in trunk

Unreviewed, rolling out r253020.

It breaks WinCairo bots.

Reverted changeset:

"[MSVC] Add /experimental:newLambdaProcessor switch for better
C++ conformance"
https://bugs.webkit.org/show_bug.cgi?id=204443
https://trac.webkit.org/changeset/253020

3:11 AM Changeset in webkit [253033] by youenn@apple.com
  • 19 edits in trunk

[Cocoa] Run camera capture in UIProcess by default in layout tests
https://bugs.webkit.org/show_bug.cgi?id=204512

Reviewed by Eric Carlson.

Source/WebCore:

Remove no longer useful internals API once we are moving capture to UIProcess.

  • platform/mediastream/RealtimeMediaSourceFactory.h:
  • testing/Internals.cpp:

(WebCore::Internals::Internals):

  • testing/Internals.h:
  • testing/Internals.idl:

Source/WebKit:

  • UIProcess/UserMediaProcessManager.cpp:

(WebKit::UserMediaProcessManager::willCreateMediaStream):
Do not send sandbox extensions in case capture happens in UIProcess.

  • WebProcess/cocoa/UserMediaCaptureManager.cpp:

(WebKit::UserMediaCaptureManager::Source::~Source):
(WebKit::UserMediaCaptureManager::createCaptureSource):
Register/unregister sources as active/unactive sources to the factory.

Tools:

By defaut, enable capture in UIProcess on Cocoa side.

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetPreferencesToConsistentValues):
(WTR::updateTestOptionsFromTestHeader):

  • WebKitTestRunner/TestOptions.h:

(WTR::TestOptions::hasSameInitializationOptions const):

LayoutTests:

Update tests to remove use of the removed internals API and disable
camera capture in UIProcess for two tests that exihibit shortcomings of our current UIProcess camera capture support.

  • fast/mediastream/constraint-intrinsic-size.html:
  • fast/mediastream/media-stream-page-muted.html:
  • fast/mediastream/mediastreamtrack-video-clone.html:
  • fast/mediastream/mock-media-source-expected.txt:
  • fast/mediastream/mock-media-source.html:
  • fast/mediastream/overconstrainederror-constraint.html:
  • webrtc/video-rotation.html:
2:51 AM Changeset in webkit [253032] by Antti Koivisto
  • 13 edits
    2 moves
    7 adds in trunk

[LFC][Integration] Setup root box properties
https://bugs.webkit.org/show_bug.cgi?id=204743

Reviewed by Zalan Bujtas.

Source/WebCore:

Test: fast/layoutformattingcontext/flow-integration-basic.html

Line layout needs to know about flow borders and padding so that boxes are offset correctly.

  • CMakeLists.txt:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/LayoutContext.cpp:

(WebCore::Layout::LayoutContext::layout):
(WebCore::Layout::LayoutContext::layoutWithPreparedRootGeometry):

Split setup and layout into separate functions.

  • layout/LayoutContext.h:
  • layout/LayoutState.cpp:

(WebCore::Layout::LayoutState::displayBoxForLayoutRoot):

  • layout/LayoutState.h:
  • layout/displaytree/DisplayPainter.cpp:

(WebCore::Display::paintInlineContent):
(WebCore::Display::Painter::paint):
(WebCore::Display::Painter::paintInlineFlow):

Avoid accessing tree root box properties when painting (since margins are not set up).

  • layout/integration/RenderBlockFlowLineLayout.cpp: Renamed from Source/WebCore/layout/RenderBlockFlowLineLayout.cpp.

Moved to integration subdirectory.

(WebCore::Layout::RenderBlockFlowLineLayout::layout):

Drop the content size paramater, the caller is responsible of setting up the root display box.

(WebCore::Layout::RenderBlockFlowLineLayout::prepareRootDisplayBoxForLayout):

Setup padding and borders.

(WebCore::Layout::RenderBlockFlowLineLayout::displayInlineContent const):
(WebCore::Layout::RenderBlockFlowLineLayout::rootLayoutBox const):

  • layout/integration/RenderBlockFlowLineLayout.h: Renamed from Source/WebCore/layout/RenderBlockFlowLineLayout.h.

(WebCore::Layout::RenderBlockFlowLineLayout::contentLogicalHeight const):

Use a member to pass content height.

  • layout/layouttree/LayoutTreeBuilder.h:

(WebCore::Layout::LayoutTreeContent::layoutBoxForRenderer const):

  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::layoutLFCLines):

LayoutTests:

  • fast/layoutformattingcontext/flow-integration-basic.html: Added.
  • platform/mac/fast/layoutformattingcontext/flow-integration-basic-expected.txt: Added.
2:30 AM Changeset in webkit [253031] by commit-queue@webkit.org
  • 13 edits in trunk

Implement createImageBitmap(OffscreenCanvas)
https://bugs.webkit.org/show_bug.cgi?id=183440

Patch by Zan Dobersek <zdobersek@igalia.com> on 2019-12-03
Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

  • web-platform-tests/2dcontext/imagebitmap/createImageBitmap-drawImage-expected.txt:
  • web-platform-tests/2dcontext/imagebitmap/createImageBitmap-serializable-expected.txt:
  • web-platform-tests/2dcontext/imagebitmap/createImageBitmap-transfer-expected.txt:
  • web-platform-tests/offscreen-canvas/convert-to-blob/offscreencanvas.convert.to.blob.w-expected.txt:
  • web-platform-tests/offscreen-canvas/the-offscreen-canvas/offscreencanvas.transfer.to.imagebitmap.w-expected.txt:

Source/WebCore:

No new tests. Covered by existing tests.

  • html/ImageBitmap.cpp:

(WebCore::ImageBitmap::createPromise):

  • html/ImageBitmap.h:
  • page/WindowOrWorkerGlobalScope.idl:

LayoutTests:

  • platform/wpe/imported/w3c/web-platform-tests/2dcontext/imagebitmap/createImageBitmap-invalid-args-expected.txt:
2:03 AM Changeset in webkit [253030] by Carlos Garcia Campos
  • 16 edits in trunk

WebDriver: handle elements of type file in send keys command
https://bugs.webkit.org/show_bug.cgi?id=188514

Reviewed by Brian Burg.

Source/WebCore:

Export symbols now used by WebKit::WebAutomationSessionProxy.

  • html/HTMLInputElement.h:

Source/WebDriver:

Handle the case of inpout element being a file upload in send keys command.

  • Capabilities.h: Add strictFileInteractability.
  • Session.cpp:

(WebDriver::Session::elementIsFileUpload): Helper to check if the given element is a file upload and whether
it's multiple or not.
(WebDriver::Session::parseElementIsFileUploadResult): Parse the result of elementIsFileUpload().
(WebDriver::Session::elementClick): If the element is a file upload, fail with invalid argument error.
(WebDriver::Session::setInputFileUploadFiles): Send setFilesForInputFileUpload message to the browser with the
selected files.
(WebDriver::Session::elementSendKeys): If the element is a file upload, call setInputFileUploadFiles()
instead. Also handle the strictFileInteractability capability to decide whether to focus and check
interactability on the input element or not.

  • Session.h:
  • WebDriverService.cpp:

(WebDriver::WebDriverService::parseCapabilities const): Handle strictFileInteractability.
(WebDriver::WebDriverService::validatedCapabilities const): Ditto.
(WebDriver::WebDriverService::matchCapabilities const): Ditto.
(WebDriver::WebDriverService::createSession): Ditto.

Source/WebKit:

Add setFilesForInputFileUpload method to Automation. It's like setFilesToSelectForFileUpload, but it works
differently, so I'm keeping both to not break safaridriver. The new one simply sends the file list to the web
process to be set on the input element, instead of saving the file list, wait for the driver to trigger the open
panel, intercept and complete the open panel request and send a dismiss open panel event to the driver.

  • UIProcess/Automation/Automation.json: Add setFilesForInputFileUpload.
  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::setFilesForInputFileUpload): Send SetFilesForInputFileUpload message to the web process.

  • UIProcess/Automation/WebAutomationSession.h:
  • WebProcess/Automation/WebAutomationSessionProxy.cpp:

(WebKit::WebAutomationSessionProxy::setFilesForInputFileUpload): Create a FileList with the received paths and
call HTMLInputElement::setFiles() on the given element.

  • WebProcess/Automation/WebAutomationSessionProxy.h:
  • WebProcess/Automation/WebAutomationSessionProxy.messages.in: Add SetFilesForInputFileUpload message.

WebDriverTests:

Remove expectations for tests that are now passing.

1:32 AM Changeset in webkit [253029] by Carlos Garcia Campos
  • 7 edits in trunk

WebDriver: most of the clear tests are failing
https://bugs.webkit.org/show_bug.cgi?id=180404

Reviewed by Brian Burg.

Source/WebDriver:

Implement the element clear command following the spec.
https://w3c.github.io/webdriver/#element-clear

  • Session.cpp:

(WebDriver::Session::elementIsEditable): Helper function to check if the element is editable.
(WebDriver::Session::elementClear): Check if the element is editable and interactable before executing the clear atom.

  • Session.h:

Source/WebKit:

Update the FormElementClear atom to follow the spec.

  • UIProcess/Automation/atoms/FormElementClear.js:

(isEditable):
(isResettableElementEmpty):

WebDriverTests:

Remove expectations for tests that are now passing.

1:30 AM Changeset in webkit [253028] by Carlos Garcia Campos
  • 20 edits in trunk/Source

[PSON] Tooltips from previous page shown on new page
https://bugs.webkit.org/show_bug.cgi?id=204735

Reviewed by Chris Dumez.

Source/WebCore:

Remove Chrome::setToolTip() that is always called after Chrome::mouseDidMoveOverElement() and add the
tooltip text and direction as parameters of Chrome::mouseDidMoveOverElement().

  • loader/EmptyClients.h:
  • page/Chrome.cpp:

(WebCore::Chrome::mouseDidMoveOverElement):
(WebCore::Chrome::getToolTip):

  • page/Chrome.h:
  • page/ChromeClient.h:
  • page/EventHandler.cpp:

(WebCore::EventHandler::mouseMoved):

Source/WebKit:

The problem is that WebPage (in the web process) is caching the tooltip text to avoid sending IPC messages when
the tooltip didn't change. When a new web process is used for the same web view, the tooltip text doesn't really
change (it's always null) until a new one is set. The setToolTip message is always sent right after the
MouseDidMoveOverElement, and they both depend on the same hit test result, so we can include the tooltip text as
part of the WebHitTestResultData struct passed to MouseDidMoveOverElement and remove the SetToolTip
message. Since the UI process is already caching the tooltip, we can simply notify the page client when it changes.

  • Shared/WebHitTestResultData.cpp:

(WebKit::WebHitTestResultData::WebHitTestResultData): Initialize toolTipText.
(WebKit::WebHitTestResultData::encode const): Encode toolTipText.
(WebKit::WebHitTestResultData::decode): Decode toolTipText.

  • Shared/WebHitTestResultData.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::mouseDidMoveOverElement): Call setToolTip() after notifying the UI client about the mouse move.
(WebKit::WebPageProxy::setToolTip): Return early if tooltip didn't change.
(WebKit::WebPageProxy::resetState): Use setToolTip() to ensure the page client is notified about the change.

  • UIProcess/WebPageProxy.messages.in: Remove SetToolTip message.
  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::mouseDidMoveOverElement): Pass tooltip text to WebHitTestResultData constructor.

  • WebProcess/WebCoreSupport/WebChromeClient.h:

Source/WebKitLegacy/mac:

Update to the new ChromeClient API.

  • WebCoreSupport/WebChromeClient.h:
  • WebCoreSupport/WebChromeClient.mm:

(WebChromeClient::mouseDidMoveOverElement):
(WebChromeClient::setToolTip):

Source/WebKitLegacy/win:

Update to the new ChromeClient API.

  • WebCoreSupport/WebChromeClient.cpp:

(WebChromeClient::mouseDidMoveOverElement):

  • WebCoreSupport/WebChromeClient.h:
1:28 AM Changeset in webkit [253027] by Carlos Garcia Campos
  • 2 edits in trunk/Tools

Unreviewed. Focus the location bar on CTRL+l in GTK MiniBrowser

  • MiniBrowser/gtk/BrowserWindow.c:

(focusLocationBar):
(browser_window_init):

Note: See TracTimeline for information about the timeline view.