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

Timeline



Dec 6, 2021:

11:30 PM Changeset in webkit [286590] by pvollan@apple.com
  • 7 edits in trunk/Source/WebKit

[iOS] Remove mach service extensions for the WebContent process
https://bugs.webkit.org/show_bug.cgi?id=232952
<rdar://problem/85259753>

Reviewed by Brent Fulgham.

Remove mach service extensions for the WebContent process, which we think are no longer needed, based on local testing.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb.in:
  • Shared/WebProcessCreationParameters.cpp:

(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):
(WebKit::nonBrowserServices): Deleted.

  • UIProcess/WebPageProxy.cpp:

(WebKit::attachmentElementServices):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

11:19 PM Changeset in webkit [286589] by Said Abou-Hallawa
  • 56 edits in trunk

[GPU Process] [Filters] Make FilterEffect::externalRepresentation() and its overridable functions work iteratively
https://bugs.webkit.org/show_bug.cgi?id=233893

Reviewed by Cameron McCormack.

Source/WebCore:

This is a step towards removing the inputEffect() from FilterEffect.

-- The enum FliterEffect::RepresentationType is replaced by

FilterRepresentation.

-- CSSFilter calls its functions from left to right to dump their

externalRepresentation.

-- SVGFilter uses its expression to dump its graph of FilterEffects.

-- Since SourceAlpha is a built-in effect it does not need to dump

SourceGraphic as its input.

  • platform/graphics/filters/FEBlend.cpp:

(WebCore::FEBlend::externalRepresentation const):

  • platform/graphics/filters/FEBlend.h:
  • platform/graphics/filters/FEColorMatrix.cpp:

(WebCore::FEColorMatrix::externalRepresentation const):

  • platform/graphics/filters/FEColorMatrix.h:
  • platform/graphics/filters/FEComponentTransfer.cpp:

(WebCore::FEComponentTransfer::externalRepresentation const):

  • platform/graphics/filters/FEComponentTransfer.h:
  • platform/graphics/filters/FEComposite.cpp:

(WebCore::FEComposite::externalRepresentation const):

  • platform/graphics/filters/FEComposite.h:
  • platform/graphics/filters/FEConvolveMatrix.cpp:

(WebCore::FEConvolveMatrix::externalRepresentation const):

  • platform/graphics/filters/FEConvolveMatrix.h:
  • platform/graphics/filters/FEDiffuseLighting.cpp:

(WebCore::FEDiffuseLighting::externalRepresentation const):

  • platform/graphics/filters/FEDiffuseLighting.h:
  • platform/graphics/filters/FEDisplacementMap.cpp:

(WebCore::FEDisplacementMap::externalRepresentation const):

  • platform/graphics/filters/FEDisplacementMap.h:
  • platform/graphics/filters/FEDropShadow.cpp:

(WebCore::FEDropShadow::externalRepresentation const):

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

(WebCore::FEFlood::externalRepresentation const):

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

(WebCore::FEGaussianBlur::externalRepresentation const):

  • platform/graphics/filters/FEGaussianBlur.h:
  • platform/graphics/filters/FEMerge.cpp:

(WebCore::FEMerge::externalRepresentation const):

  • platform/graphics/filters/FEMerge.h:
  • platform/graphics/filters/FEMorphology.cpp:

(WebCore::FEMorphology::externalRepresentation const):

  • platform/graphics/filters/FEMorphology.h:
  • platform/graphics/filters/FEOffset.cpp:

(WebCore::FEOffset::externalRepresentation const):

  • platform/graphics/filters/FEOffset.h:
  • platform/graphics/filters/FESpecularLighting.cpp:

(WebCore::FESpecularLighting::externalRepresentation const):

  • platform/graphics/filters/FESpecularLighting.h:
  • platform/graphics/filters/FETile.cpp:

(WebCore::FETile::externalRepresentation const):

  • platform/graphics/filters/FETile.h:
  • platform/graphics/filters/FETurbulence.cpp:

(WebCore::FETurbulence::externalRepresentation const):

  • platform/graphics/filters/FETurbulence.h:
  • platform/graphics/filters/Filter.h:
  • platform/graphics/filters/FilterEffect.cpp:

(WebCore::FilterEffect::externalRepresentation const):
(WebCore::operator<<):

  • platform/graphics/filters/FilterEffect.h:
  • platform/graphics/filters/FilterFunction.h:
  • platform/graphics/filters/SourceAlpha.cpp:

(WebCore::SourceAlpha::externalRepresentation const):

  • platform/graphics/filters/SourceAlpha.h:
  • platform/graphics/filters/SourceGraphic.cpp:

(WebCore::SourceGraphic::externalRepresentation const):

  • platform/graphics/filters/SourceGraphic.h:
  • rendering/CSSFilter.cpp:

(WebCore::CSSFilter::externalRepresentation const):

  • rendering/CSSFilter.h:
  • rendering/svg/SVGRenderTreeAsText.cpp:

(WebCore::writeSVGResourceContainer):

  • svg/graphics/filters/SVGFEImage.cpp:

(WebCore::FEImage::externalRepresentation const):

  • svg/graphics/filters/SVGFEImage.h:
  • svg/graphics/filters/SVGFilter.cpp:

(WebCore::SVGFilter::externalRepresentation const):

  • svg/graphics/filters/SVGFilter.h:
  • svg/graphics/filters/SVGFilterBuilder.cpp:

(WebCore::effectGeometryFlagsForElement):
(WebCore::SVGFilterBuilder::buildFilterEffects):
(WebCore::SVGFilterBuilder::buildEffectExpression const):
(WebCore::SVGFilterBuilder::buildExpression const):
(WebCore::boundarySetFlagsForElement): Deleted.

  • svg/graphics/filters/SVGFilterBuilder.h:
  • svg/graphics/filters/SVGFilterExpression.h:

LayoutTests:

Add missing closing quotations in the expected results of some of the
filter layout tests.

  • svg/filters/feDropShadow-expected.txt:
  • svg/filters/feDropShadow-subregion-expected.txt:
  • svg/filters/feDropShadow-zero-deviation-expected.txt:
  • svg/repaint/filter-child-repaint-expected.txt:
10:20 PM Changeset in webkit [286588] by Patrick Angle
  • 7 edits in trunk/Source

[Cocoa] Web Inspector: Unify Grid overlay drawing code
https://bugs.webkit.org/show_bug.cgi?id=233773

Reviewed by Devin Rousso.

Source/WebCore:

Expose InspectorOverlay::drawGridOverlay as a static method so that it can be used for iOS overlay drawing and
clean up other related drawing methods to be private static instead of instance methods or public static methods.

  • inspector/InspectorOverlay.cpp:

(WebCore::drawLayoutHatching):
(WebCore::fontForLayoutLabel):
(WebCore::backgroundPathForLayoutLabel):
(WebCore::expectedSizeForLayoutLabel):
(WebCore::drawLayoutLabel):
(WebCore::InspectorOverlay::drawLayoutHatching): Deleted.
(WebCore::InspectorOverlay::fontForLayoutLabel): Deleted.
(WebCore::InspectorOverlay::backgroundPathForLayoutLabel): Deleted.
(WebCore::InspectorOverlay::drawLayoutLabel): Deleted.

  • inspector/InspectorOverlay.h:

Source/WebKit:

Remove the (almost) 1-to-1 duplicated logic currently being used to turn Grid Overlays into a layer hierarchy
and instead use a graphics context to draw the overlays straight into the view to take advantage of the existing
drawing code we use for macOS in WebCore::InspectorOverlay. To accommodate this, we now correctly set the
content scale factor of the view itself (so that our drawing does not appear blurry) and set the frame of the
view equal to the current visible portion of the parent scroll view, which helps us to avoid having an
incredibly large graphics context to draw into (which we would if the view's frame was just set to match the
frame of the webpage's view). This frame will not always be the same size, such as when zooming in where less of
the frame is visible. Combined with the current content scale, this actually means that on zoom the effective
number of pixels that need to be drawn is consistent.

  • UIProcess/Inspector/ios/WKInspectorHighlightView.h:
  • UIProcess/Inspector/ios/WKInspectorHighlightView.mm:

(-[WKInspectorHighlightView initWithFrame:]):

  • Explicitly set this view to be non-opaque so that page content can be seen below this view. This wasn't

previously necessary because the bounds of this view were a zero-rect, which meant the background was never
painted.

(-[WKInspectorHighlightView _removeAllLayers]):
(-[WKInspectorHighlightView _createLayers:]):

  • Because the view's frame origin is now offset, we need to create the node highlight layers offset by the

negation of the frame's origin so that they still line up correctly with page content.

(-[WKInspectorHighlightView drawRect:]):
(-[WKInspectorHighlightView update:scale:frame:]):
(-[WKInspectorHighlightView _createGridOverlayLayers:scale:]): Deleted.
(createLayoutHatchingLayer): Deleted.
(createLayoutLabelLayer): Deleted.
(-[WKInspectorHighlightView _createGridOverlayLayer:scale:]): Deleted.
(-[WKInspectorHighlightView update:scale:]): Deleted.

  • UIProcess/ios/WKContentView.mm:

(-[WKContentView _showInspectorHighlight:]):

9:52 PM Changeset in webkit [286587] by fpizlo@apple.com
  • 8 edits in trunk/Source/bmalloc

[libpas] Clean up what the machine code looks like under LTO
https://bugs.webkit.org/show_bug.cgi?id=233909

Reviewed by Yusuke Suzuki.

During the very painful perf burndown of libpas that got it to be a progression (rather than a
regression) versus bmalloc, I found that certain key fast paths - like fastMalloc and fastFree - perform
better when they do not have a stack frame. For this to happen, they must only make tail calls.

Sadly, LTO was inlining a slow path into fastFree (i.e. pas_deallocate), and this slow path had an
assertion, and the call to pas_assertion_failed was not a tail call.

This fixes the problem comprehensively:

  • We now compile pas_assertion_failed as a breakpoint, just like WebKit would do. This is better for code size and maybe it could sometimes be better for performance.
  • The slow path that was getting inlined is now marked PAS_NEVER_INLINE.
  • Inspecting the machine code, I found a couple other slow paths that were being inlined in a bunch of places, and also marked them NEVER_INLINE.

If my past experiences are right, this could be a tiny speed-up on malloc-heavy workloads.

  • libpas/src/libpas/pas_lock.c:

(pas_lock_lock_slow):

  • libpas/src/libpas/pas_lock.h:
  • libpas/src/libpas/pas_monotonic_time.c:

(get_timebase_info_slow):
(get_timebase_info):

  • libpas/src/libpas/pas_thread_local_cache.c:

(pas_thread_local_cache_append_deallocation_slow):

  • libpas/src/libpas/pas_thread_local_cache.h:
  • libpas/src/libpas/pas_utils.c:
  • libpas/src/libpas/pas_utils.h:

(pas_assertion_failed):
(pas_assertion_failed_noreturn_silencer):

8:12 PM Changeset in webkit [286586] by Lauro Moura
  • 3 edits in trunk/LayoutTests

[GLIB] Small gardening

Unreviewed test gardening.

  • platform/glib/TestExpectations:
  • platform/wpe/TestExpectations:
7:40 PM Changeset in webkit [286585] by Lauro Moura
  • 3 edits in trunk/Source/WebKit

REGRESSION(r286535) [GTK] Fix clean builds after DerivedSources/WebKit2 move
https://bugs.webkit.org/show_bug.cgi?id=233881

Reviewed by Don Olmstead.

Build fix. Covered by existing tests

The previous approach of this patch created the links to the header
derived sources into the target webkit2/ folder, which in turn was a
link to <repo>/Source/WebKit/UIProcess/API/gtk. So it ended up
actually creating the links inside the Source directory.

This commit instead links a different webkit2/ folder from the
generated webkit folder for the WebKitGTK/WPE derived sources headers.

  • PlatformGTK.cmake:
  • PlatformWPE.cmake:
5:57 PM Changeset in webkit [286584] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GTK][WPE] Mathml asserts with invisible operators
https://bugs.webkit.org/show_bug.cgi?id=215217

