⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Apr 20, 2021:

11:58 PM Changeset in webkit [276346] by Paulo Matos
  • 3 edits in trunk/JSTests

Unskip couple of tests for armv7l and mips
https://bugs.webkit.org/show_bug.cgi?id=224607

Unreviewed gardening.

  • stress/check-stack-overflow-before-value-profiling-arguments.js:

(fullGC):

  • stress/intl-suppored-locales-of.js:
10:47 PM Changeset in webkit [276345] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebKit

Connection::m_mainThread is unused
https://bugs.webkit.org/show_bug.cgi?id=224806

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-04-20
Reviewed by Darin Adler.

Remove unused Connection::m_mainThread.

  • Platform/IPC/Connection.cpp:

(IPC::Connection::Connection):

  • Platform/IPC/Connection.h:
9:58 PM Changeset in webkit [276344] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Crash in CompositeEditCommand::insertNodeAt
https://bugs.webkit.org/show_bug.cgi?id=224504

Patch by Ian Gilbert <iang@apple.com> on 2021-04-20
Reviewed by Ryosuke Niwa.

Source/WebCore:

CompositeEditCommand::cleanupAfterDeletion will remove text nodes that only
have a newline. Added check inside FormatBlockCommand::formatRange to avoid
a null pointer dereference on a removed node.

Test: editing/execCommand/format-block-remove-text-node-crash.html

  • editing/FormatBlockCommand.cpp:

(WebCore::FormatBlockCommand::formatRange):

LayoutTests:

Adding a regression test case.

  • editing/execCommand/format-block-remove-text-node-crash-expected.txt: Added.
  • editing/execCommand/format-block-remove-text-node-crash.html: Added.
7:38 PM Changeset in webkit [276343] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

Static asserts in WasmAirIRGenerator.cpp and WasmB3IRGenerator.cpp trigger -Wnonnull warnings with GCC 11
https://bugs.webkit.org/show_bug.cgi?id=224826

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-04-20
Reviewed by Yusuke Suzuki.

Rewrite these static asserts to avoid warnings when built with GCC 11. Credit to Jonathan
Wakely for providing this mind-bending solution.

  • wasm/WasmAirIRGenerator.cpp:

(JSC::Wasm::AirIRGenerator::restoreWebAssemblyGlobalState):
(JSC::Wasm::AirIRGenerator::addCurrentMemory):

  • wasm/WasmB3IRGenerator.cpp:

(JSC::Wasm::B3IRGenerator::addCurrentMemory):

6:42 PM Changeset in webkit [276342] by basuke.suzuki@sony.com
  • 2 edits in trunk/Source/WebCore

[clang] Remove implicit cast related warnings.
https://bugs.webkit.org/show_bug.cgi?id=224797

Reviewed by Darin Adler.

Added explicit cast to suppress warning.
Behavior is not changed from implicit cast.

No new tests because there's no behavior change.

  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::adjustLinePositionForPagination):

6:20 PM Changeset in webkit [276341] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Crash due to VectorBuffer pre-allocation failure
https://bugs.webkit.org/show_bug.cgi?id=224840

Patch by Ian Gilbert <iang@apple.com> on 2021-04-20
Reviewed by Sam Weinig.

Source/WebKit:

Vector decoder could attempt to allocate a large buffer and on failure would crash.
Changed decode to avoid allocating a Vector based on the decoded size.

Test: ipc/large-vector-allocate-failure-crash.html

  • Shared/Cocoa/WebCoreArgumentCodersCocoa.mm:

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

LayoutTests:

Added a regression test.

  • ipc/large-vector-allocate-failure-crash-expected.txt: Added.
  • ipc/large-vector-allocate-failure-crash.html: Added.
6:05 PM Changeset in webkit [276340] by Brent Fulgham
  • 6 edits in trunk/Source

[Cocoa] Prevent GPU and WebContent processes from attempting to connect to the AppSSO service
https://bugs.webkit.org/show_bug.cgi?id=224834
<rdar://problem/72157514>

Reviewed by Jiewen Tan.

Source/WebCore:

Call version of '_protocolClassForRequest' that tells CFNetwork to ignore AppSSO flows
when building for a platform that supports it.

  • platform/mac/WebCoreNSURLExtras.mm:

(WebCore::URLByCanonicalizingURL):

Source/WebCore/PAL:

  • pal/spi/cf/CFNetworkSPI.h: Add declaration for 'skipAppSSO' version of NSURLProtocol method.

Source/WTF:

  • wtf/PlatformHave.h:
5:58 PM Changeset in webkit [276339] by Chris Dumez
  • 3 edits in trunk/Source/WebKit

If an idle GPUProcess doesn't exit under memory pressure because it just launched, check again later
https://bugs.webkit.org/show_bug.cgi?id=224829

Reviewed by Darin Adler.

In r276305, I made it so that the GPUProcess does not exit under memory pressure when idle
if it launched less than 5 seconds ago. This gives the WebProcess time to schedule work with
the GPUProcess after launching it and makes sure we don't repeatedly / frequently exit &
relaunch the GPUProcess.

In this patch, I am tweaking the policy so that if we could have exited but didn't because
the GPUProcess was too young (less than 5 seconds old), then I schedule a timer for this
5 second deadline to check again if the GPUProcess could exit (meaning that it is unused).
When the timer fires, the process doesn't have to be under memory pressure still in order
to exit, it just needs to be idle. I figured the fact that we were under memory pressure
less than 5 seconds ago should be enough incentive to exit if idle.

  • GPUProcess/GPUProcess.cpp:

(WebKit::GPUProcess::GPUProcess):
(WebKit::GPUProcess::canExitUnderMemoryPressure const):

  • GPUProcess/GPUProcess.h:
5:48 PM Changeset in webkit [276338] by eric.carlson@apple.com
  • 2 edits in trunk/Source/WTF

[Cocoa] Enable MediaSession and MediaSessionCoordinator experimental features
https://bugs.webkit.org/show_bug.cgi?id=224822
<rdar://problem/76908014>

Reviewed by Jer Noble.

  • Scripts/Preferences/WebPreferencesExperimental.yaml: Change the defaults for

MediaSessionCoordinatorEnabled and MediaSessionEnabled to true.

5:46 PM Changeset in webkit [276337] by Robert Jenner
  • 2 edits in trunk/LayoutTests

[ BigSur wk2 Debug arm64 ] http/wpt/preload/change-link-rel-attribute.html is a flakey crash
https://bugs.webkit.org/show_bug.cgi?id=224845

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations: Updted test expectations to Pass Crash while test is reviewed.
5:41 PM Changeset in webkit [276336] by eric.carlson@apple.com
  • 4 edits in trunk/LayoutTests

[BigSur Wk1] media/video-ended-event-negative-playback.html is flaky text failure
https://bugs.webkit.org/show_bug.cgi?id=221106
<rdar://problem/73724911>

Reviewed by Jer Noble.

Seeking to 0.5 and playing backwards to the beginning of the file may take longer
than 2500ms, so increase the timeout to 5000ms and don't start the failure timer
until playback begins.

  • media/video-ended-event-negative-playback-expected.txt:
  • media/video-ended-event-negative-playback.html:
  • platform/mac-wk1/TestExpectations:
5:37 PM BuildingCairoOnWindows edited by Fujii Hironori
(diff)
5:22 PM Changeset in webkit [276335] by Alan Coon
  • 2 edits in branches/safari-612.1.11-branch/Source/ThirdParty/ANGLE

Cherry-pick r276286. rdar://problem/76641662

Build ANGLE dylib into WK_OVERRIDE_FRAMEWORKS_DIR in builds that use it
https://bugs.webkit.org/show_bug.cgi?id=224785
<rdar://76641662>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-04-19
Reviewed by Alexey Proskuryakov.

  • Configurations/ANGLE-dynamic.xcconfig:

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

5:20 PM Changeset in webkit [276334] by Alan Coon
  • 8 edits in branches/safari-612.1.11-branch/Source

Versioning.

WebKit-7612.1.11.2

5:14 PM Changeset in webkit [276333] by Devin Rousso
  • 21 edits
    1 move in trunk

Parse theme_color in web application manifests and pass it along to -[WKWebView themeColor]
https://bugs.webkit.org/show_bug.cgi?id=224796

Reviewed by Darin Adler.

Source/WebCore:

  • Modules/applicationmanifest/ApplicationManifest.h:

(WebCore::ApplicationManifest::encode const):
(WebCore::ApplicationManifest::decode):

  • Modules/applicationmanifest/ApplicationManifestParser.h:
  • Modules/applicationmanifest/ApplicationManifestParser.cpp:

(WebCore::ApplicationManifestParser::parse):
(WebCore::ApplicationManifestParser::ApplicationManifestParser):
(WebCore::ApplicationManifestParser::parseManifest):
(WebCore::ApplicationManifestParser::logDeveloperWarning):
(WebCore::ApplicationManifestParser::parseColor): Added.

  • loader/cache/CachedApplicationManifest.h:
  • loader/cache/CachedApplicationManifest.cpp:

(WebCore::CachedApplicationManifest::process):
Pass an actual Document instead of a ScriptExecutionContext so that we can notify it
when finished parsing the JSON (Document::processApplicationManifest).

  • dom/Document.h:

(WebCore::Document::themeColor const):

  • dom/Document.cpp:

(WebCore::Document::processMetaElementThemeColor): Added.
(WebCore::Document::themeColorChanged): Added.
(WebCore::Document::processApplicationManifest): Added.
(WebCore::Document::processThemeColor): Deleted.
Use the theme color from <meta name="theme-color"> if valid, falling back to the theme
color from "theme_color" in the web application manifest (if specified). Only notify the
UIProcess of changes to <meta name="theme-color"> or the "theme_color" in the web
application manifest if the new value is the value that would be used.

  • html/HTMLMetaElement.cpp:

(WebCore::HTMLMetaElement::attributeChanged):
(WebCore::HTMLMetaElement::removedFromAncestor):
(WebCore::HTMLMetaElement::process):

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::rootBackgroundColorOrTransparencyChanged):
Drive-by: Rename Document::processThemeColor to Document::processMetaElementThemeColor
so that it's more specific to <meta name="theme-color">.

  • page/ChromeClient.h:

(WebCore::ChromeClient::themeColorChanged const):
(WebCore::ChromeClient::pageExtendedBackgroundColorDidChange const):
Drive-by: Remove the Color parameter since it's not actually used in the WebProcess.

Source/WebKit:

  • UIProcess/API/Cocoa/_WKApplicationManifest.h:
  • UIProcess/API/Cocoa/_WKApplicationManifest.mm:

(-[_WKApplicationManifest initWithCoder:]):
(-[_WKApplicationManifest encodeWithCoder:]):
(-[_WKApplicationManifest themeColor]): Added.

  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::themeColorChanged const):
(WebKit::WebChromeClient::pageExtendedBackgroundColorDidChange const):
Drive-by: Remove the Color parameter since it's not actually used in the WebProcess.

Tools:

  • TestWebKitAPI/Tests/WebCore/ApplicationManifestParser.cpp:

(ApplicationManifestParserTest::testThemeColor): Added.
(TEST_F.ApplicationManifestParserTest.ThemeColor): Added.

  • TestWebKitAPI/Tests/WebKitCocoa/ApplicationManifest.mm:

(TEST.ApplicationManifestBasic):
(TEST.ApplicationManifestCoding):

  • TestWebKitAPI/Tests/WebKitCocoa/WKWebViewThemeColor.mm: Renamed from Tools/TestWebKitAPI/Tests/WebKitCocoa/HTMLMetaThemeColor.mm.

(TEST.WKWebViewThemeColor.ApplicationManifest):
(TEST.WKWebViewThemeColor.MetaElementOverridesApplicationManifest):
Rename this file now that it also deals with web application manifest (in addition to <meta name="theme-color">).

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
5:08 PM Changeset in webkit [276332] by commit-queue@webkit.org
  • 9 edits in trunk/Source

Lots of spurious -Wnonnull warnings with GCC 11
https://bugs.webkit.org/show_bug.cgi?id=224452

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-04-20
Reviewed by Darin Adler.

Source/WebCore:

  • css/CSSValue.h:

(WebCore::CSSValue::deref):

  • css/StyleRule.h:

(WebCore::StyleRuleBase::deref const):

  • dom/Node.h:

(WebCore::Node::deref const):

Source/WebKit:

  • WebProcess/Plugins/PluginView.cpp:

Source/WTF:

  • wtf/RefPtr.h:

(WTF::DefaultRefDerefTraits::derefIfNotNull):

5:03 PM Changeset in webkit [276331] by Wenson Hsieh
  • 35 edits
    2 moves in trunk/Source

Rename WebCore::SelectionRect to WebCore::SelectionGeometry
https://bugs.webkit.org/show_bug.cgi?id=224820

Reviewed by Megan Gardner.

Source/WebCore:

To prepare for rendering non-rectilinear selection quads on iOS using UIKit, rename WebCore::SelectionRect to
WebCore::SelectionGeometry. In a subsequent patch, this class will be backed by a FloatQuad instead of an
IntRect, and will additionally contain a flag indicating whether it should render using the bounding rect of
the quad (and should additionally be coalesced with surrounding selection rects), or if it should render the
selection quad without coalescing.

No change in behavior.

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:

(-[WebAccessibilityObjectWrapper textRectsFromMarkers:withText:]):

  • page/DragController.cpp:
  • page/TextIndicator.cpp:

(WebCore::initializeIndicator):

  • platform/ios/SelectionGeometry.cpp: Renamed from Source/WebCore/platform/ios/SelectionRect.cpp.

(WebCore::SelectionGeometry::SelectionGeometry):
(WebCore::SelectionGeometry::setLogicalLeft):
(WebCore::SelectionGeometry::setLogicalWidth):
(WebCore::SelectionGeometry::setLogicalTop):
(WebCore::SelectionGeometry::setLogicalHeight):
(WebCore::operator<<):

  • platform/ios/SelectionGeometry.h: Renamed from Source/WebCore/platform/ios/SelectionRect.h.

