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

Timeline



Aug 5, 2021:

8:30 PM Changeset in webkit [280719] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Unreviewed test garening, skip test that is unsupported on WK1.

  • platform/win/TestExpectations:
8:10 PM Changeset in webkit [280718] by Cameron McCormack
  • 12 edits in trunk/Source

Stop tracking form elements with FormController
https://bugs.webkit.org/show_bug.cgi?id=228724
<rdar://problem/81435095>

Reviewed by Darin Adler.

Source/WebCore:

FormController currently tracks the insertion order of
HTMLFormElementWithState objects in the document. But we don't need
to know this list of form controls until the time we need to save
form state for the document (e.g. on pagehide). So we instead
traverse the document to find those elements at the point we need
them, rather than maintain FormController::m_formElementsWithState.

This is a small speedup (1-2%) on a few of the Speedometer subtests
that insert and remove many input elements.

A future optimization could record on the Document whether there are
any input elements that have had their value changed, since it's
probably common for pages with form controls to never be changed.

  • dom/Document.cpp:

(WebCore::Document::formElementsState const): Traverse the document to
find all the HTMLFormElementWithState objects.

  • dom/Element.h:

(WebCore::Element::isFormControlElementWithState const):

  • html/FormController.cpp:

(WebCore::FormController::createSavedFormStateMap):
(WebCore::FormController::formElementsState const):

  • html/FormController.h:
  • html/HTMLFormControlElementWithState.cpp:

(WebCore::HTMLFormControlElementWithState::insertedIntoAncestor):
Track the order that HTMLFormControlElementWithState objects are
inserted into the document.
(WebCore::HTMLFormControlElementWithState::removedFromAncestor):

  • html/HTMLFormControlElementWithState.h:

(WebCore::HTMLFormControlElementWithState::insertionIndex const):
(isType):

  • page/Frame.h: Remove unused formElementsCharacterCount.
  • page/ios/FrameIOS.mm:

Source/WebKitLegacy/mac:

formElementsCharacterCount is unused and can be removed.

  • WebView/WebFrame.mm:
  • WebView/WebFramePrivate.h:
7:39 PM Changeset in webkit [280717] by Diego Pino Garcia
  • 2 edits in trunk/Tools

[buildbot] Add new post-commit bot to build WPE on Ubuntu-LTS
https://bugs.webkit.org/show_bug.cgi?id=228535

Reviewed by Alexey Proskuryakov.

Currently we only had a bot to build WebKitGTK on Ubuntu LTS. This is
not enough to detect build regressions in WPE.

  • CISupport/build-webkit-org/config.json:
6:59 PM Changeset in webkit [280716] by commit-queue@webkit.org
  • 3 edits
    1 add in trunk

Assertion failure when checking array in DFG (32 bits)
https://bugs.webkit.org/show_bug.cgi?id=228839

Patch by Mikhail R. Gadelha <Mikhail R. Gadelha> on 2021-08-05
Reviewed by Yusuke Suzuki.

JSTests:

  • stress/check-array-empty-32.js: Added.

(a.b.catch.print.c):
(a.b):
(a.e):
(a):

Source/JavaScriptCore:

Since empty values don't pass the cell check in 32 bits, we need to
guard the SpecEmpty check to only happen in 64 bits archs

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::checkArray):

6:56 PM Changeset in webkit [280715] by timothy_horton@apple.com
  • 9 edits
    1 delete in trunk

fast/canvas/canvas-crash.html doesn't test what it intends to on iOS
https://bugs.webkit.org/show_bug.cgi?id=228747

Reviewed by Simon Fraser.

Source/WebCore:

The test fast/canvas/canvas-crash.html intends to test changes made
to actual canvas code (see r215632); however, on the iOS simulator
the test doesn't even manage to make a canvas context because of
"maximum area" and "maximum backing store size" limits, which differ
per-platform. This results in unique test results for iOS, as well
as the test not actually exercising the code it was intended to.

Fix this by adding an override for the maximum area limit (we already
had one for maximum backing store size), and overriding them in
this test (and another similarly afflicted test).

  • html/HTMLCanvasElement.cpp:

(WebCore::maxCanvasArea):
(WebCore::HTMLCanvasElement::setMaxCanvasAreaForTesting):
(WebCore::HTMLCanvasElement::createImageBuffer const):

  • html/HTMLCanvasElement.h:
  • testing/Internals.cpp:

(WebCore::Internals::resetToConsistentState):
(WebCore::Internals::setMaxCanvasArea):

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

LayoutTests:

  • fast/canvas/canvas-crash.html:
  • fast/canvas/canvas-skia-excessive-size.html:
  • platform/ios-simulator/fast/canvas/canvas-crash-expected.txt: Removed.
  • platform/ios-simulator/fast/canvas/canvas-skia-excessive-size-expected.txt: Removed.

Delete the iOS-specific results, and adopt the new overrides in these two tests.

6:02 PM Changeset in webkit [280714] by Alan Coon
  • 1 copy in tags/Safari-612.1.27.3.1

Tag Safari-612.1.27.3.1.

6:01 PM Changeset in webkit [280713] by Ryan Haddad
  • 2 edits in trunk/Tools

REGRESSION (r279855): TestWebKitAPI.AppleLanguagesTest.UpdateAppleLanguages is failing
https://bugs.webkit.org/show_bug.cgi?id=228309

Unreviewed test gardening.

This test has been skipped on Apple Silicon because of timeouts, and
now it is a flaky failure on Intel machines. Disable it outright for
the time being.

  • TestWebKitAPI/Tests/WebKit/OverrideAppleLanguagesPreference.mm:

(TEST_F):

5:57 PM Changeset in webkit [280712] by Alan Coon
  • 2 edits in branches/safari-612.1.27.3-branch/Source/JavaScriptCore

Cherry-pick r280659. rdar://problem/81592180

[ARM64] Fix Zoom black screen during video meeting on Safari
https://bugs.webkit.org/show_bug.cgi?id=228776

Reviewed by Saam Barati.