Unreviewed test gardening.

Remove test failures from expectations as the assert was removed.

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-12-06

  • platform/glib/TestExpectations:
5:52 PM Changeset in webkit [286583] by commit-queue@webkit.org
  • 5 edits in trunk/LayoutTests

[GLIB] Update test expectations and baselines. Unreviewed test gardening.
https://bugs.webkit.org/show_bug.cgi?id=233898

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-12-06

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-valid-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-valueMissing-expected.txt:
5:19 PM Changeset in webkit [286582] by wilander@apple.com
  • 2 edits in trunk/Tools

Add WebCore::RegistrableDomain tests for duplicate sub domains
https://bugs.webkit.org/show_bug.cgi?id=233902
<rdar://problem/86130326>

Unreviewed expansion of the RegistrableDomain.MatchesURLs API test.

https://bugs.webkit.org/show_bug.cgi?id=233330 claims that duplicate sub domains
such as news.news.example.com causes WebKit's RegistrableDomain matching to fail
and treat same-site content as cross-site. This patch add tests of such duplicate
sub domains.

  • TestWebKitAPI/Tests/WebCore/RegistrableDomain.cpp:

(TestWebKitAPI::TEST):

5:15 PM Changeset in webkit [286581] by Chris Dumez
  • 12 edits in trunk

<input type="time">'s range should be reversible
https://bugs.webkit.org/show_bug.cgi?id=233835

Reviewed by Darin Adler.

Source/WebCore:

<input type="time">'s range should be reversible when checking for overflow / underflow:

No new tests, rebaselined existing tests.

  • html/InputType.cpp:

(WebCore::InputType::rangeUnderflow const):
(WebCore::InputType::rangeOverflow const):

  • html/StepRange.cpp:

(WebCore::StepRange::StepRange):

  • html/StepRange.h:

(WebCore::StepRange::isReversible const):

  • html/TimeInputType.cpp:

(WebCore::TimeInputType::createStepRange const):

LayoutTests:

Rebaseline WPT tests that are now passing.

  • platform/mac-wk2/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-rangeOverflow-expected.txt:
  • platform/mac-wk2/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-rangeUnderflow-expected.txt:
5:13 PM Changeset in webkit [286580] by keith_miller@apple.com
  • 6 edits in trunk/Source/JavaScriptCore

TypeInfo should be materializable from Structures as a single load.
https://bugs.webkit.org/show_bug.cgi?id=233875

Reviewed by Mark Lam.

This is mostly just the members of Structure and JSCell so that
JSType and InlineTypeFlags are at the end of the JSCell header.

  • assembler/testmasm.cpp:

(JSC::testBranchIfType):
(JSC::testBranchIfNotType):

  • ftl/FTLAbstractHeapRepository.cpp:

(JSC::FTL::AbstractHeapRepository::AbstractHeapRepository):

  • runtime/JSCell.h:
  • runtime/JSCellInlines.h:

(JSC::JSCell::JSCell):

  • runtime/Structure.h:

(JSC::Structure::typeInfo const):

4:38 PM Changeset in webkit [286579] by beidson@apple.com
  • 10 edits in trunk

webpushd/webpushtool debugging additions
https://bugs.webkit.org/show_bug.cgi?id=233864

Reviewed by Alex Christensen.

Source/WebKit:

Covered by API tests.

This patch:

  • Teaches webpushtool the ability to wait for a reconnect after losing its connection
  • Starts actually broadcasting meaningful debug messages from webpushd
  • webpushd/AppBundleRequest.mm:

(WebPushD::AppBundleRequest::start):
(WebPushD::AppBundlePermissionsRequest::didCheckForExistingBundle):
(WebPushD::AppBundlePermissionsRequest::didCreateAppBundle):
(WebPushD::AppBundleDeletionRequest::didDeleteExistingBundleWithError):

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

(WebPushD::ClientConnection::setDebugModeIsEnabled):
(WebPushD::ClientConnection::broadcastDebugMessage):
(WebPushD::ClientConnection::connectionClosed):

  • webpushd/WebPushDaemon.mm:

(WebPushD::Daemon::connectionAdded):

  • webpushd/webpushtool/WebPushToolConnection.h:
  • webpushd/webpushtool/WebPushToolConnection.mm:

(WebPushTool::Connection::create):
(WebPushTool::Connection::Connection):
(WebPushTool::Connection::connectToService):
(WebPushTool::Connection::connectionDropped):

  • webpushd/webpushtool/WebPushToolMain.mm:

(printUsageAndTerminate):
(main):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/WebPushDaemon.mm:

(TestWebKitAPI::TEST): Adapt to debug message changes.

4:36 PM Changeset in webkit [286578] by Said Abou-Hallawa
  • 14 edits
    1 add in trunk/Source/WebCore

[GPU Process] Make FilterEffect calculate the primitive subregion only when needed
https://bugs.webkit.org/show_bug.cgi?id=232705
rdar://85290142

Reviewed by Cameron McCormack.

In this patch:

  1. resultColorSpace() will return colorSpace() from a FilterImageVector instead of returning the resultColorSpace() of the FilterEffect.
  1. Filter::clampFilterRegionIfNeeded() will clamp the filterRegion() instead of clamping the maxEffectRect of the lastEffect() since all the primitiveSubregions and the imageRects have to clipped to the filterRegion().
  1. determineFilterPrimitiveSubregion() is replaced by calculatePrimitiveSubregion() which will calculate the primitiveSubregion from a FilterImageVector and an optional FilterEffectGeometry.
  1. Many of FilterEffects are made protected instead of having them public.
  1. SVGFilterExpression will be defined as a Vector of SVGFilterExpressionTerm which is a struct of FilterEffect and optional FilterEffectGeometry.
  1. SVGFilter will replace the members whose types are FilterEffectVector and FilterEffectGeometryMap with a single member of type SVGFilterExpression.
  • Headers.cmake:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/filters/FEDisplacementMap.cpp:

(WebCore::FEDisplacementMap::resultColorSpace const):

  • platform/graphics/filters/FEDisplacementMap.h:
  • platform/graphics/filters/Filter.cpp:

(WebCore::Filter::clampFilterRegionIfNeeded):

  • platform/graphics/filters/Filter.h:

(WebCore::Filter::effectGeometry const): Deleted.

  • platform/graphics/filters/FilterEffect.cpp:

(WebCore::FilterEffect::calculatePrimitiveSubregion const):
(WebCore::FilterEffect::apply):
(WebCore::FilterEffect::externalRepresentation const):
(WebCore::FilterEffect::determineFilterPrimitiveSubregion): Deleted.

  • platform/graphics/filters/FilterEffect.h:

(WebCore::FilterEffect::resultColorSpace const):
(WebCore::FilterEffect::filterPrimitiveSubregion const): Deleted.
(WebCore::FilterEffect::setFilterPrimitiveSubregion): Deleted.

  • platform/graphics/filters/FilterFunction.h:

(WebCore::FilterFunction::apply):

  • svg/graphics/filters/SVGFilter.cpp:

(WebCore::SVGFilter::create):
(WebCore::SVGFilter::supportsCoreImageRendering const):
(WebCore::SVGFilter::lastEffect const):
(WebCore::SVGFilter::apply):
(WebCore::SVGFilter::clearResult):
(WebCore::SVGFilter::effectGeometry const): Deleted.

  • svg/graphics/filters/SVGFilter.h:
  • svg/graphics/filters/SVGFilterBuilder.cpp:

(WebCore::SVGFilterBuilder::effectGeometry const):
(WebCore::SVGFilterBuilder::buildEffectExpression const):
(WebCore::SVGFilterBuilder::buildExpression const):
(WebCore::buildEffectExpression): Deleted.

  • svg/graphics/filters/SVGFilterBuilder.h:

(WebCore::SVGFilterBuilder::takeEffectGeometryMap): Deleted.

  • svg/graphics/filters/SVGFilterExpression.h: Added.
4:36 PM Changeset in webkit [286577] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

[ iOS ] imported/w3c/web-platform-tests/content-security-policy/worker-src/service-* tests are consistently failing
https://bugs.webkit.org/show_bug.cgi?id=229875

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations: Add DumpJSConsoleLogInStdErr to address consistent failures.
4:18 PM Changeset in webkit [286576] by Jonathan Bedard
  • 8 edits
    6 copies
    9 adds in trunk/Tools

[reporelaypy] Add implementation of commits.webkit.org
https://bugs.webkit.org/show_bug.cgi?id=233734
<rdar://problem/85945101>

Reviewed by Dewei Zhu.

As commits.webkit.org becomes more important to WebKit development, we need to apply
our normal robust testing and review to the code backing it.

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/init.py: Add entrypoint to library.
  • Tools/Scripts/libraries/reporelaypy/reporelaypy/checkout.py: Added.