(WebCore::SelectionGeometry::rect const):
(WebCore::SelectionGeometry::logicalLeft const):
(WebCore::SelectionGeometry::logicalWidth const):
(WebCore::SelectionGeometry::logicalTop const):
(WebCore::SelectionGeometry::logicalHeight const):
(WebCore::SelectionGeometry::direction const):
(WebCore::SelectionGeometry::minX const):
(WebCore::SelectionGeometry::maxX const):
(WebCore::SelectionGeometry::maxY const):
(WebCore::SelectionGeometry::lineNumber const):
(WebCore::SelectionGeometry::isLineBreak const):
(WebCore::SelectionGeometry::isFirstOnLine const):
(WebCore::SelectionGeometry::isLastOnLine const):
(WebCore::SelectionGeometry::containsStart const):
(WebCore::SelectionGeometry::containsEnd const):
(WebCore::SelectionGeometry::isHorizontal const):
(WebCore::SelectionGeometry::isInFixedPosition const):
(WebCore::SelectionGeometry::isRubyText const):
(WebCore::SelectionGeometry::pageNumber const):
(WebCore::SelectionGeometry::setRect):
(WebCore::SelectionGeometry::setDirection):
(WebCore::SelectionGeometry::setMinX):
(WebCore::SelectionGeometry::setMaxX):
(WebCore::SelectionGeometry::setMaxY):
(WebCore::SelectionGeometry::setLineNumber):
(WebCore::SelectionGeometry::setIsLineBreak):
(WebCore::SelectionGeometry::setIsFirstOnLine):
(WebCore::SelectionGeometry::setIsLastOnLine):
(WebCore::SelectionGeometry::setContainsStart):
(WebCore::SelectionGeometry::setContainsEnd):
(WebCore::SelectionGeometry::setIsHorizontal):

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::collectSelectionGeometries):
(WebCore::RenderImage::collectSelectionRects): Deleted.

  • rendering/RenderImage.h:
  • rendering/RenderLineBreak.cpp:

(WebCore::RenderLineBreak::collectSelectionGeometries):
(WebCore::RenderLineBreak::collectSelectionRects): Deleted.

  • rendering/RenderLineBreak.h:
  • rendering/RenderObject.cpp:

(WebCore::RenderObject::collectSelectionGeometries):
(WebCore::adjustLineHeightOfSelectionGeometries):
(WebCore::coalesceSelectionGeometries):
(WebCore::RenderObject::collectSelectionGeometriesWithoutUnionInteriorLines):
(WebCore::RenderObject::collectSelectionGeometriesInternal):
(WebCore::RenderObject::collectSelectionRects): Deleted.
(WebCore::adjustLineHeightOfSelectionRects): Deleted.
(WebCore::coalesceSelectionRects): Deleted.
(WebCore::RenderObject::collectSelectionRectsWithoutUnionInteriorLines): Deleted.
(WebCore::RenderObject::collectSelectionRectsInternal): Deleted.

  • rendering/RenderObject.h:
  • rendering/RenderSelectionInfo.cpp:

(WebCore::RenderSelectionInfo::RenderSelectionInfo):

  • rendering/RenderText.cpp:

(WebCore::RenderText::collectSelectionGeometries):
(WebCore::RenderText::collectSelectionGeometriesForLineBoxes):
(WebCore::RenderText::selectionRectForRepaint):
(WebCore::RenderText::collectSelectionRects): Deleted.
(WebCore::RenderText::collectSelectionRectsForLineBoxes): Deleted.

  • rendering/RenderText.h:

Source/WebKit:

See WebCore/ChangeLog for more details.

  • Scripts/webkit/messages.py:

(headers_for_type):

  • Shared/EditorState.cpp:

(WebKit::EditorState::PostLayoutData::encode const):
(WebKit::EditorState::PostLayoutData::decode):
(WebKit::operator<<):

  • Shared/EditorState.h:
  • Shared/WebCoreArgumentCoders.cpp:

(IPC::ArgumentCoder<SelectionGeometry>::encode):
(IPC::ArgumentCoder<SelectionGeometry>::decode):
(IPC::ArgumentCoder<SelectionRect>::encode): Deleted.
(IPC::ArgumentCoder<SelectionRect>::decode): Deleted.

  • Shared/WebCoreArgumentCoders.h:
  • Shared/ios/InteractionInformationAtPosition.h:
  • Shared/ios/InteractionInformationRequest.h:
  • UIProcess/API/ios/WKWebViewIOS.mm:

(-[WKWebView _accessibilityRetrieveRectsAtSelectionOffset:withText:completionHandler:]):

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

(WebKit::WKSelectionDrawingInfo::WKSelectionDrawingInfo):
(WebKit::operator==):
(WebKit::operator<<):
(-[WKContentView _pointIsInsideSelectionRect:outBoundingRect:]):
(-[WKContentView _shouldToggleSelectionCommandsAfterTapAt:]):
(-[WKContentView webSelectionRectsForSelectionGeometries:]):
(-[WKContentView webSelectionRects]):
(-[WKContentView _lookupForWebView:]):
(-[WKContentView _shareForWebView:]):
(-[WKContentView _translateForWebView:]):
(-[WKContentView _addShortcutForWebView:]):
(-[WKContentView _showDictionary:]):
(-[WKContentView _accessibilityRetrieveRectsEnclosingSelectionOffset:withGranularity:]):
(-[WKContentView _accessibilityRetrieveRectsAtSelectionOffset:withText:completionHandler:]):
(-[WKContentView selectedTextRange]):
(-[WKContentView webSelectionRectsForSelectionRects:]): Deleted.

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

(-[WKTextSelectionRect initWithCGRect:]):
(-[WKTextSelectionRect initWithSelectionGeometry:]):
(-[WKTextSelectionRect rect]):
(-[WKTextSelectionRect writingDirection]):
(-[WKTextSelectionRect containsStart]):
(-[WKTextSelectionRect containsEnd]):
(-[WKTextSelectionRect isVertical]):
(-[WKTextSelectionRect initWithSelectionRect:]): Deleted.

  • UIProcess/ios/WebPageProxyIOS.mm:

(WebKit::WebPageProxy::requestRectsForGranularityWithSelectionOffset):
(WebKit::WebPageProxy::requestRectsAtSelectionOffsetWithText):
(WebKit::WebPageProxy::selectionBoundingRectInRootViewCoordinates const):

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

(WebKit::convertContentToRootView):
(WebKit::WebPage::getPlatformEditorState const):
(WebKit::WebPage::getRectsForGranularityWithSelectionOffset):
(WebKit::WebPage::getRectsAtSelectionOffsetWithText):
(WebKit::WebPage::requestAutocorrectionData):
(WebKit::convertContentToRootViewSelectionRects): Deleted.

Source/WebKitLegacy/ios:

  • WebCoreSupport/WebFrameIOS.mm:

(-[WebFrame selectionRectsForCoreRange:]):

4:58 PM Changeset in webkit [276330] by Robert Jenner
  • 2 edits in trunk/LayoutTests

[ BigSur Debug ] http/tests/security/webaudio-render-remote-audio-blocked-no-crossorigin.html is a flakey timeout
https://bugs.webkit.org/show_bug.cgi?id=224842

Unreviewed test gardening.

  • platform/mac/TestExpectations: Updated test expectations to Pass Timeout while test is reviewed.
4:57 PM Changeset in webkit [276329] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

-Warray-bounds warning in AirAllocateRegistersByGraphColoring.cpp with GCC 11
https://bugs.webkit.org/show_bug.cgi?id=224782

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-04-20
Reviewed by Darin Adler.

These warnings don't make any sense to me. Suppress them.

  • b3/air/AirAllocateRegistersByGraphColoring.cpp:
4:44 PM Changeset in webkit [276328] by timothy_horton@apple.com
  • 5 edits
    1 add in trunk/Tools

MacCatalyst tests crash on NSInternalInconsistencyException, reason: NSApplication has not been created yet
https://bugs.webkit.org/show_bug.cgi?id=224606

Reviewed by Wenson Hsieh.

  • TestWebKitAPI/Configurations/TestWebKitAPI.xcconfig:

Link UIKitMacHelper in macCatalyst builds.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/ios/UIKitMacHelperSPI.h: Added.
  • TestWebKitAPI/ios/mainIOS.mm:

(main):
Call UINSApplicationInstantiate to keep the tests limping along until we create an actual UIApp.

  • TestWebKitAPI/Configurations/TestWTF.xcconfig:

Also, fix the TestWTF configuration to not link Cocoa in macCatalyst builds.

4:21 PM Changeset in webkit [276327] by weinig@apple.com
  • 19 edits
    1 copy
    1 add in trunk

Separated models don't get opacity set on them at all
https://bugs.webkit.org/show_bug.cgi?id=224763

Reviewed by Tim Horton.

Source/WebCore:

Test: model-element/model-element-graphics-layers-opacity.html

This certainly won't be the way things land once separated/optimized
layer semantics are better understood, but for now, it is useful to
explicitly propogate the opacity of the owing layer to the content
layer if the content layer is a model layer. In the future, we may want
to do this for any separated child (and conversely, only to the content
layer if it is separated), but this will allow us to play a bit futher
in our experimentation.

Also adds support for dumping the opacity of a content layer to make
this testable.

  • platform/graphics/GraphicsLayerClient.h:
  • platform/graphics/ca/GraphicsLayerCA.cpp:

(WebCore::GraphicsLayerCA::setContentsToModel):
(WebCore::GraphicsLayerCA::purposeNameForInnerLayer const):
(WebCore::GraphicsLayerCA::dumpInnerLayer const):

  • testing/Internals.cpp:

(WebCore::toPlatformLayerTreeFlags):

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

LayoutTests:

Add new test which use the macOS/iOS only platformLayerTreeAsText
internals function to show that opacity is getting set on the content
layer.

  • model-element/model-element-graphics-layers-opacity-expected.txt: Added.
  • model-element/model-element-graphics-layers-opacity.html: Added.
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
  • platform/win/TestExpectations:
  • compositing/video/video-object-position-expected.txt:
  • compositing/visible-rect/mask-layer-coverage-expected.txt:
  • fullscreen/full-screen-layer-dump-expected.txt:
  • platform/ios/compositing/video/video-object-position-expected.txt:
  • platform/ios/compositing/visible-rect/mask-layer-coverage-expected.txt:
  • platform/mac/compositing/images/direct-image-object-fit-expected.txt:
  • platform/mac/compositing/reflections/direct-image-object-fit-reflected-expected.txt:
  • platform/mac/compositing/video/video-object-fit-expected.txt:

Update results for update content layer type dumping.

4:11 PM Changeset in webkit [276326] by Kate Cheney
  • 12 edits
    4 adds in trunk

Preconnect tasks and preflight checks do not correctly mark app-bound context string
https://bugs.webkit.org/show_bug.cgi?id=224779
<rdar://problem/76738879>

Reviewed by Brent Fulgham.

Source/WebCore:

Tests: http/tests/in-app-browser-privacy/context-string-preconnect.html

http/tests/in-app-browser-privacy/context-string-preflight.html

  • loader/CrossOriginAccessControl.cpp:

(WebCore::createAccessControlPreflightRequest):
CORS preflight case.

Source/WebKit:

We are using request.firstPartyForCookies() to set the app-bound request
context as of https://bugs.webkit.org/show_bug.cgi?id=224311. Some
cases like preconnect tasks and CORS preflight requests don't set this
value because it is not needed for cookie purposes. Since we are now
using it for app-bound requests, and the context is needed for all
network connections, even those that don't send bytes, we should set
the firstPartyForCookies for these cases.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::preconnectTo):
This is the code path for preconnecting to the main resource load, so
we can use the given URL as the first party.

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::preconnectTo):
This is the code path for sub resources. We should use the document
firstPartyForCookies value.

Tools:

We should clear data between tests to avoid flakiness or failures.

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetStateToConsistentValues):
(WTR::TestController::clearAppBoundNavigationData):

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/cocoa/TestControllerCocoa.mm:

(WTR::TestController::clearAppBoundNavigationData):

LayoutTests:

Layout test coverage.

  • http/tests/in-app-browser-privacy/context-string-for-subframe.html:

Drive by fix to create the subframe with JS so we can add a dummy
parameter to avoid caching and causing flakiness. Found this while
testing for flakiness in new tests.

  • http/tests/in-app-browser-privacy/context-string-preconnect-expected.txt: Added.
  • http/tests/in-app-browser-privacy/context-string-preconnect.html: Added.
  • http/tests/in-app-browser-privacy/context-string-preflight-expected.txt: Added.
  • http/tests/in-app-browser-privacy/context-string-preflight.html: Added.

Test an unsuccessful preflight request so a real request doesn't
override the stored context data for testing purposes.

3:45 PM Changeset in webkit [276325] by Aditya Keerthi
  • 9 edits in trunk/Source

[iOS][FCR] Update date/time picker appearance
https://bugs.webkit.org/show_bug.cgi?id=224794
<rdar://problem/76785859>

Reviewed by Wenson Hsieh.

Source/WebCore:

  • en.lproj/Localizable.strings:

Remove now unused string.

  • platform/LocalizedStrings.cpp:
  • platform/LocalizedStrings.h:
  • platform/cocoa/LocalizedStringsCocoa.mm:

(WebCore::formControlDoneButtonTitle):

Moved definition out of PLATFORM(WATCHOS) in LocalizedStrings.cpp and
into LocalizedStringsCocoa, so that the "Done" string can be used by
PLATFORM(IOS_FAMILY).

Source/WebKit:

Date/time pickers should have a system material background and should
avoid obscuring the associated element when possible.

  • Platform/spi/ios/UIKitSPI.h:

Add new SPI declarations to support date/time picker modifications.

  • UIProcess/ios/WKContentViewInteraction.mm:

(createTargetedPreview):
(createFallbackTargetedPreview):
(-[WKContentView _createTargetedContextMenuHintPreviewForFocusedElement]):

Set the UITargetedPreview background color to clearColor when
presenting a date/time picker, so that the presented picker has a
visible material effect. Without this change, the picker would have a
solid white or black background.

  • UIProcess/ios/forms/WKDateTimeInputControl.mm:

(-[WKDateTimePickerViewController initWithDelegate:]):
(-[WKDateTimePickerViewController viewDidLoad]):

Add a system material background to the date picker using
UIVisualEffectView.

(-[WKDateTimePickerViewController datePickerChanged:]):
(-[WKDateTimePickerViewController resetButtonPressed:]):
(-[WKDateTimePickerViewController doneButtonPressed:]):
(-[WKDateTimePickerViewController datePickerInsets]):
(-[WKDateTimePickerViewController preferredDatePickerSize]):
(-[WKDateTimePickerViewController preferredContentSize]):
(-[WKDateTimePickerViewController date]):
(-[WKDateTimePickerViewController setDate:]):
(-[WKDateTimePickerViewController setDatePickerMode:]):
(-[WKDateTimePickerViewController timeZone]):
(-[WKDateTimePickerViewController setTimeZone:]):
(-[WKDateTimePickerViewController calendar]):
(-[WKDateTimePicker initWithView:datePickerMode:]):
(-[WKDateTimePicker _preferredEdgeInsetsForDateTimePicker]):

Attempt to present the date picker in a way that does not obscure the
element.

(-[WKDateTimePicker _contextMenuInteraction:styleForMenuWithConfiguration:]):
(-[WKDateTimePicker contextMenuInteraction:configurationForMenuAtLocation:]):
(-[WKDateTimePicker dateTimePickerViewControllerDidChangeDate:]):
(-[WKDateTimePicker dateTimePickerViewControllerDidPressResetButton:]):
(-[WKDateTimePicker dateTimePickerViewControllerDidPressDoneButton:]):
(-[WKDateTimePicker shouldForceGregorianCalendar]):
(-[WKDateTimePicker dealloc]):
(-[WKDateTimePicker _timeZoneOffsetFromGMT:]):
(-[WKDateTimePicker _sanitizeInputValueForFormatter:]):
(-[WKDateTimePicker dateFormatterForPicker]):
(-[WKDateTimePicker _dateChangedSetAsNumber]):
(-[WKDateTimePicker _dateChangedSetAsString]):
(-[WKDateTimePicker setDateTimePickerToInitialValue]):
(-[WKDateTimePicker controlView]):

