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

Timeline



Mar 3, 2022:

11:55 PM Changeset in webkit [290819] by youenn@apple.com
  • 4 edits in trunk/LayoutTests

fast/mediastream/getUserMedia-to-canvas-1.html and fast/mediastream/getUserMedia-to-canvas-2.html are failing on MacOS when remote video frame flag is enabled
https://bugs.webkit.org/show_bug.cgi?id=237042
<rdar://problem/89298601>

Reviewed by Eric Carlson.

Video element videoWidth/videoHeight are updated when track settings are changed,
and not when video frames being received.

This does not guarantee that videoWidth/videoHeight (main thread) are fully in sync
with the actual video frames (background thread) when there is a change of size.

We might be able to tighten this in MediaPlayerPrivateMediaStreamAVFObjC by only resorting on video frames.
In the meantime, we update the test to use requestVideoFrameCallback which provides accurate per frame metadata.

  • fast/mediastream/getUserMedia-to-canvas-1.html:
  • fast/mediastream/getUserMedia-to-canvas-2.html:
  • webrtc/routines.js:
10:58 PM Changeset in webkit [290818] by beidson@apple.com
  • 13 edits in trunk/Source/WebKit

Add a new "Daemon -> Client" message type to webpushd
https://bugs.webkit.org/show_bug.cgi?id=237391

Reviewed by Alex Christensen.

Future work will need more messages like this.
So let's add the mechanism in a small standalone patch that uses it for debug messages.

No behavior change for now.

  • NetworkProcess/Notifications/Cocoa/WebPushDaemonConnectionCocoa.mm:

(WebKit::WebPushD::handleWebPushDaemonMessage):
(WebKit::WebPushD::Connection::connectionReceivedEvent):
(WebKit::WebPushD::Connection::connectionReceivedEvent const): Deleted.

  • NetworkProcess/Notifications/WebPushDaemonConnection.cpp:

(WebKit::WebPushD::Connection::debugMessage):

  • NetworkProcess/Notifications/WebPushDaemonConnection.h:
  • NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementConnection.h:
  • NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementConnectionCocoa.mm:

(WebKit::PCM::Connection::connectionReceivedEvent):
(WebKit::PCM::Connection::connectionReceivedEvent const): Deleted.

  • Platform/IPC/DaemonConnection.h:
  • Shared/WebPushDaemonConstants.h:

(WebKit::WebPushD::daemonMessageTypeSendsReply):

  • webpushd/ICAppBundle.mm:

(WebPushD::broadcastDebugMessage):

  • webpushd/PushClientConnection.h:
  • webpushd/PushClientConnection.mm:

(WebPushD::ClientConnection::broadcastDebugMessage):
(WebPushD::ClientConnection::sendDebugMessage):
(WebPushD::ClientConnection::sendDaemonMessage const):

  • webpushd/WebPushDaemon.h:
  • webpushd/WebPushDaemon.mm:

(WebPushD::Daemon::broadcastDebugMessage):
(WebPushD::Daemon::broadcastAllConnectionIdentities):
(WebPushD::Daemon::connectionAdded):

10:38 PM Changeset in webkit [290817] by Ross Kirsling
  • 2 edits in trunk/Source/WebKit

REGRESSION(r290815): Fix even more incorrect #if ENABLE(SERVICE_WORKER) usage in NetworkProcess
https://bugs.webkit.org/show_bug.cgi?id=237461

Unreviewed build fix.

  • NetworkProcess/NetworkProcess.cpp:

The existence of NetworkProcess::{getPendingPushMessages, processPushMessages} depend on ENABLE(SERVICE_WORKER);
it is only when they exist that their implementation depends on ENABLE(BUILT_IN_NOTIFICATIONS).

10:02 PM Changeset in webkit [290816] by commit-queue@webkit.org
  • 14 edits
    2 deletes in trunk

WebGL context count is not limited for GPU process
https://bugs.webkit.org/show_bug.cgi?id=222411

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2022-03-03
Reviewed by Kenneth Russell.

Source/WebCore:

Move the context limit from the GraphicsContextGL implementation
level to WebGLRenderingContext level. This way the limit
is applied to the GPUP implementation too.

Recycle the context with the earliest activity (draw, readpixels)
instead of the creation order.

Stores the WebGL contexts to per-thread set and limits the size of the set.
The set is per-thread to support WebGL contexts in DOM as well as
offscreen canvas use-cases. Offscreen canvas is not implemented for Cocoa
but other ports may enable it.

Tested by:
LayoutTests/webgl/lose-context-after-context-lost.html
LayoutTests/webgl/many-contexts-access-after-loss.html
LayoutTests/webgl/many-contexts.html
LayoutTests/webgl/max-active-contexts-console-warning.html
LayoutTests/webgl/max-active-contexts-gc.html
LayoutTests/webgl/max-active-contexts-oldest-context-lost.html
LayoutTests/webgl/max-active-contexts-webglcontextlost-prevent-default.html

  • Headers.cmake:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::activeContexts):
(WebCore::addActiveContext):
(WebCore::removeActiveContext):
(WebCore::WebGLRenderingContextBase::WebGLRenderingContextBase):
(WebCore::WebGLRenderingContextBase::setGraphicsContextGL):
(WebCore::WebGLRenderingContextBase::destroyGraphicsContextGL):
(WebCore::WebGLRenderingContextBase::clearIfComposited):
(WebCore::WebGLRenderingContextBase::maybeRestoreContext):
(WebCore::WebGLRenderingContextBase::updateActiveOrdinal):

  • html/canvas/WebGLRenderingContextBase.h:

(WebCore::WebGLRenderingContextBase::activeOrdinal const):

  • platform/graphics/angle/GraphicsContextGLANGLE.cpp:
  • platform/graphics/cocoa/GraphicsContextGLCocoa.mm:

(WebCore::GraphicsContextGLANGLE::~GraphicsContextGLANGLE):

  • platform/graphics/cocoa/WebProcessGraphicsContextGLCocoa.mm:

(WebCore::createWebProcessGraphicsContextGL):

  • platform/graphics/opengl/GraphicsContextGLOpenGL.cpp:

(WebCore::GraphicsContextGLOpenGL::~GraphicsContextGLOpenGL):

  • platform/graphics/opengl/GraphicsContextGLOpenGLManager.cpp: Removed.
  • platform/graphics/opengl/GraphicsContextGLOpenGLManager.h: Removed.
  • platform/graphics/texmap/GraphicsContextGLTextureMapper.cpp:

(WebCore::createWebProcessGraphicsContextGL):

  • platform/graphics/texmap/GraphicsContextGLTextureMapperANGLE.cpp:

(WebCore::GraphicsContextGLANGLE::~GraphicsContextGLANGLE):

LayoutTests:

  • platform/ios-wk2/TestExpectations:
9:28 PM Changeset in webkit [290815] by Ben Nham
  • 28 edits
    2 adds in trunk

Enforce silent push quota
https://bugs.webkit.org/show_bug.cgi?id=236863

Reviewed by Brady Eidson.

Source/WebCore:

All PushSubscriptions are created with the userVisibleOnly flag set. This means that all
push events should result in a user-facing notification.

To enforce this, we use a quota system. A push subscription can process up to three silent
pushes. After three silent pushes, we remove the push subscription. To continue to receive
pushes, the user must navigate back to the website and the site must request permission to
send pushes again.

Originally we were going to use a more complicated quota system that moved subscriptions
from waking to non-waking before finally unsubscribing, but this seemed like it could lead
to subscriptions being in a partially-working state that would be hard to explain and reason
about. As a result, I've removed the wakeState column from PushDatabase and replaced it
a silentPushCount column.

To track whether or not a service worker has shown a notification while processing a push
event, we use a boolean flag on ServiceWorkerGlobalScope. This should be sufficient because
we currently only process one push event at a time.

Covered by existing and new API tests.

  • Modules/push-api/PushDatabase.cpp:

(WebCore::PushRecord::isolatedCopy const):
(WebCore::PushRecord::isolatedCopy):
(WebCore::PushDatabase::insertRecord):
(WebCore::makePushRecordFromRow):
(WebCore::PushDatabase::getRecordByTopic):
(WebCore::PushDatabase::getRecordByBundleIdentifierAndScope):
(WebCore::PushDatabase::getTopics):
(WebCore::PushDatabase::incrementSilentPushCount):
(WebCore::PushDatabase::removeRecordsByBundleIdentifierAndSecurityOrigin):

  • Modules/push-api/PushDatabase.h:
  • workers/service/ServiceWorkerGlobalScope.h:
  • workers/service/ServiceWorkerRegistration.cpp:

(WebCore::ServiceWorkerRegistration::showNotification):

  • workers/service/context/ServiceWorkerThread.cpp:

(WebCore::ServiceWorkerThread::queueTaskToFirePushEvent):

Source/WebKit:

  • If a push event doesn't result in a notification or if the associated promise rejects, then we increment the silent push count associated with that origin.
  • PushService now removes a subscription if the origin has reached its quota of silent pushes.

Covered by existing and new API tests.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::processPushMessage):

  • NetworkProcess/Notifications/NetworkNotificationManager.cpp:

(WebKit::NetworkNotificationManager::incrementSilentPushCount):
(WebKit::ReplyCaller<int>::callReply):

  • Shared/WebPushDaemonConstants.h:

(WebKit::WebPushD::messageTypeSendsReply):

  • UIProcess/API/Cocoa/WKProcessPool.mm:

(-[WKProcessPool _notificationManagerForTesting]):

  • webpushd/PushService.mm:

(WebPushD::updateTopicLists):
(WebPushD::PushService::incrementSilentPushCount):

  • webpushd/WebPushDaemon.mm:

(WebPushD::MessageInfo::incrementSilentPushCount::encodeReply):
(WebPushD::Daemon::decodeAndHandleMessage):
(WebPushD::Daemon::incrementSilentPushCount):

Tools:

Modified existing push tests to show a notification. Added a new test case to make sure that
subscriptions are removed when an origin reaches its quota of silent pushes.

  • TestWebKitAPI/TestNotificationProvider.cpp:

(TestWebKitAPI::notificationPermissions):
(TestWebKitAPI::TestNotificationProvider::TestNotificationProvider):
(TestWebKitAPI::TestNotificationProvider::~TestNotificationProvider):
(TestWebKitAPI::TestNotificationProvider::notificationPermissions):
(TestWebKitAPI::TestNotificationProvider::setPermission):

  • TestWebKitAPI/Tests/WebCore/PushDatabase.cpp:

(TestWebKitAPI::makeTemporaryDatabasePath):
(TestWebKitAPI::getTopicsSync):
(TestWebKitAPI::PushDatabaseTest::getTopics):
(TestWebKitAPI::PushDatabaseTest::removeRecordsByBundleIdentifierAndSecurityOrigin):
(TestWebKitAPI::PushDatabaseTest::incrementSilentPushCount):
(TestWebKitAPI::operator==):
(TestWebKitAPI::TEST_F):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/cocoa/HTTPServer.mm:

(TestWebKitAPI::HTTPServer::origin const):

LayoutTests:

Update PushEvent tests to check that notifications are displayed.

  • http/wpt/push-api/pushEvent.any.js:

(promise_test.async const):
(promise_test.async if):

  • http/wpt/push-api/pushEvent.any.serviceworker-expected.txt:
8:40 PM Changeset in webkit [290814] by Ben Nham
  • 2 edits in trunk/Source/WebKit

Allow webpushd to launch browser in background
https://bugs.webkit.org/show_bug.cgi?id=237114

Reviewed by Brady Eidson.

Now that webpushd is sandboxed on Mac (r289566), the LaunchServices SPI call to launch
Safari is now failing, because LaunchServices goes down a different path when there is a
sandboxed caller. In particular, it fails to launch Safari because Safari doesn't register
for the webkit-app-launch scheme. Safari also doesn't want to list this scheme in its plist.

For now, to unblock our testing, we're giving ourselves an entitlement to restore the
pre-sandboxed behavior of being able to launch Safari even though it doesn't register for
the webkit-app-launch scheme. We are still in discussions with LaunchServices and Safari
about if there is a better and more restrictive way of granting ourselves this ability.

  • Scripts/process-entitlements.sh:
8:08 PM Changeset in webkit [290813] by Devin Rousso
  • 35 edits
    5 adds in trunk/Source

[GPU Process] dont load Apple Pay button/logo PDFs in the WebProcess
https://bugs.webkit.org/show_bug.cgi?id=237177

Reviewed by Simon Fraser.

Source/WebCore:

  • platform/graphics/SystemImage.h: Added.

(WebCore::SystemImage::draw const):
(WebCore::SystemImage::SystemImage):
Introduce a new extendable class SystemImage that represents a collection of arguments
and methodology (that uses those arguments) to draw something from the system.
This patch introduces two concrete uses:

  • ApplePayButtonSystemImage uses PassKit SPI to draw an Apple Pay button.
  • ApplePayLogoSystemImage loads a PDF file of the Apple Pay logo from inside PassKit.