(Checkout): Abstraction managing local repository checkout.

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/checkoutroute.py: Added.

(Redirector): Generates redirects for certain SCM services.
(CheckoutRoute): http routes returning information based on a checkout.

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/database.py: Added.

(Database): A connection to a true Redis or TinyRedis database.

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/tests/checkout_unittest.py:

(CheckoutUnittest):

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/tests/checkoutroute_unittest.py: Added.

(RedirectorUnittest):
(CheckoutRouteUnittest):

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/tests/database_unittest.py: Added.

(DatabaseUnittest):

  • Tools/Scripts/libraries/reporelaypy/reporelaypy/webserver.py: Copied from Tools/Scripts/libraries/webkitflaskpy/setup.py.

(health):

  • Tools/Scripts/libraries/reporelaypy/run: Added.
  • Tools/Scripts/libraries/reporelaypy/setup.py: Added.
  • Tools/Scripts/libraries/resultsdbpy/resultsdbpy/init.py: Bump version.
  • Tools/Scripts/libraries/resultsdbpy/resultsdbpy/flask_support/flask_testcase.py:

(FlaskTestCase.run_with_mock_webserver.decorator.real_method):
(FlaskRequestsResponse): Moved to webkitflaskpy.

  • Tools/Scripts/libraries/webkitflaskpy/setup.py: Bump version, update library description.
  • Tools/Scripts/libraries/webkitflaskpy/webkitflaskpy/init.py: Bump version.
  • Tools/Scripts/libraries/webkitflaskpy/webkitflaskpy/mock_app.py: Added.

(mock_app): Setup a flask app for testing.

  • Tools/Scripts/libraries/webkitflaskpy/webkitflaskpy/response.py: Added.

(Response): Move FlaskRequestsResponse to more generic location.

  • Tools/Scripts/webkitpy/init.py: Include reporelaypy for testing.
  • Tools/Scripts/webkitpy/test/main.py:

(main): Include reporelaypy for testing.
(Tester._run_tests): Ditto.

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

4:06 PM Changeset in webkit [286575] by Ryan Haddad
  • 4 edits in branches/safari-612-branch

Unreviewed, fix the debug build.

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

Regression(r286505) imported/w3c/web-platform-tests/html/cross-origin-opener-policy/javascript-url.https.html is a flaky crash
https://bugs.webkit.org/show_bug.cgi?id=233874

Reviewed by Darin Adler.

r286505 fixed ProvisionalPageProxy so that ProvisionalPageProxy::m_provisionalLoadURL gets properly initialized when the
ProvisionalPageProxy gets constructed *after* the provisional load has already started (COOP proces-swap case). One side
effect of this though is that ProvisionalPageProxy::cancel() no longer returns early and will try to notify the client
that the provisional load failed, dereferencing m_mainFrame in doing so. In the event where the main frame has not yet
been created in the new provisional process, this would do a null-dereference of m_mainFrame.

To address the issue, we now early return in ProvisionalPageProxy::cancel() if m_isProcessSwappingOnNavigationResponse
is true (i.e. The ProvisionalPageProxy was created after the provisional load had started). In such situations, we
don't want to ProvisionalPageProxy to be the one notifying the client of the provisional load failure anyway. The reason
is that there is still a provisional load going on in the committed process/page.

No new tests, covered by existing test that is flakily crashing.

  • UIProcess/ProvisionalPageProxy.cpp:

(WebKit::ProvisionalPageProxy::cancel):

2:53 PM Changeset in webkit [286573] by ysuzuki@apple.com
  • 8 edits in trunk/Source/bmalloc

[libpas] Set pthread_setspecific with marker in TLS destructor to detect TLS is destroyed
https://bugs.webkit.org/show_bug.cgi?id=233851

Reviewed by Mark Lam.

TLS has lifetime problem that,

  1. TLS is destroyed
  2. The other TLS is destroyed, and the destructor is called
  3. The destructor touches (1)'s TLS, then revive TLS of (1) (e.g. libpas's thread local cache).

To handle these cases, pthread library (libc) repeatedly calls destructor PAS_THREAD_LOCAL_CACHE_DESTROYED times
so that we clean up revived TLS again.

By using this mechanism, we can emulate pthread_self_is_exiting_np so that we can avoid reviving TLS.

  1. When destroying TLS, we set a marker (PAS_THREAD_LOCAL_CACHE_DESTROYED in this case) in TLS.
  2. During the other destructor calls, we can detect that TLS is destroyed by checking pthread_getspecific(...) == PAS_THREAD_LOCAL_CACHE_DESTROYED.
  3. We repeatedly calls the destructor of TLS, but every time, we set PAS_THREAD_LOCAL_CACHE_DESTROYED. So after PAS_THREAD_LOCAL_CACHE_DESTROYED times, it is left, and we achieve the goal (1) offering the way to detect the destroyed TLS and (2) avoiding reviving of TLS.

This patch implements it when pthread_self_is_exiting_np does not exist.

  • libpas/src/libpas/pas_segregated_page_inlines.h:

(pas_segregated_page_switch_lock_with_mode):

  • libpas/src/libpas/pas_thread_local_cache.c:

(destructor):
(pas_thread_local_cache_create):
(pas_thread_local_cache_destroy):
(pas_thread_local_cache_get_local_allocator_slow):
(pas_thread_local_cache_for_all):

  • libpas/src/libpas/pas_thread_local_cache.h:

(pas_thread_local_cache_try_get_impl):
(pas_thread_local_cache_try_get):
(pas_thread_local_cache_can_set):
(pas_thread_local_cache_set_impl):
(pas_thread_local_cache_set):
(pas_thread_local_cache_is_guaranteed_to_destruct): Deleted.

  • libpas/src/libpas/pas_try_reallocate.h:

(pas_try_reallocate):

  • libpas/src/libpas/pas_utils.h:
  • libpas/src/test/IsoHeapPageSharingTests.cpp:

(std::addAllTests):

  • libpas/src/test/IsoHeapPartialAndBaselineTests.cpp:

(addIsoHeapPartialAndBaselineTests):

2:50 PM Changeset in webkit [286572] by mark.lam@apple.com
  • 25 edits in trunk/Source/JavaScriptCore

Remove unneeded virtual allocator methods from Subspace.
https://bugs.webkit.org/show_bug.cgi?id=233891
rdar://86117970

Reviewed by Yusuke Suzuki.

Since the virtual allocate() and allocateFor() methods are now deleted, we can
also rename the inline allocateNonVirtual() and allocatorForNonVirtual() methods
to simply allocate() and allocateFor(). Similarly, rename
allocatorForNonVirtualConcurrently() to allocatorForConcurrently().

There are 2 places that still invokes the non-inline version of
CompleteSubspace::allocatorFor(). For this reason, we introduce a
CompleteSubsace::allocatorForNonInline() to keep the linkage the same. There's a
chance that the compiler/linker may already inline the method in 1 or both of
these places, but we'll offer allocatorForNonInline() to keep the code expressing
the same thing and let the compiler/linker decide whether to inline it or not just
as before.

This is purely a re-factoring patch. There are no behavior changes, except for
the removal of those 2 entries from the vtbls.

  • bytecode/AccessCase.cpp:

(JSC::AccessCase::generateImpl):

  • bytecode/ObjectAllocationProfileInlines.h:

(JSC::ObjectAllocationProfileBase<Derived>::initializeProfile):

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::emitAllocateRawObject):

  • ftl/FTLLowerDFGToB3.cpp:

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

  • heap/CompleteSubspace.cpp:

(JSC::CompleteSubspace::allocatorForNonInline):
(JSC::CompleteSubspace::tryAllocateSlow):
(JSC::CompleteSubspace::allocatorFor): Deleted.
(JSC::CompleteSubspace::allocate): Deleted.

  • heap/CompleteSubspace.h:

(JSC::CompleteSubspace::allocatorFor):
(JSC::CompleteSubspace::allocatorForNonVirtual): Deleted.

  • heap/CompleteSubspaceInlines.h:

(JSC::CompleteSubspace::allocate):
(JSC::CompleteSubspace::allocateNonVirtual): Deleted.

  • heap/IsoSubspace.cpp:

(JSC::IsoSubspace::allocatorFor): Deleted.
(JSC::IsoSubspace::allocate): Deleted.

  • heap/IsoSubspace.h:

(JSC::IsoSubspace::allocatorFor):
(JSC::IsoSubspace::allocatorForNonVirtual): Deleted.

  • heap/IsoSubspaceInlines.h:

(JSC::IsoSubspace::allocate):
(JSC::IsoSubspace::allocateNonVirtual): Deleted.

  • heap/Subspace.h:
  • jit/AssemblyHelpers.h:

(JSC::AssemblyHelpers::emitAllocateJSObjectWithKnownSize):

  • runtime/ButterflyInlines.h:

(JSC::Butterfly::tryCreateUninitialized):
(JSC::Butterfly::createUninitialized):
(JSC::Butterfly::tryCreate):
(JSC::Butterfly::growArrayRight):
(JSC::Butterfly::reallocArrayRightIfPossible):

  • runtime/DirectArguments.cpp:

(JSC::DirectArguments::overrideThings):

  • runtime/GenericArgumentsInlines.h:

(JSC::GenericArguments<Type>::initModifiedArgumentsDescriptor):

  • runtime/HashMapImpl.h:

(JSC::HashMapBuffer::create):

  • runtime/JSArray.cpp:

(JSC::JSArray::tryCreateUninitializedRestricted):

  • runtime/JSArray.h:

(JSC::JSArray::tryCreate):

  • runtime/JSArrayBufferView.cpp:

(JSC::JSArrayBufferView::ConstructionContext::ConstructionContext):

  • runtime/JSBigInt.cpp:

(JSC::JSBigInt::createWithLength):

  • runtime/JSCellInlines.h:

(JSC::allocatorForConcurrently):
(JSC::tryAllocateCellHelper):
(JSC::allocatorForNonVirtualConcurrently): Deleted.

  • runtime/JSPropertyNameEnumerator.cpp:

(JSC::JSPropertyNameEnumerator::create):

  • runtime/ScopedArguments.cpp:

(JSC::ScopedArguments::createUninitialized):

  • runtime/StructureChain.cpp:

(JSC::StructureChain::create):

2:24 PM Changeset in webkit [286571] by Adrian Perez de Castro
  • 1 copy in releases/WPE WebKit/webkit-2.34.2