Updated this method to return nil, matching other form controls that
do not present a keyboard input view (example: <select>).

(-[WKDateTimePicker controlBeginEditing]):
(-[WKDateTimePicker controlEndEditing]):
(-[WKDateTimePicker calendarType]):
(-[WKDateTimePicker hour]):
(-[WKDateTimePicker minute]):
(-[WKDateTimePicker setHour:minute:]):

3:42 PM Changeset in webkit [276324] by keith_miller@apple.com
  • 13 edits in trunk/Source

FullGCActivityCallback should use the percentage of pages uncompressed in RAM to determine deferral.
https://bugs.webkit.org/show_bug.cgi?id=224817

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

Right now we try to determine if too many pages are paged out by
dereferencing them and bailing out of the GC if we go over a
deadline. While this works if the only goal is to avoid causing
extensive thrashing on spinny disks (HDD), it doesn't prevent
thrashing when access to disk is fast (e.g. SSD). This is because
on fast disks the proportional time to load the memory from disk
is much lower. Additionally, on SSDs in particular we don't want
to load the pages into RAM then bail as that will force a
different page onto disk, increasing wear.

This patch switches to asking the OS if each MarkedBlock is paged
out. Then if we are over a threshold we wait until we would have
GC'd anyway. This patch uses the (maxVMGrowthFactor - 1) as the
percentage of "slow" pages (paged out or compressed) needed to
defer the GC. The idea behind that threshold is that if we add
that many pages then the same number of pages would be forced
out of RAM for us to do a GC anyway (in the limit).

  • heap/BlockDirectory.cpp:

(JSC::BlockDirectory::updatePercentageOfPagedOutPages):
(JSC::BlockDirectory::isPagedOut): Deleted.

  • heap/BlockDirectory.h:
  • heap/FullGCActivityCallback.cpp:

(JSC::FullGCActivityCallback::doCollection):

  • heap/Heap.cpp:

(JSC::Heap::isPagedOut):

  • heap/Heap.h:
  • heap/MarkedSpace.cpp:

(JSC::MarkedSpace::isPagedOut):

  • heap/MarkedSpace.h:
  • runtime/OptionsList.h:

Source/WebKit:

Add mincore to the acceptable syscall list.

  • WebProcess/com.apple.WebProcess.sb.in:

Source/WTF:

Add a noexcept flavor of FunctionTraits. On Linux mincore (and probably other syscalls) are marked noexcept so the existing overloads don't work.

  • wtf/FunctionTraits.h:
3:37 PM Changeset in webkit [276323] by basuke.suzuki@sony.com
  • 2 edits in trunk/Tools

[PlayStation] Remove warnings for unused parameter.
https://bugs.webkit.org/show_bug.cgi?id=224830

Reviewed by Darin Adler.

  • MiniBrowser/playstation/main.cpp:

(main):

3:33 PM Changeset in webkit [276322] by Cameron McCormack
  • 1 edit
    2 adds in trunk/LayoutTests

Add test for line breaking around inline-blocks.
https://bugs.webkit.org/show_bug.cgi?id=224832

Reviewed by Alan Bujtas.

  • fast/css/inline-block-line-break-expected.html: Added.
  • fast/css/inline-block-line-break.html: Added.
3:25 PM Changeset in webkit [276321] by Ruben Turcios
  • 1 copy in tags/Safari-612.1.11.1

Tag Safari-612.1.11.1.

3:13 PM Changeset in webkit [276320] by jiewen_tan@apple.com
  • 2 edits in trunk/Source/WebKit

Platform Key registration does not prompt for user password when in biometric lockout
https://bugs.webkit.org/show_bug.cgi?id=224828
<rdar://76907840>

Reviewed by Brent Fulgham.

Covered by manul tests.

  • UIProcess/WebAuthentication/Cocoa/LocalConnection.mm:

(WebKit::LocalConnection::verifyUser):

3:06 PM Changeset in webkit [276319] by commit-queue@webkit.org
  • 5 edits in trunk

gtest.a exports symbols, causing link-time warning: direct access in function ... means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
https://bugs.webkit.org/show_bug.cgi?id=224812

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-04-20
Reviewed by Alexey Proskuryakov.

Compile and use gtest as a static library that does not export any symbols.
Fixes link-time warnings about mismatch of symbol visibility. The error occurs when
gtest.a is compiled exporting symbols with default visibility, but the clients use the library
and hide the symbols via ld flags.

Source/ThirdParty:

  • gtest/xcode/Config/StaticLibraryTarget.xcconfig:

Compile the static gtest with GTEST_API_=

Tools:

  • TestWebKitAPI/Configurations/TestWTF.xcconfig:
  • TestWebKitAPI/Configurations/TestWebKitAPI.xcconfig:

Compile the gtest clients with GTEST_API_=

2:45 PM Changeset in webkit [276318] by commit-queue@webkit.org
  • 2 edits in trunk/Source/ThirdParty/ANGLE

MacCatalyst ANGLE is linked with @loader_path/../../../libANGLE-shared.dylib
https://bugs.webkit.org/show_bug.cgi?id=224602

Patch by Alex Christensen <achristensen@webkit.org> on 2021-04-20
Reviewed by Alexey Proskuryakov.

  • Configurations/ANGLE-dynamic.xcconfig:
1:21 PM Changeset in webkit [276317] by Fujii Hironori
  • 4 edits in trunk

editing/execCommand/insert-image-in-composed-list.html is crashing
https://bugs.webkit.org/show_bug.cgi?id=224801

Reviewed by Don Olmstead.

Source/WebCore:

This crash were happened for Release builds of GTK port compiled
by GCC and WinCairo port compiled by Clang 12.

As per the comment of Position::containerNode(), it returns null
in some cases.

  • editing/DeleteSelectionCommand.cpp:

(WebCore::DeleteSelectionCommand::removeRedundantBlocks): Added
null checking for the return value of Position::containerNode().

LayoutTests:

  • platform/gtk/TestExpectations: Unmarked it.
1:19 PM WebKitGTK/2.32.x edited by Adrian Perez de Castro
(diff)
1:16 PM Changeset in webkit [276316] by don.olmstead@sony.com
  • 12 edits in trunk

[CMake] Don't use FORWARDING_HEADERS_DIR for JSC GLib headers
https://bugs.webkit.org/show_bug.cgi?id=224821

Reviewed by Michael Catanzaro.

.:

Create CMake variables JavaScriptCoreGLib_FRAMEWORK_HEADERS_DIR and
JavaScriptCoreGLib_DERIVED_SOURCES_DIR to represent where the JavaScriptCore GLib headers
and derived sources will reside. The names and locations set then follow along with the
conventions used for the other frameworks.

  • Source/cmake/OptionsGTK.cmake:
  • Source/cmake/OptionsWPE.cmake:

Source/JavaScriptCore:

Use JavaScriptCoreGLib_FRAMEWORK_HEADERS_DIR and JavaScriptCoreGLib_DERIVED_SOURCES_DIR
for GLib JSC headers instead of FORWARDING_HEADERS_DIR and DERIVED_SOURCES_DIR.

  • GLib.cmake:
  • PlatformGTK.cmake:

Source/WebKit:

Use JavaScriptCoreGLib_FRAMEWORK_HEADERS_DIR and JavaScriptCoreGLib_DERIVED_SOURCES_DIR
for GLib JSC headers instead of FORWARDING_HEADERS_DIR and DERIVED_SOURCES_DIR.

  • PlatformGTK.cmake:

Tools:

Use JavaScriptCoreGLib_FRAMEWORK_HEADERS_DIR and JavaScriptCoreGLib_DERIVED_SOURCES_DIR
for GLib JSC headers instead of FORWARDING_HEADERS_DIR and DERIVED_SOURCES_DIR.

  • MiniBrowser/wpe/CMakeLists.txt:
  • TestWebKitAPI/glib/CMakeLists.txt:
  • TestWebKitAPI/glib/PlatformWPE.cmake:
1:02 PM WebKitGTK/2.32.x edited by Adrian Perez de Castro
(diff)
12:29 PM Changeset in webkit [276315] by aakash_jain@apple.com
  • 5 edits in trunk/Tools

Switch commit-queue back to git.webkit.org
https://bugs.webkit.org/show_bug.cgi?id=224762

Reviewed by Jonathan Bedard.

  • CISupport/ews-build/factories.py:

(CommitQueueFactory.init): Use git.webkit.org for Commit-Queue.

  • CISupport/ews-build/factories_unittest.py:

(TestCommitQueueFactory.test_commit_queue_factory): Updated unit-tests.

  • CISupport/ews-build/steps.py:

(CheckOutSource.init):
(PushCommitToWebKitRepo.evaluateCommand):

11:38 AM Changeset in webkit [276314] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

[macOS] Add additional logging to help identify SSO dialog dismissals
https://bugs.webkit.org/show_bug.cgi?id=224703
<rdar://problem/76783787>

Reviewed by Maciej Stachowiak.

Add logging around the SSO sheet life cycle to help identify edge cases..."

  • UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.mm:

(WebKit::SOAuthorizationSession::presentViewController):
(WebKit::SOAuthorizationSession::dismissViewController):

11:27 AM Changeset in webkit [276313] by Ruben Turcios
  • 5 edits
    2 copies
    1 add in branches/safari-612.1.11-branch/Source/WebCore

Cherry-pick r275907. rdar://problem/76907146

[WebIDL] includes for Conditional dictionary members should also be guarded
https://bugs.webkit.org/show_bug.cgi?id=224501
<rdar://problem/76598492>

Reviewed by Tim Horton.

WebKitAdditions sometimes needs to conditionally include IDL files and in those cases the
generated JS*.h might not get created even though the wrapped C++ type does exist. In
these cases, we should also guard the #include JS*.h (in addition to the already guarded
usage of the wrapped C++ type in convertDictionary).

  • bindings/scripts/CodeGeneratorJS.pm: (GenerateDictionaryImplementationContent):
  • bindings/scripts/test/TestDictionary.idl: Added.
  • bindings/scripts/test/JS/JSTestDictionary.h: Added.
  • bindings/scripts/test/JS/JSTestDictionary.cpp: Added.
  • bindings/scripts/test/TestDictionaryWithOnlyConditionalMembers.idl:
  • bindings/scripts/test/JS/JSTestDictionaryWithOnlyConditionalMembers.cpp:
  • bindings/scripts/test/SupplementalDependencies.dep:

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

11:02 AM Changeset in webkit [276312] by Wenson Hsieh
  • 3 edits in trunk/Source/WebKit

[Mac Catalyst] Adopt UIView API to avoid showing focus rings around WKContentView
https://bugs.webkit.org/show_bug.cgi?id=224819

Reviewed by Tim Horton.

Replace our usage of the deprecated -[UIView _setFocusRingType:] method with API on UIView that achieves
the same effect.

  • Platform/spi/ios/UIKitSPI.h:
  • UIProcess/ios/WKContentView.mm:

(-[WKContentView _commonInitializationWithProcessPool:configuration:]):

10:19 AM Changeset in webkit [276311] by commit-queue@webkit.org
  • 5 edits in trunk

Fix use-after-move introduced in r275407
https://bugs.webkit.org/show_bug.cgi?id=224045

Patch by Alex Christensen <achristensen@webkit.org> on 2021-04-20
Reviewed by Darin Adler.

Source/WebKit:

  • UIProcess/ios/WKGeolocationProviderIOS.mm:

(-[WKGeolocationProviderIOS geolocationAuthorizationGranted]):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/Geolocation.mm:

(-[FakeWebGeolocationPolicyDecider receivedRequest]):
(-[FakeWebGeolocationPolicyDecider decidePolicyForGeolocationRequestFromOrigin:requestingURL:window:listener:]):
(fakeWebGeolocationPolicyDecider):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/ios/UIKitSPI.h:
10:17 AM Changeset in webkit [276310] by Razvan Caliman
  • 11 edits in trunk/Source/WebInspectorUI

Web Inspector: Tree Outlines: ondetach can be called without onattach ever being called
https://bugs.webkit.org/show_bug.cgi?id=224652
<rdar://problem/76746385>

Reviewed by Devin Rousso.

Ensure TreeElement.ondetach() cannot be called if the conditions
for previously calling TreeElement.onattach() have not been met.

  • UserInterface/Views/TreeElement.js:

(WI.TreeElement.prototype._detach):

10:13 AM Changeset in webkit [276309] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

[WPE] QML WPEView dynamic loading fails
https://bugs.webkit.org/show_bug.cgi?id=224814

Patch by Marco Felsch <m.felsch@pengutronix.de> on 2021-04-20
Reviewed by Philippe Normand.

The scene graph can be initialized when we receive window handle change
notification and so we will not receive a scenegraph initialization
notification. In such case we need to initzialize it ourself.

No new tests. Testing can be done if the WPEView is moved to a
QML component which gets loaded later on demand.

  • UIProcess/API/wpe/qt/WPEQtView.cpp:

(WPEQtView::configureWindow):

9:50 AM Changeset in webkit [276308] by commit-queue@webkit.org
  • 7 edits in trunk

[WPE][Qt] Fix build failure after r270690
https://bugs.webkit.org/show_bug.cgi?id=223070

Patch by Marco Felsch <m.felsch@pengutronix.de> on 2021-04-20
Reviewed by Philippe Normand.

Source/WebKit:

WPE fails to build with -DENABLE_WPE_QT_API=ON after adapting the
visibility for linked frameworks done by r270690.

The reason for that is that the visibility is now more strict and we
have to add the WTF dependecy or drop the WTF fast-allocate mechanism.

Adding the WTF dependency is a bit odd since this would staticly link
the WTF lib into a small wrapper lib. Also this lib has nothing to do
with Webkit at all. It is just a QT adaption library.

No new tests, it can be build again.

  • UIProcess/API/wpe/qt/WPEQtView.cpp:

(WPEQtView::notifyLoadChangedCallback):
(WPEQtView::notifyLoadFailedCallback):
(WPEQtView::runJavaScript):

  • UIProcess/API/wpe/qt/WPEQtViewBackend.cpp:

(WPEQtViewBackend::create):

  • UIProcess/API/wpe/qt/WPEQtViewBackend.h:
  • UIProcess/API/wpe/qt/WPEQtViewLoadRequest.h:

Drop WTF usage and use system allocator since the lib has nothing to do
with Webkit at all.

Tools:

  • Scripts/webkitpy/style/checker.py:

Add exception for WPE QT wrapper library to use system alloc instead
of WTF.

9:16 AM Changeset in webkit [276307] by Aditya Keerthi
  • 5 edits in trunk