The problem (rdar://81434487) reports that Zoom turns to a black screen during the video
meeting on Safari. The reproduction of this problem is verified and bisected to the previous patch
(https://bugs.webkit.org/show_bug.cgi?id=228057). Previously, we introduce a pattern
matching for instruction EON-with-shift on ARM64, where the pattern is d = n ((m ShiftType amount) -1).

x = m ShiftType amount
y = x -1
z = n
y

We check canBeInternal() on x but not on y based on the computing cost analysis in that patch,
which is totally wrong. If the pattern matching is triggered, then the compiler would not emit
the corresponding Air of x after lowering, leading to data corruption or system crash since y
depends on x.

In the real world example (Zoom video meeting), we find the B3 IR:

...
Int32 b@528 = SShr(b@526, $31(b@527), Wasm: {opcode: I32ShrS, location: 0x26b})
Int32 b@529 = BitXor(b@528, $-1(b@144), Wasm: {opcode: I32Xor, location: 0x26e})
...
Int32 b@551 = BitXor(b@446, b@529, Wasm: {opcode: I32Xor, location: 0x28e})
...

After Lowering to Air:

...
Not32 %fp, %x2, b@529
...
XorNotRightShift32 %tmp199, %tmp211, $31, %tmp209, b@551
...

Since the implementation of the previous patch does commitInternal() on b@528, the operand of
b@529 turns to a frame pointer. To resolve this problem, we should either check canBeInternal()
on both b@528 and b@529 or not at all.

  • b3/B3LowerToAir.cpp:

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

5:53 PM Changeset in webkit [280711] by commit-queue@webkit.org
  • 1 edit
    3 copies
    3 moves in trunk/LayoutTests

[GLIB] Unreviewed test gardening, move some expected results to GTK/WPE specific directories
https://bugs.webkit.org/show_bug.cgi?id=228844

Some expected results have diverged between GTK and WPE and need to be
moved to the more specific directories.

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-08-05

  • platform/gtk/fast/selectors/unqualified-hover-strict-expected.txt: Copied from LayoutTests/platform/glib/fast/selectors/unqualified-hover-strict-expected.txt.
  • platform/gtk/media/video-playing-and-pause-expected.txt: Copied from LayoutTests/platform/glib/media/video-playing-and-pause-expected.txt.
  • platform/gtk/tables/mozilla/core/col_span-expected.txt: Copied from LayoutTests/platform/glib/tables/mozilla/core/col_span-expected.txt.
  • platform/wpe/fast/selectors/unqualified-hover-strict-expected.txt: Renamed from LayoutTests/platform/glib/fast/selectors/unqualified-hover-strict-expected.txt.
  • platform/wpe/media/video-playing-and-pause-expected.txt: Renamed from LayoutTests/platform/glib/media/video-playing-and-pause-expected.txt.
  • platform/wpe/tables/mozilla/core/col_span-expected.txt: Renamed from LayoutTests/platform/glib/tables/mozilla/core/col_span-expected.txt.
5:48 PM Changeset in webkit [280710] by Alan Coon
  • 8 edits in branches/safari-612.1.27.3-branch/Source

Versioning.

WebKit-7612.1.27.3.1

5:40 PM Changeset in webkit [280709] by Russell Epstein
  • 8 edits in branches/safari-612.1.27.0-branch/Source

Versioning.

WebKit-7612.1.27.0.2

5:23 PM Changeset in webkit [280708] by Chris Dumez
  • 2 edits in trunk/LayoutTests

REGRESSION (r280541): [ BigSur Debug ] accessibility/roles-computedRoleString.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=228744
<rdar://problem/81472432>

Unreviewed, speed up test a bit as it is timing out flakily in Debug.

  • accessibility/roles-computedRoleString.html:
5:20 PM Changeset in webkit [280707] by Russell Epstein
  • 1 copy in tags/Safari-612.1.27.0.1

Tag Safari-612.1.27.0.1.

4:47 PM Changeset in webkit [280706] by Kate Cheney
  • 4 edits in trunk

LoadWebArchive.FailNavigation1 test is a false positive
https://bugs.webkit.org/show_bug.cgi?id=228848
<rdar://problem/81587448>

Reviewed by Brent Fulgham.

Source/WebKit:

Drive by logging fix.

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::fetchWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteData):

Tools:

Update LoadWebArchive.FailNavigation1 to test the case of a webarchive
being loaded with a host for better test coverage.

  • TestWebKitAPI/Tests/mac/load-web-archive-1.html:
3:47 PM Changeset in webkit [280705] by Andres Gonzalez
  • 5 edits
    1 add in trunk

VoiceOver is not announcing the state as selected/unselected when an item is selected in a grid.
https://bugs.webkit.org/show_bug.cgi?id=228840
<rdar://78225826>

Reviewed by Chris Fleizach.

Source/WebCore:

Test: accessibility/selected-state-changed-notifications.html.

On iOS, a table/grid cell element is not exposed to AX clients. Instead
the content of the cell is. This patch ensures that if the cell element
is selected, the AX objects that represent the content inside the cell
will inherit the selected state from the cell.

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:

(-[WebAccessibilityObjectWrapper _accessibilityTraitsFromAncestors]):

LayoutTests:

  • accessibility/selected-state-changed-notifications.html:
  • platform/ios/TestExpectations:
  • platform/ios/accessibility/selected-state-changed-notifications-expected.txt: Added.
3:39 PM Changeset in webkit [280704] by rmorisset@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION (r280507): ASSERTION FAILED: !undominatedPhis.contains(value) in JSC::B3::(anonymous namespace)::Validater::validatePhisAreDominatedByUpsilons()
https://bugs.webkit.org/show_bug.cgi?id=228838
<rdar://problem/81579314>

Reviewed by Geoffrey Garen.

When I added validation of the dominance of Phis by their Upsilons, I checked two things:

  • There is no path from the entry point to a Phi without going through a corresponding Upsilon (the actual dominance check)
  • There is no way to execute a Phi twice without going through a corresponding Upsilon in between

The second property is not actually true in B3 IR, I had misunderstood that part of the meaning of Phis/Upsilons.
So this patch just removes this second check.

It has no security/stability/performance implication: this is validation code, which runs automatically in debug mode, but should not run at all on customer machines.

  • b3/B3Validate.cpp:
1:56 PM Changeset in webkit [280703] by ntim@apple.com
  • 34 edits
    4 adds in trunk

Implement support for <dialog> element cancel event
https://bugs.webkit.org/show_bug.cgi?id=227534

Reviewed by Chris Dumez.

This makes <dialog> emit a cancel event then close when the escape key is pressed.

Updated relevant WPT:

  • <dialog> cancel event WPTs: used send_keys instead of test_driver.Actions() (which are unsupported by WebKit test runner)
  • oncancel now is recognized

Failing WPT:

  • dialog-cancel-with-input.html: needs <dialog> focusing steps (webkit.org/b/227537) to be implemented for <input> to get focus
  • dialog-cancel-with-select.html: needs <dialog> focusing steps (webkit.org/b/227537) to be implemented for <select> to get focus
  • dialog-keydown-preventDefault.html: current implementation does not prevent canceling from happening when keydown event has preventDefault()

LayoutTests/imported/w3c:

  • web-platform-tests/html/browsers/the-window-object/security-window/window-security.https-expected.txt:
  • web-platform-tests/html/browsers/the-window-object/window-properties.https-expected.txt:
  • web-platform-tests/html/dom/idlharness.https-expected.txt:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-events-expected.txt:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-events.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-preventDefault-expected.txt:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-preventDefault.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-input-expected.txt:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-input.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-select.html:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-keydown-preventDefault-expected.txt:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-keydown-preventDefault.html:
  • web-platform-tests/html/webappapis/scripting/events/event-handler-all-global-events-expected.txt:
  • web-platform-tests/html/webappapis/scripting/events/event-handler-attributes-body-window-expected.txt:
  • web-platform-tests/html/webappapis/scripting/events/event-handler-attributes-windowless-body-expected.txt:
  • web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-expected.txt:

Source/WebCore:

  • dom/GlobalEventHandlers.idl:
  • html/HTMLAttributeNames.in:
  • html/HTMLDialogElement.cpp:

(WebCore::HTMLDialogElement::cancel):

  • html/HTMLDialogElement.h:
  • html/HTMLElement.cpp:

(WebCore::HTMLElement::createEventHandlerNameMap):

  • page/EventHandler.cpp:

(WebCore::EventHandler::internalKeyEvent):

LayoutTests:

  • platform/glib/imported/w3c/web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-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/ios-wk2/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-events-expected.txt: Added.
  • platform/ios-wk2/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-preventDefault-expected.txt: Added.
  • platform/ios-wk2/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-input-expected.txt: Added.
  • platform/ios-wk2/imported/w3c/web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-keydown-preventDefault-expected.txt: Added.
  • platform/ios-wk2/imported/w3c/web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-expected.txt:
  • platform/mac-wk1/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/mac-wk1/imported/w3c/web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-expected.txt:
  • platform/mac-wk2/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/mac-wk2/imported/w3c/web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
12:29 PM Changeset in webkit [280702] by eric.carlson@apple.com
  • 9 edits in trunk/Source

[iOS] getUserMedia sometimes doesn't capture from specified microphone
https://bugs.webkit.org/show_bug.cgi?id=228753
rdar://79704226

Reviewed by Youenn Fablet.

Source/WebCore:

The system will always choose the "default" audio input source unless
+[AVAudioSession setPreferredInput:error:] is called first, and that only works
if the audio session category has been set to PlayAndRecord *before* it is called,
so configure the audio session for recording before we choose and configure the
audio capture device.

Tested manually, this only reproduces on hardware.

  • platform/audio/PlatformMediaSessionManager.cpp:

(WebCore::PlatformMediaSessionManager::activeAudioSessionRequired const): Audio
capture requires an active audio session.
(WebCore::PlatformMediaSessionManager::removeSession): Move #if USE(AUDIO_SESSION)
guard inside of maybeDeactivateAudioSession so it isn't spread throughout the file.
(WebCore::PlatformMediaSessionManager::sessionWillBeginPlayback): Ditto.
(WebCore::PlatformMediaSessionManager::processWillSuspend): Ditto.
(WebCore::PlatformMediaSessionManager::processDidResume): Ditto.
(WebCore::PlatformMediaSessionManager::sessionCanProduceAudioChanged): Add logging,
call maybeActivateAudioSession() so we activate the audio session if necessary.
(WebCore::PlatformMediaSessionManager::addAudioCaptureSource): Call updateSessionState
instead of scheduleUpdateSessionState so the audio session category is updated
immediately.
(WebCore::PlatformMediaSessionManager::maybeDeactivateAudioSession): Move
#if USE(AUDIO_SESSION) into the function so it doesn't need to be spread
throughout the file.
(WebCore::PlatformMediaSessionManager::maybeActivateAudioSession): Ditto.

  • platform/audio/PlatformMediaSessionManager.h:

(WebCore::PlatformMediaSessionManager::isApplicationInBackground const):

  • platform/audio/ios/AudioSessionIOS.mm:

(WebCore::AudioSessionIOS::setPreferredBufferSize): Log an error if we are unable
to set the preferred buffer size.

  • platform/mediastream/ios/AVAudioSessionCaptureDeviceManager.h:
  • platform/mediastream/ios/AVAudioSessionCaptureDeviceManager.mm:

(WebCore::AVAudioSessionCaptureDeviceManager::setPreferredAudioSessionDeviceUID):
New, set the preferred input so capture will use select the device we want.
(WebCore::AVAudioSessionCaptureDeviceManager::scheduleUpdateCaptureDevices): Remove
m_recomputeDevices, setAudioCaptureDevices has been restructured so we don't need it.
(WebCore::AVAudioSessionCaptureDeviceManager::computeCaptureDevices): Ditto.
(WebCore::AVAudioSessionCaptureDeviceManager::setAudioCaptureDevices): Don't update
the list of capture devices when the default device changes, only when a device is
added, removed, enabled, or disabled.

  • platform/mediastream/mac/CoreAudioCaptureSource.cpp:

(WebCore::CoreAudioSharedUnit::setCaptureDevice): Call setPreferredAudioSessionDeviceUID
so the correct device is selected.
(WebCore::CoreAudioSharedUnit::cleanupAudioUnit): Clear m_persistentID.
(WebCore::CoreAudioCaptureSource::create): Return an error with a string, or the
web process can detect a failure.
(WebCore::CoreAudioCaptureSource::stopProducingData): Add logging.

Source/WebKit:

  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.cpp: Re

(WebKit::UserMediaCaptureManagerProxy::SourceProxy::audioUnitWillStart): Delete,
we don't need it now that the web process configures the audio session before
capture begins.

11:30 AM Changeset in webkit [280701] by Russell Epstein
  • 2 edits in branches/safari-612.1.27.0-branch/Source/JavaScriptCore

Cherry-pick r280659. rdar://problem/81569033

[ARM64] Fix Zoom black screen during video meeting on Safari
https://bugs.webkit.org/show_bug.cgi?id=228776

Reviewed by Saam Barati.

The problem (rdar://81434487) reports that Zoom turns to a black screen during the video
meeting on Safari. The reproduction of this problem is verified and bisected to the previous patch
(https://bugs.webkit.org/show_bug.cgi?id=228057). Previously, we introduce a pattern
matching for instruction EON-with-shift on ARM64, where the pattern is d = n ((m ShiftType amount) -1).

x = m ShiftType amount
y = x -1
z = n
y

We check canBeInternal() on x but not on y based on the computing cost analysis in that patch,
which is totally wrong. If the pattern matching is triggered, then the compiler would not emit
the corresponding Air of x after lowering, leading to data corruption or system crash since y
depends on x.

In the real world example (Zoom video meeting), we find the B3 IR:

...
Int32 b@528 = SShr(b@526, $31(b@527), Wasm: {opcode: I32ShrS, location: 0x26b})
Int32 b@529 = BitXor(b@528, $-1(b@144), Wasm: {opcode: I32Xor, location: 0x26e})
...
Int32 b@551 = BitXor(b@446, b@529, Wasm: {opcode: I32Xor, location: 0x28e})
...

After Lowering to Air:

...
Not32 %fp, %x2, b@529
...
XorNotRightShift32 %tmp199, %tmp211, $31, %tmp209, b@551
...

Since the implementation of the previous patch does commitInternal() on b@528, the operand of
b@529 turns to a frame pointer. To resolve this problem, we should either check canBeInternal()
on both b@528 and b@529 or not at all.

  • b3/B3LowerToAir.cpp:

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

11:03 AM Changeset in webkit [280700] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

Document::isLayoutTimerActive should read isLayoutPending
https://bugs.webkit.org/show_bug.cgi?id=228835

Reviewed by Antti Koivisto.

Callers of this function curious about whether there's a layout scheduled.

  • dom/Document.cpp:

(WebCore::Document::isLayoutPending const):
(WebCore::Document::isLayoutTimerActive const): Deleted.

  • dom/Document.h:
  • html/parser/HTMLParserScheduler.cpp:

(WebCore::HTMLParserScheduler::continueNextChunkTimerFired):

10:18 AM Changeset in webkit [280699] by youenn@apple.com
  • 2 edits in trunk/Source/WebKit

GPUProcessProxy should send tccd mach lookup sandbox extension
https://bugs.webkit.org/show_bug.cgi?id=228827

Reviewed by Per Arne Vollan.

In https://bugs.webkit.org/show_bug.cgi?id=225319, I mistakenly moved from mach lookup extension to generic extension.
Reverting that change.

  • UIProcess/GPU/GPUProcessProxy.cpp:

(WebKit::addTCCDSandboxExtension):

10:05 AM Changeset in webkit [280698] by eric.carlson@apple.com
  • 3 edits in trunk/Source/WebKit

[GPUP] RemoteAudioSessionProxyManager should use the shared audio session
https://bugs.webkit.org/show_bug.cgi?id=228795
<rdar://problem/81530450>

Reviewed by Jer Noble.

RemoteAudioSessionProxyManager creates and uses a private AudioSession, which means
that any code that moves from the WebProcess to the GPUProcess and uses
AudioSession::sharedSession will be using a separate platform audio session wrapper
object. RemoteAudioSessionProxyManager doesn't need a private AudioSession, so
change it to use AudioSession::sharedSession.

  • GPUProcess/media/RemoteAudioSessionProxyManager.cpp:

(WebKit::RemoteAudioSessionProxyManager::RemoteAudioSessionProxyManager): Don't
create a new AudioSession.
(WebKit::RemoteAudioSessionProxyManager::~RemoteAudioSessionProxyManager): Use
AudioSession::sharedSession().
(WebKit::RemoteAudioSessionProxyManager::updateCategory): Ditto.
(WebKit::RemoteAudioSessionProxyManager::setPreferredBufferSizeForProcess): Ditto.
(WebKit::RemoteAudioSessionProxyManager::tryToSetActiveForProcess): Ditto.

9:44 AM Changeset in webkit [280697] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Suppress more -Wreturn-type warnings
https://bugs.webkit.org/show_bug.cgi?id=228831

Unreviewed.

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-08-05

  • platform/KeyboardScrollingAnimator.cpp:

(WebCore::KeyboardScrollingAnimator::keyboardScrollForKeyboardEvent const):

9:27 AM Changeset in webkit [280696] by Russell Epstein
  • 2 edits in branches/safari-612.1.27.0-branch/Source/WebKit

Cherry-pick r280652. rdar://problem/81568994

[GPUProcess] REGRESSION: A noticeable slow down when browsing Live Photos album on iCloud.com
https://bugs.webkit.org/show_bug.cgi?id=228673
<rdar://81353138>

Reviewed by Wenson Hsieh.

RemoteImageBufferProxy::flushDrawingContext() assumes a FlushContext item
is always appended to its DisplayList when it calls flushDrawingContextAsync()
and this is why it waits up to 3 seconds for the DidFlush message. But this
does not happen if the DisplayList of RemoteImageBufferProxy is empty.

In addition to checking whether the DisplayList is empty, we can check also
whether we do not have pending a FlushContext item before appending a new
one.

  • WebProcess/GPU/graphics/RemoteImageBufferProxy.h:

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

9:26 AM Changeset in webkit [280695] by Russell Epstein
  • 2 edits in branches/safari-612.1.27.0-branch/Source/WebCore

Cherry-pick r280648. rdar://problem/81568979

REGRESSION(?): subtitle text sizing is sometimes inconsistent
https://bugs.webkit.org/show_bug.cgi?id=228786
<rdar://problem/80525509>

Reviewed by Eric Carlson.

Tested manually. I'm still not 100% sure of the root cause of this, but after talking with
some folks more familiar with WebKit's media "stack" it seems like this only happens with
in-band non-VTT subtitle tracks that have their own styling. The fix is also pretty obvious.

  • html/track/TextTrackCueGeneric.cpp: (WebCore::TextTrackCueGeneric::setFontSize): We should still pass along the new font size (and bool important) even if we don't have a display tree yet, as the font size (and bool important) are used when the display tree is created, meaning that we shouldn't have to wait for another setFontSize call after the display tree is created in order to update the font size.

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

9:26 AM Changeset in webkit [280694] by Russell Epstein
  • 3 edits in branches/safari-612.1.27.0-branch/Source/WebKit

Cherry-pick r280639. rdar://problem/81568951

[GPU Process] REGRESSION: iCloud Photos Web app may crash WebProcess once the GPUProcess is relaunched
https://bugs.webkit.org/show_bug.cgi?id=228665

Reviewed by Simon Fraser.

When the GPUProcess is relaunched, ensure NativeImage is detached from
the RemoteResourceCacheProxy once it is removed from its m_nativeImages.

Otherwise the NativeImage later will ask RemoteResourceCacheProxy to
release its corresponding NativeImage from RemoteResourceCache even
though it was destroyed when the GPUProcess was relaunched.

  • WebProcess/GPU/graphics/RemoteResourceCacheProxy.cpp: (WebKit::RemoteResourceCacheProxy::~RemoteResourceCacheProxy): (WebKit::RemoteResourceCacheProxy::clearNativeImageMap): (WebKit::RemoteResourceCacheProxy::remoteResourceCacheWasDestroyed):
  • WebProcess/GPU/graphics/RemoteResourceCacheProxy.h:

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

9:26 AM Changeset in webkit [280693] by Russell Epstein
  • 2 edits in branches/safari-612.1.27.0-branch/Source/WebCore

Cherry-pick r280623. rdar://problem/81517664

Null check self.session after calling _cancel instead of before
https://bugs.webkit.org/show_bug.cgi?id=228757
<rdar://79224868>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-08-03
Reviewed by Geoffrey Garen.

_cancel already null checks self.session before using it.
It seems to be setting self.session to null after the null check, so move the null check to before we use it.
This should fix an occasional crash during teardown.

  • platform/network/cocoa/WebCoreNSURLSession.mm: (-[WebCoreNSURLSessionDataTask _restart]):

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

9:26 AM Changeset in webkit [280692] by Russell Epstein
  • 2 edits in branches/safari-612.1.27.0-branch/Source/WebKit

Cherry-pick r280606. rdar://problem/81475582

[iOS] Fix sandbox violation in GPU process
https://bugs.webkit.org/show_bug.cgi?id=228743
<rdar://problem/81334849>

Reviewed by Brent Fulgham.

Allow reading "hw.product" in the GPU process' sandbox.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.GPU.sb:

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

9:23 AM Changeset in webkit [280691] by Robert Jenner
  • 1 edit
    2 adds in trunk/LayoutTests

( Rebaseline) [ iOS ] fast/forms/ios/inputmode-none.html is a constant failure
https://bugs.webkit.org/show_bug.cgi?id=228200

Uneviewed test gardening.

  • platform/ios/fast/forms/ios/inputmode-none-expected.txt: Added.
9:03 AM Changeset in webkit [280690] by Wenson Hsieh
  • 3 edits in trunk/Source/WebKit

[macOS Monterey] Translate popover becomes detached from webpage after scrolling
https://bugs.webkit.org/show_bug.cgi?id=228807
rdar://81540115

Reviewed by Sam Weinig.

Close the context menu translation popover in WebViewImpl::dismissContentRelativeChildWindowsFromViewOnly
(along with all other content-relative UI) to prevent the popover from being detached from its translated text
upon scrolling or zooming.

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

(WebKit::WebViewImpl::dismissContentRelativeChildWindowsFromViewOnly):
(WebKit::WebViewImpl::handleContextMenuTranslation):

Save a weak pointer to the current translation popover when we're about to present it, and use it to force the
popover to -close when dismissing content-relative child windows. Also take this opportunity to remove some
staging declarations on LTUITranslationViewController that have long since landed in the macOS 12 SDK.

8:27 AM Changeset in webkit [280689] by commit-queue@webkit.org
  • 16 edits in trunk

GCC 11 builds should use -Wno-array-bounds, -Wno-nonnull
https://bugs.webkit.org/show_bug.cgi?id=228601

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-08-05
Reviewed by Carlos Garcia Campos.

.:

Prior to GCC 11, these were good warnings that could catch serious errors. But GCC 11 has
just become too sensitive and it's flagging what appear to be harmless cases, and not
providing enough feedback to know why. This has resulted in me littering our code with
pragmas to suppress GCC's false positives, and I think it's reached the point where it's
nicer to just turn off the warnings until such time that GCC gets this under control, and
rely on Clang instead in the meantime.

The GCC developers have indicated that these warnings will *always* produce false positives
in some circumstances, but with GCC 11 it's just too become too much IMO.

  • Source/cmake/WebKitCompilerFlags.cmake:

Source/JavaScriptCore:

  • b3/air/AirAllocateRegistersByGraphColoring.cpp:
  • jit/JITCall.cpp:

(JSC::JIT::compileOpCall):

Source/WebCore:

  • css/CSSValue.h:

(WebCore::CSSValue::deref):

  • css/StyleRule.h:

(WebCore::StyleRuleBase::deref const):

  • dom/Node.h:

(WebCore::Node::deref const):

Source/WebKit:

  • WebProcess/Plugins/PluginView.cpp:

(WebKit::PluginView::Stream::~Stream):

Source/WTF:

  • wtf/Bitmap.h:

(WTF::WordType>::clear):

  • wtf/Compiler.h:
  • wtf/Packed.h:

(WTF::PackedAlignedPtr::get const):

  • wtf/RefPtr.h:

(WTF::DefaultRefDerefTraits::derefIfNotNull):

8:26 AM Changeset in webkit [280688] by ntim@apple.com
  • 2 edits
    10 adds in trunk/LayoutTests/imported/w3c

Re-import html/semantics/interactive-elements/the-dialog-element WPT
https://bugs.webkit.org/show_bug.cgi?id=228822

Unreviewed.

Upstream commit: https://github.com/web-platform-tests/wpt/commit/1fa1d40a251a1a9e506caec3fdfba5fe2c7ef6f6

  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-events-expected.txt: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-events.html: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-preventDefault-expected.txt: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-preventDefault.html: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-input-expected.txt: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-input.html: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-select-expected.txt: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-cancel-with-select.html: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-keydown-preventDefault-expected.txt: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/dialog-keydown-preventDefault.html: Added.
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/w3c-import.log:
8:14 AM Changeset in webkit [280687] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

Use reinterpret_cast_ptr in KeywordLookupGenerator, PropertyMapHashTable
https://bugs.webkit.org/show_bug.cgi?id=228819

Patch by Zan Dobersek <zdobersek@igalia.com> on 2021-08-05
Reviewed by Adrian Perez de Castro.

Switch to using reinterpret_cast_ptr in KeywordLookupGenerator (which
generates the KeywordLookup.h header) and PropertyMapHashTable, reducing
a bit the GCC warning spewage when compiling for targets benefitting
from the reinterpret_cast_ptr workaround.

  • KeywordLookupGenerator.py:
  • runtime/PropertyMapHashTable.h:

(JSC::PropertyTable::table):
(JSC::PropertyTable::table const):

8:02 AM Changeset in webkit [280686] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Fix warning in HTTPParsers.parseStructuredFieldValue
https://bugs.webkit.org/show_bug.cgi?id=228815

Patch by Rob Buis <rbuis@igalia.com> on 2021-08-05
Reviewed by Sam Weinig.

UChar is unsigned, so it is not needed to check that it is
zewro or greater.

  • platform/network/HTTPParsers.cpp:

(WebCore::parseStructuredFieldValue):

7:34 AM Changeset in webkit [280685] by Adrian Perez de Castro
  • 2 edits in trunk/Tools/buildstream

[Flatpak SDK] Update libwpe to 1.11.1
https://bugs.webkit.org/show_bug.cgi?id=228793

Reviewed by Alejandro G. Castro.

  • elements/sdk/libwpe.bst: Bump to version 1.11.1, which includes the

new fullscreen API support.

7:13 AM Changeset in webkit [280684] by aboya@igalia.com
  • 2 edits in trunk/LayoutTests

Unreviewed GStreamer MSE microgardening
https://bugs.webkit.org/show_bug.cgi?id=228823

  • platform/glib/TestExpectations:
5:57 AM Changeset in webkit [280683] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

Avoid reinterpret_cast alignment increase warnings with GCC on CPU(RISCV64)
https://bugs.webkit.org/show_bug.cgi?id=228818

Patch by Zan Dobersek <zdobersek@igalia.com> on 2021-08-05
Reviewed by Adrian Perez de Castro.

  • wtf/StdLibExtras.h: As with 32-bit ARM and MIPS targets, RISC-V 64-bit

builds with GCC also spawn warnings when the use of reinterpret_cast
causes an increase in alignment. Workaround via reinterpret_cast_ptr is
thus required for CPU(RISCV64).

5:25 AM Changeset in webkit [280682] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

run-jsc-stress-tests: detect the riscv64 architecture
https://bugs.webkit.org/show_bug.cgi?id=228817

Patch by Zan Dobersek <zdobersek@igalia.com> on 2021-08-05
Reviewed by Adrian Perez de Castro.

  • Scripts/run-jsc-stress-tests: Detect the riscv64 architecture when

examining ELF binaries. For the moment, this architecture should be
marked as not supporting FTL.

12:40 AM Changeset in webkit [280681] by imanol
  • 6 edits in trunk/Source

Fix XR related clang warnings in WPE
https://bugs.webkit.org/show_bug.cgi?id=228779

Reviewed by Sam Weinig.

Fix a few compiler warnings.

Source/WebCore:

  • platform/xr/openxr/OpenXRInputSource.cpp:

(PlatformXR::OpenXRInputSource::getButton const):

  • platform/xr/openxr/OpenXRSwapchain.cpp:

(PlatformXR::OpenXRSwapchain::create):
(PlatformXR::OpenXRSwapchain::OpenXRSwapchain):
(PlatformXR::OpenXRSwapchain::acquireImage):

  • platform/xr/openxr/OpenXRSwapchain.h:

Source/WebKit:

  • Shared/XR/XRDeviceProxy.cpp:

(WebKit::XRDeviceProxy::views const):

Aug 4, 2021:

8:31 PM Changeset in webkit [280680] by Wenson Hsieh
  • 3 edits in trunk/LayoutTests

Adjust editing/deleting/ios/backspace-last-character.html to check that pressing backspace deletes one character
https://bugs.webkit.org/show_bug.cgi?id=228806

Reviewed by Tim Horton.

Add test coverage for r280671 by augmenting an existing iOS editing test to verify that hitting backspace only
deletes a single character in a textarea.

  • editing/deleting/ios/backspace-last-character-expected.txt:
  • editing/deleting/ios/backspace-last-character.html:
8:15 PM Changeset in webkit [280679] by Diego Pino Garcia
  • 23 edits
    9 adds in trunk/LayoutTests

[WPE] Unreviewed test gardening. Update baselines after r280672.

  • platform/glib/fast/selectors/unqualified-hover-strict-expected.txt:
  • platform/glib/imported/w3c/web-platform-tests/html/dom/idlharness.worker-expected.txt:
  • platform/glib/imported/w3c/web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-expected.txt:
  • platform/glib/media/video-playing-and-pause-expected.png:
  • platform/glib/media/video-playing-and-pause-expected.txt:
  • platform/glib/tables/mozilla/core/col_span-expected.txt:
  • platform/wpe/fast/selectors/unqualified-hover-strict-expected.png: Added.
  • platform/wpe/fast/text/text-letter-spacing-expected.png: Added.
  • platform/wpe/fast/text/text-letter-spacing-expected.txt:
  • platform/wpe/fast/text/wbr-expected.png: Added.
  • platform/wpe/fast/text/wbr-expected.txt:
  • platform/wpe/fast/text/whitespace/span-in-word-space-causes-overflow-expected.png: Added.
  • platform/wpe/fast/text/whitespace/span-in-word-space-causes-overflow-expected.txt:
  • platform/wpe/fast/text/word-break-expected.txt:
  • platform/wpe/http/wpt/webxr/xrSession_end_device_reports_shutdown.https-expected.txt:
  • platform/wpe/http/wpt/webxr/xrSession_ended_by_system.https-expected.txt:
  • platform/wpe/http/wpt/webxr/xrSession_reject_multiple_end.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/css/css-color-adjust/inheritance-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/css/cssom/cssstyledeclaration-csstext-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/css/cssom/getComputedStyle-detached-subtree-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/css/mediaqueries/test_media_queries-expected.txt: Added.
  • platform/wpe/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/webxr/render_state_vertical_fov_inline.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/webxr/xrFrame_lifetime.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/webxr/xrPose_transform_sameObject.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/webxr/xrStationaryReferenceSpace_floorlevel_updates.https-expected.txt:
  • platform/wpe/tables/mozilla/core/col_span-expected.png: Added.
  • platform/wpe/tables/mozilla/marvin/x_col_width_rel-expected.png: Added.
  • platform/wpe/tables/mozilla/marvin/x_col_width_rel-expected.txt:
  • platform/wpe/tables/mozilla/marvin/x_colgroup_width_rel-expected.png: Added.
  • platform/wpe/tables/mozilla/marvin/x_colgroup_width_rel-expected.txt:
  • platform/wpe/tables/mozilla/other/ms-expected.txt:
7:53 PM Changeset in webkit [280678] by commit-queue@webkit.org
  • 7 edits in trunk/LayoutTests

LayoutTests/imported/w3c:
Update some WPT baselines after recent improvements.
https://bugs.webkit.org/show_bug.cgi?id=228804

Unreviewed test gardening. Update baseline after r279978.
This test is already marked as flaky on mac and iOS.

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-08-04

  • web-platform-tests/html/semantics/embedded-content/media-elements/error-codes/error-expected.txt:

LayoutTests:
[GLIB] Update some WPT baselines after recent improvements.
https://bugs.webkit.org/show_bug.cgi?id=228804

Update WPT test baselines after r279971, r279978, r279979, and r280310
to account for more passing tests.
Unreviewed test gardening.

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-08-04

  • platform/glib/imported/w3c/web-platform-tests/html/dom/idlharness.worker-expected.txt:
  • platform/glib/imported/w3c/web-platform-tests/mathml/relations/html5-tree/math-global-event-handlers.tentative-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
7:52 PM Changeset in webkit [280677] by Darin Adler
  • 3 edits in trunk/Source/WebCore

Change WebSocket.cpp to @no-unify, since it’s hard to do that for someone without a Mac
https://bugs.webkit.org/show_bug.cgi?id=228808

Reviewed by Anders Carlsson.

  • Sources.txt: Add @no-unify.
  • WebCore.xcodeproj/project.pbxproj: Add WebSocket.cpp to the WebCore target.
7:46 PM Changeset in webkit [280676] by Devin Rousso
  • 3 edits in trunk/Source/WebCore

REGRESSION (r280374): ASSERTION FAILED: Completion handler should not be called more than once under WebCore::MediaControlsContextMenuProvider::contextMenuItemSelected
https://bugs.webkit.org/show_bug.cgi?id=228725
<rdar://problem/81437221>

Reviewed by Eric Carlson.

The contextmenu system used by (modern) media controls are a bit wonky in that it has to
support both macOS and iOS, which use wildly different mechanisms. The former has distinct
methods for handling when a contextmenu item is selected vs when the menu is dismissed (at
least as of r280374). The latter has a single method that handles both. Additionally, the
(modern) media controls JS expects the following from showMediaControlsContextMenu:

  1. showMediaControlsContextMenu will only return true if the contextmenu will be shown
  2. the callback provided to showMediaControlsContextMenu will always/only be invoked when the contextmenu is dismissed (regardless of whether an item is selected)
  3. if an item is selected, the logic for that will be handled by the MediaControlsHost

This patch primarily addresses #2, but also slightly adjusts the code to fix #1. It does #1
by moving the call that saves the callback further down. On iOS, #2 already works. On macOS,
it does #2 by changing from CompletionHandler to Function, allowing it to be called more
than once, with the understanding that the JS callback will not be invoked more than once.
This way, macOS can match the behavior of iOS by eagerly invoking the JS callback when a
contextmenu item is selected without waiting for the menu to actually dismiss, while still
handling the contextmenu being dismissed without an item being selected (and also not having
to worry about whether the CompletionHandler has already been invoked).

  • Modules/mediacontrols/MediaControlsHost.h:
  • Modules/mediacontrols/MediaControlsHost.cpp:

(WebCore::MediaControlsContextMenuProvider::create):
(WebCore::MediaControlsContextMenuProvider::MediaControlsContextMenuProvider):
(WebCore::MediaControlsContextMenuProvider::didDismissContextMenu):
(WebCore::MediaControlsContextMenuProvider::contextMenuCleared):
(WebCore::MediaControlsHost::showMediaControlsContextMenu):

7:15 PM Changeset in webkit [280675] by Alan Coon
  • 1 copy in tags/Safari-612.1.26.1.3

Tag Safari-612.1.26.1.3.

7:05 PM Changeset in webkit [280674] by Alan Coon
  • 8 edits in branches/safari-612.1.26.1-branch/Source

Versioning.

WebKit-7612.1.26.1.3

6:32 PM Changeset in webkit [280673] by Alan Coon
  • 1 copy in tags/Safari-612.1.26.1.2

Tag Safari-612.1.26.1.2.

4:55 PM Changeset in webkit [280672] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

Bifurcated RemoteLayerBackingStore zooms in every time it repaints
https://bugs.webkit.org/show_bug.cgi?id=228798

Reviewed by Sam Weinig.

  • Shared/RemoteLayerTree/RemoteLayerBackingStore.mm:

(WebKit::RemoteLayerBackingStore::display):
If applying the scale/flip workaround manually, we need to save the
GraphicsContext state, or it leaks between paints.

4:53 PM Changeset in webkit [280671] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

REGRESSION (r280492): Clicking backspace on sign in fields results in deleting two characters instead of one.
https://bugs.webkit.org/show_bug.cgi?id=228802

Patch by Dana Estra <destra@apple.com> on 2021-08-04
Reviewed by Tim Horton.

No tests yet.

  • page/EventHandler.cpp:

(WebCore::EventHandler::defaultKeyboardEventHandler):

4:47 PM Changeset in webkit [280670] by Jean-Yves Avenard
  • 5 edits in trunk/Source/WebKit

Use Observer in place of VideoFullscreenManagerProxyClient
https://bugs.webkit.org/show_bug.cgi?id=228761
rdar://problem/81489026

Reviewed by Jer Noble.

Use an Observer member rather than creating a child class that would be used
when the PiP state change. This prevents having to deal with lifetime and
potentially setting it up multiple times.
No change in observable behaviour, covered with existing tests.

  • UIProcess/Cocoa/VideoFullscreenManagerProxy.h: Remove VideoFullscreenManagerProxyClient

class. Use WeakHashSet to store observers.

  • UIProcess/Cocoa/VideoFullscreenManagerProxy.mm:

(WebKit::VideoFullscreenManagerProxy::addVideoInPictureInPictureDidChangeObserver):
Method added, replace older setClient
(WebKit::VideoFullscreenManagerProxy::hasVideoInPictureInPictureDidChange):
Iterate over all observers and call accordingly.

  • UIProcess/ios/fullscreen/WKFullScreenWindowControllerIOS.mm:

(-[WKFullScreenWindowController initWithWebView:]): Remove no longer necessary
code.
(-[WKFullScreenWindowController dealloc]): Remove no longer necessary
code.
(-[WKFullScreenWindowController beganEnterFullScreenWithInitialFrame:finalFrame:]):
set PiP change observer if none already exists.

  • UIProcess/mac/WKFullScreenWindowController.mm:

(-[WKFullScreenWindowController initWithWindow:webView:page:]): Remove no longer necessary
code.
(-[WKFullScreenWindowController dealloc]): Remove no longer necessary
code.
(-[WKFullScreenWindowController clearVideoFullscreenManagerObserver]):
(-[WKFullScreenWindowController setVideoFullscreenManagerObserver]):
(-[WKFullScreenWindowController didExitPictureInPicture]):
(-[WKFullScreenWindowController windowDidEnterFullScreen:]):
(-[WKFullScreenWindowController windowDidFailToExitFullScreen:]):
(-[WKFullScreenWindowController windowDidExitFullScreen:]):

4:08 PM Changeset in webkit [280669] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

RemoteLayerBackingStore: Adopt a new bifurcated layer switch
https://bugs.webkit.org/show_bug.cgi?id=228800
<rdar://problem/81534641>

Reviewed by Sam Weinig.

  • Shared/RemoteLayerTree/RemoteLayerBackingStore.mm:

(WebKit::RemoteLayerBackingStore::applyBackingStoreToLayer):
Let CA know that we're going to hand it both a display list and
backing store ahead of time by setting a new bit.

3:53 PM Changeset in webkit [280668] by fpizlo@apple.com
  • 4 edits in trunk/Source/bmalloc

[libpas] medium size class lookup needs to correctly fence the counting lock read path
https://bugs.webkit.org/show_bug.cgi?id=228799

Reviewed by Tadeu Zagallo.

The medium size class lookup does a binary search on a data structure that may mutate; we
catch that using a counting lock. But the algorithm wasn't fencing the tail end; it's supposed
to reread the count at the end but that read was not fenced.

This adds the fencing using pas_depend. I confirmed that the disassembly does the right thing.
It adds very little code.

Also rebased a test. Libpas tests are very specific about memory usage in some cases, and so
sometimes you will encounter a test run that requires limits to be adjusted. This happens
because some tests can sometimes create very complex heap layouts that really do use more
memory than we asserted, but the assertion had always worked because the test never ran with
the "wrong" kind of layout. This fixes a one-off test failure I saw when debugging this fix.

  • libpas/src/libpas/pas_mutation_count.h:

(pas_mutation_count_matches_with_dependency):
(pas_mutation_count_matches): Deleted.

  • libpas/src/libpas/pas_segregated_heap.c:

(medium_directory_tuple_for_index_impl):
(medium_directory_tuple_for_index_with_lock):
(pas_segregated_heap_medium_directory_tuple_for_index):

  • libpas/src/test/ThingyAndUtilityHeapAllocationTests.cpp:

(std::addLargeHeapTests):

3:24 PM Changeset in webkit [280667] by Ayumi Kojima
  • 2 edits in trunk/LayoutTests

[ MacOS wk1 Release ] media/video-page-visibility-restriction.html is flaky timing out.
https://bugs.webkit.org/show_bug.cgi?id=228801

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
3:10 PM Changeset in webkit [280666] by Robert Jenner
  • 2 edits in trunk/LayoutTests

REGRESSION: [ BigSur wk2 rosetta ] compositing/contents-scale/hidpi-compositing-layer-positioned-on-scaled-context.html is a flaky failure
<rdar://68957822>

Uneviewed test expectation removal.

  • platform/mac/TestExpectationsRosetta:
2:54 PM Changeset in webkit [280665] by Alan Coon
  • 8 edits in branches/safari-612.1.26.1-branch/Source

Versioning.

WebKit-7612.1.26.1.2

2:36 PM Changeset in webkit [280664] by Peng Liu
  • 18 edits in trunk

[Catalina][GPUP] Some API tests fail after GPU Process features are enabled
https://bugs.webkit.org/show_bug.cgi?id=228589

Reviewed by Jer Noble.

Source/WebCore:

When "Media in GPU Process" is enabled, AudioSession[IOS|Mac] runs in
the GPU process. HTMLMediaElement, which is an observer of audio session,
runs in a WebContent process. It cannot get its AudioSession's configuration
directly. We need a mechanism to "push" the latest audio session configuration
from the GPU process to the WebContent process.

This patch replaces the MutedStateObserver with an audio session configuration
change observer interface, so that an audio session will notify its observers
after changing its configurations, including buffer size, muted state, sample rate.
Currently, this observer interface is used on macOS only.

No new tests. Fix an API test failure.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::initializeMediaSession):
(WebCore::HTMLMediaElement::~HTMLMediaElement):
(WebCore::HTMLMediaElement::hardwareMutedStateDidChange):

  • html/HTMLMediaElement.h:
  • platform/audio/AudioSession.cpp:

(WebCore::AudioSession::addConfigurationChangeObserver):
(WebCore::AudioSession::removeConfigurationChangeObserver):

  • platform/audio/AudioSession.h:
  • platform/audio/ios/AudioSessionIOS.h:

Move m_interruptionObservers to this class because only AudioSessionIOS
supports interruption observers.

  • platform/audio/mac/AudioSessionMac.h:
  • platform/audio/mac/AudioSessionMac.mm:

(WebCore::AudioSessionMac::handleSampleRateChange):
(WebCore::AudioSessionMac::handleSampleRateChange const):
(WebCore::AudioSessionMac::handleBufferSizeChange):
(WebCore::AudioSessionMac::handleBufferSizeChange const):
(WebCore::AudioSessionMac::sampleRate const):
(WebCore::AudioSessionMac::setPreferredBufferSize):
(WebCore::AudioSessionMac::handleMutedStateChange):
(WebCore::AudioSessionMac::addConfigurationChangeObserver):
(WebCore::AudioSessionMac::removeConfigurationChangeObserver):
(WebCore::AudioSessionMac::addMutedStateObserver): Deleted.
(WebCore::AudioSessionMac::removeMutedStateObserver): Deleted.

Source/WebKit:

When an audio session's configuration changes, let RemoteAudioSessionProxy
in the GPU process send the latest audio session configuration to RemoteAudioSession
in the WebContent process through an IPC message (RemoteAudioSession::ConfigurationChanged).

  • GPUProcess/media/RemoteAudioSessionProxy.cpp:

(WebKit::RemoteAudioSessionProxy::configurationChanged):

  • GPUProcess/media/RemoteAudioSessionProxy.h:
  • GPUProcess/media/RemoteAudioSessionProxyManager.cpp:

(WebKit::RemoteAudioSessionProxyManager::RemoteAudioSessionProxyManager):
(WebKit::RemoteAudioSessionProxyManager::~RemoteAudioSessionProxyManager):
(WebKit::RemoteAudioSessionProxyManager::beginAudioSessionInterruption):
(WebKit::RemoteAudioSessionProxyManager::endAudioSessionInterruption):
(WebKit::RemoteAudioSessionProxyManager::hardwareMutedStateDidChange):
(WebKit::RemoteAudioSessionProxyManager::bufferSizeDidChange):
(WebKit::RemoteAudioSessionProxyManager::sampleRateDidChange):
(WebKit::RemoteAudioSessionProxyManager::configurationDidChange):

  • GPUProcess/media/RemoteAudioSessionProxyManager.h:
  • WebProcess/GPU/media/RemoteAudioSession.cpp:

(WebKit::RemoteAudioSession::addConfigurationChangeObserver):
(WebKit::RemoteAudioSession::removeConfigurationChangeObserver):
(WebKit::RemoteAudioSession::configurationChanged):

  • WebProcess/GPU/media/RemoteAudioSession.h:
  • WebProcess/GPU/media/RemoteAudioSession.messages.in:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/AudioBufferSize.mm:

(TestWebKitAPI::TEST):

2:29 PM Changeset in webkit [280663] by Jonathan Bedard
  • 5 edits in trunk/Tools

[check-github-mirror-integrity] Store remote cache in checkout
https://bugs.webkit.org/show_bug.cgi?id=228792
<rdar://problem/81527357>

Reviewed by Aakash Jain.

  • Scripts/check-github-mirror-integrity: Use the local checkout to store the svn.webkit.org, if possible.
  • Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Scripts/libraries/webkitscmpy/webkitscmpy/remote/svn.py:

(Svn.init): Allow caller to define cache path.
(Svn._cache_path): Deleted.

2:22 PM Changeset in webkit [280662] by Russell Epstein
  • 8 edits in branches/safari-612.1.27.0-branch/Source

Versioning.

WebKit-7612.1.27.0.1

2:19 PM Changeset in webkit [280661] by Russell Epstein
  • 1 copy in branches/safari-612.1.27.2-branch

New branch.

2:18 PM Changeset in webkit [280660] by Russell Epstein
  • 1 copy in branches/safari-612.1.27.3-branch

New branch.

2:17 PM Changeset in webkit [280659] by Yijia Huang
  • 2 edits in trunk/Source/JavaScriptCore

[ARM64] Fix Zoom black screen during video meeting on Safari
https://bugs.webkit.org/show_bug.cgi?id=228776

Reviewed by Saam Barati.

The problem (rdar://81434487) reports that Zoom turns to a black screen during the video
meeting on Safari. The reproduction of this problem is verified and bisected to the previous patch
(https://bugs.webkit.org/show_bug.cgi?id=228057). Previously, we introduce a pattern
matching for instruction EON-with-shift on ARM64, where the pattern is d = n ((m ShiftType amount) -1).

x = m ShiftType amount
y = x -1
z = n
y

We check canBeInternal() on x but not on y based on the computing cost analysis in that patch,
which is totally wrong. If the pattern matching is triggered, then the compiler would not emit
the corresponding Air of x after lowering, leading to data corruption or system crash since y
depends on x.

In the real world example (Zoom video meeting), we find the B3 IR:

...
Int32 b@528 = SShr(b@526, $31(b@527), Wasm: {opcode: I32ShrS, location: 0x26b})
Int32 b@529 = BitXor(b@528, $-1(b@144), Wasm: {opcode: I32Xor, location: 0x26e})
...
Int32 b@551 = BitXor(b@446, b@529, Wasm: {opcode: I32Xor, location: 0x28e})
...

After Lowering to Air:

...
Not32 %fp, %x2, b@529
...
XorNotRightShift32 %tmp199, %tmp211, $31, %tmp209, b@551
...

Since the implementation of the previous patch does commitInternal() on b@528, the operand of
b@529 turns to a frame pointer. To resolve this problem, we should either check canBeInternal()
on both b@528 and b@529 or not at all.

  • b3/B3LowerToAir.cpp:
2:06 PM Changeset in webkit [280658] by Russell Epstein
  • 1 copy in branches/safari-612.1.27.0-branch

New branch.

2:03 PM Changeset in webkit [280657] by Russell Epstein
  • 1 copy in tags/Safari-612.1.27

Tag Safari-612.1.27.

1:54 PM Changeset in webkit [280656] by Ayumi Kojima
  • 2 edits in trunk/LayoutTests

[ MacOS ] webaudio/silent-audio-interrupted-in-background.html is flaky timing out.
https://bugs.webkit.org/show_bug.cgi?id=228796

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
1:44 PM Changeset in webkit [280655] by Jonathan Bedard
  • 2 edits in trunk/Tools

[check-github-mirror-integrity] Compare current time to canonical time
https://bugs.webkit.org/show_bug.cgi?id=228787
<rdar://problem/81524499>

Reviewed by Aakash Jain.

  • Scripts/check-github-mirror-integrity: If the mirror isn't in line with the canonical repository, we should

check against the current time, not the time of last commit on the mirror.

1:28 PM Changeset in webkit [280654] by magomez@igalia.com
  • 2 edits in trunk/Source/WebCore

[GTK][WPE] Elliptic radial gradients are not working
https://bugs.webkit.org/show_bug.cgi?id=228771

Reviewed by Žan Doberšek.

Transform the radial circular gradients using the aspect ratio to convert
them into the appropriate elliptic gradients.

  • platform/graphics/cairo/GradientCairo.cpp:

(WebCore::Gradient::createPattern):

1:20 PM Changeset in webkit [280653] by Simon Fraser
  • 2 edits in trunk/Source/WebKit

Crash in DisplayLink::notifyObserversDisplayWasRefreshed() on macOS
https://bugs.webkit.org/show_bug.cgi?id=228790
<rdar://81338621>

Reviewed by Tim Horton.

Defend against DisplayLink::nominalFramesPerSecondFromDisplayLink() returning zero,
which can result in a later divide by zero in m_currentUpdate.nextUpdate().

  • UIProcess/mac/DisplayLink.cpp:

(WebKit::DisplayLink::nominalFramesPerSecondFromDisplayLink):

12:43 PM Changeset in webkit [280652] by Said Abou-Hallawa
  • 2 edits in trunk/Source/WebKit

[GPUProcess] REGRESSION: A noticeable slow down when browsing Live Photos album on iCloud.com
https://bugs.webkit.org/show_bug.cgi?id=228673
<rdar://81353138>

Reviewed by Wenson Hsieh.

RemoteImageBufferProxy::flushDrawingContext() assumes a FlushContext item
is always appended to its DisplayList when it calls flushDrawingContextAsync()
and this is why it waits up to 3 seconds for the DidFlush message. But this
does not happen if the DisplayList of RemoteImageBufferProxy is empty.

In addition to checking whether the DisplayList is empty, we can check also
whether we do not have pending a FlushContext item before appending a new
one.

  • WebProcess/GPU/graphics/RemoteImageBufferProxy.h:
12:37 PM Changeset in webkit [280651] by mmaxfield@apple.com
  • 5 edits
    2 adds in trunk

[Cocoa] Tweak the formatting for passing NSArrays to TextStreams
https://bugs.webkit.org/show_bug.cgi?id=228766

Reviewed by Simon Fraser.

Source/WTF:

Instead of using -[NSArray description], which puts its output on multiple lines,
instead use the same formatting as WTF::Vector, which puts its output on a single line.

We can also use this opportunity to tweak the implementation of operator<<(id) to
allow it to be called with Core Foundation types in raw C++ code.

  • wtf/text/TextStream.h:
  • wtf/text/cocoa/TextStreamCocoa.mm:

(WTF::TextStream::operator<<):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WTF/cocoa/TextStreamCocoa.cpp: Added.

(TEST):

  • TestWebKitAPI/Tests/WTF/cocoa/TextStreamCocoa.mm: Added.

(TEST):

12:24 PM Changeset in webkit [280650] by commit-queue@webkit.org
  • 6 edits in trunk/Source/JavaScriptCore

Unreviewed, reverting r280609.
https://bugs.webkit.org/show_bug.cgi?id=228791

Broke JSC tests on iOS.

Reverted changeset:

"[ARM64] Use link register instead of pinning a register for
materializing big load constants"
https://bugs.webkit.org/show_bug.cgi?id=228710
https://commits.webkit.org/r280609

11:59 AM Changeset in webkit [280649] by Chris Dumez
  • 4 edits in trunk/LayoutTests

REGRESSION (r280541): [ BigSur Debug ] accessibility/roles-computedRoleString.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=228744
<rdar://problem/81472432>

Unreviewed, the test's JS was getting in some sort of infinite loop. Tweak the code a bit
so that it keeps running without infinite looping.

  • accessibility/roles-computedRoleString.html:
  • platform/mac/TestExpectations:
  • platform/mac/accessibility/roles-computedRoleString-expected.txt:
11:55 AM Changeset in webkit [280648] by Devin Rousso
  • 2 edits in trunk/Source/WebCore

REGRESSION(?): subtitle text sizing is sometimes inconsistent
https://bugs.webkit.org/show_bug.cgi?id=228786
<rdar://problem/80525509>

Reviewed by Eric Carlson.

Tested manually. I'm still not 100% sure of the root cause of this, but after talking with
some folks more familiar with WebKit's media "stack" it seems like this only happens with
in-band non-VTT subtitle tracks that have their own styling. The fix is also pretty obvious.

  • html/track/TextTrackCueGeneric.cpp:

(WebCore::TextTrackCueGeneric::setFontSize):
We should still pass along the new font size (and bool important) even if we don't have a
display tree yet, as the font size (and bool important) are used when the display tree is
created, meaning that we shouldn't have to wait for another setFontSize call after the
display tree is created in order to update the font size.

11:44 AM Changeset in webkit [280647] by Wenson Hsieh
  • 2 edits in trunk/Source/WebKit

[iOS 15] "Look Up" action is sometimes missing after force pressing images
https://bugs.webkit.org/show_bug.cgi?id=228774
rdar://78040734

Reviewed by Devin Rousso.

On iOS devices that support both 3D Touch and Visual Look Up (i.e., iPhone XS and iPhone XS Max), it's currently
possible to skip the image analysis preflight gesture entirely when showing the context menu over images in the
case where the user triggers the interaction by exceeding the force press threshold in under 100 ms (the current
delay of the image analysis long press gesture).

Mitigate this by teaching WKImageAnalysisGestureRecognizer to trigger image analysis preflight slightly ahead of
the context menu interaction when performing a force press by transitioning to Began state early under
-touchesBegan:withEvent: and -touchesMoved:withEvent:, if the touch's force exceeds a certain (relatively
low) threshold.

  • UIProcess/ios/WKImageAnalysisGestureRecognizer.mm:

(-[WKImageAnalysisGestureRecognizer touchesBegan:withEvent:]):
(-[WKImageAnalysisGestureRecognizer touchesMoved:withEvent:]):
(-[WKImageAnalysisGestureRecognizer beginAfterExceedingForceThresholdIfNeeded:]):

11:39 AM Changeset in webkit [280646] by commit-queue@webkit.org
  • 9 edits
    3 adds in trunk

Unreviewed, reverting r280630.
https://bugs.webkit.org/show_bug.cgi?id=228788

broke some downstream tests

Reverted changeset:

"fast/canvas/canvas-crash.html doesn't test what it intends to
on iOS"
https://bugs.webkit.org/show_bug.cgi?id=228747
https://commits.webkit.org/r280630

11:29 AM Changeset in webkit [280645] by commit-queue@webkit.org
  • 7 edits in trunk/LayoutTests

[GLIB] Unreviewed test gardening, update baselines after r280017
https://bugs.webkit.org/show_bug.cgi?id=228783

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-08-04

  • platform/glib/fast/multicol/client-rects-expected.txt:
  • platform/glib/fast/multicol/client-rects-spanners-complex-expected.txt:
  • platform/glib/fast/multicol/client-rects-spanners-expected.txt:
  • platform/glib/fast/multicol/newmulticol/client-rects-expected.txt:
  • platform/gtk/fast/multicol/client-rects-expected.png:
  • platform/gtk/fast/multicol/newmulticol/client-rects-expected.png:
11:28 AM Changeset in webkit [280644] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[macOS] Update message filters
https://bugs.webkit.org/show_bug.cgi?id=228773
<rdar://problem/81514311>

Reviewed by Brent Fulgham.

Update message filters with enforcement on macOS based on telemetry.

  • WebProcess/com.apple.WebProcess.sb.in:
11:02 AM Changeset in webkit [280643] by Antti Koivisto
  • 3 edits in trunk/Source/WebCore

Use fast malloc for RuleData vectors
https://bugs.webkit.org/show_bug.cgi?id=228770

Reviewed by Chris Dumez.

Revert the change that enabled probabilistic guard malloc as it is not needed anymore.

  • style/RuleFeature.h:
  • style/RuleSet.h:
11:01 AM Changeset in webkit [280642] by Russell Epstein
  • 10 edits
    2 deletes in branches/safari-612.1-branch/Source/WebCore

Revert r280492. rdar://problem/81522050

11:01 AM Changeset in webkit [280641] by Russell Epstein
  • 2 edits in branches/safari-612.1-branch/Source/WebCore

Revert r280501. rdar://problem/81522050

10:58 AM Changeset in webkit [280640] by Jonathan Bedard
  • 7 edits
    1 copy
    2 adds in trunk/Tools

[webkitcorepy] Add shared terminal input code
https://bugs.webkit.org/show_bug.cgi?id=226024
<rdar://problem/78261645>

Reviewed by Dewei Zhu.

  • Scripts/libraries/webkitcorepy/setup.py: Bump version.
  • Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Export Terminal object, bump version.
  • Scripts/libraries/webkitcorepy/webkitcorepy/credentials.py:

(credentials): Use Terminal.input.

  • Scripts/libraries/webkitcorepy/webkitcorepy/mocks/init.py:
  • Scripts/libraries/webkitcorepy/webkitcorepy/mocks/terminal.py: Added.

(Terminal):
(Terminal.input): Mocking input and raw_input requires so specialized knowledge,
so we should generalize it.

  • Scripts/libraries/webkitcorepy/webkitcorepy/terminal.py: Added.

(Terminal):
(Terminal.input): Python 2/3 compatible input function.
(Terminal.choose): Generic multiple-choice input prompt.

  • Scripts/libraries/webkitcorepy/webkitcorepy/tests/terminal_unittest.py: Added.

(TerminalTests):
(TerminalTests.test_choose_basic):
(TerminalTests.test_choose_strict):
(TerminalTests.test_choose_default):
(TerminalTests.test_choose_triple):
(TerminalTests.test_choose_number):

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

(User.prompt): Use Terminal.input.
(User.prompt_with_multiple_lists): Ditto.
(User.prompt_with_list): Ditto.
(User.confirm): Ditto.

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

(MockUser.prompt): Use Terminal.input.
(MockUser.prompt_with_list): Ditto.

10:43 AM Changeset in webkit [280639] by Said Abou-Hallawa
  • 3 edits in trunk/Source/WebKit

[GPU Process] REGRESSION: iCloud Photos Web app may crash WebProcess once the GPUProcess is relaunched
https://bugs.webkit.org/show_bug.cgi?id=228665

Reviewed by Simon Fraser.

When the GPUProcess is relaunched, ensure NativeImage is detached from
the RemoteResourceCacheProxy once it is removed from its m_nativeImages.

Otherwise the NativeImage later will ask RemoteResourceCacheProxy to
release its corresponding NativeImage from RemoteResourceCache even
though it was destroyed when the GPUProcess was relaunched.

  • WebProcess/GPU/graphics/RemoteResourceCacheProxy.cpp:

(WebKit::RemoteResourceCacheProxy::~RemoteResourceCacheProxy):
(WebKit::RemoteResourceCacheProxy::clearNativeImageMap):
(WebKit::RemoteResourceCacheProxy::remoteResourceCacheWasDestroyed):

  • WebProcess/GPU/graphics/RemoteResourceCacheProxy.h:
10:39 AM Changeset in webkit [280638] by Antti Koivisto
  • 3 edits in trunk/Source/WebCore

Reduce Vector<> wasted capacity in some RuleSet code
https://bugs.webkit.org/show_bug.cgi?id=224160
<rdar://problem/76369555>

Unreviewed, reverting revert r279242.

Reland as this was not related to the crashes seen.

  • style/RuleSet.cpp:

(WebCore::Style::RuleSet::addRulesFromSheet):
(WebCore::Style::RuleSet::evaluateDynamicMediaQueryRules):
(WebCore::Style::shrinkDynamicRules):
(WebCore::Style::RuleSet::shrinkToFit):

  • style/RuleSet.h:
10:33 AM Changeset in webkit [280637] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GLIB] Mark mhtml tests as flaky. Unreviewed test gardening.
https://bugs.webkit.org/show_bug.cgi?id=228778

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2021-08-04

  • platform/glib/TestExpectations:
9:46 AM Changeset in webkit [280636] by Ayumi Kojima
  • 2 edits in trunk/LayoutTests

[ BigSur Debug ] accessibility/roles-computedRoleString.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=228744

Unreviewed test gardening.

  • platform/mac/TestExpectations:
8:43 AM Changeset in webkit [280635] by Andres Gonzalez
  • 2 edits in trunk/Tools

Add contributor to accessibility watchlist.
https://bugs.webkit.org/show_bug.cgi?id=228775

Reviewed by Chris Fleizach.

  • Scripts/webkitpy/common/config/watchlist: Added Andres Gonzalez to accessibility watchlist.
8:37 AM Changeset in webkit [280634] by Ayumi Kojima
  • 3 edits in trunk/LayoutTests

Removed testexpectations from iPad and updated them in ios-wk2 for 3 editing/pasteboard/smart-paste-paragraph tests.
https://bugs.webkit.org/show_bug.cgi?id=228285

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
  • platform/ipad/TestExpectations:
7:04 AM Changeset in webkit [280633] by Andres Gonzalez
  • 8 edits
    2 adds in trunk

Add support for aria-selected value changes in table cells.
https://bugs.webkit.org/show_bug.cgi?id=228756
<rdar://problem/81483071>

Reviewed by Chris Fleizach.

Source/WebCore:

Test: accessibility/selected-state-changed-notifications.html

  • Added the AXSelectedStateChangedNotification to notify AX clients that

the selected state of an object has changed.

  • This notification is used in this patch for aria-selected value

changes in table cells.

  • accessibility/AXLogger.cpp:

(WebCore::operator<<):

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::selectedStateChanged):
(WebCore::AXObjectCache::handleAttributeChange):

  • accessibility/AXObjectCache.h:
  • accessibility/ios/AXObjectCacheIOS.mm:

(WebCore::AXObjectCache::notificationPlatformName):

  • accessibility/mac/AXObjectCacheMac.mm:

(WebCore::AXObjectCache::postPlatformNotification):

LayoutTests:

  • accessibility/selected-state-changed-notifications-expected.txt: Added.
  • accessibility/selected-state-changed-notifications.html: Added.
5:57 AM Changeset in webkit [280632] by Martin Robinson
  • 3 edits in trunk/Source/WebCore

Add a HashTraits implementation for LayoutUnit
https://bugs.webkit.org/show_bug.cgi?id=228630

Reviewed by Fujii Hironori.

No new tests. This should not change behavior in an easily-observable way, but
could prevent rare hashing problems in the future.

  • page/scrolling/ScrollSnapOffsetsInfo.cpp:

(WebCore::updateSnapOffsetsForScrollableArea): Use LayoutUnit as the hash, which avoids
and extra conversion to float.

  • platform/LayoutUnit.h: Add a HashTraits implementation for LayoutUnit.
3:57 AM Changeset in webkit [280631] by cathiechen
  • 5 edits in trunk

REGRESSION (r277997) Images get stretched with aspect-ratio and max-width: x%
https://bugs.webkit.org/show_bug.cgi?id=228076

Reviewed by Antti Koivisto.

Source/WebCore:

The image get stretched because constrainLogicalWidthInFragmentByMinMax returns the intrinsic width while computing MinSize.
According to [1], the box's minimum width is its min-content size not the MinIntrinsic width which is used because of
the recursion. To break the recursion, computeIntrinsicLogicalWidthUsing calls computeLogicalWidthFromAspectRatioInternal instead,
then checks children's width.

[1] https://www.w3.org/TR/css-sizing-4/#aspect-ratio-minimum

  • rendering/RenderBox.cpp:

(WebCore::RenderBox::constrainLogicalWidthInFragmentByMinMax const): If shouldComputeLogicalWidthFromAspectRatio,
the length should be treated as MinContent not MinIntrinsic.
(WebCore::RenderBox::computeIntrinsicLogicalWidthUsing const): To break the loop, call computeLogicalWidthFromAspectRatioInternal instead
to get the width from aspect-ratio and if there is child, make sure the min/max logical width not less than content's width.
(WebCore::RenderBox::computeLogicalWidthFromAspectRatioInternal const):
(WebCore::RenderBox::computeLogicalWidthFromAspectRatio const):

  • rendering/RenderBox.h:

LayoutTests:

2:40 AM Changeset in webkit [280630] by timothy_horton@apple.com
  • 9 edits
    1 delete in trunk

fast/canvas/canvas-crash.html doesn't test what it intends to on iOS
https://bugs.webkit.org/show_bug.cgi?id=228747

Reviewed by Simon Fraser.

Source/WebCore:

The test fast/canvas/canvas-crash.html intends to test changes made
to actual canvas code (see r215632); however, on the iOS simulator
the test doesn't even manage to make a canvas context because of
"maximum area" and "maximum backing store size" limits, which differ
per-platform. This results in unique test results for iOS, as well
as the test not actually exercising the code it was intended to.

Fix this by adding an override for the maximum area limit (we already
had one for maximum backing store size), and overriding them in
this test (and another similarly afflicted test).

  • html/HTMLCanvasElement.cpp:

(WebCore::maxCanvasArea):
(WebCore::HTMLCanvasElement::setMaxCanvasAreaForTesting):
(WebCore::HTMLCanvasElement::createImageBuffer const):

  • html/HTMLCanvasElement.h:
  • testing/Internals.cpp:

(WebCore::Internals::resetToConsistentState):
(WebCore::Internals::setMaxCanvasArea):

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

LayoutTests:

  • fast/canvas/canvas-crash.html:
  • fast/canvas/canvas-skia-excessive-size.html:
  • platform/ios-simulator/fast/canvas/canvas-crash-expected.txt: Removed.
  • platform/ios-simulator/fast/canvas/canvas-skia-excessive-size-expected.txt: Removed.

Delete the iOS-specific results, and adopt the new overrides in these two tests.

1:19 AM Changeset in webkit [280629] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Add missing null-check in Touch constructor
https://bugs.webkit.org/show_bug.cgi?id=228231

Patch by Carlos Garcia Campos <cgarcia@igalia.com> on 2021-08-04
Reviewed by Darin Adler.

  • dom/Touch.cpp:

(WebCore::scaledLocation): Helper to initialize absolutePosition.
(WebCore::Touch::Touch): Use scaledLocation().

Note: See TracTimeline for information about the timeline view.