WPE WebKit 2.34.2

2:23 PM Changeset in webkit [286570] by Adrian Perez de Castro
  • 4 edits in releases/WebKitGTK/webkit-2.34

Unreviewed. Update OptionsWPE.cmake and NEWS for the 2.34.2 release

.:

  • Source/cmake/OptionsWPE.cmake: Bump version numbers.

Source/WebKit:

  • wpe/NEWS: Add release notes for 2.34.2.
2:17 PM Changeset in webkit [286569] by Ryan Haddad
  • 29 edits
    1 delete in trunk

REGRESSION (r286507): [macOS] Many file system access layout tests became flaky failures
https://bugs.webkit.org/show_bug.cgi?id=233892

Unreviewed, revert r286507.

Source/WebCore:

  • Modules/filesystemaccess/FileSystemStorageConnection.h:

Source/WebKit:

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::monitoredDataTypes):

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::fetchWebsiteData):
(WebKit::NetworkProcess::deleteWebsiteData):
(WebKit::NetworkProcess::deleteWebsiteDataForOrigins):
(WebKit::NetworkProcess::deleteAndRestrictWebsiteDataForRegistrableDomains):
(WebKit::NetworkProcess::registrableDomainsWithWebsiteData):

  • NetworkProcess/storage/FileSystemStorageHandle.h:

(WebKit::FileSystemStorageHandle::activeSyncAccessHandle const): Deleted.

  • NetworkProcess/storage/FileSystemStorageManager.cpp:

(WebKit::FileSystemStorageManager::~FileSystemStorageManager):
(WebKit::FileSystemStorageManager::close): Deleted.

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

(WebKit::originPath):
(WebKit::NetworkStorageManager::localOriginStorageManager):
(WebKit::readOriginFromFile): Deleted.
(WebKit::writeOriginToFileIfNecessary): Deleted.
(WebKit::deleteOriginFileIfNecessary): Deleted.
(WebKit::originDirectoryPath): Deleted.
(WebKit::originFilePath): Deleted.
(WebKit::NetworkStorageManager::removeOriginStorageManagerIfPossible): Deleted.
(WebKit::toWebsiteDataType): Deleted.
(WebKit::NetworkStorageManager::forEachOriginDirectory): Deleted.
(WebKit::NetworkStorageManager::fetchDataFromDisk): Deleted.
(WebKit::NetworkStorageManager::fetchData): Deleted.
(WebKit::NetworkStorageManager::deleteDataOnDisk): Deleted.
(WebKit::NetworkStorageManager::deleteData): Deleted.
(WebKit::NetworkStorageManager::deleteDataModifiedSince): Deleted.
(WebKit::NetworkStorageManager::deleteDataForRegistrableDomains): Deleted.

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

(WebKit::OriginStorageManager::StorageBucket::typeStoragePath const):
(WebKit::OriginStorageManager::StorageBucket::fileSystemStorageManager):
(WebKit::OriginStorageManager::OriginStorageManager):
(WebKit::OriginStorageManager::StorageBucket::toStorageIdentifier): Deleted.
(WebKit::OriginStorageManager::StorageBucket::isActive): Deleted.
(WebKit::OriginStorageManager::StorageBucket::deleteData): Deleted.
(WebKit::OriginStorageManager::StorageBucket::deleteFileSystemStorageData): Deleted.
(WebKit::OriginStorageManager::isActive): Deleted.
(WebKit::OriginStorageManager::deleteData): Deleted.

  • NetworkProcess/storage/OriginStorageManager.h:
  • Shared/WebsiteData/WebsiteData.cpp:

(WebKit::WebsiteData::ownerProcess):

  • Shared/WebsiteData/WebsiteDataType.h:
  • UIProcess/API/Cocoa/WKWebsiteDataRecord.mm:

(dataTypesToString):

  • UIProcess/API/Cocoa/WKWebsiteDataRecordInternal.h:

(WebKit::toWebsiteDataType):
(WebKit::toWKWebsiteDataTypes):

  • UIProcess/API/Cocoa/WKWebsiteDataRecordPrivate.h:
  • UIProcess/API/Cocoa/WKWebsiteDataStore.mm:

(+[WKWebsiteDataStore _allWebsiteDataTypesIncludingPrivate]):

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/Network/NetworkProcessConnection.cpp:

(WebKit::NetworkProcessConnection::didReceiveMessage):

  • WebProcess/WebCoreSupport/WebFileSystemStorageConnection.messages.in: Removed.

Source/WTF:

  • wtf/FileSystem.cpp:

(WTF::FileSystemImpl::readEntireFile): Deleted.
(WTF::FileSystemImpl::deleteAllFilesModifiedSince): Deleted.

  • wtf/FileSystem.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/FileSystemAccess.mm:
1:58 PM Changeset in webkit [286568] by weinig@apple.com
  • 10 edits
    1 add in trunk

[CSS Color 5] Update color-mix() to support srgb-linear and alpha premultiplication
https://bugs.webkit.org/show_bug.cgi?id=233862

Reviewed by Cameron McCormack.

Source/WebCore:

  • Updates color-mix() to support srgb-linear interpolation.
  • Updates color-mix() to interpolate using alpha premultiplied colors.
  • Moves interpolation normalization to ColorInterpolation.h so that it can be shared in the future. Adds AlphaPremulitplied parameter to ColorInterpolationMethod to allow specifying the behavior desired. Also adds encoding/decoding of ColorInterpolationMethod which will be needed shortly.
  • Headers.cmake:
  • WebCore.xcodeproj/project.pbxproj:

Add new files.

  • css/CSSValueKeywords.in:

Add reference (commented out, since it is also defined above) for srgb-linear in the color-mix section.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::consumeColorInterpolationMethod):
Add support for parsing srgb-linear as a color-interpolation-method color space.

(WebCore::CSSPropertyParserHelpers::makeCanonicalColor):
(WebCore::CSSPropertyParserHelpers::makeCanonicalColor<HWBA<float>>):
(WebCore::CSSPropertyParserHelpers::makeCanonicalColor<HSLA<float>>):
With much of makeColorTypeByNormalizingComponentsAfterMix moving to ColorNormalization,
the CSS specific parts are still needed here, which just convert HWBA and HSLA colors
to SRGBA<uint8_t> to match parsing.

(WebCore::CSSPropertyParserHelpers::mixColorComponentsUsingColorInterpolationMethod):
Utilize new interpolateColorComponents<> function to do the interpolation.

(WebCore::CSSPropertyParserHelpers::normalizeHue): Deleted.
(WebCore::CSSPropertyParserHelpers::normalizeWhitenessBlackness): Deleted.
(WebCore::CSSPropertyParserHelpers::makeColorTypeByNormalizingComponentsAfterMix): Deleted.
(WebCore::CSSPropertyParserHelpers::makeColorTypeByNormalizingComponentsAfterMix<HWBA<float>>): Deleted.
(WebCore::CSSPropertyParserHelpers::makeColorTypeByNormalizingComponentsAfterMix<HSLA<float>>): Deleted.
(WebCore::CSSPropertyParserHelpers::makeColorTypeByNormalizingComponentsAfterMix<LCHA<float>>): Deleted.
(WebCore::CSSPropertyParserHelpers::makeColorTypeByNormalizingComponentsAfterMix<OKLCHA<float>>): Deleted.
Moved to ColorNormalization.h

  • platform/graphics/ColorInterpolation.h:

(WebCore::preInterpolationNormalizationForComponent):
(WebCore::preInterpolationNormalization):
(WebCore::postInterpolationNormalizationForComponent):
(WebCore::postInterpolationNormalization):
(WebCore::interpolateColorComponents):
Move complete interpolation here from CSSPropertyParserHelpers and add support for optionally
interpolating using alpha premultiplied colors.

(WebCore::ColorInterpolationMethod::encode const):
(WebCore::ColorInterpolationMethod::decode):
Add encode/decode for ColorInterpolationMethod so it can be used over IPC. Not currently needed
but will be needed soon for use with Gradient.

  • platform/graphics/ColorModels.h:

Add coordinateSystem constexpr property to each model. Used mostly to identify which color models have
special behavior due to a hue component.

  • platform/graphics/ColorNormalization.h: Added.

(WebCore::normalizeWhitenessBlackness):
(WebCore::normalizeHue):
(WebCore::makeColorTypeByNormalizingComponents):
(WebCore::makeColorTypeByNormalizingComponents<HWBA<float>>):
(WebCore::makeColorTypeByNormalizingComponents<HSLA<float>>):
(WebCore::makeColorTypeByNormalizingComponents<LCHA<float>>):
(WebCore::makeColorTypeByNormalizingComponents<OKLCHA<float>>):
Split out of CSSPropertyParserHelpers so it can be used by the interpolation code.

LayoutTests:

Update test and results to also test the srgb-linear color space and also to
specifically test colors with and without alpha, updating the results for the
new premuliplied results.

  • fast/css/parsing-color-mix-expected.txt:
  • fast/css/parsing-color-mix.html:
1:36 PM Changeset in webkit [286567] by mark.lam@apple.com
  • 2 edits in trunk/Source/WebKit

Reverting local test code that should not have been landed.

Not reviewed.

  • UIProcess/Cocoa/ModelElementControllerCocoa.mm:
1:31 PM Changeset in webkit [286566] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

Momentum Event Dispatcher: Momentum phase runs backwards with natural scrolling disabled
https://bugs.webkit.org/show_bug.cgi?id=233894
<rdar://problem/86111948>

Reviewed by Simon Fraser.

  • WebProcess/WebPage/MomentumEventDispatcher.cpp:

(WebKit::MomentumEventDispatcher::consumeDeltaForCurrentTime):
Only flip the deltas if the trackpad is configured to use "natural"
scrolling (in which "directionInvertedFromDevice" is true).

(WebKit::MomentumEventDispatcher::computeNextDelta):
Fix initial queue state logging to log both axes before setting the "did log" bit.

1:15 PM Changeset in webkit [286565] by Simon Fraser
  • 4 edits in trunk/Source

Add a call to os_signpost to tag a momentum scroll animation
https://bugs.webkit.org/show_bug.cgi?id=233885

Reviewed by Tim Horton.

Source/WebCore:

Use the momentum "Began" and "Ended" events to mark the start/end of a momentum scroll
as an animation via os_signost.

Put the code in ScrollingEffectsController rather than MomentumEventDispatcher so that
non-generated momentum gets marked too.

  • platform/mac/ScrollingEffectsController.mm:

(WebCore::ScrollingEffectsController::handleWheelEvent):

Source/WTF:

  • wtf/SystemTracing.h:
1:06 PM Changeset in webkit [286564] by beidson@apple.com
  • 6 edits
    2 copies in trunk/Source/WebKit

Put webpushd code in WebKit.framework.
https://bugs.webkit.org/show_bug.cgi?id=233886

Reviewed by Alex Christensen.

This fixes some build/mastering/linking issues.

  • Configurations/webpushd.xcconfig:
  • Shared/API/Cocoa/WKMain.h:
  • Shared/API/Cocoa/WKMain.mm:

(WKWebPushDaemonMain):

  • WebKit.xcodeproj/project.pbxproj:
  • webpushd/WebPushDaemonMain.h: Copied from Source/WebKit/Shared/API/Cocoa/WKMain.mm.
  • webpushd/WebPushDaemonMain.mm:

(WebKit::WebPushDaemonMain):
(main): Deleted.

  • webpushd/webpushd.cpp: Copied from Source/WebKit/Shared/API/Cocoa/WKMain.mm.

(main):

1:03 PM Changeset in webkit [286563] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

REGRESSION (r286527): Three API tests crashing under WebKit::ProcessLauncher::launchProcess()
https://bugs.webkit.org/show_bug.cgi?id=233882
<rdar://problem/86111726>

Reviewed by Brent Fulgham.

Correct the eventHandler to capture the process name, rather than using a raw pointer to the character string.

  • UIProcess/Launcher/cocoa/ProcessLauncherCocoa.mm:

(WebKit::ProcessLauncher::launchProcess):

1:01 PM Changeset in webkit [286562] by commit-queue@webkit.org
  • 2 edits in trunk/PerformanceTests

[RAMification] Add support for dumping smaps rollups on Linux
https://bugs.webkit.org/show_bug.cgi?id=233867

Patch by Zan Dobersek <zdobersek@igalia.com> on 2021-12-06
Reviewed by Yusuke Suzuki.

Add the option to dump smaps rollup after the end of each RAMification
test case. This mirrors the vmmap functionality and is implemented
alongside that option.

Once the jsc binary is left idle after the test case run, the
smaps_rollup output for the given jsc process is collected from the
proc filesystem. This material is then printed out after the test
is done, following the memory footprint dump.

For now this prefers the smaps_rollup instead of the complete smaps.
In this form, it already gives a good insight into the balance between
the proportional and residential set size amounts. Complete smaps could
be beneficial later, especially if we can implement differentiation
between allocations of different types and/or purposes.

  • JetStream2/RAMification.py:

(parseArgs):
(BaseRunner.init):
(BaseRunner.getResults):
(LocalRunner.runOneTest):
(main):
(main.runTestList):

12:52 PM Changeset in webkit [286561] by Russell Epstein
  • 1 copy in branches/safari-613.1.11-branch

New branch.

12:04 PM Changeset in webkit [286560] by Devin Rousso
  • 22 edits in trunk/Source

Change IDL Date to be backed by WallTime to avoid confusion when converting to native dates
https://bugs.webkit.org/show_bug.cgi?id=233781

Reviewed by Darin Adler.

JS Date is milliseconds-based, but some native dates (e.g. NSDate) are seconds-based.
WallTime will help avoid confusion since not a generic type (e.g. double) and instead
has explicitly defined conversion methods to seconds, milliseconds, etc..

Source/WebCore:

  • bindings/IDLTypes.h:

(WebCore::IDLDate::nullValue):
(WebCore::IDLDate::isNullValue):
(WebCore::IDLDate::extractValueFromNullable):

  • bindings/js/JSDOMConvertDate.h:

(WebCore::Converter<IDLDate>::convert):
(WebCore::JSConverter<IDLDate>::convert):

  • bindings/js/JSDOMConvertDate.cpp:

(WebCore::jsDate):
(WebCore::valueToDate):

  • Modules/applepay/ApplePayLineItem.h:

(WebCore::ApplePayLineItem::decode):

  • Modules/applepay/cocoa/PaymentSummaryItemsCocoa.mm:

(WebCore::toDate):

  • bindings/js/IDBBindingUtilities.cpp:

(WebCore::get):
(WebCore::toJS):
(WebCore::createIDBKeyFromValue):

  • html/BaseDateAndTimeInputType.h:
  • html/DateTimeLocalInputType.cpp:

(WebCore::DateTimeLocalInputType::valueAsDate const):
(WebCore::DateTimeLocalInputType::setValueAsDate const):

  • html/BaseDateAndTimeInputType.cpp:

(WebCore::BaseDateAndTimeInputType::valueAsDate const):
(WebCore::BaseDateAndTimeInputType::setValueAsDate const):

  • html/DateTimeLocalInputType.h:
  • html/HTMLInputElement.h:
  • html/HTMLInputElement.cpp:

(WebCore::HTMLInputElement::valueAsDate const):
(WebCore::HTMLInputElement::setValueAsDate):

  • html/InputType.h:
  • html/InputType.cpp:

(WebCore::InputType::valueAsDate const):
(WebCore::InputType::setValueAsDate const):

  • html/MonthInputType.h:
  • html/MonthInputType.cpp:

(WebCore::MonthInputType::valueAsDate const):

  • html/HTMLMediaElement.h:
  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::getStartDate const):
This also fixes an apparently longstanding bug in that MediaTime::toDouble is apparently a
seconds-based value, so this is the one case that doesn't need Seconds::fromMilliseconds.

Source/WebKitLegacy/mac:

  • DOM/DOMInternal.h:

(kit):
(core):

  • DOM/DOMHTMLMediaElement.mm:

(-[DOMHTMLMediaElement getStartDate]):

12:02 PM Changeset in webkit [286559] by Russell Epstein
  • 9 edits in branches/safari-613.1.10-branch/Source

Versioning.

WebKit-7613.1.10.2

11:45 AM Changeset in webkit [286558] by Patrick Angle
  • 17 edits
    3 adds in trunk

Web Inspector: Support Cascade Layers in the Styles sidebar
https://bugs.webkit.org/show_bug.cgi?id=233208

Reviewed by Devin Rousso.

Source/JavaScriptCore:

Add new values to CSS.Grouping's type enum for cascade layers and make the text optional since an
anonymous layer will not have a name or other text.

  • inspector/protocol/CSS.json:

Source/WebCore:

Test: inspector/css/getMatchedStylesForNodeLayerGrouping.html

Add support for parsing and grouping CSS @layer rules in InspectorStyleSheet to the existing paths for
handling other groupings so that the frontend is made aware of rules wrapped inside a layer or multiple layers.

  • Headers.cmake:
  • WebCore.xcodeproj/project.pbxproj:
  • CompiledSelector.h needs to be exported as a private header to include in WebKitLegacy's build, since it is

imported by StyleRule.h, which is now imported by CSSImportRule.h, which is imported in WebKitLegacy.

  • css/CSSImportRule.cpp:

(WebCore::CSSImportRule::cascadeLayerName const):

  • css/CSSImportRule.h:
  • css/CSSLayerRule.cpp:

(WebCore::CSSLayerRule::cssText const):
(WebCore::CSSLayerRule::layerName const):
(WebCore::CSSLayerRule::stringFromCascadeLayerName):

  • css/CSSLayerRule.h:
  • inspector/InspectorStyleSheet.cpp:

(flattenSourceData):
(WebCore::asCSSRuleList):
(WebCore::buildArrayForGroupings):

  • style/InspectorCSSOMWrappers.cpp:

(WebCore::Style::InspectorCSSOMWrappers::collect):

Source/WebInspectorUI:

  • UserInterface/Models/CSSGrouping.js:

(WI.CSSGrouping):
(WI.CSSGrouping.prototype.get isLayer):
(WI.CSSGrouping.prototype.get prefix):

  • Update CSSGrouping to support @layer rules, and make text optional for a grouping, since anonymous layers

will not have a name.

  • UserInterface/Models/CSSStyleDeclaration.js:

(WI.CSSStyleDeclaration.prototype.generateFormattedText):

  • Ensure that spacing remains correct and "null" isn't shown for groupings without text.
  • UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:

(WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):

  • When merging layer groups, ensure that a "." is used as a separator, and that each group has a name (to

prevent having a hanging period or the "null" text appearing).

LayoutTests:

Add new test cases for CSS.getMatchesStyleForNode to make sure that layer groupings are correctly determined,
and that rules nested in @layer rules and @import layer()s are correctly represented and sorted by the order
they are applied to an element.

  • inspector/css/getMatchedStylesForNode-expected.txt:
  • Re-baseline to account for change in order of CSSGrouping properties in the protocol due to text now being

optional.

  • inspector/css/getMatchedStylesForNodeLayerGrouping-expected.txt: Added.
  • inspector/css/getMatchedStylesForNodeLayerGrouping.html: Added.
  • inspector/css/resources/external-layers.css: Added.
11:45 AM Changeset in webkit [286557] by pvollan@apple.com
  • 3 edits in trunk/Source/WebKit

[iOS][WP] Block access to unused IOKit class
https://bugs.webkit.org/show_bug.cgi?id=233866
<rdar://problem/86086475>

Reviewed by Brent Fulgham.

Block access to IOKit class IOMobileFramebufferUserClient in the WebContent process' sandbox on iOS,
which is unused according to telemetry.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb.in:
  • UIProcess/WebPageProxy.cpp:

(WebKit::gpuIOKitClasses):

11:45 AM Changeset in webkit [286556] by Wenson Hsieh
  • 4 edits in trunk/Source/WebCore

Unreviewed, add some missing #includes in WebCore

Add several missing #include-s, which currently aren't causing any issues due to unified sources (but will
once I introduce several new source files in WebCore/Modules in a future patch).

  • Modules/web-locks/WebLockRegistry.cpp:
  • page/Page.cpp:
  • page/PageConfiguration.h:
11:30 AM Changeset in webkit [286555] by graouts@webkit.org
  • 17 edits
    6 copies
    6 adds in trunk

[Web Animations] Add a way to run scripted animations
https://bugs.webkit.org/show_bug.cgi?id=233869
rdar://85983542

Reviewed by Dean Jackson.

Source/WebCore:

Tests: webanimations/custom-effect/custom-effect.html

webanimations/custom-effect/document-timeline-animate.html