REGRESSION (r275523): [iOS] Opaque system fill colors are incorrect in dark mode
https://bugs.webkit.org/show_bug.cgi?id=224800
<rdar://problem/76878335>

Reviewed by Darin Adler.

Source/WebCore:

r275523 updated form control backgrounds to use opaque variants of
system colors. This change was implemented by blending the system
colors over a white background. However, in dark mode, the colors
should be blended over a black background, to retain a dark appearance.

Updated an existing test to validate the colors in light and dark mode.

  • rendering/RenderThemeIOS.mm:

(WebCore::systemColorFromCSSValueSystemColorInformation):

Added a useDarkAppearance parameter, so that the system color can be
blended over black when necessary.

(WebCore::systemColorFromCSSValueID):
(WebCore::RenderThemeIOS::cssValueToSystemColorMap const):

LayoutTests:

  • fast/css/ios/system-color-for-css-value-expected.txt:
  • fast/css/ios/system-color-for-css-value.html:
8:47 AM Changeset in webkit [276306] by basuke.suzuki@sony.com
  • 14 edits in trunk/Source

Remove UNUSED warnings based on the configuration.
https://bugs.webkit.org/show_bug.cgi?id=224787

Reviewed by Darin Adler.

Added UNUSED_VARIABLE or its variant to suppress warnings based on the configuration.

Source/WebCore:

No new tests because it just for suppression of the warnings.

  • loader/SubresourceLoader.cpp:

(WebCore::SubresourceLoader::willSendRequestInternal):

  • page/PageConsoleClient.cpp:

(WebCore::snapshotCanvas):

  • page/PerformanceLogging.cpp:

(WebCore::PerformanceLogging::didReachPointOfInterest):

  • platform/graphics/freetype/FontCacheFreeType.cpp:

(WebCore::FontCache::systemFallbackForCharacters):

  • platform/image-decoders/jpeg/JPEGImageDecoder.cpp:

Source/WebKit:

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.cpp:

(WebKit::ResourceLoadStatisticsStore::debugLogDomainsInBatches):

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::prepareToSuspend):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::requestStorageSpace):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):

  • WebProcess/Storage/WebSWContextManagerConnection.cpp:

(WebKit::WebSWContextManagerConnection::installServiceWorker):

  • WebProcess/WebPage/WebURLSchemeTaskProxy.cpp:

(WebKit::pageIDFromWebFrame):
(WebKit::frameIDFromWebFrame):

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::prepareToSuspend):

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

Make sure we don't exit the GPUProcess too frequently while under memory pressure
https://bugs.webkit.org/show_bug.cgi?id=224798

Reviewed by Darin Adler.

Source/WebKit:

We've recently started to exit the GPUProcess if idle and under memory pressure, in order
to save memory. This is great but we wouldn't want to repeatedly exit and relaunch the
GPUProcess while under memory pressure either. To address this, I am adding a condition to
GPUProcess::canExitUnderMemoryPressure() to make sure we don't exit the GPUProcess if it's
been running for less than 5 seconds.

To avoid generating flakiness in our benchmarks and API tests, I am disabling this condition
if the memory pressure is simulated (via notifyutil -p org.WebKit.lowMemory).

  • GPUProcess/GPUProcess.cpp:

(WebKit::GPUProcess::canExitUnderMemoryPressure const):

  • GPUProcess/GPUProcess.h:

Source/WTF:

Add member function to the MemoryPressureHandler to indicate if we're currently simulating memory
pressure or not.

  • wtf/MemoryPressureHandler.h:

(WTF::MemoryPressureHandler::isSimulatingMemoryPressure const):

7:51 AM Changeset in webkit [276304] by Chris Dumez
  • 5 edits in trunk/Source/WebKit

Unreviewed, reverting r276271.

It did not fix the Canvas-Arcs subtest on the bots

Reverted changeset:

"MotionMark's Canvas-Arcs subtest is broken if the GPUProcess
is not yet running"
https://bugs.webkit.org/show_bug.cgi?id=224778
https://commits.webkit.org/r276271

7:48 AM Changeset in webkit [276303] by Darin Adler
  • 25 edits
    1 add in trunk/Source

Refactor sorted array mapping machinery in LocaleToScriptMapping.cpp for reuse elsewhere
https://bugs.webkit.org/show_bug.cgi?id=224733

Reviewed by Yusuke Suzuki.

Source/WebCore:

  • Modules/indexeddb/client/IDBConnectionToServer.h: Removed unneeded includes.
  • Modules/mediastream/RTCRtpSFrameTransformer.h: Ditto.
  • Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h: Ditto.
  • Modules/webauthn/AuthenticatorCoordinatorClient.h: Ditto.
  • Modules/websockets/WebSocketChannel.cpp: Ditto.
  • Modules/websockets/WebSocketDeflater.cpp: Ditto.
  • bindings/IDLTypes.h: Ditto.
  • bridge/jsc/BridgeJSC.h: Ditto.
  • contentextensions/DFANode.h: Ditto.
  • contentextensions/NFAToDFA.cpp: Ditto.
  • contentextensions/Term.h: Ditto.
  • css/typedom/StylePropertyMap.h: Ditto.
  • css/typedom/StylePropertyMapReadOnly.cpp: Ditto.
  • cssjit/SelectorCompiler.cpp: Ditto.
  • platform/text/LocaleToScriptMapping.cpp:

(WebCore::scriptNameToCode): Refactor to use SortedArrayMap. Also changed to take StringView.
(WebCore::localeToScriptCodeForFontSelection): Ditto. Cut down on memory allocation by using
StringView instead of String while looping through substrings.

  • platform/text/LocaleToScriptMapping.h: Changed scriptNameToCode to take StringView.

Source/WebKit:

  • NetworkProcess/PrivateClickMeasurementManager.h: Removed unused include of HashMap.h.
  • NetworkProcess/cache/NetworkCacheSubresourcesEntry.h: Ditto.
  • WebProcess/WebPage/mac/WebPageMac.mm:

(WebKit::createSelectorExceptionMap): Deleted.
(WebKit::commandNameForSelectorName): Use SortedArrayMap instead of HashMap.

Source/WTF:

  • WTF.xcodeproj/project.pbxproj: Added SortedArrayMap.h.
  • wtf/CMakeLists.txt: Ditto.
  • wtf/SortedArrayMap.h: Added. Builds on the idiom in LocalToScriptMapping, and to be

generic uses std::pair instead of custom structures. Includes the ComparableASCIILiteral
structure for maps that are keyed by case-sensitive ASCII strings.

  • wtf/StdLibExtras.h:

(WTF::binarySearchImpl): Use auto in one place to make this a bit more generic.

7:07 AM Changeset in webkit [276302] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC] Implement Box::isSizeContainmentBox()
https://bugs.webkit.org/show_bug.cgi?id=224799

Reviewed by Antti Koivisto.

This is part of https://www.w3.org/TR/css-contain-2/#containment-size

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::isSizeContainmentBox const):

  • layout/layouttree/LayoutBox.h:
4:38 AM Changeset in webkit [276301] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore

AudioSourceProviderAVFObjC uses atomic variables but also locks with mutex
https://bugs.webkit.org/show_bug.cgi?id=224543

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-04-20
Reviewed by Darin Adler.

Remove the use of std::atomic, the variables are already protected by the
mutex.

  • platform/graphics/avfoundation/AudioSourceProviderAVFObjC.h:
  • platform/graphics/avfoundation/AudioSourceProviderAVFObjC.mm:

(WebCore::AudioSourceProviderAVFObjC::provideInput):
(WebCore::AudioSourceProviderAVFObjC::process):

4:29 AM Changeset in webkit [276300] by commit-queue@webkit.org
  • 6 edits in trunk/Source/WebKit

WebGL GPU Process implementation should use thread safety annotations
https://bugs.webkit.org/show_bug.cgi?id=224752

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-04-20
Reviewed by Kenneth Russell.

Make WebGL GPU process implementation use thread safety analysis.

Mark up the guarded variables in IPC Stream implementation using
clang thread safety analysis annotations.

  • GPUProcess/graphics/RemoteGraphicsContextGL.cpp:

(WebKit::RemoteGraphicsContextGL::paintImageDataToImageBuffer):

  • Platform/IPC/StreamConnectionWorkQueue.cpp:

(IPC::StreamConnectionWorkQueue::dispatch):
(IPC::StreamConnectionWorkQueue::addStreamConnection):
(IPC::StreamConnectionWorkQueue::removeStreamConnection):
(IPC::StreamConnectionWorkQueue::processStreams):

  • Platform/IPC/StreamConnectionWorkQueue.h:
  • Platform/IPC/StreamServerConnection.cpp:

(IPC::StreamServerConnectionBase::enqueueMessage):

  • Platform/IPC/StreamServerConnection.h:

(IPC::StreamServerConnection<Receiver>::startReceivingMessages):
(IPC::StreamServerConnection<Receiver>::stopReceivingMessages):
(IPC::StreamServerConnection<Receiver>::dispatchStreamMessages):
(IPC::StreamServerConnection<Receiver>::dispatchOutOfStreamMessage):

3:54 AM Changeset in webkit [276299] by Martin Robinson
  • 5 edits in trunk/Source/WebCore

Re-land: Eliminate ScrollAnimatorGeneric::m_smoothAnimation
https://bugs.webkit.org/show_bug.cgi?id=222588

Reviewed by Žan Doberšek.

No new tests. This change should not change behavior.

Eliminate the extra ScrollAnimationSmooth in ScrollAnimatorGeneric. The base
class already knows how to do scroll animations for programmatic scrolls,
so we can reuse that animation for doing ScrollAnimator::scroll(...). This
makes the code easier to understand and should simplify managing interactions
between the different animations in the future.

Changes since first version: Now only update the current position of the animation
if it is not active. This is the behavior that was used in ScrollAnimatorGeneric
and is the correct behavior when using ScrollAnimationSmooth.

  • platform/ScrollAnimator.cpp:

(WebCore::ScrollAnimator::ScrollAnimator): Renamed m_animationProgrammaticScroll
to m_scrollAnimation. The more generic name reflects the fact that it is also
used for doing scrolling from UI interaction now.
(WebCore::ScrollAnimator::scroll): Use the ScrollAnimationSmooth member to do
animated scrolls when necessary.
(WebCore::ScrollAnimator::scrollToPositionWithoutAnimation): Make sure the animation
is up to date with the current position when scrolling without it. This is
how ScrollAnimatorGeneric treated its ScrollAnimationSmooth.
(WebCore::ScrollAnimator::scrollToPositionWithAnimation): Rename member.
(WebCore::ScrollAnimator::cancelAnimations): Ditto.
(WebCore::ScrollAnimator::willEndLiveResize): Ditto.
(WebCore::ScrollAnimator::didAddVerticalScrollbar): Ditto.
(WebCore::ScrollAnimator::didAddHorizontalScrollbar): Ditto.

  • platform/ScrollAnimator.h: Ditto.
  • platform/generic/ScrollAnimatorGeneric.cpp:

(WebCore::ScrollAnimatorGeneric::ScrollAnimatorGeneric): Eliminate ScrollAnimationSmooth.
(WebCore::ScrollAnimatorGeneric::scrollToPositionWithoutAnimation): Ditto.
(WebCore::ScrollAnimatorGeneric::didAddVerticalScrollbar): Ditto.
(WebCore::ScrollAnimatorGeneric::didAddHorizontalScrollbar): Ditto.
(WebCore::ScrollAnimatorGeneric::ensureSmoothScrollingAnimation): Deleted.
(WebCore::ScrollAnimatorGeneric::scroll): Deleted.
(WebCore::ScrollAnimatorGeneric::willEndLiveResize): Deleted.

  • platform/generic/ScrollAnimatorGeneric.h:
3:53 AM WebKitGTK/2.32.x edited by Philippe Normand
(diff)
3:25 AM Changeset in webkit [276298] by ysuzuki@apple.com
  • 2 edits in trunk/JSTests

[JSC] Limit memory allocation size of JSTests/stress/early-return-from-builtin.js
https://bugs.webkit.org/show_bug.cgi?id=224803
<rdar://problem/75597901>

Reviewed by Ryosuke Niwa.

Add limit to JSTests/stress/early-return-from-builtin.js to avoid infinite allocation.

  • stress/early-return-from-builtin.js:

(let.iter.Symbol.iterator):

3:24 AM Changeset in webkit [276297] by Manuel Rego Casasnovas
  • 2 edits
    3 adds in trunk/LayoutTests

[WPE] Update expectations for 2 :focus-visible tests
https://bugs.webkit.org/show_bug.cgi?id=224808

Unreviewed test gardening.

The failures on these tests are related to the lack of support for <input type="color"> in WPE.

  • platform/wpe/TestExpectations:
  • platform/wpe/imported/w3c/web-platform-tests/css/selectors/focus-visible-003-expected.txt: Added.
  • platform/wpe/imported/w3c/web-platform-tests/css/selectors/focus-visible-004-expected.txt: Added.
3:19 AM Changeset in webkit [276296] by cathiechen
  • 10 edits
    7 adds in trunk/LayoutTests

Update html/rendering/replaced-elements/attributes-for-embedded-content-and-images/ tests from WPT
https://bugs.webkit.org/show_bug.cgi?id=224748

Reviewed by Rob Buis.

LayoutTests/imported/w3c:

Update the tests for "mapping attribute width and height as the implicit aspect ratio" which are based on the latest agreement
from WPT commit 19445e7b39.

  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/canvas-aspect-ratio-expected.txt:
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/canvas-aspect-ratio.html:
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/img-aspect-ratio-expected.txt:
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/img-aspect-ratio.html:
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/number-placeholder-right-aligned-expected.html: Added.
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/number-placeholder-right-aligned.html: Added.
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/picture-aspect-ratio-expected.txt: Added.
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/picture-aspect-ratio.html: Added.
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/resources/aspect-ratio.js: Added.

(test_computed_style_aspect_ratio):

  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/resources/w3c-import.log: Added.
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/video-aspect-ratio-expected.txt:
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/video-aspect-ratio.html:
  • web-platform-tests/html/rendering/replaced-elements/attributes-for-embedded-content-and-images/w3c-import.log:

LayoutTests:

picture-aspect-ratio.html is flaky.

2:50 AM Changeset in webkit [276295] by Chris Lord
  • 2 edits in trunk/Source/WebCore

Don't use the full CSS parser for CSSFontFaceSet
https://bugs.webkit.org/show_bug.cgi?id=224749

Reviewed by Darin Adler.

Replace use of the full CSS parser in CSSFontFaceSet with
CSSPropertyParserWorkerSafe::parseFont to parse font shorthands. This
makes CSSFontFaceSet safe to use in a Worker (required for
OffscreenCanvas) and ought also to be faster, at the cost of a slight
increase in lines of code.

No new tests, covered by existing tests.

  • css/CSSFontFaceSet.cpp:

(WebCore::computeFontSelectionRequest):
(WebCore::CSSFontFaceSet::matchingFacesExcludingPreinstalledFonts):

2:22 AM Changeset in webkit [276294] by Carlos Garcia Campos
  • 2 edits in trunk

