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

Timeline



Feb 28, 2022:

11:47 PM Changeset in webkit [290631] by Diego Pino Garcia
  • 2 edits in trunk/Source/WebCore

[GTK] Unreviewed, non-unified build fix after 247791@main

  • platform/graphics/gbm/GBMDevice.h:
11:46 PM Changeset in webkit [290630] by Tyler Wilcock
  • 9 edits
    3 adds in trunk

AX: WebKit should ignore empty modals rather than trapping focus inside them
https://bugs.webkit.org/show_bug.cgi?id=237163

Reviewed by Chris Fleizach and Andres Gonzalez.

Source/WebCore:

Given this markup:

<div role="dialog" aria-modal="true">

<div aria-hidden="true">

<button>Close modal (inside modal)</button>

</div>

</div>

There is no accessible content inside this modal, but WebKit traps user focus inside,
making the rest of the page completely inaccessible.

With this patch we ignore modals that don't have accessible content.
We do this by walking the DOM to find any non-AX-ignored objects.

Because determining whether or not an element is ignored is dependent
on modals present on the page, this patch moves the call to ignoredFromModalPresence
out of AccessibilityObject::defaultObjectInclusion, as this function is
downstream of computeAccessibilityIsIgnored, and we need to call
that on objects inside modal candidates. Without this move, we would
recurse infinitely in AXObjectCache::modalElementHasAccessibleContent.

We now check whether an object is ignored due to modal presence in
AccessibilityObject::accessibilityIsIgnored(), so that function should
be used as the final say in determining whether an object is ignored.

Test: accessibility/ignore-modals-without-any-content.html

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::modalElementHasAccessibleContent):
(WebCore::AXObjectCache::currentModalNode):

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

(WebCore::AccessibilityObject::defaultObjectInclusion const):
(WebCore::AccessibilityObject::accessibilityIsIgnored const):

  • accessibility/AccessibilityObject.h:

(WebCore::AccessibilityObject::computeAccessibilityIsIgnored const):

LayoutTests:

  • accessibility/ignore-modals-without-any-content-expected.txt: Added.
  • accessibility/ignore-modals-without-any-content.html: Added.
  • platform/glib/TestExpectations: Skip new test.
  • platform/ios/TestExpectations: Enable new test.
  • platform/ios/accessibility/ignore-modals-without-any-content-expected.txt: Added.
  • platform/win/TestExpectations: Skip new test.
10:12 PM Changeset in webkit [290629] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

[IPC] Do more hardening in WebSWServerConnection's client registration / unregistration
https://bugs.webkit.org/show_bug.cgi?id=237290
<rdar://88903506>

Reviewed by Alex Christensen.

Validate client identifiers sent by the WebContent process via IPC to make sure that the
process identifier of the client actually matches the process identifier of the process
we're connected to.

Also validate the SecurityOriginData to make sure it is not empty. We support sending
empty SecurityOriginData objects over IPC. However, they cannot be used as keys in
HashMaps.

If validation fails, we assume the WebContent process is compromised and we terminate it.

  • NetworkProcess/ServiceWorker/WebSWServerConnection.cpp:

(WebKit::WebSWServerConnection::registerServiceWorkerClient):
(WebKit::WebSWServerConnection::unregisterServiceWorkerClient):

8:54 PM Changeset in webkit [290628] by Simon Fraser
  • 4 edits
    6 adds in trunk

Compositing/paint invalidation with transforms
https://bugs.webkit.org/show_bug.cgi?id=233421
<rdar://problem/85814854>

Reviewed by Alan Bujtas.

Source/WebCore:

When changing transform from something like translate(0) to `translate3d(0, 0, 0)
scale(0.5, 0.5)`, we trigger compositing, and thus need to repaint the previous rect of the
layer in its old repaint container. However, the existing code would take the new transform
into account when computing that rect, thus dirtying a rect that is too small.

To fix this, we need to use the cached repaint rects on RenderLayer for this repaint.
However, doing so revealed a bug (via
compositing/shared-backing/repaint-into-shared-backing.html) in how we compute repaint
cached repaint rects in the presence of shared backing. During a compositing update, if a
layer's composited state changed, we'd call computeRepaintRectsIncludingDescendants(), which
computes rect relative to the layer's repaint container. But at this time, the state of
backing sharing in BackingSharingState is in flux (we essentially don't know yet if a layer
can use shared backing). So we may compute and cache repaint rects relative to the wrong
container.

To fix this, leverage the existing m_layersPendingRepaint logic, and delay computing the
repaint rects until we've established our final backing sharing configuration.

Tests: compositing/repaint/composite-and-scale-change.html

compositing/shared-backing/repaint-into-shared-backing-become-composited.html

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::setBackingProviderLayer):
(WebCore::RenderLayer::calculateClipRects const):

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::BackingSharingState::issuePendingRepaints):
(WebCore::RenderLayerCompositor::updateBacking):

LayoutTests:

  • compositing/repaint/composite-and-scale-change-expected.txt: Added.
  • compositing/repaint/composite-and-scale-change.html: Added.

Test that dumps repaint rects.

  • compositing/shared-backing/repaint-into-shared-backing-become-composited-expected.html: Added.
  • compositing/shared-backing/repaint-into-shared-backing-become-composited.html: Added.

Companion to repaint-into-shared-backing.html but toggles compositing in the other
direction.

  • platform/gtk/compositing/repaint/composite-and-scale-change-actual.txt: Added.
  • platform/mac-wk1/compositing/repaint/composite-and-scale-change-expected.txt: Added.
7:24 PM Changeset in webkit [290627] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

Fix use-after-move bug in NetworkResourceLoader
https://bugs.webkit.org/show_bug.cgi?id=237294

Patch by Alex Christensen <achristensen@webkit.org> on 2022-02-28
Reviewed by Chris Dumez.

Luckily, they were just two booleans, and after you call std::move on a bool you get
technically undefined behavior. Luckily, in practice the bool value is unchanged.
We don't need to rely on that, though. Let's read from the location with defined behavior.

  • NetworkProcess/NetworkResourceLoader.cpp:
7:13 PM Changeset in webkit [290626] by Ross Kirsling
  • 2 edits in trunk/Source/WebKit

REGRESSION(r290470): CDMInstanceSession::setLogIdentifier must be guarded with !RELEASE_LOG_DISABLED
https://bugs.webkit.org/show_bug.cgi?id=237302

Unreviewed build fix.

  • GPUProcess/media/RemoteCDMInstanceSessionProxy.cpp:

(WebKit::RemoteCDMInstanceSessionProxy::setLogIdentifier):

7:00 PM Changeset in webkit [290625] by Simon Fraser
  • 10 edits in trunk

No animation when scroll snap scroller is navigated with the keyboard
https://bugs.webkit.org/show_bug.cgi?id=236244

Reviewed by Tim Horton.

Source/WebCore:

Keyboard-driven scrolls in overflow didn't animate, simply because scrollAnimatorEnabled()
wasn't implemented for RenderLayerScrollableArea.

I could not figure out a reliable way to test that we animated the scroll.

  • rendering/RenderLayerScrollableArea.cpp:

(WebCore::RenderLayerScrollableArea::scrollAnimatorEnabled const):

  • rendering/RenderLayerScrollableArea.h:

Tools:

In fixing this bug I ran into the issue predicted in https://bugs.webkit.org/show_bug.cgi?id=234456#c6.
As a workaround, explicitly set NSScrollAnimationEnabled to NO in both processes. This is a partial revert
of r287228 which I tried, and failed to fix via bug 234488.

  • WebKitTestRunner/InjectedBundle/mac/InjectedBundleMac.mm:

(WTR::InjectedBundle::platformInitialize):

  • WebKitTestRunner/mac/main.mm:

(setDefaultsToConsistentValuesForTesting):

LayoutTests:

Turn off the scroll animator for these tests that assume that scrolling is instantaneous.

  • css3/scroll-snap/scroll-padding-overflow-paging.html:
  • fast/events/wheelevent-in-scrolling-div.html:
  • tiled-drawing/scrolling/scroll-snap/scroll-snap-proximity-overflow-rtl-with-keyboard.html:
6:38 PM Changeset in webkit [290624] by Robert Jenner
  • 2 edits in trunk/LayoutTests

[ iOS ] fast/mediastream/video-rotation-gpu-process-crash.html is a flaky crash
https://bugs.webkit.org/show_bug.cgi?id=237295

Unreviewed test gardening.

Patch by Matteo Flores <Matteo Flores> on 2022-02-28

  • platform/ios/TestExpectations:
6:34 PM Changeset in webkit [290623] by sihui_liu@apple.com
  • 5 edits in trunk/Source/WebKit

[macOS] TestWebKitAPI.WebKit.MigrateLocalStorageDataToGeneralStorageDirectory is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=237065
<rdar://problem/89324250>

Reviewed by Darin Adler.

Revert r290544 as it does not fully fix the flaky test. The flakiness is caused by network process exiting
before transactions of SQLiteStorageArea are committed. In NetworkProcess::destroySession, we schedule a
background task to commit transactions in the session, and remove session. In NetworkProcess::didClose, for
existing sessions, we schedule tasks to commit transaction and wait until the tasks are finished before exiting
network process. That means for a session, when NetworkProcess::destroySession is called before
NetworkProcess::didClose, process may exit before commit task (scheduled by NetworkProcess::destroySession) is
finished (NetworkProcess::didClose does not wait because session is already removed).

To solve this issue, let NetworkProcess::didClose check existing NetworkStorageManagers, instead of
NetworkSessions. NetworkStorageManager can outlive NetworkSession when it's finishing cleanup task
(including committing transactions) on its background thread; we want to ensure process exits after the cleanup
task is done.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::didClose):

  • NetworkProcess/storage/NetworkStorageManager.cpp:

(WebKit::allNetworkStorageManagers):
(WebKit::NetworkStorageManager::forEach):
(WebKit::NetworkStorageManager::NetworkStorageManager):
(WebKit::NetworkStorageManager::~NetworkStorageManager):

  • NetworkProcess/storage/NetworkStorageManager.h:
  • NetworkProcess/storage/SQLiteStorageArea.cpp:

(WebKit::SQLiteStorageArea::SQLiteStorageArea):
(WebKit::SQLiteStorageArea::startTransactionIfNecessary):
(WebKit::SQLiteStorageArea::commitTransactionIfNecessary):
(WebKit::commitTransactionsAtExit): Deleted.

5:03 PM Changeset in webkit [290622] by Robert Jenner
  • 4 edits in trunk/LayoutTests

REBASELINE [ iOS15 ] fast/text/khmer-lao-font.html is a constant text failure
<rdar://88841324>

Unreviewed test gardening. Rebaseline for iOS15.

  • platform/ios-wk2/TestExpectations:
  • platform/ios-wk2/fast/text/khmer-lao-font-expected.txt:
  • platform/ios/fast/text/khmer-lao-font-expected.txt:
4:59 PM Changeset in webkit [290621] by jer.noble@apple.com
  • 17 edits in trunk/Source

[Cocoa] Adopt -streamDataParser:didProvideContentKeySpecifier:forTrackID: delegate callback
https://bugs.webkit.org/show_bug.cgi?id=236109
<rdar://problem/88785844>

Reviewed by Eric Carlson.

Source/WebCore:

Re-land support after a rollout in r290311, this time with an off-by-default Experimental Feature
flag.

In addition to checking whether the renderer classes support AVContentKeySession, also check whether
the RuntimeSetting has been enabled. This requires passing that setting through to the
MediaSessionManagerCocoa singleton, so it can be accessed from platform/.

If the renderer support check succeeds and the setting is enabled, only then should the delegate for
AVStreamDataParser include support for the new -didProvideContentKeySpecifier callback. Subclass the
WebAVStreamDataParserListener into a new WebAVStreamDataParserWithKeySpecifierListener object, and
instantiate one or the other according to the support checks above.

  • page/RuntimeEnabledFeatures.cpp:

(WebCore::RuntimeEnabledFeatures::setSampleBufferContentKeySessionSupportEnabled):

  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::sampleBufferContentKeySessionSupportEnabled const):

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

(WebCore::MediaSessionManagerCocoa::setSampleBufferContentKeySessionSupportEnabled):
(WebCore::MediaSessionManagerCocoa::sampleBufferContentKeySessionSupportEnabled):

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

(-[WebAVStreamDataParserWithKeySpecifierListener streamDataParser:didProvideContentKeySpecifier:forTrackID:]):
(WebCore::SourceBufferParserAVFObjC::SourceBufferParserAVFObjC):
(-[WebAVStreamDataParserListener streamDataParser:didProvideContentKeySpecifier:forTrackID:]): Deleted.

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

(WebCore::sampleBufferRenderersSupportKeySession):

Source/WebKit:

Pass the new RuntimeEnabledFeature through to the GPU process.

  • GPUProcess/GPUProcess.cpp:

(WebKit::GPUProcess::setSampleBufferContentKeySessionSupportEnabled):

  • GPUProcess/GPUProcess.h:
  • GPUProcess/GPUProcess.messages.in:
  • GPUProcess/GPUProcessCreationParameters.cpp:

(WebKit::GPUProcessCreationParameters::encode const):
(WebKit::GPUProcessCreationParameters::decode):

  • GPUProcess/GPUProcessCreationParameters.h:
  • UIProcess/GPU/GPUProcessProxy.cpp:

(WebKit::GPUProcessProxy::updatePreferences):

  • UIProcess/GPU/GPUProcessProxy.h:

Source/WTF:

  • Scripts/Preferences/WebPreferencesExperimental.yaml:
4:14 PM Changeset in webkit [290620] by Wenson Hsieh
  • 10 edits in trunk/Tools

Add API testing infrastructure for "Markup Image" and "Copy Cropped Image"
https://bugs.webkit.org/show_bug.cgi?id=236519
rdar://89154213

Reviewed by Tim Horton.

Add API testing support (as well as a new API test) for the "Markup Image" flow.

  • TestWebKitAPI/Tests/WebKitCocoa/ImageAnalysisTests.mm:

(TestWebKitAPI::TEST):
(TestWebKitAPI::invokeImageMarkupAction):

  • TestWebKitAPI/Tests/WebKitCocoa/WKContentViewEditingActions.mm:

Add an API test that triggers the "Markup Image" action, and verifies the following:

  • The first image is replaced with the canned image result (a 215-px-wide image of the WebKit logo).
  • The selection range is effectively unchanged.
  • TestWebKitAPI/cocoa/ImageAnalysisTestingUtilities.h:
  • TestWebKitAPI/cocoa/ImageAnalysisTestingUtilities.mm:

Add a declaration for ImageAnalysisMarkupSwizzler, a helper class that is used in the new API test to make
VisionKit return a canned image and cropped rect when invoking the SPI that corresponds to "Markup Image"; see
WebKitAdditions change for more information.

  • TestWebKitAPI/cocoa/TestWKWebView.h:
  • TestWebKitAPI/cocoa/TestWKWebView.mm:

(-[WKWebView selectedText]):

  • TestWebKitAPI/ios/TestUIMenuBuilder.h:
  • TestWebKitAPI/ios/TestUIMenuBuilder.mm:

(-[TestUIMenuBuilder actionWithTitle:]):

Refactor and rename this to return the found UIAction instead of just a BOOL indicating whether or not it could
be found, and change existing call sites above to use EXPECT_NULL and EXPECT_NOT_NULL.

(-[TestUIMenuBuilder containsActionWithTitle:]): Deleted.

  • TestWebKitAPI/ios/UIKitSPI.h:
3:48 PM Changeset in webkit [290619] by pvollan@apple.com
  • 3 edits in trunk/Source/WebCore

[iOS] Weak link AVPictureInPictureController
https://bugs.webkit.org/show_bug.cgi?id=237227
<rdar://76011860>

Reviewed by Brent Fulgham.

Weak linking instead of soft linking should be a small performance improvement.

  • Configurations/WebCore.xcconfig:
  • platform/ios/VideoFullscreenInterfaceAVKit.mm:

(WebCore::supportsPictureInPicture):

3:26 PM Changeset in webkit [290618] by pvollan@apple.com
  • 2 edits in trunk/Source/WebCore

Remove release assert when UI process is blocking IOSurface IOKit access
https://bugs.webkit.org/show_bug.cgi?id=237278

Reviewed by Darin Adler.

Remove release assert in IOSurface::bytesPerRowAlignment() when UI process is blocking IOSurface IOKit access.
Instead, log this event, and return an appropriate value.

  • platform/graphics/cocoa/IOSurface.mm:

(WebCore::IOSurface::bytesPerRowAlignment):

3:24 PM Changeset in webkit [290617] by Brandon
  • 2 edits in trunk

Add Brandon Stewart's name to contributors.json
https://bugs.webkit.org/show_bug.cgi?id=237288

Reviewed by Saam Barati.

Add Brandon Stewart's name to contributors.json

  • metadata/contributors.json:
3:09 PM Changeset in webkit [290616] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Unreviewed, address feedback from Darin regarding r290610.

  • platform/graphics/Color.h:

(WebCore::add):

2:09 PM Changeset in webkit [290615] by commit-queue@webkit.org
  • 4 edits
    2 adds in trunk

Handle widow relayout differently
https://bugs.webkit.org/show_bug.cgi?id=235519

Patch by Rob Buis <rbuis@igalia.com> on 2022-02-28
Reviewed by Alan Bujtas.

Source/WebCore:

Handle widow relayout differently to prevent function call recursion.

Test: fast/multicol/widow-many-relayouts-crash.html

  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::layoutBlock):
(WebCore::RenderBlockFlow::relayoutToAvoidWidows): Deleted.

  • rendering/RenderBlockFlow.h:

(WebCore::RenderBlockFlow::didBreakAtLineToAvoidWidow const):

LayoutTests:

  • fast/multicol/widow-many-relayouts-crash-expected.txt: Added.
  • fast/multicol/widow-many-relayouts-crash.html: Added.
1:48 PM Changeset in webkit [290614] by chris.reid@sony.com
  • 2 edits in trunk/Tools

[Win] vswhere should search for Visual Studio Build tools
https://bugs.webkit.org/show_bug.cgi?id=237229

Reviewed by Ross Kirsling.

  • Scripts/webkitdirs.pm:
1:19 PM Changeset in webkit [290613] by Devin Rousso
  • 13 edits in trunk/Source

Web Inspector: [Flexbox] Add options to show each area's CSS order and/or DOM index in the parent flex container
https://bugs.webkit.org/show_bug.cgi?id=237215

Reviewed by Patrick Angle.

This will help developers better understand how CSS order and the DOM index of each flex
item interact and result in what's eventually rendered.

Source/JavaScriptCore:

  • inspector/protocol/DOM.json:

Add an optional boolean parameter to DOM.showFlexOverlay:

  • showOrderNumbers controls whether labels with the computed CSS order value are shown over each flex item's area.

Source/WebCore:

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

(WebCore::InspectorDOMAgent::showFlexOverlay):
Pass along the optional boolean parameter showOrderNumbers.

  • inspector/InspectorOverlay.h:

(WebCore::InspectorOverlay::Highlight::FlexHighlightOverlay::encode const):
(WebCore::InspectorOverlay::Highlight::FlexHighlightOverlay::decode):
Add member bool for showOrderNumbers to Flex::Config.
Add member Vector<InspectorOverlayLabel> to FlexHighlightOverlay for drawing labels.

  • inspector/InspectorOverlay.cpp:

(WebCore::InspectorOverlay::drawFlexOverlay):
(WebCore::InspectorOverlay::buildFlexOverlay):
Use showOrderNumbers to (when enabled) add items to Vector<InspectorOverlayLabel> for
each flex item's computed CSS order and DOM index in the parent flex container.

Source/WebInspectorUI:

  • UserInterface/Base/Setting.js:

Add global WI.Setting for flexOverlayShowOrderNumbers.

  • UserInterface/Models/DOMNode.js:

(WI.DOMNode.prototype.set layoutContextType): Added.
(WI.DOMNode.prototype.showLayoutOverlay): Added.
(WI.DOMNode.prototype.hideLayoutOverlay): Added.
(WI.DOMNode.prototype._handleLayoutOverlaySettingChanged): Renamed from _handleGridLayoutOverlaySettingChanged.
Listen for changes to the above WI.Setting and include the value when invoking DOM.showFlexOverlay.

  • UserInterface/Views/CSSFlexNodeOverlayListSection.js:

(WI.CSSFlexNodeOverlayListSection.prototype.initialLayout): Added.
Add UI for the above WI.Setting.

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Views/CSSGridNodeOverlayListSection.js:

(WI.CSSGridNodeOverlayListSection.prototype.initialLayout):
Drive-by: Adjust a WI.UIString to avoid possible future clashing.

1:00 PM Changeset in webkit [290612] by Devin Rousso
  • 5 edits
    3 adds in trunk

Web Inspector: add IterableWeakSet
https://bugs.webkit.org/show_bug.cgi?id=237141

Reviewed by Patrick Angle.

Source/WebInspectorUI:

This allows clients to have a way to have an iterable collection that doesn't keep the
objects in the collection alive. We cannot just use WeakSet as it's not iterable (the
former) or Array/Set as it keeps the objects alive (the latter).

IterableWeakSet is a combination of:

  • a Set of WeakRef for each object, which gives us iterability with order preserved
  • a WeakMap of each object mapping to the wrapper WeakRef in the Set (see below)
  • a FinalizationRegistry to remove the wrapper WeakRef when the object is destroyed
  • UserInterface/Base/IterableWeakSet.js: Added.

(IterableWeakSet):
(IterableWeakSet.prototype.get size):
(IterableWeakSet.prototype.has):
(IterableWeakSet.prototype.add):
(IterableWeakSet.prototype.delete):
(IterableWeakSet.prototype.take):
(IterableWeakSet.prototype.clear):
(IterableWeakSet.prototype.keys):
(IterableWeakSet.prototype.values):
(IterableWeakSet.prototype.Symbol.iterator):
(IterableWeakSet.prototype.copy):
(IterableWeakSet.prototype.toJSON):
(IterableWeakSet.prototype.get _finalizationRegistry):
We could just have a Set/Array of WeakRef, but that would require iterating the entire
array to find the WeakRef that matches the given object, which is less efficient.

  • UserInterface/Controllers/GridOverlayConfigurationDiagnosticEventRecorder.js:

(WI.GridOverlayConfigurationDiagnosticEventRecorder):
Don't keep WI.DOMNode that are layoutOverlayShowing alive in order to record diagnostics.

  • UserInterface/Main.html:
  • UserInterface/Test.html:

LayoutTests:

  • inspector/unit-tests/iterableweakset.html: Added.
  • inspector/unit-tests/iterableweakset-expected.txt: Added.
12:26 PM Changeset in webkit [290611] by Robert Jenner
  • 2 edits
    1 delete in trunk/LayoutTests

REGRESSION(r288070): [ Monterey ] platform/mac/fast/text/international/Geeza-Pro-vertical-metrics-adjustment.html is a constant text failure.
https://bugs.webkit.org/show_bug.cgi?id=236857

Unreviewed test gardening.

Patch by Matteo Flores <Matteo Flores> on 2022-02-28

  • platform/mac/fast/text/international/Geeza-Pro-vertical-metrics-adjustment-expected.txt: Removed.
  • platform/mac/platform/mac/fast/text/international/Geeza-Pro-vertical-metrics-adjustment-expected.txt: Previous file was in platform/mac/fast... instead of platform/mac/platform/mac/fast...
11:59 AM Changeset in webkit [290610] by Chris Dumez
  • 17 edits in trunk

Adopt the modern Hasher more widely
https://bugs.webkit.org/show_bug.cgi?id=237262

Reviewed by Sam Weinig.

Source/WebCore:

  • dom/MessagePortIdentifier.h:

(WebCore::add):
(WTF::MessagePortIdentifierHash::hash):
(WebCore::MessagePortIdentifier::hash const): Deleted.

  • history/BackForwardItemIdentifier.h:

(WebCore::add):
(WTF::BackForwardItemIdentifierHash::hash):
(WebCore::BackForwardItemIdentifier::hash const): Deleted.

  • loader/ResourceCryptographicDigest.h:

(WebCore::add):
(WTF::DefaultHash<WebCore::ResourceCryptographicDigest>::hash):

  • platform/graphics/Color.h:

(WebCore::add):
(WebCore::Color::hash const): Deleted.

  • platform/graphics/ColorHash.h:

(WTF::ColorHash::hash):

  • platform/graphics/Font.cpp:

(WebCore::add):
(WebCore::CharacterFallbackMapKeyHash::hash):

  • platform/graphics/FontCache.cpp:

(WebCore::add):
(WebCore::FontPlatformDataCacheKeyHash::hash):
(WebCore::FontCascadeCacheKeyHash::hash): Deleted.

  • platform/graphics/FontCache.h:

(WebCore::add):
(WebCore::FontCascadeCacheKeyHash::hash):

  • platform/graphics/cocoa/FontFamilySpecificationCoreText.cpp:

(WebCore::add):
(WebCore::FontFamilySpecificationKeyHash::hash):

  • platform/graphics/cocoa/SystemFontDatabaseCoreText.h:

(WebCore::add):
(WebCore::SystemFontDatabaseCoreText::CascadeListParameters::Hash::hash):
(WebCore::SystemFontDatabaseCoreText::CascadeListParameters::hash const): Deleted.

  • platform/graphics/freetype/FontCacheFreeType.cpp:

(WebCore::add):
(WebCore::FallbackFontDescriptionKeyHash::hash):

Source/WebKit:

  • NetworkProcess/cache/NetworkCache.h:

(WebKit::NetworkCache::add):
(WTF::GlobalFrameIDHash::hash):
(WebKit::NetworkCache::GlobalFrameID::hash const): Deleted.

  • Platform/IPC/StringReference.cpp:

(IPC::StringReference::Hash::hash):

  • Platform/IPC/StringReference.h:

(IPC::add):

11:57 AM Changeset in webkit [290609] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

Fix typo in adattributiond sandbox
https://bugs.webkit.org/show_bug.cgi?id=237279

Patch by Alex Christensen <achristensen@webkit.org> on 2022-02-28
Reviewed by Chris Dumez.

After this change, it matches the value in com.apple.webkit.adattributiond.plist

  • Resources/SandboxProfiles/ios/com.apple.WebKit.adattributiond.sb:
11:18 AM Changeset in webkit [290608] by Angelos Oikonomopoulos
  • 2 edits in trunk/Tools

[webkit-patch] Allow user to opt out of browser for viewing the diff
https://bugs.webkit.org/show_bug.cgi?id=220925