This patch adds two new Web-exposed features to allow authors to write callback-based animations
leveraging the full power of the Web Animations model.

First, we add a new AnimationEffect subclass which wraps a callback to be executed on every tick
of the associated animation's timeline: CustomEffect. It can be constructed by providing a JS function
as its first parameter, and either a number or a dictionary to provide timing properties for the effect.
This is similar to how KeyframeEffect will accept a keyframes object and then timing data. The callback
is provided the effect progress as its sole parameter. Web authors can use this new interface as follows:

const animation = new Animation;
animation.effect = new CustomEffect(progress => { … }, 1000);
animation.play();

Second, to make starting callback-based animations more straightforward and in a very similar fashion
to how keyframe animations can be initiated on an element using Element.animate(), we introduce a new
animate() method on DocumentTimeline, allowing the previous exmaple to be written as:

const animation = document.timeline.animate(progress => { … }, 1000);

This simple approach allows Web authors to move past the simple use of requestAnimationFrame() and harness
the Web Animations timing model which will let them pause and resume animations, seek them, control their
playback rate, apply easing, respond to the "finished" promise, etc.

The code itself is very simple, CustomEffect is simply an AnimationEffect subclass that indicates that it's
always interested in scheduling updates while active using the ticksContinouslyWhileActive() method. This
means that all the scheduling logic contained in WebAnimation and AnimationEffect applies, allowing callbacks
to not be fired when the animation is paused or when the page is suspended, or fired sparingly when a steps()
timing function is specified.

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Headers.cmake:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • animation/AnimationEffect.h:

(WebCore::AnimationEffect::isCustomEffect const):

  • animation/CustomAnimationOptions.h: Added.
  • animation/CustomAnimationOptions.idl: Added.
  • animation/CustomEffect.cpp: Added.

(WebCore::CustomEffect::create):
(WebCore::CustomEffect::CustomEffect):
(WebCore::CustomEffect::animationDidTick):

  • animation/CustomEffect.h: Added.

(WebCore::CustomEffect::~CustomEffect):

  • animation/CustomEffect.idl: Added.
  • animation/CustomEffectCallback.h: Added.
  • animation/CustomEffectCallback.idl: Added.
  • animation/DocumentTimeline.cpp:

(WebCore::DocumentTimeline::animate):

  • animation/DocumentTimeline.h:
  • animation/DocumentTimeline.idl:
  • bindings/js/WebCoreBuiltinNames.h:

Source/WTF:

Add a new experimental feature for the CustomEffect interface.

  • Scripts/Preferences/WebPreferencesExperimental.yaml:

LayoutTests:

Add tests for the new CustomEffect interface and the document.timeline.animate() method.
These are written using WPT libraries such that they may be upstreamed to the WPT repository
in the future if and when the CustomEffect interface is standardized.

  • platform/win/TestExpectations:
  • webanimations/custom-effect/custom-effect-expected.txt: Added.
  • webanimations/custom-effect/custom-effect.html: Added.
  • webanimations/custom-effect/document-timeline-animate-expected.txt: Added.
  • webanimations/custom-effect/document-timeline-animate.html: Added.
11:22 AM Changeset in webkit [286554] by jonlee@apple.com
  • 6 edits in trunk

Update GPU Process feature flags
https://bugs.webkit.org/show_bug.cgi?id=232547
rdar://83905400

Reviewed by Wenson Hsieh.

Source/WTF:

Move features enabled by default to internal. DOM and WebGL are experimental.

  • Scripts/Preferences/WebPreferencesExperimental.yaml:
  • Scripts/Preferences/WebPreferencesInternal.yaml:

Tools:

  • Scripts/webkitpy/layout_tests/run_webkit_tests.py:

(parse_args): Update features that are set when using run-webkit-tests --use-gpu-process.

  • WebKitTestRunner/TestOptions.cpp:

(WTR::TestOptions::defaults): Turn off DOM Rendering on layout test bots for the time being.

11:13 AM Changeset in webkit [286553] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Null check in shouldUseBreakElement
https://bugs.webkit.org/show_bug.cgi?id=229275

Patch by Rob Buis <rbuis@igalia.com> on 2021-12-06
Reviewed by Ryosuke Niwa.

Source/WebCore:

Need to null check node in shouldUseBreakElement.
Also bail out early in InsertLineBreakCommand::doApply
in case position is not editable.

Test: editing/execCommand/insert-line-break-crash.html

  • editing/InsertLineBreakCommand.cpp:

(WebCore::InsertLineBreakCommand::shouldUseBreakElement):
(WebCore::InsertLineBreakCommand::doApply):

LayoutTests:

  • editing/execCommand/insert-line-break-crash-expected.txt: Added.
  • editing/execCommand/insert-line-break-crash.html: Added.
11:00 AM Changeset in webkit [286552] by commit-queue@webkit.org
  • 6 edits in trunk

[iOS] Allow WKWebView clients to override undoManager
https://bugs.webkit.org/show_bug.cgi?id=233297
<rdar://problem/85526549>

Patch by Matt Gilligan <matthew_gilligan@apple.com> on 2021-12-06
Reviewed by Wenson Hsieh.

Source/WebKit:

Move WKContentView's undoManager up the responder chain to WKWebView so web view
subclasses can customize the undo manager used when WKContentView is first responder.

Test: KeyboardInputTests.OverrideUndoManager

  • UIProcess/API/ios/WKWebViewIOS.mm:

(-[WKWebView undoManager]):
Return the undo manager provided by _contentView when it is current.

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

(-[WKContentView undoManagerForWebView]):
Provide the view's undo manager via this property so that -undoManager will look up the
responder chain to WKWebView.

(-[WKContentView undoManager]): Deleted.

Tools:

  • TestWebKitAPI/Tests/ios/KeyboardInputTestsIOS.mm:

(-[CustomUndoManagerWebView undoManager]):
(TestWebKitAPI::TEST):

10:49 AM Changeset in webkit [286551] by Russell Epstein
  • 1 copy in tags/Safari-613.1.10.1

Tag Safari-613.1.10.1.

10:46 AM Changeset in webkit [286550] by Tadeu Zagallo
  • 28 edits
    2 adds in trunk

Restore navigator.hardwareConcurrency
https://bugs.webkit.org/show_bug.cgi?id=233381
<rdar://85023911>

Reviewed by Saam Barati.

LayoutTests/imported/w3c:

  • web-platform-tests/html/dom/idlharness.https-expected.txt:
  • web-platform-tests/html/dom/idlharness.worker-expected.txt:
  • web-platform-tests/workers/WorkerNavigator-hardware-concurrency.any.worker-expected.txt:

Source/WebCore:

Navigator.hardwareConcurrency was removed in r219379, but it is now used
by emscripten to implement std::thread::hardware_concurrency()

Test: fast/dom/navigator-hardwareConcurrency.html

  • page/Navigator.idl:
  • page/NavigatorBase.cpp:

(WebCore::NavigatorBase::hardwareConcurrency):

  • page/NavigatorBase.h:
  • page/WorkerNavigator.idl:

LayoutTests:

  • fast/dom/Window/resources/window-property-collector.js:

(emitExpectedResult):

  • fast/dom/navigator-detached-no-crash-expected.txt:
  • fast/dom/navigator-hardwareConcurrency-expected.txt: Added.
  • fast/dom/navigator-hardwareConcurrency.html: Added.
  • fast/workers/resources/worker-navigator.js:
  • fast/workers/worker-navigator-expected.txt:
  • platform/glib/imported/w3c/web-platform-tests/html/dom/idlharness.worker-expected.txt:
  • platform/gtk/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/ios-wk2/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/ipad/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/mac-wk1/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/mac-wk1/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/mac-wk2/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/mac-wk2/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/mac/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/win/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/wincairo/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/wpe/fast/dom/navigator-detached-no-crash-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
10:40 AM Changeset in webkit [286549] by Lauro Moura
  • 2 edits in trunk/Source/WebKit

REGRESSION(r286535) [GTK] Fix clean builds after DerivedSources/WebKit2 move
https://bugs.webkit.org/show_bug.cgi?id=233881

Reviewed by Žan Doberšek.

Build fix. Covered by exiting tests.

  • PlatformGTK.cmake: Add symbolic links for the public generated like

we do for the regular headers. It happened to work before because they
were created already in a webkit2 folder.

10:35 AM Changeset in webkit [286548] by Russell Epstein
  • 9 edits in branches/safari-613.1.10-branch/Source

Versioning.

WebKit-7613.1.10.1

10:27 AM Changeset in webkit [286547] by Wenson Hsieh
  • 2 edits in trunk/Tools

[iOS] AppHighlights.AppHighlightCreateAndRestoreAndScroll is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=233828

Reviewed by Tim Horton.

This test began to sometimes fail on iOS 15 API test runners in EWS after enabling APP_HIGHLIGHTS in non-
internal builds. Make this test more robust by waiting for scrolling to the restored highlight.

  • TestWebKitAPI/Tests/WebKitCocoa/WKAppHighlights.mm:

(TestWebKitAPI::TEST):

10:20 AM Changeset in webkit [286546] by Said Abou-Hallawa
  • 14 edits in trunk

[GPU Process] (REGRESSION r285597): Set the filterRegion of the CSSFilter after it is created
https://bugs.webkit.org/show_bug.cgi?id=233849

Reviewed by Cameron McCormack.

Source/WebCore:

In this patch:

  1. sourceImageRect is no longer passed as an argument to SVGFilter. It should be passed only when SVGFilter::apply() is called.
  1. CSSFilter::create() will create and build the FilterFunctions from the FilterOperations. So we have to pass the targetBoundingBox since the FilterEffects will need it when calculating the outsets.
  1. The steps in RenderLayerFilters::beginFilterEffect() are: a) Recreate the CSSFilter if the targetBoundingBox changes. b) Calculate the filterRegion = targetBoundingBox + outsets c) Clamp the filterRegion if needed. This will change the filterScale. d) Set sourceImageRect = filterRegion. e) Recreate the sourceImage if needed. f) setup the context for drawing the target renderer.
  1. Managing the targetBoundingBox and the filterRegion is moved from CSSFilter to RenderLayerFilters.
  • css/CSSFilterImageValue.cpp:

(WebCore::CSSFilterImageValue::image):

  • platform/graphics/filters/Filter.cpp:

(WebCore::Filter::Filter):

  • platform/graphics/filters/Filter.h:

(WebCore::Filter::Filter):

  • rendering/CSSFilter.cpp:

(WebCore::CSSFilter::create):
(WebCore::CSSFilter::CSSFilter):
(WebCore::createSVGFilter):
(WebCore::CSSFilter::buildFilterFunctions):
(WebCore::CSSFilter::apply):
(WebCore::CSSFilter::setFilterRegion):
(WebCore::m_hasFilterThatShouldBeRestrictedBySecurityOrigin): Deleted.
(WebCore::CSSFilter::updateBackingStoreRect): Deleted.
(WebCore::CSSFilter::computeSourceImageRectForDirtyRect): Deleted.
(WebCore::CSSFilter::setSourceImageRect): Deleted.

  • rendering/CSSFilter.h:
  • rendering/RenderLayerFilters.cpp:

(WebCore::RenderLayerFilters::buildFilter):
(WebCore::RenderLayerFilters::allocateBackingStoreIfNeeded):
(WebCore::RenderLayerFilters::beginFilterEffect):
(WebCore::RenderLayerFilters::applyFilterEffect):
(WebCore::RenderLayerFilters::allocateBackingStore): Deleted.

  • rendering/RenderLayerFilters.h:
  • rendering/svg/RenderSVGResourceFilter.cpp:

(WebCore::RenderSVGResourceFilter::applyResource):

  • rendering/svg/SVGRenderTreeAsText.cpp:

(WebCore::writeSVGResourceContainer):

  • svg/graphics/filters/SVGFilter.cpp:

(WebCore::SVGFilter::create):
(WebCore::SVGFilter::SVGFilter):

  • svg/graphics/filters/SVGFilter.h:

LayoutTests:

Unskip layout tests which were skipped in r285597.

9:46 AM Changeset in webkit [286545] by commit-queue@webkit.org
  • 12 edits in trunk

WKWebpagePreferences._activeContentRuleListActionPatterns should be an NSDictionary of identifier to allowed patterns
https://bugs.webkit.org/show_bug.cgi?id=233842

Patch by Alex Christensen <achristensen@webkit.org> on 2021-12-06
Reviewed by Timothy Hatcher.

Source/WebCore:

There's no need for nil to match everything because a pattern can be written to quickly match everything.
There is a need for different extensions (with different identifiers) to have different active action permissions, though.

  • contentextensions/ContentExtensionsBackend.cpp:

(WebCore::ContentExtensions::ContentExtensionsBackend::processContentRuleListsForLoad):

  • loader/DocumentLoader.cpp:

(WebCore::DocumentLoader::DocumentLoader):
(WebCore::DocumentLoader::setActiveContentRuleListActionPatterns):
(WebCore::DocumentLoader::allowsActiveContentRuleListActionsForURL const):

  • loader/DocumentLoader.h:

Source/WebKit:

  • Shared/WebsitePoliciesData.cpp:

(WebKit::WebsitePoliciesData::decode):

  • Shared/WebsitePoliciesData.h:
  • UIProcess/API/APIWebsitePolicies.h:
  • UIProcess/API/Cocoa/WKWebpagePreferences.mm:

(-[WKWebpagePreferences _setActiveContentRuleListActionPatterns:]):
(-[WKWebpagePreferences _activeContentRuleListActionPatterns]):

  • UIProcess/API/Cocoa/WKWebpagePreferencesPrivate.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/WKContentExtensionStore.mm:

(navigationDelegateAllowingActiveActionsOnTestHost):
(TEST_F):

9:20 AM Changeset in webkit [286544] by graouts@webkit.org
  • 6 edits in trunk/Source/WebCore

Clean up virtual methods on AnimationEffect
https://bugs.webkit.org/show_bug.cgi?id=233868

Reviewed by Simon Fraser.

To this day, the only concrete subclass of AnimationEffect has been KeyframeEffect. Soon, we'll introduce
another concrete subclass for callback-based animations leveraging the Web Animations mode: CustomEffect.
To prepare for this new class, we clean up the virtual methods on AnimationEffect such that they make a
bit more sense:

  • much of the implementation of timeToNextTick() is brought from KeyframeEffect to AnimationEffect to

account for the cases which are purely based on timing properties shared by any potential AnimationEffect
subclass,

  • we add a new ticksContinouslyWhileActive() method which allows subclasses to indicate whether they require

continuous scheduling while active, which is true for KeyframeEffect unless it has no keyframes, no CSS
properties set on its keyframes or is running fully accelerated,

  • much of the implementation of setAnimation() is brought from KeyframeEffect to AnimationEffect since

updating the relevance of the animation based on a change of effect should apply to any AnimationEffect,

  • the apply() and invalidate() methods are moved from AnimationEffect to KeyframeEffect alone since they

really are specific to KeyframeEffect's interaction with style resolution,

  • all the other virtual methods on AnimationEffect have stub implementations such that new subclasses

only need to override them as required: animationDidTick(), animationDidPlay(),
animationDidChangeTimingProperties(), animationWasCanceled(), animationSuspensionStateDidChange(bool)
and animationTimelineDidChange(AnimationTimeline*).

  • animation/AnimationEffect.cpp:

(WebCore::AnimationEffect::setAnimation):
(WebCore::AnimationEffect::timeToNextTick const):

  • animation/AnimationEffect.h:

(WebCore::AnimationEffect::animationDidTick):
(WebCore::AnimationEffect::animationDidPlay):
(WebCore::AnimationEffect::animationDidChangeTimingProperties):
(WebCore::AnimationEffect::animationWasCanceled):
(WebCore::AnimationEffect::animationSuspensionStateDidChange):
(WebCore::AnimationEffect::animationTimelineDidChange):
(WebCore::AnimationEffect::ticksContinouslyWhileActive const):
(WebCore::AnimationEffect::setAnimation): Deleted.
(WebCore::AnimationEffect::timeToNextTick const): Deleted.

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::setAnimation):
(WebCore::KeyframeEffect::ticksContinouslyWhileActive const):
(WebCore::KeyframeEffect::timeToNextTick const):

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

(WebCore::WebAnimation::invalidateEffect):
(WebCore::WebAnimation::resolve):
(WebCore::WebAnimation::timeToNextTick const):

6:35 AM Changeset in webkit [286543] by Nikolas Zimmermann
  • 5 edits in trunk/Source

[LBSE] Toggling the Settings -> Enabled LBSE flag has no immediate effect
https://bugs.webkit.org/show_bug.cgi?id=233871

Reviewed by Rob Buis.

Toggling "Enable layer-based SVG engine" in e.g. MiniBrowser or from JS has no immediate effect.
A relayout is not enough: a full style / render tree rebuild is needed.

Source/WebCore:

Covered by existing tests.

  • page/SettingsBase.cpp:

(WebCore::SettingsBase::layerBasedSVGEngineEnabledChanged): Rebuild style / renderers upon changes.

  • page/SettingsBase.h:

Source/WTF:

  • Scripts/Preferences/WebPreferencesInternal.yaml: When "LayerBasedSVGEngineEnabled" changes call

WebCore::SettingsBase::layerBasedSVGEngineEnabledChanged() to assure the switch from legacy to
LBSE engine and vice-versa is live and doesn't need reloads to take effect.

6:28 AM Changeset in webkit [286542] by Nikolas Zimmermann
  • 17 edits in trunk/Source/WebCore

[LBSE] Add RenderObject::isSVGRootOrLegacySVGRoot() helper
https://bugs.webkit.org/show_bug.cgi?id=233870

Reviewed by Rob Buis.

Preparations to begin a new RenderSVGRoot implementation for the
layer-based SVG engine (LBSE).

Add a helper function to identify either legacy SVG or LBSE root
render objects (LegacyRenderSVGRoot and the upcoming RenderSVGRoot).

Covered by existing tests, no change in behavior.

  • accessibility/AXObjectCache.cpp:

(WebCore::createFromRenderer):

  • accessibility/AccessibilityRenderObject.cpp:

(WebCore::AccessibilityRenderObject::boundingBoxRect const):
(WebCore::AccessibilityRenderObject::determineAccessibilityRole):

  • dom/Element.cpp:

(WebCore::Element::boundingAbsoluteRectWithoutLayout):

  • inspector/InspectorOverlay.cpp:

(WebCore::buildRendererHighlight):

  • layout/integration/LayoutIntegrationCoverage.cpp:

(WebCore::LayoutIntegration::canUseForChild):

  • rendering/RenderGeometryMap.cpp:

(WebCore::canMapBetweenRenderersViaLayers):

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::beginTransparencyLayers):
(WebCore::RenderLayer::calculateClipRects const):

  • rendering/RenderLayer.h:

(WebCore::RenderLayer::canUseOffsetFromAncestor const):

  • rendering/RenderObject.cpp:

(WebCore::objectIsRelayoutBoundary):

  • rendering/RenderObject.h:

(WebCore::RenderObject::isLegacySVGRoot const):
(WebCore::RenderObject::isSVGRootOrLegacySVGRoot const):

  • rendering/RenderReplaced.cpp:

(WebCore::hasIntrinsicSize):

  • rendering/RenderView.cpp:

(WebCore::RenderView::layout):

  • rendering/svg/LegacyRenderSVGRoot.h:
  • rendering/svg/SVGRenderSupport.cpp:

(WebCore::layoutSizeOfNearestViewportChanged):

  • rendering/svg/SVGRenderingContext.cpp:

(WebCore::SVGRenderingContext::prepareToRenderSVGContent):
(WebCore::SVGRenderingContext::calculateTransformationToOutermostCoordinateSystem):

  • rendering/updating/RenderTreeBuilder.cpp:

(WebCore::RenderTreeBuilder::reportVisuallyNonEmptyContent):

12:13 AM Changeset in webkit [286541] by Antti Koivisto
  • 6 edits in trunk/Source/WebCore

[LFC][Integration] Use end bits in text box iterator
https://bugs.webkit.org/show_bug.cgi?id=233858

Reviewed by Alan Bujtas.

Make text box traversal work correctly in bidi context where encountering a different
layout box does not necessarily mean there are no further text boxes for the layout box.

  • layout/formattingContexts/inline/InlineDisplayContentBuilder.cpp:

(WebCore::Layout::InlineDisplayContentBuilder::processBidiContent):
(WebCore::Layout::InlineDisplayContentBuilder::computeIsFirstIsLastBoxForInlineContent):

Set the bits for all box types.

  • layout/formattingContexts/inline/display/InlineDisplayBox.h:

(WebCore::InlineDisplay::Box::Box):
(WebCore::InlineDisplay::Box::isTextOrSoftLineBreak const):
(WebCore::InlineDisplay::Box::isFirstForLayoutBox const):
(WebCore::InlineDisplay::Box::isLastForLayoutBox const):
(WebCore::InlineDisplay::Box::setIsFirstForLayoutBox):
(WebCore::InlineDisplay::Box::setIsLastForLayoutBox):
(WebCore::InlineDisplay::Box::isFirstBox const): Deleted.
(WebCore::InlineDisplay::Box::isLastBox const): Deleted.
(WebCore::InlineDisplay::Box::setIsLastBox): Deleted.
(WebCore::InlineDisplay::Box::setIsFirstBox): Deleted.

Renamed for clarity and correctness.

  • layout/integration/InlineIteratorBoxModernPath.h:

(WebCore::InlineIterator::BoxModernPath::isText const):
(WebCore::InlineIterator::BoxModernPath::traverseNextTextBox):

Use the isLastForLayoutBox bit to end the traversal.

(WebCore::InlineIterator::BoxModernPath::traverseNextInlineBox):
(WebCore::InlineIterator::BoxModernPath::traversePreviousInlineBox):
(WebCore::InlineIterator::BoxModernPath::traverseNextWithSameLayoutBox):
(WebCore::InlineIterator::BoxModernPath::traversePreviousWithSameLayoutBox):

Factor into helpers.

  • layout/integration/InlineIteratorTextBox.h:
12:13 AM Changeset in webkit [286540] by youenn@apple.com
  • 2 edits in trunk/Source/WTF

Enable NavigationPreloadManager by default
https://bugs.webkit.org/show_bug.cgi?id=233755

Reviewed by Chris Dumez.

  • Scripts/Preferences/WebPreferencesExperimental.yaml:
12:05 AM Changeset in webkit [286539] by youenn@apple.com
  • 3 edits in trunk/Source/ThirdParty/libwebrtc

Close WebRTC allocation sequence shared socket in case of sequence network failure
https://bugs.webkit.org/show_bug.cgi?id=233808

Reviewed by Geoffrey Garen.

  • Source/webrtc/p2p/client/basic_port_allocator.cc:
  • Source/webrtc/p2p/client/basic_port_allocator.h:

Dec 5, 2021:

9:49 PM Changeset in webkit [286538] by Said Abou-Hallawa
  • 59 edits
    1 add in trunk

[GPU Process] Add the encoding/decoding for Filter and FilterEffect
https://bugs.webkit.org/show_bug.cgi?id=232844

Reviewed by Wenson Hsieh.

Source/WebCore:

This patch adds the encoding and decoding for the FilterEffect and the
Filter objects. Because these objects have super-classes, we are going
to do the encoding and decoding through a new IPC class called
FilterReference.

The encoding and decoding of these classes will be needed in two cases:

1) DisplayList::Recorder::drawFilteredImageBuffer()
2) RemoteImageBufferProxy::filteredImage()

A few things have not be done this patch yet:

1) LightSource has not been encoded/decoded
2) FELighting classes have not been encoded/decoded
3) FEImage has not been encoded/decoded
4) SVGFilter has not been encoded/decoded

This patch does not change any behavior even if the GPU Process for DOM
rendering is enabled. The sourceImage for the filter and the filter image
need to be of type of RemoteImageBufferProxy to this code to be called.

  • Headers.cmake:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/ConcreteImageBuffer.h:
  • platform/graphics/GraphicsContext.cpp:

(WebCore::GraphicsContext::drawFilteredImageBuffer):

  • platform/graphics/GraphicsContext.h:
  • 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.cpp:

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

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

(WebCore::DisplayList::DrawFilteredImageBuffer::DrawFilteredImageBuffer):
(WebCore::DisplayList::DrawFilteredImageBuffer::apply const):
(WebCore::DisplayList::DrawFilteredImageBuffer::apply):
(WebCore::DisplayList::operator<<):

  • platform/graphics/displaylists/DisplayListItems.h:

(WebCore::DisplayList::DrawFilteredImageBuffer::sourceImageIdentifier const):
(WebCore::DisplayList::DrawFilteredImageBuffer::sourceImageRect const):
(WebCore::DisplayList::DrawFilteredImageBuffer::globalBounds const):
(WebCore::DisplayList::DrawFilteredImageBuffer::localBounds const):

  • platform/graphics/displaylists/DisplayListRecorder.cpp:

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

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

(WebCore::DisplayList::RecorderImpl::recordDrawFilteredImageBuffer):

  • platform/graphics/displaylists/DisplayListRecorderImpl.h:
  • platform/graphics/filters/FEBlend.h:

(WebCore::FEBlend::encode const):
(WebCore::FEBlend::decode):

  • platform/graphics/filters/FEColorMatrix.h:

(WebCore::FEColorMatrix::encode const):
(WebCore::FEColorMatrix::decode):

  • platform/graphics/filters/FEComponentTransfer.h:

(WebCore::ComponentTransferFunction::encode const):
(WebCore::ComponentTransferFunction::decode):
(WebCore::FEComponentTransfer::encode const):
(WebCore::FEComponentTransfer::decode):

  • platform/graphics/filters/FEComposite.h:

(WebCore::FEComposite::encode const):
(WebCore::FEComposite::decode):

  • platform/graphics/filters/FEConvolveMatrix.h:

(WebCore::FEConvolveMatrix::encode const):
(WebCore::FEConvolveMatrix::decode):

  • platform/graphics/filters/FEDiffuseLighting.h:

(WebCore::FEDiffuseLighting::decode):

  • platform/graphics/filters/FEDisplacementMap.h:

(WebCore::FEDisplacementMap::encode const):
(WebCore::FEDisplacementMap::decode):

  • platform/graphics/filters/FEDropShadow.h:

(WebCore::FEDropShadow::encode const):
(WebCore::FEDropShadow::decode):

  • platform/graphics/filters/FEFlood.h:

(WebCore::FEFlood::encode const):
(WebCore::FEFlood::decode):

  • platform/graphics/filters/FEGaussianBlur.h:

(WebCore::FEGaussianBlur::encode const):
(WebCore::FEGaussianBlur::decode):

  • platform/graphics/filters/FELighting.h:

(WebCore::FELighting::encode const):
(WebCore::FELighting::decode):

  • platform/graphics/filters/FEMerge.cpp:

(WebCore::FEMerge::create):
(WebCore::FEMerge::FEMerge):

  • platform/graphics/filters/FEMerge.h:

(WebCore::FEMerge::encode const):
(WebCore::FEMerge::decode):

  • platform/graphics/filters/FEMorphology.h:

(WebCore::FEMorphology::encode const):
(WebCore::FEMorphology::decode):

  • platform/graphics/filters/FEOffset.h:

(WebCore::FEOffset::encode const):
(WebCore::FEOffset::decode):

  • platform/graphics/filters/FESpecularLighting.h:

(WebCore::FESpecularLighting::decode):

  • platform/graphics/filters/FETile.h:
  • platform/graphics/filters/FETurbulence.h:

(WebCore::FETurbulence::encode const):
(WebCore::FETurbulence::decode):

  • platform/graphics/filters/Filter.cpp:

(WebCore::Filter::apply):

  • platform/graphics/filters/Filter.h:

(WebCore::Filter::setClipOperation):

  • platform/graphics/filters/SourceGraphic.h:
  • rendering/CSSFilter.cpp:

(WebCore::CSSFilter::create):
(WebCore::CSSFilter::CSSFilter):

  • rendering/CSSFilter.h:
  • rendering/RenderLayerFilters.cpp:

(WebCore::RenderLayerFilters::applyFilterEffect):

  • rendering/svg/RenderSVGResourceFilter.cpp:

(WebCore::RenderSVGResourceFilter::postApplyResource):

  • svg/SVGFEMergeElement.cpp:

(WebCore::SVGFEMergeElement::build const):

Source/WebKit:

  • GPUProcess/graphics/RemoteDisplayListRecorder.cpp:

(WebKit::RemoteDisplayListRecorder::drawFilteredImageBuffer):

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

(WebKit::RemoteRenderingBackend::getFilteredImageForImageBuffer):

  • GPUProcess/graphics/RemoteRenderingBackend.h:
  • GPUProcess/graphics/RemoteRenderingBackend.messages.in:
  • Platform/IPC/FilterReference.h: Added.

(IPC::FilterReference::FilterReference):
(IPC::FilterReference::takeFilter):
(IPC::FilterReference::encodeFilterEffect):
(IPC::FilterReference::decodeFilterEffect):
(IPC::FilterReference::encodeSVGFilter):
(IPC::FilterReference::decodeSVGFilter):
(IPC::FilterReference::encodeCSSFilter):
(IPC::FilterReference::decodeCSSFilter):
(IPC::FilterReference::encodeFilter):
(IPC::FilterReference::decodeFilter):
(IPC::FilterReference::encode const):
(IPC::FilterReference::decode):

  • Scripts/webkit/messages.py:

(types_that_cannot_be_forward_declared):

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/GPU/graphics/RemoteDisplayListRecorderProxy.cpp:

(WebKit::RemoteDisplayListRecorderProxy::recordDrawFilteredImageBuffer):

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

(WebKit::RemoteRenderingBackendProxy::getFilteredImage):

  • WebProcess/GPU/graphics/RemoteRenderingBackendProxy.h:

Tools:

  • TestWebKitAPI/Tests/WebCore/DisplayListTests.cpp:
  • TestWebKitAPI/Tests/WebCore/cg/DisplayListTestsCG.cpp:
8:40 PM Changeset in webkit [286537] by Simon Fraser
  • 6 edits in trunk

Add trace points for generated momentum events
https://bugs.webkit.org/show_bug.cgi?id=233857

Reviewed by Tim Horton.

Source/WebKit:

Add start/end points for synthetic momentum, and a trace point for each generated event.

  • WebProcess/WebPage/MomentumEventDispatcher.cpp:

(WebKit::MomentumEventDispatcher::dispatchSyntheticMomentumEvent):
(WebKit::MomentumEventDispatcher::didStartMomentumPhase):
(WebKit::MomentumEventDispatcher::didEndMomentumPhase):

Source/WTF:

  • wtf/SystemTracing.h:

Tools:

Add start/end points for synthetic momentum, and a trace point for each generated event.

  • Tracing/SystemTracePoints.plist:
Note: See TracTimeline for information about the timeline view.