Repository navigation
Merge upstream/main (013da9aa8cc1) + cherry-pick WebKit#63906 - #205
Conversation
… currentPlaybackPosition https://bugs.webkit.org/show_bug.cgi?id=313557 rdar://175774587 Reviewed by Eric Carlson. When MediaPlayerPrivateWirelessPlayback is in use, a media element's currentTime is tied to the MediaDeviceRoute's currentPlaybackPosition, but from WebKit's perspective there is no guarantee that currentPlaybackPosition will update at a reasonable interval during playback. To resolve this, added a CMTimebase to MediaPlayerPrivateWirelessPlayback that is configured with the route's playbackSpeed and currentPlaybackPosition. A timebase observer is added that fires every 100ms (in the media timeline) to update currentTime. This interval matches the one we use in MediaPlayerPrivateAVFoundation's periodic time observer, providing smoothed estimated time updates during wireless playback. While here, simplified how we handle seeks. Removed the "pending seek" concept from MediaPlayerPrivateWirelessPlayback and instead assumed that a seek occurs whenever currentPlaybackPositionDidChange is called. Tests: media/wireless-playback-media-player/current-time-advances-between-position-updates.html media/wireless-playback-media-player/current-time-resumes-after-pause.html media/wireless-playback-media-player/current-time-updates-after-rate-change.html media/wireless-playback-media-player/current-time-updates-after-route-seek.html media/wireless-playback-media-player/current-time-updates-after-seek.html media/wireless-playback-media-player/timeupdate-without-position-updates.html * LayoutTests/media/wireless-playback-media-player/current-time-advances-between-position-updates-expected.txt: Added. * LayoutTests/media/wireless-playback-media-player/current-time-advances-between-position-updates.html: Added. * LayoutTests/media/wireless-playback-media-player/current-time-resumes-after-pause-expected.txt: Added. * LayoutTests/media/wireless-playback-media-player/current-time-resumes-after-pause.html: Added. * LayoutTests/media/wireless-playback-media-player/current-time-updates-after-rate-change-expected.txt: Added. * LayoutTests/media/wireless-playback-media-player/current-time-updates-after-rate-change.html: Added. * LayoutTests/media/wireless-playback-media-player/current-time-updates-after-route-seek-expected.txt: Added. * LayoutTests/media/wireless-playback-media-player/current-time-updates-after-route-seek.html: Added. * LayoutTests/media/wireless-playback-media-player/current-time-updates-after-seek-expected.txt: Added. * LayoutTests/media/wireless-playback-media-player/current-time-updates-after-seek.html: Added. * LayoutTests/media/wireless-playback-media-player/timeupdate-without-position-updates-expected.txt: Added. * LayoutTests/media/wireless-playback-media-player/timeupdate-without-position-updates.html: Added. * Source/WebCore/PAL/pal/cf/CoreMediaSoftLink.cpp: * Source/WebCore/PAL/pal/cf/CoreMediaSoftLink.h: * Source/WebCore/platform/graphics/MediaPlayerPrivateWirelessPlayback.cpp: (WebCore::MediaPlayerPrivateWirelessPlayback::~MediaPlayerPrivateWirelessPlayback): (WebCore::MediaPlayerPrivateWirelessPlayback::play): (WebCore::MediaPlayerPrivateWirelessPlayback::pause): (WebCore::MediaPlayerPrivateWirelessPlayback::seekToTarget): (WebCore::MediaPlayerPrivateWirelessPlayback::currentTime const): (WebCore::MediaPlayerPrivateWirelessPlayback::setRate): (WebCore::MediaPlayerPrivateWirelessPlayback::currentPlaybackPositionDidChange): (WebCore::MediaPlayerPrivateWirelessPlayback::ensureTimebase): (WebCore::MediaPlayerPrivateWirelessPlayback::destroyTimebase): (WebCore::MediaPlayerPrivateWirelessPlayback::updateTimebaseTimeAndRate): (WebCore::MediaPlayerPrivateWirelessPlayback::scheduleTimebaseTimer): (WebCore::MediaPlayerPrivateWirelessPlayback::timebaseTimerFired): * Source/WebCore/platform/graphics/MediaPlayerPrivateWirelessPlayback.h: Canonical link: https://commits.webkit.org/312246@main
… text file https://bugs.webkit.org/show_bug.cgi?id=313572 Reviewed by Jonathan Bedard. Problem: `git-webkit review` relies on the `position` field returned by GitHub's pull request comments API to place each inline comment in the generated review text file. GitHub computes `position` against its own view of the pull request diff, but the diff we fetch via `application/vnd.github.diff` is computed against the merge base and can have a different hunk layout (e.g. a hunk that has already landed on main is absent from our diff). When GitHub's `position` lands outside the range of lines in the diff we fetched, the count in `insert_diff_comments` never matches and the comment is silently dropped — it never appears in the review text file. Solution: Translate comment locations ourselves using the `line` / `original_line` field (the new-file line number the comment applies to), which is unambiguous regardless of which diff was used to compute it. A new `_line_to_position_map` helper walks the diff we actually fetched, parses `@@ -a,b +c,d @@` hunk headers, and records the position within our diff for each new-file line. `_diff_comments` now uses that map to assign each comment a position that matches the diff being displayed, falling back to the raw `position` field only when no line number is reported (preserves behavior for file-level comments and legacy/mock data used by the existing tests). * Tools/Scripts/libraries/webkitscmpy/webkitscmpy/remote/git_hub.py: Canonical link: https://commits.webkit.org/312247@main
…upport https://bugs.webkit.org/show_bug.cgi?id=313507 rdar://175721231 Reviewed by Sihui Liu. Prepare BackForwardCache and CachedFrame for multi-process BFCache with Site Isolation. Add a new take(BackForwardFrameItemIdentifier, Page*) overload that looks up cache entries directly by identifier rather than through a HistoryItem. This is needed because subframe processes suspend and restore their BFCache entries using the main frame's identifier passed from the UIProcess, without access to the HistoryItem. The existing take(HistoryItem&, Page*) now delegates to the new overload. Add Page ownership validation to both take() and get(). With multi-process BFCache, a subframe process caches its Page under the main frame's BackForwardFrameItemIdentifier via SetSubframesSuspended. If a different Page in the same process later navigates to the same back/forward item, the FrameLoader's BFCache lookup can find this subframe entry instead of a cache miss. Since the subframe's CachedPage has a RemoteFrame main frame with no DocumentLoader, restoring from it causes a crash. The Page validation ensures each Page only finds its own cache entries. The take() overload checks before removing from the map so mismatched entries are preserved for their rightful owner. In CachedFrame, restore() now null-guards m_document to support RemoteFrame entries. In an iframe process under Site Isolation, the Page's main frame is a RemoteFrame with no Document — the CachedFrame stores the frame tree structure but not a Document. The child frame reconstruction loop and pruneDetachedChildFrames() are moved outside the m_document guard so they execute for both LocalFrame and RemoteFrame paths. CachedFrame::open() adds a RemoteFrame branch that calls restore() directly, since RemoteFrames have no FrameLoader to drive the restoration. In FrameLoader::continueLoadAfterNavigationPolicy, replace the isInBackForwardCache() check with BackForwardCache::get(). The former only checks if the key exists in the cache, while the latter also validates Page ownership. Without this, the FrameLoader can take the BFCache restoration path using a subframe's CachedPage, stalling the navigation instead of proceeding to the normal load path that triggers a process swap via the UIProcess. No new tests (no behavior change for single-process BFCache). * Source/WebCore/history/BackForwardCache.cpp: (WebCore::BackForwardCache::addIfCacheable): (WebCore::BackForwardCache::take): (WebCore::BackForwardCache::get): * Source/WebCore/history/BackForwardCache.h: * Source/WebCore/history/CachedFrame.cpp: (WebCore::CachedFrameBase::restore): (WebCore::CachedFrame::open): * Source/WebCore/loader/FrameLoader.cpp: (WebCore::FrameLoader::continueLoadAfterNavigationPolicy): Canonical link: https://commits.webkit.org/312248@main
rdar://175516150 https://bugs.webkit.org/show_bug.cgi?id=313487 Reviewed by Richard Robinson. Say JavaScript creates a new window. That window starts out with a session history for items the user has never interacted with. Once the user clicks a link on that document, we push a new session history entry that *does* have user interaction. But when analyzing the back list we notice the previous item had no interaction, and therefore don't reveal it to the API back/forward list. The intention is that once the user makes a new entry by interacting, a series of non-interacted-with items in the back list are coalesced into one logical step in the list. 311615@main accidentally broke that logic if the series of interaction-free items was at the start of the list (as in the new window case) This PR fixes that and gives progressions on some other API tests that had some back counts wrong. Test: Tools/TestWebKitAPI/Tests/WebKit/WKWebView/WKBackForwardListTests.mm * Source/WebKit/UIProcess/API/Cocoa/WKBackForwardListItem.mm: (-[WKBackForwardListItem _loggingStringForTesting]): * Source/WebKit/UIProcess/API/Cocoa/WKBackForwardListItemPrivate.h: * Source/WebKit/UIProcess/WebBackForwardList.cpp: (WebKit::WebBackForwardList::itemStartingAtIndexSkippingItemsAddedByJSWithoutUserGesture const): (WebKit::WebBackForwardList::loggingString const): (WebKit::WebBackForwardList::loggingString): Deleted. * Source/WebKit/UIProcess/WebBackForwardList.h: * Source/WebKit/UIProcess/WebBackForwardList.swift: * Tools/TestWebKitAPI/Tests/WebKit/WKWebView/WKBackForwardListTests.mm: (runBackForwardNavigationSkipsItemsWithoutUserGestureTest): (TEST(WKBackForwardList, BackNavigationHijacking)): (TEST(WKBackForwardList, ForwardSkipIteratesThroughLeadingConsecutiveJSItems)): (TEST(WKBackForwardList, BackForwardNavigationSkipsPromiseRedirectWithoutUserInteraction)): (TEST(WKBackForwardList, BackButtonWorksAfterUserClickFromJSCreatedPage)): Canonical link: https://commits.webkit.org/312249@main
https://bugs.webkit.org/show_bug.cgi?id=313580 rdar://175796349 Reviewed by Pascoe. pal.swift is the umbrella module entry that re-exports the underlying Clang module via @_exported public import pal. Sibling Swift files (CryptoKit+UnsafeOverlays.swift, CryptoTypes.swift, RegexHelper.swift, CryptoKitShim.swift) import via the umbrella name (pal.Core.crypto.*, etc.). The Xcode build compiles pal.swift; the CMake build was missing it. Add it so the umbrella re-export is present on Mac. * Source/WebCore/PAL/pal/CMakeLists.txt: Canonical link: https://commits.webkit.org/312250@main
https://bugs.webkit.org/show_bug.cgi?id=313603 Introduced debug assertion failures in EWS Reverted changeset: "[Site Isolation] fast/events/before-unload-navigate-different-window.html fails" https://bugs.webkit.org/show_bug.cgi?id=313075 https://commits.webkit.org/312031@main Canonical link: https://commits.webkit.org/312251@main
https://bugs.webkit.org/show_bug.cgi?id=313599 rdar://175804637 Reviewed by Mike Wyrzykowski. * Source/WebCore/platform/graphics/MediaPlayerPrivateWirelessPlayback.cpp: Canonical link: https://commits.webkit.org/312252@main
…g constraint https://bugs.webkit.org/show_bug.cgi?id=307564 rdar://170156450 Reviewed by Keith Miller. In the existing JSPI implementation, evacuated Wasm stack slices and callee saves are registered with the VM and scanned as conservative roots. This creates a potential memory leak. Here is the reference structure: Promise --> PinballCompletion --> EvacuatedStacks, Callee Saves --> ... ^ | VM The Promise is the promise that caused JSPI suspension, and it owns (transitively via resolution handlers) the PinballCompletion with the suspended computation. Normally, when the promise is fulfilled or rejected, PinballCompletion unregisters the evacuated stacks and callee saves it owns, and all these objects become garbage-collectable. Also, if the promise is forgotten without being resolved and becomes unmarked together with PinballCompletion, PinballCompletion destructor unregisters the evacuated stacks and callee saves, so everything is collected. However, if there happens to be a reference chain starting in evacuated stacks or callee saves and leading back to the promise, this transitive strong reference from the VM conservative roots will keep the promise and all the other objects involved alive forever. This patch prevents such a scenario. It stops treating evacuated stacks and callee saves as VM conservative roots. Instead, a new GC constraint is introduced for PinballCompletion objects, to scan the evacuated stacks and callee saves owned by a completion for conservative roots only when the completion itself is marked. This change requires some care in the implantation of evacuated stack slices. In the original implementation the top slice is removed from a PinballCompletion and stored in PinballHandlerContext by pinballHandlerInitContext(). Control would then return to assembly code which would prepare the stack space for the slice and then call pinballHandlerImplantSlice() to copy the slice data onto the stack. This creates a time window when a stack slice has been taken out of its owner PinballCompletion, but its contents have not yet been copied onto the stack. If GC were to run in this window, the slice would not be scanned for conservative roots. This is not an immediate problem because currently we do nothing in that time window that could start a GC, but it is a fragility in case the code is changed in the future. To avoid this fragility, we change the logic so that instead of storing the slice to implant in PinballHandlerContext, we store the pinball object itself, and the slice is only taken out of a PinballCompletion immediately before being implanted. We also refactor the initialization code to make it an initializer of the PinballHandlerContext struct instead of a static helper function. Unified sources fixes --------------------- The change in unified sources order with this patch, combined with the revision of JSC header includes by https://bugs.webkit.org/show_bug.cgi?id=312585 caused build breakage. The patch includes these additional changes unrelated to its core logic to fix the breakage: - TemporalPlainYearMonth.h / .cpp: Moved the addDurationToYearMonth template definition from the header into the .cpp file and added explicit template instantiations for AddOrSubtract::Add and AddOrSubtract::Subtract. The header only had a forward declaration of JSGlobalObject, so the globalObject->vm() call on line 91 failed with an incomplete type error. - WeakMapImplInlines.h: Added #include "Symbol.h". The canBeHeldWeakly function calls asSymbol() which is declared in Symbol.h, but the header only had a forward declaration of Symbol via the include chain. - PinballHandlerContext.cpp: Added #include "StackAlignment.h". The constructor asserts !(sliceByteSize % stackAlignmentBytes()), but stackAlignmentBytes() is declared in StackAlignment.h which wasn't included directly. Testing ------- - Added `jspi-gc-abandoned-suspensions.js` to reproduce the memory leak scenario described above. - Refactoring changes are covered by existing tests. Canonical link: https://commits.webkit.org/312253@main
https://bugs.webkit.org/show_bug.cgi?id=313535 Reviewed by Ben Nham. MemoryCache::get() already returns a standalone copy of the blob data (via copyBlob) to safely release the lock. The second copyBlob in BlobStorage::get() was copying that result again unnecessarily. * Source/WebKit/NetworkProcess/cache/NetworkCacheBlobStorage.cpp: (WebKit::NetworkCache::BlobStorage::get): Canonical link: https://commits.webkit.org/312254@main
…t() after closing the web view https://bugs.webkit.org/show_bug.cgi?id=313566 rdar://175108210 Reviewed by Aditya Keerthi and Abrar Rahman Protyasha. Return early from a couple `PopUpSOAuthorizationSession` codepaths, in the case where the web view has already been closed. Test: SOAuthorizationPopUp.InterceptionCancelAfterClose * Source/WebKit/UIProcess/Cocoa/SOAuthorization/PopUpSOAuthorizationSession.mm: (WebKit::PopUpSOAuthorizationSession::abortInternal): (WebKit::PopUpSOAuthorizationSession::completeInternal): * Tools/TestWebKitAPI/Tests/WebKit/WKWebView/SOAuthorizationTests.mm: (TestWebKitAPI::TEST(SOAuthorizationPopUp, InterceptionCancelAfterClose)): Canonical link: https://commits.webkit.org/312255@main
…om JavaScript <https://bugs.webkit.org/show_bug.cgi?id=313389> <rdar://175652847> Reviewed by Chris Dumez. Handle the case in `workerObjectDestroyed()` where `workerGlobalScopeDestroyedInternal()` has already run. When that happens, the proxy's thread, context, and identifier are already cleaned up -- the only remaining work is releasing the initial construction ref via `deref()`. Without this, `workerObjectDestroyed()` returns early on the nullopt identifier, leaving the ref permanently held. Also clear `m_queuedEarlyTasks` in `workerGlobalScopeDestroyedInternal()` because tasks queued before the worker thread is created capture `Ref { *this }`, forming a retain cycle through the proxy's own member vector that prevents destruction even after `deref()` is called. The leak was introduced in Bug 22723 (254597@main) which added the null-context early return to `workerObjectDestroyed()` and added `m_scriptExecutionContext = nullptr` to `workerGlobalScopeDestroyedInternal()` as part of implementing nested dedicated workers. Test using `run-webkit-tests --leaks` with: - workers/worker-set-delete-terminate-crash.html - workers/worker-terminate-crash.html * Source/WebCore/workers/WorkerMessagingProxy.cpp: (WebCore::WorkerMessagingProxy::workerObjectDestroyed): (WebCore::WorkerMessagingProxy::workerGlobalScopeDestroyedInternal): Canonical link: https://commits.webkit.org/312256@main
…tml fails https://bugs.webkit.org/show_bug.cgi?id=313280 rdar://175553453 Reviewed by Ryosuke Niwa. A cross-origin iframe's initial navigation should appear as a PerformanceResourceTiming entry in the parent document's performance timeline. Resource timing does not work in site isolation because ResourceTiming::addResourceTiming() relies on document.parentDocument and frame->ownerElement(), which are null in the Site Isolation case. To address this problem, we send the ResourceTiming data to the parent WCP via IPC in SubresourceLoader::reportResourceTiming(). Then the parent adds the information to the document's Performance object through the new ResourceTimingInformation::addResourceTimingToDocument(). * LayoutTests/TestExpectations: * LayoutTests/imported/w3c/web-platform-tests/service-workers/service-worker/navigation-preload/resource-timing.https-expected.txt: * LayoutTests/platform/ios-site-isolation/TestExpectations: * LayoutTests/platform/mac-site-isolation/TestExpectations: * Source/WebCore/Headers.cmake: * Source/WebCore/WebCore.xcodeproj/project.pbxproj: * Source/WebCore/loader/LocalFrameLoaderClient.cpp: * Source/WebCore/loader/LocalFrameLoaderClient.h: * Source/WebCore/loader/ResourceLoadTiming.h: (WebCore::ResourceLoadTiming::ResourceLoadTiming): * Source/WebCore/loader/ResourceTiming.cpp: (WebCore::ResourceTiming::ResourceTiming): (WebCore::ResourceTiming::isolatedCopy const): (WebCore::ResourceTiming::isolatedCopy): * Source/WebCore/loader/ResourceTiming.h: (WebCore::ResourceTiming::ResourceTiming): Deleted. * Source/WebCore/loader/ResourceTimingInformation.cpp: (WebCore::ResourceTimingInformation::addResourceTimingToDocument): (WebCore::ResourceTimingInformation::addResourceTiming): * Source/WebCore/loader/ResourceTimingInformation.h: * Source/WebCore/loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::reportResourceTiming): * Source/WebCore/page/RemoteFrame.cpp: (WebCore::RemoteFrame::addResourceTimingFromChild): * Source/WebCore/page/RemoteFrame.h: * Source/WebCore/page/RemoteFrameClient.h: * Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in: * Source/WebKit/UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::addResourceTimingFromSubframe): * Source/WebKit/UIProcess/WebPageProxy.h: * Source/WebKit/UIProcess/WebPageProxy.messages.in: * Source/WebKit/WebProcess/WebCoreSupport/WebLocalFrameLoaderClient.cpp: * Source/WebKit/WebProcess/WebCoreSupport/WebRemoteFrameClient.cpp: (WebKit::WebRemoteFrameClient::addResourceTimingFromChild): * Source/WebKit/WebProcess/WebCoreSupport/WebRemoteFrameClient.h: * Source/WebKit/WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::addResourceTimingFromSubframe): * Source/WebKit/WebProcess/WebPage/WebPage.h: * Source/WebKit/WebProcess/WebPage/WebPage.messages.in: Canonical link: https://commits.webkit.org/312257@main
https://bugs.webkit.org/show_bug.cgi?id=306150 rdar://167835037 Reviewed by Dan Glastonbury and Kimmo Kinnunen. When fragment shader output components are expanded for Metal compatibility/validation, only the original components were being copied in the conversion function. The missing components were left uninitialized which led to garbage memory being written to the framebuffer. So add a second loop in SaturateScalarOrVectorCommon to zero-initialize the missing components after copying the original components. Test: webgl/webgl2-init-missing-fragment-output-components.html * LayoutTests/webgl/webgl2-init-missing-fragment-output-components-expected.txt: Added. * LayoutTests/webgl/webgl2-init-missing-fragment-output-components.html: Added. * Source/ThirdParty/ANGLE/src/compiler/translator/msl/ModifyStruct.cpp: * Source/ThirdParty/ANGLE/src/tests/gl_tests/GLSLTest.cpp: Originally-landed-as: 305413.216@safari-7624-branch (0df3411). rdar://173969027 Canonical link: https://commits.webkit.org/312258@main
https://bugs.webkit.org/show_bug.cgi?id=313525 Reviewed by Brady Eidson. This PR fixes a number of issues with site isolation pertaining to navigate-blob.html 1. Named window lookup fails across processes When RemotePageProxy::injectPageIntoNewProcess() creates a popup's WebPage in another process, the opener frame doesn't exist yet (IPC ordering). FrameTree::find() locates the popup by name but isFrameFamiliarWith() rejects it because the opener is null. Fix: Deferred opener resolution in WebPage::create() (WebPage.cpp, WebPage.h). Store unresolved opener ID; when the opener's WebPage is later created in the same process, resolve pending openers by calling updateOpener(). 2. topDocumentSyncData not propagated during main frame process swap When a main frame navigates cross-origin, didChangeMainDocument() in the new process broadcasts BroadcastAllDocumentSyncData. This message arrives at ProvisionalPageProxy::didReceiveMessage(), which has an explicit list of forwarded messages — BroadcastAllDocumentSyncData was not on it. The message was silently dropped, so the old process (hosting subframes) never learned the new top-level origin. Blobs created by subframes were registered with the wrong partition key. Fix: Added BroadcastDocumentSyncData and BroadcastAllDocumentSyncData to the forwarded message list in ProvisionalPageProxy::didReceiveMessage() (ProvisionalPageProxy.cpp). 3. topDocumentSyncData race conditions during process swap Page::updateTopDocumentSyncData(Ref<DocumentSyncData>&&) rejected broadcasts when the main frame was a LocalFrame with a document, so the broadcast arriving before the frame swap was ignored. In addition, Page::setMainFrame() resets m_topDocumentSyncData unconditionally, wiping the just-received broadcast when the main frame was replaced with a RemoteFrame. Fix: Always accept broadcasts in updateTopDocumentSyncData, and only update m_topDocumentSyncData from the new frame's document when the new frame is a LocalFrame with a document (Page.cpp). 4. Debug assertion failure: null opener frame WebPageProxy assumed the opener frame still existed when processInheritedFromOpener was true. With site isolation, the opener frame can be destroyed or replaced between the time the popup was opened and when it later navigates. The processInheritedFromOpener flag is a sticky property set at popup creation time. It doesn't track whether the opener frame is still alive. By the time the popup navigates, the opener frame may have been removed by a process swap, page close, or DOM mutation. Fix: Fall back to ensureProcessForSite when the opener frame is gone (WebPageProxy.cpp). 5. Debug assertion in frameWasRemovedInAnotherProcess frameWasRemovedInAnotherProcess is the normal cross-process frame synchronization message under site isolation. When a frame is removed in one process, every other process hosting a remote representation of that frame receives this message to tear down its RemoteFrame. With the deferred opener resolution fix, more cross-process frame relationships are established (popups correctly linked to openers across processes). When those frames are later removed - during navigation, process swap, or DOM manipulation — the synchronization message legitimately arrives at the WebPage hosting the remote representation. The ASSERT_NOT_REACHED was incorrect because it treated a normal synchronization path as unreachable. Fix: Removed the assertion (WebPage.cpp). Co-authored with Claude. Test: http/tests/local/blob/navigate-blob.html * LayoutTests/platform/ios-site-isolation/TestExpectations: * LayoutTests/platform/mac-site-isolation/TestExpectations: * Source/WebCore/page/Page.cpp: (WebCore::Page::setMainFrame): (WebCore::Page::updateTopDocumentSyncData): * Source/WebKit/UIProcess/ProvisionalPageProxy.cpp: (WebKit::ProvisionalPageProxy::didReceiveMessage): * Source/WebKit/UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::initializeWebPage): * Source/WebKit/WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::create): (WebKit::WebPage::frameWasRemovedInAnotherProcess): * Source/WebKit/WebProcess/WebPage/WebPage.h: Canonical link: https://commits.webkit.org/312259@main
…ml fails https://bugs.webkit.org/show_bug.cgi?id=313369 Reviewed by Chris Dumez. When a subframe navigation triggers a process swap (e.g., localhost -> 127.0.0.1) and a server redirect sends it back to the parent's site (127.0.0.1 -> localhost), the UIProcess continues the load in the parent's process. The new process computes Sec-Fetch-Site fresh - context origin = localhost (inherited from parent), request URL = localhost - yielding "same-origin". The cross-site redirect through 127.0.0.1 is lost. Fixed the buy by passing navigation.originalRequest() in LoadParameters's originalRequest when continuing a redirect in loadContinuingInNonInitiatingProcess and continueNavigationInNewProcess subframe paths. In computeFetchMetadataSite, when the DocumentLoader is a continuing load after a provisional load started and has a different original URL, recompute Sec-Fetch-Site by evaluating the original URL first, then degrading for the redirect. Tests: http/wpt/fetch/fetch-metadata-for-sandbox-iframes-reuse.html http/wpt/fetch/fetch-metadata-for-sandbox-iframes.html * LayoutTests/platform/ios-site-isolation/TestExpectations: * LayoutTests/platform/mac-site-isolation/TestExpectations: * Source/WebCore/loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::SubresourceLoader): * Source/WebCore/loader/cache/CachedResourceLoader.cpp: (WebCore::CachedResourceLoader::computeFetchMetadataSite): (WebCore::CachedResourceLoader::updateHTTPRequestHeaders): * Source/WebCore/loader/cache/CachedResourceLoader.h: * Source/WebKit/UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::receivedNavigationActionPolicyDecision): (WebKit::WebPageProxy::continueNavigationInNewProcess): Canonical link: https://commits.webkit.org/312260@main
….modulemap https://bugs.webkit.org/show_bug.cgi?id=313567 rdar://175786669 Reviewed by Richard Robinson. Excluding it is unnecessary and may cause build issues. No new tests needed. * Source/WebCore/WebCore_Private.modulemap: Canonical link: https://commits.webkit.org/312261@main
…k only the elements that have relations-attributes https://bugs.webkit.org/show_bug.cgi?id=313445 rdar://175681348 Reviewed by Joshua Hoffman. updateRelationsIfNeeded() previously walked every element in the entire DOM on every rebuild, checking all 13 relation attributes per element. This is wasteful because only a small fraction of elements have relation attributes. Track elements with relation attributes in a WeakHashSet during the initial full-DOM build, and maintain it incrementally as attributes change. Subsequent rebuilds (triggered by id changes, reference target changes, etc.) iterate only the tracked elements instead of the full DOM. On a page with 1000 DOM elements but only 5 labels and 0 ARIA relation attributes, the rebuild now walks 5 elements instead of 1000. This change is a 0.51% improvement on Speedometer 3.1. * Source/WebCore/accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::handleAttributeChange): (WebCore::AXObjectCache::performDeferredCacheUpdate): (WebCore::AXObjectCache::updateRelationsIfNeeded): (WebCore::AXObjectCache::updateRelationsForTree): * Source/WebCore/accessibility/AXObjectCache.h: * Source/WebCore/accessibility/AccessibilityObject.h: Canonical link: https://commits.webkit.org/312262@main
… for line ranges spanning nested table boundaries https://bugs.webkit.org/show_bug.cgi?id=313508 rdar://174349841 Reviewed by Joshua Hoffman. On macOS, attributedStringForTextMarkerRange used rangeForTextMarkerRange() to convert text markers to a SimpleRange via CharacterOffset. This path relies on characterOffsetsInOrder() to determine ordering, which produces incorrect results for positions spanning across nested table boundaries (e.g. a text node inside a cell vs. an ancestor tbody position). The reversed range caused attributedStringForTextMarkerRange to return an empty string, making VoiceOver read "new line" instead of the actual line content. Fix this by matching iOS and switching to simpleRange(), which converts directly from the text markers' boundary points. This commit does not address the core bug causing the reversed range. I attempted to do this, but it ended up being complex, so a FIXME was added instead. This commit is still a good step forward, decreasing the difference between platforms and introducing a layout test that reproduces the issue. * LayoutTests/accessibility/attributed-string-for-line-in-table-expected.txt: Added. * LayoutTests/accessibility/attributed-string-for-line-in-table.html: Added. * LayoutTests/platform/glib/TestExpectations: * LayoutTests/platform/ios/TestExpectations: * Source/WebCore/accessibility/AXObjectCache.cpp: (WebCore::characterOffsetsInOrder): * Source/WebCore/accessibility/cocoa/AccessibilityObjectCocoa.mm: (WebCore::AccessibilityObject::attributedStringForTextMarkerRange const): Canonical link: https://commits.webkit.org/312263@main
…surface https://bugs.webkit.org/show_bug.cgi?id=313518 Reviewed by Carlos Garcia Campos. A child layer's blend mode must blend against the contents of its enclosing stacking context, not whatever the parent canvas happens to hold from unrelated ancestors. * Source/WebCore/platform/graphics/skia/SkiaCompositingLayer.cpp: (WebCore::SkiaCompositingLayer::computeTransformsAndAnimations): (WebCore::SkiaCompositingLayer::recursivePaint): * Source/WebCore/platform/graphics/skia/SkiaCompositingLayer.h: Canonical link: https://commits.webkit.org/312264@main
Unreviewed build fix. ResourceTiming.h is a Private framework header, so includes of sibling headers must use angle-bracket form. * Source/WebCore/loader/ResourceTiming.h: Canonical link: https://commits.webkit.org/312265@main
https://bugs.webkit.org/show_bug.cgi?id=313560 Reviewed by Yusuke Suzuki. This is a follow-up to 312222@main with a small cleanup. * Source/cmake/WebKitCompilerFlags.cmake: Use cmake_push_check_state() and cmake_pop_check_state() consistently to ensure that variables are restored to their original values after modifying them for tests. Canonical link: https://commits.webkit.org/312266@main
…rectory entry https://bugs.webkit.org/show_bug.cgi?id=313538 Reviewed by Darin Adler. FileSystem::listDirectory() uses std::filesystem::directory_iterator internally, which caches each entry's file type from readdir's d_type field. However, it only returns filenames, discarding the cached type. Callers that need the entry type then call FileSystem::fileType() per entry, which does a redundant lstat() syscall to rediscover what directory_iterator already knew. Add FileSystem::traverseDirectory() that uses directory_iterator directly and provides both the filename and file type to the callback, reading the type from directory_entry::symlink_status() which uses the cached d_type without a syscall. It also avoids materializing all filenames into an intermediate Vector. Update the four call sites that were doing listDirectory() + fileType() per entry: NetworkCacheFileSystem, deleteAllFilesModifiedSince, DirectoryFileListCreator, and DOMFileSystem::listDirectoryWithMetadata. * Source/WTF/wtf/FileSystem.cpp: (WTF::FileSystemImpl::deleteAllFilesModifiedSince): (WTF::FileSystemImpl::traverseDirectory): * Source/WTF/wtf/FileSystem.h: * Source/WTF/wtf/playstation/FileSystemPlayStation.cpp: (WTF::FileSystemImpl::traverseDirectory): * Source/WebCore/Modules/entriesapi/DOMFileSystem.cpp: (WebCore::listDirectoryWithMetadata): * Source/WebCore/html/DirectoryFileListCreator.cpp: (WebCore::appendDirectoryFiles): * Source/WebKit/NetworkProcess/cache/NetworkCacheFileSystem.cpp: (WebKit::NetworkCache::traverseDirectory): Canonical link: https://commits.webkit.org/312267@main
https://bugs.webkit.org/show_bug.cgi?id=313501 Reviewed by Yusuke Suzuki. Prevent `PKG_CONFIG_PATH` from pointing to Linux specific configs (`.pc` files); causing build to fail. Canonical link: https://commits.webkit.org/312268@main
https://bugs.webkit.org/show_bug.cgi?id=313345 rdar://175616055 Reviewed by Keith Miller. 1. Make promiseReturnUndefinedOnFulfilled C++ function instead. It is just returning an undefined. 2. Clean up asyncDispose code. Using @newResolvedPromise / @newRejectedPromise helpers, and coverting entire region with try-catch instead. * Source/JavaScriptCore/builtins/AsyncIteratorPrototype.js: (overriddenName.string_appeared_here.asyncDispose): (linkTimeConstant.promiseReturnUndefinedOnFulfilled): Deleted. * Source/JavaScriptCore/builtins/BuiltinNames.h: * Source/JavaScriptCore/bytecode/LinkTimeConstant.h: * Source/JavaScriptCore/runtime/JSGlobalObject.cpp: (JSC::JSC_DEFINE_HOST_FUNCTION): (JSC::JSGlobalObject::init): Canonical link: https://commits.webkit.org/312269@main
https://bugs.webkit.org/show_bug.cgi?id=313010 rdar://175354204 Reviewed by Charlie Wolfe. A recent change in CFNetwork results in WebKit potentially receiving a @"none" value for the cookie's SameSite property. This wasn't previously possible because unspecified and None were handled identically. Since the CFNetwork change, a debug assertion within WebKit is now being triggered on some sites. This change adds explicit support for the @"none" SameSite value. * Source/WebCore/platform/network/cocoa/CookieCocoa.mm: (WebCore::coreSameSitePolicy): (WebCore::nsSameSitePolicy): * Tools/TestWebKitAPI/Tests/WebKit/WKWebView/WKHTTPCookieStore.mm: (TEST(WKHTTPCookieStore, SetCookies)): Canonical link: https://commits.webkit.org/312270@main
https://bugs.webkit.org/show_bug.cgi?id=313574 rdar://174429082 Reviewed by Lily Spiniolas, Aditya Keerthi, and Abrar Rahman Protyasha. The problem: The previous fix 310265@main WebKit#60950 expanded the slider thumb's touch hit area and interaction region by 12.5pt when either dimension is below 48pt. The touch hit area was correct and matched UIKit, but the interaction region (the visible gaze glow highlight) was too large. The fix: UIKit does not enlarge the gaze glow, so to match that behaviour, the interaction region inflation for slider thumbs in inflateRectForInteractionRegion is removed. * LayoutTests/interaction-region/form-control-refresh/slider-thumb-native-interaction-region-expected.txt: * LayoutTests/interaction-region/input-type-range-region-expected.txt: * Source/WebCore/rendering/cocoa/RenderThemeCocoa.mm: (WebCore::RenderThemeCocoa::inflateRectForInteractionRegion): Canonical link: https://commits.webkit.org/312271@main
https://bugs.webkit.org/show_bug.cgi?id=313632 Unreviewed, flag a webrtc test as flaky. * LayoutTests/platform/glib/TestExpectations: Canonical link: https://commits.webkit.org/312272@main
https://bugs.webkit.org/show_bug.cgi?id=313628 Reviewed by Nikolas Zimmermann. Update geometry parsing expectations after 312018@main. * LayoutTests/platform/mac-tahoe-wk2-lbse-text/imported/w3c/web-platform-tests/svg/geometry/parsing/height-computed-expected.txt: * LayoutTests/platform/mac-tahoe-wk2-lbse-text/imported/w3c/web-platform-tests/svg/geometry/parsing/width-computed-expected.txt: Canonical link: https://commits.webkit.org/312273@main
https://bugs.webkit.org/show_bug.cgi?id=306955 Unreviewed gardening. These tests only crash/fail in debug builds. * LayoutTests/platform/glib/TestExpectations: Canonical link: https://commits.webkit.org/312274@main
…ests/fecomponenttransfer-tablevalues-crash.html` is a flaky timeout https://bugs.webkit.org/show_bug.cgi?id=313641 Unreviewed gardening. * LayoutTests/platform/glib/TestExpectations: Canonical link: https://commits.webkit.org/312275@main
https://bugs.webkit.org/show_bug.cgi?id=313714 rdar://175910769 Reviewed by Mike Wyrzykowski. Add `_scrollOffsetAdjustedForObscuredInset:`, which is the inverse of `_contentOffsetAdjustedForObscuredInset:`, and use it in `_beginLiveResize`. `_didCommitLayerTreeDuringAnimatedResize:` had the classic scroll position/ scroll offset confusion, which breaks side-scrolling RTL pages with non-zero scrollOrigin. Fix by converting the scrollPosition to a scroll offset before computing contentOffsets. No test, because rotation is not reliably testable. Manual testing shows that this improves the behavior. * Source/WebKit/UIProcess/API/Cocoa/WKWebViewInternal.h: * Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm: (-[WKWebView _scrollOffsetAdjustedForObscuredInset:]): (-[WKWebView _didCommitLayerTreeDuringAnimatedResize:mainFrameData:]): (-[WKWebView _updateLiveResizeTransform]): (-[WKWebView _beginLiveResize]): Canonical link: https://commits.webkit.org/312391@main
https://bugs.webkit.org/show_bug.cgi?id=313776 rdar://175367866 312334@main breaks viewing some 3d models Reverted change: Transform camera instead of model https://bugs.webkit.org/show_bug.cgi?id=313026 rdar://175367866 312334@main (43f2400) Canonical link: https://commits.webkit.org/312392@main
https://bugs.webkit.org/show_bug.cgi?id=305256 rdar://168015751 Reviewed by Ryosuke Niwa. The `Performance` object stored only one LCP entry, instead of the buffer of 150 entries as specified by [1]. Fix by implementing the `performance entry buffer map` per spec [2], allowing us to specify the max buffer size on a per-entryType basis. This replaces the ad-hoc buffers, and brings the code closer to spec terminology. Change PerformanceEntry::Type to be a normal enum; we can use EnumSet where necessary, and now just trivially cast the values to get indexes into the std::array. [1] https://w3c.github.io/timing-entrytypes-registry/#registry [2] https://w3c.github.io/performance-timeline/#performance-entry-buffer-map Test: imported/w3c/web-platform-tests/largest-contentful-paint/lcp-buffer-size.html * LayoutTests/imported/w3c/web-platform-tests/largest-contentful-paint/lcp-buffer-size-expected.txt: Added. * LayoutTests/imported/w3c/web-platform-tests/largest-contentful-paint/lcp-buffer-size.html: Added. * LayoutTests/imported/w3c/web-platform-tests/user-timing/measures-expected.txt: * Source/WebCore/page/Performance.cpp: (WebCore::Performance::Performance): (WebCore::Performance::entryBufferTuple): (WebCore::Performance::entryBufferTuple const): (WebCore::Performance::initializeEntryBufferMap): (WebCore::Performance::addToEntryBuffer): (WebCore::Performance::clearEntryBuffer): (WebCore::Performance::getEntries const): (WebCore::Performance::getEntriesByType const): (WebCore::Performance::getEntriesByName const): (WebCore::Performance::appendBufferedEntriesByType const): (WebCore::Performance::processEventEntry): (WebCore::Performance::clearResourceTimings): (WebCore::Performance::setResourceTimingBufferSize): (WebCore::Performance::reportFirstContentfulPaint): (WebCore::Performance::enqueueLargestContentfulPaint): (WebCore::Performance::addNavigationTiming): (WebCore::Performance::addResourceTiming): (WebCore::Performance::isResourceTimingBufferFull const): (WebCore::Performance::resourceTimingBufferFullTimerFired): (WebCore::Performance::mark): (WebCore::Performance::clearMarks): (WebCore::Performance::measure): (WebCore::Performance::clearMeasures): * Source/WebCore/page/Performance.h: * Source/WebCore/page/PerformanceEntry.h: * Source/WebCore/page/PerformanceObserver.cpp: (WebCore::PerformanceObserver::observe): * Source/WebCore/page/PerformanceObserver.h: (WebCore::PerformanceObserver::typeFilter const): Canonical link: https://commits.webkit.org/312393@main
rdar://175501798 https://bugs.webkit.org/show_bug.cgi?id=313595 Reviewed by Simon Fraser. Animating transform-related properties (translate, rotate, scale) from none to none would crash in WebCore::blend (in AcceleratedEffect.cpp) because the from and to value is null. Account for this case by returning base when from/to is null. Also simplify the logic a bit. Test: imported/w3c/web-platform-tests/css/css-animations/crashtests/transform-properties-from-none-to-none-crash.html * LayoutTests/imported/w3c/web-platform-tests/css/css-animations/crashtests/transform-properties-from-none-to-none-crash.html: Added. * Source/WebCore/platform/animation/AcceleratedEffect.cpp: (WebCore::blend): Canonical link: https://commits.webkit.org/312394@main
…nt ICU https://bugs.webkit.org/show_bug.cgi?id=313778 rdar://175972975 Reviewed by Yijia Huang. Recently ICU gets severe regression which causes significant slowness on DateCache warmup. To make things stabilized, we workaround it by warming up, as almost all web pages uses it. * Source/JavaScriptCore/runtime/VM.cpp: (JSC::VM::VM): Canonical link: https://commits.webkit.org/312395@main
…es not stop `mousedown` from firing https://bugs.webkit.org/show_bug.cgi?id=313688 rdar://174864309 Reviewed by Richard Robinson and Abrar Rahman Protyasha. In 306362@main we began to clear the pointer capture controller when `[WKTouchEventsGestureRecognizer reset]` was called so that the map of active touches wouldn't get stuck when an external gesture recognizer handled the touch in a specific manner. However, when the screen is tapped, after `pointerdown` is dispatched, `PointerCaptureController::preventsCompatibilityMouseEventsForIdentifier` is called to see if we should also dispatch `mousedown`. Critically, this is done by examining the map of active touches, which now gets cleared before the check, thus preventing us from making thte correct determination. Fix the issue by only clearing the map from `[WKTouchEventsGestureRecognizer reset]` if the last touch's type isn't `WKTouchEventType::End`, indicating that the touch sequence finished abnormally. Tested by `pointerevents/ios/pointer-events-no-mousedown-when-prevent-default-called-on-pointerdown.html` * Source/WebKit/UIProcess/ios/WKTouchEventsGestureRecognizer.mm: (-[WKTouchEventsGestureRecognizer reset]): Canonical link: https://commits.webkit.org/312396@main
… CSS aspect ratio paths https://bugs.webkit.org/show_bug.cgi?id=313738 Reviewed by Sammy Gill. This function figures out how tall (or wide) a flex item should be based on its aspect ratio and its known cross size. It handles three different cases but the old code tangled them together with a shared variable that meant "cross-axis border + padding" in one branch and "main-axis border + padding" in the other. The refactor splits them into three explicit paths, each with its own return: 1. Intrinsic ratio (like an image) - strip border+padding from the cross size if needed, multiply by ratio. 2. CSS ratio with content-box - strip border + padding from cross size, multiply by ratio. Has a FIXME because it always strips even when the value is already content-box. 3. CSS ratio with border-box - multiply border-box cross size by ratio, then subtract main-axis border + padding so the caller gets a content-box result. No behavior change. * Source/WebCore/rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::computeMainSizeFromAspectRatioUsing): Canonical link: https://commits.webkit.org/312397@main
https://bugs.webkit.org/show_bug.cgi?id=313683 rdar://175017084 Reviewed by Aditya Keerthi. The problem: The originating issue: https://commits.webkit.org/274268@main was that the volume slider was impossible to use since it was too small and thus a quirk was made to have Spotify serve the mobile version to iPad. Then in https://commits.webkit.org/298591@main Spotify started blocking iPad mini UA entirely, and the previous quirk was removed, and to unblock iPad mini users https://commits.webkit.org/299301@main was landed. The commit message for the last patch states that it is only for "iPad mini", but the code applied to all iOS devices, thus also affecting full size iPads, and the mobile search UI is now broken due to the quirk only intending to be for smaller screens. The fix: Remove Spotify from needsIPhoneUserAgent and move the iPhone UA override into effectiveContentModeAfterAdjustingPolicies gated on !useDesktopBrowsingMode. iPad Mini still gets iPhone UA (desktop browsing not recommended for its screen class so it hits the gate) and full-size iPad gets desktop mode with working search as well as both the volume and time slider being draggable (the originating issue). * Source/WebCore/page/Quirks.cpp: * Source/WebCore/page/Quirks.h: * Source/WebCore/platform/UserAgent.h: * Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies): Canonical link: https://commits.webkit.org/312398@main
https://bugs.webkit.org/show_bug.cgi?id=313652 rdar://166181001 Reviewed by Eric Carlson When a <video> used child <source> elements and the page-declared `type` attribute disagreed with what the server actually returned (e.g. an Adobe Scene7-served URL declared as video/mp4 whose response body was video/webm), the page never played. WebKit's resource selection algorithm fed the page- declared type into MediaPlayer engine selection: AVFoundation accepted the candidate based on type=video/mp4 and rejected the body during decode. MediaPlayer's engine fallback chain then tried MediaPlayerPrivateWebM, but WebM aborted early in doPreload() because the contentType it was handed was still video/mp4 — it never inspected the body. Every alternative engine rejected the source for the same reason, the source-element resource selection algorithm gave up, and an error was fired on <source>. The src-attribute path (LoadingFromSrcAttr) already had a content-sniffer fallback for this case implemented inside HTMLMediaElement::setNetworkState, but the source-element path (LoadingFromSourceElement) did not. Rather than duplicate the fallback logic in HTMLMediaElement for each load-state, the sniff-and-reload is moved down into MediaPlayer, where it applies uniformly to any load that reaches the engine layer: - After an engine reports FormatError or DecodeError before reaching HaveMetadata, MediaPlayer first runs its existing engine-fallback chain (nextBestMediaEngine / nextMediaEngine) so a correctly-declared type still gets its other installed engines a chance. - When the fallback chain is exhausted and we haven't sniffed yet, MediaPlayer starts a MediaResourceSniffer against m_url, fetches the first 1445 bytes, and uses the magic bytes to determine the actual container type. If the sniffed type differs from the originally-loaded m_loadOptions.contentType, MediaPlayer clears its attempted-engine set, updates m_loadOptions.contentType to the sniffed value, and re-runs engine selection with loadWithNextMediaEngine(nullptr). The correct engine is picked based on what the body actually is. - If the sniffer returns the same type, an empty result, or a non-cancelled error, the original engine failure is propagated to the client unchanged. NetworkError never triggers the sniff — the loader has already failed and retrying through the same loader would just waste a request (and break content-blocker tests that count blocked loads). Because the sniff lives at the engine layer, it is symmetric: a <source type=video/mp4> pointing at a WebM body reloads into WebM, and a <source type=video/webm> pointing at an MP4 body reloads into AVFoundation. The HTMLMediaElement source-selection algorithm, selectNextSourceChild's strict supportsType filter, and the per-<source> error-event timing are unchanged — no spec deviation, no delay for the common "first source has an unsupported declared type" fallback case, and `canPlayType` continues to return "" for unknown types. The HTMLMediaElement-side SrcAttr sniff fallback (sniffForContentType, cancelSniffer, m_sniffer, m_networkErrorOccured, m_lastContentTypeUsed, SnifferPromise) is removed; MediaPlayer handles the same case transparently to the client. * LayoutTests/media/video-source-mime-sniff-webm.html: Added. * LayoutTests/media/video-source-mime-sniff-webm-expected.txt: Added. End-to-end test: a <source> declares video/mp4 but points at a real WebM file; asserts loadeddata fires (proving MediaPlayer's sniff reloaded into the WebM engine). * LayoutTests/media/video-source-mime-sniff-mp4.html: Added. * LayoutTests/media/video-source-mime-sniff-mp4-expected.txt: Added. Symmetric end-to-end test: a <source> declares video/webm but points at a real MP4 file; asserts loadeddata fires (proving MediaPlayer's sniff reloaded into the AVFoundation engine). * Source/WebCore/platform/graphics/MediaPlayer.h: Forward-declare MediaResourceSniffer, add m_sniffer and m_sniffAttempted members, declare the private attemptSniffAndReload and cancelSniffer helpers. * Source/WebCore/platform/graphics/MediaPlayer.cpp: (WebCore::MediaPlayer::load): (WebCore::MediaPlayer::load with MediaSourcePrivateClient): (WebCore::MediaPlayer::load with MediaStreamPrivate): Cancel any in-flight sniffer and reset m_sniffAttempted on a fresh load. (WebCore::MediaPlayer::networkStateChanged): Narrow the engine-fallback trigger from `>= FormatError` to `FormatError || DecodeError` so NetworkError no longer probes additional engines (sniffer included). When the fallback chain is exhausted, call attemptSniffAndReload() and defer reporting the failure to the client if a sniff was started. (WebCore::MediaPlayer::cancelSniffer): New. Cancels an in-flight sniffer. (WebCore::MediaPlayer::attemptSniffAndReload): New. Single-shot sniff against m_url; on a distinct sniffed type, clears m_attemptedEngines, updates m_loadOptions.contentType, and re-runs engine selection via loadWithNextMediaEngine(nullptr). On same-type/empty/error, propagates the original engine failure via mediaPlayerNetworkStateChanged. (WebCore::MediaPlayer::reset): Cancel any in-flight sniffer and reset m_sniffAttempted alongside m_attemptedEngines. * Source/WebCore/html/HTMLMediaElement.h: * Source/WebCore/html/HTMLMediaElement.cpp: Remove the HTMLMediaElement-side sniff fallback; MediaPlayer owns it now. (WebCore::HTMLMediaElement::setNetworkState): Remove the SrcAttr-only sniff-and-retry block; the engine-level sniff handles both src-attr and source-element paths. (WebCore::HTMLMediaElement::loadResource): Inline the completion-handler lambda into the function body. It was invoked exactly once, synchronously, at the end of the function, and its captures (url, player, logSiteIdentifier, this) duplicated locals that were already in scope — it was purely a lexical group with no async dispatch. Dropping the wrapper also removes a dead UNUSED_PARAM(logSiteIdentifier) guard that only existed to silence the unused-capture warning when ENABLE(MEDIA_SOURCE) was off. Also drops the m_lastContentTypeUsed bookkeeping that belonged to the removed sniff fallback. (WebCore::HTMLMediaElement::createMediaPlayer): Drop the m_networkErrorOccured / m_lastContentTypeUsed / cancelSniffer resets — the flags, the helper, and the sniffer are all gone. * Source/WebCore/html/HTMLVideoElement.cpp: Add `#include <wtf/NativePromise.h>`. HTMLVideoElement::bitmapImageForCurrentTime calls BitmapImagePromise::createAndReject(), which instantiates NativePromise<Ref<ShareableBitmap>, void>. MediaPlayer.h only declares the alias and does not include <wtf/NativePromise.h>; on Cocoa/GTK the template definition reached this translation unit through a transitive include, but on PlayStation that chain did not resolve and the build failed with "implicit instantiation of undefined template". Including the header directly at the point of use makes the build independent of which other headers happen to pull it in. Canonical link: https://commits.webkit.org/312399@main
…rop our RtlDllShutdownInProgress decl e9072ad adds pas_process_is_shutting_down() (RtlDllShutdownInProgress via GetProcAddress) and uses it in TLC destructor + WTF::Thread::didExit. Subsumes our direct RtlDllShutdownInProgress guard; dropped the decl + ntdll pragma from pas_thread.h. AbstractModuleRecord: upstream landed the same single-pass star-export walk (Sosuke WebKit#63795); replaced our equivalent with the canonical version, keeping our shouldPreventExtensions parameter and BUN m_isTypeScript guard. Kept: is_exiting flag, pas_thread_suspender plumbing, asymmetric decommit_allocator_range (is_symmetric=false).
There was a problem hiding this comment.
Actionable comments posted: 20
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@JSTests/microbenchmarks/float32-array-last-index-of-medium.js`:
- Line 1: Remove the "//@ memoryHog!" annotation from the top of the
JSTests/microbenchmarks/float32-array-last-index-of-medium.js benchmark file so
it is no longer classified as a heavy memory hog; locate the file and delete
that single comment line (no other changes needed), then run the benchmark suite
to confirm it now runs as a medium test.
In `@JSTests/microbenchmarks/float64-array-last-index-of-small.js`:
- Line 1: Remove the misplaced `//@ memoryHog!` annotation from the top of the
small benchmark (float64-array-last-index-of-small.js) — locate the comment `//@
memoryHog!` and delete it so the test, which only allocates 16 Float64 elements,
is not misclassified or scheduled as a memory-hog benchmark.
In `@JSTests/microbenchmarks/int16-array-last-index-of-large.js`:
- Line 1: Add the memoryHog annotation to this large benchmark file so the test
harness treats it as a large allocation; specifically, insert the single-line
comment "//@ memoryHog!" near the top of
JSTests/microbenchmarks/int16-array-last-index-of-large.js (before or above the
declaration of the large backing-store size variable `size` which is defined as
`let size = 20 << 20;`) so the test is classified consistently with other
*-last-index-of-large.js tests.
In `@JSTests/stress/comma-in-condition-context.js`:
- Around line 301-336: The top-level async IIFE that runs the generator and
asyncFn checks is not awaited, so print("PASS") can execute before the async
assertions complete; capture and await the IIFE (or explicitly await its
Promise) before calling print("PASS") so the test only prints PASS after the
await asyncFn(...) assertions finish — update the anonymous async IIFE
invocation near the top of the file and ensure print("PASS") runs only after
that Promise resolves (referring to the async IIFE and the print("PASS") call).
In
`@LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote-expected.html`:
- Around line 2-7: The file is missing required HTML metadata: add a lang
attribute to the <html> element (e.g., <html lang="en">) and add a <title>
element inside the <head> (e.g., <title>Test</title>) so the document satisfies
HTMLHint; update the existing <html> and <head> elements accordingly.
In `@LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote.html`:
- Around line 2-7: Add a lang attribute to the <html> element and include a
<title> element inside the <head> to satisfy HTML checks: update the <html> tag
to include a suitable language (e.g., lang="en") and add a concise
<title>...</title> element within the existing <head> block so the file has both
lang and title present.
In `@LayoutTests/fast/scrolling/scrollbar-gutter-stable-rtl-viewport.html`:
- Line 10: The iframe in the test HTML snippet lacks an accessible name which
triggers the frame-title-require linting rule; update the <iframe> element in
scrollbar-gutter-stable-rtl-viewport.html (the iframe defined on the shown line)
to include a descriptive title attribute (e.g., title="RTL scrollbar gutter
test" or similar) so the frame has an accessible name and the lint will pass.
In `@LayoutTests/fast/table/blocks-in-inline-table-cell-height.html`:
- Around line 18-21: The test places <td> cells directly under the <table>,
which relies on parser auto-insertion; update the markup so each pair of <td>
elements is wrapped in an explicit <tr> (i.e., wrap the <td> containing the
elements with id="a" and the <td> containing id="b" inside a <tr>), ensuring the
table rows are explicit and deterministic across ports.
In
`@LayoutTests/http/tests/site-isolation/inspector/dom/getDocument-frame-target.html`:
- Around line 25-36: Pre-arm the event awaits to avoid races: call
WI.targetManager.awaitEvent(WI.TargetManager.Event.DidCommitProvisionalTarget)
into a variable before checking target.isProvisional, then await that variable
only if target.isProvisional to get committedEvent and update target; likewise,
call WI.domManager.awaitEvent(WI.DOMManager.Event.FrameDocumentAvailable) into a
variable before checking WI.domManager.frameTargetDocumentForTarget(target), and
only await that variable if frameDoc is falsy to obtain docEvent and frameDoc;
keep InspectorTest.expectNotNull(target.DOMAgent, ...) as-is.
In
`@LayoutTests/http/tests/site-isolation/inspector/dom/resources/dom-frame.html`:
- Line 2: The HTML root element (<html>) in the test fixture lacks a lang
attribute; update the <html> tag (the file's root element) to include an
appropriate language code (for example lang="en" or the correct locale for the
content) so the fixture is compliant with HTML validation and accessibility
expectations.
In
`@LayoutTests/imported/w3c/web-platform-tests/css/css-animations/crashtests/transform-properties-from-none-to-none-crash.html`:
- Line 3: Add a lang attribute to the root HTML element to satisfy the
html-lang-require lint; update the <html> element that currently reads with
class "test-wait" (the root HTML element / tag with class "test-wait") to
include an appropriate lang value (e.g., "en") so the tag becomes lang="…" plus
the existing class.
In
`@LayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/moveBefore-name-map.html`:
- Line 8: The test image element with attributes name="target" and data-target
is missing the required alt attribute; update the <img name="target"
data-target> element to include alt="" (an empty alt) so the fixture becomes
valid HTML while preserving the named-element behavior.
In `@LayoutTests/media/iframe-load-html-as-m2ts.html`:
- Line 2: Add an explicit lang attribute to the root <html> element by updating
the <html> tag (the document's root element) to include the appropriate language
code (e.g., lang="en") so the file declares its language for accessibility and
satisfies HTMLHint.
In `@LayoutTests/media/video-source-mime-sniff-mp4.html`:
- Line 2: Add a lang attribute to the root <html> element in the test file to
satisfy HTMLHint and improve accessibility; locate the opening <html> tag in
LayoutTests/media/video-source-mime-sniff-mp4.html and modify it to include an
appropriate language code (e.g., lang="en") so the tag becomes <html lang="en">.
In `@LayoutTests/media/video-source-mime-sniff-webm.html`:
- Around line 1-39: Add a lang attribute to the root HTML element in
LayoutTests/media/video-source-mime-sniff-webm.html: update the <html> tag (the
document root surrounding the head and body) to include lang="en" so the page
provides document language metadata for accessibility and tooling.
In `@LayoutTests/platform/wpe/TestExpectations`:
- Around line 857-862: The triage block entries in TestExpectations are out of
alphabetical order; reorder the three new WebGL2 texture expectations so they
are alphabetized (place
webgl/2.0.y/conformance2/textures/image_bitmap_from_video before
webgl/2.0.y/conformance2/textures/video, and ensure
webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html
is in the correct alphabetical position within the same block) while preserving
the existing status tokens and the subsequent webkit.org/... lines (e.g., the
entries referencing tex-2d-r16f-red-float.html and
tex-2d-rgb8ui-rgb_integer-unsigned_byte.html).
In `@LayoutTests/TestExpectations`:
- Line 4836: The TestExpectations entry "webkit.org/b/313392
webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html" is missing the
required bracketed expectation; either add an explicit expectation status (for
example change it to "webkit.org/b/313392 [ Failure ]
webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html" or
"webkit.org/b/313392 [ Skip ]
webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html") or delete the
entire line if no override is intended, ensuring the entry matches the
TestExpectations format used elsewhere.
In `@LayoutTests/webgl/TestExpectations`:
- Around line 26-30: The TestExpectations file contains a duplicated test
expectation line for
"webgl/2.0.y/deqp/functional/gles3/uniformbuffers/single_struct.html [ Pass
Failure ]"; remove the duplicate so only one entry for single_struct.html
remains, preserving the exact expectation format and order of other lines (leave
the other entries like single_basic_type.html, instance_array_basic_type.html,
and random.html unchanged).
In `@Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cpp`:
- Around line 1756-1766: The bounds facts for StringCharCodeAt and
StringCodePointAt are being attached unconditionally, which is unsound because
these ops can bail on out-of-bounds; guard those setRelationship(...) calls with
a check of node->arrayMode().isInBounds() similar to the GetByVal pattern so the
Relationships (using m_zero, Relationship::GreaterThan and
Relationship::LessThan) are only set when the index is proven in-bounds.
In `@Source/JavaScriptCore/wasm/WasmTypeDefinition.cpp`:
- Around line 1239-1265: appendToWorkIfNeeded currently enqueues only the
expanded payload (TypeInformation::get(type.index).expand()), dropping wrapper
TypeDefinition like Subtype/Projection/RecursionGroup and causing dangling
TypeIndex after tryCleanup; change appendToWorkIfNeeded to obtain the raw
referenced TypeDefinition (via TypeInformation::get(type.index) or the
appropriate accessor that returns the wrapper TypeDefinition) and append that to
WorkList instead of—or in addition to—the expanded form, and ensure
WebAssemblyGCTypeDependencies::process (and its callers like process for
FunctionSignature) continue to operate on the wrapper TypeDefinition so wrapper
nodes are retained in the dependency closure.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
Run ID: a434059d-9e88-4659-b0cd-7d13352b4af6
⛔ Files ignored due to path filters (3)
LayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/w3c-import.logis excluded by!**/*.logLayoutTests/imported/w3c/web-platform-tests/html/syntax/speculative-parsing/generated/document-write/svg-script-src.tentative.sub-expected.txtis excluded by!**/generated/**LayoutTests/imported/w3c/web-platform-tests/html/syntax/speculative-parsing/generated/page-load/svg-script-src.tentative-expected.txtis excluded by!**/generated/**
📒 Files selected for processing (183)
JSTests/microbenchmarks/array-prototype-lastIndexOf-contiguous-long.jsJSTests/microbenchmarks/array-prototype-lastIndexOf-int32-long.jsJSTests/microbenchmarks/bigint64-array-last-index-of-large.jsJSTests/microbenchmarks/bigint64-array-last-index-of-medium.jsJSTests/microbenchmarks/bigint64-array-last-index-of-small.jsJSTests/microbenchmarks/biguint64-array-last-index-of-large.jsJSTests/microbenchmarks/biguint64-array-last-index-of-medium.jsJSTests/microbenchmarks/biguint64-array-last-index-of-small.jsJSTests/microbenchmarks/float32-array-last-index-of-large.jsJSTests/microbenchmarks/float32-array-last-index-of-medium.jsJSTests/microbenchmarks/float32-array-last-index-of-small.jsJSTests/microbenchmarks/float64-array-last-index-of-large.jsJSTests/microbenchmarks/float64-array-last-index-of-medium.jsJSTests/microbenchmarks/float64-array-last-index-of-small.jsJSTests/microbenchmarks/int16-array-last-index-of-large.jsJSTests/microbenchmarks/int16-array-last-index-of-medium.jsJSTests/microbenchmarks/int16-array-last-index-of-small.jsJSTests/microbenchmarks/int32-array-last-index-of-large.jsJSTests/microbenchmarks/int32-array-last-index-of-medium.jsJSTests/microbenchmarks/int32-array-last-index-of-small.jsJSTests/microbenchmarks/int8-array-last-index-of-large.jsJSTests/microbenchmarks/int8-array-last-index-of-medium.jsJSTests/microbenchmarks/int8-array-last-index-of-small.jsJSTests/microbenchmarks/string-equality-256-8bit.jsJSTests/microbenchmarks/string-equality-long-8bit.jsJSTests/microbenchmarks/string-equality-short-8bit.jsJSTests/microbenchmarks/typed-array-lastIndexOf-empty.jsJSTests/microbenchmarks/uint16-array-last-index-of-large.jsJSTests/microbenchmarks/uint16-array-last-index-of-medium.jsJSTests/microbenchmarks/uint16-array-last-index-of-small.jsJSTests/microbenchmarks/uint32-array-last-index-of-large.jsJSTests/microbenchmarks/uint32-array-last-index-of-medium.jsJSTests/microbenchmarks/uint32-array-last-index-of-small.jsJSTests/microbenchmarks/uint8-array-last-index-of-large.jsJSTests/microbenchmarks/uint8-array-last-index-of-medium.jsJSTests/microbenchmarks/uint8-array-last-index-of-small.jsJSTests/microbenchmarks/uint8-clamped-array-last-index-of-large.jsJSTests/microbenchmarks/uint8-clamped-array-last-index-of-medium.jsJSTests/microbenchmarks/uint8-clamped-array-last-index-of-small.jsJSTests/modules/namespace-single-walk.jsJSTests/modules/namespace-single-walk/conflict-only.jsJSTests/modules/namespace-single-walk/cycle-a.jsJSTests/modules/namespace-single-walk/cycle-b.jsJSTests/modules/namespace-single-walk/leaf-a.jsJSTests/modules/namespace-single-walk/leaf-b.jsJSTests/modules/namespace-single-walk/mid-left.jsJSTests/modules/namespace-single-walk/mid-right.jsJSTests/modules/namespace-single-walk/root.jsJSTests/stress/comma-in-condition-context.jsJSTests/stress/integer-range-optimization-arith-bit-and-or.jsJSTests/stress/integer-range-optimization-string-char-code-at.jsJSTests/stress/string-equality-word-compare.jsJSTests/wasm/regress/wasm-tag-retains-reachable-types.jsLayoutTests/TestExpectationsLayoutTests/fast/dom/crash-with-bad-url.htmlLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-columns-expected.txtLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-columns.htmlLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-document-expected.txtLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-document.htmlLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-iframes-expected.txtLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-iframes.htmlLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-window-expected.txtLayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-window.htmlLayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote-expected.htmlLayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote.htmlLayoutTests/fast/scrolling/scrollbar-gutter-stable-rtl-viewport-expected.htmlLayoutTests/fast/scrolling/scrollbar-gutter-stable-rtl-viewport.htmlLayoutTests/fast/table/blocks-in-inline-table-cell-height-expected.htmlLayoutTests/fast/table/blocks-in-inline-table-cell-height.htmlLayoutTests/fast/webgpu/regression/repro_1380-expected.txtLayoutTests/fast/webgpu/regression/repro_1380b-expected.txtLayoutTests/fast/webgpu/regression/repro_1380d-expected.txtLayoutTests/http/tests/IndexedDB/resources/commit-then-stop-frame.htmlLayoutTests/http/tests/IndexedDB/transaction-commit-pending-requests-stop-expected.txtLayoutTests/http/tests/IndexedDB/transaction-commit-pending-requests-stop.htmlLayoutTests/http/tests/site-isolation/inspector/dom/getDocument-frame-target-expected.txtLayoutTests/http/tests/site-isolation/inspector/dom/getDocument-frame-target.htmlLayoutTests/http/tests/site-isolation/inspector/dom/resources/dom-frame.htmlLayoutTests/http/tests/text-extraction/debug-text-extraction-subframes-expected.txtLayoutTests/http/tests/webgpu/webgpu/api/operation/adapter/requestDevice-expected.txtLayoutTests/http/tests/webgpu/webgpu/api/validation/capability_checks/limits/maxStorageBuffersInFragmentStage-expected.txtLayoutTests/http/tests/webgpu/webgpu/api/validation/capability_checks/limits/maxStorageBuffersInVertexStage-expected.txtLayoutTests/http/tests/webgpu/webgpu/api/validation/capability_checks/limits/maxStorageTexturesInFragmentStage-expected.txtLayoutTests/http/tests/webgpu/webgpu/api/validation/capability_checks/limits/maxStorageTexturesInVertexStage-expected.txtLayoutTests/http/tests/webgpu/webgpu/api/validation/createPipelineLayout-expected.txtLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/anchor-scroll-implicit-001.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/anchor-scroll-implicit-002.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-auto-pseudo-element-implicit-001-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-auto-pseudo-element-implicit-001.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-auto-pseudo-element-implicit-002-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-auto-pseudo-element-implicit-002.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-basics-expected.txtLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-basics.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-none-pseudo-element-implicit-001-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-none-pseudo-element-implicit-001.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-none-pseudo-element-implicit-002-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-none-pseudo-element-implicit-002.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-none-pseudo-element-named-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-none-pseudo-element-named.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-normal-pseudo-element-implicit-001-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-normal-pseudo-element-implicit-001.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-normal-pseudo-element-implicit-002-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-normal-pseudo-element-implicit-002.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-normal-pseudo-element-implicit-003-expected.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-anchor-position/position-anchor-normal-pseudo-element-implicit-003.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-animations/crashtests/transform-properties-from-none-to-none-crash.htmlLayoutTests/imported/w3c/web-platform-tests/css/css-tables/absolute-tables-height-001-expected.txtLayoutTests/imported/w3c/web-platform-tests/css/css-tables/absolute-tables-height-001.htmlLayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/moveBefore-id-map-expected.txtLayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/moveBefore-id-map.htmlLayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/moveBefore-name-map-expected.txtLayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/moveBefore-name-map.htmlLayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/script-move-before-expected.txtLayoutTests/imported/w3c/web-platform-tests/dom/nodes/moveBefore/script-move-before.htmlLayoutTests/imported/w3c/web-platform-tests/html/dom/elements/global-attributes/the-anchor-attribute-003.tentative.htmlLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/messagechannel.any-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/messagechannel.any.serviceworker-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/messagechannel.any.sharedworker-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/messagechannel.any.worker-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/no-coop-coep.https.any-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/no-coop-coep.https.any.serviceworker-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/no-coop-coep.https.any.sharedworker-expected.txtLayoutTests/imported/w3c/web-platform-tests/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/no-coop-coep.https.any.worker-expected.txtLayoutTests/imported/w3c/web-platform-tests/largest-contentful-paint/lcp-buffer-size-expected.txtLayoutTests/imported/w3c/web-platform-tests/largest-contentful-paint/lcp-buffer-size.htmlLayoutTests/imported/w3c/web-platform-tests/svg/animations/repeat-iteration-event-002-expected.txtLayoutTests/imported/w3c/web-platform-tests/svg/animations/repeat-iteration-event-003-expected.txtLayoutTests/imported/w3c/web-platform-tests/svg/animations/repeat-iteration-event-004-expected.txtLayoutTests/imported/w3c/web-platform-tests/svg/animations/smil-clock-value-parsing-expected.txtLayoutTests/imported/w3c/web-platform-tests/user-timing/measures-expected.txtLayoutTests/imported/w3c/web-platform-tests/workers/semantics/structured-clone/dedicated-expected.txtLayoutTests/imported/w3c/web-platform-tests/workers/semantics/structured-clone/shared-expected.txtLayoutTests/js/Atomics-waitasync-invocable-on-main-thread.htmlLayoutTests/js/dom/webassembly-memory-shared-basic.htmlLayoutTests/media/iframe-load-html-as-m2ts-expected.txtLayoutTests/media/iframe-load-html-as-m2ts.htmlLayoutTests/media/video-source-mime-sniff-mp4-expected.txtLayoutTests/media/video-source-mime-sniff-mp4.htmlLayoutTests/media/video-source-mime-sniff-webm-expected.txtLayoutTests/media/video-source-mime-sniff-webm.htmlLayoutTests/platform/glib/TestExpectationsLayoutTests/platform/glib/fast/forms/auto-fill-button/input-strong-password-auto-fill-button-expected.txtLayoutTests/platform/glib/fast/text/system-font-features-expected.htmlLayoutTests/platform/glib/fast/text/system-font-legacy-name-expected.txtLayoutTests/platform/gtk-wayland/TestExpectationsLayoutTests/platform/gtk/TestExpectationsLayoutTests/platform/ios-site-isolation/TestExpectationsLayoutTests/platform/ios/TestExpectationsLayoutTests/platform/mac-site-isolation/TestExpectationsLayoutTests/platform/mac-wk2/TestExpectationsLayoutTests/platform/mac/TestExpectationsLayoutTests/platform/win/TestExpectationsLayoutTests/platform/wk2/TestExpectationsLayoutTests/platform/wpe/TestExpectationsLayoutTests/webaudio/dom-exceptions.htmlLayoutTests/webgl/TestExpectationsLayoutTests/webgl/webgl-allow-shared-typed-array.htmlLayoutTests/webgl/webgl-allow-shared.htmlLayoutTests/workers/worker-set-delete-terminate-crash.htmlLayoutTests/workers/worker-terminate-crash.htmlSource/JavaScriptCore/b3/B3OptimizeAssociativeExpressionTrees.cppSource/JavaScriptCore/b3/B3ReduceStrength.cppSource/JavaScriptCore/b3/testb3.hSource/JavaScriptCore/b3/testb3_1.cppSource/JavaScriptCore/bytecompiler/NodesCodegen.cppSource/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cppSource/JavaScriptCore/dfg/DFGSpeculativeJIT.cppSource/JavaScriptCore/ftl/FTLLowerDFGToB3.cppSource/JavaScriptCore/inspector/protocol/DOM.jsonSource/JavaScriptCore/parser/Nodes.hSource/JavaScriptCore/runtime/AbstractModuleRecord.cppSource/JavaScriptCore/runtime/AbstractModuleRecord.hSource/JavaScriptCore/runtime/ArrayPrototype.cppSource/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototypeFunctions.hSource/JavaScriptCore/runtime/StableSort.hSource/JavaScriptCore/runtime/VM.cppSource/JavaScriptCore/runtime/WaiterListManager.cppSource/JavaScriptCore/wasm/WasmTag.hSource/JavaScriptCore/wasm/WasmTypeDefinition.cppSource/JavaScriptCore/wasm/WasmTypeDefinition.hSource/JavaScriptCore/wasm/js/WebAssemblyGCStructure.cppSource/JavaScriptCore/wasm/js/WebAssemblyGCStructure.hSource/ThirdParty/ANGLE/.gitmodules
💤 Files with no reviewable changes (11)
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-iframes-expected.txt
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-window-expected.txt
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-columns-expected.txt
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-iframes.html
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-window.html
- LayoutTests/platform/wk2/TestExpectations
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-document.html
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-columns.html
- LayoutTests/fast/events/touch/ios/touch-event-regions-layer-tree/dblclick-document-expected.txt
- LayoutTests/platform/gtk-wayland/TestExpectations
- LayoutTests/platform/ios-site-isolation/TestExpectations
| @@ -0,0 +1,15 @@ | |||
| //@ memoryHog! | |||
There was a problem hiding this comment.
Remove //@ memoryHog! from this medium benchmark.
For a 4096-element medium test, this classification is likely too strong and may unnecessarily exclude or de-prioritize the benchmark in standard runs.
Suggested patch
-//@ memoryHog!
let size = 4096;📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| //@ memoryHog! | |
| let size = 4096; |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@JSTests/microbenchmarks/float32-array-last-index-of-medium.js` at line 1,
Remove the "//@ memoryHog!" annotation from the top of the
JSTests/microbenchmarks/float32-array-last-index-of-medium.js benchmark file so
it is no longer classified as a heavy memory hog; locate the file and delete
that single comment line (no other changes needed), then run the benchmark suite
to confirm it now runs as a medium test.
| @@ -0,0 +1,15 @@ | |||
| //@ memoryHog! | |||
There was a problem hiding this comment.
Remove //@ memoryHog! from this small benchmark.
At Line 1, this test only allocates 16 Float64 elements, so the memory-hog annotation looks misplaced and may misclassify/schedule the benchmark unnecessarily.
Proposed fix
-//@ memoryHog!📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| //@ memoryHog! |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@JSTests/microbenchmarks/float64-array-last-index-of-small.js` at line 1,
Remove the misplaced `//@ memoryHog!` annotation from the top of the small
benchmark (float64-array-last-index-of-small.js) — locate the comment `//@
memoryHog!` and delete it so the test, which only allocates 16 Float64 elements,
is not misclassified or scheduled as a memory-hog benchmark.
| @@ -0,0 +1,14 @@ | |||
| let size = 20 << 20; | |||
There was a problem hiding this comment.
Add //@ memoryHog! for this large variant.
This benchmark allocates a large backing store and should be classified consistently with other large *-last-index-of-large.js tests to avoid unintended scheduling/memory pressure behavior.
Suggested patch
+//@ memoryHog!
let size = 20 << 20;📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| let size = 20 << 20; | |
| //@ memoryHog! | |
| let size = 20 << 20; |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@JSTests/microbenchmarks/int16-array-last-index-of-large.js` at line 1, Add
the memoryHog annotation to this large benchmark file so the test harness treats
it as a large allocation; specifically, insert the single-line comment "//@
memoryHog!" near the top of
JSTests/microbenchmarks/int16-array-last-index-of-large.js (before or above the
declaration of the large backing-store size variable `size` which is defined as
`let size = 20 << 20;`) so the test is classified consistently with other
*-last-index-of-large.js tests.
| (async () => { | ||
| for (let i = 0; i < 100; i++) { | ||
| const it = gen(0, 1); | ||
| shouldBe(it.next().value, "T", "generator truthy"); | ||
| const it2 = gen(1, 0); | ||
| shouldBe(it2.next().value, "F", "generator falsy"); | ||
|
|
||
| shouldBe(await asyncFn(0, 1), "T", "async truthy"); | ||
| shouldBe(await asyncFn(1, 0), "F", "async falsy"); | ||
| } | ||
| })(); | ||
|
|
||
| // ========================================================================= | ||
| // Switch | ||
| // ========================================================================= | ||
|
|
||
| function testSwitch(a, b) { | ||
| switch (true) { | ||
| case (a, b > 5): | ||
| return "big"; | ||
| case (a, b > 0): | ||
| return "small"; | ||
| default: | ||
| return "none"; | ||
| } | ||
| } | ||
| noInline(testSwitch); | ||
|
|
||
| for (let i = 0; i < 1e3; i++) { | ||
| shouldBe(testSwitch(99, 10), "big"); | ||
| shouldBe(testSwitch(99, 3), "small"); | ||
| shouldBe(testSwitch(99, -1), "none"); | ||
| shouldBe(testSwitch(99, 0), "none"); | ||
| } | ||
|
|
||
| print("PASS"); |
There was a problem hiding this comment.
Wait for the async assertions before printing PASS.
The async IIFE returns immediately, so print("PASS") can run before the await asyncFn(...) checks finish. That makes this test capable of reporting success even if the async cases fail later.
Proposed fix
-(async () => {
+const runAsyncChecks = async () => {
for (let i = 0; i < 100; i++) {
const it = gen(0, 1);
shouldBe(it.next().value, "T", "generator truthy");
@@
shouldBe(await asyncFn(0, 1), "T", "async truthy");
shouldBe(await asyncFn(1, 0), "F", "async falsy");
}
-})();
-
-print("PASS");
+};
+
+runAsyncChecks().then(() => {
+ print("PASS");
+}, error => {
+ throw error;
+});🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@JSTests/stress/comma-in-condition-context.js` around lines 301 - 336, The
top-level async IIFE that runs the generator and asyncFn checks is not awaited,
so print("PASS") can execute before the async assertions complete; capture and
await the IIFE (or explicitly await its Promise) before calling print("PASS") so
the test only prints PASS after the await asyncFn(...) assertions finish —
update the anonymous async IIFE invocation near the top of the file and ensure
print("PASS") runs only after that Promise resolves (referring to the async IIFE
and the print("PASS") call).
| <html> | ||
| <head> | ||
| <style> | ||
| body { font-family: Ahem; font-size: 16px; } | ||
| </style> | ||
| </head> |
There was a problem hiding this comment.
Add missing document metadata required by HTML linting.
<html> is missing lang, and <head> is missing <title>. This will keep triggering the current HTMLHint warning/error.
Suggested patch
-<html>
+<html lang="en">
<head>
+<title>list-marker-with-empty-inline-before-blockquote expected</title>
<style>
body { font-family: Ahem; font-size: 16px; }
</style>
</head>📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| <html> | |
| <head> | |
| <style> | |
| body { font-family: Ahem; font-size: 16px; } | |
| </style> | |
| </head> | |
| <html lang="en"> | |
| <head> | |
| <title>list-marker-with-empty-inline-before-blockquote expected</title> | |
| <style> | |
| body { font-family: Ahem; font-size: 16px; } | |
| </style> | |
| </head> |
🧰 Tools
🪛 HTMLHint (1.9.2)
[warning] 2-2: An lang attribute must be present on elements.
(html-lang-require)
[error] 7-7: <title> must be present in tag.
(title-require)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In
`@LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote-expected.html`
around lines 2 - 7, The file is missing required HTML metadata: add a lang
attribute to the <html> element (e.g., <html lang="en">) and add a <title>
element inside the <head> (e.g., <title>Test</title>) so the document satisfies
HTMLHint; update the existing <html> and <head> elements accordingly.
| webgl/2.0.y/conformance2/textures/video [ Skip ] | ||
| webgl/2.0.y/conformance2/textures/image_bitmap_from_video [ Skip ] | ||
| webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html [ Skip ] | ||
|
|
||
| webkit.org/b/280603 webgl/2.0.0/conformance2/textures/video/tex-2d-r16f-red-float.html [ Failure Timeout Pass ] | ||
| webkit.org/b/280603 webgl/2.0.0/conformance2/textures/video/tex-2d-rgb8ui-rgb_integer-unsigned_byte.html [ Timeout Pass ] | ||
| webkit.org/b/280603 webgl/2.0.y/conformance2/textures/video/tex-2d-r16f-red-float.html [ Failure Timeout Pass ] | ||
| webkit.org/b/280603 webgl/2.0.y/conformance2/textures/video/tex-2d-rgb8ui-rgb_integer-unsigned_byte.html [ Timeout Pass ] |
There was a problem hiding this comment.
🧹 Nitpick | 🔵 Trivial | ⚡ Quick win
Keep the new WebGL2 expectations alphabetized.
The triage block explicitly requires alphabetical ordering, but these new entries are inserted out of order (video before image_bitmap_from_video and misc). Please reorder them to keep the section easy to diff and reason about.
♻️ Suggested reorder
-webgl/2.0.y/conformance2/textures/video [ Skip ]
-webgl/2.0.y/conformance2/textures/image_bitmap_from_video [ Skip ]
-webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html [ Skip ]
+webgl/2.0.y/conformance2/textures/image_bitmap_from_video [ Skip ]
+webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html [ Skip ]
+webgl/2.0.y/conformance2/textures/video [ Skip ]📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| webgl/2.0.y/conformance2/textures/video [ Skip ] | |
| webgl/2.0.y/conformance2/textures/image_bitmap_from_video [ Skip ] | |
| webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html [ Skip ] | |
| webkit.org/b/280603 webgl/2.0.0/conformance2/textures/video/tex-2d-r16f-red-float.html [ Failure Timeout Pass ] | |
| webkit.org/b/280603 webgl/2.0.0/conformance2/textures/video/tex-2d-rgb8ui-rgb_integer-unsigned_byte.html [ Timeout Pass ] | |
| webkit.org/b/280603 webgl/2.0.y/conformance2/textures/video/tex-2d-r16f-red-float.html [ Failure Timeout Pass ] | |
| webkit.org/b/280603 webgl/2.0.y/conformance2/textures/video/tex-2d-rgb8ui-rgb_integer-unsigned_byte.html [ Timeout Pass ] | |
| webgl/2.0.y/conformance2/textures/image_bitmap_from_video [ Skip ] | |
| webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html [ Skip ] | |
| webgl/2.0.y/conformance2/textures/video [ Skip ] | |
| webkit.org/b/280603 webgl/2.0.y/conformance2/textures/video/tex-2d-r16f-red-float.html [ Failure Timeout Pass ] | |
| webkit.org/b/280603 webgl/2.0.y/conformance2/textures/video/tex-2d-rgb8ui-rgb_integer-unsigned_byte.html [ Timeout Pass ] |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@LayoutTests/platform/wpe/TestExpectations` around lines 857 - 862, The triage
block entries in TestExpectations are out of alphabetical order; reorder the
three new WebGL2 texture expectations so they are alphabetized (place
webgl/2.0.y/conformance2/textures/image_bitmap_from_video before
webgl/2.0.y/conformance2/textures/video, and ensure
webgl/2.0.y/conformance2/textures/misc/tex-image-with-bad-args-from-dom-elements.html
is in the correct alphabetical position within the same block) while preserving
the existing status tokens and the subsequent webkit.org/... lines (e.g., the
entries referencing tex-2d-r16f-red-float.html and
tex-2d-rgb8ui-rgb_integer-unsigned_byte.html).
| webkit.org/b/292182 webgl/2.0.y/conformance/textures/misc/texture-video-transparent.html [ Failure Pass ] | ||
| webkit.org/b/292182 webgl/2.0.y/conformance2/rendering/clipping-wide-points.html [ Failure Pass ] | ||
|
|
||
| webkit.org/b/313392 webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Find TestExpectations files and report lines that look like rules but have no [ ... ] expectation.
fd -a '^TestExpectations$' LayoutTests | while read -r f; do
echo "== $f =="
rg -n '^\s*(webkit\.org/b/\d+\s+)?\S+\s*$' "$f" \
| rg -v '^\s*[0-9]+:\s*(#|$)' \
| rg -v '\[[^]]+\]'
doneRepository: oven-sh/WebKit
Length of output: 118
🏁 Script executed:
# Find all TestExpectations files and check which ones might contain line 4836
fd -t f 'TestExpectations$' LayoutTests | head -20Repository: oven-sh/WebKit
Length of output: 1004
🏁 Script executed:
# Count lines in the main TestExpectations file to verify line 4836 exists
if [ -f "LayoutTests/TestExpectations" ]; then
wc -l "LayoutTests/TestExpectations"
echo "---"
sed -n '4836p' "LayoutTests/TestExpectations" | cat -A
fiRepository: oven-sh/WebKit
Length of output: 177
🏁 Script executed:
# Show context around line 4836
if [ -f "LayoutTests/TestExpectations" ]; then
sed -n '4830,4840p' "LayoutTests/TestExpectations" | cat -n
fiRepository: oven-sh/WebKit
Length of output: 888
Add expectation status to line 4836 in LayoutTests/TestExpectations.
Line 4836 contains a bug-id and test path but is missing the bracketed expectation status that all valid TestExpectations entries require. Add an explicit status (e.g., [ Failure ], [ Skip ]) or remove the line entirely if no override is intended.
webkit.org/b/313392 webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@LayoutTests/TestExpectations` at line 4836, The TestExpectations entry
"webkit.org/b/313392
webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html" is missing the
required bracketed expectation; either add an explicit expectation status (for
example change it to "webkit.org/b/313392 [ Failure ]
webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html" or
"webkit.org/b/313392 [ Skip ]
webgl/2.0.y/conformance2/textures/misc/tex-image-10bpc.html") or delete the
entire line if no override is intended, ensuring the entry matches the
TestExpectations format used elsewhere.
| webkit.org/b/244979 webgl/2.0.y/deqp/functional/gles3/uniformbuffers/single_struct.html [ Pass Failure ] | ||
| webkit.org/b/244979 webgl/2.0.y/deqp/functional/gles3/uniformbuffers/single_basic_type.html [ Pass Failure ] | ||
| webkit.org/b/244979 webgl/2.0.y/deqp/functional/gles3/uniformbuffers/instance_array_basic_type.html [ Pass Failure ] | ||
| webkit.org/b/244979 webgl/2.0.y/deqp/functional/gles3/uniformbuffers/random.html [ Pass Failure ] | ||
| webkit.org/b/244979 webgl/2.0.y/deqp/functional/gles3/uniformbuffers/single_struct.html [ Pass Failure ] |
There was a problem hiding this comment.
Remove the duplicated single_struct.html expectation.
webgl/2.0.y/deqp/functional/gles3/uniformbuffers/single_struct.html is listed twice with the same Pass Failure outcome. Keeping both entries adds noise and can obscure future edits.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@LayoutTests/webgl/TestExpectations` around lines 26 - 30, The
TestExpectations file contains a duplicated test expectation line for
"webgl/2.0.y/deqp/functional/gles3/uniformbuffers/single_struct.html [ Pass
Failure ]"; remove the duplicate so only one entry for single_struct.html
remains, preserving the exact expectation format and order of other lines (leave
the other entries like single_basic_type.html, instance_array_basic_type.html,
and random.html unchanged).
| case StringCharCodeAt: { | ||
| setRelationship(Relationship(node, m_zero, Relationship::GreaterThan, -1)); | ||
| setRelationship(Relationship(node, m_zero, Relationship::LessThan, (static_cast<int32_t>(std::numeric_limits<char16_t>::max()) + 1))); | ||
| break; | ||
| } | ||
|
|
||
| case StringCodePointAt: { | ||
| setRelationship(Relationship(node, m_zero, Relationship::GreaterThan, -1)); | ||
| setRelationship(Relationship(node, m_zero, Relationship::LessThan, (static_cast<int32_t>(0x10FFFF) + 1))); | ||
| break; | ||
| } |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
rg -nC 4 '\bStringCharCodeAt\b|\bStringCodePointAt\b' Source/JavaScriptCore JSTestsRepository: oven-sh/WebKit
Length of output: 20509
🏁 Script executed:
# Check the ArrayMode implementation and alreadyChecked() behavior
rg -nA 15 'ArrayMode::alreadyChecked' Source/JavaScriptCoreRepository: oven-sh/WebKit
Length of output: 2668
🏁 Script executed:
# Look at the lowering implementations to understand out-of-bounds behavior
rg -nB 5 -A 15 'compileStringCharCodeAt|compileStringCodePointAt' Source/JavaScriptCoreRepository: oven-sh/WebKit
Length of output: 13178
🏁 Script executed:
# Check DFGSSALoweringPhase to see lowerStringBoundsCheck implementation
rg -nB 3 -A 10 'lowerStringBoundsCheck' Source/JavaScriptCore/dfg/DFGSSALoweringPhase.cppRepository: oven-sh/WebKit
Length of output: 1183
🏁 Script executed:
# Examine the test file for clues about expected behavior
head -100 JSTests/stress/integer-range-optimization-string-char-code-at.jsRepository: oven-sh/WebKit
Length of output: 2187
🏁 Script executed:
# Get more context around the case statement in DFGIntegerRangeOptimizationPhase
sed -n '1750,1780p' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cppRepository: oven-sh/WebKit
Length of output: 1691
🏁 Script executed:
# Check if there's any arrayMode checking in the phase or if it operates unconditionally
rg -nB 10 'case StringCharCodeAt:' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cpp | head -40Repository: oven-sh/WebKit
Length of output: 537
🏁 Script executed:
# Look for how the phase determines when to apply bounds facts
rg -n 'arrayMode|isInBounds' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cppRepository: oven-sh/WebKit
Length of output: 344
🏁 Script executed:
# Get the full context around the guard check to see which cases are covered
sed -n '1780,1810p' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cppRepository: oven-sh/WebKit
Length of output: 1809
🏁 Script executed:
# Get broader context to see the structure - look for where StringCharCodeAt case sits relative to GetByVal
sed -n '1750,1770p' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cppRepository: oven-sh/WebKit
Length of output: 1060
🏁 Script executed:
# Also check what comes before GetByVal to see if StringCharCodeAt is separate
sed -n '1740,1760p' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cppRepository: oven-sh/WebKit
Length of output: 1130
🏁 Script executed:
# Confirm the structure - get line counts to see exact boundaries
sed -n '1755,1785p' Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cpp | cat -nRepository: oven-sh/WebKit
Length of output: 1753
🏁 Script executed:
# Confirm what the out-of-bounds case returns by checking the lowering
sed -n '11491,11535p' Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cppRepository: oven-sh/WebKit
Length of output: 1933
Guard these string bounds facts by arrayMode.isInBounds().
StringCharCodeAt / StringCodePointAt can produce out-of-bounds accesses that bail out speculatively. Attaching bounds facts unconditionally is unsound—these facts should only apply when the index is proven valid, matching the pattern used for GetByVal (see line 1786).
Recommended fix pattern
case StringCharCodeAt: {
if (node->arrayMode().isInBounds()) {
setRelationship(Relationship(node, m_zero, Relationship::GreaterThan, -1));
setRelationship(Relationship(node, m_zero, Relationship::LessThan, (static_cast<int32_t>(std::numeric_limits<char16_t>::max()) + 1)));
}
break;
}
case StringCodePointAt: {
if (node->arrayMode().isInBounds()) {
setRelationship(Relationship(node, m_zero, Relationship::GreaterThan, -1));
setRelationship(Relationship(node, m_zero, Relationship::LessThan, (static_cast<int32_t>(0x10FFFF) + 1)));
}
break;
}🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@Source/JavaScriptCore/dfg/DFGIntegerRangeOptimizationPhase.cpp` around lines
1756 - 1766, The bounds facts for StringCharCodeAt and StringCodePointAt are
being attached unconditionally, which is unsound because these ops can bail on
out-of-bounds; guard those setRelationship(...) calls with a check of
node->arrayMode().isInBounds() similar to the GetByVal pattern so the
Relationships (using m_zero, Relationship::GreaterThan and
Relationship::LessThan) are only set when the index is proven in-bounds.
| inline static void appendToWorkIfNeeded(Type type, WebAssemblyGCTypeDependencies::WorkList& work) | ||
| { | ||
| if (isRefWithTypeIndex(type)) { | ||
| SUPPRESS_UNCHECKED_LOCAL const auto& referencedType = TypeInformation::get(type.index).expand(); | ||
| work.append(referencedType); | ||
| } | ||
| } | ||
|
|
||
| void WebAssemblyGCTypeDependencies::process(const TypeDefinition& typeDef, WorkList& work) | ||
| { | ||
| if (m_typeDefinitions.contains(typeHash(typeDef))) | ||
| return; | ||
| m_typeDefinitions.add(typeHash(typeDef)); | ||
|
|
||
| if (typeDef.is<StructType>()) { | ||
| SUPPRESS_UNCHECKED_LOCAL auto* structType = typeDef.as<StructType>(); | ||
| for (unsigned i = 0; i < structType->fieldCount(); ++i) | ||
| process(structType->field(i), work); | ||
| } else if (typeDef.is<ArrayType>()) { | ||
| process(typeDef.as<ArrayType>()->elementType(), work); | ||
| } else if (typeDef.is<FunctionSignature>()) { | ||
| SUPPRESS_UNCHECKED_LOCAL auto* signature = typeDef.as<FunctionSignature>(); | ||
| for (unsigned i = 0; i < signature->argumentCount(); ++i) | ||
| appendToWorkIfNeeded(signature->argumentType(i), work); | ||
| for (unsigned i = 0; i < signature->returnCount(); ++i) | ||
| appendToWorkIfNeeded(signature->returnType(i), work); | ||
| } |
There was a problem hiding this comment.
Retain the referenced wrapper type, not just its expansion.
appendToWorkIfNeeded() currently enqueues TypeInformation::get(type.index).expand(). That keeps the concrete payload alive, but drops wrapper TypeDefinitions such as Subtype/Projection/RecursionGroup, so a GC object or tag can still end up with a dangling TypeIndex after tryCleanup().
Please retain the raw referenced TypeDefinition in the dependency closure, or extend the traversal to preserve both the wrapper and its expanded form.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@Source/JavaScriptCore/wasm/WasmTypeDefinition.cpp` around lines 1239 - 1265,
appendToWorkIfNeeded currently enqueues only the expanded payload
(TypeInformation::get(type.index).expand()), dropping wrapper TypeDefinition
like Subtype/Projection/RecursionGroup and causing dangling TypeIndex after
tryCleanup; change appendToWorkIfNeeded to obtain the raw referenced
TypeDefinition (via TypeInformation::get(type.index) or the appropriate accessor
that returns the wrapper TypeDefinition) and append that to WorkList instead
of—or in addition to—the expanded form, and ensure
WebAssemblyGCTypeDependencies::process (and its callers like process for
FunctionSignature) continue to operate on the wrapper TypeDefinition so wrapper
nodes are retained in the dependency closure.
…hecks bd8dde5 introduced WTF::truncateDoubleToInt{32,64} to address clang exploiting [conv.fpint] UB when static_cast<intN_t>(double) overflows, then swept most call sites. These four were missed: - TypedArrayAdaptors.h toNativeFromDouble (the case from oven-sh/bun#28607 / #179) - TypedArrayAdaptors.h toNativeFromDoubleWithoutCoercion — collapsed to a single int64 truncate + Type-narrow + round-trip; integer narrowing is well-defined so any wrap fails the round-trip - JSCJSValue.h tryConvertToInt52 — feeds isAnyInt / DFG Int52Rep - DFGAbstractInterpreterInlines.h ArithRound/Floor/Ceil/Trunc constant folding Same instruction count (cvttsd2si/fcvtzs via intrinsic/asm) so no codegen change vs the previous behavior on clang <= 21.
209f169 to
2c7f103
Compare
add-apt-repository validates the PPA against the Launchpad API, which intermittently returns "user or team does not exist" when degraded. Write the deb line and fetch the signing key directly so docker build doesn't depend on the API.
…t entry" This reverts commit 8aed073.
…fetch add-apt-repository validates against the Launchpad API, which fails when Launchpad is degraded. Write the deb line directly (HTTPS via the modern ppa.launchpadcontent.net host), fetch the signing key from keyserver.ubuntu.com with curl --retry, and loop apt-get update until gcc-13 actually appears in the index so a transient archive blip doesn't fail the image build.
… (Launchpad intermittent timeouts)
…oesn't retry connect failures)
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@Dockerfile`:
- Around line 69-74: The retry loop mistakenly breaks when apt-cache shows
"Candidate: (none)" because the grep checks only for "Candidate"; update the
loop condition so it only breaks when an actual candidate version exists (e.g.,
extract the Candidate field and ensure it is not "(none)" or explicitly check
for a value other than "(none)"). Replace the current check `apt-cache policy
gcc-13 | grep -q Candidate` with logic that parses the Candidate token (for
example via awk or grep for "Candidate:" then verifying the second field !=
"(none)"), keeping the same retry/backoff loop in the Dockerfile lines
containing the for-loop and the apt-cache check.
- Around line 64-68: Replace the global-trust key placement and source line:
instead of piping the downloaded key into
/etc/apt/trusted.gpg.d/ubuntu-toolchain-r.gpg, dearmor it into a dedicated
keyring file (e.g. /usr/share/keyrings/ubuntu-toolchain-r-archive-keyring.gpg)
and update the PPA source echo (the line writing to ubuntu-toolchain-r.list) to
include the signed-by option referencing that keyring (e.g. deb
[signed-by=/usr/share/keyrings/ubuntu-toolchain-r-archive-keyring.gpg]
https://ppa.launchpadcontent.net/ubuntu-toolchain-r/test/ubuntu
${UBUNTU_CODENAME} main) so the key trust is scoped to this PPA only.
- Around line 75-87: The dpkg check currently only verifies gcc-13, which can
hide failures of other essential packages; update the post-install validation to
assert all core toolchain packages are installed (e.g., gcc-13, g++-13,
libgcc-13-dev, libstdc++-13-dev, and any other packages listed in the apt-get
install line) instead of only gcc-13—replace the single "dpkg -l gcc-13
>/dev/null" with a check that loops over or queries all package names (for
example using dpkg -l or dpkg-query for each of "gcc-13", "g++-13",
"libgcc-13-dev", "libstdc++-13-dev") and exit/fail the build if any are missing
so later steps like update-alternatives (referenced around line 91) won't break
unexpectedly.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
| && for i in 1 2 3 4 5 6; do \ | ||
| apt-get install -y \ | ||
| -o Acquire::Retries=10 \ | ||
| -o Acquire::http::Timeout=30 \ | ||
| -o Acquire::https::Timeout=30 \ | ||
| gcc-13 g++-13 libgcc-13-dev libstdc++-13-dev \ | ||
| libasan6 libubsan1 libatomic1 libtsan0 liblsan0 libgfortran5 libc6-dev \ | ||
| && break; \ | ||
| echo "apt-get install failed (attempt $i), retrying..."; \ | ||
| sleep $((i * 30)); \ | ||
| done \ | ||
| && dpkg -l gcc-13 >/dev/null \ | ||
| && rm -rf /var/lib/apt/lists/* |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
# First, let's locate and examine the Dockerfile to understand the context
git ls-files | grep -i dockerfile | head -20Repository: oven-sh/WebKit
Length of output: 1258
🏁 Script executed:
# Read the main Dockerfile to understand the context
cat -n Dockerfile | head -100Repository: oven-sh/WebKit
Length of output: 4802
🏁 Script executed:
# Check lines 75-87 more carefully and search for how gcc-13 and other packages are used later
cat -n Dockerfile | sed -n '75,100p'Repository: oven-sh/WebKit
Length of output: 1231
🏁 Script executed:
# Let's verify the dpkg-query syntax and validate the concern
# First, let's search for any similar validation patterns in the codebase
rg "dpkg" DockerfileRepository: oven-sh/WebKit
Length of output: 93
🏁 Script executed:
# Let's verify the dpkg-query command syntax that was suggested in the patch
# First, understand what dpkg -l does vs dpkg-query
# Check if dpkg-query is available and verify the suggested syntax
man dpkg-query 2>/dev/null || dpkg-query --help 2>&1 | head -30Repository: oven-sh/WebKit
Length of output: 107
🌐 Web query:
dpkg-query command syntax -W flag format Status check
💡 Result:
dpkg-query syntax for the -W / --show option 1) Basic form - dpkg-query -W [package-name-pattern...] - dpkg-query --show [package-name-pattern...] It “will list all packages matching the given pattern” and the output is based on the --showformat option. If you don’t specify a package-name-pattern, you get matches according to the --list semantics (i.e., it behaves like --list in terms of pattern matching).
Citations:
- 1: https://man7.org/linux/man-pages/man1/dpkg-query.1.html
- 2: https://manpages.ubuntu.com/manpages/jammy/man1/dpkg-query.1.html
🏁 Script executed:
# Verify the dpkg-query syntax for checking package status
# Let's search for documentation on the format string used in the suggestion
web_search "dpkg-query -W -f '\${Status}' package installation check"Repository: oven-sh/WebKit
Length of output: 109
🌐 Web query:
dpkg-query Status field format 'install ok installed'
💡 Result:
The 'Status' field in the dpkg status file (/var/lib/dpkg/status) follows the format: Status: <want> <flag> <status>, where each component is a single word separated by spaces. For 'install ok installed': - <want>: "install" - the desired action is to install the package. - <flag>: "ok" - no installation problems (other possible flags: reinstreq, hold, hold-reinstreq). - <status>: "installed" - all files are installed and configuration was successful (other possible statuses: not-installed, unpacked, half-configured, half-installed, config-files). This indicates a fully and successfully installed package with no errors, desired to remain installed. It corresponds to the abbreviated status "ii" in dpkg-query --list output (i for install wanted, i for installed, no error flag). Examples from status file: Status: install ok installed Status: purge ok installed (want=purge but still installed, e.g., due to dependencies) Status: deinstall ok config-files
Citations:
- 1: http://www.fifi.org/doc/libapt-pkg-doc/dpkg-tech.html/ch1.html
- 2: https://manpages.ubuntu.com/manpages/jammy/man1/dpkg-query.1.html
- 3: https://manpages.debian.org/trixie/dpkg/dpkg-query.1.en.html
- 4: dpkg "purge ok installed" status confuses pkg.installed saltstack/salt#10719
- 5: https://askubuntu.com/questions/898163/what-is-the-file-var-lib-dpkg-status-about-and-why-do-i-need-it
- 6: https://juno.ihep.ac.cn/~blyth/env/notes/linux/ubuntu/dpkg/
Validate all required toolchain packages, not only gcc-13.
The current check at line 86 validates only gcc-13, but the installation loop can exit successfully even if other critical packages like g++-13, libgcc-13-dev, or libstdc++-13-dev fail due to transient issues. This causes build failures in later stages (e.g., update-alternatives at line 91 requires g++-13) that are difficult to diagnose after expensive work.
Validate all core compiler packages:
Suggested patch
- && dpkg -l gcc-13 >/dev/null \
+ && for pkg in gcc-13 g++-13 libgcc-13-dev libstdc++-13-dev; do \
+ dpkg-query -W -f='${Status}' "$pkg" | grep -qx 'install ok installed' \
+ done \🧰 Tools
🪛 Trivy (0.69.3)
[error] 63-87: 'apt-get' missing '--no-install-recommends'
'--no-install-recommends' flag is missed: '. /etc/os-release && curl -fsSL --retry 5 --retry-connrefused "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x60C317803A41BA51845E371A1E9377A2BA9EF27F" | gpg --dearmor -o /etc/apt/trusted.gpg.d/ubuntu-toolchain-r.gpg && echo "deb https://ppa.launchpadcontent.net/ubuntu-toolchain-r/test/ubuntu ${UBUNTU_CODENAME} main" > /etc/apt/sources.list.d/ubuntu-toolchain-r.list && for i in 1 2 3 4 5 6; do apt-get update; apt-cache policy gcc-13 | grep -q Candidate && break; echo "ubuntu-toolchain-r index not fetched (attempt
Rule: DS-0029
(IaC/Dockerfile)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@Dockerfile` around lines 75 - 87, The dpkg check currently only verifies
gcc-13, which can hide failures of other essential packages; update the
post-install validation to assert all core toolchain packages are installed
(e.g., gcc-13, g++-13, libgcc-13-dev, libstdc++-13-dev, and any other packages
listed in the apt-get install line) instead of only gcc-13—replace the single
"dpkg -l gcc-13 >/dev/null" with a check that loops over or queries all package
names (for example using dpkg -l or dpkg-query for each of "gcc-13", "g++-13",
"libgcc-13-dev", "libstdc++-13-dev") and exit/fail the build if any are missing
so later steps like update-alternatives (referenced around line 91) won't break
unexpectedly.
… a GH release Launchpad's PPA host is single-IP and went hard-down for >1h, blocking every Linux Docker build. This script (run once when Launchpad is up) downloads the gcc-13 focal .debs for amd64+arm64, tars them reproducibly, uploads to release tag gcc-13-focal-debs, and prints the Dockerfile RUN block with per-arch SHA-256 pins so dpkg -i can't be subverted by a tampered asset.
…HTTPS) keyserver.ubuntu.com is on the same Canonical infrastructure as the PPA itself; when one is down so is the other. The connection is already TLS-authenticated to ppa.launchpadcontent.net, so trust it directly.
…ependency) Launchpad PPA, API and keyserver.ubuntu.com are all single-IP (185.125.190.80) and went hard-down for ~3h on 2026-05-01, blocking every Linux glibc build. Mirror the focal toolchain-r .debs to oven-sh/WebKit release tag gcc-13-focal-debs and dpkg -i from there with a SHA-256 pin. Base-archive deps (binutils, libisl22, libmpc3, libmpfr6) come from the Azure ubuntu mirror which has been reliable. Regenerate via scripts/mirror-gcc13-debs.sh.
There was a problem hiding this comment.
Actionable comments posted: 1
♻️ Duplicate comments (1)
Dockerfile (1)
72-73:⚠️ Potential issue | 🟡 Minor | ⚡ Quick winAssert fully installed package state, not just dpkg entries.
dpkg -l ... >/dev/nullis a loose check here: it only proves those package records exist, not that they reachedinstall ok installed. After thedpkg -i ... || apt-get install -f -yrecovery path, that can let a partially configured toolchain survive untilupdate-alternativesor the compile smoke test fails later.Suggested patch
- && (dpkg -i /tmp/gcc13/*.deb || apt-get install -f -y) \ - && dpkg -l gcc-13 g++-13 libstdc++-13-dev >/dev/null \ + && (dpkg -i /tmp/gcc13/*.deb || apt-get install -f -y) \ + && for pkg in gcc-13 g++-13 libstdc++-13-dev; do \ + dpkg-query -W -f='${Status}' "$pkg" | grep -qx 'install ok installed'; \ + done \🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@Dockerfile` around lines 72 - 73, The current check using dpkg -l gcc-13 g++-13 libstdc++-13-dev only verifies package entries exist and can allow partially-configured packages to slip through after the dpkg -i ... || apt-get install -f -y recovery; change the health check to assert packages are fully installed by querying each package's Status (e.g., via dpkg-query or dpkg -s) and ensuring the Status string equals "install ok installed" for gcc-13, g++-13 and libstdc++-13-dev before proceeding to update-alternatives or any compile smoke test; if any package is not fully installed, fail the build or re-run apt-get install -y to complete installation.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@Dockerfile`:
- Around line 67-68: The current Dockerfile uses eval to compute
"expected=$GCC13_DEBS_SHA256_${TARGETARCH}", which allows shell interpolation;
replace that with an explicit case switch on TARGETARCH that assigns the correct
checksum string to a local variable (e.g., expected) for each supported
architecture (amd64, arm64, etc.) and emit a clear error/exit for an unexpected
arch. Locate the block that references TARGETARCH and GCC13_DEBS_SHA256_, add a
case/TARGETARCH branch that sets expected to the corresponding
GCC13_DEBS_SHA256_<arch> literal value, and then keep the subsequent echo "... |
sha256sum -c -" step unchanged so unsupported architectures fail fast.
---
Duplicate comments:
In `@Dockerfile`:
- Around line 72-73: The current check using dpkg -l gcc-13 g++-13
libstdc++-13-dev only verifies package entries exist and can allow
partially-configured packages to slip through after the dpkg -i ... || apt-get
install -f -y recovery; change the health check to assert packages are fully
installed by querying each package's Status (e.g., via dpkg-query or dpkg -s)
and ensuring the Status string equals "install ok installed" for gcc-13, g++-13
and libstdc++-13-dev before proceeding to update-alternatives or any compile
smoke test; if any package is not fully installed, fail the build or re-run
apt-get install -y to complete installation.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
| && eval "expected=\$GCC13_DEBS_SHA256_${TARGETARCH}" \ | ||
| && echo "${expected} /tmp/gcc13.tar.gz" | sha256sum -c - \ |
There was a problem hiding this comment.
🧹 Nitpick | 🔵 Trivial | ⚡ Quick win
Replace eval with an explicit architecture switch.
scripts/mirror-gcc13-debs.sh already generates this block with a case statement. Keeping the same shape here removes shell-code interpolation and gives a clearer failure path for unexpected architectures.
Suggested patch
- && eval "expected=\$GCC13_DEBS_SHA256_${TARGETARCH}" \
+ && case "${TARGETARCH}" in \
+ amd64) expected="${GCC13_DEBS_SHA256_amd64}" ;; \
+ arm64) expected="${GCC13_DEBS_SHA256_arm64}" ;; \
+ *) echo "unsupported TARGETARCH=${TARGETARCH}"; exit 1 ;; \
+ esac \🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@Dockerfile` around lines 67 - 68, The current Dockerfile uses eval to compute
"expected=$GCC13_DEBS_SHA256_${TARGETARCH}", which allows shell interpolation;
replace that with an explicit case switch on TARGETARCH that assigns the correct
checksum string to a local variable (e.g., expected) for each supported
architecture (amd64, arm64, etc.) and emit a clear error/exit for an unexpected
arch. Locate the block that references TARGETARCH and GCC13_DEBS_SHA256_, add a
case/TARGETARCH branch that sets expected to the corresponding
GCC13_DEBS_SHA256_<arch> literal value, and then keep the subsequent echo "... |
sha256sum -c -" step unchanged so unsupported architectures fail fast.
Merges upstream through
013da9aa8cc1(154 commits since #203) on top of #203.Notable upstream
e9072ad4757f[libpas] Clean up Windows shutdown handling — addspas_process_is_shutting_down()(runtimeGetProcAddressofRtlDllShutdownInProgress). Subsumes our static-decl shutdown guard; we now use Apple's. Ouris_exitingflag (FLS-ordering) andpas_thread_suspenderstay — different concerns.Cherry-pick: WebKit#63906
IPInt
call_indirect/call_refexception-handler PC-advance fix. Validated: pglite passes on bun#29897.Kept on top
decommit_allocator_range(is_symmetric=false) — load-bearing on Windowsis_exitingflag,pas_thread_suspender, compact-heap lazy-commit, OS-gate widening