[WPE] Switch to libsoup3 by default
https://bugs.webkit.org/show_bug.cgi?id=224802

Reviewed by Žan Doberšek.

  • Source/cmake/OptionsWPE.cmake:
2:14 AM Changeset in webkit [276293] by commit-queue@webkit.org
  • 11 edits in trunk

Implement CSS display property 2-value syntax
https://bugs.webkit.org/show_bug.cgi?id=224574

Patch by Tim Nguyen <ntim@apple.com> on 2021-04-20
Reviewed by Darin Adler.

Except for list-item which doesn't have layout support for different variants.
Also fix a WPT to expect the most backwards-compatible form for display: flow computed value.

Test: web-platform-tests/css/css-display/parsing/display-valid.html

LayoutTests/imported/w3c:

  • web-platform-tests/css/css-display/parsing/display-valid-expected.txt:
  • web-platform-tests/html/rendering/widgets/button-layout/computed-style-expected.txt:
  • web-platform-tests/html/rendering/widgets/button-layout/computed-style.html:
  • web-platform-tests/html/rendering/widgets/button-layout/display-other-expected.txt:

Source/WebCore:

  • css/CSSValueKeywords.in:
  • css/parser/CSSParserFastPaths.cpp:

(WebCore::CSSParserFastPaths::isValidKeywordPropertyAndValue):
(WebCore::CSSParserFastPaths::isKeywordPropertyID):

  • css/parser/CSSPropertyParser.cpp:

(WebCore::consumeDisplay):
(WebCore::CSSPropertyParser::parseSingleValue):

LayoutTests:

  • platform/mac-wk1/imported/w3c/web-platform-tests/html/rendering/widgets/button-layout/computed-style-expected.txt:
1:46 AM Changeset in webkit [276292] by Ben Nham
  • 2 edits in trunk/Source/JavaScriptCore

LinkBuffer fails to build when MALLOC_HEAP_BREAKDOWN is enabled
https://bugs.webkit.org/show_bug.cgi?id=224722

Reviewed by Yusuke Suzuki.

When ENABLE_MALLOC_HEAP_BREAKDOWN is set, LinkBuffer causes a build failure at link time
since it never defines its debugHeap. Fix that.

  • assembler/LinkBuffer.cpp:
12:44 AM Changeset in webkit [276291] by Diego Pino Garcia
  • 3 edits
    2 deletes in trunk/LayoutTests

[WPE] Unreviewed test gardening. Update baselines and test expectations of recent failures.

  • platform/wpe/TestExpectations:
  • platform/wpe/fast/canvas/webgl/index-validation-with-subsequent-draws-expected.txt: Removed.
  • platform/wpe/fast/encoding/utf-16-little-endian-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/resource-timing/resource_timing.worker-expected.txt: Removed.
12:26 AM Changeset in webkit [276290] by ysuzuki@apple.com
  • 5 edits in trunk/Source/JavaScriptCore

[JSC] Use FixedVector for LLIntPrototypeLoadAdaptiveStructureWatchpoint vector
https://bugs.webkit.org/show_bug.cgi?id=224729

Reviewed by Darin Adler.

Replace Vector<LLIntPrototypeLoadAdaptiveStructureWatchpoint> with FixedVector.

  • bytecode/CodeBlock.h:
  • bytecode/LLIntPrototypeLoadAdaptiveStructureWatchpoint.cpp:

(JSC::LLIntPrototypeLoadAdaptiveStructureWatchpoint::LLIntPrototypeLoadAdaptiveStructureWatchpoint):
(JSC::LLIntPrototypeLoadAdaptiveStructureWatchpoint::initialize):

  • bytecode/LLIntPrototypeLoadAdaptiveStructureWatchpoint.h:
  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::setupGetByIdPrototypeCache):

12:14 AM Changeset in webkit [276289] by Diego Pino Garcia
  • 3 edits
    2 adds in trunk/LayoutTests

[GTK][WPE] Unreviewed test gardening. Emit new port baselines after r276193.

  • platform/gtk/TestExpectations:
  • platform/gtk/security/block-test-expected.txt: Added.
  • platform/wpe/security/block-test-expected.txt:
12:12 AM Changeset in webkit [276288] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebKit

REGRESSION(r224516): Remote WebGL Context is not create due to RemoteRenderingBackend not being created
https://bugs.webkit.org/show_bug.cgi?id=224751

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-04-20
Reviewed by Chris Dumez.

Fix WebGL GPU process after r275922.

RemoteRenderingBackend must be created so that RemoteGraphicsContextGL
can take a reference of it.

Fixes layout test failures when run with --gpu-process.

  • WebProcess/GPU/graphics/RemoteRenderingBackendProxy.cpp:

(WebKit::RemoteRenderingBackendProxy::ensureBackendCreated):

  • WebProcess/GPU/graphics/RemoteRenderingBackendProxy.h:
  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::createGraphicsContextGL const):

Apr 19, 2021:

11:33 PM Changeset in webkit [276287] by Antti Koivisto
  • 16 edits in trunk

Render tree updates for Text node content mutations should happen during rendering update
https://bugs.webkit.org/show_bug.cgi?id=222406
<rdar://problem/74822830>

Reviewed by Simon Fraser.

Source/WebCore:

Calls to Text.insertData and similar should not mutate render tree synchronously.
Instead render tree should be updated during the next rendering update along with
any style changes.

These updates already go via RenderTreeUpdater. We just need to save the information
about which nodes need updating so the next rendering update can pick them up.

This seems to help with some performance benchmarks.

  • dom/CharacterData.cpp:

(WebCore::CharacterData::parserAppendData):
(WebCore::CharacterData::setDataAndUpdate):

Move in-tree check to the updateRendererAfterContentChange and make it use isConnected().

  • dom/Document.cpp:

(WebCore::Document::removedLastRef):
(WebCore::Document::resolveStyle):

Include the text update when updating the render tree.

(WebCore::Document::updateTextRenderer):

Create a text update that will get flushed during the next rendering update.

(WebCore::Document::needsStyleRecalc const):

We need to recalc if there are pending text updates.

  • dom/Document.h:
  • dom/Text.cpp:

(WebCore::Text::splitText):

Use updateRendererAfterContentChange instead of poking render tree directly.

(WebCore::Text::updateRendererAfterContentChange):

  • rendering/updating/RenderTreeUpdater.cpp:
  • style/StyleTreeResolver.cpp:

(WebCore::Style::TreeResolver::TreeResolver):
(WebCore::Style::TreeResolver::resolve):

  • style/StyleTreeResolver.h:

(WebCore::Style::TreeResolver::TreeResolver):

  • style/StyleUpdate.cpp:

(WebCore::Style::Update::addText):

Merge text updates.

(WebCore::Style::Update::addPossibleRoot):

  • style/StyleUpdate.h:

(WebCore::Style::Update::roots const):
(WebCore::Style::Update:: const): Deleted.

Refcount the nodes since this now has longer lifetime.

  • editing/CompositeEditCommand.cpp:

(WebCore::CompositeEditCommand::deleteInsignificantText):

Ensure we leave deleteInsignificantText with updated render tree. Clients expect that.
Do layout (instead of just style update) for consistency, deleteInsignificantText does one anyway in beginning.

  • editing/markup.cpp:

(WebCore::replaceChildrenWithFragment):

Pending text update may ref the node so this refcount assert is not correct.

  • style/StyleUpdate.cpp:

(WebCore::Style::Update::addText):

LayoutTests:

These are progressions.

  • fast/text/splitText-dirty-lines-expected.txt:
  • fast/text/text-combine-surroundContents-crash-expected.txt:
  • imported/blink/fast/css/first-letter-range-insert-expected.txt:

Here we were actually drawing text that didn't exist in DOM anymore.

10:19 PM Changeset in webkit [276286] by commit-queue@webkit.org
  • 2 edits in trunk/Source/ThirdParty/ANGLE

Build ANGLE dylib into WK_OVERRIDE_FRAMEWORKS_DIR in builds that use it
https://bugs.webkit.org/show_bug.cgi?id=224785
<rdar://76641662>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-04-19
Reviewed by Alexey Proskuryakov.

  • Configurations/ANGLE-dynamic.xcconfig:
10:15 PM Changeset in webkit [276285] by ysuzuki@apple.com
  • 8 edits in trunk/JSTests

[JSC] Rebaseline test results for new ICU
https://bugs.webkit.org/show_bug.cgi?id=224792

Reviewed by Mark Lam.

This patch updates some intl- tests' expectation since it is changed because of ICU CLDR data change.

  • stress/intl-datetimeformat-formatrange-relevant-extensions-ja.js:

(shouldBeOneOfThem):
(vm.icuVersion):

  • stress/intl-datetimeformat-formatrange-relevant-extensions.js:

(shouldBeOneOfThem):

  • stress/intl-datetimeformat-formatrange-should-not-handle-gregorian-change-date.js:

(shouldBe):
(vm.icuHeaderVersion):

  • stress/intl-datetimeformat-formatrangetoparts-relevant-extensions-ja.js:

(normalize):
(shouldBe):
(compareParts):
(shouldBeOneOfParts):
(shouldBeParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt5.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.vm.icuVersion):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt7.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt9.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt11.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt13.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeParts.fmt13.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt14.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt15.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.shouldBeOneOfParts.fmt16.formatRangeToParts):
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt1.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt2.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt3.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt4.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt5.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt6.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt7.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt8.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt9.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt10.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt11.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt12.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt13.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt14.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt15.formatRangeToParts): Deleted.
(Intl.DateTimeFormat.prototype.formatRangeToParts.compareParts.fmt16.formatRangeToParts): Deleted.

  • stress/intl-datetimeformat-formatrangetoparts-relevant-extensions.js:

(normalize):
(shouldBe):
(compareParts):
(shouldBeOneOfParts):
(shouldBeParts):

  • stress/intl-datetimeformat-formatrangetoparts-should-not-handle-gregorian-change-date.js:

(shouldBe):

  • stress/intl-datetimeformat.js:

(shouldBeOneOfThem):

9:49 PM Changeset in webkit [276284] by Chris Dumez
  • 5 edits in trunk

REGRESSION (r276189): GPUProcess.WebProcessTerminationAfterTooManyGPUProcessCrashes is crashing
https://bugs.webkit.org/show_bug.cgi?id=224790
<rdar://problem/76869318>

Reviewed by Darin Adler.

Source/WebKit:

GPUProcess.WebProcessTerminationAfterTooManyGPUProcessCrashes is intentionally repeatedly
killing the GPUProcess. As a result, the GPUProcess may get killed very shortly after
a relaunch and the RemoteAudioDestinationManager::StartAudioDestination synchronous IPC
may fail if it is ongoing at the time of the crash. This would cause m_destinationID to
not get initialized and then get sent as IPC parameter, thus crashing.

pre-r276189, we were not crashing because m_destinationID was not reset on crash and we
would thus send IPC for a destination that does not exist but at least the destinationID
would not be 0. This patch makes sure we don't try and send IPC at all when m_destinationID
is 0.

  • WebProcess/GPU/media/RemoteAudioDestinationProxy.cpp:

(WebKit::RemoteAudioDestinationProxy::connection):
(WebKit::RemoteAudioDestinationProxy::startRendering):
(WebKit::RemoteAudioDestinationProxy::stopRendering):
(WebKit::RemoteAudioDestinationProxy::storageChanged):

  • WebProcess/GPU/media/RemoteAudioDestinationProxy.h:

Tools:

Re-enable API test now that it is no longer crashing.

  • TestWebKitAPI/Tests/WebKitCocoa/GPUProcess.mm:

(TEST):

9:45 PM Changeset in webkit [276283] by Said Abou-Hallawa
  • 3 edits in trunk/Source/WebCore

cachedCGColor() and nsColor() are not thread-safe
https://bugs.webkit.org/show_bug.cgi?id=223033

Reviewed by Chris Dumez.

These functions will break if they are used by a worker thread.

  • platform/graphics/cg/ColorCG.cpp:

(WebCore::cachedCGColor):

  • platform/graphics/mac/ColorMac.mm:

(WebCore::nsColor):

8:26 PM Changeset in webkit [276282] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GLIB] Unreviewed test gardening. Gardened flaky failures after r224791.

  • platform/glib/TestExpectations:
7:26 PM Changeset in webkit [276281] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebKit

[iOS] Media playback continues after backgrounding hosting application
https://bugs.webkit.org/show_bug.cgi?id=224776
<rdar://75707807>

Reviewed by Eric Carlson.

Tested by existing API test: WKWebViewPausePlayingAudioTests.OutOfWindow

When the MediaSessionHelperIOS was moved into the GPU process, no object remains listening for the
UIApplication{Will,Did}Enter{Foreground,Background}Notification rebroadcasted by WebPageIOS.

Rather than just rebroadcast the UIKit notification to all listeners within the WebContent process,
which may or may not be listening, just tell the current PlatformMediaSessionManager directly.

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::applicationWillResignActive):
(WebKit::WebPage::applicationDidEnterBackground):
(WebKit::WebPage::applicationWillEnterForeground):
(WebKit::WebPage::applicationDidBecomeActive):

6:02 PM Changeset in webkit [276280] by Chris Dumez
  • 2 edits in trunk/Tools

Unreviewed, temporarily disable GPUProcess.DISABLED_WebProcessTerminationAfterTooManyGPUProcessCrashes
https://bugs.webkit.org/show_bug.cgi?id=224790

It is crashing. I will renable it with the fix at Bug 224790.

  • TestWebKitAPI/Tests/WebKitCocoa/GPUProcess.mm:

(TEST):

5:54 PM Changeset in webkit [276279] by Diego Pino Garcia
  • 5 edits in trunk/LayoutTests

[GLIB] Unreviewed test gardening. Update baselines and test expectations after r224791.

  • platform/glib/TestExpectations:
  • platform/glib/http/tests/xmlhttprequest/simple-cross-origin-denied-events-post-expected.txt:
  • platform/glib/imported/w3c/web-platform-tests/xhr/send-entity-body-none-expected.txt:
  • platform/glib/security/block-test-no-port-expected.txt:
5:18 PM Changeset in webkit [276278] by Patrick Angle
  • 3 edits in trunk/Source/WebInspectorUI

REGRESSION (r268691 && r270134): Web Inspector: Clicking on go-to arrow in Computed panel no longer works
https://bugs.webkit.org/show_bug.cgi?id=224774

Reviewed by Devin Rousso.

The Styles panel will not always be part of the same sidebar as the Computed panel as of r268691, so we should
look for the Styles panel in WI.detailsSidebar, which will report all of the panels it manages across multiple
sidebars. Additionally, as of r270134, there is no longer a private _visible property for
WI.StyleDetailsPanel, so it can not be used by WI.SpreadsheetRulesStyleDetailsPanel. Instead, visibility
should be determined by checking if the panel is attached and not pending layout.

  • UserInterface/Views/ComputedStyleDetailsSidebarPanel.js:

(WI.ComputedStyleDetailsSidebarPanel.prototype.computedStyleDetailsPanelShowProperty):

  • UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:

(WI.SpreadsheetRulesStyleDetailsPanel.prototype.scrollToSectionAndHighlightProperty):

4:37 PM Changeset in webkit [276277] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

[ews] Enabled detailed error log when unit-tests fails
https://bugs.webkit.org/show_bug.cgi?id=224789

Unreviewed minor unit-test fix.

  • CISupport/ews-build/factories_unittest.py:

(TestCase): Set maxDiff to None.

4:03 PM Changeset in webkit [276276] by BJ Burg
  • 3 edits
    1 add in trunk/Tools

Can't use Web Inspector on web views made by TestWebKitAPI
https://bugs.webkit.org/show_bug.cgi?id=147073
<rdar://problem/76708379>

Reviewed by Devin Rousso.

It is necessary to spin a nested run loop at the point in the test where you would
like to remote inspect a WebView. Messages from the remote connection are dispatched
through UIProcess, so if lldb has paused UIProcess, WebInspectorUI will not be able to
get any data from the inspected WebView.

  • TestWebKitAPI/DebugUtilities.h: Added.

Add macros to wait for a remote inspector to attach or detach, then drop into
the debugger when it has done so.

  • TestWebKitAPI/PlatformUtilities.h: Add missing #pragma once.
  • TestWebKitAPI/WTFStringUtilities.h: Force the build to fail noisily if we have

attempted to redefine WTF_STRINGTYPEADAPTER_COPIED_WTF_STRING. Force the correct
ordering between "WTFStringUtilities.h" and <wtf/text/StringConcatenate.h>.

3:20 PM Changeset in webkit [276275] by Wenson Hsieh
  • 6 edits in trunk

Rename FloatQuad::isEmpty() to boundingBoxIsEmpty() and reimplement isEmpty()
https://bugs.webkit.org/show_bug.cgi?id=224769

Reviewed by Tim Horton.

Source/WebCore:

The existing isEmpty() method on FloatQuad only checks that the bounding box of the quad is empty (as
indicated by the comment above the method declaration). This means isEmpty() returns false in cases where
the quad consists of one or more non-rectilinear line segments, even though the quad contains no area.

To address this, we rename the existing isEmpty() helper to boundingBoxIsEmpty() and reintroduce an
isEmpty() method that accounts for quads which are equivalent to non-rectilinear line segments.

No change in behavior.

  • inspector/InspectorOverlay.cpp:

(WebCore::drawFragmentHighlight):

  • platform/graphics/FloatQuad.cpp:
  • platform/graphics/FloatQuad.h:

(WebCore::FloatQuad::isEmpty const): Deleted.
(WebCore::FloatQuad::boundingBoxIsEmpty const):

Tools:

Add an API test to exercise the new FloatQuad::isEmpty() method.

  • TestWebKitAPI/Tests/WebCore/FloatQuadTests.cpp:

(TestWebKitAPI::checkIsEmpty):
(TestWebKitAPI::TEST):

2:18 PM Changeset in webkit [276274] by Patrick Angle
  • 2 edits in trunk/Source/WebCore

Web Inspector: Grid overlay column line label placement copy/paste error
https://bugs.webkit.org/show_bug.cgi?id=224777

Reviewed by Devin Rousso.

In grid overlays, a typo meant for all column line labels after the initial line, only the start of the line was
used for placement, where it is more accurate to use the start and end points to match the behavior of the first
line. This had no visual impact because subsequent lines do not currently have their labels adjusted further into
the grid, only flipped into the grid but still referencing the same point. This patch corrects the value of
gapLabelLine to always be a line on which the label can be placed, instead of a single point.

  • inspector/InspectorOverlay.cpp:

(WebCore::InspectorOverlay::buildGridOverlay):

2:10 PM Changeset in webkit [276273] by youenn@apple.com
  • 3 edits in trunk/LayoutTests

[mac-wk2] LayoutTest fast/mediastream/getUserMedia-webaudio.html is a flaky timeout
https://bugs.webkit.org/show_bug.cgi?id=170960

Reviewed by Eric Carlson.

Update test to check for noise for more iterations.
Remove timeout expectation since it is no longer timing out in bots.

  • fast/mediastream/getUserMedia-webaudio.html:
  • platform/mac-wk2/TestExpectations:
1:45 PM Changeset in webkit [276272] by Devin Rousso
  • 8 edits
    2 adds in trunk

Web Inspector: Graphics: add support for steps()/spring() CSS timing functions
https://bugs.webkit.org/show_bug.cgi?id=224654

Reviewed by BJ Burg.

Source/WebInspectorUI:

  • UserInterface/Models/Geometry.js:

(WI.StepsFunction): Added.
(WI.StepsFunction.fromString): Added.
(WI.StepsFunction.prototype.get type): Added.
(WI.StepsFunction.prototype.get count): Added.
(WI.StepsFunction.prototype.copy): Added.
(WI.StepsFunction.prototype.toString): Added.
Create a model object for steps() CSS timing function.

  • UserInterface/Models/Animation.js:

(WI.Animation.prototype._updateEffect):
Also support effect.timingFunction/keyframe.easing being a steps()/spring() CSS timing function.

  • UserInterface/Views/AnimationContentView.js:

(WI.AnimationContentView.prototype._refreshPreview):
Create a UI for steps()/spring() CSS timing functions.

LayoutTests:

  • inspector/animation/lifecycle-web-animation.html:
  • inspector/animation/lifecycle-web-animation-expected.txt:
  • inspector/animation/resources/lifecycle-utilities.js:
  • inspector/unit-tests/geometry.html: Added.
  • inspector/unit-tests/geometry-expected.txt: Added.
1:35 PM Changeset in webkit [276271] by Chris Dumez
  • 5 edits in trunk/Source/WebKit

MotionMark's Canvas-Arcs subtest is broken if the GPUProcess is not yet running
https://bugs.webkit.org/show_bug.cgi?id=224778

Reviewed by Simon Fraser.

I recently made changes so that the GPUProcess is only launched when it is needed. This means
that until MotionMark's Canvas-Arcs subtest, the GPUProcess is usually not yet running. As a
result, RemoteRenderingBackendProxy::createImageBuffer() ends up launching the GPUProcess
and sending the GPUConnectionToWebProcess::CreateRenderingBackend and
RemoteRenderingBackend::CreateImageBuffer IPC right away. We seem to have a synchronization
issue because when this happens, the rendering for the Canvas-Arcs subtest is visibly broken
and its score is very low (< 6, instead of > 600).

Making the GPUConnectionToWebProcess::CreateRenderingBackend synchronous again (I made it
async recently) seems to address the synchronization issue and restores correct behavior on
MotionMark. I am therefore making this IPC synchronous again in this patch to get benchmark
coverage again while I investigate the root cause offline.

  • GPUProcess/GPUConnectionToWebProcess.cpp:

(WebKit::GPUConnectionToWebProcess::createRenderingBackend):

  • GPUProcess/GPUConnectionToWebProcess.h:
  • GPUProcess/GPUConnectionToWebProcess.messages.in:
  • WebProcess/GPU/graphics/RemoteRenderingBackendProxy.cpp:

(WebKit::RemoteRenderingBackendProxy::ensureGPUProcessConnection):

1:16 PM Changeset in webkit [276270] by timothy_horton@apple.com
  • 2 edits in trunk/Tools

Fix the macCatalyst TestWebKitAPI build
https://bugs.webkit.org/show_bug.cgi?id=224780

  • TestWebKitAPI/Configurations/TestWebKitAPI.xcconfig:

Unreviewed build fix; link PDFKit since we now enable it.

1:09 PM Changeset in webkit [276269] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC][IFC] LineCandidate.inlineContent should be ignored when reverting
https://bugs.webkit.org/show_bug.cgi?id=224771
<rdar://76760857>

Reviewed by Antti Koivisto.

Source/WebCore:

LineCandidate.inlineContent is a set of candidate runs for the line and when the line breaker says "please revert" (move back to an earlier position on the line)
these runs should all be ignored as they did not make it to the line.
(inlineContentIsFullyCommitted flag got confused when the number of candidate runs matched the number of runs we managed to put on the line as part of the revert. It did not take the "revert" bit into account.)

Test: fast/inline/crash-when-revert-has-trailing-line-break.html

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::placeInlineContent):

LayoutTests:

  • fast/inline/crash-when-revert-has-trailing-line-break-expected.txt: Added.
  • fast/inline/crash-when-revert-has-trailing-line-break.html: Added.
12:42 PM Changeset in webkit [276268] by Amir Mark Jr.
  • 2 edits in trunk/LayoutTests

[ wk2 ] http/tests/security/contentSecurityPolicy/report-only-connect-src-xmlhttprequest-redirect-to-blocked.py is a constant text failure
https://bugs.webkit.org/show_bug.cgi?id=224626

Unreviewed test gardening

  • platform/wk2/TestExpectations: Updating expectations as a fix is being worked on.
11:55 AM Changeset in webkit [276267] by Chris Dumez
  • 4 edits in trunk

SVG Images launch the GPUProcess unnecessarily
https://bugs.webkit.org/show_bug.cgi?id=224770

Reviewed by Eric Carlson.

Source/WebCore:

Make sure MediaPlayer::supportsType() returns early for MIME types that can definitely
not be media, to avoid launch the GPUProcess unnecessarily.

  • platform/graphics/MediaPlayer.cpp:

(WebCore::MediaPlayer::supportsType):

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKitCocoa/GPUProcess.mm:

(TEST):

11:52 AM Changeset in webkit [276266] by msaboff@apple.com
  • 13 edits in trunk/Source/bmalloc

[bmalloc] Enable Adaptive Scavenger for Mac
https://bugs.webkit.org/show_bug.cgi?id=224706

Reviewed by Filip Pizlo.

Enabled the adaptive scavenger code paths for macOS.
The original reason that the partial scavenging paths were kept for macOS was due
to regression on power tests. To alleviate the power regression, this patch splits
out the adaptive scavenger parameters with macOS specific values.

The parameters are:

The multiplier used to compute the next scavenging wait time based on the

time needed for the prior scavenging.

Minimum wait time between scavenging.
Maximum wait time between scavenging.

The values in the current code are:

Wait time Multiplier: 150
Minimum wait time: 100ms
Maximum wait time: 10,000ms (10 seconds)

The proposed values for macOS, determined using empirical testing.

Wait time Multiplier: 300
Minimum wait time: 750ms
Maximum wait time: 20,000ms (20 seconds)


When tested on various mac variants, this change:

  • Provides a 3-5% reduction in memory use on RAMification.
  • It is neutral on JetStream2.
  • It is neutral to a slight regression on Speedometer2, but there is some variability in those results.

Since macOS was the only platform still using the partial scavenging code path,
the partial scavenging code paths were deleted.

  • bmalloc/BPlatform.h:
  • bmalloc/Heap.cpp:

(bmalloc::Heap::scavenge):
(bmalloc::Heap::allocateSmallChunk):
(bmalloc::Heap::allocateSmallPage):
(bmalloc::Heap::allocateLarge):
(bmalloc::Heap::scavengeToHighWatermark): Deleted.

  • bmalloc/Heap.h:
  • bmalloc/IsoDirectory.h:
  • bmalloc/IsoDirectoryInlines.h:

(bmalloc::passedNumPages>::takeFirstEligible):
(bmalloc::passedNumPages>::scavenge):
(bmalloc::passedNumPages>::scavengeToHighWatermark): Deleted.

  • bmalloc/IsoHeapImpl.h:
  • bmalloc/IsoHeapImplInlines.h:

(bmalloc::IsoHeapImpl<Config>::scavengeToHighWatermark): Deleted.

  • bmalloc/LargeMap.cpp:

(bmalloc::LargeMap::add):

  • bmalloc/LargeRange.h:

(bmalloc::LargeRange::LargeRange):
(bmalloc::LargeRange::setUsedSinceLastScavenge):
(bmalloc::merge):
(): Deleted.

  • bmalloc/Scavenger.cpp:

(bmalloc::Scavenger::Scavenger):
(bmalloc::Scavenger::scavenge):
(bmalloc::Scavenger::threadRunLoop):
(bmalloc::Scavenger::timeSinceLastPartialScavenge): Deleted.
(bmalloc::Scavenger::partialScavenge): Deleted.

  • bmalloc/Scavenger.h:
  • bmalloc/SmallPage.h:

(bmalloc::SmallPage::setUsedSinceLastScavenge):

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

Web Inspector: REGRESSION(?): Network: Request (Object Tree) is sometimes empty
https://bugs.webkit.org/show_bug.cgi?id=224768
<rdar://problem/76783636>

Reviewed by BJ Burg.

  • UserInterface/Views/LocalJSONContentView.js:

(WI.LocalJSONContentView.prototype.renderRemoteObject):
If the WI.RemoteObject is simple enough to be rendered inline, WI.ObjectTreeView won't
show a WI.TreeOutline by default. We have to tell it to use a WI.TreeOutline by passing
forceExpanding = true into the constructor.

  • UserInterface/Views/ObjectTreeView.js:

(WI.ObjectTreeView.prototype.showOnlyJSON):
Add some console.assert to help prevent this from happening again.

10:59 AM Changeset in webkit [276264] by Manuel Rego Casasnovas
  • 27 edits
    1 delete in trunk

[selectors] Script focus and :focus-visible
https://bugs.webkit.org/show_bug.cgi?id=224598

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update expectations as the tests pass now.

  • web-platform-tests/css/selectors/focus-visible-008-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-009-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-010-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-014-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-001-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-002.tentative-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-003.tentative-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-004-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-005-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-006.tentative-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-007.tentative-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-012-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-013-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-014-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-015-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-016.tentative-expected.txt:
  • web-platform-tests/css/selectors/focus-visible-script-focus-017.tentative-expected.txt:

Source/WebCore:

Implement :focus-visible behavior when a script moves focus.
An element will match :focus-visible when a script move focus if the last focused element was not focused via mouse click.

This patch makes WebKit behaves like Chromium and Firefox and pass all the related tests.

There's an ongoing discussion about 6 tests that are marked as ".tentative" in the following issue:
https://github.com/web-platform-tests/wpt/issues/28505

Test: web-platform-tests/css/selectors/focus-visible-script-focus-*

  • dom/Document.cpp:

(WebCore::Document::adjustFocusedNodeOnNodeRemoval): Just update FocusOptions initializer.
(WebCore::Document::setFocusedElement): Store if the last element has been focused by mouse click or not.

  • dom/Document.h: New member m_latestFocusTrigger.

(WebCore::Document::wasLastFocusByClick const): Method to check status of m_latestFocusTrigger.

  • dom/Element.cpp:

(WebCore::Element::focus): When there's a script focus, this checks if the last element was focused
by mouse click in order to make it match :focus-visible.

  • dom/FocusOptions.h: Add FocusTrigger enum to know if an element has been focused via mouse click or not.