Reviewed by Jonathan Bedard.

The user may legitimately have a browser installed yet not want to
use it to view the diff.

  • Scripts/webkitpy/common/system/user.py:

(User.can_open_url):

11:10 AM Changeset in webkit [290607] by Ross Kirsling
  • 2 edits in trunk/Source/WebKit

REGRESSION(r290588): Broke WinCairo and PlayStation debug builds
https://bugs.webkit.org/show_bug.cgi?id=237277

Unreviewed build fix.

  • Scripts/webkit/messages.py:

(conditions_for_header):

10:30 AM Changeset in webkit [290606] by Aditya Keerthi
  • 5 edits
    7 adds in trunk

[macOS] Unable to upload ".pages" files to file inputs accepting ".pages" and ".jpeg" files
https://bugs.webkit.org/show_bug.cgi?id=237219
rdar://89482882

Reviewed by Tim Horton and Said Abou-Hallawa.

Source/WebCore:

In r264286, WebKit began transcoding images of an unsupported format
to a supported format, for file inputs that accepted image types. For
example, selecting a HEIF image in an input that accepts JPEG images
would transcode the selected image to a JPEG image.

In order to determine when attempt transcoding, the logic added in
r264286 obtains the MIME type corresponding to the selected file's
extension, and compares that to the list of accepted MIME types.
If there is a mismatch, transcoding is attempted.

The ".pages" extension does not have a well-defined MIME type in
NSURLFileTypeMappings. This is due to the fact that a the extension
maps to both a file and a package type. Consequently, the retrieved
MIME type for ".pages" files is an empty string. Following r227051,
when the file input also accepts an image type, WebKit attempts to
transcode these files, and any others that do not have a well-defined
MIME type.

While the aforementioned behavior can be considered strange, it is not
an issue in practice, since WebKit will attempt to transcode the
image, fail to do so, and upload the original file. The failure is
detected in CGImageDestinationFinalize, which returns false if an image
was not successfully written. However, a recent regression in the
ImageIO framework is causing CGImageDestinationFinalize to return true,
even if image transcoding fails. This results in WebKit uploading a
zero byte JPEG file, when a user attempts to upload ".pages" files to
file inputs accepting ".pages" and ".jpeg" files.

Ideally, the described issue would be resolved by a fix in ImageIO.
However, a more immediate solution exists in WebKit: only attempt to
transcode files to an accepted image type, if the file selected is
image. ".pages" files are not images, and WebKit should not attempt
to transcode them. See below for further explanation of the solution.

Test: fast/forms/file/entries-api/pages-jpeg-open-panel.html

  • platform/graphics/cg/ImageUtilitiesCG.cpp:

(WebCore::transcodeImage):

Prior to using ImageIO to perform transcoding, WebKit obtains a Uniform
Type Identifier for the selected file using CGImageSourceCreateWithURL
and CGImageSourceGetType. If the file is not an image, a null string is
returned. WebKit can use this information to avoid the transcoding
attempt, and avoid calls to ImageIO methods further down this method.
Specifically, this solution works around the ImageIO bug by avoiding
the call to CGImageDestinationFinalize for non-images. The solution is
also an overall improvement, as WebKit now avoids unnecessary calls to
multiple ImageIO methods, in cases where we know transcoding will fail.

LayoutTests:

Add a layout test that contains a file input that accepts ".pages" and
".jpeg" files, and attempts to upload a ".pages" file.

  • TestExpectations:
  • fast/forms/file/entries-api/pages-jpeg-open-panel-expected.txt: Added.
  • fast/forms/file/entries-api/pages-jpeg-open-panel.html: Added.
  • fast/forms/file/entries-api/pdf-jpeg-open-panel-expected.txt: Added.
  • fast/forms/file/entries-api/pdf-jpeg-open-panel.html: Added.
  • fast/forms/file/entries-api/resources/documents/document.pages: Added.
  • fast/forms/file/entries-api/resources/documents/document.pdf: Added.
  • platform/mac-wk2/TestExpectations:
10:06 AM Changeset in webkit [290605] by Jonathan Bedard
  • 9 edits in trunk/Tools

Unreviewed, reverting r290583.

Breaks webkit-patch

Reverted changeset:

"'run-benchmark' script should log http requests during
benchmark run."
https://bugs.webkit.org/show_bug.cgi?id=237076
https://commits.webkit.org/r290583

10:03 AM Changeset in webkit [290604] by Simon Fraser
  • 7 edits in trunk

Revert r290548

It caused three tests to start failing.

Source/WebCore:

  • rendering/RenderLayerScrollableArea.cpp:

(WebCore::RenderLayerScrollableArea::scrollAnimatorEnabled const): Deleted.

  • rendering/RenderLayerScrollableArea.h:

LayoutTests:

  • css3/scroll-snap/scroll-padding-overflow-paging.html:
  • fast/events/wheelevent-in-scrolling-div.html:
  • tiled-drawing/scrolling/scroll-snap/scroll-snap-proximity-overflow-rtl-with-keyboard.html:
10:00 AM Changeset in webkit [290603] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Use DeferTerminationForAWhile in Interpreter::unwind
https://bugs.webkit.org/show_bug.cgi?id=237176

Reviewed by Mark Lam.

If we're unwinding the stack due to a regular exception (not a TerminationException), then
we want to use a DeferTerminationForAWhile scope. This is because we want to avoid a
TerminationException being raised (due to a concurrent termination request) in the middle
of unwinding. The unwinding code only checks if we're handling a TerminationException before
it starts unwinding and is not expecting this status to change in the middle. Without the
DeferTerminationForAWhile scope, control flow may end up in an exception handler, and effectively
"catch" the newly raised TerminationException, which should not be catchable.

On the other hand, if we're unwinding the stack due to a TerminationException, we do not need
nor want the DeferTerminationForAWhile scope. This is because on exit, DeferTerminationForAWhile
will set the VMTraps NeedTermination bit if termination is in progress. The system expects the
NeedTermination bit to be have been cleared by VMTraps::handleTraps() once the TerminationException
has been raised. Some legacy client apps relies on this and expects to be able to re-enter the
VM after it exits due to termination. If the NeedTermination bit is set, upon re-entry, the
VM will behave as if a termination request is pending and terminate almost immediately, thereby
breaking the legacy client apps.

  • interpreter/Interpreter.cpp:

(JSC::UnwindFunctor::notifyDebuggerOfUnwinding):
(JSC::sanitizeRemoteFunctionException):
(JSC::Interpreter::unwind):
(JSC::notifyDebuggerOfUnwinding): Deleted.

9:49 AM Changeset in webkit [290602] by Russell Epstein
  • 1 copy in tags/Safari-613.1.17.1.10

Tag Safari-613.1.17.1.10.

9:49 AM Changeset in webkit [290601] by Russell Epstein
  • 8 edits
    2 deletes in branches/safari-613.1.17.1-branch

Revert r290518. rdar://problem/86582214

9:45 AM Changeset in webkit [290600] by Russell Epstein
  • 9 edits in branches/safari-613.1.17.1-branch/Source

Versioning.

WebKit-7613.1.17.1.10

9:37 AM Changeset in webkit [290599] by commit-queue@webkit.org
  • 6 edits in trunk/Tools

Enable python3 for lighttpd
https://bugs.webkit.org/show_bug.cgi?id=236938

Patch by Pascal Abresch <nep@packageloss.eu> on 2022-02-28
Reviewed by Darin Adler.

This is needed for the Haiku port to use the python3 tests.
This patch also removes the PHP support since all PHP tests have been removed and there are
currently no plans to include new ones in the future.

  • Scripts/webkitpy/layout_tests/servers/http_server.py:

(Lighttpd._prepare_config):

  • Scripts/webkitpy/layout_tests/servers/lighttpd.conf:
9:10 AM Changeset in webkit [290598] by graouts@webkit.org
  • 4 edits in trunk

[web-animations] web-animations/interfaces/Animatable/getAnimations.html is a unique failure
https://bugs.webkit.org/show_bug.cgi?id=237271

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/interfaces/Animatable/getAnimations-expected.txt:

Source/WebCore:

Our computation for the relevant state did not account for the playback rate. We rewrite
the function to match the spec exactly.

  • animation/WebAnimation.cpp:

(WebCore::WebAnimation::computeRelevance):

8:38 AM WebKitGTK/2.36.x edited by Michael Catanzaro
(diff)
8:32 AM Changeset in webkit [290597] by commit-queue@webkit.org
  • 2 edits in trunk

-Wodr warning spam caused by ENABLE(BINDING_INTEGRITY)
https://bugs.webkit.org/show_bug.cgi?id=229867
<rdar://problem/82975115>

Patch by Michael Catanzaro <Michael Catanzaro> on 2022-02-28
Reviewed by Carlos Garcia Campos.

Build WebKit with -Wno-odr. This warning is not salvagable, and it's impossible to suppress
locally.

  • Source/cmake/WebKitCompilerFlags.cmake:

2022-02-24 Matt Woodrow <Matt Woodrow>

Unreviewed, update my (Matt Woodrow) status to committer.

  • metadata/contributors.json:
7:52 AM WebKitGTK/2.36.x edited by Michael Catanzaro
(diff)
7:36 AM Changeset in webkit [290596] by Jonathan Bedard
  • 3 edits in trunk/Tools

[run-webkit-tests] Use Python 3 (Part 3)
https://bugs.webkit.org/show_bug.cgi?id=226658
<rdar://problem/78882016 >

Reviewed by Ryan Haddad.

  • Tools/CISupport/ews-build/steps.py:

(RunWebKitTests): Change invocation to Python 3.

  • Tools/CISupport/ews-build/steps_unittest.py:

(test_success):
(test_warnings):

Canonical link: https://commits.webkit.org/247872@main

6:50 AM Changeset in webkit [290595] by commit-queue@webkit.org
  • 4 edits
    3 adds in trunk

FTP EPLF does not handle directory
https://bugs.webkit.org/show_bug.cgi?id=45113

Patch by Pascal Abresch <nep@packageloss.eu> on 2022-02-28
Reviewed by Darin Adler.

The code used "!result.type" to check for an invalid type. However,
the first type in the FTPEntryType enum is FTPDirectoryEntry, so this
was actually returning true for directories, turning them into "junk"
entries which would not be listed.

Since the code for EPLF can only result in either files, directories,
or uninitialized/junk entries, the check can be removed, returning
result.type is the correct thing to do in all 3 cases.
Source/WebCore:

Test: http/tests/misc/ftp-eplf-directory.py

  • loader/FTPDirectoryParser.cpp:

(WebCore::parseOneFTPLine):

LayoutTests:

  • http/tests/misc/ftp-eplf-directory-expected.txt: Added.
  • http/tests/misc/ftp-eplf-directory.py: Added.
  • platform/gtk/TestExpectations:
6:01 AM Changeset in webkit [290594] by commit-queue@webkit.org
  • 4 edits
    1 add in trunk/Source/WebKit

REGRESSION(r290588) Missing symbol jsValueForDecodedMessage<107> (IPCStreamTesterProxy_WasCreated)
https://bugs.webkit.org/show_bug.cgi?id=237268

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2022-02-28
Reviewed by Antti Koivisto.

Add the class IPCStreamTesterProxy now that *MessageReceiver.cpp
are needed. After commit
"IPC_TESTING_API MessageArgumentDescriptions.cpp is slow to compile"
MessageReceiver.cpp files contain also message-specific functions that
need to be compiled, even though IPCStreamTesterProxy itself is not
used.

  • Shared/IPCStreamTesterProxy.h: Added.
  • Sources.txt:
  • WebKit.xcodeproj/project.pbxproj:
2:47 AM Changeset in webkit [290593] by Carlos Garcia Campos
  • 6 edits in releases/WebKitGTK/webkit-2.36

Merge r290586 - [ATSPI] Always expose table cells (layout and CSS) that have rendered text content
https://bugs.webkit.org/show_bug.cgi?id=237204

Reviewed by Adrian Perez de Castro.

Source/WebCore:

  • accessibility/atspi/AccessibilityObjectAtspi.cpp:

(WebCore::AccessibilityObject::accessibilityPlatformIncludesObject const):

LayoutTests:

  • accessibility/gtk/nested-block-element-children-expected.txt: Rebaseline.
  • platform/glib/TestExpectations: Remove accessibility/generated-content-with-display-table-crash.html.
  • platform/gtk/TestExpectations: Remove accessibility/gtk/nested-block-element-children.html.
2:47 AM Changeset in webkit [290592] by Carlos Garcia Campos
  • 5 edits in releases/WebKitGTK/webkit-2.36

Merge r290585 - [GTK][a11y] Test accessibility/gtk/xml-roles-exposed.html is failing since ATSPI switch
https://bugs.webkit.org/show_bug.cgi?id=237202

Reviewed by Adrian Perez de Castro.

Source/WebCore:

Handle the special case of form item having unknown aria role to be exposed as landmark.

  • accessibility/atspi/AccessibilityObjectAtspi.cpp:

(WebCore::AccessibilityObjectAtspi::effectiveRole const):

LayoutTests:

  • platform/gtk/TestExpectations: Remove accessibility/gtk/xml-roles-exposed.html.
  • platform/gtk/accessibility/gtk/xml-roles-exposed-expected.txt: Rebaseline.
2:18 AM Changeset in webkit [290591] by youenn@apple.com
  • 17 edits in trunk/Source/WebKit