This architecture was chosen so that GraphicsContext doesn't have to know about Apple Pay
specific things, instead only dealing with a very generic interface (whos subclasses know
more specifically what to do with the data they're given).

  • Modules/applepay/ApplePayButtonSystemImage.h: Added.

(WebCore::ApplePayButtonSystemImage::create):
(WebCore::ApplePayButtonSystemImage::ApplePayButtonSystemImage):
(WebCore::ApplePayButtonSystemImage::encode const):
(WebCore::ApplePayButtonSystemImage::decode):
(isType):

  • Modules/applepay/ApplePayButtonSystemImage.mm: Added.

(WebCore::toPKPaymentButtonType):
(WebCore::toPKPaymentButtonStyle):
(WebCore::ApplePayButtonSystemImage::draw const):

  • css/CSSPrimitiveValueMappings.h:
  • rendering/style/RenderStyle.h:
  • rendering/style/RenderStyleConstants.cpp:
  • rendering/style/RenderStyleConstants.h:

Drive-by: Move ApplePayButtonStyle and ApplePayButtonType to ApplePayButtonSystemImage.h
so they can be used elsewhere (e.g. GPUProcess) without having to include everything else.

  • Modules/applepay/ApplePayLogoSystemImage.h: Added.

(WebCore::ApplePayLogoSystemImage::create):
(WebCore::ApplePayLogoSystemImage::ApplePayLogoSystemImage):
(WebCore::ApplePayLogoSystemImage::encode const):
(WebCore::ApplePayLogoSystemImage::decode):
(isType):

  • Modules/applepay/ApplePayLogoSystemImage.mm: Added.

(WebCore::passKitBundle):
(WebCore::loadPassKitPDFPage):
(WebCore::applePayLogoWhite):
(WebCore::applePayLogoBlack):
(WebCore::applePayLogoForStyle):
(WebCore::ApplePayLogoSystemImage::draw const):
Add a new ApplePayLogoStyle so that the WebProcess isn't able to provide an arbitrary PDF
to load when rendering -webkit-named-image(apple-pay-logo-[white,black]).

  • platform/cocoa/ThemeCocoa.mm:

(WebCore::ThemeCocoa::drawNamedImage const):
(WebCore::fitContextToBox): Deleted.
(WebCore::passKitBundle): Deleted.
(WebCore::loadPassKitPDFPage): Deleted.
(WebCore::applePayButtonLogoBlack): Deleted.
(WebCore::applePayButtonLogoWhite): Deleted.
(WebCore::drawApplePayButton): Deleted.

  • rendering/RenderThemeCocoa.mm:

(WebCore::RenderThemeCocoa::paintApplePayButton):
(WebCore::toPKPaymentButtonStyle): Deleted.
(WebCore::toPKPaymentButtonType): Deleted.
Move the logic that draws the Apple Pay button to a method on GraphicsContext so that it
can hook into the various GPUProcess flags/systems.

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

(WebCore::GraphicsContext::drawSystemImage): Added.

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

(WebCore::BifurcatedGraphicsContext::drawSystemImage): Added.

  • platform/graphics/NullGraphicsContext.h:

(WebCore::NullGraphicsContext::drawSystemImage): Added.

  • platform/graphics/displaylists/DisplayList.cpp:

(WebCore::DisplayList::DisplayList::append):

  • platform/graphics/displaylists/DisplayListItemBuffer.cpp:

(WebCore::DisplayList::ItemHandle::apply):
(WebCore::DisplayList::ItemHandle::destroy):
(WebCore::DisplayList::ItemHandle::safeCopy const):

  • platform/graphics/displaylists/DisplayListItemType.h:
  • platform/graphics/displaylists/DisplayListItemType.cpp:

(WebCore::DisplayList::sizeOfItemInBytes):
(WebCore::DisplayList::isDrawingItem):
(WebCore::DisplayList::isInlineItem):

  • platform/graphics/displaylists/DisplayListItems.h:

(WebCore::DisplayList::DrawSystemImage::DrawSystemImage): Added.
(WebCore::DisplayList::DrawSystemImage::systemImage const): Added.
(WebCore::DisplayList::DrawSystemImage::destination const): Added.
(WebCore::DisplayList::DrawSystemImage::globalBounds const): Added.
(WebCore::DisplayList::DrawSystemImage::localBounds const): Added.
(WebCore::DisplayList::DrawSystemImage::encode const): Added.
(WebCore::DisplayList::DrawSystemImage::decode): Added.

  • platform/graphics/displaylists/DisplayListItems.cpp:

(WebCore::DisplayList::DrawSystemImage::apply const): Added.
(WebCore::DisplayList::operator<<):

  • platform/graphics/displaylists/DisplayListRecorder.h:
  • platform/graphics/displaylists/DisplayListRecorder.cpp:

(WebCore::DisplayList::Recorder::drawSystemImage): Added.

  • platform/graphics/displaylists/DisplayListRecorderImpl.h:
  • platform/graphics/displaylists/DisplayListRecorderImpl.cpp:

(WebCore::DisplayList::RecorderImpl::recordDrawSystemImage): Added.
Add new DrawSystemImage display list item to handle GPUProcess drawing of SystemImage.

  • Headers.cmake:
  • Sources.txt:
  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • Modules/model-element/scenekit/SceneKitModelLoaderUSD.mm:

Drive-by: Unified sources build fix.

Source/WebKit:

See Source/WebCore/ChangeLog for an explanation of SystemImage.

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

(IPC::ArgumentCoder<Ref<SystemImage>>::encode): Added.
(IPC::ArgumentCoder<Ref<SystemImage>>::decode): Added.
Support sending SystemImage (technically Ref<SystemImage>) across processes.

  • GPUProcess/graphics/RemoteDisplayListRecorder.messages.in:
  • GPUProcess/graphics/RemoteDisplayListRecorder.h:
  • GPUProcess/graphics/RemoteDisplayListRecorder.cpp:

(WebKit::RemoteDisplayListRecorder::drawSystemImage): Added.

  • WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.h:
  • WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.cpp:

(WebKit::RemoteDisplayListRecorderProxy::recordDrawSystemImage): Addded.
Add new DrawSystemImage display list item.

  • Scripts/webkit/messages.py:

(class_template_headers):
Add support for Ref<T> in IPC messages.

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

Element with position: sticky after sticking, starts to move incorrectly when scrolling
https://bugs.webkit.org/show_bug.cgi?id=231953
<rdar://84662329>

Reviewed by Sam Weinig.

Source/WebCore:

Sometimes we'd fail to push new StickyPositionViewportConstraints to the scrolling
tree, because operator== failed to compare m_constrainingRectAtLastLayout. This breaks
the requirement that the "last committed scroll position" for the overflow scrolling
node has to be updated in the same commit as the "constraining-rect-at-last-layout"
on the sticky node.

Test: scrollingcoordinator/scrolling-tree/sticky-in-overflow-stale-constraints.html

  • page/scrolling/ScrollingConstraints.cpp:

(WebCore::operator<<):

  • page/scrolling/ScrollingConstraints.h:

(WebCore::StickyPositionViewportConstraints::operator== const):

LayoutTests:

  • platform/ios-wk2/scrollingcoordinator/scrolling-tree/sticky-in-overflow-stale-constraints-expected.txt: Added.
  • scrollingcoordinator/scrolling-tree/sticky-in-overflow-stale-constraints-expected.txt: Added.
  • scrollingcoordinator/scrolling-tree/sticky-in-overflow-stale-constraints.html: Added.
6:40 PM Changeset in webkit [290811] by Dewei Zhu
  • 10 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 Jonathan Bedard.

Relanding 290583 with fix.
Add support to log http requests during benchmark run for diagnostic purpose.
AutoInstall sets 'AUTOINSTALL_CA_CERT_PATH' to environment variables when certificate is specified,
and uses 'AUTOINSTALL_CA_CERT_PATH' when it's present in environment variables. This ensures scripts invoked
from subprocess can use autoinstalled correcctly.

  • Scripts/libraries/webkitcorepy/webkitcorepy/autoinstall.py:

(AutoInstall):
(AutoInstall.set_index):

  • 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 with specified implicit dependencies.

  • 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/248047@main

6:19 PM Changeset in webkit [290810] by Jonathan Bedard
  • 4 edits in trunk/Tools

[git-webkit] Handle new PR with old branch name
https://bugs.webkit.org/show_bug.cgi?id=237457
<rdar://problem/89788939>

Reviewed by Dewei Zhu.

  • Tools/Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py:

(PullRequest.main):

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

5:38 PM Changeset in webkit [290809] by Russell Epstein
  • 1 copy in tags/Safari-614.1.5.6

Tag Safari-614.1.5.6.

5:38 PM Changeset in webkit [290808] by Russell Epstein
  • 1 delete in tags/Safari-614.1.5.6

Remove tag.

5:36 PM Changeset in webkit [290807] by Russell Epstein
  • 26 edits
    12 adds in branches/safari-614.1.5-branch/Source

Cherry-pick r290805. rdar://problem/89053248

Copy WebKit frameworks and XPC processes to Secondary Path
https://bugs.webkit.org/show_bug.cgi?id=237394

Reviewed by Saam Barati.

Source/JavaScriptCore:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/Base.xcconfig:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.

Source/ThirdParty/ANGLE:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • ANGLE.xcodeproj/project.pbxproj:
  • Configurations/ANGLE-dynamic.xcconfig:
  • scripts/copy-frameworks-to-secondary-path.sh: Added.

Source/ThirdParty/libwebrtc:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/libwebrtc.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • libwebrtc.xcodeproj/project.pbxproj:

Source/WebCore:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/WebCore.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • WebCore.xcodeproj/project.pbxproj:

Source/WebGPU:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/WebGPU.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • WebGPU.xcodeproj/project.pbxproj:

Source/WebInspectorUI:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/WebInspectorUIFramework.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • WebInspectorUI.xcodeproj/project.pbxproj:

Source/WebKit:

Added build configuration variables and scripts to copy the built Framework as well as the XPC services
to the SYSTEM_SECONDARY_CONTENT_PATH when it is set. When copying the XPC services, we update the XPC
binaries to reference the frameworks from the SYSTEM_SECONDARY_CONTENT_PATH by updating
DYLD_VERSIONED_FRAMEWORK_PATH.

  • Configurations/Base.xcconfig:
  • Configurations/WebKitSwift.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • Scripts/copy-xpc-services-to-secondary-path.sh: Added.
  • Scripts/update-dyld-environment-load-command: Added.
  • Scripts/webkitpy: Added.
  • Scripts/webkitpy/mach_o.py: Added. (_utf8_bytes_to_str): (_mach_o_int_field): (_mach_o_int_field._get_mach_o_int_field): (_mach_o_int_field._set_mach_o_int_field): (_mach_o_int_field._set_mach_o_int_field.func): (_mach_o_chararray_field): (_mach_o_chararray_field._get_mach_o_chararray_field): (_mach_o_chararray_field._set_mach_o_chararray_field): (_mach_o_chararray_field._set_mach_o_chararray_field.func): (_mach_o_varchar_field): (_mach_o_varchar_field._get_mach_o_varchar_field): (_mach_o_varchar_field._set_mach_o_varchar_field): (_mach_o_varchar_field._set_mach_o_varchar_field.func): (MachOCommand): (MachOCommand.init): (MachOSourceVersionCommand): (MachOSourceVersionCommand.version_str): (MachOSection): (MachOSection.init): (MachOSegmentCommand): (MachOSection32): (MachOSegment32Command): (MachOSegment32Command.init): (MachOSection64): (MachOSegment64Command): (MachOSegment64Command.init): (MachOLoadDylibCommand): (MachOLoadDylibCommand._version_str): (MachOLoadDylibCommand.compatibility_version_str): (MachOLoadDylibCommand.current_version_str): (MachODyldEnvironmentCommand): (MachODyldEnvironmentCommand.variable): (MachODyldEnvironmentCommand.value): (MachODyldEnvironmentCommand.build): (MachOIDDylibCommand): (MachOHeader): (MachOHeader.init): (MachOHeader.used_header_size): (MachOHeader.total_header_size): (MachOHeader.available_header_size): (MachOHeader.architecture_name): (MachOHeader.id_command): (MachOHeader.dyld_env_commands): (MachOHeader.dyld_versioned_framework_paths): (MachOHeader.filter_commands): (MachOHeader.update_file): (MachOHeader.parse_command): (MachOHeader32LE): (MachOHeader32LE.init): (MachOHeader64LE): (MachOHeader64LE.init): (MachOFile): (MachOFile.init): (is_macho_bytes): (is_macho_file): (enumerate_macho_files):
  • WebKit.xcodeproj/project.pbxproj:

Source/WebKitLegacy:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • WebKitLegacy.xcodeproj/project.pbxproj:
  • scripts/copy-frameworks-to-secondary-path.sh: Added.

Source/WebKitLegacy/mac:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/Base.xcconfig:

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

5:32 PM Changeset in webkit [290806] by sihui_liu@apple.com
  • 9 edits in trunk

Text manipulation does not observe updated title element
https://bugs.webkit.org/show_bug.cgi?id=237435
rdar://87318842

Reviewed by Wenson Hsieh.

Source/WebCore:

TextManipulationController now monitors two types of nodes (after first-time manipulation):
(1) manipulated nodes with content update
(2) non-manipulated nodes (newly displayed or newly added)
We should make sure title element gets added to set (1) if it's newly created, and gets added to set (2) if its
text content is updated.

New test: TextManipulation.CompleteTextManipulationForTitleElement

  • dom/Document.cpp:

(WebCore::Document::setTitle):

  • dom/Text.cpp:

(WebCore::Text::setDataAndUpdate):

  • editing/TextManipulationController.cpp:

(WebCore::TextManipulationController::didUpdateContentForNode):
(WebCore::TextManipulationController::didAddOrCreateRendererForNode):
(WebCore::TextManipulationController::scheduleObservationUpdate):
(WebCore::TextManipulationController::replace):
(WebCore::TextManipulationController::didCreateRendererForElement): Deleted.
(WebCore::TextManipulationController::didUpdateContentForText): Deleted.
(WebCore::TextManipulationController::didCreateRendererForTextNode): Deleted.

  • editing/TextManipulationController.h:
  • html/HTMLTitleElement.cpp:
  • rendering/updating/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::createRenderer):
(WebCore::RenderTreeUpdater::createTextRenderer):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:

(TestWebKitAPI::TEST):

5:26 PM Changeset in webkit [290805] by msaboff@apple.com
  • 26 edits
    14 adds in trunk/Source

Copy WebKit frameworks and XPC processes to Secondary Path
https://bugs.webkit.org/show_bug.cgi?id=237394

Reviewed by Saam Barati.

Source/JavaScriptCore:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/Base.xcconfig:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.

Source/ThirdParty/ANGLE:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • ANGLE.xcodeproj/project.pbxproj:
  • Configurations/ANGLE-dynamic.xcconfig:
  • scripts/copy-frameworks-to-secondary-path.sh: Added.

Source/ThirdParty/libwebrtc:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/libwebrtc.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • libwebrtc.xcodeproj/project.pbxproj:

Source/WebCore:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/WebCore.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • WebCore.xcodeproj/project.pbxproj:

Source/WebGPU:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/WebGPU.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • WebGPU.xcodeproj/project.pbxproj:

Source/WebInspectorUI:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/WebInspectorUIFramework.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • WebInspectorUI.xcodeproj/project.pbxproj:

Source/WebKit:

Added build configuration variables and scripts to copy the built Framework as well as the XPC services
to the SYSTEM_SECONDARY_CONTENT_PATH when it is set. When copying the XPC services, we update the XPC
binaries to reference the frameworks from the SYSTEM_SECONDARY_CONTENT_PATH by updating
DYLD_VERSIONED_FRAMEWORK_PATH.

  • Configurations/Base.xcconfig:
  • Configurations/WebKitSwift.xcconfig:
  • Scripts/copy-frameworks-to-secondary-path.sh: Added.
  • Scripts/copy-xpc-services-to-secondary-path.sh: Added.
  • Scripts/update-dyld-environment-load-command: Added.
  • Scripts/webkitpy: Added.
  • Scripts/webkitpy/mach_o.py: Added.

(_utf8_bytes_to_str):
(_mach_o_int_field):
(_mach_o_int_field._get_mach_o_int_field):
(_mach_o_int_field._set_mach_o_int_field):
(_mach_o_int_field._set_mach_o_int_field.func):
(_mach_o_chararray_field):
(_mach_o_chararray_field._get_mach_o_chararray_field):
(_mach_o_chararray_field._set_mach_o_chararray_field):
(_mach_o_chararray_field._set_mach_o_chararray_field.func):
(_mach_o_varchar_field):
(_mach_o_varchar_field._get_mach_o_varchar_field):
(_mach_o_varchar_field._set_mach_o_varchar_field):
(_mach_o_varchar_field._set_mach_o_varchar_field.func):
(MachOCommand):
(MachOCommand.init):
(MachOSourceVersionCommand):
(MachOSourceVersionCommand.version_str):
(MachOSection):
(MachOSection.init):
(MachOSegmentCommand):
(MachOSection32):
(MachOSegment32Command):
(MachOSegment32Command.init):
(MachOSection64):
(MachOSegment64Command):
(MachOSegment64Command.init):
(MachOLoadDylibCommand):
(MachOLoadDylibCommand._version_str):
(MachOLoadDylibCommand.compatibility_version_str):
(MachOLoadDylibCommand.current_version_str):
(MachODyldEnvironmentCommand):
(MachODyldEnvironmentCommand.variable):
(MachODyldEnvironmentCommand.value):
(MachODyldEnvironmentCommand.build):
(MachOIDDylibCommand):
(MachOHeader):
(MachOHeader.init):
(MachOHeader.used_header_size):
(MachOHeader.total_header_size):
(MachOHeader.available_header_size):
(MachOHeader.architecture_name):
(MachOHeader.id_command):
(MachOHeader.dyld_env_commands):
(MachOHeader.dyld_versioned_framework_paths):
(MachOHeader.filter_commands):
(MachOHeader.update_file):
(MachOHeader.parse_command):
(MachOHeader32LE):
(MachOHeader32LE.init):
(MachOHeader64LE):
(MachOHeader64LE.init):
(MachOFile):
(MachOFile.init):
(is_macho_bytes):
(is_macho_file):
(enumerate_macho_files):

  • WebKit.xcodeproj/project.pbxproj:

Source/WebKitLegacy:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • WebKitLegacy.xcodeproj/project.pbxproj:
  • scripts/copy-frameworks-to-secondary-path.sh: Added.

Source/WebKitLegacy/mac:

Added build configuration variables and scripts to copy the built Framework to the SYSTEM_SECONDARY_CONTENT_PATH
when it is set.

  • Configurations/Base.xcconfig:
5:21 PM Changeset in webkit [290804] by Alan Coon
  • 1 copy in tags/Safari-614.1.5.6

Tag Safari-614.1.5.6.

5:08 PM Changeset in webkit [290803] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebCore

Allow [SecureContext] extended attribute on namespaces.
https://bugs.webkit.org/show_bug.cgi?id=237401

Patch by Dan Glastonbury <djg@apple.com> on 2022-03-03
Reviewed by Alexey Shvayka.

  • bindings/scripts/IDLAttributes.json:

Enable SecureContext as a valid extended attribute on namespace.

  • bindings/scripts/test/BindingTestGlobalConstructors.idl:
  • bindings/scripts/test/JS/*: Updated
  • bindings/scripts/test/TestNamespaceObject.idl:

Added [SecureContext] to namespace

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

[JSC] Update wasm branch hinting
https://bugs.webkit.org/show_bug.cgi?id=237411

Patch by Tom Tartarin <tom@leaningtech.com> on 2022-03-03
Reviewed by Yusuke Suzuki.

JSTests:

Simplify the module tested with the updated format.

  • wasm/branch-hints/branchHintsModule.wasm:
  • wasm/branch-hints/branchHintsSection.js:

Source/JavaScriptCore:

Change the section's name.
Clarify semantics in the parser.

  • wasm/WasmBranchHintsSectionParser.cpp:

(JSC::Wasm::BranchHintsSectionParser::parse):

  • wasm/WasmSectionParser.cpp:

(JSC::Wasm::SectionParser::parseCustom):

5:04 PM Changeset in webkit [290801] by commit-queue@webkit.org
  • 2 edits in trunk

Add Dan Glastonbury's name to contributors.json
https://bugs.webkit.org/show_bug.cgi?id=237453

Patch by Dan Glastonbury <djg@apple.com> on 2022-03-03
Reviewed by Alan Bujtas.

  • metadata/contributors.json:
4:57 PM Changeset in webkit [290800] by commit-queue@webkit.org
  • 2 edits in trunk

Add myself (Anjali Kumar) to contributors.json
https://bugs.webkit.org/show_bug.cgi?id=237449

Patch by Anjali Kumar <anjalik_22@apple.com> on 2022-03-03
Reviewed by Patrick Angle.

  • metadata/contributors.json: Added myself.
4:53 PM Changeset in webkit [290799] by Lauro Moura
  • 7 edits in trunk/Tools

[Python3] Switch a few more glib scripts to Python3
https://bugs.webkit.org/show_bug.cgi?id=237442

Reviewed by Adrian Perez de Castro.

  • Scripts/check-for-global-bss-symbols-in-webkitgtk-libs: Update

shebang.
(bss_symbols): Decode Popen bytes output.

  • gtk/jhbuildrc: Update shebang.
  • gtk/ycm_extra_conf.py: Ditto.
  • jhbuild/jhbuild-wrapper: Ditto.

(jhbuild_at_expected_revision): Decode Popen bytes output.

  • jhbuild/jhbuildrc_common.py: Remove uneeded shebang.
  • wpe/jhbuildrc: Update shebang.
3:46 PM Changeset in webkit [290798] by Robert Jenner
  • 3 edits in trunk/Source/WebKit

Unreviewed, reverting r290752.

r290752 broke mutliple tests, slowing down the iOS15 EWS
queue.

Reverted changeset:

"[iOS] Hard link AVPictureInPictureController"
https://bugs.webkit.org/show_bug.cgi?id=237227
https://commits.webkit.org/r290752

3:25 PM Changeset in webkit [290797] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

WKContentView should explicitly request the system pointer in the fallback case
https://bugs.webkit.org/show_bug.cgi?id=237410
<rdar://79198381>

Reviewed by Anders Carlsson.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView pointerRegionForPositionInformation:point:]):
(-[WKContentView pointerInteraction:styleForRegion:]):
Instead of assuming a nil region and nil style will provide the system
pointer, provide a region the size of the WKContentView and explicitly
request the system pointer shape.

Also, drive-by adopt the API systemPointerStyle instead of the
deprecated SPI version.

2:51 PM Changeset in webkit [290796] by Jonathan Bedard
  • 7 edits in trunk/Tools

[webkitcorepy] Disable prompt when saving credentials
https://bugs.webkit.org/show_bug.cgi?id=237438
<rdar://problem/89764417>

Reviewed by Aakash Jain.

  • Tools/Scripts/libraries/webkitbugspy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitbugspy/webkitbugspy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py:

(Tracker.credentials): Pass 'save' to webkitcorepy.credentials.

  • Tools/Scripts/libraries/webkitcorepy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitcorepy/webkitcorepy/credentials.py:

(credentials): Unless caller explicitly disables saving, assume that all credentials
should be saved to a system's keyring.

  • Tools/Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/setup.py:

(Setup.github): Automatically save any prompted credentials.
(Setup.git): Ditto.

  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/remote/git_hub.py:

(GitHub.credentials): Pass 'save' to github.Tracker.credentials.

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

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

[macOS] WebContent processes crash with XPC_EXIT_REASON_SIGTERM_TIMEOUT when logging out
https://bugs.webkit.org/show_bug.cgi?id=237398
<rdar://88940229>

Reviewed by Darin Adler.

Because we don't use RunningBoard on macOS, we leak an OS transaction to control the lifetime of our XPC
services ourselves. However, one of the side effects of leaking this transaction is that the default SIGTERM
handler doesn't cleanly exit our XPC services when logging out or rebooting. This led to crashes with
XPC_EXIT_REASON_SIGTERM_TIMEOUT as termination reason (rdar://88940229).

To address the issue, we now set our own SIGTERM handler that releases the OS transaction and calls the
default SIGTERM handler to exit cleanly. In the future, we should likely adopt RunningBoard on macOS and
control our lifetime via process assertions instead of leaking this OS transaction.

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceEntryPoint.h:

(WebKit::XPCServiceInitializer):

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceEntryPoint.mm:

(WebKit::setOSTransaction):
(WebKit::XPCServiceExit):
(WebKit::osTransaction): Deleted.

2:07 PM Changeset in webkit [290794] by Wenson Hsieh
  • 9 edits in trunk/Source/WebKit

[iOS] Further reduce hangs underneath -[WKContentView requestAutocorrectionContextWithCompletionHandler:]
https://bugs.webkit.org/show_bug.cgi?id=237387
rdar://89654600

Reviewed by Tim Horton.

Tweak the mitigations landed in r288925 to be even more aggressive. Currently, we preemptively send an
autocorrection context from the web process to the UI process after receiving an IPC message from the UI process
indicating that an input view has been shown. However, this message might arrive too late in cases where the web
process hangs immediately after we're done setting element focus, within the very same runloop; in such a
scenario, we'll still end up hanging underneath the sync autocorrection request underneath -_elementDidFocus:
in the UI process.

We can instead make this mitigation even more aggressive, by setting a flag on WebPage when we're about to
propagate an ElementDidFocus message to the UI process that (in lieu of the WebKit client) would normally
cause the keyboard to appear. During the next DOM selection change, we then consult this flag and preemptively
send an autocorrection context to the UI process.

Additionally, remove another safeguard in the original change in r288925 which effectively invalidated the
cached autocorrection context after the end of the runloop by setting _autocorrectionContextNeedsUpdate. This
was only done to narrow the scope of the fix to just the scenario where UIKit requests autocorrection contexts
multiple times in the same runloop iteration. However, this appears to be insufficient to tackle more scenarios
where UIKit frequently requests autocorrection contexts even though the selection has not changed; hopefully, by
leaving _autocorrectionContextNeedsUpdate := NO, we can mitigate some of these other cases.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView requestAutocorrectionContextWithCompletionHandler:]):

  • WebProcess/Plugins/PDF/PDFPlugin.mm:

(WebKit::PDFPlugin::notifySelectionChanged):

  • WebProcess/WebCoreSupport/WebEditorClient.cpp:

(WebKit::WebEditorClient::respondToChangedSelection):

  • WebProcess/WebCoreSupport/ios/WebChromeClientIOS.mm:

(WebKit::WebChromeClient::notifyRevealedSelectionByScrollingFrame):
(WebKit::WebChromeClient::didLayout):

  • WebProcess/WebCoreSupport/ios/WebEditorClientIOS.mm:

(WebKit::WebEditorClient::overflowScrollPositionChanged):
(WebKit::WebEditorClient::subFrameScrollPositionChanged):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::didScrollSelection):
(WebKit::WebPage::didChangeSelection):

Split didChangeSelection into two methods: didScrollSelection, which is invoked from codepaths where we're
scheduling an editor state after overflow or mainframe scrolling, and didChangeSelection, which now takes a
Frame indicating the frame that contains the changed selection. On iOS, we handle this by both scheduling an
editor state update, but also preemptively sending the autocorrection context to the UI process if we've just
focused an element that will probably cause the keyboard to appear (unless the client explicitly prevents it).

Note that we must check the frame containing the changed selection and bail if the render tree is in the
middle of being destroyed, so that we don't end up triggering layout (and release asserting) in the case where
we're clearing the selection during document teardown.

(WebKit::WebPage::resetFocusedElementForFrame):
(WebKit::WebPage::elementDidFocus):
(WebKit::WebPage::elementDidBlur):
(WebKit::WebPage::didCommitLoad):
(WebKit::WebPage::didChangeOverflowScrollPosition): Deleted.

  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::setIsShowingInputViewForFocusedElement):

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::updateSelectionAppearance):

Pass in frame to didChangeSelection.

(WebKit::WebPage::setIsShowingInputViewForFocusedElement): Deleted.

Move this back into the header, now that it's a straightforward setter again.

1:51 PM Changeset in webkit [290793] by Jonathan Bedard
  • 7 edits in trunk/Tools

[git-webkit] Open pre-populated GitHub page for new tokens
https://bugs.webkit.org/show_bug.cgi?id=237436
<rdar://problem/89763053>

Reviewed by Ryan Haddad.

GitHub gives us a way to pre-populate its token generation web page. We should
open this page with appropriate arguments during setup.

  • Tools/Scripts/libraries/webkitbugspy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitbugspy/webkitbugspy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py:

(Tracker.credentials): Make 'prompt' into a function, allowing us to open a url
and change the prompt based on the success of opening the url.

  • Tools/Scripts/libraries/webkitcorepy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitcorepy/webkitcorepy/credentials.py:

(credentials): Allow 'prompt' to be callable.

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

1:19 PM Changeset in webkit [290792] by Lauro Moura
  • 3 edits in trunk/Tools

[build.webkit.org] Add GTK queue using clang
https://bugs.webkit.org/show_bug.cgi?id=229637

Reviewed by Michael Catanzaro.

This commit adds a specific queue to build with clang in place of GCC.
It will help cover both toolchains and catch bugs and warnings
that happen to be raised by/to affect only clang.

Initially, it'll be a build-only queue, moving to a complete build and
tester in the future. It'll use clang-12, the version available in the
current SDK used by GTK and WPE.

  • CISupport/build-webkit-org/config.json:
  • CISupport/build-webkit-org/factories_unittest.py:

(TestExpectedBuildSteps):

1:02 PM Changeset in webkit [290791] by mmaxfield@apple.com
  • 40 edits in trunk/Source/WebGPU

[WebGPU] Abide by the WebKit Style Guide
https://bugs.webkit.org/show_bug.cgi?id=237437

Reviewed by Darin Adler.

The style guide says "Do not place a space between the type name and the protocol name."

  • WebGPU/Adapter.h:

(WebGPU::Adapter::create):

  • WebGPU/Adapter.mm:

(WebGPU::Adapter::Adapter):
(WebGPU::deviceMeetsRequiredLimits):

  • WebGPU/BindGroup.h:

(WebGPU::BindGroup::create):
(WebGPU::BindGroup::vertexArgumentBuffer const):
(WebGPU::BindGroup::fragmentArgumentBuffer const):
(WebGPU::BindGroup::computeArgumentBuffer const):

  • WebGPU/BindGroup.mm:

(WebGPU::Device::createBindGroup):
(WebGPU::BindGroup::BindGroup):

  • WebGPU/BindGroupLayout.h:

(WebGPU::BindGroupLayout::create):
(WebGPU::BindGroupLayout::vertexArgumentEncoder const):
(WebGPU::BindGroupLayout::fragmentArgumentEncoder const):
(WebGPU::BindGroupLayout::computeArgumentEncoder const):

  • WebGPU/BindGroupLayout.mm:

(WebGPU::Device::createBindGroupLayout):
(WebGPU::BindGroupLayout::BindGroupLayout):

  • WebGPU/Buffer.h:

(WebGPU::Buffer::create):
(WebGPU::Buffer::buffer const):

  • WebGPU/Buffer.mm:

(WebGPU::Buffer::Buffer):

  • WebGPU/CommandBuffer.h:

(WebGPU::CommandBuffer::create):
(WebGPU::CommandBuffer::commandBuffer const):

  • WebGPU/CommandBuffer.mm:

(WebGPU::CommandBuffer::CommandBuffer):

  • WebGPU/CommandEncoder.h:

(WebGPU::CommandEncoder::create):

  • WebGPU/CommandEncoder.mm:

(WebGPU::CommandEncoder::CommandEncoder):

  • WebGPU/ComputePassEncoder.h:

(WebGPU::ComputePassEncoder::create):

  • WebGPU/ComputePassEncoder.mm:

(WebGPU::ComputePassEncoder::ComputePassEncoder):

  • WebGPU/ComputePipeline.h:

(WebGPU::ComputePipeline::create):
(WebGPU::ComputePipeline::computePipelineState const):

  • WebGPU/ComputePipeline.mm:

(WebGPU::createLibrary):
(WebGPU::createFunction):
(WebGPU::createComputePipelineState):
(WebGPU::ComputePipeline::ComputePipeline):

  • WebGPU/Device.h:
  • WebGPU/Device.mm:

(WebGPU::Device::create):
(WebGPU::Device::Device):

  • WebGPU/Instance.mm:

(WebGPU::sortedDevices):
(WebGPU::Instance::requestAdapter):

  • WebGPU/QuerySet.h:

(WebGPU::QuerySet::create):
(WebGPU::QuerySet::counterSampleBuffer const):

  • WebGPU/QuerySet.mm:

(WebGPU::QuerySet::QuerySet):

  • WebGPU/Queue.h:

(WebGPU::Queue::create):

  • WebGPU/Queue.mm:

(WebGPU::Queue::Queue):

  • WebGPU/RenderBundle.h:

(WebGPU::RenderBundle::create):
(WebGPU::RenderBundle::indirectCommandBuffer const):

  • WebGPU/RenderBundle.mm:

(WebGPU::RenderBundle::RenderBundle):

  • WebGPU/RenderBundleEncoder.h:

(WebGPU::RenderBundleEncoder::create):

  • WebGPU/RenderBundleEncoder.mm:

(WebGPU::RenderBundleEncoder::RenderBundleEncoder):

  • WebGPU/RenderPassEncoder.h:

(WebGPU::RenderPassEncoder::create):

  • WebGPU/RenderPassEncoder.mm:

(WebGPU::RenderPassEncoder::RenderPassEncoder):

  • WebGPU/RenderPipeline.h:

(WebGPU::RenderPipeline::create):
(WebGPU::RenderPipeline::renderPipelineState const):

  • WebGPU/RenderPipeline.mm:

(WebGPU::RenderPipeline::RenderPipeline):

  • WebGPU/Sampler.h:

(WebGPU::Sampler::create):
(WebGPU::Sampler::samplerState const):

  • WebGPU/Sampler.mm:

(WebGPU::Sampler::Sampler):

  • WebGPU/ShaderModule.h:

(WebGPU::ShaderModule::create):
(WebGPU::ShaderModule::library const):

  • WebGPU/ShaderModule.mm:

(WebGPU::ShaderModule::createLibrary):
(WebGPU::earlyCompileShaderModule):
(WebGPU::ShaderModule::ShaderModule):

  • WebGPU/Texture.h:

(WebGPU::Texture::create):
(WebGPU::Texture::texture const):

  • WebGPU/Texture.mm:

(WebGPU::Texture::Texture):

  • WebGPU/TextureView.h:

(WebGPU::TextureView::create):
(WebGPU::TextureView::texture const):

  • WebGPU/TextureView.mm:

(WebGPU::TextureView::TextureView):

12:22 PM Changeset in webkit [290790] by Russell Epstein
  • 9 edits in branches/safari-613-branch/Source

Versioning.

WebKit-7613.2.1

12:21 PM Changeset in webkit [290789] by Russell Epstein
  • 3 edits in branches/safari-613-branch/Source/JavaScriptCore

Cherry-pick r288363. rdar://problem/88995092

Fix build when using Visual Studio 2022
https://bugs.webkit.org/show_bug.cgi?id=235440

Reviewed by Antti Koivisto.

It doesn't like having a switch with a default but no cases.
This is cleaner with if statements anyways.
Also make members const because I can.

  • jit/JITCode.cpp: (JSC::JITCode::calleeSaveRegisters const):
  • jit/JITCode.h:

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

11:51 AM Changeset in webkit [290788] by sbarati@apple.com
  • 13 edits in trunk/Source/JavaScriptCore

Add a DeferTraps scope
https://bugs.webkit.org/show_bug.cgi?id=237306
<rdar://83494949>

Reviewed by Mark Lam.

  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::jettison):
(JSC::CodeBlock::noticeIncomingCall):

  • bytecode/CodeBlock.h:
  • bytecode/RepatchInlines.h:

(JSC::linkFor):
(JSC::virtualForWithFunction):

  • dfg/DFGOperations.cpp:

(JSC::DFG::JSC_DEFINE_JIT_OPERATION):

  • interpreter/Interpreter.cpp:

(JSC::Interpreter::executeProgram):
(JSC::Interpreter::executeCall):
(JSC::Interpreter::executeConstruct):
(JSC::Interpreter::execute):
(JSC::Interpreter::executeModuleProgram):

  • interpreter/InterpreterInlines.h:

(JSC::Interpreter::execute):

  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::setUpCall):

  • runtime/ExceptionScope.h:
  • runtime/ScriptExecutable.cpp:

(JSC::ScriptExecutable::installCode):

  • runtime/VMTraps.cpp:

(JSC::VMTraps::handleTraps):
(JSC::VMTraps::takeTopPriorityTrap):

  • runtime/VMTraps.h:

(JSC::VMTraps::needHandling const):
(JSC::VMTraps::maybeNeedHandling const):
(JSC::VMTraps::hasTrapBit):
(JSC::VMTraps::setTrapBit):

  • runtime/VMTrapsInlines.h:

(JSC::DeferTraps::DeferTraps):
(JSC::DeferTraps::~DeferTraps):

11:04 AM Changeset in webkit [290787] by Russell Epstein
  • 8 edits
    2 adds in branches/safari-614.1.5-branch

Cherry-pick r290512. rdar://problem/89765722

[Tables] Incorrect table sizing when colgroup comes after tbody
https://bugs.webkit.org/show_bug.cgi?id=237205
<rdar://86582214>

Reviewed by Antti Koivisto.

Source/WebCore:

Let's use the colgroup for table sizing even when it comes after any thead, tbody, tfoot, and tr elements.
This makes WebKit match other rendering engines (see https://src.chromium.org/viewvc/blink?revision=159442&view=revision)

Test: fast/table/table-sizing-fails-when-colgroup-comes-after-content.html

  • rendering/RenderTable.cpp: (WebCore::RenderTable::firstColumn const):
  • rendering/RenderTableCol.cpp: (WebCore::RenderTableCol::nextColumn const):

LayoutTests:

  • fast/table/table-sizing-fails-when-colgroup-comes-after-content-expected.html: Added.
  • fast/table/table-sizing-fails-when-colgroup-comes-after-content.html: Added.
  • platform/mac/tables/mozilla_expected_failures/dom/appendCol1-expected.txt: Progression.
  • platform/mac/tables/mozilla_expected_failures/dom/appendColGroup1-expected.txt: Progression.

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

11:00 AM Changeset in webkit [290786] by Russell Epstein
  • 9 edits in branches/safari-614.1.5-branch/Source

Versioning.

WebKit-7614.1.5.6

10:25 AM Changeset in webkit [290785] by Simon Fraser
  • 11 edits
    2 adds in trunk

nasa.gov page with fixed backgrounds paints incorrectly on scroll
https://bugs.webkit.org/show_bug.cgi?id=237405
<rdar://66568551>

Reviewed by Antti Koivisto.
Source/WebCore:

https://www.nasa.gov/specials/artemis/ shows an issue where elements with background-attachment:fixed
don't repaint on scroll. This page has scrollable <html> and <body>, and the elements with fixed
backgrounds are composited, so this reveals that we fail to repaint composited children
of an overflow scroll in this case.

Fix by having RenderLayerScrollableArea::scrollTo() do repaints on slow repaint objects
which are scrolled by the current scroller.

Do some unrelated cleanup in code that I was going to use in this patch but turned out
not to need: rename hasFixedBackgroundImage() to hasAnyFixedBackground() for clarity,
and share the implementation with hasAnyLocalBackground().

Test: fast/repaint/background-attachment-fixed-in-composited-scroll.html

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::styleWillChange):
(WebCore::RenderElement::willBeDestroyed):

  • rendering/RenderLayer.cpp:
  • rendering/RenderLayerScrollableArea.cpp:

(WebCore::RenderLayerScrollableArea::scrollTo):

  • rendering/style/FillLayer.cpp:

(WebCore::FillLayer::hasImageWithAttachment const):
(WebCore::FillLayer::hasFixedImage const): Deleted.

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

(WebCore::RenderStyle::hasAnyLocalBackground const): Deleted.

  • rendering/style/RenderStyle.h:

(WebCore::RenderStyle::hasBackgroundImage const):
(WebCore::RenderStyle::hasAnyFixedBackground const):
(WebCore::RenderStyle::hasAnyLocalBackground const):
(WebCore::RenderStyle::hasFixedBackgroundImage const): Deleted.

LayoutTests:

Repaint test which is only valid for mac-wk2 (iOS does not support background-attachment:fixed).

  • TestExpectations:
  • fast/repaint/background-attachment-fixed-in-composited-scroll-expected.txt: Added.
  • fast/repaint/background-attachment-fixed-in-composited-scroll.html: Added.
  • platform/mac-wk2/TestExpectations:
10:20 AM Changeset in webkit [290784] by mmaxfield@apple.com
  • 4 edits in trunk

[Style] Forbid spaces between type names and protocol names in Objective-C
https://bugs.webkit.org/show_bug.cgi?id=237406

Reviewed by Darin Adler.

According to https://lists.webkit.org/pipermail/webkit-dev/2022-February/032130.html.

Tools:

Because the style checker uses regexes, we don't know what's a type name and what's
a protocol name, so the checker simplifies the problem and just checks for "id <".

  • Scripts/webkitpy/style/checkers/cpp.py:

(check_objc_protocol):
(check_style):

Websites/webkit.org:

  • code-style.md:
10:01 AM Changeset in webkit [290783] by jonlee@apple.com
  • 3 edits in trunk/LayoutTests

Unreviewed test gardening.

  • gpu-process/TestExpectations:
  • platform/ios/TestExpectations:
9:56 AM Changeset in webkit [290782] by Alan Bujtas
  • 3 edits
    2 adds in trunk

A text node longer than 65,535 characters following another text node is invisible in a scrolling context
https://bugs.webkit.org/show_bug.cgi?id=237330
<rdar://problem/89645522>

Reviewed by Antti Koivisto.

Source/WebCore:

  1. We split text content at 65536 characters (see Text::createWithLengthLimit)
  2. InlineTextBox can only hold up to 65534 (max short unsigned) characters (unsigned short m_len { 0 };)

Arithmetic overflow produces 0 length inline text boxes and they get removed at
LegacyLineLayout::computeBlockDirectionPositionsForLine as redundant boxes.

Test: fast/text/text-overflow-over-64k.html

  • rendering/LegacyInlineTextBox.h: Let's just use unsigned. At this point we don't have that many

legacy inline text boxes anyway.

LayoutTests:

  • fast/text/text-overflow-over-64k-expected.html: Added.
  • fast/text/text-overflow-over-64k.html: Added.
9:30 AM Changeset in webkit [290781] by Ross Kirsling
  • 2 edits in trunk/Source/WebKit

REGRESSION(r290776): NetworkSession::swServer depends on ENABLE(SERVICE_WORKER)
https://bugs.webkit.org/show_bug.cgi?id=237432

Unreviewed build fix.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::terminateRemoteWorkerContextConnectionWhenPossible):

9:25 AM Changeset in webkit [290780] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebCore

Update IDLParser to support trailing commas in enums.
https://bugs.webkit.org/show_bug.cgi?id=232607
<rdar://problem/85189036>

Patch by Dan Glastonbury <djg@apple.com> on 2022-03-03
Reviewed by Sam Weinig.

Now compatible with the grammar specified by [1].

[1] https://webidl.spec.whatwg.org/#prod-EnumValueListComma

  • bindings/scripts/IDLParser.pm:

(parseEnumValues):

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

(WebCore::convertEnumerationToString):
(WebCore::convertEnumerationToJS):
(WebCore::parseEnumeration<TestObj::EnumTrailingComma>):
(WebCore::expectedEnumerationValues<TestObj::EnumTrailingComma>):

  • bindings/scripts/test/JS/JSTestObj.h:
  • bindings/scripts/test/TestObj.idl:
9:24 AM Changeset in webkit [290779] by Antti Koivisto
  • 11 edits in trunk/Source/WebCore

Simplify pseudo element resolution
https://bugs.webkit.org/show_bug.cgi?id=237413

Reviewed by Antoine Quint.

Remove ElementUpdates struct with a map that contains pseudo element updates.
Instead use a single ElementUpdate struct and pass the pseudo element styles
as cached pseudo styles of the element RenderStyle. Previously RenderTreeUpdater
would move them there.

  • rendering/updating/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::Parent::Parent):
(WebCore::RenderTreeUpdater::updateRenderTree):
(WebCore::RenderTreeUpdater::pushParent):
(WebCore::RenderTreeUpdater::popParent):
(WebCore::RenderTreeUpdater::updateBeforeDescendants):
(WebCore::RenderTreeUpdater::updateAfterDescendants):
(WebCore::RenderTreeUpdater::updateElementRenderer):

  • rendering/updating/RenderTreeUpdater.h:
  • rendering/updating/RenderTreeUpdaterGeneratedContent.cpp:

(WebCore::RenderTreeUpdater::GeneratedContent::updatePseudoElement):
(WebCore::RenderTreeUpdater::GeneratedContent::needsPseudoElement):

  • rendering/updating/RenderTreeUpdaterGeneratedContent.h:
  • style/StyleTreeResolver.cpp:

(WebCore::Style::TreeResolver::computeDescendantsToResolve):
(WebCore::Style::TreeResolver::resolveElement):
(WebCore::Style::TreeResolver::shouldResolveElement):
(WebCore::Style::TreeResolver::resetDescendantStyleRelations):
(WebCore::Style::TreeResolver::resolveComposedTree):
(WebCore::Style::computeDescendantsToResolve): Deleted.
(WebCore::Style::shouldResolveElement): Deleted.
(WebCore::Style::resetDescendantStyleRelations): Deleted.

  • style/StyleTreeResolver.h:
  • style/StyleUpdate.cpp:

(WebCore::Style::Update::elementUpdate const):
(WebCore::Style::Update::elementUpdate):
(WebCore::Style::Update::elementStyle const):
(WebCore::Style::Update::elementStyle):
(WebCore::Style::Update::addElement):
(WebCore::Style::Update::elementUpdates const): Deleted.
(WebCore::Style::Update::elementUpdates): Deleted.

  • style/StyleUpdate.h:
8:57 AM Changeset in webkit [290778] by youenn@apple.com
  • 6 edits
    2 adds in trunk

macOS Safari 15.2 Audio Echo Issue after camera pause/unpause
https://bugs.webkit.org/show_bug.cgi?id=235544
<rdar://problem/88297045>

Reviewed by Eric Carlson.

Source/WebCore:

After https://commits.webkit.org/r275600, the muted state of MediaPlayer would be set to the page muted state
without taking into consideration HTMLMediaElement.muted.
Update the call site to use effectiveMuted instead.
Add internals API to write a corresponding layout test.

Test: fast/mediastream/mediastreamtrack-audiovideo-mutepage.html

  • html/HTMLMediaElement.cpp:
  • testing/Internals.cpp:
  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

  • fast/mediastream/mediastreamtrack-audiovideo-mutepage-expected.txt: Added.
  • fast/mediastream/mediastreamtrack-audiovideo-mutepage.html: Added.
8:53 AM Changeset in webkit [290777] by Jonathan Bedard
  • 3 edits in trunk/Tools

[Python-3] Invoke webkit-patch with Python 3 by default (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=231591
<rdar://problem/84153640>

Unreviewed follow-up fix.

  • Scripts/webkitpy/tool/commands/download.py:

(AbstractRevertPrepCommand._prepare_state): Reason may be spread accross multiple arguments.

  • Scripts/webkitpy/tool/commands/download_unittest.py:
8:09 AM Changeset in webkit [290776] by Chris Dumez
  • 22 edits in trunk

REGRESSION(r290356-r290351?): [ iOS EWS ] 3 imported/w3c/web-platform-tests/service-workers/service-worker/* tests are constant text failures.
https://bugs.webkit.org/show_bug.cgi?id=237160
<rdar://problem/89440067>

Reviewed by Youenn Fablet.

LayoutTests/imported/w3c:

Rebaseline test that is now passing.

  • web-platform-tests/service-workers/service-worker/fetch-request-no-freshness-headers.https-expected.txt:

Source/WebCore:

In r290352, I made a change so that the service worker is more likely to launch in the WebContent
process that caused it to launch. This is beneficial for performance and memory usage.

The partitioned-service-worker*.html service worker tests are relying on an ID variable that is
randomly generated inside the service worker and they expect this ID to not change during the
duration of the test. This means that if the service worker exits / relaunches, those tests start
failing because the ID changes.

The issue is that we have logic in WebProcessProxy::didStartProvisionalLoadForMainFrame() that
terminates the service workers running inside the WebProcess if a new eTLD+1 page is loaded inside
the process. We do so to try and achieve better process isolation between different sites. The
issue is that those tests launch a service worker and then open a new cross-site popup. When the
cross-site popup loads inside the same process, we'd make the decision to terminate the service
workers in this process and relaunch them in a new clean one, causing the tests to fail.

While it is true per the specification that service workers can be terminated / relaunched at
almost any point, there are exceptions. In particular, we should keep a service worker running
if it still has pending extendable events. For this reason, the tests rely on FetchEvent.waitUntil()
to keep the service worker running. Sadly, we would not obey that in this case.

To address the issue, we no longer unconditionally close the service worker context connection
when a WebProcess loads a new eTLD+1. Instead, we tell the network process to close that connection
as soon as possible. When the network process receives this IPC, it terminates the context
connection ONLY if the service workers using the connection have no pending events. If we cannot
close the context connection right away, we set a flag on the context connection to indicate that
we should close it as soon as possible. Currently, this flag is only used to close the connection
right away (no 10 second delay) once the connection no longer has any clients. I think that, ideally,
we'd close the connection as soon as the service workers no longer have pending events. However,
this adds complexity and is error-prone so I didn't implement it in this patch and merely added a
FIXME comment. As it stands, my patch STILL relaunches service workers in origin-clean processes
in the common case. It only fails to do so in the case where there are pending service worker
events which is a case where we had the correctness bug anyway.

No new tests, unskipped existing tests.

  • workers/service/server/SWServer.cpp:

(WebCore::SWServer::forEachServiceWorker const):
(WebCore::SWServer::terminateContextConnectionWhenPossible):
(WebCore::SWServer::unregisterServiceWorkerClient):

  • workers/service/server/SWServer.h:
  • workers/service/server/SWServerToContextConnection.cpp:

(WebCore::SWServerToContextConnection::SWServerToContextConnection):
(WebCore::SWServerToContextConnection::server const):
(WebCore::SWServerToContextConnection::terminateWhenPossible):

  • workers/service/server/SWServerToContextConnection.h:

(WebCore::SWServerToContextConnection::shouldTerminateWhenPossible const):

Source/WebKit:

In r290352, I made a change so that the service worker is more likely to launch in the WebContent
process that caused it to launch. This is beneficial for performance and memory usage.

The partitioned-service-worker*.html service worker tests are relying on an ID variable that is
randomly generated inside the service worker and they expect this ID to not change during the
duration of the test. This means that if the service worker exits / relaunches, those tests start
failing because the ID changes.

The issue is that we have logic in WebProcessProxy::didStartProvisionalLoadForMainFrame() that
terminates the service workers running inside the WebProcess if a new eTLD+1 page is loaded inside
the process. We do so to try and achieve better process isolation between different sites. The
issue is that those tests launch a service worker and then open a new cross-site popup. When the
cross-site popup loads inside the same process, we'd make the decision to terminate the service
workers in this process and relaunch them in a new clean one, causing the tests to fail.

While it is true per the specification that service workers can be terminated / relaunched at
almost any point, there are exceptions. In particular, we should keep a service worker running
if it still has pending extendable events. For this reason, the tests rely on FetchEvent.waitUntil()
to keep the service worker running. Sadly, we would not obey that in this case.

To address the issue, we no longer unconditionally close the service worker context connection
when a WebProcess loads a new eTLD+1. Instead, we tell the network process to close that connection
as soon as possible. When the network process receives this IPC, it terminates the context
connection ONLY if the service workers using the connection have no pending events. If we cannot
close the context connection right away, we set a flag on the context connection to indicate that
we should close it as soon as possible. Currently, this flag is only used to close the connection
right away (no 10 second delay) once the connection no longer has any clients. I think that, ideally,
we'd close the connection as soon as the service workers no longer have pending events. However,
this adds complexity and is error-prone so I didn't implement it in this patch and merely added a
FIXME comment. As it stands, my patch STILL relaunches service workers in origin-clean processes
in the common case. It only fails to do so in the case where there are pending service worker
events which is a case where we had the correctness bug anyway.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::terminateRemoteWorkerContextConnectionWhenPossible):

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/ServiceWorker/WebSWServerToContextConnection.cpp:

(WebKit::WebSWServerToContextConnection::WebSWServerToContextConnection):
(WebKit::WebSWServerToContextConnection::~WebSWServerToContextConnection):
(WebKit::WebSWServerToContextConnection::postMessageToServiceWorkerClient):
(WebKit::WebSWServerToContextConnection::close):

  • NetworkProcess/ServiceWorker/WebSWServerToContextConnection.h:
  • NetworkProcess/SharedWorker/WebSharedWorkerServer.cpp:

(WebKit::WebSharedWorkerServer::terminateContextConnectionWhenPossible):

  • NetworkProcess/SharedWorker/WebSharedWorkerServer.h:
  • NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.cpp:

(WebKit::WebSharedWorkerServerToContextConnection::removeSharedWorkerObject):

  • NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.h:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::terminateRemoteWorkerContextConnectionWhenPossible):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::didStartProvisionalLoadForMainFrame):

LayoutTests:

Unskip tests that are no longer failing.

  • platform/ios/TestExpectations:
7:22 AM Changeset in webkit [290775] by Adrian Perez de Castro
  • 7 edits in trunk/Source

Non-unified build fixes, early March 2022 edition
https://bugs.webkit.org/show_bug.cgi?id=237420

Unreviewed non-unified build fixes.

Source/JavaScriptCore:

  • llint/LLIntExceptions.h: Add forward declaration for WasmInstruction.

Source/WebCore:

  • inspector/agents/InspectorDOMDebuggerAgent.h: Add forward declaration for ScriptExecutionContext.

Source/WebKit:

  • UIProcess/API/APIDataTask.cpp: Add missing inclusion of DataReference.h, remove

"#pragma once" from non-header file.

  • UIProcess/API/APIDataTaskClient.h: Add missing inclusion of DataReference.h.
5:09 AM Changeset in webkit [290774] by Martin Robinson
  • 9 edits
    21 adds in trunk/LayoutTests

Update WPT css-scroll-snap tests
https://bugs.webkit.org/show_bug.cgi?id=237358

Reviewed by Manuel Rego Casasnovas.

LayoutTests/imported/w3c:

  • resources/import-expectations.json:
  • resources/resource-files.json:
  • web-platform-tests/css/css-scroll-snap/capturing-snap-positions-expected.txt: Added.
  • web-platform-tests/css/css-scroll-snap/capturing-snap-positions.html: Added.
  • web-platform-tests/css/css-scroll-snap/input/keyboard.html:
  • web-platform-tests/css/css-scroll-snap/input/mouse-wheel-expected.txt: Added.
  • web-platform-tests/css/css-scroll-snap/input/mouse-wheel.html: Added.
  • web-platform-tests/css/css-scroll-snap/input/snap-area-overflow-boundary-expected.txt: Added.
  • web-platform-tests/css/css-scroll-snap/input/snap-area-overflow-boundary.html: Added.
  • web-platform-tests/css/css-scroll-snap/input/w3c-import.log:
  • web-platform-tests/css/css-scroll-snap/no-red-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/scroll-snap-root-001-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/scroll-snap-root-002-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/scroll-target-001-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/scroll-target-margin-005-expected.txt: Added.
  • web-platform-tests/css/css-scroll-snap/scroll-target-margin-005.html: Added.
  • web-platform-tests/css/css-scroll-snap/selection-target-expected.txt: Added.
  • web-platform-tests/css/css-scroll-snap/selection-target.html: Added.
  • web-platform-tests/css/css-scroll-snap/snap-after-initial-layout/scroll-snap-initial-layout-000-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/snap-after-initial-layout/scroll-snap-writing-mode-000-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/snap-after-initial-layout/snap-after-initial-layout-ref.html: Added.
  • web-platform-tests/css/css-scroll-snap/snap-after-initial-layout/w3c-import.log:
  • web-platform-tests/css/css-scroll-snap/support/common.js:

(waitForAnimationEnd.):
(waitForAnimationEnd):
(waitForWheelEvent):
(waitForScrollEnd):
(waitForScrollTo):

  • web-platform-tests/css/css-scroll-snap/w3c-import.log:

LayoutTests:

  • platform/glib/imported/w3c/web-platform-tests/css/css-scroll-snap/scroll-target-margin-005-expected.txt: Added.
  • platform/mac-wk1/imported/w3c/web-platform-tests/css/css-scroll-snap/scroll-target-margin-005-expected.txt: Added.
3:06 AM Changeset in webkit [290773] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

REGRESSION (r290512): imported/blink/fast/table/crash-output-element-as-column-group.html asserts sometimes
https://bugs.webkit.org/show_bug.cgi?id=237393

Reviewed by Simon Fraser.

Merging https://chromium.googlesource.com/chromium/src/+/1cfc9b9c37f43567529b09a9824d6d3a7bd9abb6%5E%21/#F2
The reason why crash-output-element-as-column-group.html crashes after r290512 is because
now we allow colgroup after the table content (thead, tbody) -prior to r290512, this test was pretty much a no-op.

  • rendering/RenderTableCol.cpp:

(WebCore::RenderTableCol::updateFromElement):

2:08 AM Changeset in webkit [290772] by commit-queue@webkit.org
  • 39 edits
    6 copies
    2 adds in trunk

Unreviewed, reverting r290756.
https://bugs.webkit.org/show_bug.cgi?id=237412

Speedometer2

Reverted changeset:

"[css] Implement 'text-decoration' as a shorthand."
https://bugs.webkit.org/show_bug.cgi?id=237175
https://commits.webkit.org/r290756

1:51 AM Changeset in webkit [290771] by commit-queue@webkit.org
  • 7 edits in trunk/Tools

[Python3] Switch a couple glib/flatpak scripts to Python3
https://bugs.webkit.org/show_bug.cgi?id=237377

Patch by Philippe Normand <pnormand@igalia.com> on 2022-03-03
Reviewed by Carlos Garcia Campos.

  • Scripts/update-webkit-flatpak: Update shebang to Python3.
  • Scripts/webkit-flatpak: Ditto.
  • glib/api_test_runner.py: Ditto.
  • glib/common.py: Remove useless shebang.
  • glib/generate-inspector-gresource-manifest.py: Update shebang to Python3.
  • glib/svn-revision: Ditto.

Mar 2, 2022:

11:31 PM Changeset in webkit [290770] by commit-queue@webkit.org
  • 4 edits in trunk

Treat empty intersection correctly in RenderLayer::getRectToExpose
https://bugs.webkit.org/show_bug.cgi?id=237189

Patch by Rob Buis <rbuis@igalia.com> on 2022-03-02
Reviewed by Simon Fraser.

LayoutTests/imported/w3c:

  • web-platform-tests/css/css-contain/content-visibility/content-visibility-050-expected.txt:

Source/WebCore:

The case where the target rect to reveal had zero height and was outside of the visible rect, the
classification was wrongly that the target was visible, fix this to classify as hidden instead.

Test: imported/w3c/web-platform-tests/css/css-contain/content-visibility/content-visibility-050.html

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::getRectToExpose const):

11:08 PM Changeset in webkit [290769] by commit-queue@webkit.org
  • 12 edits in trunk/Source/JavaScriptCore

Unreviewed, reverting r290717.
https://bugs.webkit.org/show_bug.cgi?id=237409

Speedometer2

Reverted changeset:

"Add a DeferTraps scope"
https://bugs.webkit.org/show_bug.cgi?id=237306
https://commits.webkit.org/r290717

10:49 PM Changeset in webkit [290768] by Justin Michaud
  • 93 edits in trunk/Source/JavaScriptCore

Refactor OpcodeTraits to support the possibility of having 2-byte WASM opcode ids in bytecode streams
https://bugs.webkit.org/show_bug.cgi?id=237347

The number of WASM opcodes will increase beyond 255 when WASM SIMD is implemented, and so this patch
changes OpcodeTraits to allow for the possibility of having two-byte WASM opcodes without regressing
JS. We have to thread these OpcodeTraits everywhere that they are used so that code can read the
correct value when decoding an instruction stream. This patch does not change the size of WASM opcodes
yet, although I have tested that the test suite still passes if we do increase the opcode size.

Reviewed by Keith Miller.

  • bytecode/BytecodeBasicBlock.cpp:

(JSC::BytecodeBasicBlock<OpcodeTraits>::BytecodeBasicBlock):
(JSC::BytecodeBasicBlock<OpcodeTraits>::addLength):
(JSC::BytecodeBasicBlock<OpcodeTraits>::shrinkToFit):
(JSC::isJumpTarget):
(JSC::BytecodeBasicBlock<OpcodeTraits>::computeImpl):
(JSC::BytecodeBasicBlock<JSOpcodeTraits>::compute):
(JSC::BytecodeBasicBlock::BytecodeBasicBlock): Deleted.
(JSC::BytecodeBasicBlock::addLength): Deleted.
(JSC::BytecodeBasicBlock::shrinkToFit): Deleted.
(JSC::BytecodeBasicBlock::computeImpl): Deleted.
(JSC::BytecodeBasicBlock::compute): Deleted.

  • bytecode/BytecodeBasicBlock.h:

(JSC::BytecodeBasicBlock::addSuccessor):

  • bytecode/BytecodeDumper.cpp:

(JSC::BytecodeDumperBase<InstructionStreamType>::printLocationAndOp):
(JSC::BytecodeDumperBase<InstructionStreamType>::dumpValue):
(JSC::BytecodeDumper<Block>::outOfLineJumpOffset const):
(JSC::BytecodeDumper<Block>::dumpBytecode):
(JSC::dumpHeader):
(JSC::CodeBlockBytecodeDumper<Block>::dumpBlock):
(JSC::CodeBlockBytecodeDumper<Block>::dumpGraph):
(JSC::Wasm::BytecodeDumper::dumpBlock):
(JSC::Wasm::BytecodeDumper::registerName const):
(JSC::Wasm::BytecodeDumper::outOfLineJumpOffset const):
(JSC::BytecodeDumperBase::printLocationAndOp): Deleted.
(JSC::BytecodeDumperBase::dumpValue): Deleted.

  • bytecode/BytecodeDumper.h:
  • bytecode/BytecodeGeneratorification.cpp:

(JSC::BytecodeGeneratorification::BytecodeGeneratorification):
(JSC::BytecodeGeneratorification::enterPoint const):
(JSC::BytecodeGeneratorification::instructions const):
(JSC::GeneratorLivenessAnalysis::run):
(JSC::performGeneratorification):

  • bytecode/BytecodeGeneratorification.h:
  • bytecode/BytecodeGraph.h:

(JSC::BytecodeGraph::blockContainsBytecodeOffset):
(JSC::BytecodeGraph::findBasicBlockForBytecodeOffset):
(JSC::BytecodeGraph::findBasicBlockWithLeaderOffset):
(JSC::BytecodeGraph::at const):
(JSC::BytecodeGraph::operator[] const):
(JSC::BytecodeGraph::first):
(JSC::BytecodeGraph::last):
(JSC::BytecodeGraph::dump):
(JSC::BytecodeGraph::BytecodeGraph):

  • bytecode/BytecodeLivenessAnalysis.cpp:

(JSC::BytecodeLivenessAnalysis::computeFullLiveness):
(JSC::BytecodeLivenessAnalysis::dumpResults):

  • bytecode/BytecodeLivenessAnalysis.h:
  • bytecode/BytecodeLivenessAnalysisInlines.h:

(JSC::BytecodeLivenessPropagation::stepOverBytecodeIndexDef):
(JSC::BytecodeLivenessPropagation::stepOverBytecodeIndexUse):
(JSC::BytecodeLivenessPropagation::stepOverBytecodeIndexUseInExceptionHandler):
(JSC::BytecodeLivenessPropagation::stepOverBytecodeIndex):
(JSC::BytecodeLivenessPropagation::stepOverInstruction):
(JSC::BytecodeLivenessPropagation::computeLocalLivenessForInstruction):
(JSC::BytecodeLivenessPropagation::computeLocalLivenessForBlock):
(JSC::BytecodeLivenessPropagation::getLivenessInfoAtInstruction):
(JSC::BytecodeLivenessPropagation::runLivenessFixpoint):

  • bytecode/BytecodeRewriter.cpp:

(JSC::BytecodeRewriter::insertImpl):
(JSC::BytecodeRewriter::adjustJumpTargets):

  • bytecode/BytecodeRewriter.h:

(JSC::BytecodeRewriter::InsertionPoint::InsertionPoint):
(JSC::BytecodeRewriter::Fragment::Fragment):
(JSC::BytecodeRewriter::BytecodeRewriter):
(JSC::BytecodeRewriter::insertFragmentBefore):
(JSC::BytecodeRewriter::insertFragmentAfter):
(JSC::BytecodeRewriter::replaceBytecodeWithFragment):
(JSC::BytecodeRewriter::adjustAbsoluteOffset):
(JSC::BytecodeRewriter::adjustJumpTarget):

  • bytecode/BytecodeUseDef.cpp:

(JSC::computeUsesForBytecodeIndexImpl):
(JSC::computeDefsForBytecodeIndexImpl):

  • bytecode/BytecodeUseDef.h:

(JSC::computeUsesForBytecodeIndex):
(JSC::computeDefsForBytecodeIndex):

  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::dumpBytecode):
(JSC::CodeBlock::finishCreation):
(JSC::CodeBlock::hasOpDebugForLineAndColumn):
(JSC::CodeBlock::notifyLexicalBindingUpdate):
(JSC::CodeBlock::validate):
(JSC::CodeBlock::outOfLineJumpOffset):
(JSC::CodeBlock::outOfLineJumpTarget):
(JSC::CodeBlock::binaryArithProfileForPC):
(JSC::CodeBlock::unaryArithProfileForPC):
(JSC::CodeBlock::insertBasicBlockBoundariesForControlFlowProfiler):

  • bytecode/CodeBlock.h:

(JSC::CodeBlock::outOfLineJumpOffset):
(JSC::CodeBlock::bytecodeOffset):
(JSC::CodeBlock::bytecodeIndex):
(JSC::CodeBlock::instructions const):
(JSC::CodeBlock::instructionAt const):

  • bytecode/Instruction.h:

(JSC::BaseInstruction::opcodeID const):
(JSC::BaseInstruction::name const):
(JSC::BaseInstruction::isWide16 const):
(JSC::BaseInstruction::isWide32 const):
(JSC::BaseInstruction::width const):
(JSC::BaseInstruction::hasMetadata const):
(JSC::BaseInstruction::hasCheckpoints const):
(JSC::BaseInstruction::numberOfCheckpoints const):
(JSC::BaseInstruction::sizeShiftAmount const):
(JSC::BaseInstruction::opcodeIDWidth const):
(JSC::BaseInstruction::opcodeIDBytes const):
(JSC::BaseInstruction::size const):
(JSC::BaseInstruction::is const):
(JSC::BaseInstruction::as const):
(JSC::BaseInstruction::asKnownWidth const):
(JSC::BaseInstruction::cast):
(JSC::BaseInstruction::cast const):
(JSC::BaseInstruction::wide16 const):
(JSC::BaseInstruction::wide32 const):

  • bytecode/InstructionStream.cpp:

(JSC::InstructionStream::InstructionStream): Deleted.
(JSC::InstructionStream::sizeInBytes const): Deleted.
(JSC::InstructionStream::contains const): Deleted.

  • bytecode/InstructionStream.h:

(JSC::InstructionStream::sizeInBytes const):
(JSC::InstructionStream::BaseRef::operator-> const):
(JSC::InstructionStream::BaseRef::ptr const):
(JSC::InstructionStream::BaseRef::unwrap const):
(JSC::InstructionStream::MutableRef::operator->):
(JSC::InstructionStream::MutableRef::operator-> const):
(JSC::InstructionStream::MutableRef::ptr):
(JSC::InstructionStream::MutableRef::ptr const):
(JSC::InstructionStream::MutableRef::unwrap):
(JSC::InstructionStream::MutableRef::unwrap const):
(JSC::InstructionStream::iterator::operator++):
(JSC::InstructionStream::contains const):
(JSC::InstructionStream::InstructionStream):
(JSC::InstructionStreamWriter::InstructionStreamWriter):
(JSC::InstructionStreamWriter::finalize):
(JSC::InstructionStreamWriter::swap):
(JSC::InstructionStreamWriter::iterator::operator++):

  • bytecode/Opcode.h:
  • bytecode/OpcodeInlines.h:

(JSC::isOpcodeShape):

  • bytecode/OpcodeSize.h:
  • bytecode/PreciseJumpTargets.cpp:

(JSC::getJumpTargetsForInstruction):
(JSC::computePreciseJumpTargetsInternal):
(JSC::computePreciseJumpTargets):
(JSC::recomputePreciseJumpTargets):
(JSC::findJumpTargetsForInstruction):

  • bytecode/PreciseJumpTargets.h:
  • bytecode/PreciseJumpTargetsInlines.h:

(JSC::jumpTargetForInstruction):
(JSC::extractStoredJumpTargetsForInstruction):
(JSC::updateStoredJumpTargetsForInstruction):

  • bytecode/UnlinkedCodeBlock.cpp:

(JSC::dumpLineColumnEntry):
(JSC::UnlinkedCodeBlock::instructions const):
(JSC::UnlinkedCodeBlock::outOfLineJumpOffset):

  • bytecode/UnlinkedCodeBlock.h:

(JSC::UnlinkedCodeBlock::instructionAt const):
(JSC::UnlinkedCodeBlock::bytecodeOffset):
(JSC::UnlinkedCodeBlock::opProfileControlFlowBytecodeOffsets const):
(JSC::UnlinkedCodeBlock::outOfLineJumpOffset):

  • bytecode/UnlinkedCodeBlockGenerator.cpp:

(JSC::UnlinkedCodeBlockGenerator::finalize):
(JSC::UnlinkedCodeBlockGenerator::applyModification):
(JSC::UnlinkedCodeBlockGenerator::addOutOfLineJumpTarget):
(JSC::UnlinkedCodeBlockGenerator::outOfLineJumpOffset):

  • bytecode/UnlinkedCodeBlockGenerator.h:

(JSC::UnlinkedCodeBlockGenerator::addOpProfileControlFlowBytecodeOffset):
(JSC::UnlinkedCodeBlockGenerator::outOfLineJumpOffset):

  • bytecompiler/BytecodeGenerator.h:

(JSC::BytecodeGenerator::instructions const):
(JSC::BytecodeGenerator::withWriter):

  • bytecompiler/BytecodeGeneratorBase.h:
  • bytecompiler/BytecodeGeneratorBaseInlines.h:

(JSC::BytecodeGeneratorBase<Traits>::recordOpcode):
(JSC::BytecodeGeneratorBase<Traits>::alignWideOpcode16):
(JSC::BytecodeGeneratorBase<Traits>::alignWideOpcode32):

  • bytecompiler/StaticPropertyAnalysis.h:

(JSC::StaticPropertyAnalysis::create):
(JSC::StaticPropertyAnalysis::StaticPropertyAnalysis):

  • bytecompiler/StaticPropertyAnalyzer.h:

(JSC::StaticPropertyAnalyzer::createThis):
(JSC::StaticPropertyAnalyzer::newObject):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::handleCall):
(JSC::DFG::ByteCodeParser::handleVarargsCall):
(JSC::DFG::ByteCodeParser::handleRecursiveTailCall):
(JSC::DFG::ByteCodeParser::inlineCall):
(JSC::DFG::ByteCodeParser::parseGetById):
(JSC::DFG::ByteCodeParser::parseBlock):
(JSC::DFG::ByteCodeParser::parseCodeBlock):

  • dfg/DFGCapabilities.cpp:

(JSC::DFG::capabilityLevel):

  • dfg/DFGCapabilities.h:

(JSC::DFG::capabilityLevel):

  • dfg/DFGOSRExit.cpp:

(JSC::DFG::OSRExit::compileExit):

  • dfg/DFGOSRExitCompilerCommon.cpp:

(JSC::DFG::callerReturnPC):
(JSC::DFG::adjustAndJumpToTarget):

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileLoopHint):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileCompareStrictEq):

  • ftl/FTLOSRExitCompiler.cpp:

(JSC::FTL::compileStub):

  • ftl/FTLOperations.cpp:

(JSC::FTL::JSC_DEFINE_JIT_OPERATION):

  • generator/Argument.rb:
  • generator/DSL.rb:
  • generator/Opcode.rb:
  • interpreter/AbstractPC.h:
  • interpreter/CallFrame.cpp:

(JSC::CallFrame::currentVPC const):
(JSC::CallFrame::setCurrentVPC):

  • interpreter/CallFrame.h:
  • interpreter/Interpreter.cpp:

(JSC::CatchInfo::CatchInfo):

  • interpreter/Interpreter.h:
  • jit/JIT.cpp:

(JSC::JIT::privateCompileMainPass):
(JSC::JIT::privateCompileSlowCases):

  • jit/JIT.h:
  • jit/JITArithmetic.cpp:

(JSC::JIT::emit_op_jless):
(JSC::JIT::emit_op_jlesseq):
(JSC::JIT::emit_op_jgreater):
(JSC::JIT::emit_op_jgreatereq):
(JSC::JIT::emit_op_jnless):
(JSC::JIT::emit_op_jnlesseq):
(JSC::JIT::emit_op_jngreater):
(JSC::JIT::emit_op_jngreatereq):
(JSC::JIT::emitSlow_op_jless):
(JSC::JIT::emitSlow_op_jlesseq):
(JSC::JIT::emitSlow_op_jgreater):
(JSC::JIT::emitSlow_op_jgreatereq):
(JSC::JIT::emitSlow_op_jnless):
(JSC::JIT::emitSlow_op_jnlesseq):
(JSC::JIT::emitSlow_op_jngreater):
(JSC::JIT::emitSlow_op_jngreatereq):
(JSC::JIT::emit_op_below):
(JSC::JIT::emit_op_beloweq):
(JSC::JIT::emit_op_jbelow):
(JSC::JIT::emit_op_jbeloweq):
(JSC::JIT::emit_op_unsigned):
(JSC::JIT::emit_compareAndJump):
(JSC::JIT::emit_compareUnsignedAndJump):
(JSC::JIT::emit_compareUnsigned):
(JSC::JIT::emit_compareAndJumpSlow):
(JSC::JIT::emit_op_inc):
(JSC::JIT::emit_op_dec):
(JSC::JIT::emit_op_mod):
(JSC::JIT::emitSlow_op_mod):
(JSC::JIT::emit_op_pow):
(JSC::JIT::emitSlow_op_pow):
(JSC::JIT::emit_op_negate):
(JSC::JIT::emitSlow_op_negate):
(JSC::JIT::emitBitBinaryOpFastPath):
(JSC::JIT::emit_op_bitnot):
(JSC::JIT::emit_op_bitand):
(JSC::JIT::emit_op_bitor):
(JSC::JIT::emit_op_bitxor):
(JSC::JIT::emit_op_lshift):
(JSC::JIT::emitRightShiftFastPath):
(JSC::JIT::emit_op_rshift):
(JSC::JIT::emit_op_urshift):
(JSC::JIT::emit_op_add):
(JSC::JIT::emitSlow_op_add):
(JSC::JIT::emitMathICFast):
(JSC::JIT::emitMathICSlow):
(JSC::JIT::emit_op_div):
(JSC::JIT::emit_op_mul):
(JSC::JIT::emitSlow_op_mul):
(JSC::JIT::emit_op_sub):
(JSC::JIT::emitSlow_op_sub):

  • jit/JITCall.cpp:

(JSC::JIT::emit_op_ret):
(JSC::JIT::compileCallEvalSlowCase):
(JSC::JIT::compileOpCall):
(JSC::JIT::compileOpCallSlowCase):
(JSC::JIT::emit_op_call):
(JSC::JIT::emit_op_tail_call):
(JSC::JIT::emit_op_call_eval):
(JSC::JIT::emit_op_call_varargs):
(JSC::JIT::emit_op_tail_call_varargs):
(JSC::JIT::emit_op_tail_call_forward_arguments):
(JSC::JIT::emit_op_construct_varargs):
(JSC::JIT::emit_op_construct):
(JSC::JIT::emitSlow_op_call):
(JSC::JIT::emitSlow_op_tail_call):
(JSC::JIT::emitSlow_op_call_eval):
(JSC::JIT::emitSlow_op_call_varargs):
(JSC::JIT::emitSlow_op_tail_call_varargs):
(JSC::JIT::emitSlow_op_tail_call_forward_arguments):
(JSC::JIT::emitSlow_op_construct_varargs):
(JSC::JIT::emitSlow_op_construct):
(JSC::JIT::emit_op_iterator_open):
(JSC::JIT::emitSlow_op_iterator_open):
(JSC::JIT::emit_op_iterator_next):
(JSC::JIT::emitSlow_op_iterator_next):

  • jit/JITExceptions.cpp:

(JSC::genericUnwind):

  • jit/JITInlines.h:

(JSC::JIT::fastPathResumePoint const):
(JSC::JIT::jumpTarget):

  • jit/JITOpcodes.cpp:

(JSC::JIT::emit_op_mov):
(JSC::JIT::emit_op_end):
(JSC::JIT::emit_op_jmp):
(JSC::JIT::emit_op_new_object):
(JSC::JIT::emitSlow_op_new_object):
(JSC::JIT::emit_op_overrides_has_instance):
(JSC::JIT::emit_op_instanceof):
(JSC::JIT::emitSlow_op_instanceof):
(JSC::JIT::emit_op_is_empty):
(JSC::JIT::emit_op_typeof_is_undefined):
(JSC::JIT::emit_op_is_undefined_or_null):
(JSC::JIT::emit_op_is_boolean):
(JSC::JIT::emit_op_is_number):
(JSC::JIT::emit_op_is_big_int):
(JSC::JIT::emit_op_is_cell_with_type):
(JSC::JIT::emit_op_is_object):
(JSC::JIT::emit_op_to_primitive):
(JSC::JIT::emit_op_to_property_key):
(JSC::JIT::emit_op_set_function_name):
(JSC::JIT::emit_op_not):
(JSC::JIT::emit_op_jfalse):
(JSC::JIT::emit_op_jeq_null):
(JSC::JIT::emit_op_jneq_null):
(JSC::JIT::emit_op_jundefined_or_null):
(JSC::JIT::emit_op_jnundefined_or_null):
(JSC::JIT::emit_op_jeq_ptr):
(JSC::JIT::emit_op_jneq_ptr):
(JSC::JIT::emit_op_eq):
(JSC::JIT::emit_op_jeq):
(JSC::JIT::emit_op_jtrue):
(JSC::JIT::emit_op_neq):
(JSC::JIT::emit_op_jneq):
(JSC::JIT::emit_op_throw):
(JSC::JIT::compileOpStrictEq):
(JSC::JIT::emit_op_stricteq):
(JSC::JIT::emit_op_nstricteq):
(JSC::JIT::compileOpStrictEqJump):
(JSC::JIT::emit_op_jstricteq):
(JSC::JIT::emit_op_jnstricteq):
(JSC::JIT::emitSlow_op_jstricteq):
(JSC::JIT::emitSlow_op_jnstricteq):
(JSC::JIT::emit_op_to_number):
(JSC::JIT::emit_op_to_numeric):
(JSC::JIT::emit_op_to_string):
(JSC::JIT::emit_op_to_object):
(JSC::JIT::emit_op_catch):
(JSC::JIT::emit_op_identity_with_profile):
(JSC::JIT::emit_op_get_parent_scope):
(JSC::JIT::emit_op_switch_imm):
(JSC::JIT::emit_op_switch_char):
(JSC::JIT::emit_op_switch_string):
(JSC::JIT::emit_op_eq_null):
(JSC::JIT::emit_op_neq_null):
(JSC::JIT::emit_op_enter):
(JSC::JIT::emit_op_get_scope):
(JSC::JIT::emit_op_to_this):
(JSC::JIT::emit_op_create_this):
(JSC::JIT::emit_op_check_tdz):
(JSC::JIT::emitSlow_op_eq):
(JSC::JIT::emitSlow_op_neq):
(JSC::JIT::emitSlow_op_jeq):
(JSC::JIT::emitSlow_op_jneq):
(JSC::JIT::emit_op_debug):
(JSC::JIT::emit_op_loop_hint):
(JSC::JIT::emitSlow_op_loop_hint):
(JSC::JIT::emit_op_check_traps):
(JSC::JIT::emit_op_nop):
(JSC::JIT::emit_op_super_sampler_begin):
(JSC::JIT::emit_op_super_sampler_end):
(JSC::JIT::emitSlow_op_check_traps):
(JSC::JIT::emit_op_new_regexp):
(JSC::JIT::emitNewFuncCommon):
(JSC::JIT::emit_op_new_func):
(JSC::JIT::emit_op_new_generator_func):
(JSC::JIT::emit_op_new_async_generator_func):
(JSC::JIT::emit_op_new_async_func):
(JSC::JIT::emitNewFuncExprCommon):
(JSC::JIT::emit_op_new_func_exp):
(JSC::JIT::emit_op_new_generator_func_exp):
(JSC::JIT::emit_op_new_async_func_exp):
(JSC::JIT::emit_op_new_async_generator_func_exp):
(JSC::JIT::emit_op_new_array):
(JSC::JIT::emit_op_new_array_with_size):
(JSC::JIT::emit_op_profile_type):
(JSC::JIT::emit_op_log_shadow_chicken_prologue):
(JSC::JIT::emit_op_log_shadow_chicken_tail):
(JSC::JIT::emit_op_profile_control_flow):
(JSC::JIT::emit_op_argument_count):
(JSC::JIT::emit_op_get_rest_length):
(JSC::JIT::emit_op_get_argument):
(JSC::JIT::emit_op_get_prototype_of):

  • jit/JITOpcodes32_64.cpp:

(JSC::JIT::emit_op_eq):
(JSC::JIT::emit_op_neq):
(JSC::JIT::emit_op_jeq):
(JSC::JIT::emit_op_jneq):
(JSC::JIT::emitSlow_op_eq):
(JSC::JIT::emitSlow_op_neq):
(JSC::JIT::emitSlow_op_jeq):
(JSC::JIT::emitSlow_op_jneq):
(JSC::JIT::emit_op_stricteq):
(JSC::JIT::emit_op_nstricteq):
(JSC::JIT::emit_op_jstricteq):
(JSC::JIT::emit_op_jnstricteq):
(JSC::JIT::emitSlow_op_jstricteq):
(JSC::JIT::emitSlow_op_jnstricteq):

  • jit/JITOperations.cpp:

(JSC::JSC_DEFINE_JIT_OPERATION):

  • jit/JITOperations.h:
  • jit/JITPropertyAccess.cpp:

(JSC::JIT::emit_op_get_by_val):
(JSC::JIT::emitSlow_op_get_by_val):
(JSC::JIT::emit_op_get_private_name):
(JSC::JIT::emitSlow_op_get_private_name):
(JSC::JIT::emit_op_set_private_brand):
(JSC::JIT::emitSlow_op_set_private_brand):
(JSC::JIT::emit_op_check_private_brand):
(JSC::JIT::emitSlow_op_check_private_brand):
(JSC::JIT::emit_op_put_by_val):
(JSC::JIT::emit_op_put_by_val_direct):
(JSC::JIT::emitSlow_op_put_by_val):
(JSC::JIT::emit_op_put_private_name):
(JSC::JIT::emitSlow_op_put_private_name):
(JSC::JIT::emit_op_put_getter_by_id):
(JSC::JIT::emit_op_put_setter_by_id):
(JSC::JIT::emit_op_put_getter_setter_by_id):
(JSC::JIT::emit_op_put_getter_by_val):
(JSC::JIT::emit_op_put_setter_by_val):
(JSC::JIT::emit_op_del_by_id):
(JSC::JIT::emitSlow_op_del_by_id):
(JSC::JIT::emit_op_del_by_val):
(JSC::JIT::emitSlow_op_del_by_val):
(JSC::JIT::emit_op_try_get_by_id):
(JSC::JIT::emitSlow_op_try_get_by_id):
(JSC::JIT::emit_op_get_by_id_direct):
(JSC::JIT::emitSlow_op_get_by_id_direct):
(JSC::JIT::emit_op_get_by_id):
(JSC::JIT::emitSlow_op_get_by_id):
(JSC::JIT::emit_op_get_by_id_with_this):
(JSC::JIT::emitSlow_op_get_by_id_with_this):
(JSC::JIT::emit_op_put_by_id):
(JSC::JIT::emitSlow_op_put_by_id):
(JSC::JIT::emit_op_in_by_id):
(JSC::JIT::emitSlow_op_in_by_id):
(JSC::JIT::emit_op_in_by_val):
(JSC::JIT::emitSlow_op_in_by_val):
(JSC::JIT::emit_op_has_private_name):
(JSC::JIT::emitSlow_op_has_private_name):
(JSC::JIT::emit_op_has_private_brand):
(JSC::JIT::emitSlow_op_has_private_brand):
(JSC::JIT::emit_op_resolve_scope):
(JSC::JIT::emit_op_get_from_scope):
(JSC::JIT::emit_op_put_to_scope):
(JSC::JIT::emitSlow_op_put_to_scope):
(JSC::JIT::emit_op_get_from_arguments):
(JSC::JIT::emit_op_put_to_arguments):
(JSC::JIT::emit_op_get_internal_field):
(JSC::JIT::emit_op_put_internal_field):
(JSC::JIT::emit_op_get_property_enumerator):
(JSC::JIT::emit_op_enumerator_next):
(JSC::JIT::emit_op_enumerator_get_by_val):
(JSC::JIT::emitSlow_op_enumerator_get_by_val):
(JSC::JIT::emit_op_enumerator_in_by_val):
(JSC::JIT::emit_op_enumerator_has_own_property):

  • llint/LLIntData.cpp:

(JSC::LLInt::initialize):

  • llint/LLIntData.h:

(JSC::LLInt::exceptionInstructions):
(JSC::LLInt::wasmExceptionInstructions):

  • llint/LLIntExceptions.cpp:

(JSC::LLInt::returnToThrow):
(JSC::LLInt::wasmReturnToThrow):

  • llint/LLIntExceptions.h:
  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::llint_trace_operand):
(JSC::LLInt::llint_trace_value):
(JSC::LLInt::setupGetByIdPrototypeCache):
(JSC::LLInt::performLLIntGetByID):
(JSC::LLInt::varargsSetup):
(JSC::LLInt::commonCallEval):
(JSC::LLInt::dispatchToNextInstructionDuringExit):

  • llint/LLIntSlowPaths.h:
  • llint/LowLevelInterpreter.asm:
  • llint/LowLevelInterpreter.cpp:

(JSC::CLoopRegister::operator const JSInstruction*):
(JSC::CLoop::execute):
(JSC::CLoopRegister::operator const Instruction*): Deleted.

  • llint/LowLevelInterpreter32_64.asm:
  • llint/LowLevelInterpreter64.asm:
  • llint/WebAssembly.asm:
  • runtime/CachedTypes.cpp:

(JSC::CachedInstructionStream::encode):
(JSC::CachedInstructionStream::decode const):
(JSC::CachedCodeBlock::instructions const):

  • runtime/CommonSlowPaths.cpp:

(JSC::updateArithProfileForBinaryArithOp):
(JSC::iteratorOpenTryFastImpl):
(JSC::iteratorNextTryFastImpl):

  • runtime/CommonSlowPaths.h:
  • runtime/JSCConfig.h:
  • runtime/JSCJSValue.h:
  • runtime/SlowPathFunction.h:
  • runtime/VM.cpp:

(JSC::VM::addLoopHintExecutionCounter):
(JSC::VM::getLoopHintExecutionCounter):
(JSC::VM::removeLoopHintExecutionCounter):

  • runtime/VM.h:
  • wasm/WasmCallee.cpp:

(JSC::Wasm::LLIntCallee::LLIntCallee):
(JSC::Wasm::LLIntCallee::outOfLineJumpOffset):
(JSC::Wasm::LLIntCallee::outOfLineJumpTarget):

  • wasm/WasmCallee.h:
  • wasm/WasmFunctionCodeBlockGenerator.cpp:

(JSC::Wasm::FunctionCodeBlockGenerator::setInstructions):
(JSC::Wasm::FunctionCodeBlockGenerator::addOutOfLineJumpTarget):
(JSC::Wasm::FunctionCodeBlockGenerator::outOfLineJumpOffset):

  • wasm/WasmFunctionCodeBlockGenerator.h:

(JSC::Wasm::FunctionCodeBlockGenerator::constantRegisters const):
(JSC::Wasm::FunctionCodeBlockGenerator::instructions const):
(JSC::Wasm::FunctionCodeBlockGenerator::addJumpTarget):
(JSC::Wasm::FunctionCodeBlockGenerator::numberOfJumpTargets):
(JSC::Wasm::FunctionCodeBlockGenerator::lastJumpTarget):
(JSC::Wasm::FunctionCodeBlockGenerator::outOfLineJumpOffset):
(JSC::Wasm::FunctionCodeBlockGenerator::bytecodeOffset):
(JSC::Wasm::FunctionCodeBlockGenerator::tierUpCounter):

  • wasm/WasmGeneratorTraits.h:
  • wasm/WasmLLIntGenerator.cpp:

(JSC::Wasm::LLIntGenerator::addSwitch):
(JSC::GenericLabel<Wasm::GeneratorTraits>::setLocation):

  • wasm/WasmLLIntTierUpCounter.cpp:

(JSC::Wasm::LLIntTierUpCounter::addOSREntryDataForLoop):
(JSC::Wasm::LLIntTierUpCounter::osrEntryDataForLoop const const):

  • wasm/WasmLLIntTierUpCounter.h:

(JSC::Wasm::LLIntTierUpCounter::LLIntTierUpCounter):

  • wasm/WasmSlowPaths.cpp:

(JSC::LLInt::WASM_SLOW_PATH_DECL):
(JSC::LLInt::slow_path_wasm_throw_exception):
(JSC::LLInt::slow_path_wasm_popcount):
(JSC::LLInt::slow_path_wasm_popcountll):

  • wasm/WasmSlowPaths.h:
10:23 PM Changeset in webkit [290767] by Lauro Moura
  • 2 edits in trunk/Tools

[Tools] Fix linux_get_crash_log.py error logging with python3
https://bugs.webkit.org/show_bug.cgi?id=237404

Reviewed by Fujii Hironori.

Avoid issues generating error logs after 247736@main defaulted to
python3.

  • Scripts/webkitpy/port/linux_get_crash_log.py:

(GDBCrashLogGenerator._get_gdb_output): Encode returncode before
appending to bytes.

9:08 PM Changeset in webkit [290766] by sihui_liu@apple.com
  • 20 edits
    4 deletes in trunk/Source/WebKit

REGRESSION (r289474): cacheStoragePath is empty in NetworkStorageManager::localOriginStorageManager
https://bugs.webkit.org/show_bug.cgi?id=237335

Reviewed by Chris Dumez.

CacheStorage::Engine::storagePath returns emptyString if salt file under rootDirectory cannot be read or
written, so we need to make sure sandbox extension for rootDirectory is consumed before calling storagePath
(in createNetworkStorageManager of NetworkSession).

This patch also refactors code about adding session in network process. Now we would create
NetworkStorageManager when NetworkSession is created.

  • NetworkProcess/NetworkConnectionToWebProcess.cpp:

(WebKit::NetworkConnectionToWebProcess::updateQuotaBasedOnSpaceUsageForTesting):
(WebKit::NetworkConnectionToWebProcess::writeBlobsToTemporaryFilesForIndexedDB):

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::createNetworkConnectionToWebProcess):
(WebKit::NetworkProcess::addStorageSession):
(WebKit::NetworkProcess::addWebsiteDataStore):
(WebKit::NetworkProcess::hasLocalStorage):
(WebKit::NetworkProcess::fetchWebsiteData):
(WebKit::NetworkProcess::deleteWebsiteData):
(WebKit::NetworkProcess::deleteWebsiteDataForOrigins):
(WebKit::NetworkProcess::deleteAndRestrictWebsiteDataForRegistrableDomains):
(WebKit::NetworkProcess::registrableDomainsWithWebsiteData):
(WebKit::NetworkProcess::prepareToSuspend):
(WebKit::NetworkProcess::resume):
(WebKit::NetworkProcess::syncLocalStorage):
(WebKit::NetworkProcess::resetQuota):
(WebKit::NetworkProcess::clearStorage):
(WebKit::NetworkProcess::didIncreaseQuota):
(WebKit::NetworkProcess::renameOriginInWebsiteData):
(WebKit::NetworkProcess::uiProcessBundleIdentifier):
(WebKit::NetworkProcess::connectionToWebProcessClosed):
(WebKit::NetworkProcess::ensureSession): Deleted.

  • NetworkProcess/NetworkProcess.h:

(WebKit::NetworkProcess::uiProcessBundleIdentifier const): Deleted.

  • NetworkProcess/NetworkSession.cpp:

(WebKit::createNetworkStorageManager):
(WebKit::NetworkSession::NetworkSession):
(WebKit::NetworkSession::invalidateAndCancel):
(WebKit::NetworkSession::lowMemoryHandler):
(WebKit::NetworkSession::addServiceWorkerSession): Deleted.
(WebKit::NetworkSession::addStorageManagerSession): Deleted.

  • NetworkProcess/NetworkSession.h:

(WebKit::NetworkSession::storageManager):

  • NetworkProcess/NetworkSessionCreationParameters.cpp:

(WebKit::NetworkSessionCreationParameters::encode const):
(WebKit::NetworkSessionCreationParameters::decode):

  • NetworkProcess/NetworkSessionCreationParameters.h:
  • NetworkProcess/RemoteNetworkingContext.h: Removed.
  • NetworkProcess/cache/CacheStorageEngine.cpp:

(WebKit::CacheStorage::Engine::requestSpace):

  • NetworkProcess/cocoa/NetworkProcessCocoa.mm:

(WebKit::NetworkProcess::uiProcessBundleIdentifier):

  • NetworkProcess/curl/RemoteNetworkingContextCurl.cpp: Removed.
  • NetworkProcess/mac/RemoteNetworkingContext.mm: Removed.
  • NetworkProcess/soup/RemoteNetworkingContextSoup.cpp: Removed.
  • PlatformPlayStation.cmake:
  • PlatformWin.cmake:
  • Shared/WebsiteDataStoreParameters.cpp:

(WebKit::WebsiteDataStoreParameters::encode const):
(WebKit::WebsiteDataStoreParameters::decode):
(WebKit::WebsiteDataStoreParameters::~WebsiteDataStoreParameters): Deleted.

  • Shared/WebsiteDataStoreParameters.h:

(): Deleted.

  • SourcesCocoa.txt:
  • SourcesGTK.txt:
  • SourcesWPE.txt:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::addSession):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::parameters):

  • UIProcess/WebsiteData/WebsiteDataStore.h:

(WebKit::WebsiteDataStore::resolvedIndexedDBDirectory const):
(WebKit::WebsiteDataStore::resolvedIndexedDatabaseDirectory const): Deleted.

9:05 PM Changeset in webkit [290765] by sihui_liu@apple.com
  • 14 edits in trunk

Throw proper exception on failed removeEntry() calls
https://bugs.webkit.org/show_bug.cgi?id=237382
<rdar://89232969>

Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

  • web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any-expected.txt:
  • web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getDirectoryHandle.https.any.worker-expected.txt:
  • web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any-expected.txt:
  • web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-getFileHandle.https.any.worker-expected.txt:
  • web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any-expected.txt:
  • web-platform-tests/file-system-access/sandboxed_FileSystemDirectoryHandle-removeEntry.https.any.worker-expected.txt:

Source/WebKit:

Updated existing tests.

  • NetworkProcess/storage/FileSystemStorageError.h:

(WebKit::convertToException):

  • NetworkProcess/storage/FileSystemStorageHandle.cpp:

(WebKit::FileSystemStorageHandle::removeEntry):

LayoutTests:

  • storage/filesystemaccess/handle-move-expected.txt:
  • storage/filesystemaccess/handle-move-worker-expected.txt:
  • storage/filesystemaccess/resources/handle-move.js:

(async test):

6:56 PM Changeset in webkit [290764] by Robert Jenner
  • 2 edits in trunk/LayoutTests

WindowServer returned not alive with context:,unresponsive work processor(s)
<rdar://86037417>

Unreviewed test gardening. Skipping tests on iOS due to tests causing WindowServer to crash.

  • platform/ios-wk2/TestExpectations:
6:44 PM Changeset in webkit [290763] by Robert Jenner
  • 4 edits in trunk/LayoutTests

Unreviewed, reverting r290658.

r290658 broke two tests for iOS, slowing down EWS.

Reverted changeset:

"fast/mediastream/getUserMedia-to-canvas-1.html and
fast/mediastream/getUserMedia-to-canvas-2.html are failing on
MacOS when remote video frame flag is enabled"
https://bugs.webkit.org/show_bug.cgi?id=237042
https://commits.webkit.org/r290658

5:03 PM Changeset in webkit [290762] by Andres Gonzalez
  • 5 edits in trunk/Source/WebCore

ITM: Checkbox state change is not updated in isolated tree
https://bugs.webkit.org/show_bug.cgi?id=237381
rdar://89529486

Reviewed by Chris Fleizach.

Fixes the following test in isolated tree mode:
accessibility/mac/checked-status-tree-items.html
accessibility/aria-switch-checked.html

  • accessibility/isolatedtree/AXIsolatedObject.cpp:

(WebCore::AXIsolatedObject::initializeAttributeData):
Properly initializes the properties SupportsCheckedState, IsChecked and
ButtonState.
(WebCore::AXIsolatedObject::getOrRetrievePropertyValue):
Uses the new template method propertyValue(PropertyName).

  • accessibility/isolatedtree/AXIsolatedObject.h:

(WebCore::AXIsolatedObject::propertyValue const):

  • accessibility/isolatedtree/AXIsolatedTree.cpp:

(WebCore::AXIsolatedTree::updateNodeProperty):
Updates both IsChecked and ButtonState.

  • accessibility/isolatedtree/AXIsolatedTree.h:
4:29 PM Changeset in webkit [290761] by commit-queue@webkit.org
  • 8 edits in trunk/Source

[WebGPU] Implement GPUDeviceDescriptor.requiredLimits
https://bugs.webkit.org/show_bug.cgi?id=232741
Source/WebCore:

<rdar://problem/85325316>

Patch by Dan Glastonbury <djg@apple.com> on 2022-03-02
Reviewed by Myles C. Maxfield.

Implement IDL bindings for requiredLimits attribute of
GPUDeviceDescriptor.

  • Modules/WebGPU/GPUDeviceDescriptor.h:

(WebCore::GPUDeviceDescriptor::convertToBacking const):

  • Modules/WebGPU/GPUDeviceDescriptor.idl:

Source/WebCore/PAL:

<rdar://problem/85325316>

Patch by Dan Glastonbury <djg@apple.com> on 2022-03-02
Reviewed by Myles C. Maxfield.

Implement IDL bindings for requiredLimits attribute of
GPUDeviceDescriptor.

  • pal/graphics/WebGPU/WebGPUDeviceDescriptor.h:

Source/WebKit:

rdar://problem/85325316

Patch by Dan Glastonbury <djg@apple.com> on 2022-03-02
Reviewed by Myles C. Maxfield.

Implement IDL bindings for requiredLimits attribute of
GPUDeviceDescriptor.

  • Shared/WebGPU/WebGPUDeviceDescriptor.cpp:

(WebKit::WebGPU::ConvertToBackingContext::convertToBacking):
(WebKit::WebGPU::ConvertFromBackingContext::convertFromBacking):

  • Shared/WebGPU/WebGPUDeviceDescriptor.h:

(WebKit::WebGPU::DeviceDescriptor::encode const):
(WebKit::WebGPU::DeviceDescriptor::decode):

4:08 PM Changeset in webkit [290760] by Simon Fraser
  • 5 edits
    2 adds in trunk

Rendering issues with many dynamically-added sticky elements inside overflow scroll
https://bugs.webkit.org/show_bug.cgi?id=237378
<rdar://83745510>

Reviewed by Cameron McCormack.

Source/WebCore:

A bug was filed describing a symptom where position:sticky elements would eventually
fail to render when many of them were dynamically added inside a non-stacking context
overflow scroll.

Debugging showed that CALayers were accumulating, causing us to hit per-process IOSurface
limits, at which point content fails to render (this is being fixed via rdar://89640915).
Further debugging showed that these layers were unparented, and being entrained by
ScrollingStateStickyNodes, which were accumulating in ScrollingStateTree's m_unparentedNodes.

This happened because with this scrolling configuration, each ScrollingStateStickyNode
is parented via a ScrollingStateOverflowScrollProxyNode which is referenced by entries
in RenderLayerBacking's m_ancestorClippingStack. On cleanup, the ScrollingStateOverflowScrollProxyNode
was unparented first, leaving the ScrollingStateStickyNode in m_unparentedNodes.

The fix is to have ScrollingStateTree::unparentChildrenAndDestroyNode() remove nodes
from m_unparentedNodes.

To test, add a m_unparentedNodes count to scrollingStateTreeAsText output, which means
having scrollingStateTreeAsText() as a member function on ScrollingStateTree.

Test: scrollingcoordinator/scrolling-tree/accumulated-unparented-sticky-nodes.html

  • page/scrolling/AsyncScrollingCoordinator.cpp:

(WebCore::AsyncScrollingCoordinator::scrollingStateTreeAsText const):

  • page/scrolling/ScrollingStateTree.cpp:

(WebCore::ScrollingStateTree::unparentChildrenAndDestroyNode):
(WebCore::ScrollingStateTree::scrollingStateTreeAsText const):

  • page/scrolling/ScrollingStateTree.h:

LayoutTests:

  • scrollingcoordinator/scrolling-tree/accumulated-unparented-sticky-nodes-expected.txt: Added.
  • scrollingcoordinator/scrolling-tree/accumulated-unparented-sticky-nodes.html: Added.
3:59 PM Changeset in webkit [290759] by Jonathan Bedard
  • 7 edits in trunk/Tools

[webkitcorepy] Add Terminal.open_url
https://bugs.webkit.org/show_bug.cgi?id=237386
<rdar://problem/89703756>

Reviewed by Don Olmstead.

Different platforms have different commands to open URLs.

  • Tools/Scripts/libraries/webkitcorepy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitcorepy/webkitcorepy/terminal.py:

(Terminal): Add list of valid URL prefixes.
(Terminal.open_url): If terminal is interactive, open the provided URL.

  • Tools/Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/setup.py:

(Setup.main): Invoke Terminal.open_url.

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

3:25 PM Changeset in webkit [290758] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

[AppSSO] Correct logging messages to avoid confusing screeners that an error has occurred
https://bugs.webkit.org/show_bug.cgi?id=237390
<rdar://problem/89710486>

Reviewed by Simon Fraser.

The phrasing of the message in 'SOAuthorizationCoordinator::tryAuthorize' when a URL is not relevant for
AppSSO flows is:

AUTHORIZATIONCOORDINATOR_RELEASE_LOG("tryAuthorize: Cannot authorize the requested URL.");

This leads people spelunking logs to believe that the URL can't be authorized (perhaps due to an error).

Instead, we should more accurately report that the URL is not one that is mediated through an AppSSO flow,
and so no AppSSO processing is needed.

  • UIProcess/Cocoa/SOAuthorization/SOAuthorizationCoordinator.mm:

(WebKit::SOAuthorizationCoordinator::tryAuthorize):

3:09 PM Changeset in webkit [290757] by Chris Dumez
  • 2 edits in trunk/Tools

Unreviewed, address post-landing feedback from Darin on r290743

  • WebKitTestRunner/mac/EventSenderProxy.mm:

(WTR::EventSenderProxy::mouseMoveTo):

2:28 PM Changeset in webkit [290756] by Oriol Brufau
  • 39 edits
    4 deletes in trunk

[css] Implement 'text-decoration' as a shorthand.
https://bugs.webkit.org/show_bug.cgi?id=237175

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update tests to take into account that 'text-decoration' is a shorthand.

  • web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:
  • web-platform-tests/css/css-variables/variable-presentation-attribute-expected.txt:
  • web-platform-tests/css/cssom/getComputedStyle-detached-subtree-expected.txt:

Source/WebCore:

The 'text-decoration' property was considered to be a longhand, sharing
a computed value with 'text-decoration-line'.

This patch switches 'text-decoration' into a shorthand of the following
longhands: 'text-decoration-line', 'text-decoration-thickness',
'text-decoration-style' and 'text-decoration-color'. This is according
to https://www.w3.org/TR/css-text-decor-4/#text-decoration-property

For now I'm keeping the grammar as-is, so 'text-decoration' will only
accept values that are valid in 'text-decoration-line', but will set
the other longhands to the initial value. This should probably change
in a follow-up.

I'm also keeping '-webkit-text-decoration' as-is, as a shorthand of
'text-decoration-{line,style,color}', not including thickness for some
obscure reason. '-webkit-text-decoration' should probably be removed
anyways.

There is a bunch of editing code that was getting/setting/removing
'text-decoration' as a longhand, so I'm switching that to:

  • Use 'text-decoration-line' when getting values.
  • Use 'text-decoration' when setting values, and use a string for the value, this parses it and sets each longhand to the correct value.
  • Use 'text-decoration' get removing declarations, effectively removing all longhands.

This preserves the previous behavior as much as possible.

Tests: fast/css/getComputedStyle/computed-style.html

fast/css/getComputedStyle/computed-style-without-renderer.html
fast/css/getComputedStyle/getComputedStyle-text-decoration.html
fast/css/style-enumerate-properties.html
fast/css3-text/css3-text-decoration/getComputedStyle/getComputedStyle-text-decoration-shorthand.html
fast/css3-text/css3-text-decoration/text-decoration-dashed.html
fast/css3-text/css3-text-decoration/text-decoration-dotted-dashed.html
fast/css3-text/css3-text-decoration/text-decoration-dotted.html
imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml.html
imported/w3c/web-platform-tests/css/css-variables/variable-presentation-attribute.html
imported/w3c/web-platform-tests/css/cssom/getComputedStyle-detached-subtree.html
svg/css/getComputedStyle-basic.xhtml

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::valueForPropertyInStyle):

  • css/CSSProperties.json:
  • css/StyleProperties.cpp:

(WebCore::StyleProperties::getPropertyValue const):
(WebCore::StyleProperties::asText const):

  • css/parser/CSSPropertyParser.cpp:

(WebCore::CSSPropertyParser::parseSingleValue):
(WebCore::CSSPropertyParser::parseShorthand):

  • editing/EditingStyle.cpp:

(WebCore::EditingStyle::styleWithResolvedTextDecorations const):
(WebCore::EditingStyle::collapseTextDecorationProperties):
(WebCore::textDecorationValueList):
(WebCore::EditingStyle::conflictsWithInlineStyleOfElement const):
(WebCore::EditingStyle::styleIsPresentInComputedStyleOfNode const):
(WebCore::EditingStyle::mergeStyle):
(WebCore::EditingStyle::removeEquivalentProperties):
(WebCore::reconcileTextDecorationProperties):
(WebCore::StyleChange::StyleChange):
(WebCore::setTextDecorationProperty):
(WebCore::StyleChange::extractTextStyles):
(WebCore::diffTextDecorations):
(WebCore::extractPropertiesNotIn):

  • editing/cocoa/HTMLConverter.mm:

(HTMLConverterCaches::propertyValueForNode):
(HTMLConverter::computedAttributesForElement):

  • editing/markup.cpp:

(WebCore::serializePreservingVisualAppearanceInternal):

  • style/PropertyAllowlist.cpp:

(WebCore::Style::isValidCueStyleProperty):

LayoutTests:

Update tests to take into account that 'text-decoration' is a shorthand.

  • editing/pasteboard/data-transfer-get-data-on-drop-rich-text-expected.txt:
  • fast/css/getComputedStyle/computed-style-expected.txt:
  • fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
  • fast/css/getComputedStyle/getComputedStyle-text-decoration-expected.txt:
  • fast/css/getComputedStyle/getComputedStyle-text-decoration.html:
  • fast/css/getComputedStyle/resources/property-names.js:
  • fast/css/style-enumerate-properties-expected.txt:
  • fast/css/style-enumerate-properties.html:
  • fast/css3-text/css3-text-decoration/getComputedStyle/getComputedStyle-text-decoration-shorthand-expected.txt:
  • fast/css3-text/css3-text-decoration/getComputedStyle/getComputedStyle-text-decoration-shorthand.html:
  • fast/css3-text/css3-text-decoration/text-decoration-dashed-expected-mismatch.html:
  • fast/css3-text/css3-text-decoration/text-decoration-dashed.html:
  • fast/css3-text/css3-text-decoration/text-decoration-dotted-dashed-expected-mismatch.html:
  • fast/css3-text/css3-text-decoration/text-decoration-dotted-dashed.html:
  • fast/css3-text/css3-text-decoration/text-decoration-dotted-expected-mismatch.html:
  • fast/css3-text/css3-text-decoration/text-decoration-dotted.html:
  • fast/events/input-events-paste-rich-datatransfer-expected.txt:
  • platform/glib/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
  • platform/glib/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
  • platform/glib/svg/css/getComputedStyle-basic-expected.txt: Removed.
  • platform/gtk/fast/events/input-events-paste-rich-datatransfer-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-detached-subtree-expected.txt:
  • platform/ios/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
  • platform/ios/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
  • platform/ios/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:
  • platform/ios/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-detached-subtree-expected.txt:
  • platform/ios/svg/css/getComputedStyle-basic-expected.txt: Removed.
  • platform/wpe/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-detached-subtree-expected.txt:
  • svg/css/getComputedStyle-basic-expected.txt:
2:07 PM Changeset in webkit [290755] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

[WebAuthn] Completion handler is not called when WebAuthn invoked without proper entitlements
https://bugs.webkit.org/show_bug.cgi?id=237380
<rdar://problem/89700242>

Reviewed by Chris Dumez.

WebAuthn is not permitted outside of Web Browser applications. When an application that lacks
the full web browser entitlement attempts to invoke WebAuthn flows, we do an early return. However,
the completion handler for this flow is bypassed, preventing applications from being informed of
this problem.

  • WebProcess/WebAuthentication/WebAuthenticatorCoordinator.cpp:

(WebKit::WebAuthenticatorCoordinator::makeCredential):
(WebKit::WebAuthenticatorCoordinator::getAssertion):
(WebKit::WebAuthenticatorCoordinator::isUserVerifyingPlatformAuthenticatorAvailable):

1:25 PM Changeset in webkit [290754] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[iOS] Seatbelt sandbox profile entitlement is deprecated
https://bugs.webkit.org/show_bug.cgi?id=237374

Reviewed by Brent Fulgham.

Replace with new entitlement.

  • Scripts/process-entitlements.sh:
1:12 PM Changeset in webkit [290753] by Jonathan Bedard
  • 2 edits in trunk/Tools

[Python-3] Invoke webkit-patch with Python 3 by default
https://bugs.webkit.org/show_bug.cgi?id=231591
<rdar://problem/84153640>

Reviewed by Ryan Haddad.

  • Scripts/webkit-patch: Change shebang to Python 3.
1:10 PM Changeset in webkit [290752] by pvollan@apple.com
  • 3 edits in trunk/Source/WebKit

[iOS] Hard link AVPictureInPictureController
https://bugs.webkit.org/show_bug.cgi?id=237227

Reviewed by Brent Fulgham.

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

  • Configurations/WebKit.xcconfig:
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):

1:04 PM Changeset in webkit [290751] by J Pascoe
  • 5 edits in trunk/LayoutTests

[WebAuthn] Remove obsolete failed attestation tests
https://bugs.webkit.org/show_bug.cgi?id=237346
rdar://problem/89647260

Reviewed by Brent Fulgham.

The removed items tested that creation fails whenever attestation fails, however
we've changed behavior such that creation succeeds with 'none' attestation in this
case, making these failure tests obsolete.

  • http/wpt/webauthn/public-key-credential-create-failure-local-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-local-silent.https.html:
  • http/wpt/webauthn/public-key-credential-create-failure-local.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-local.https.html:
12:59 PM Changeset in webkit [290750] by Robert Jenner
  • 2 edits in trunk/LayoutTests

[ iOS Debug ] editing/async-clipboard/* 20 tests are flaky timeouts on iOS.
https://bugs.webkit.org/show_bug.cgi?id=237372

Unreviewed test gardening.

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

  • platform/ios-wk2/TestExpectations:
12:56 PM Changeset in webkit [290749] by Robert Jenner
  • 2 edits in trunk/LayoutTests

REGRESSION(r290539): [ iOS ] 2X http/wpt/webauthn/public-key-credential-create-failure-local (layout-tests) are constant text failures
https://bugs.webkit.org/show_bug.cgi?id=237346

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
12:53 PM BuildingCairoOnWindows edited by Fujii Hironori
(diff)
12:53 PM Changeset in webkit [290748] by Jonathan Bedard
  • 5 edits in trunk/Tools

[git-webkit] Derive branch name from bug title
https://bugs.webkit.org/show_bug.cgi?id=237284
<rdar://problem/89578241 >

Reviewed by Dewei Zhu.

  • Tools/Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/branch.py:

(Branch.to_branch_name): Convert string (particularly a bug title) to potential branch name.
(Branch.main): If provided branch name is actually a bug number or URL, use the title
of that bug as the branch name.

  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/test/branch_unittest.py:

(TestBranch):
(TestBranch.test_prompt_git):
(TestBranch.test_prompt_number):
(TestBranch.test_prompt_url):
(TestBranch.test_invalid_branch):
(TestBranch.test_to_branch_name):

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

12:41 PM Changeset in webkit [290747] by Jonathan Bedard
  • 9 edits in trunk

[git-webkit] Sync personal fork by default
https://bugs.webkit.org/show_bug.cgi?id=237324
<rdar://problem/89618617>

Reviewed by Dewei Zhu.

  • metadata/project_config: Add webkitscmpy.update-fork option.
  • Tools/Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/local/git.py:

(Git): Add new webkitscmpy.update-fork option.

  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/git.py:
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py:

(PullRequest.main): If we are rebasing the source branch, we should push that synced branch
to a user's personal fork, if such a fork exists.

  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/test/pull_request_unittest.py:

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

12:18 PM Changeset in webkit [290746] by Wenson Hsieh
  • 15 edits in trunk

[iOS] Copy context menu action should be titled "Copy Link" when long pressing a non-image link
https://bugs.webkit.org/show_bug.cgi?id=237367
rdar://77397886

Reviewed by Devin Rousso.

Source/WebCore:

Add a localizable string for "Copy Link". See WebKit/ChangeLog for more details.

  • en.lproj/Localizable.strings:

Source/WebKit:

Change the current title of the "Copy" context menu action to "Copy Link", when showing the context menu for a
non-image link. See below for more details.

Tests: fast/events/touch/ios/long-press-on-link.html

fast/events/touch/ios/long-press-on-image.html

  • UIProcess/API/Cocoa/_WKActivatedElementInfo.mm:

(-[_WKActivatedElementInfo _initWithInteractionInformationAtPosition:userInfo:]):
(-[_WKActivatedElementInfo _isImage]):

Add a helper method to return whether or not the activated element represents an image. Crucially, this will
return YES in the case of image links, even though the activated element type is _WKActivatedElementTypeLink.
We consult this below to still show "Copy" in the case of image links, instead of "Copy Link".

  • UIProcess/API/Cocoa/_WKActivatedElementInfoInternal.h:
  • UIProcess/API/Cocoa/_WKElementAction.mm:

(+[_WKElementAction _elementActionWithType:customTitle:assistant:]):
(+[_WKElementAction _elementActionWithType:info:assistant:]):

Add a _WKActivatedElementInfo argument to -_elementActionWithType:assistant:, and use this to set a custom
title for the menu action in the case of the Copy action for non-image links.

(+[_WKElementAction _elementActionWithType:assistant:]): Deleted.

  • UIProcess/API/Cocoa/_WKElementActionInternal.h:
  • UIProcess/ios/WKActionSheetAssistant.mm:

(-[WKActionSheetAssistant _appendOpenActionsForURL:actions:elementInfo:]):
(-[WKActionSheetAssistant defaultActionsForLinkSheet:]):
(-[WKActionSheetAssistant defaultActionsForImageSheet:]):

Additionally use -_isImage instead of -image here when supplying several default Visual Look Up-related
items; -image is misleading here, since it returns a non-null result even in the case of non-image elements,
if a node snapshot was requested by the client. It's also a bit wasteful, since it means we currently create an
image from the bitmap data while performing this check, when we really only need to know whether the hit-tested
element was an image element.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView _simulateElementAction:atLocation:]):
(-[WKContentView _contentsOfUserInterfaceItem:]):
(-[WKContentView _contextMenuInteraction:configurationForMenuAtLocation:completion:]):

Include the titles of all visible menu items as an additional argument in the "contents of user interface item"
dictionary, in the case of context menus. To do this, we take advantage of the -updateVisibleMenuWithBlock:
API, which passes the currently visible UIMenu, to collect the titles of each visible menu item, and then
simply return the visible menu as-is.

See adjusted layout tests for more information.

(-[WKContentView contextMenuInteraction:willDisplayMenuForConfiguration:animator:]):

Move the call to -_didShowContextMenu to the animation completion block, such that we invoke the testing
completion handler for didShowContextMenuCallback after the menu is actually visible. Importantly, this allows
us to query the list of visible menu item titles above, by calling -updateVisibleMenuWithBlock:.

  • UIProcess/mac/DisplayCaptureSessionManager.mm:

(WebKit::alertForWindowSelection):

Drive-by fix: add quotes around the description argument to the UI string macro to fix an error when running
the update-webkit-localizable-strings script.

LayoutTests:

Adjust a couple of layout tests to check for items labeled "Copy" (in the case of an image) and "Copy Link" (in
the case of a link).

  • fast/events/touch/ios/long-press-on-image-expected.txt:
  • fast/events/touch/ios/long-press-on-image.html:
  • fast/events/touch/ios/long-press-on-link-expected.txt:
  • fast/events/touch/ios/long-press-on-link.html:
11:58 AM Changeset in webkit [290745] by mmaxfield@apple.com
  • 4 edits
    2 adds in trunk/LayoutTests

[Cocoa] The behavior of navigator-language-ru changed in Monterey / iOS 15
https://bugs.webkit.org/show_bug.cgi?id=237384
<rdar://problem/80335706>

Unreviewed test gardening.

Add a new test for the new behavior, but keep the old one too for older OSes.

  • fast/text/international/system-language/navigator-language/navigator-language-ru-2-expected.txt: Added.
  • fast/text/international/system-language/navigator-language/navigator-language-ru-2.html: Added.
  • platform/ios-14/TestExpectations:
  • platform/ios/TestExpectations:
  • platform/mac-wk2/TestExpectations:
11:47 AM Changeset in webkit [290744] by J Pascoe
  • 2 edits in trunk/Source/WebKit

[WebAuthn] Ensure presenter gets dismissed on iOS
https://bugs.webkit.org/show_bug.cgi?id=237336
rdar://81609371

Reviewed by Brent Fulgham.

Always call [m_presenter dismissWithError] to ensure presenter gets dismissed.

  • UIProcess/WebAuthentication/Cocoa/AuthenticatorPresenterCoordinator.mm:

(WebKit::AuthenticatorPresenterCoordinator::dimissPresenter):

11:39 AM Changeset in webkit [290743] by Chris Dumez
  • 13 edits in trunk

Mousemove events double-firing in Safari
https://bugs.webkit.org/show_bug.cgi?id=237342
<rdar://88025610>

Reviewed by Wenson Hsieh.

Source/WebKit:

When we constructed a WebViewImpl, we would add a mouse tracking area to the view,
so that mouseMoved/mouseEntered/mouseExited would get called and we would be able
to forward these mouse events to the WebContent process. However, when the view
becomes first responder, an implicit mouse tracking area also gets added. As a
result, we would get duplicate calls to mouseMoved/mouseEntered/mouseExited.

We consulted with the AppKit team and their recommendation was to use a different
owner object for our mouse tracking area and have that object forward the
mouseMoved/mouseEntered/mouseExited calls to our WebViewImpl. In doing so, we
can stop forwarding mouseMoved/mouseEntered/mouseExited calls from WKWebView &
WKView, which are NOT for our mouse tracking area.

No new tests, I tried but wasn't able to write an API test for this.
I had trouble making the test window key so that the view would receive
the (duplicate) mousemove events. I validated via logging that we are no longer
getting duplicate mousemove events. I also checked on
https://www.vsynctester.com/testing/mouse.html that the output now looks correct.

  • UIProcess/API/Cocoa/WKViewPrivate.h:
  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/mac/WKView.mm:

(-[WKView _simulateMouseMove:]):
(-[WKView mouseMoved:]): Deleted.
(-[WKView mouseEntered:]): Deleted.
(-[WKView mouseExited:]): Deleted.

  • UIProcess/API/mac/WKWebViewMac.mm:

(-[WKWebView _simulateMouseMove:]):
(-[WKWebView mouseMoved:]): Deleted.
(-[WKWebView mouseEntered:]): Deleted.
(-[WKWebView mouseExited:]): Deleted.

  • UIProcess/Cocoa/WebViewImpl.h:
  • UIProcess/Cocoa/WebViewImpl.mm:

(-[WKMouseTrackingObserver initWithViewImpl:]):
(-[WKMouseTrackingObserver mouseMoved:]):
(-[WKMouseTrackingObserver mouseEntered:]):
(-[WKMouseTrackingObserver mouseExited:]):
(WebKit::WebViewImpl::WebViewImpl):
(WebKit::WebViewImpl::updatePrimaryTrackingAreaOptions):
(WebKit::WebViewImpl::setPrimaryTrackingArea): Deleted.

  • UIProcess/mac/PageClientImplMac.mm:

(WebKit::PageClientImpl::recommendedScrollbarStyleDidChange):

Tools:

Call [WKWebView _simulateMouseMove:] SPI instead of calling [WKWebView mouseMoved:]
since the latter calls are now being ignored.

  • TestWebKitAPI/cocoa/TestWKWebView.mm:

(-[TestWKWebView mouseMoveToPoint:withFlags:]):

  • TestWebKitAPI/mac/PlatformWebViewMac.mm:

(TestWebKitAPI::PlatformWebView::simulateMouseMove):

  • WebKitTestRunner/mac/EventSenderProxy.mm:

(WTR::EventSenderProxy::mouseMoveTo):

11:26 AM Changeset in webkit [290742] by Russell Epstein
  • 1 copy in tags/Safari-614.1.3.8

Tag Safari-614.1.3.8.

11:21 AM Changeset in webkit [290741] by graouts@webkit.org
  • 5 edits in trunk

[web-animations] setting the composite property on a keyframe effect should invalidate the target style
https://bugs.webkit.org/show_bug.cgi?id=237356

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

  • web-platform-tests/web-animations/animation-model/keyframe-effects/effect-value-context-filling-expected.txt:

Source/WebCore:

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::setComposite):

  • animation/KeyframeEffect.h:

(WebCore::KeyframeEffect::setComposite): Deleted.

11:06 AM Changeset in webkit [290740] by Russell Epstein
  • 9 edits in branches/safari-614.1.3-branch/Source

Versioning.

WebKit-7614.1.3.8

10:59 AM Changeset in webkit [290739] by sihui_liu@apple.com
  • 10 edits in trunk

Add assertion that no two sessions share the same general storage directory
https://bugs.webkit.org/show_bug.cgi?id=236844
<rdar://problem/89178566>

Reviewed by Chris Dumez.

Source/WebKit:

rdar://89190571 shows that there can be two WebsiteDataStores using the same general storage directory, when
initializing network process. This can lead to corruption because storage code of each session runs on its own
WorkQueue (or thread) in network process. If two sessions (WebsiteDataStores) use the same directory, the
directory and its files may be accessed concurrently. The correct usage is creating different persistent
sessions with different paths. Let's add an assertion to help find problematic use case.

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::sendCreationParametersToNewProcess):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::parameters):

  • UIProcess/WebsiteData/WebsiteDataStore.h:

(WebKit::WebsiteDataStore::cacheStorageDirectory const):
(WebKit::WebsiteDataStore::resolvedGeneralStorageDirectory const):
(WebKit::WebsiteDataStore::generalStorageDirectory const): Deleted.

Tools:

Update the tests where two WebsiteDataStores are created with the same general storage directory.

  • TestWebKitAPI/Tests/WebKitCocoa/PrivateClickMeasurement.mm:

(emptyObservationsDBPath):
(emptyPcmDBPath):
(cleanUp):

  • TestWebKitAPI/Tests/WebKitCocoa/PushAPI.mm:
  • TestWebKitAPI/Tests/WebKitCocoa/ResourceLoadStatistics.mm:

(TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/WebPushDaemon.mm:
  • TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:

(runWebsiteDataStoreCustomPaths):

10:53 AM Changeset in webkit [290738] by Tyler Wilcock
  • 2 edits in trunk/Source/WebCore

AX: Handle null FileList in RenderFileUploadControl::fileTextValue()
https://bugs.webkit.org/show_bug.cgi?id=237349

Reviewed by Chris Fleizach.

In rare circumstances, it's possible for the FileList associated
with RenderFileUploadControl::inputElement (HTMLInputElement::files())
to be null. This causes a crash in RenderFileUploadControl::fileTextValue().

In this patch, we avoid this crash by handling a null FileList
and returning a null String.

  • rendering/RenderFileUploadControl.cpp:

(WebCore::RenderFileUploadControl::fileTextValue const):
Handle null input.files() and return a null String rather than ASSERTing.

10:52 AM Changeset in webkit [290737] by Alan Coon
  • 1 copy in branches/safari-test-branch

New branch.

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

Add test coverage for deleting FileSystem data when file is being written
https://bugs.webkit.org/show_bug.cgi?id=237353

Reviewed by Chris Dumez.

Verify that file can be removed from disk, and active FileSystemSyncAccessHandle is invalidated in this case.

  • TestWebKitAPI/Tests/WebKitCocoa/FileSystemAccess.mm:
10:47 AM Changeset in webkit [290735] by graouts@webkit.org
  • 3 edits
    2 adds in trunk

Outline-width with transition don't animate correctly
https://bugs.webkit.org/show_bug.cgi?id=173708

Reviewed by Antti Koivisto.

Source/WebCore:

Account for a change in outline size when checking whether a style change affects
visual overflow.

No new test for this, I'm not sure how to write one since the issue is failing to
repaint during an animation but WKTR seems to force a repaint for reftests.

  • rendering/style/RenderStyle.cpp:

(WebCore::RenderStyle::changeAffectsVisualOverflow const):

LayoutTests:

Add a repaint test that checks that the outline is accounted for during the transition.

  • fast/repaint/outline-transition-expected.txt: Added.
  • fast/repaint/outline-transition.html: Added.
9:09 AM Changeset in webkit [290734] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[RTL] Image alt text has incorrect bidi reordering
https://bugs.webkit.org/show_bug.cgi?id=237366
<rdar://problem/89687229>

Reviewed by Antti Koivisto.

Source/WebCore:

Test: fast/images/alt-text-with-right-to-left-inline-direction-reordering.html

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::paintReplaced): Enable bidi reordering.

LayoutTests:

  • fast/images/alt-text-with-right-to-left-inline-direction-reordering-expected-mismatch.html: Added.
  • fast/images/alt-text-with-right-to-left-inline-direction-reordering.html: Added.
9:07 AM Changeset in webkit [290733] by youenn@apple.com
  • 11 edits in trunk/Source

Rename MediaSampleAVFObjC::createImageSample to MediaSampleAVFObjC::createFromPixelBuffer
https://bugs.webkit.org/show_bug.cgi?id=237354

Reviewed by Eric Carlson.

Source/WebCore:

No change of behavior, this is a renaming.

  • html/HTMLCanvasElement.cpp:

(WebCore::HTMLCanvasElement::toMediaSample):

  • platform/graphics/avfoundation/objc/MediaSampleAVFObjC.h:

(WebCore::MediaSampleAVFObjC::createFromPixelBuffer):
(WebCore::MediaSampleAVFObjC::createImageSample): Deleted.

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

(WebCore::MediaSampleAVFObjC::createFromPixelBuffer):
(WebCore::MediaSampleAVFObjC::createImageSample): Deleted.

  • platform/graphics/cocoa/GraphicsContextGLCocoa.mm:

(WebCore::GraphicsContextGLCocoa::paintCompositedResultsToMediaSample):

  • platform/mediastream/RealtimeVideoSource.cpp:

(WebCore::RealtimeVideoSource::adaptVideoSample):

Source/WebKit:

  • GPUProcess/webrtc/LibWebRTCCodecsProxy.mm:

(WebKit::LibWebRTCCodecsProxy::createDecoderCallback):

  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.cpp:

(WebKit::UserMediaCaptureManagerProxy::SourceProxy::rotateVideoFrameIfNeeded):

  • WebProcess/GPU/webrtc/SharedVideoFrame.cpp:

(WebKit::SharedVideoFrameReader::read):

  • WebProcess/cocoa/RemoteCaptureSampleManager.cpp:

(WebKit::RemoteCaptureSampleManager::RemoteVideo::videoSampleAvailable):

8:59 AM Changeset in webkit [290732] 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-03-02
Reviewed by Antti Koivisto.
Reland after revert:
Add missing includes to JSC inlines, needed for ASAN build. Compile
failure was hidden my unified build.

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>):

8:45 AM Changeset in webkit [290731] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[iOS][WP] Stop generating certain sandbox violation reports
https://bugs.webkit.org/show_bug.cgi?id=237364

Reviewed by Chris Dumez.

Stop generating certain common sandbox violation reports in the WebContent process on iOS, since that
can improve performance. We will still get telemetry for these violations.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb.in:
7:27 AM Changeset in webkit [290730] by graouts@webkit.org
  • 15 edits in trunk

[web-animations] changes to font-size should recompute keyframes
https://bugs.webkit.org/show_bug.cgi?id=237357

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

  • web-platform-tests/css/css-animations/responsive/column-width-001-expected.txt:
  • web-platform-tests/web-animations/animation-model/keyframe-effects/effect-value-context-expected.txt:
  • web-platform-tests/web-animations/animation-model/keyframe-effects/effect-value-context-filling-expected.txt:
  • web-platform-tests/web-animations/responsive/fontSize-expected.txt:
  • web-platform-tests/web-animations/responsive/perspective-expected.txt:
  • web-platform-tests/web-animations/responsive/textIndent-expected.txt:
  • web-platform-tests/web-animations/responsive/to-style-change-expected.txt:

Source/WebCore:

When we compute keyframes, it's possible that some values are specified using "em" units
and thus dependent on the current value for font-size. If the font-size changes over time,
we must recompute keyframes to ensure that any such value is updated.

To ensure that we correctly determine when the font-size changed, we pass a pointer to the
style seen when we last udpated animations so that we only consider a change in font-size
provided we've ever resolved animations.

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::propertyAffectingKeyframeResolutionDidChange):
(WebCore::KeyframeEffect::propertyAffectingLogicalPropertiesDidChange): Deleted.

  • animation/KeyframeEffect.h:
  • animation/KeyframeEffectStack.cpp:

(WebCore::KeyframeEffectStack::applyKeyframeEffects):

  • animation/KeyframeEffectStack.h:
  • style/StyleTreeResolver.cpp:

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

  • style/Styleable.h:

(WebCore::Styleable::applyKeyframeEffects const):

7:23 AM Changeset in webkit [290729] by Oriol Brufau
  • 6 edits in trunk

[css-cascade] Support 'revert-layer' in @keyframes
https://bugs.webkit.org/show_bug.cgi?id=237152

Reviewed by Antti Koivisto.

Source/WebCore:

In @keyframes, 'revert-layer' should roll back the cascaded value to
author origin. Resolver::styleForKeyframe already has the base style of
the element, so we only need to avoid applying properties with the
'revert-layer' value.

Test: imported/w3c/web-platform-tests/css/css-cascade/revert-layer-010.html.html

  • style/StyleBuilder.cpp:

(WebCore::Style::Builder::applyProperty):

  • style/StyleBuilderState.h:

(WebCore::Style::BuilderState::setIsBuildingKeyframeStyle):

  • style/StyleResolver.cpp:

(WebCore::Style::Resolver::styleForKeyframe):

LayoutTests:

Expect test to pass.

7:06 AM Changeset in webkit [290728] by commit-queue@webkit.org
  • 15 edits in trunk/Source

[GTK] setDragImage ignores offset
https://bugs.webkit.org/show_bug.cgi?id=237292

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

Source/WebCore:

To fix this, I need DataTransfer to expose its dragLocation, which is the offset passed to
setDragImage.

  • dom/DataTransfer.h:

(WebCore::DataTransfer::dragLocation const):

Source/WebKit:

Plumb the offset from the last place we have access to a DataTransfer object down to
DragSource, where it's ultimately used. This allows web content to properly position the
drag image under the mouse cursor.

  • UIProcess/API/gtk/DragSource.h:
  • UIProcess/API/gtk/DragSourceGtk3.cpp:

(WebKit::DragSource::begin):

  • UIProcess/API/gtk/DragSourceGtk4.cpp:

(WebKit::DragSource::begin):

  • UIProcess/API/gtk/PageClientImpl.cpp:

(WebKit::PageClientImpl::startDrag):

  • UIProcess/API/gtk/PageClientImpl.h:
  • UIProcess/API/gtk/WebKitWebViewBase.cpp:

(webkitWebViewBaseStartDrag):

  • UIProcess/API/gtk/WebKitWebViewBasePrivate.h:
  • UIProcess/PageClient.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::startDrag):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebPageProxy.messages.in:
  • WebProcess/WebCoreSupport/gtk/WebDragClientGtk.cpp:

(WebKit::WebDragClient::startDrag):

7:03 AM Changeset in webkit [290727] by Adrian Perez de Castro
  • 2 edits in trunk

[CMake] Build failure with libstdc++ (>= 6) when cross-compiling (fatal error: stdlib.h: No such file or directory)
https://bugs.webkit.org/show_bug.cgi?id=161697
<rdar://problem/89613152>

Reviewed by Carlos Garcia Campos.

  • Source/cmake/WebKitCompilerFlags.cmake: Go through CMake instead of the plain "env"

program for the sake of portability.

6:49 AM Changeset in webkit [290726] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[RTL] Incorrect alt text position in right to left context
https://bugs.webkit.org/show_bug.cgi?id=237352
<rdar://problem/89657704>

Reviewed by Simon Fraser.

Source/WebCore:

Take the inline direction into account when computing the alt text location.

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::paintReplaced): This is mostly moving things around/modernizing it.

LayoutTests:

  • fast/images/alt-text-with-right-to-left-inline-direction-expected-mismatch.html: Added.
  • fast/images/alt-text-with-right-to-left-inline-direction.html: Added.
5:49 AM Changeset in webkit [290725] by youenn@apple.com
  • 2 edits in trunk/Source/WebKit

Annotate LibWebRTC with thread safety macros
https://bugs.webkit.org/show_bug.cgi?id=237321
<rdar://problem/89625577>

Unreviewed, addressing post commit style change.
No change of behavior.

  • WebProcess/GPU/webrtc/LibWebRTCCodecs.h:
12:50 AM Changeset in webkit [290724] by Carlos Garcia Campos
  • 6 edits in trunk

REGRESSION(r216096): [GTK] Test accessibility/gtk/menu-list-unfocused-notifications.html is failing since r216096
https://bugs.webkit.org/show_bug.cgi?id=171598

Reviewed by Adrian Perez de Castro.

Source/WebCore:

Enable accessibility when a WTR observer is added.

  • accessibility/atspi/AccessibilityAtspi.cpp:

(WebCore::AccessibilityAtspi::addNotificationObserver):

LayoutTests:

Since r216096 the notification for menu list changes is deffered, so we need to wait one run loop cycle to get
the notifications. Also update the test to ignore notifications that are not interesting like AXLoadComplete and
AXElementBusyChanged, and update expectations for the new behavior with ATSPI where the notification is emitted
on the menu and not the combo.

  • accessibility/gtk/menu-list-unfocused-notifications-expected.txt:
  • accessibility/gtk/menu-list-unfocused-notifications.html:
  • platform/gtk/TestExpectations:
12:49 AM Changeset in webkit [290723] by Carlos Garcia Campos
  • 3 edits in trunk/LayoutTests

[ATSPI] Test accessibility/select-element-at-index.html is failing
https://bugs.webkit.org/show_bug.cgi?id=237315

Reviewed by Adrian Perez de Castro.

This is because the test contains platform specific behavior for ATK that was migrated to ATSPI by mistake. We
should behave like all other ports now.

  • accessibility/select-element-at-index.html:
  • platform/glib/TestExpectations:
12:09 AM Changeset in webkit [290722] by commit-queue@webkit.org
  • 31 edits
    7 copies
    3 adds in trunk

Add SPI _WKDataTask
https://bugs.webkit.org/show_bug.cgi?id=237234

Patch by Alex Christensen <achristensen@webkit.org> on 2022-03-02
Reviewed by Tim Horton.

Source/WebKit:

When I added WKWebView._requestResource:completionHandler: I overlooked a few things.
First, it is unable to support HTTPS because I didn't hook up authentication challenge handling to it.
Second, it is unable to have a maximum accepted response length, which is a requirement for an adopter.
To make these possible, I made _WKDataTask which is related to WKDownload and NSURLSessionDataTask.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::dataTaskWithRequest):
(WebKit::NetworkProcess::cancelDataTask):
(WebKit::NetworkProcess::requestResource): Deleted.

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/NetworkSession.h:

(WebKit::NetworkSession::dataTaskWithRequest):
(WebKit::NetworkSession::cancelDataTask):
(WebKit::NetworkSession::requestResource): Deleted.

  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::dataTaskWithRequest):
(WebKit::NetworkSessionCocoa::cancelDataTask):
(WebKit::NetworkSessionCocoa::removeDataTask):
(WebKit::NetworkSessionCocoa::requestResource): Deleted.

  • NetworkProcess/cocoa/WKURLSessionTaskDelegate.h: Copied from Source/WebKit/Shared/Authentication/cocoa/AuthenticationChallengeDispositionCocoa.h.
  • NetworkProcess/cocoa/WKURLSessionTaskDelegate.mm: Added.

(-[WKURLSessionTaskDelegate initWithIdentifier:session:]):
(-[WKURLSessionTaskDelegate connection]):
(-[WKURLSessionTaskDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
(-[WKURLSessionTaskDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):
(-[WKURLSessionTaskDelegate URLSession:dataTask:didReceiveResponse:completionHandler:]):
(-[WKURLSessionTaskDelegate URLSession:dataTask:didReceiveData:]):
(-[WKURLSessionTaskDelegate URLSession:task:didCompleteWithError:]):

  • Scripts/webkit/messages.py:

(types_that_cannot_be_forward_declared):

  • Shared/API/APIObject.h:
  • Shared/Authentication/cocoa/AuthenticationChallengeDispositionCocoa.h:
  • Shared/Authentication/cocoa/AuthenticationChallengeDispositionCocoa.mm:

(WebKit::fromAuthenticationChallengeDisposition):

  • Shared/Cocoa/APIObject.mm:

(API::Object::newObject):

  • Shared/DataTaskIdentifier.h: Copied from Source/WebKit/Shared/Authentication/cocoa/AuthenticationChallengeDispositionCocoa.h.
  • Sources.txt:
  • SourcesCocoa.txt:
  • UIProcess/API/APIDataTask.cpp: Copied from Source/WebKit/UIProcess/API/APIInspectorExtensionClient.h.

(API::DataTask::setClient):
(API::DataTask::cancel):
(API::DataTask::DataTask):

  • UIProcess/API/APIDataTask.h: Copied from Source/WebKit/UIProcess/API/APIInspectorExtensionClient.h.

(API::DataTask::create):
(API::DataTask::page):
(API::DataTask::client const):

  • UIProcess/API/APIDataTaskClient.h: Copied from Source/WebKit/UIProcess/API/APIInspectorExtensionClient.h.

(API::DataTaskClient::create):
(API::DataTaskClient::~DataTaskClient):
(API::DataTaskClient::didReceiveChallenge const):
(API::DataTaskClient::willPerformHTTPRedirection const):
(API::DataTaskClient::didReceiveResponse const):
(API::DataTaskClient::didReceiveData const):
(API::DataTaskClient::didCompleteWithError const):

  • UIProcess/API/APIInspectorExtensionClient.h:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _dataTaskWithRequest:completionHandler:]):
(-[WKWebView _requestResource:completionHandler:]): Deleted.

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/Cocoa/_WKDataTask.h: Copied from Source/WebKit/UIProcess/API/APIInspectorExtensionClient.h.
  • UIProcess/API/Cocoa/_WKDataTask.mm: Added.

(-[_WKDataTask cancel]):
(-[_WKDataTask webView]):
(-[_WKDataTask delegate]):
(-[_WKDataTask setDelegate:]):
(-[_WKDataTask dealloc]):
(-[_WKDataTask _apiObject]):

  • UIProcess/API/Cocoa/_WKDataTaskDelegate.h: Added.
  • UIProcess/API/Cocoa/_WKDataTaskInternal.h: Copied from Source/WebKit/Shared/Authentication/cocoa/AuthenticationChallengeDispositionCocoa.h.
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::dataTaskWithRequest):
(WebKit::NetworkProcessProxy::dataTaskReceivedChallenge):
(WebKit::NetworkProcessProxy::dataTaskWillPerformHTTPRedirection):
(WebKit::NetworkProcessProxy::dataTaskDidReceiveResponse):
(WebKit::NetworkProcessProxy::dataTaskDidReceiveData):
(WebKit::NetworkProcessProxy::dataTaskDidCompleteWithError):
(WebKit::NetworkProcessProxy::requestResource): Deleted.

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/Network/NetworkProcessProxy.messages.in:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::dataTaskWithRequest):
(WebKit::WebPageProxy::requestResource): Deleted.

  • UIProcess/WebPageProxy.h:
  • WebKit.xcodeproj/project.pbxproj:

Source/WTF:

  • wtf/PlatformHave.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/NetworkProcess.mm:

(-[TestDataTaskDelegate dataTask:didReceiveAuthenticationChallenge:completionHandler:]):
(-[TestDataTaskDelegate dataTask:didReceiveResponse:decisionHandler:]):
(-[TestDataTaskDelegate dataTask:didReceiveData:]):
(-[TestDataTaskDelegate dataTask:didCompleteWithError:]):
(TEST):

Note: See TracTimeline for information about the timeline view.