This refers to the "focus trigger" concept on the HTML spec (see https://html.spec.whatwg.org/multipage/interaction.html).

  • page/EventHandler.cpp:

(WebCore::EventHandler::dispatchMouseEvent): Pass FocusTrigger:Click in setFocusedElement() call.

LayoutTests:

Update expectations for tests, most of them are passing on Mac. On iOS a bunch timeout so they're skipped, as other :focus-visible tests.

  • platform/ios/TestExpectations:
  • platform/mac/imported/w3c/web-platform-tests/css/selectors/focus-visible-009-expected.txt: Removed as test passes now.
  • platform/mac/TestExpectations:
10:53 AM Changeset in webkit [276263] by Chris Dumez
  • 3 edits in trunk/Source/WebKit

Fix races in LibWebRTCCodecs introduced in r276214
https://bugs.webkit.org/show_bug.cgi?id=224758

Reviewed by Youenn Fablet.

After r276214, LibWebRTCCodecs's createDecoder() / createEncoder() may hop to the main
thread to initialize the connection to the GPUProcess. If releaseDecoder() / releaseEncoder()
were to get called very shortly after, they may win the race and have no decoder / encoder
to release, since they are dispatched directly to the background thread. To address the issue,
we now call ensureGPUProcessConnectionAndDispatchToThread() in releaseDecoder(), releaseEncoder()
and initializeEncoder().

  • WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp:

(WebKit::LibWebRTCCodecs::releaseDecoder):
(WebKit::LibWebRTCCodecs::releaseEncoder):
(WebKit::LibWebRTCCodecs::initializeEncoder):

10:51 AM Changeset in webkit [276262] by Darin Adler
  • 10 edits in trunk

Nullptr crash in CSSCalcValue::category() via HTMLConverterCaches::floatPropertyValueForNode
https://bugs.webkit.org/show_bug.cgi?id=221392

Reviewed by Simon Fraser.

LayoutTests/imported/w3c:

  • web-platform-tests/css/css-values/minmax-length-percent-serialize-expected.txt:

Updated to reflect 8 tests passing that were failing before.

Source/WebCore:

  • css/CSSCalculationValue.cpp:

(WebCore::CSSCalcOperationNode::createCalcExpression const): Pass in a destination category
when creating a CalcExpressionOperation.
(WebCore::createCSS): Pass the destination category from the CalcExpressionOperation when
creating a CSSCalcOperationNode.

  • css/CSSCalculationValue.h: Moved the CalculationCategory enumeration from here to

CalculationValue.h.

  • platform/CalculationValue.cpp:

(WebCore::operator==): Include destination category when comparing.

  • platform/CalculationValue.h: Moved CalculationCategory here. Added a destination

category constructor argument, data members, and getter function to the
CalcExpressionOperation class.

LayoutTests:

  • fast/css/calc-parsing-expected.txt: Updated for change below.
  • fast/css/calc-parsing.html: Added more test cases so this covers the affected cases of computed

style for calc expressions that mix percentages and numbers. Alternatively, we could remove this
entire test case because the web platform tests also cover this pretty well.

10:20 AM WebKitGTK/2.32.x edited by clopez@igalia.com
(diff)
10:17 AM Changeset in webkit [276261] by Chris Gambrell
  • 12 edits
    2 adds
    2 deletes in trunk/LayoutTests

[LayoutTests] Convert http/tests/blink convert PHP to Python
https://bugs.webkit.org/show_bug.cgi?id=224702
<rdar://problem/76783504>

Reviewed by Darin Adler.

  • http/tests/blink/sendbeacon/beacon-cookie-expected.txt:
  • http/tests/blink/sendbeacon/beacon-cookie.html:
  • http/tests/blink/sendbeacon/beacon-cross-origin-expected.txt:
  • http/tests/blink/sendbeacon/beacon-cross-origin.html:
  • http/tests/blink/sendbeacon/beacon-cross-origin.https-expected.txt:
  • http/tests/blink/sendbeacon/beacon-cross-origin.https.html:
  • http/tests/blink/sendbeacon/beacon-same-origin-expected.txt:
  • http/tests/blink/sendbeacon/beacon-same-origin.html:
  • http/tests/blink/sendbeacon/resources/check-beacon.php: Removed.
  • http/tests/blink/sendbeacon/resources/check-beacon.py: Added.

(extensive_strip):

  • http/tests/blink/sendbeacon/resources/save-beacon.php: Removed.
  • http/tests/blink/sendbeacon/resources/save-beacon.py: Added.

(prettify):
(decode_multipart):

  • http/tests/resources/portabilityLayer.py:

(get_post_data):
(get_request):

  • platform/ios/http/tests/blink/sendbeacon/beacon-same-origin-expected.txt:
  • platform/mac/http/tests/blink/sendbeacon/beacon-same-origin-expected.txt:
10:08 AM Changeset in webkit [276260] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

CSSValuePool should be non-copyable
https://bugs.webkit.org/show_bug.cgi?id=224764

Reviewed by Alan Bujtas.

  • css/CSSValuePool.h:
9:59 AM Changeset in webkit [276259] by mark.lam@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Build fix for Debug -O3 after r276162.
https://bugs.webkit.org/show_bug.cgi?id=224681
rdar://76698113

Not reviewed.

  • runtime/JSObject.cpp:
9:53 AM Changeset in webkit [276258] by Philippe Normand
  • 2 edits in trunk/LayoutTests

Unreviewed, GLIB gardening

  • platform/glib/TestExpectations: Flag a few more media tests to skip or as flaky crash.
9:46 AM Changeset in webkit [276257] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Add more GPUProcess release logging to facilitate debugging
https://bugs.webkit.org/show_bug.cgi?id=224761

Reviewed by Darin Adler.

  • GPUProcess/GPUProcess.cpp:

(WebKit::GPUProcess::GPUProcess):
(WebKit::GPUProcess::createGPUConnectionToWebProcess):
(WebKit::GPUProcess::removeGPUConnectionToWebProcess):
(WebKit::GPUProcess::initializeGPUProcess):

9:45 AM Changeset in webkit [276256] by Philippe Normand
  • 2 edits in trunk/LayoutTests

Unreviewed, GLIB gardening

  • platform/glib/TestExpectations: Flag imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-implicit.html as flaky crash.
8:41 AM Changeset in webkit [276255] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC] The layout containment box establishes an absolute positioning containing block and a fixed positioning containing block
https://bugs.webkit.org/show_bug.cgi?id=224754

Reviewed by Antti Koivisto.

https://www.w3.org/TR/css-contain-2/#containment-layout.

"The layout containment box establishes an absolute positioning containing block and a fixed positioning containing block."

  • layout/layouttree/LayoutBox.h:

(WebCore::Layout::Box::isContainingBlockForFixedPosition const):
(WebCore::Layout::Box::isContainingBlockForOutOfFlowPosition const):

8:21 AM Changeset in webkit [276254] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC] Layout containment box establishes an independent formatting context
https://bugs.webkit.org/show_bug.cgi?id=224753

Reviewed by Antti Koivisto.

https://www.w3.org/TR/css-contain-2/#containment-layout.

"The layout containment box establishes an independent formatting context."

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::establishesIndependentFormattingContext const):

8:18 AM Changeset in webkit [276253] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore

Silence various -Wreturn-type warnings
https://bugs.webkit.org/show_bug.cgi?id=224756

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-04-19
Reviewed by Don Olmstead.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::mixColorComponents):

  • inspector/InspectorOverlay.cpp:

(WebCore::expectedSizeForLayoutLabel):

  • rendering/style/RenderStyle.cpp:

(WebCore::RenderStyle::usedClear):
(WebCore::RenderStyle::usedFloat):

7:16 AM Changeset in webkit [276252] by Wenson Hsieh
  • 2 edits in trunk/Source/WebCore

Unreviewed, fix the build after r276181
<rdar://problem/76832595>

Add a couple of missing forward declarations for IntRect and IntPoint.

  • page/ContextMenuClient.h:
6:54 AM Changeset in webkit [276251] by youenn@apple.com
  • 3 edits in trunk/Source/WebCore

Add assertions to check for no memory allocation in AudioMediaStreamTrackRendererUnit rendering thread
https://bugs.webkit.org/show_bug.cgi?id=224674

Reviewed by Eric Carlson.

Add ForbidMallocUseForCurrentThreadScope in audio rendering code path to prevent memory allocation.
Rename inputProc to renderingCallback.
Remove use of AudioMediaStreamTrackRendererUnit::singleton and instead use the pointer given to renderingCallback.
This is safe as AudioMediaStreamTrackRendererUnit destructor stops the audio unit.

  • platform/mediastream/mac/AudioMediaStreamTrackRendererUnit.cpp:

(WebCore::AudioMediaStreamTrackRendererUnit::createAudioUnitIfNeeded):
(WebCore::AudioMediaStreamTrackRendererUnit::render):
(WebCore::AudioMediaStreamTrackRendererUnit::renderingCallback):
(WebCore::AudioMediaStreamTrackRendererUnit::inputProc): Deleted.

  • platform/mediastream/mac/AudioMediaStreamTrackRendererUnit.h:
6:43 AM Changeset in webkit [276250] by Philippe Normand
  • 2 edits in trunk/Tools

Unreviewed, WPE Minibrowser build warning fix.

  • MiniBrowser/wpe/main.cpp: No need to use typedef for this struct declaration.
6:28 AM Changeset in webkit [276249] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC] Implement Box::isLayoutContainmentBox
https://bugs.webkit.org/show_bug.cgi?id=224740

Reviewed by Antti Koivisto.

This is part of https://www.w3.org/TR/css-contain-2/#containment-layout

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::isLayoutContainmentBox const):
(WebCore::Layout::Box::isInternalTableBox const):

  • layout/layouttree/LayoutBox.h:

(WebCore::Layout::Box::isInternalRubyBox const):

6:22 AM Changeset in webkit [276248] by Philippe Normand
  • 4 edits
    39 moves
    15 adds in trunk/LayoutTests

Unreviewed, WPE gardening

Share more media tests baselines between the GTK and WPE ports.

  • platform/glib/TestExpectations:
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-implicit-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-implicit-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-negative-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-negative-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-without-codecs-parameter-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-changetype-play-without-codecs-parameter-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-duration-boundaryconditions-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-duration-boundaryconditions-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-getvideoplaybackquality-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-getvideoplaybackquality-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-is-type-supported-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-is-type-supported-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-remove-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-remove-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-removesourcebuffer-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-removesourcebuffer-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/media-source/mediasource-sourcebuffer-mode-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/media-source/mediasource-sourcebuffer-mode-expected.txt.
  • platform/glib/media/W3C/video/canPlayType/canPlayType_codecs_order_1-expected.txt: Renamed from LayoutTests/platform/gtk/media/W3C/video/canPlayType/canPlayType_codecs_order_1-expected.txt.
  • platform/glib/media/W3C/video/canPlayType/canPlayType_supported_but_no_codecs_parameter_1-expected.txt: Renamed from LayoutTests/platform/gtk/media/W3C/video/canPlayType/canPlayType_supported_but_no_codecs_parameter_1-expected.txt.
  • platform/glib/media/W3C/video/canPlayType/canPlayType_two_implies_one_1-expected.txt: Renamed from LayoutTests/platform/gtk/media/W3C/video/canPlayType/canPlayType_two_implies_one_1-expected.txt.
  • platform/glib/media/W3C/video/canPlayType/canPlayType_two_implies_one_2-expected.txt: Renamed from LayoutTests/platform/gtk/media/W3C/video/canPlayType/canPlayType_two_implies_one_2-expected.txt.
  • platform/glib/media/audio-controls-rendering-expected.png: Renamed from LayoutTests/platform/gtk/media/audio-controls-rendering-expected.png.
  • platform/glib/media/audio-repaint-expected.png: Renamed from LayoutTests/platform/gtk/media/audio-repaint-expected.png.
  • platform/glib/media/context-menu-actions-expected.txt: Renamed from LayoutTests/platform/gtk/media/context-menu-actions-expected.txt.
  • platform/glib/media/controls-after-reload-expected.png: Renamed from LayoutTests/platform/gtk/media/controls-after-reload-expected.png.
  • platform/glib/media/controls-layout-direction-expected.png: Renamed from LayoutTests/platform/gtk/media/controls-layout-direction-expected.png.
  • platform/glib/media/controls-strict-expected.png: Renamed from LayoutTests/platform/gtk/media/controls-strict-expected.png.
  • platform/glib/media/controls-styling-expected.png: Renamed from LayoutTests/platform/gtk/media/controls-styling-expected.png.
  • platform/glib/media/controls-styling-strict-expected.png: Renamed from LayoutTests/platform/gtk/media/controls-styling-strict-expected.png.
  • platform/glib/media/controls-without-preload-expected.png: Renamed from LayoutTests/platform/gtk/media/controls-without-preload-expected.png.
  • platform/glib/media/media-can-play-ogg-expected.txt: Renamed from LayoutTests/platform/gtk/media/media-can-play-ogg-expected.txt.
  • platform/glib/media/media-controls-clone-expected.png: Renamed from LayoutTests/platform/gtk/media/media-controls-clone-expected.png.
  • platform/glib/media/media-document-audio-repaint-expected.png: Renamed from LayoutTests/platform/gtk/media/media-document-audio-repaint-expected.png.
  • platform/glib/media/media-fullscreen-inline-expected.txt: Renamed from LayoutTests/platform/gtk/media/media-fullscreen-inline-expected.txt.
  • platform/glib/media/media-fullscreen-not-in-document-expected.txt: Renamed from LayoutTests/platform/gtk/media/media-fullscreen-not-in-document-expected.txt.
  • platform/glib/media/media-source/media-source-resize-expected.txt: Renamed from LayoutTests/platform/gtk/media/media-source/media-source-resize-expected.txt.
  • platform/glib/media/video-canvas-alpha-expected.png: Renamed from LayoutTests/platform/gtk/media/video-canvas-alpha-expected.png.
  • platform/glib/media/video-controls-rendering-expected.png: Renamed from LayoutTests/platform/gtk/media/video-controls-rendering-expected.png.
  • platform/glib/media/video-display-toggle-expected.png: Renamed from LayoutTests/platform/gtk/media/video-display-toggle-expected.png.
  • platform/glib/media/video-empty-source-expected.png: Renamed from LayoutTests/platform/gtk/media/video-empty-source-expected.png.
  • platform/glib/media/video-no-audio-expected.png: Renamed from LayoutTests/platform/gtk/media/video-no-audio-expected.png.
  • platform/glib/media/video-playing-and-pause-expected.png: Renamed from LayoutTests/platform/gtk/media/video-playing-and-pause-expected.png.
  • platform/glib/media/video-playing-and-pause-expected.txt: Renamed from LayoutTests/platform/gtk/media/video-playing-and-pause-expected.txt.
  • platform/glib/media/video-volume-slider-expected.png: Renamed from LayoutTests/platform/gtk/media/video-volume-slider-expected.png.
  • platform/glib/media/video-zoom-controls-expected.png: Renamed from LayoutTests/platform/gtk/media/video-zoom-controls-expected.png.
  • platform/glib/media/video-zoom-expected.png: Renamed from LayoutTests/platform/gtk/media/video-zoom-expected.png.
  • platform/glib/media/video-zoom-expected.txt: Renamed from LayoutTests/platform/gtk/media/video-zoom-expected.txt.
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
  • platform/wpe/media/video-aspect-ratio-expected.txt: Added.
  • platform/wpe/media/video-canvas-createPattern-expected.png: Added.
  • platform/wpe/media/video-colorspace-yuv420-expected.png: Added.
  • platform/wpe/media/video-colorspace-yuv420-expected.txt: Added.
  • platform/wpe/media/video-colorspace-yuv422-expected.png: Added.
  • platform/wpe/media/video-colorspace-yuv422-expected.txt: Added.
  • platform/wpe/media/video-frame-accurate-seek-expected.png: Added.
  • platform/wpe/media/video-frame-accurate-seek-expected.txt: Added.
  • platform/wpe/media/video-layer-crash-expected.txt: Added.
  • platform/wpe/media/video-transformed-expected.txt: Added.