RemoteVideoFrameObjectHeap should process its IPC messages in a background thread
https://bugs.webkit.org/show_bug.cgi?id=237198

Reviewed by Darin Adler.

Minor refactoring to have addWorkQueueMessageReceiver take a reference instead of a pointer.
Make RemoteVideoFrameObjectHeap become a WorkQueueMessageReceiver.
This ensures that a main thread hang in GPUProcess will not block big memory releases or WebProcess access to pixel buffers.

No observable change of behavior.

  • GPUProcess/GPUConnectionToWebProcess.cpp:

(WebKit::GPUConnectionToWebProcess::didClose):
(WebKit::GPUConnectionToWebProcess::videoFrameObjectHeap const):

  • GPUProcess/GPUConnectionToWebProcess.h:
  • GPUProcess/media/RemoteVideoFrameObjectHeap.cpp:

(WebKit::remoteVideoFrameObjectHeapQueue):
(WebKit::RemoteVideoFrameObjectHeap::create):
(WebKit::RemoteVideoFrameObjectHeap::RemoteVideoFrameObjectHeap):
(WebKit::RemoteVideoFrameObjectHeap::~RemoteVideoFrameObjectHeap):
(WebKit::RemoteVideoFrameObjectHeap::close):
(WebKit::RemoteVideoFrameObjectHeap::releaseVideoFrame):
(WebKit::RemoteVideoFrameObjectHeap::getVideoFrameBuffer):
(WebKit::RemoteVideoFrameObjectHeap::pixelBuffer):
(WebKit::RemoteVideoFrameObjectHeap::stopListeningForIPC): Deleted.

  • GPUProcess/media/RemoteVideoFrameObjectHeap.h:
  • NetworkProcess/IndexedDB/WebIDBServer.cpp:

(WebKit::WebIDBServer::addConnection):

  • NetworkProcess/WebStorage/StorageManagerSet.cpp:

(WebKit::StorageManagerSet::addConnection):

  • NetworkProcess/storage/NetworkStorageManager.cpp:

(WebKit::NetworkStorageManager::startReceivingMessageFromConnection):

  • NetworkProcess/webrtc/RTCDataChannelRemoteManagerProxy.cpp:

(WebKit::RTCDataChannelRemoteManagerProxy::registerConnectionToWebProcess):

  • Platform/IPC/Connection.cpp:

(IPC::Connection::addWorkQueueMessageReceiver):

  • Platform/IPC/Connection.h:
  • UIProcess/mac/SecItemShimProxy.cpp:

(WebKit::SecItemShimProxy::initializeConnection):

  • WebProcess/GPU/media/RemoteAudioSourceProviderManager.cpp:

(WebKit::RemoteAudioSourceProviderManager::setConnection):

  • WebProcess/GPU/webrtc/RemoteVideoFrameObjectHeapProxyProcessor.cpp:

(WebKit::RemoteVideoFrameObjectHeapProxyProcessor::RemoteVideoFrameObjectHeapProxyProcessor):

  • WebProcess/Inspector/WebInspectorInterruptDispatcher.cpp:

(WebKit::WebInspectorInterruptDispatcher::initializeConnection):

  • WebProcess/Network/webrtc/RTCDataChannelRemoteManager.cpp:

(WebKit::RTCDataChannelRemoteManager::setConnection):

  • WebProcess/WebPage/EventDispatcher.cpp:

(WebKit::EventDispatcher::initializeConnection):

  • WebProcess/WebPage/ViewUpdateDispatcher.cpp:

(WebKit::ViewUpdateDispatcher::initializeConnection):

2:03 AM Changeset in webkit [290590] by youenn@apple.com
  • 11 edits in trunk/Source

Ensure RemoteMediaPlayerProxy sets its resource owner to pixel buffers created by its player
https://bugs.webkit.org/show_bug.cgi?id=237200

Reviewed by Eric Carlson.

Source/WebCore:

Add API to set the resource owner for a player private.
In case player private is running in GPUProcess, use resource owner to mark pixel buffers as owned by the resource owner.
Covered by existing tests.

  • platform/graphics/MediaPlayerPrivate.h:

(WebCore::MediaPlayerPrivateInterface::setResourceOwner):

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::updateLastPixelBuffer):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::updateLastPixelBuffer):

Source/WebKit:

Set resource owner to the player private.

  • GPUProcess/media/RemoteMediaPlayerManagerProxy.cpp:

(WebKit::RemoteMediaPlayerManagerProxy::createMediaPlayer):

  • GPUProcess/media/RemoteMediaPlayerProxy.cpp:

(WebKit::RemoteMediaPlayerProxy::RemoteMediaPlayerProxy):

  • GPUProcess/media/RemoteMediaPlayerProxy.h:
1:56 AM Changeset in webkit [290589] by Angelos Oikonomopoulos
  • 5 edits in trunk/Source/JavaScriptCore

[JSC] Reuse known register values on ARMv7
https://bugs.webkit.org/show_bug.cgi?id=237207

Reviewed by Žan Doberšek.

Set up a CachedTempRegister for each of addressTempRegister,
dataTempRegister on ARMv7 and use them to generate shorter instruction
sequences when possible.

Saves 1.5-2% of code size on JS2 with no measurable difference in
performance.

  • assembler/AbstractMacroAssembler.h:

(JSC::AbstractMacroAssembler::CachedTempRegister::value):

  • assembler/MacroAssemblerARMv7.cpp:

(JSC::MacroAssembler::probe):

  • assembler/MacroAssemblerARMv7.h:

(JSC::MacroAssemblerARMv7::MacroAssemblerARMv7):
(JSC::MacroAssemblerARMv7::add32):
(JSC::MacroAssemblerARMv7::getEffectiveAddress):
(JSC::MacroAssemblerARMv7::add64):
(JSC::MacroAssemblerARMv7::lshift32):
(JSC::MacroAssemblerARMv7::mul32):
(JSC::MacroAssemblerARMv7::rshift32):
(JSC::MacroAssemblerARMv7::urshift32):
(JSC::MacroAssemblerARMv7::load32):
(JSC::MacroAssemblerARMv7::load16):
(JSC::MacroAssemblerARMv7::load16SignedExtendTo32):
(JSC::MacroAssemblerARMv7::load8):
(JSC::MacroAssemblerARMv7::load8SignedExtendTo32):
(JSC::MacroAssemblerARMv7::loadPair32):
(JSC::MacroAssemblerARMv7::store8):
(JSC::MacroAssemblerARMv7::storePair32):
(JSC::MacroAssemblerARMv7::loadDouble):
(JSC::MacroAssemblerARMv7::loadFloat):
(JSC::MacroAssemblerARMv7::storeDouble):
(JSC::MacroAssemblerARMv7::storeFloat):
(JSC::MacroAssemblerARMv7::branchTruncateDoubleToInt32):
(JSC::MacroAssemblerARMv7::branchConvertDoubleToInt32):
(JSC::MacroAssemblerARMv7::long_move):
(JSC::MacroAssemblerARMv7::short_move):
(JSC::MacroAssemblerARMv7::move):
(JSC::MacroAssemblerARMv7::compare32AndSetFlags):
(JSC::MacroAssemblerARMv7::branch8):
(JSC::MacroAssemblerARMv7::branchTest8):
(JSC::MacroAssemblerARMv7::branchTest16):
(JSC::MacroAssemblerARMv7::farJump):
(JSC::MacroAssemblerARMv7::branchMul32):
(JSC::MacroAssemblerARMv7::nearCall):
(JSC::MacroAssemblerARMv7::nearTailCall):
(JSC::MacroAssemblerARMv7::call):
(JSC::MacroAssemblerARMv7::compare8):
(JSC::MacroAssemblerARMv7::test8):
(JSC::MacroAssemblerARMv7::jump):
(JSC::MacroAssemblerARMv7::makeBranch):
(JSC::MacroAssemblerARMv7::setupArmAddress):
(JSC::MacroAssemblerARMv7::makeBaseIndexBase):
(JSC::MacroAssemblerARMv7::moveFixedWidthEncoding):
(JSC::MacroAssemblerARMv7::cachedDataTempRegister):
(JSC::MacroAssemblerARMv7::cachedAddressTempRegister):
(JSC::MacroAssemblerARMv7::getCachedDataTempRegisterIDAndInvalidate):
(JSC::MacroAssemblerARMv7::getCachedAddressTempRegisterIDAndInvalidate):

  • bytecode/CallLinkInfo.cpp:

(JSC::CallLinkInfo::emitFastPathImpl):

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

IPC_TESTING_API MessageArgumentDescriptions.cpp is slow to compile
https://bugs.webkit.org/show_bug.cgi?id=237195

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2022-02-28
Reviewed by Antti Koivisto.

IPC testing API needs convert message data buffer, IPC::Decoder, to
JSValue. This is a run-time operation.
IPC message decoding is based on templates, a compile time operation.
IPC generator generates MessageArgumentDescriptions.cpp with
a big switch. The switch has a case for each message name. The case would
call templated jsValueForDecodedArguments<Arguments>, where the Arguments
is the type tuple for the message arguments.

The above would mean that MessageArgumentDescriptions would need to
include all the headers for all the messages in WebKit in order
to populate the Arguments tuple for particular message.
This would cause MessageArgumentDescriptions to be slow to compile because
it would need all the headers in Source/WebKit related to message parameter types.

This would show up as slow compiles that would consume much memory (5-6gb) and do a
lot of work.

It would also have to compile the MessageArgumentDescriptions each time
any of the headers were touched.

Change this so that the big switch calls a declared but not defined
template jsValueForDecodedMessage<MessageName> for each MessageName case in the
switch.

Instantiate the template for each message in the *MessageReceiver.cpp file
that each message receiver has. This file already has to include all the
headers used for that particular message receiver. These files are small and compile
fast.

After this change MessageArgumentDescriptions.cpp only includes the message
definition headers, does not use much more than the standard 1gb+ of memory
while compiling and is relatively fast to compile. Also if any of the dependent
headers are touched, only the corresponding small *MessageReceiver.cpp files are compiled.

This change is needed for further improve the JS testing API implementation.
Adding new operations that employ the same strategy, eg. switch and a complex
template instantiation, would possibly just make the matter worse. New operations
that are needed are message sends, which use templates similarly to the message
decode case that is implement here.

This change regenerates the checked-in test content that can be used to review
what kind of changes the real MessageArgumentDescriptions.cpp and MessageReceiver.cpps
get.

  • Platform/IPC/JSIPCBinding.h:
  • Scripts/webkit/messages.py:

(generate_message_handler):
(generate_js_value_conversion_function):
(generate_message_argument_description_implementation):

  • Scripts/webkit/tests/MessageArgumentDescriptions.cpp:

(IPC::jsValueForArguments):
(IPC::jsValueForReplyArguments):

  • Scripts/webkit/tests/TestWithCVPixelBufferMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithCVPixelBuffer_SendCVPixelBuffer>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithCVPixelBuffer_ReceiveCVPixelBuffer>):

  • Scripts/webkit/tests/TestWithIfMessageMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithIfMessage_LoadURL>):

  • Scripts/webkit/tests/TestWithImageDataMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithImageData_SendImageData>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithImageData_ReceiveImageData>):

  • Scripts/webkit/tests/TestWithLegacyReceiverMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_LoadURL>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_LoadSomething>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_TouchEvent>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_AddEvent>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_LoadSomethingElse>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_DidReceivePolicyDecision>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_Close>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_PreferencesDidChange>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_SendDoubleAndFloat>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_SendInts>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_CreatePlugin>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_RunJavaScriptAlert>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_GetPlugins>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_GetPluginProcessConnection>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithLegacyReceiver_GetPluginProcessConnection>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_TestMultipleAttributes>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithLegacyReceiver_TestMultipleAttributes>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_TestParameterAttributes>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_TemplateTest>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_SetVideoLayerID>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_DidCreateWebProcessConnection>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_InterpretKeyEvent>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_DeprecatedOperation>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithLegacyReceiver_ExperimentalOperation>):

  • Scripts/webkit/tests/TestWithSemaphoreMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithSemaphore_SendSemaphore>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSemaphore_ReceiveSemaphore>):

  • Scripts/webkit/tests/TestWithStreamBufferMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithStreamBuffer_SendStreamBuffer>):

  • Scripts/webkit/tests/TestWithStreamMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithStream_SendString>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithStream_SendStringSynchronized>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithStream_SendMachSendRight>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithStream_ReceiveMachSendRight>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithStream_SendAndReceiveMachSendRight>):

  • Scripts/webkit/tests/TestWithSuperclassMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_LoadURL>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_TestAsyncMessage>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithSuperclass_TestAsyncMessage>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_TestAsyncMessageWithNoArguments>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithSuperclass_TestAsyncMessageWithNoArguments>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_TestAsyncMessageWithMultipleArguments>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithSuperclass_TestAsyncMessageWithMultipleArguments>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_TestAsyncMessageWithConnection>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithSuperclass_TestAsyncMessageWithConnection>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_TestSyncMessage>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithSuperclass_TestSyncMessage>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithSuperclass_TestSynchronousMessage>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithSuperclass_TestSynchronousMessage>):

  • Scripts/webkit/tests/TestWithoutAttributesMessageReceiver.cpp:

(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_LoadURL>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_LoadSomething>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_TouchEvent>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_AddEvent>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_LoadSomethingElse>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_DidReceivePolicyDecision>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_Close>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_PreferencesDidChange>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_SendDoubleAndFloat>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_SendInts>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_CreatePlugin>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_RunJavaScriptAlert>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_GetPlugins>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_GetPluginProcessConnection>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithoutAttributes_GetPluginProcessConnection>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_TestMultipleAttributes>):
(IPC::jsValueForDecodedMessageReply<MessageName::TestWithoutAttributes_TestMultipleAttributes>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_TestParameterAttributes>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_TemplateTest>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_SetVideoLayerID>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_DidCreateWebProcessConnection>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_InterpretKeyEvent>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_DeprecatedOperation>):
(IPC::jsValueForDecodedMessage<MessageName::TestWithoutAttributes_ExperimentalOperation>):

1:01 AM Changeset in webkit [290587] by ntim@apple.com
  • 2 edits in trunk/Source/WTF

Enable inert attribute feature flag
https://bugs.webkit.org/show_bug.cgi?id=235668

Reviewed by Darin Adler.

  • Scripts/Preferences/WebPreferencesExperimental.yaml:
1:00 AM Changeset in webkit [290586] by Carlos Garcia Campos
  • 6 edits in trunk

[ATSPI] Always expose table cells (layout and CSS) that have rendered text content
https://bugs.webkit.org/show_bug.cgi?id=237204

Reviewed by Adrian Perez de Castro.

Source/WebCore:

  • accessibility/atspi/AccessibilityObjectAtspi.cpp:

(WebCore::AccessibilityObject::accessibilityPlatformIncludesObject const):

LayoutTests:

  • accessibility/gtk/nested-block-element-children-expected.txt: Rebaseline.
  • platform/glib/TestExpectations: Remove accessibility/generated-content-with-display-table-crash.html.
  • platform/gtk/TestExpectations: Remove accessibility/gtk/nested-block-element-children.html.
12:58 AM Changeset in webkit [290585] by Carlos Garcia Campos
  • 5 edits in trunk

[GTK][a11y] Test accessibility/gtk/xml-roles-exposed.html is failing since ATSPI switch
https://bugs.webkit.org/show_bug.cgi?id=237202

Reviewed by Adrian Perez de Castro.

Source/WebCore:

Handle the special case of form item having unknown aria role to be exposed as landmark.

  • accessibility/atspi/AccessibilityObjectAtspi.cpp:

(WebCore::AccessibilityObjectAtspi::effectiveRole const):

LayoutTests:

  • platform/gtk/TestExpectations: Remove accessibility/gtk/xml-roles-exposed.html.
  • platform/gtk/accessibility/gtk/xml-roles-exposed-expected.txt: Rebaseline.
12:29 AM Changeset in webkit [290584] by graouts@webkit.org
  • 4 edits in trunk

[web-animations] web-animations/interfaces/KeyframeEffect/processing-a-keyframes-argument-001.html is a unique failure
https://bugs.webkit.org/show_bug.cgi?id=237259

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/interfaces/KeyframeEffect/processing-a-keyframes-argument-001-expected.txt:

Source/WebCore:

We incorrectly threw when processing a null or undefined value when an iterable was provided to setKeyframes().
We now correctly insert an empty keyframe if such a value is provided.

  • animation/KeyframeEffect.cpp:

(WebCore::processIterableKeyframes):

Feb 27, 2022:

11:07 PM Changeset in webkit [290583] by Dewei Zhu
  • 9 edits in trunk/Tools

'run-benchmark' script should log http requests during benchmark run.
https://bugs.webkit.org/show_bug.cgi?id=237076
<rdar://89270825>

Reviewed by Simon Fraser.

Add support to log http requests during benchmark run for diagnostic purpose.

  • Scripts/webkitpy/init.py: Update 'attr' package version to 20.3.0 so match upgraded twisted version
  • Scripts/webkitpy/autoinstalled/twisted.py: Upgrade twisted version to latest python2 & python3 compatibile

version.

  • Scripts/webkitpy/benchmark_runner/benchmark_runner.py: Ensure benchmark diagnostic directory is created.

(BenchmarkRunner.init):

  • Scripts/webkitpy/benchmark_runner/http_server_driver/http_server/twisted_http_server.py: Add '--log-path'

arugment to allow specify logging output and it defaults to '/tmp/run-benchmark-http.log'

  • Scripts/webkitpy/benchmark_runner/http_server_driver/http_server_driver.py:

(HTTPServerDriver.set_device_id):
(HTTPServerDriver):
(HTTPServerDriver.set_http_log):

  • Scripts/webkitpy/benchmark_runner/http_server_driver/simple_http_server_driver.py: Pass http log path to

twisted http server if specified.
(SimpleHTTPServerDriver.init):
(SimpleHTTPServerDriver.serve):
(SimpleHTTPServerDriver.set_http_log):

  • Scripts/webkitpy/benchmark_runner/run_benchmark.py: Fix a tiny bug that default_diagnose_dir() is involked twice in

argument parser help message.
(config_argument_parser):

  • Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py: Set http request log path if diagnostic directory

is specified.
(WebServerBenchmarkRunner.init):

Canonical link: https://commits.webkit.org/247861@main

9:09 PM Changeset in webkit [290582] by sihui_liu@apple.com
  • 10 edits in trunk/Source/WebKit

Add a feature flag for using general storage directory
https://bugs.webkit.org/show_bug.cgi?id=237186
rdar://89521373

Reviewed by Chris Dumez.

  • FeatureFlags/WebKit-appletvos.plist:
  • FeatureFlags/WebKit-ios.plist:
  • FeatureFlags/WebKit-macos.plist:
  • FeatureFlags/WebKit-watchos.plist:
  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::WebsiteDataStore::defaultShouldUseCustomStoragePaths):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::defaultShouldUseCustomStoragePaths):

  • UIProcess/WebsiteData/WebsiteDataStore.h:
  • UIProcess/WebsiteData/WebsiteDataStoreConfiguration.cpp:

(WebKit::WebsiteDataStoreConfiguration::WebsiteDataStoreConfiguration):

  • UIProcess/WebsiteData/WebsiteDataStoreConfiguration.h:
8:17 PM Changeset in webkit [290581] by Said Abou-Hallawa
  • 6 edits in trunk/Source

[GPU Process] Deleted unneeded constructors from DisplayList::Recorder classes
https://bugs.webkit.org/show_bug.cgi?id=237261

Reviewed by Wenson Hsieh.

Source/WebCore:

This should have been done in r289594.

  • platform/graphics/displaylists/DisplayListRecorder.cpp:

(WebCore::DisplayList::Recorder::Recorder):

  • platform/graphics/displaylists/DisplayListRecorder.h:

Source/WebKit:

  • WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.cpp:
  • WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.h:
8:01 PM Changeset in webkit [290580] by Jonathan Bedard
  • 71 edits
    2 deletes in trunk

webkitpy: WebSocket server doesn't support Python 3
https://bugs.webkit.org/show_bug.cgi?id=230319
<rdar://problem/58814743>

Reviewed by Fujii Hironori.

Tools:

  • Scripts/new-run-webkit-websocketserver: Change shebang.
  • Scripts/webkitpy/layout_tests/servers/websocket_server.py:

(PyWebSocket._prepare_config): Invoke WebSocket server with Python 3.

LayoutTests:

Make all tests Python 3 compatible, even at the cost of Python 2
compatibility, since WebSocket tests are always invoked with Python 3.

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/binary-frames_wsh.py:

(web_socket_transfer_data):
(all_distinct_bytes):

  • http/tests/websocket/tests/hybi/broken-utf8_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/check-binary-messages_wsh.py:

(web_socket_transfer_data):
(all_distinct_bytes):

  • http/tests/websocket/tests/hybi/client-close-2-expected.txt:
  • http/tests/websocket/tests/hybi/client-close-2.html:
  • http/tests/websocket/tests/hybi/client-close-2_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/client-close-expected.txt:
  • http/tests/websocket/tests/hybi/client-close.html:
  • http/tests/websocket/tests/hybi/client-close_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/close-code-and-reason_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/close-on-unload_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/compressed-control-frame_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/cookie_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/deflate-frame-invalid-parameter_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/deflate-frame_wsh.py:

(_get_deflate_frame_extension_processor):
(web_socket_do_extra_handshake):
(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/echo-cookie_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/echo_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/fragmented-binary-frames_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/handshake-fail-by-extensions-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-invalid-http-version_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-maxlength_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-mismatch-protocol-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-more-accept-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-more-extensions-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-more-protocol-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-no-accept-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-no-connection-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-no-cr_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-no-upgrade-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-non-ascii-header-value-sec-websocket-accept_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-non-ascii-header-value-sec-websocket-extensions_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-non-ascii-header-value-sec-websocket-protocol_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-non-ascii-status-line_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-null-char-in-status_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-prepended-null_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-fail-by-wrong-accept-header_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-ok-with-http-version-beyond-1_1_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-ok-with-legacy-sec-websocket-response-headers_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/handshake-ok-with-legacy-websocket-response-headers_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/imported/blink/permessage-deflate-invalid-parameter_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/imported/blink/permessage-deflate-manual_wsh.py:
  • http/tests/websocket/tests/hybi/imported/blink/permessage-deflate-unsolicited-negotiation-response_wsh.py:
  • http/tests/websocket/tests/hybi/imported/blink/permessage-deflate_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/inspector/binary_wsh.py:

(web_socket_transfer_data):
(all_distinct_bytes):

  • http/tests/websocket/tests/hybi/invalid-continuation_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/invalid-encode-length_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/pong_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/protocol-test_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/reserved-bits_wsh.py:

(_get_deflate_frame_extension_processor):
(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/reserved-opcodes_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/send-file-blob_wsh.py:

(web_socket_transfer_data):
(all_distinct_bytes):

  • http/tests/websocket/tests/hybi/too-long-payload_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/unicode_wsh.py:
  • http/tests/websocket/tests/hybi/unmasked-frames_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/workers/resources/binary-frames_wsh.py:

(web_socket_transfer_data):
(all_distinct_bytes):

  • http/tests/websocket/tests/hybi/workers/resources/check-binary-messages_wsh.py:

(web_socket_transfer_data):
(all_distinct_bytes):

  • http/tests/websocket/tests/hybi/workers/resources/no-onmessage-in-sync-op_wsh.py:

(web_socket_transfer_data):

  • http/tests/websocket/tests/hybi/workers/resources/protocol-test_wsh.py:

(web_socket_do_extra_handshake):

  • http/tests/websocket/tests/hybi/zero-length-text_wsh.py:

(web_socket_transfer_data):

  • platform/glib/TestExpectations:
  • platform/ios-wk2/http/tests/websocket/tests/hybi/handshake-fail-by-no-cr-expected.txt:
  • platform/mac-wk2/http/tests/websocket/tests/hybi/client-close-2-expected.txt: Removed.
  • platform/mac-wk2/http/tests/websocket/tests/hybi/client-close-expected.txt: Removed.
  • platform/mac-wk2/http/tests/websocket/tests/hybi/handshake-fail-by-no-cr-expected.txt:
  • platform/mac/TestExpectations:
  • platform/win/TestExpectations:
  • platform/wincairo/TestExpectations:
7:28 PM Changeset in webkit [290579] by commit-queue@webkit.org
  • 9 edits
    2 deletes in trunk

Unreviewed, reverting r290577.
https://bugs.webkit.org/show_bug.cgi?id=237264

Breaks ios-wk2 layout test.

Reverted changeset:

"Compute correct containing block override size for items that
are subgridden in one dimension only."
https://bugs.webkit.org/show_bug.cgi?id=236951
https://commits.webkit.org/r290577

7:24 PM Changeset in webkit [290578] by Wenson Hsieh
  • 8 edits in trunk/Source

Invoking "Markup Image" should preserve the existing selection range
https://bugs.webkit.org/show_bug.cgi?id=237242

Reviewed by Darin Adler.

Source/WebCore:

Move the implementation of replaceNodeFromPasteboard out of the macOS-specific implementation file and into
EditorCocoa instead, so that we can use it on both iOS and macOS to handle the "Markup Image" action. See WebKit
ChangeLog for more details.

  • editing/Editor.h:
  • editing/cocoa/EditorCocoa.mm:

(WebCore::maybeCopyNodeAttributesToFragment):
(WebCore::Editor::replaceNodeFromPasteboard):

Also make a few minor adjustments while we're moving this code:

  • Make this take a reference instead of a pointer (the method always expects a non-null Node pointer anyways).
  • Add a FIXME mentioning that we can just delete setInsertionPasteboard altogether once Mail compose on

macOS uses WebKit2.

  • Unconditionally pass false for whether or not we should enable smart paste when replacing the node. This

prevents us from inserting spaces around the replacement image element when triggering the "Markup Image"
item.

  • Use makeRangeSelectingNode instead of makeRangeSelectingNodeContents when selecting the node to replace.

This allows us to handle the case where the node to replace cannot contain children for editing (in
particular, image elements).

Note that this codepath (replaceNodeFromPasteboard) is currently only exercised by WebKitLegacy service
controls code that was originally intended for use by Mail compose, but never ended up being used.

  • editing/mac/EditorMac.mm:

(WebCore::Editor::pasteWithPasteboard):
(WebCore::maybeCopyNodeAttributesToFragment): Deleted.
(WebCore::Editor::replaceNodeFromPasteboard): Deleted.

Source/WebKit:

Make a few adjustments to replaceWithPasteboardData, such that it attempts to restore the previous selection
range after replacing the target element. If the previous selection is no longer valid (i.e., it was orphaned as
a result of the editing command used to replace the element), then we fall back to restoring the visible
character range of the previous selection, relative to the editable root (or the body if there is none).

API tests will be added in https://webkit.org/b/236519, once we're able to swizzle out the underlying VisionKit
methods in order to make these tests run reliably.

  • WebProcess/WebPage/Cocoa/WebPageCocoa.mm:

(WebKit::OverridePasteboardForSelectionReplacement::OverridePasteboardForSelectionReplacement):
(WebKit::OverridePasteboardForSelectionReplacement::~OverridePasteboardForSelectionReplacement):

Add a helper RAII object that encapsulates logic for setting and unsetting data on the override pasteboard. Use
this in the two methods below.

(WebKit::WebPage::replaceWithPasteboardData):

Switch to using the refactored Editor::replaceNodeFromPasteboard method instead of calling to the adjacent
replaceSelectionWithPasteboardData method below. Using this method allows us to avoid manually selecting the
target element here, and also avoids smart pasteboard replacement (which may insert spaces before or after the
image); the latter is important in order to correctly restore the previous selection's character range in the
case where the previous selection range was orphaned by the replacement.

(WebKit::WebPage::replaceSelectionWithPasteboardData):

Source/WebKitLegacy/mac:

See WebKit and WebCore ChangeLogs for more detail.

  • Misc/WebSharingServicePickerController.mm:

(-[WebSharingServicePickerController didShareImageData:confirmDataIsValidTIFFData:]):

Adjust this call site to pass in a reference instead of a pointer. Also deploy RefPtr in some adjacent code.

7:03 PM Changeset in webkit [290577] by Matt Woodrow
  • 9 edits
    2 adds in trunk

Compute correct containing block override size for items that are subgridden in one dimension only.
https://bugs.webkit.org/show_bug.cgi?id=236951

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

Added new WPT similar to auto-track-sizing-001 which adds new variations
with nested subgrids and varying whether the other axis is subgridded.

  • web-platform-tests/css/css-grid/subgrid/auto-track-sizing-002-expected.html: Added.
  • web-platform-tests/css/css-grid/subgrid/auto-track-sizing-002.html: Added.

Source/WebCore:

Items that are subgridded in one dimension will be included in the track sizing algorithm of the
outer grid for that dimension. When measuring their size in the subgridded dimension, we need to
set their containing block size in the other (non-subgridded) dimension, which is only available
from the subgrid's track sizing, not the outer track sizes.

This recurses up to set the override size on the subgrid element instead, and forces a layout
there, which should copy down subgrid track sizes and compute the other dimension, making it
available on the inner item we need.

Test: imported/w3c/web-platform-tests/css/css-grid/subgrid/auto-track-sizing-002.html

  • rendering/GridLayoutFunctions.cpp:

(WebCore::GridLayoutFunctions::extraMarginForSubgridAncestors):

  • rendering/GridLayoutFunctions.h:
  • rendering/GridTrackSizingAlgorithm.cpp:

(WebCore::GridTrackSizingAlgorithmStrategy::updateOverridingContainingBlockContentSizeForChild const):

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::isSubgridOf):

  • rendering/RenderGrid.h:

LayoutTests:

Marked existing WPT as passing.

6:14 PM Changeset in webkit [290576] by Matt Woodrow
  • 4 edits in trunk

Convert grid direction to be relative to subgrid when accounting for extra margin.
https://bugs.webkit.org/show_bug.cgi?id=236954

Reviewed by Dean Jackson.

Source/WebCore:

|direction| is passed as a direction relative to |grid|, so we need to convert it
to be a direction relative to the subgrid item in order to account for margin on
the correct edge.

Marks existing test orthogonal-writing-mode-003.html as passing.

  • rendering/GridLayoutFunctions.cpp:

(WebCore::GridLayoutFunctions::marginLogicalSizeForChild):

LayoutTests:

Marks existing test orthogonal-writing-mode-003.html as passing.

5:24 PM Changeset in webkit [290575] by Chris Dumez
  • 100 edits in trunk

Omit template parameter for SetForScope<> variables
https://bugs.webkit.org/show_bug.cgi?id=237258

Reviewed by Darin Adler.

Source/JavaScriptCore:

  • bytecompiler/BytecodeGenerator.h:

(JSC::BytecodeGenerator::emitNode):

  • debugger/Debugger.cpp:

(JSC::Debugger::dispatchFunctionToObservers):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::setLocalOrTmp):
(JSC::DFG::ByteCodeParser::setArgument):

  • inspector/InspectorBackendDispatcher.cpp:

(Inspector::BackendDispatcher::dispatch):

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseInner):
(JSC::Parser<LexerType>::parseAsyncFunctionSourceElements):
(JSC::Parser<LexerType>::parseAsyncGeneratorFunctionSourceElements):
(JSC::Parser<LexerType>::parseFunctionBody):
(JSC::Parser<LexerType>::parseFunctionParameters):
(JSC::Parser<LexerType>::parseFunctionInfo):
(JSC::Parser<LexerType>::parseFunctionDeclaration):
(JSC::Parser<LexerType>::parseAsyncFunctionDeclaration):
(JSC::Parser<LexerType>::parseClass):
(JSC::Parser<LexerType>::parseProperty):
(JSC::Parser<LexerType>::parseGetterSetter):
(JSC::Parser<LexerType>::parseFunctionExpression):
(JSC::Parser<LexerType>::parseAsyncFunctionExpression):
(JSC::Parser<LexerType>::parseArrowFunctionExpression):

Source/WebCore:

  • Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:

(WebCore::IDBServer::MemoryBackingStoreTransaction::abort):

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::performDeferredCacheUpdate):

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::JSCustomElementRegistry::define):

  • bindings/js/ScriptController.cpp:

(WebCore::ScriptController::evaluateInWorld):
(WebCore::ScriptController::evaluateModule):
(WebCore::ScriptController::callInWorld):
(WebCore::ScriptController::executeJavaScriptURL):

  • css/CSSFontSelector.cpp:

(WebCore::CSSFontSelector::addFontFaceRule):

  • css/parser/CSSSelectorParser.cpp:

(WebCore::CSSSelectorParser::consumeCompoundSelector):

  • dom/CustomElementReactionQueue.cpp:

(WebCore::CustomElementQueue::invokeAll):

  • dom/Document.cpp:

(WebCore::Document::updateRenderTree):
(WebCore::Document::styleForElementIgnoringPendingStylesheets):
(WebCore::Document::destroyRenderTree):
(WebCore::Document::hitTest):

  • dom/EventTarget.cpp:

(WebCore::EventTarget::fireEventListeners):

  • dom/Microtasks.cpp:

(WebCore::MicrotaskQueue::performMicrotaskCheckpoint):

  • dom/ScriptExecutionContext.cpp:

(WebCore::ScriptExecutionContext::forEachActiveDOMObject const):

  • dom/Traversal.cpp:

(WebCore::NodeIteratorBase::acceptNode):

  • editing/Editor.cpp:

(WebCore::Editor::cut):
(WebCore::Editor::copy):
(WebCore::Editor::copyFont):
(WebCore::Editor::paste):
(WebCore::Editor::pasteAsPlainText):
(WebCore::Editor::pasteAsQuotation):
(WebCore::Editor::pasteFont):

  • history/BackForwardCache.cpp:

(WebCore::BackForwardCache::pruneToSizeNow):
(WebCore::BackForwardCache::removeAllItemsForPage):

  • html/DOMTokenList.cpp:

(WebCore::DOMTokenList::updateAssociatedAttributeFromTokens):

  • html/HTMLButtonElement.cpp:

(WebCore::HTMLButtonElement::defaultEventHandler):

  • html/HTMLFormControlElement.cpp:

(WebCore::HTMLFormControlElement::focusAndShowValidationMessage):

  • html/HTMLFormElement.cpp:

(WebCore::HTMLFormElement::reset):
(WebCore::HTMLFormElement::constructEntryList):

  • html/HTMLTrackElement.cpp:

(WebCore::HTMLTrackElement::scheduleLoad):

  • html/parser/CSSPreloadScanner.cpp:

(WebCore::CSSPreloadScanner::scan):

  • html/shadow/TextControlInnerElements.cpp:

(WebCore::SearchFieldResultsButtonElement::resolveCustomStyle):

  • html/track/LoadableTextTrack.cpp:

(WebCore::LoadableTextTrack::scheduleLoad):

  • loader/ContentFilter.cpp:

(WebCore::ContentFilter::handleProvisionalLoadFailure):

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::load):
(WebCore::FrameLoader::clearProvisionalLoadForPolicyCheck):
(WebCore::FrameLoader::dispatchBeforeUnloadEvent):
(WebCore::FrameLoader::loadDifferentDocumentItem):

  • loader/cache/CachedRawResource.cpp:

(WebCore::CachedRawResource::updateBuffer):

  • loader/cache/MemoryCache.cpp:

(WebCore::MemoryCache::pruneLiveResourcesToSize):
(WebCore::MemoryCache::pruneDeadResourcesToSize):

  • page/Chrome.cpp:

(WebCore::Chrome::runModal const):

  • page/ContextMenuController.cpp:

(WebCore::ContextMenuController::handleContextMenuEvent):

  • page/DOMWindow.cpp:

(WebCore::DOMWindow::suspendForBackForwardCache):

  • page/DragController.cpp:

(WebCore::DragController::performDragOperation):

  • page/EventSource.cpp:

(WebCore::EventSource::doExplicitLoadCancellation):

  • page/FrameView.cpp:

(WebCore::FrameView::applyRecursivelyWithVisibleRect):
(WebCore::FrameView::updateEmbeddedObjects):
(WebCore::FrameView::autoSizeIfEnabled):

  • page/FrameViewLayoutContext.cpp:

(WebCore::FrameViewLayoutContext::layout):
(WebCore::FrameViewLayoutContext::runAsynchronousTasks):

  • page/csp/ContentSecurityPolicy.cpp:

(WebCore::ContentSecurityPolicy::didReceiveHeaders):

  • page/ios/EventHandlerIOS.mm:

(WebCore::EventHandler::tryToBeginDragAtPoint):

  • page/scrolling/ScrollingTree.cpp:

(WebCore::ScrollingTree::commitTreeState):

  • page/scrolling/ThreadedScrollingTree.cpp:

(WebCore::ThreadedScrollingTree::handleWheelEventAfterMainThread):

  • platform/PreviewConverter.cpp:

(WebCore::PreviewConverter::iterateClients):
(WebCore::PreviewConverter::replayToClient):

  • platform/audio/PlatformMediaSession.cpp:

(WebCore::PlatformMediaSession::clientWillBeginPlayback):

  • platform/graphics/ca/GraphicsLayerCA.cpp:

(WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
(WebCore::GraphicsLayerCA::commitLayerChangesAfterSublayers):

  • platform/graphics/mac/WebLayer.mm:

(-[WebSimpleLayer renderInContext:]):

  • platform/graphics/texmap/TextureMapperGL.cpp:

(WebCore::TextureMapperGL::drawTexture):

  • platform/graphics/texmap/TextureMapperLayer.cpp:

(WebCore::TextureMapperLayer::paintSelfAndChildrenWithReplica):
(WebCore::TextureMapperLayer::paintIntoSurface):
(WebCore::TextureMapperLayer::paintWithIntermediateSurface):
(WebCore::TextureMapperLayer::paintRecursive):

  • platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:

(WebCore::CoordinatedGraphicsLayer::purgeBackingStores):

  • platform/ios/LegacyTileLayer.mm:

(-[LegacyTileLayer renderInContext:]):

  • platform/mac/ScrollbarThemeMac.mm:

(WebCore::ScrollbarThemeMac::paint):

  • rendering/RenderFlexibleBox.cpp:

(WebCore::RenderFlexibleBox::applyStretchAlignmentToChild):

  • rendering/RenderGeometryMap.cpp:

(WebCore::RenderGeometryMap::pushMappingsToAncestor):

  • rendering/RenderInline.cpp:

(WebCore::RenderInline::computeVisibleRectInContainer const):

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::flushPendingLayerChanges):

  • rendering/RenderLayerScrollableArea.cpp:

(WebCore::RenderLayerScrollableArea::updateScrollbarsAfterLayout):

  • rendering/RenderTable.cpp:

(WebCore::RenderTable::layout):

  • rendering/svg/LegacyRenderSVGRoot.cpp:

(WebCore::LegacyRenderSVGRoot::layout):

  • rendering/svg/RenderSVGResourceContainer.cpp:

(WebCore::RenderSVGResourceContainer::markAllClientsForInvalidation):

  • rendering/svg/RenderSVGRoot.cpp:

(WebCore::RenderSVGRoot::layout):

  • storage/StorageMap.cpp:

(WebCore::StorageMap::setItemIgnoringQuota):

  • style/StyleBuilder.cpp:

(WebCore::Style::Builder::applyCustomProperty):
(WebCore::Style::Builder::applyCascadeProperty):

  • style/StyleInvalidator.cpp:

(WebCore::Style::Invalidator::invalidateWithMatchElementRuleSets):

  • style/StyleScope.cpp:

(WebCore::Style::Scope::createDocumentResolver):
(WebCore::Style::Scope::createOrFindSharedShadowTreeResolver):
(WebCore::Style::Scope::updateResolver):

  • svg/SVGPathBlender.cpp:

(WebCore::SVGPathBlender::addAnimatedPath):

  • workers/WorkerThread.cpp:

(WebCore::WorkerThread::evaluateScriptIfNecessary):

Source/WebKit:

  • NetworkProcess/storage/QuotaManager.cpp:

(WebKit::QuotaManager::handleRequests):

  • Shared/API/Cocoa/WKRemoteObjectCoder.mm:

(createEncodedObject):
(decodeObject):

  • UIProcess/API/glib/InputMethodFilter.cpp:

(WebKit::InputMethodFilter::filterKeyEvent):

  • UIProcess/API/glib/WebKitWebView.cpp:

(WebKitWebViewClient::frameDisplayed):

  • UIProcess/API/gtk/InputMethodFilterGtk.cpp:

(WebKit::InputMethodFilter::filterKeyEvent):

  • UIProcess/API/ios/WKWebViewIOS.mm:

(-[WKWebView _keyboardChangedWithInfo:adjustScrollView:]):

  • UIProcess/Cocoa/WebViewImpl.mm:

(WebKit::WebViewImpl::updateTextTouchBar):

  • UIProcess/Inspector/WebInspectorUIProxy.cpp:

(WebKit::WebInspectorUIProxy::open):
(WebKit::WebInspectorUIProxy::closeFrontendPageAndWindow):

  • UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm:

(WebKit::ScrollingTreeScrollingNodeDelegateIOS::commitStateAfterChildren):

  • UIProcess/_WKWebViewPrintFormatter.mm:

(-[_WKWebViewPrintFormatter _setSnapshotPaperRect:]):

  • UIProcess/gtk/ClipboardGtk3.cpp:

(WebKit::Clipboard::write):

  • UIProcess/gtk/WebDateTimePickerGtk.cpp:

(WebKit::WebDateTimePickerGtk::update):

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView becomeFirstResponderForWebView]):
(-[WKContentView resignFirstResponderForWebView]):
(-[WKContentView unsuppressSoftwareKeyboardUsingLastAutocorrectionContextIfNeeded]):
(-[WKContentView _elementDidFocus:userIsInteracting:blurPreviousNode:activityStateChanges:userObject:]):
(-[WKContentView _elementDidBlur]):

  • UIProcess/ios/forms/WKDateTimeInputControl.mm:

(-[WKDateTimePicker handleDatePickerPresentationDismissal]):
(-[WKDateTimePicker removeDatePickerPresentation]):

  • WebProcess/Plugins/Plugin.cpp:

(WebKit::Plugin::destroyPlugin):

  • WebProcess/WebPage/CoordinatedGraphics/CompositingCoordinator.cpp:

(WebKit::CompositingCoordinator::flushPendingLayerChanges):
(WebKit::CompositingCoordinator::purgeBackingStores):

  • WebProcess/WebPage/RemoteLayerTree/RemoteLayerTreeDrawingArea.mm:

(WebKit::RemoteLayerTreeDrawingArea::updateRendering):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::stopLoadingDueToProcessSwap):
(WebKit::WebPage::mouseEvent):
(WebKit::WebPage::keyEvent):
(WebKit::WebPage::restoreSessionInternal):
(WebKit::WebPage::dispatchTouchEvent):
(WebKit::WebPage::setInitialFocus):
(WebKit::WebPage::setActivityState):
(WebKit::WebPage::insertTextAsync):
(WebKit::WebPage::createAppHighlightInSelectedRange):

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::completeSyntheticClick):
(WebKit::WebPage::requestDragStart):
(WebKit::WebPage::requestAdditionalItemsForDragSession):
(WebKit::WebPage::selectPositionAtPoint):
(WebKit::WebPage::dynamicViewportSizeUpdate):
(WebKit::WebPage::focusTextInputContextAndPlaceCaret):

  • WebProcess/WebPage/wc/DrawingAreaWC.cpp:

(WebKit::DrawingAreaWC::updateRendering):

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::prepareToSuspend):

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:

(-[WebView updateTextTouchBar]):

  • WebView/WebViewData.mm:

(WebViewLayerFlushScheduler::layerFlushCallback):

Source/WTF:

  • wtf/RefCounter.h:

(WTF::RefCounter<T>::Count::deref):

Tools:

  • TestWebKitAPI/Tests/WTF/SetForScope.cpp:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/WKInspectorDelegate.mm:

(TEST):

  • TestWebKitAPI/mac/TestFontOptions.mm:

(-[TestFontOptions setShadowWidth:]):
(-[TestFontOptions setShadowHeight:]):
(-[TestFontOptions setShadowBlurRadius:]):
(-[TestFontOptions setHasShadow:]):
(-[TestFontOptions setForegroundColor:]):
(-[TestFontOptions setBackgroundColor:]):

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetStateToConsistentValues):
(WTR::TestController::reattachPageToWebProcess):

5:16 PM Changeset in webkit [290574] by Cameron McCormack
  • 8 edits in trunk/Source/WebCore

Add a mechanism to request a UA shadow tree update before style
https://bugs.webkit.org/show_bug.cgi?id=237224

Reviewed by Antti Koivisto.

SVG <use> elements register themselves with the document when their
shadow tree contents need updating, and this updating is done in
Document::resolveStyle. For lazy HTML <input> element UA shadow trees
(in bug 236747) we need something similar.

  • dom/Document.cpp:

(WebCore::Document::resolveStyle):
(WebCore::Document::addElementWithPendingUserAgentShadowTreeUpdate):
(WebCore::Document::removeElementWithPendingUserAgentShadowTreeUpdate):

  • dom/Document.h:
  • dom/Element.h:

(WebCore::Element::updateUserAgentShadowTree):

  • svg/SVGDocumentExtensions.cpp:

(WebCore::SVGDocumentExtensions::~SVGDocumentExtensions): Deleted.
(WebCore::SVGDocumentExtensions::addUseElementWithPendingShadowTreeUpdate): Deleted.
(WebCore::SVGDocumentExtensions::removeUseElementWithPendingShadowTreeUpdate): Deleted.

  • svg/SVGDocumentExtensions.h:

(WebCore::SVGDocumentExtensions::useElementsWithPendingShadowTreeUpdate const): Deleted.

  • svg/SVGUseElement.cpp:

(WebCore::SVGUseElement::insertedIntoAncestor):
(WebCore::SVGUseElement::removedFromAncestor):
(WebCore::SVGUseElement::updateUserAgentShadowTree):
(WebCore::SVGUseElement::invalidateShadowTree):
(WebCore::SVGUseElement::updateShadowTree): Deleted.

  • svg/SVGUseElement.h:
3:52 PM Changeset in webkit [290573] by graouts@webkit.org
  • 4 edits in trunk

[web-animations] web-animations/timing-model/animations/setting-the-timeline-of-an-animation.html is a unique failure
https://bugs.webkit.org/show_bug.cgi?id=237257

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

Mark WPT progressions.

  • web-platform-tests/web-animations/timing-model/animations/setting-the-timeline-of-an-animation-expected.txt:

Source/WebCore:

The spec has changed since we initially implemented Animation.playState and we missed one condition for
an animation's play state to be "idle".

  • animation/WebAnimation.cpp:

(WebCore::WebAnimation::playState const):

2:19 PM Changeset in webkit [290572] by Matt Woodrow
  • 4 edits in trunk

Handle reverse flow direction when converting iterator coords for a subgrid
https://bugs.webkit.org/show_bug.cgi?id=236955

Reviewed by Dean Jackson.

Source/WebCore:

When recursing into a subgrid via createForSubgrid, we convert the iterator's
position into coordinates relative to the subgrid. This handles the case where
the subgrid has a reverse flow direction (RTL vs LTR) and swaps the position
to be relative to the opposite edge.

Marks existing WPT grid-gap-007.html as passing

  • rendering/Grid.cpp:

(WebCore::GridIterator::createForSubgrid):

LayoutTests:

Marked grid-gap-007.html as now passing, and added bug annotations to
remaining subgrid failures.

2:15 PM Changeset in webkit [290571] by graouts@webkit.org
  • 5 edits in trunk

[svg] flood-opacity should be clamped to the [0,1] range
https://bugs.webkit.org/show_bug.cgi?id=237253

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt:
  • web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt:

Source/WebCore:

  • rendering/style/SVGRenderStyle.h:

(WebCore::SVGRenderStyle::setFloodOpacity):

1:19 PM Changeset in webkit [290570] by graouts@webkit.org
  • 5 edits in trunk

[svg] stroke-opacity should be clamped to the [0,1] range
https://bugs.webkit.org/show_bug.cgi?id=237254

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-002-expected.txt:
  • web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-002-expected.txt:

Source/WebCore:

  • rendering/style/SVGRenderStyle.h:

(WebCore::SVGRenderStyle::setStrokeOpacity):

12:55 PM Changeset in webkit [290569] by graouts@webkit.org
  • 5 edits in trunk

[svg] stop-opacity should be clamped to the [0,1] range
https://bugs.webkit.org/show_bug.cgi?id=237255

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-002-expected.txt:
  • web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-002-expected.txt:

Source/WebCore:

  • rendering/style/SVGRenderStyle.h:

(WebCore::SVGRenderStyle::setStopOpacity):

12:31 PM Changeset in webkit [290568] by graouts@webkit.org
  • 5 edits in trunk

[svg] fill-opacity should be clamped to the [0,1] range
https://bugs.webkit.org/show_bug.cgi?id=237252

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt:
  • web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt:

Source/WebCore:

  • rendering/style/SVGRenderStyle.h:

(WebCore::SVGRenderStyle::setFillOpacity):

11:54 AM Changeset in webkit [290567] by Matt Woodrow
  • 2 edits in trunk

2022-02-24 Matt Woodrow <Matt Woodrow>

Unreviewed, update my (Matt Woodrow) status to committer.

  • metadata/contributors.json:
11:44 AM Changeset in webkit [290566] by Chris Dumez
  • 28 edits in trunk/Source

Simplify SerializedScriptValue construction
https://bugs.webkit.org/show_bug.cgi?id=237241

Reviewed by Darin Adler.

Source/WebCore:

The 2 main factory functions for SerializedScriptValue now share the same code.
I also dropped some SerializedScriptValue API that was no longer useful.
Finally, I simplified factory functions for MessageEvent.

  • Modules/indexeddb/IDBValue.cpp:

(WebCore::IDBValue::IDBValue):

  • Modules/webaudio/AudioWorkletNode.cpp:

(WebCore::AudioWorkletNode::create):

  • bindings/js/SerializedScriptValue.cpp:

(WebCore::SerializedScriptValue::create):
(WebCore::SerializedScriptValue::toString const):
(WebCore::SerializedScriptValue::toString): Deleted.

  • bindings/js/SerializedScriptValue.h:

(WebCore::SerializedScriptValue::wireBytes const):
(WebCore::SerializedScriptValue::SerializedScriptValue):
(WebCore::SerializedScriptValue::adopt): Deleted.
(WebCore::SerializedScriptValue::data const): Deleted.
(WebCore::SerializedScriptValue::toWireBytes const): Deleted.

  • dom/BroadcastChannel.cpp:

(WebCore::BroadcastChannel::dispatchMessage):

  • dom/MessageEvent.cpp:

(WebCore::MessageEvent::MessageEvent):
(WebCore::MessageEvent::create):

  • dom/MessageEvent.h:
  • dom/MessagePort.cpp:

(WebCore::MessagePort::dispatchMessages):

  • page/DOMWindow.cpp:

(WebCore::DOMWindow::postMessage):

  • page/EventSource.cpp:

(WebCore::EventSource::dispatchMessageEvent):

  • page/History.cpp:

(WebCore::History::stateObjectAdded):

  • testing/Internals.cpp:

(WebCore::Internals::serializeObject const):
(WebCore::Internals::deserializeBuffer const):

  • workers/WorkerMessagingProxy.cpp:

(WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
(WebCore::WorkerMessagingProxy::postMessageToWorkerGlobalScope):

  • workers/service/ServiceWorkerContainer.cpp:

(WebCore::ServiceWorkerContainer::postMessage):

  • workers/shared/SharedWorkerGlobalScope.cpp:

(WebCore::SharedWorkerGlobalScope::postConnectEvent):

Source/WebKit:

Update code base to reflect SerializedScriptValue API changes.

  • Shared/API/APISerializedScriptValue.h:

(API::SerializedScriptValue::createFromWireBytes):
(API::SerializedScriptValue::dataReference const):
(API::SerializedScriptValue::adopt): Deleted.

  • Shared/SessionState.cpp:

(WebKit::PageState::encode const):

  • Shared/UserData.cpp:

(WebKit::UserData::decode):

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _evaluateJavaScript:asAsyncFunction:withSourceURL:withArguments:forceUserGesture:inFrame:inWorld:completionHandler:]):

  • UIProcess/Inspector/WebInspectorUIExtensionControllerProxy.cpp:

(WebKit::WebInspectorUIExtensionControllerProxy::evaluateScriptForExtension):
(WebKit::WebInspectorUIExtensionControllerProxy::evaluateScriptInExtensionTab):

  • UIProcess/UserContent/WebUserContentControllerProxy.cpp:

(WebKit::WebUserContentControllerProxy::didPostMessage):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::runJavaScriptInFrameInScriptWorld):

  • WebProcess/Inspector/WebInspectorUIExtensionController.cpp:

(WebKit::WebInspectorUIExtensionController::evaluateScriptForExtension):
(WebKit::WebInspectorUIExtensionController::evaluateScriptInExtensionTab):

  • WebProcess/UserContent/WebUserContentController.cpp:
  • WebProcess/WebCoreSupport/SessionStateConversion.cpp:

(WebKit::toFrameState):
(WebKit::applyFrameState):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::runJavaScript):

9:54 AM Changeset in webkit [290565] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GStreamer] media/video-src-blob-perf.html timing out likely since update to GStreamer 1.20
https://bugs.webkit.org/show_bug.cgi?id=237256

Unreviewed, gardening

Patch by Philippe Normand <pnormand@igalia.com> on 2022-02-27

  • platform/glib/TestExpectations: Flag test as timing out.
8:38 AM Changeset in webkit [290564] by ntim@apple.com
  • 10 edits in trunk

Force -webkit-user-modify used style to readonly for inert nodes
https://bugs.webkit.org/show_bug.cgi?id=237244

Reviewed by Darin Adler.

This disallows programmatic edition of contenteditable inert nodes. Edition via user-input is
already prevented by forcing pointer-events style to none.

We create a seperate effectiveUserModify, similar to effectiveUserSelect/effectivePointerEvents,
to avoid changing the computed style.

This behaviour also matches Blink & Gecko.

LayoutTests/imported/w3c:

  • web-platform-tests/inert/inert-and-contenteditable.tentative-expected.txt:

Source/WebCore:

Test: imported/w3c/web-platform-tests/inert/inert-and-contenteditable.tentative.html

  • dom/Node.cpp:

(WebCore::computeEditabilityFromComputedStyle):

  • editing/ApplyBlockElementCommand.cpp:

(WebCore::ApplyBlockElementCommand::rangeForParagraphSplittingTextNodesIfNeeded):

  • editing/ReplaceSelectionCommand.cpp:

(WebCore::ReplaceSelectionCommand::doApply):

  • rendering/EventRegion.cpp:

(WebCore::EventRegion::unite):

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::styleWillChange):

  • rendering/style/RenderStyle.h:

(WebCore::RenderStyle::effectiveUserModify const):

  • style/StyleTreeResolver.cpp:

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

8:33 AM Changeset in webkit [290563] by Chris Dumez
  • 9 edits in trunk

Call WKNavigationDelegate.didFailProvisionalNavigation even after a cross-origin navigation with COOP
https://bugs.webkit.org/show_bug.cgi?id=237071
<rdar://problem/89354367>

Reviewed by Darin Adler.

Source/WebKit:

When doing a process swap on navigation (PSON), we start a new provisional load in the new provisional
process and ask the committed process to stop all loads. Since we swap in decidePolicyForNavigationAction,
no provisional load has started in the committed process yet. If the provisional process sends us a
didFailProvisionalLoad though, we know the provisional load has failed and we take this into consideration
and notify the client app.

When doing a process swap on resource response (due to COOP), we were behaving differently and it was
causing some confusion. Since we swap on resource response, the provisional load has started in the
committed process by the time we process-swap (unlike PSON). We were also not asking for the committed
process to stop/cancel this provisional load. As a result, a provisional load would still be going on
in the committed process while another provisional load starts happening in the provisional page / process.
Then, if the provisional process would send us a didFailProvisional, we would not pass it along to the
client app. Instead we would destroy the ProvisionalPageProxy, which would tell the committed process to
stop loading and send its own didFailProvisionalLoad, and the client app would eventually get notified.

Even though the difference in behavior was confusing, it was working in most cases. There was however
an edge case where it didn't work and we would fail to tell the client app that the provisional load
had failed. In particular, we would run into trouble when navigating cross-site to a site that adopted
the COOP header. We would first do a process-swap on navigation, stop the provisional load in the committed
process A, then start a provisional load in process B. We would then get the COOP header and we would
start a new provisional load in process C. Process B would go away since we cannot have 2 provisional
pages / processes at the same time for the same WebPageProxy. Then if the provisional load fails in
process C, we would ignore the didFailProvisionalLoad from process C and destroy the provisional page.
We would tell the committed process A to stop loading, expecting it to send its own didFailProvisionalLoad
but it wouldn't happen since PSON had already stopped all loading in process A earlier when swapping to
process B.

To address the issue, we align COOP process swap with PSON process swap. We now has the committed process
to stop all loads when process swapping on resource response due to COOP. As a result, when the provisional
load fails in the provisional process, we can simply pass it along to the client, no matter if the process
swap occurred due to PSON or COOP.

Covered by new API test.

  • UIProcess/ProvisionalPageProxy.cpp:

(WebKit::ProvisionalPageProxy::~ProvisionalPageProxy):
We no longer need to tell the committed process to stop loading when the provisional page gets destroyed
and this was a process swap on resource response. The reason is that when process-swapping on navigation
response, we now drop the provisional load in the committed process right away, like in the PSON case.

(WebKit::ProvisionalPageProxy::cancel):
When cancelling a provisional load due to PSON or COOP, we need to notify the client that the provisional
load failed. We used to only to it in the PSON case. We now do it for both PSON and COOP since they
behave the same.

(WebKit::ProvisionalPageProxy::didFailProvisionalLoadForFrame):
Similarly as above, now that PSON and COOP behave the same, we need to pass the didFailProvisionalLoad
from the provisional process to the client app for both PSON and COOP (Not just PSON).

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::triggerBrowsingContextGroupSwitchForNavigation):
When triggering a process swap on resource response (due to COOP), we now stop the provisional load going
on in the committed process to be consistent with what we do in the PSON case. This way there is only a
single provisional load going on and it is happening in the provisional page / process.

Tools:

Add API test coverage (Test was written by Alex Christensen).

  • TestWebKitAPI/Tests/WebKitCocoa/Navigation.mm:

(TEST):

8:26 AM Changeset in webkit [290562] by dino@apple.com
  • 2 edits in trunk/Source/WebCore

Loading a USDZ url as the main resource renders as garbage
https://bugs.webkit.org/show_bug.cgi?id=237240
rdar://88767033

Reviewed by Antoine Quint.

We can't render a USD document if the ModelDocument feature is not enabled.

  • platform/MIMETypeRegistry.cpp:

(WebCore::MIMETypeRegistry::canShowMIMEType):

8:17 AM Changeset in webkit [290561] by graouts@webkit.org
  • 4 edits in trunk

[css-animations] implicit keyframes should be inserted after explicit keyframes with the same offset
https://bugs.webkit.org/show_bug.cgi?id=237246

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

Update WPT test added in bug 236838 to match the spec following discussion with Brian Birtles in
https://github.com/web-platform-tests/wpt/pull/32903.

  • web-platform-tests/css/css-animations/KeyframeEffect-getKeyframes.tentative.html:

Source/WebCore:

The CSS Animations spec says the following about implicit keyframes generation:

Let initial keyframe be the keyframe in keyframes with offset 0, timing function default timing
function and composite default composite.

If there is no such keyframe, let initial keyframe be a new empty keyframe with offset 0, timing
function default timing function, composite |default composite, and add it to keyframes after the
last keyframe with offset 0.

Let final keyframe be the keyframe in keyframes with offset 1, timing function default timing
function and composite default composite.

If there is no such keyframe, let final keyframe be a new empty keyframe with offset 1, timing
function default timing function and composite default composite, and add it to keyframes after
the last keyframe with offset 1.

Full details are at https://drafts.csswg.org/css-animations-2/#keyframes.

The KeyframeList::insert() method does the right thing already by adding a new keyframe after all
other keyframes with that same offset, so all we need to do is to use this method rather than
specifying explicit indexes.

  • rendering/style/KeyframeList.cpp:

(WebCore::KeyframeList::fillImplicitKeyframes):

8:03 AM Changeset in webkit [290560] by ntim@apple.com
  • 2 edits in trunk/Source/WebCore

Use hasAttributeWithoutSynchronisation for checking inert attribute in Adjuster::adjust
https://bugs.webkit.org/show_bug.cgi?id=237248

Reviewed by Dean Jackson.

hasAttributeWithoutSynchronisation should be slightly faster than hasAttribute.

  • style/StyleAdjuster.cpp:

(WebCore::Style::Adjuster::adjust const):

6:10 AM Changeset in webkit [290559] by ntim@apple.com
  • 3 edits
    2 adds in trunk

Optimize StyleSharingResolver inert checks
https://bugs.webkit.org/show_bug.cgi?id=237235

Reviewed by Youenn Fablet.

Source/WebCore:

inert is an boolean attribute, the only thing that matters for the StyleAdjuster
inertness adjustment is the presence of the attribute, not its value. E.g.
inert=false is the same as inert=inert or inert=true.

This saves getting and comparing values for those attributes, and also allows
inert=inert and inert=true or inert=false to start sharing style.

  • style/StyleSharingResolver.cpp:

(WebCore::Style::SharingResolver::canShareStyleWithElement const):

LayoutTests:

Add small test that style sharing is not wrongly applied.

  • fast/css/inert-style-sharing-expected.html: Added.
  • fast/css/inert-style-sharing.html: Added.
4:06 AM Changeset in webkit [290558] by youenn@apple.com
  • 7 edits in trunk/Source/WebKit

Exposing RemoteVideoFrameProxy::write is unneeded
https://bugs.webkit.org/show_bug.cgi?id=237212

Reviewed by Eric Carlson.

Exposing RemoteVideoFrameProxy::write is unneeded as RemoteVideoFrameProxy is immutable.
It is best to remove it as calling write() inadvertently would break things.
Renaming read() to newReadReference() to make it clear that we are creating a new read reference
that needs to be sent to GPUProcess to prevent leaks.
No change of behavior.

  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxy.cpp:

(WebKit::RemoteGraphicsContextGLProxy::copyTextureFromMedia):

  • WebProcess/GPU/media/RemoteVideoFrameProxy.cpp:

(WebKit::RemoteVideoFrameProxy::~RemoteVideoFrameProxy):
(WebKit::RemoteVideoFrameProxy::newReadReference const):
(WebKit::RemoteVideoFrameProxy::pixelBuffer const):
(WebKit::RemoteVideoFrameProxy::write const): Deleted.
(WebKit::RemoteVideoFrameProxy::read const): Deleted.

  • WebProcess/GPU/media/RemoteVideoFrameProxy.h:
  • WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp:

(WebKit::LibWebRTCCodecs::encodeFrame):

  • WebProcess/GPU/webrtc/RemoteVideoFrameObjectHeapProxyProcessor.cpp:

(WebKit::RemoteVideoFrameObjectHeapProxyProcessor::getVideoFrameBuffer):

  • WebProcess/GPU/webrtc/SharedVideoFrame.cpp:

(WebKit::SharedVideoFrameWriter::write):

3:44 AM Changeset in webkit [290557] by youenn@apple.com
  • 4 edits in trunk/Source/WebCore

Simplify CVPixelBuffer data copies in SharedVideoFrameInfo
https://bugs.webkit.org/show_bug.cgi?id=237194

Reviewed by Eric Carlson.

Remove use of vImageUnpremultiplyData_BGRA8888 which might not be correct for canvas data.
Make use of CVPixelBufferGetPlaneCount to share more code between monoplanar and biplanar formats.

Covered by existing tests.

  • platform/cocoa/CoreVideoSoftLink.cpp:
  • platform/cocoa/CoreVideoSoftLink.h:
  • platform/cocoa/SharedVideoFrameInfo.mm:

(WebCore::SharedVideoFrameInfo::isReadWriteSupported const):
(WebCore::copyToCVPixelBufferPlane):
(WebCore::SharedVideoFrameInfo::createPixelBufferFromMemory):
(WebCore::SharedVideoFrameInfo::writePixelBuffer):

3:21 AM Changeset in webkit [290556] by ntim@apple.com
  • 17 edits
    2 adds in trunk/LayoutTests

Re-import inert and <dialog> WPT
https://bugs.webkit.org/show_bug.cgi?id=237243

Reviewed by Youenn Fablet.

Upstream commit: https://github.com/web-platform-tests/wpt/commit/9261ca87db106c1f31f1ab4f54b8f4a2617cbc24

LayoutTests/imported/w3c:

  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-replaced-renderer-expected.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-replaced-renderer-ref.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-replaced-renderer.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-table-column-expected.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-table-column-ref.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-table-column.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/w3c-import.log:
  • web-platform-tests/inert/inert-and-contenteditable.tentative-expected.txt: Added.
  • web-platform-tests/inert/inert-and-contenteditable.tentative.html: Added.
  • web-platform-tests/inert/inert-iframe-hittest.tentative-expected.txt:
  • web-platform-tests/inert/inert-iframe-hittest.tentative.html:
  • web-platform-tests/inert/inert-iframe-tabbing.tentative-expected.txt:
  • web-platform-tests/inert/inert-iframe-tabbing.tentative.html:
  • web-platform-tests/inert/w3c-import.log:

LayoutTests:

  • TestExpectations:
  • platform/ios-wk2/imported/w3c/web-platform-tests/inert/inert-iframe-hittest.tentative-expected.txt:
  • platform/ios-wk2/imported/w3c/web-platform-tests/inert/inert-iframe-tabbing.tentative-expected.txt:
Note: See TracTimeline for information about the timeline view.