6:12 AM Changeset in webkit [276247] by commit-queue@webkit.org
  • 24 edits
    3 adds in trunk

Enable -Wthread-safety, add attributes to custom lock classes, and provide macros to declare guards
https://bugs.webkit.org/show_bug.cgi?id=221614
<rdar://problem/74396781>

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-04-19
Reviewed by David Kilzer.

PerformanceTests:

Add -Wthread-safety to compile flags.

  • DecoderTest/Configurations/Base.xcconfig:

Source/bmalloc:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/JavaScriptCore:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/WebCore:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/WebCore/PAL:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/WebInspectorUI:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/WebKit:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/WebKitLegacy/mac:

Add -Wthread-safety to compile flags.

  • Configurations/Base.xcconfig:

Source/WTF:

Implement rudimentary support for clang thread safety analysis.
The added macros can be used to declare which member variables or
global variables are locked by which mutexes. The compiler will
check statically that the mutexes are held correctly. The checking
is intra procedural, not global.

  • Configurations/Base.xcconfig:

Add -Wthread-safety to compile flags.

  • wtf/CheckedLock.h: Added.

Add CheckedLock, a Lock variant that is amenable to static
analysis.
Add a Locker specialization for CheckedLock that is amenable to
static analysis.

Locker<CheckedLock> is a std::scoped_lock. The scoped_lock cannot be aliased,
since it appears that (Apple's) libcxx is not compiled with thread safety
analysis support enabled by default.

New types are needed due Locker move constructor and conditional locking.
The Locker has default usage pattern of:

auto locker = holdLock(m_lock);

This forces dynamism that removes the possibility of simple statical
analysis that thread safety analysis capabilities "mutex" and "scoped_lock"
currently implement. Most likely large fraction of call sites is due to historical
lack of CTAD and as such can be converted to less general form.
Once the pattern is not used by default, CheckedLock can be deleted
and the move dynamism bits of Locker can be moved to some more specific type
("UncheckedLocker").

  • wtf/ThreadSafetyAnalysis.h: Added.

Add macro wrappers around clang "mutex" and "scoped_lock" capability attributes.

Tools:

  • TestWebKitAPI/Configurations/Base.xcconfig:

Add -Wthread-safety to compile flags.

  • TestWebKitAPI/CMakeLists.txt:
  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WTF/CheckedLock.cpp: Added.

(TestWebKitAPI::TEST):
Implement a test for testing that CheckedLock compiles.

4:55 AM Changeset in webkit [276246] by Carlos Garcia Campos
  • 2 edits in trunk

[GTK] Switch to libsoup3 by default
https://bugs.webkit.org/show_bug.cgi?id=224741

Reviewed by Sergio Villar Senin.

  • Source/cmake/OptionsGTK.cmake:
3:28 AM Changeset in webkit [276245] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

Make RealtimeIncomingAudioSourceCocoa preallocate audio buffer
https://bugs.webkit.org/show_bug.cgi?id=224672

Reviewed by Eric Carlson.

Instead of allocating the buffer on valid data, we wait for data to be of the correct sample rate.
We preallocate the buffer accordingly in constructor to avoid allocation in the webrtc audio thread.
Default is 1 channel since mono is what webrtc encoders mostly do these days.
Covered by existing tests.

  • platform/mediastream/mac/RealtimeIncomingAudioSourceCocoa.cpp:

(WebCore::RealtimeIncomingAudioSourceCocoa::RealtimeIncomingAudioSourceCocoa):
(WebCore::RealtimeIncomingAudioSourceCocoa::OnData):

2:56 AM Changeset in webkit [276244] by youenn@apple.com
  • 4 edits in trunk/Source/WebCore

Move from RecursiveLock to Lock in RealtimeMediaSource
https://bugs.webkit.org/show_bug.cgi?id=224671

Reviewed by Eric Carlson.

RecursiveLock is more expensive as it allocates memory and not useful here.
Covered by existing tests.

  • platform/mediastream/RealtimeMediaSource.h:
  • platform/mediastream/RealtimeOutgoingAudioSource.h:
  • platform/mediastream/RealtimeOutgoingVideoSource.h:
2:53 AM Changeset in webkit [276243] by youenn@apple.com
  • 9 edits in trunk/Source/WebCore

Reduce crackling at start of playing a live audio track
https://bugs.webkit.org/show_bug.cgi?id=218898
<rdar://problem/71625010>

Reviewed by Eric Carlson.

We often hear crackles at the beginning of playing a MediaStreamTrack.
This is due to starting at a point where there is not enough data, so we start rendering and quickly run short of data.
Our heuristic to start was not good since we were not accounting to LibWebRTC audio module which sends audio samples by batch of 5 samples.
So we would have needed to at least have 6 samples to be sure to not run out of data.

What this patch does:

  • Add an extra parameter to AudioSampleDataSource so that we do not start until we have at least been pushed a given number of sample count.
  • Change LibWebRTAudioModule to send audio samples by batch of 3 (hence 30 ms) instead of 5
  • Set this new parameter to 2 for local tracks and 4 for remote tracks
  • Add a new boolean to AudioSampleDataSource to know whether we start the track for the first time or not. If we start it, use the new parameter to buffer enough data. Otherwise, use current heuristic.

We also reduce the AudioSampleDataSource buffer to 0.5 seconds instead of 2 seconds, since 2 seconds is too much for real time audio.

Manually tested.

  • platform/audio/cocoa/AudioSampleDataSource.h:
  • platform/audio/cocoa/AudioSampleDataSource.mm:

(WebCore::AudioSampleDataSource::create):
(WebCore::AudioSampleDataSource::AudioSampleDataSource):
(WebCore::AudioSampleDataSource::pullSamplesInternal):

  • platform/mediastream/libwebrtc/LibWebRTCAudioModule.cpp:

(WebCore::LibWebRTCAudioModule::pollFromSource):

  • platform/mediastream/libwebrtc/LibWebRTCAudioModule.h:
  • platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.cpp:

(WebCore::pollSamplesCount):
(WebCore::AudioMediaStreamTrackRendererCocoa::pushSamples):

  • platform/mediastream/mac/MediaStreamTrackAudioSourceProviderCocoa.cpp:

(WebCore::MediaStreamTrackAudioSourceProviderCocoa::MediaStreamTrackAudioSourceProviderCocoa):

  • platform/mediastream/mac/WebAudioSourceProviderCocoa.h:
  • platform/mediastream/mac/WebAudioSourceProviderCocoa.mm:

(WebCore::WebAudioSourceProviderCocoa::prepare):

2:49 AM Changeset in webkit [276242] by youenn@apple.com
  • 5 edits
    13 moves
    17 adds
    2 deletes in trunk/LayoutTests

Migrate some WebRTC encoded transform tests to WPT
https://bugs.webkit.org/show_bug.cgi?id=224604

Reviewed by Eric Carlson.

LayoutTests/imported/w3c:

  • web-platform-tests/webrtc-encoded-transform/routines.js: Added.

(async createConnections):
(waitFor):

  • web-platform-tests/webrtc-encoded-transform/script-audio-transform-worker.js: Added.

(MockRTCRtpTransformer):
(MockRTCRtpTransformer.prototype.start):
(MockRTCRtpTransformer.prototype.process):
(onrtctransform):

  • web-platform-tests/webrtc-encoded-transform/script-audio-transform.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/script-audio-transform.https.html: Renamed from LayoutTests/http/wpt/webrtc/audio-script-transform.html.
  • web-platform-tests/webrtc-encoded-transform/script-change-transform-worker.js: Renamed from LayoutTests/http/wpt/webrtc/change-encoded-transform.js.
  • web-platform-tests/webrtc-encoded-transform/script-change-transform.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/script-change-transform.https.html: Renamed from LayoutTests/http/wpt/webrtc/change-encoded-transform.html.
  • web-platform-tests/webrtc-encoded-transform/script-late-transform.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/script-late-transform.https.html: Renamed from LayoutTests/http/wpt/webrtc/webrtc-late-transform.html.
  • web-platform-tests/webrtc-encoded-transform/script-metadata-transform-worker.js: Renamed from LayoutTests/http/wpt/webrtc/metadata-transform-worker.js.
  • web-platform-tests/webrtc-encoded-transform/script-metadata-transform.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/script-metadata-transform.https.html: Renamed from LayoutTests/http/wpt/webrtc/metadata-transform.html.
  • web-platform-tests/webrtc-encoded-transform/script-transform-worker.js: Renamed from LayoutTests/http/wpt/webrtc/script-transform.js.
  • web-platform-tests/webrtc-encoded-transform/script-transform.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/script-transform.https.html: Renamed from LayoutTests/http/wpt/webrtc/webrtc-transform.html.
  • web-platform-tests/webrtc-encoded-transform/script-write-twice-transform-worker.js: Renamed from LayoutTests/http/wpt/webrtc/write-twice-transform.js.
  • web-platform-tests/webrtc-encoded-transform/script-write-twice-transform.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/script-write-twice-transform.https.html: Renamed from LayoutTests/http/wpt/webrtc/write-twice-transform.html.
  • web-platform-tests/webrtc-encoded-transform/sframe-keys.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-keys.https.html: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-buffer-source-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-buffer-source.html: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-in-worker.https-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-in-worker.https.html: Renamed from LayoutTests/http/wpt/webrtc/sframe-transform-in-worker.html.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-readable-expected.txt: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-readable.html: Added.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform-worker.js: Renamed from LayoutTests/http/wpt/webrtc/sframe-transform.js.
  • web-platform-tests/webrtc-encoded-transform/sframe-transform.html: Renamed from LayoutTests/http/wpt/webrtc/sframe-transform.html.

LayoutTests:

  • http/wpt/webrtc/sframe-transform-readable-crash.html: Removed.
  • platform/glib/TestExpectations:
  • platform/ios-wk1/TestExpectations:
  • platform/mac-wk1/TestExpectations:
  • webrtc/script-transform.js: Removed.
2:03 AM Changeset in webkit [276241] by imanol
  • 3 edits in trunk/Source/WebCore

Enable GL_ANGLE_instanced_arrays WebGL extension in WPE
https://bugs.webkit.org/show_bug.cgi?id=224438

Reviewed by Darin Adler.

Tested by WebGL WPT.

  • html/canvas/ANGLEInstancedArrays.cpp:

(WebCore::ANGLEInstancedArrays::supported):

  • platform/graphics/opengl/ExtensionsGLOpenGLES.cpp:

(WebCore::ExtensionsGLOpenGLES::supportsExtension):

1:58 AM CSSContainment edited by rwlbuis@webkit.org
(diff)
1:39 AM Changeset in webkit [276240] by commit-queue@webkit.org
  • 4 edits in trunk

[css-flexbox] Table layout disregards overriding height
https://bugs.webkit.org/show_bug.cgi?id=224665

Patch by Felipe Erias <Felipe Erias> on 2021-04-19
Reviewed by Sergio Villar Senin.

Source/WebCore:

Update table layout to take into account the overriding height set by the element's parent.
This was causing several WPT tests to fail.

  • rendering/RenderTable.cpp:

(WebCore::RenderTable::layout):
During layout, set the computed height so that it is at least as large as the overriding height
provided by the element's parent (if any) minus the height that will be taken up by captions.
This additional height will be distributed among the table's sections so its total height matches
the overriding value.

LayoutTests:

1:23 AM Changeset in webkit [276239] by Martin Robinson
  • 4 edits in trunk/Source/WebCore

[css-scroll-snap] Properly support fractional scroll steps in WebCore::ScrollAnimator::scroll
https://bugs.webkit.org/show_bug.cgi?id=224176

Reviewed by Simon Fraser.

Stop using the ScrollableArea's position to calculate scroll snap positions in ScrollAnimator::snap.
The position stored in ScrollAnimator is a floating point position, while the one stored in ScrollableArea
is an integer position. This currently isn't an issue, because all callers of ScrollAnimator::scroll
use integer scroll offsets, but this will allow this function to be used in the future for precise
scrolling delta.

No new tests. This doesn't change any behavior, since all callers currently use
integer scroll offsets, but a future change will make use of this fix.

  • platform/ScrollAnimator.cpp:

(WebCore::ScrollAnimator::scroll): Get the current scroll position from the ScrollAnimator,
which stores it in floating point. Also, only call into the scroll snap code if we actually
have scroll offsets.
(WebCore::ScrollAnimator::offsetFromPosition): Added this helper.
(WebCore::ScrollAnimator::positionFromOffset): Ditto.
(WebCore::ScrollAnimator::deltaFromStep): Return a delta instead of a position so this helper
can be used with offsets or positions.
(WebCore::ScrollAnimator::positionFromStep): Deleted.

  • platform/ScrollAnimator.h:
  • platform/mac/ScrollAnimatorMac.mm:

(WebCore::ScrollAnimatorMac::scroll): Use the new helper.j

1:16 AM Changeset in webkit [276238] by Philippe Normand
  • 11 edits in trunk

[WPE][GTK] Enable AVIF decoder as experimental feature and unskip tests
https://bugs.webkit.org/show_bug.cgi?id=224663

Reviewed by Xabier Rodriguez-Calvar.

.:

Make the USE_AVIF option public and enable it as experimental feature.

  • Source/cmake/OptionsGTK.cmake:
  • Source/cmake/OptionsWPE.cmake:

Source/WebCore:

Refactor the AVIF build options out of the GTK port so they can be reused by other CMake ports.

  • PlatformGTK.cmake:
  • platform/ImageDecoders.cmake:
  • platform/image-decoders/avif/AVIFImageDecoder.cpp:
  • platform/image-decoders/avif/AVIFImageReader.cpp:
  • platform/image-decoders/avif/AVIFUniquePtr.h:

LayoutTests:

  • platform/gtk/TestExpectations: Unskip avif tests.
12:46 AM BuildingCairoOnWindows edited by Fujii Hironori
(diff)
Note: See TracTimeline for information about the timeline view.