Timeline



Aug 15, 2019:

11:53 PM Changeset in webkit [248762] by ysuzuki@apple.com
  • 407 edits in trunk

[WTF] Add makeUnique<T>, which ensures T is fast-allocated, WTF_MAKE_FAST_ALLOCATED annotation part
https://bugs.webkit.org/show_bug.cgi?id=200620

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Three patches including this one were originally one patch. I split it into three pieces to make roll-out easy.
This part, we annotate classes / structs with WTF_MAKE_FAST_ALLOCATED and WTF_MAKE_STRUCT_FAST_ALLOCATED if
they are allocated from std::make_unique. The second patch will switch std::make_unique to WTF::makeUnique and
the third patch will insert a static_assert that makeUnique-allocated class T is FastMalloc-ed.
One insight from this patch is that we tend to forget adding WTF_MAKE_STRUCT_FAST_ALLOCATED if it is just a data struct.

  • debugger/Debugger.h:
  • inspector/scripts/codegen/objc_generator_templates.py:
  • inspector/scripts/tests/all/expected/definitions-with-mac-platform.json-result:
  • inspector/scripts/tests/generic/expected/commands-with-async-attribute.json-result:
  • inspector/scripts/tests/generic/expected/commands-with-optional-call-return-parameters.json-result:
  • inspector/scripts/tests/generic/expected/definitions-with-mac-platform.json-result:
  • inspector/scripts/tests/generic/expected/domain-availability.json-result:
  • inspector/scripts/tests/generic/expected/domains-with-varying-command-sizes.json-result:
  • inspector/scripts/tests/generic/expected/enum-values.json-result:
  • inspector/scripts/tests/generic/expected/events-with-optional-parameters.json-result:
  • inspector/scripts/tests/generic/expected/generate-domains-with-feature-guards.json-result:
  • inspector/scripts/tests/generic/expected/same-type-id-different-domain.json-result:
  • inspector/scripts/tests/generic/expected/shadowed-optional-type-setters.json-result:
  • inspector/scripts/tests/generic/expected/should-strip-comments.json-result:
  • inspector/scripts/tests/generic/expected/type-declaration-aliased-primitive-type.json-result:
  • inspector/scripts/tests/generic/expected/type-declaration-array-type.json-result:
  • inspector/scripts/tests/generic/expected/type-declaration-enum-type.json-result:
  • inspector/scripts/tests/generic/expected/type-declaration-object-type.json-result:
  • inspector/scripts/tests/generic/expected/type-requiring-runtime-casts.json-result:
  • inspector/scripts/tests/generic/expected/type-with-open-parameters.json-result:
  • inspector/scripts/tests/generic/expected/version.json-result:
  • inspector/scripts/tests/ios/expected/definitions-with-mac-platform.json-result:
  • inspector/scripts/tests/mac/expected/definitions-with-mac-platform.json-result:

Source/WebCore:

  • Modules/encryptedmedia/legacy/LegacyCDM.h:

(WebCore::LegacyCDM::keySystem const): Deleted.
(WebCore::LegacyCDM::client const): Deleted.
(WebCore::LegacyCDM::setClient): Deleted.

  • Modules/encryptedmedia/legacy/LegacyCDMPrivate.h:
  • Modules/encryptedmedia/legacy/LegacyCDMSessionClearKey.h:
  • Modules/webaudio/AsyncAudioDecoder.h:

(WebCore::AsyncAudioDecoder::DecodingTask::audioData): Deleted.
(WebCore::AsyncAudioDecoder::DecodingTask::sampleRate const): Deleted.
(WebCore::AsyncAudioDecoder::DecodingTask::successCallback): Deleted.
(WebCore::AsyncAudioDecoder::DecodingTask::errorCallback): Deleted.
(WebCore::AsyncAudioDecoder::DecodingTask::audioBuffer): Deleted.

  • Modules/webauthn/AuthenticatorCoordinator.h:
  • Modules/webdatabase/SQLStatement.h:

(WebCore::SQLStatement::hasStatementCallback const): Deleted.
(WebCore::SQLStatement::hasStatementErrorCallback const): Deleted.

  • Modules/webgpu/WHLSL/AST/WHLSLVariableDeclaration.h:
  • Modules/webgpu/WHLSL/Metal/WHLSLEntryPointScaffolding.h:
  • Modules/webgpu/WHLSL/WHLSLResolvingType.h:
  • bindings/js/DOMPromiseProxy.h:
  • bindings/js/GCController.h:
  • bridge/jsc/BridgeJSC.h:
  • contentextensions/ContentExtensionsBackend.h:
  • dom/FullscreenManager.h:

(WebCore::FullscreenManager::document): Deleted.
(WebCore::FullscreenManager::document const): Deleted.
(WebCore::FullscreenManager::topDocument const): Deleted.
(WebCore::FullscreenManager::page const): Deleted.
(WebCore::FullscreenManager::frame const): Deleted.
(WebCore::FullscreenManager::documentElement const): Deleted.
(WebCore::FullscreenManager::hasLivingRenderTree const): Deleted.
(WebCore::FullscreenManager::pageCacheState const): Deleted.
(WebCore::FullscreenManager::scheduleFullStyleRebuild): Deleted.
(WebCore::FullscreenManager::fullscreenElement const): Deleted.
(WebCore::FullscreenManager::isFullscreen const): Deleted.
(WebCore::FullscreenManager::isFullscreenKeyboardInputAllowed const): Deleted.
(WebCore::FullscreenManager::currentFullscreenElement const): Deleted.

  • dom/Microtasks.h:

(WebCore::MicrotaskQueue::vm const): Deleted.

  • editing/CompositeEditCommand.h:
  • editing/mac/AlternativeTextUIController.h:
  • html/HTMLMediaElement.h:
  • inspector/InspectorFrontendClientLocal.h:
  • inspector/agents/WebHeapAgent.cpp:
  • layout/displaytree/DisplayRun.h:
  • layout/inlineformatting/InlineItem.h:
  • layout/inlineformatting/InlineLine.h:
  • layout/tableformatting/TableGrid.h:
  • loader/FrameLoader.h:

(WebCore::FrameLoader::frame const): Deleted.
(WebCore::FrameLoader::policyChecker const): Deleted.
(WebCore::FrameLoader::history const): Deleted.
(WebCore::FrameLoader::notifier const): Deleted.
(WebCore::FrameLoader::subframeLoader const): Deleted.
(WebCore::FrameLoader::mixedContentChecker const): Deleted.
(WebCore::FrameLoader::urlSelected): Deleted.
(WebCore::FrameLoader::reload): Deleted.
(WebCore::FrameLoader::requestedHistoryItem const): Deleted.
(WebCore::FrameLoader::documentLoader const): Deleted.
(WebCore::FrameLoader::policyDocumentLoader const): Deleted.
(WebCore::FrameLoader::provisionalDocumentLoader const): Deleted.
(WebCore::FrameLoader::state const): Deleted.
(WebCore::FrameLoader::shouldReportResourceTimingToParentFrame const): Deleted.
(WebCore::FrameLoader::client const): Deleted.
(WebCore::FrameLoader::forceSandboxFlags): Deleted.
(WebCore::FrameLoader::hasOpenedFrames const): Deleted.
(WebCore::FrameLoader::setLoadsSynchronously): Deleted.
(WebCore::FrameLoader::loadsSynchronously const): Deleted.
(WebCore::FrameLoader::stateMachine): Deleted.
(WebCore::FrameLoader::quickRedirectComing const): Deleted.
(WebCore::FrameLoader::pageDismissalEventBeingDispatched const): Deleted.
(WebCore::FrameLoader::previousURL const): Deleted.
(WebCore::FrameLoader::setOverrideCachePolicyForTesting): Deleted.
(WebCore::FrameLoader::setOverrideResourceLoadPriorityForTesting): Deleted.
(WebCore::FrameLoader::setStrictRawResourceValidationPolicyDisabledForTesting): Deleted.
(WebCore::FrameLoader::isStrictRawResourceValidationPolicyDisabledForTesting): Deleted.
(WebCore::FrameLoader::provisionalLoadErrorBeingHandledURL const): Deleted.
(WebCore::FrameLoader::setProvisionalLoadErrorBeingHandledURL): Deleted.
(WebCore::FrameLoader::isReloadingFromOrigin const): Deleted.
(WebCore::FrameLoader::setAlwaysAllowLocalWebarchive): Deleted.
(WebCore::FrameLoader::alwaysAllowLocalWebarchive const): Deleted.
(WebCore::FrameLoader::loadWithDocumentLoader): Deleted.
(WebCore::FrameLoader::loadWithNavigationAction): Deleted.
(WebCore::FrameLoader::shouldTreatCurrentLoadAsContinuingLoad const): Deleted.

  • loader/NavigationDisabler.h:
  • loader/NavigationScheduler.h:
  • loader/cache/CachedResource.h:
  • loader/cache/CachedSVGDocumentReference.h:

(WebCore::CachedSVGDocumentReference::loadRequested const): Deleted.
(WebCore::CachedSVGDocumentReference::document): Deleted.

  • loader/ios/PreviewLoader.h:
  • page/CaptionUserPreferences.h:
  • page/PrewarmInformation.h:
  • page/ResizeObserver.h:
  • page/SuspendableTimer.h:
  • page/csp/ContentSecurityPolicyDirective.h:
  • page/ios/ContentChangeObserver.h:
  • page/ios/DOMTimerHoldingTank.h:
  • page/linux/ResourceUsageOverlayLinux.cpp:
  • page/mac/TextIndicatorWindow.h:
  • page/scrolling/ScrollSnapOffsetsInfo.h:
  • page/scrolling/ScrollingMomentumCalculator.h:
  • platform/CPUMonitor.h:
  • platform/FileMonitor.h:
  • platform/ScrollAnimation.h:
  • platform/SuddenTermination.h:
  • platform/audio/AudioBus.h:

(WebCore::AudioBus::numberOfChannels const): Deleted.
(WebCore::AudioBus::channel): Deleted.
(WebCore::AudioBus::channel const): Deleted.
(WebCore::AudioBus::length const): Deleted.
(WebCore::AudioBus::sampleRate const): Deleted.
(WebCore::AudioBus::setSampleRate): Deleted.
(WebCore::AudioBus::reset): Deleted.
(WebCore::AudioBus::AudioBus): Deleted.

  • platform/audio/AudioChannel.h:

(WebCore::AudioChannel::AudioChannel): Deleted.
(WebCore::AudioChannel::set): Deleted.
(WebCore::AudioChannel::length const): Deleted.
(WebCore::AudioChannel::mutableData): Deleted.
(WebCore::AudioChannel::data const): Deleted.
(WebCore::AudioChannel::zero): Deleted.
(WebCore::AudioChannel::clearSilentFlag): Deleted.
(WebCore::AudioChannel::isSilent const): Deleted.

  • platform/audio/AudioFIFO.h:

(WebCore::AudioFIFO::framesInFifo const): Deleted.
(WebCore::AudioFIFO::updateIndex): Deleted.

  • platform/audio/AudioPullFIFO.h:
  • platform/audio/AudioResampler.h:

(WebCore::AudioResampler::rate const): Deleted.

  • platform/audio/AudioResamplerKernel.h:
  • platform/audio/AudioSession.cpp:
  • platform/audio/AudioSession.h:

(WebCore::AudioSession::isActive const): Deleted.

  • platform/audio/Biquad.h:
  • platform/audio/Cone.h:

(WebCore::ConeEffect::setInnerAngle): Deleted.
(WebCore::ConeEffect::innerAngle const): Deleted.
(WebCore::ConeEffect::setOuterAngle): Deleted.
(WebCore::ConeEffect::outerAngle const): Deleted.
(WebCore::ConeEffect::setOuterGain): Deleted.
(WebCore::ConeEffect::outerGain const): Deleted.

  • platform/audio/DenormalDisabler.h:

(WebCore::DenormalDisabler::DenormalDisabler): Deleted.
(WebCore::DenormalDisabler::~DenormalDisabler): Deleted.
(WebCore::DenormalDisabler::flushDenormalFloatToZero): Deleted.
(WebCore::DenormalDisabler::getCSR): Deleted.
(WebCore::DenormalDisabler::setCSR): Deleted.

  • platform/audio/DirectConvolver.h:
  • platform/audio/Distance.h:

(WebCore::DistanceEffect::model): Deleted.
(WebCore::DistanceEffect::setModel): Deleted.
(WebCore::DistanceEffect::setRefDistance): Deleted.
(WebCore::DistanceEffect::setMaxDistance): Deleted.
(WebCore::DistanceEffect::setRolloffFactor): Deleted.
(WebCore::DistanceEffect::refDistance const): Deleted.
(WebCore::DistanceEffect::maxDistance const): Deleted.
(WebCore::DistanceEffect::rolloffFactor const): Deleted.

  • platform/audio/DownSampler.h:
  • platform/audio/DynamicsCompressor.h:

(WebCore::DynamicsCompressor::sampleRate const): Deleted.
(WebCore::DynamicsCompressor::nyquist const): Deleted.
(WebCore::DynamicsCompressor::tailTime const): Deleted.
(WebCore::DynamicsCompressor::latencyTime const): Deleted.

  • platform/audio/DynamicsCompressorKernel.h:

(WebCore::DynamicsCompressorKernel::latencyFrames const): Deleted.
(WebCore::DynamicsCompressorKernel::sampleRate const): Deleted.
(WebCore::DynamicsCompressorKernel::meteringGain const): Deleted.

  • platform/audio/EqualPowerPanner.h:
  • platform/audio/FFTConvolver.h:

(WebCore::FFTConvolver::fftSize const): Deleted.

  • platform/audio/HRTFDatabase.h:

(WebCore::HRTFDatabase::numberOfAzimuths): Deleted.
(WebCore::HRTFDatabase::sampleRate const): Deleted.

  • platform/audio/HRTFElevation.h:

(WebCore::HRTFElevation::HRTFElevation): Deleted.
(WebCore::HRTFElevation::kernelListL): Deleted.
(WebCore::HRTFElevation::kernelListR): Deleted.
(WebCore::HRTFElevation::elevationAngle const): Deleted.
(WebCore::HRTFElevation::numberOfAzimuths const): Deleted.
(WebCore::HRTFElevation::sampleRate const): Deleted.

  • platform/audio/HRTFPanner.h:

(WebCore::HRTFPanner::fftSize const): Deleted.
(WebCore::HRTFPanner::sampleRate const): Deleted.

  • platform/audio/MultiChannelResampler.h:
  • platform/audio/PlatformAudioData.h:
  • platform/audio/Reverb.h:

(WebCore::Reverb::impulseResponseLength const): Deleted.

  • platform/audio/ReverbAccumulationBuffer.h:

(WebCore::ReverbAccumulationBuffer::readIndex const): Deleted.
(WebCore::ReverbAccumulationBuffer::readTimeFrame const): Deleted.

  • platform/audio/ReverbConvolver.h:

(WebCore::ReverbConvolver::impulseResponseLength const): Deleted.
(WebCore::ReverbConvolver::inputBuffer): Deleted.
(WebCore::ReverbConvolver::useBackgroundThreads const): Deleted.

  • platform/audio/ReverbConvolverStage.h:

(WebCore::ReverbConvolverStage::inputReadIndex const): Deleted.

  • platform/audio/ReverbInputBuffer.h:

(WebCore::ReverbInputBuffer::writeIndex const): Deleted.

  • platform/audio/SincResampler.h:
  • platform/audio/UpSampler.h:
  • platform/audio/ZeroPole.h:

(WebCore::ZeroPole::ZeroPole): Deleted.
(WebCore::ZeroPole::reset): Deleted.
(WebCore::ZeroPole::setZero): Deleted.
(WebCore::ZeroPole::setPole): Deleted.
(WebCore::ZeroPole::zero const): Deleted.
(WebCore::ZeroPole::pole const): Deleted.

  • platform/audio/cocoa/WebAudioBufferList.h:

(WebCore::WebAudioBufferList::list const): Deleted.
(WebCore::WebAudioBufferList::operator AudioBufferList& const): Deleted.
(WebCore::WebAudioBufferList::kind const): Deleted.

  • platform/audio/ios/AudioSessionIOS.mm:
  • platform/audio/mac/CARingBuffer.h:
  • platform/encryptedmedia/clearkey/CDMClearKey.h:
  • platform/gamepad/mac/HIDGamepad.h:
  • platform/graphics/FloatPoint.h:
  • platform/graphics/Font.h:
  • platform/graphics/GraphicsContext.h:
  • platform/graphics/GraphicsContext3DPrivate.h:
  • platform/graphics/GraphicsContextImpl.h:
  • platform/graphics/GraphicsLayer.cpp:
  • platform/graphics/LegacyCDMSession.h:
  • platform/graphics/Region.h:
  • platform/graphics/VelocityData.h:
  • platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.h:
  • platform/graphics/avfoundation/CDMFairPlayStreaming.h:
  • platform/graphics/avfoundation/CDMPrivateMediaSourceAVFObjC.h:
  • platform/graphics/avfoundation/ISOFairPlayStreamingPsshBox.h:
  • platform/graphics/avfoundation/cf/CDMSessionAVFoundationCF.h:
  • platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
  • platform/graphics/avfoundation/objc/CDMSessionAVFoundationObjC.h:
  • platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
  • platform/graphics/ca/GraphicsLayerCA.h:
  • platform/graphics/cairo/FontCustomPlatformData.h:
  • platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
  • platform/graphics/cairo/PlatformContextCairo.h:
  • platform/graphics/cocoa/GraphicsContext3DCocoa.mm:
  • platform/graphics/cv/ImageRotationSessionVT.h:

(WebCore::ImageRotationSessionVT::RotationProperties::isIdentity const): Deleted.
(WebCore::ImageRotationSessionVT::transform const): Deleted.
(WebCore::ImageRotationSessionVT::rotationProperties const): Deleted.
(WebCore::ImageRotationSessionVT::size): Deleted.
(WebCore::ImageRotationSessionVT::rotatedSize): Deleted.

  • platform/graphics/cv/PixelBufferConformerCV.h:
  • platform/graphics/cv/TextureCacheCV.h:
  • platform/graphics/cv/VideoTextureCopierCV.h:
  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
  • platform/graphics/gstreamer/VideoTextureCopierGStreamer.h:
  • platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
  • platform/graphics/holepunch/MediaPlayerPrivateHolePunch.h:
  • platform/graphics/iso/ISOBox.h:
  • platform/graphics/iso/ISOOriginalFormatBox.h:
  • platform/graphics/iso/ISOProtectionSchemeInfoBox.h:
  • platform/graphics/iso/ISOSchemeInformationBox.h:
  • platform/graphics/iso/ISOSchemeTypeBox.h:
  • platform/graphics/iso/ISOTrackEncryptionBox.h:
  • platform/graphics/iso/ISOVTTCue.cpp:

(WebCore::ISOStringBox::contents): Deleted.

  • platform/graphics/iso/ISOVTTCue.h:

(WebCore::ISOWebVTTCue::boxTypeName): Deleted.
(WebCore::ISOWebVTTCue::presentationTime const): Deleted.
(WebCore::ISOWebVTTCue::duration const): Deleted.
(WebCore::ISOWebVTTCue::sourceID const): Deleted.
(WebCore::ISOWebVTTCue::id const): Deleted.
(WebCore::ISOWebVTTCue::originalStartTime const): Deleted.
(WebCore::ISOWebVTTCue::settings const): Deleted.
(WebCore::ISOWebVTTCue::cueText const): Deleted.

  • platform/graphics/nicosia/NicosiaPaintingOperation.h:
  • platform/graphics/nicosia/texmap/NicosiaBackingStoreTextureMapperImpl.h:
  • platform/graphics/nicosia/texmap/NicosiaCompositionLayerTextureMapperImpl.h:
  • platform/graphics/nicosia/texmap/NicosiaContentLayerTextureMapperImpl.h:
  • platform/graphics/nicosia/texmap/NicosiaGC3DLayer.h:
  • platform/graphics/nicosia/texmap/NicosiaImageBackingTextureMapperImpl.h:
  • platform/graphics/opengl/Extensions3DOpenGLCommon.h:
  • platform/graphics/texmap/TextureMapperGC3DPlatformLayer.h:
  • platform/graphics/texmap/coordinated/Tile.h:
  • platform/graphics/win/FontCustomPlatformData.h:
  • platform/graphics/win/FullScreenController.cpp:
  • platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
  • platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:
  • platform/graphics/win/PlatformContextDirect2D.h:
  • platform/graphics/win/WKCAImageQueue.cpp:
  • platform/gtk/PasteboardHelper.cpp:
  • platform/ios/LegacyTileGrid.h:
  • platform/mediarecorder/MediaRecorderPrivateAVFImpl.h:
  • platform/mediastream/gstreamer/GStreamerAudioData.h:

(WebCore::GStreamerAudioData::GStreamerAudioData): Deleted.
(WebCore::GStreamerAudioData::getSample): Deleted.
(WebCore::GStreamerAudioData::getAudioInfo): Deleted.
(WebCore::GStreamerAudioData::kind const): Deleted.

  • platform/mediastream/gstreamer/GStreamerCapturer.h:
  • platform/mediastream/gstreamer/GStreamerMediaStreamSource.cpp:
  • platform/mediastream/libwebrtc/GStreamerVideoDecoderFactory.h:
  • platform/mediastream/libwebrtc/GStreamerVideoEncoderFactory.cpp:
  • platform/mediastream/libwebrtc/GStreamerVideoEncoderFactory.h:
  • platform/mediastream/libwebrtc/LibWebRTCDTMFSenderBackend.h:
  • platform/mediastream/libwebrtc/LibWebRTCProvider.cpp:
  • platform/mediastream/libwebrtc/LibWebRTCProvider.h:
  • platform/mediastream/libwebrtc/LibWebRTCProviderCocoa.h:
  • platform/mock/MediaPlaybackTargetPickerMock.h:
  • platform/mock/RTCDataChannelHandlerMock.h:
  • platform/network/ResourceErrorBase.h:
  • platform/network/curl/CookieJarDB.h:
  • platform/network/curl/CurlCacheEntry.h:
  • platform/network/curl/CurlContext.h:
  • platform/network/curl/CurlMultipartHandle.h:
  • platform/network/curl/CurlRequestScheduler.h:
  • platform/network/curl/CurlSSLVerifier.h:
  • platform/network/ios/PreviewConverter.h:
  • platform/network/soup/NetworkStorageSessionSoup.cpp:
  • platform/vr/openvr/VRPlatformDisplayOpenVR.h:
  • platform/vr/openvr/VRPlatformManagerOpenVR.h:
  • rendering/HitTestResult.h:
  • rendering/LayerOverlapMap.cpp:
  • rendering/RenderLayerCompositor.h:
  • rendering/svg/RenderSVGResourceMasker.h:
  • replay/UserInputBridge.h:
  • svg/graphics/filters/SVGFilterBuilder.h:
  • svg/properties/SVGAttributeAnimator.h:
  • svg/properties/SVGDecoratedProperty.h:
  • svg/properties/SVGPropertyAnimatorFactory.h:
  • testing/InternalSettings.cpp:
  • testing/LegacyMockCDM.cpp:
  • testing/LegacyMockCDM.h:
  • testing/MockCDMFactory.h:
  • workers/WorkerEventQueue.cpp:
  • workers/WorkerEventQueue.h:
  • workers/service/ServiceWorkerContainer.h:
  • worklets/PaintWorkletGlobalScope.h:
  • xml/XMLErrors.h:
  • xml/parser/XMLDocumentParserLibxml2.cpp:

Source/WebDriver:

  • glib/SessionHostGlib.cpp:

Source/WebKit:

  • NetworkProcess/AdClickAttributionManager.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsPersistentStorage.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Cookies/WebCookieManager.h:
  • NetworkProcess/CustomProtocols/LegacyCustomProtocolManager.h:
  • NetworkProcess/NetworkHTTPSUpgradeChecker.h:
  • NetworkProcess/NetworkProcess.cpp:
  • NetworkProcess/NetworkSession.h:
  • NetworkProcess/NetworkSocketChannel.h:
  • NetworkProcess/WebSocketTask.h:
  • NetworkProcess/cache/PrefetchCache.h:
  • NetworkProcess/cocoa/WebSocketTaskCocoa.h:
  • NetworkProcess/soup/WebKitSoupRequestInputStream.cpp:
  • NetworkProcess/soup/WebSocketTaskSoup.h:
  • NetworkProcess/webrtc/LibWebRTCSocketClient.h:
  • NetworkProcess/webrtc/NetworkMDNSRegister.cpp:
  • Platform/Module.h:
  • PluginProcess/PluginControllerProxy.h:
  • Shared/ApplePay/WebPaymentCoordinatorProxy.h:
  • Shared/Authentication/AuthenticationManager.h:
  • Shared/Cocoa/SandboxExtensionCocoa.mm:
  • Shared/Plugins/NPObjectMessageReceiver.h:
  • Shared/RemoteLayerTree/RemoteLayerTreeTransaction.h:
  • UIProcess/API/APIAutomationClient.h:
  • UIProcess/API/APIAutomationSessionClient.h:
  • UIProcess/API/APIContextMenuClient.h:
  • UIProcess/API/APICustomProtocolManagerClient.h:
  • UIProcess/API/APIDiagnosticLoggingClient.h:
  • UIProcess/API/APIDownloadClient.h:
  • UIProcess/API/APIFindClient.h:
  • UIProcess/API/APIFindMatchesClient.h:
  • UIProcess/API/APIFormClient.h:
  • UIProcess/API/APIFullscreenClient.h:
  • UIProcess/API/APIGeolocationProvider.h:
  • UIProcess/API/APIHistoryClient.h:
  • UIProcess/API/APIIconDatabaseClient.h:
  • UIProcess/API/APIIconLoadingClient.h:
  • UIProcess/API/APIInjectedBundleClient.h:
  • UIProcess/API/APILegacyContextHistoryClient.h:
  • UIProcess/API/APILoaderClient.h:
  • UIProcess/API/APINavigationClient.h:
  • UIProcess/API/APIPolicyClient.h:
  • UIProcess/API/APIUIClient.h:
  • UIProcess/API/C/WKPage.cpp:

(WKPageSetPageStateClient):

  • UIProcess/API/Cocoa/WKUserContentController.mm:
  • UIProcess/API/Cocoa/_WKRemoteWebInspectorViewController.mm:
  • UIProcess/API/glib/IconDatabase.h:
  • UIProcess/API/glib/WebKitAutomationSession.cpp:
  • UIProcess/API/glib/WebKitIconLoadingClient.cpp:
  • UIProcess/API/glib/WebKitNotificationProvider.h:
  • UIProcess/API/glib/WebKitUserContentManager.cpp:
  • UIProcess/API/glib/WebKitWebContext.cpp:
  • UIProcess/API/glib/WebKitWebView.cpp:
  • UIProcess/API/gtk/WebKitRemoteInspectorProtocolHandler.cpp:
  • UIProcess/API/gtk/WebKitWebInspector.cpp:
  • UIProcess/API/mac/WKView.mm:

(-[WKView maybeInstallIconLoadingClient]):

  • UIProcess/API/wpe/APIViewClient.h:
  • UIProcess/API/wpe/ScrollGestureController.h:
  • UIProcess/ApplicationStateTracker.h:
  • UIProcess/Cocoa/AutomationSessionClient.h:
  • UIProcess/Cocoa/IconLoadingDelegate.h:
  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.cpp:
  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.h:
  • UIProcess/DrawingAreaProxy.h:
  • UIProcess/HighPerformanceGraphicsUsageSampler.h:
  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/PageClient.h:
  • UIProcess/PerActivityStateCPUUsageSampler.h:
  • UIProcess/RemoteLayerTree/RemoteLayerTreeScrollingPerformanceData.h:
  • UIProcess/RemoteLayerTree/RemoteScrollingCoordinatorProxy.h:
  • UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h:
  • UIProcess/SystemPreviewController.h:
  • UIProcess/UserMediaPermissionRequestManagerProxy.h:
  • UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.h:
  • UIProcess/WebNavigationState.h:
  • UIProcess/WebPageInjectedBundleClient.h:
  • UIProcess/WebPageProxy.h:
  • UIProcess/WebsiteData/WebsiteDataStoreClient.h:
  • UIProcess/gtk/DragAndDropHandler.h:
  • UIProcess/ios/EditableImageController.h:
  • UIProcess/ios/InputViewUpdateDeferrer.h:
  • UIProcess/ios/SmartMagnificationController.h:
  • UIProcess/ios/fullscreen/WKFullScreenViewController.mm:
  • UIProcess/mac/WKFullScreenWindowController.mm:
  • UIProcess/mac/WKTextFinderClient.mm:
  • WebProcess/ApplePay/WebPaymentCoordinator.h:
  • WebProcess/Geolocation/GeolocationPermissionRequestManager.h:
  • WebProcess/Geolocation/WebGeolocationManager.h:
  • WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
  • WebProcess/InjectedBundle/API/c/mac/WKBundlePageBannerMac.mm:
  • WebProcess/InjectedBundle/API/glib/DOM/DOMObjectCache.cpp:
  • WebProcess/InjectedBundle/API/glib/WebKitWebPage.cpp:
  • WebProcess/MediaCache/WebMediaKeyStorageManager.h:
  • WebProcess/MediaStream/UserMediaPermissionRequestManager.h:
  • WebProcess/Network/webrtc/LibWebRTCProvider.cpp:
  • WebProcess/Network/webrtc/LibWebRTCResolver.h:
  • WebProcess/Notifications/WebNotificationManager.h:
  • WebProcess/Plugins/Netscape/NetscapePlugin.h:
  • WebProcess/Plugins/Netscape/x11/NetscapePluginX11.h:
  • WebProcess/Plugins/PluginController.h:
  • WebProcess/Storage/WebSWOriginTable.h:
  • WebProcess/WebCoreSupport/WebAlternativeTextClient.h:
  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebCoreSupport/WebContextMenuClient.h:
  • WebProcess/WebCoreSupport/WebDragClient.h:
  • WebProcess/WebCoreSupport/WebEditorClient.h:
  • WebProcess/WebCoreSupport/WebGeolocationClient.h:
  • WebProcess/WebCoreSupport/WebInspectorClient.h:
  • WebProcess/WebCoreSupport/WebMessagePortChannelProvider.h:
  • WebProcess/WebCoreSupport/WebNotificationClient.h:
  • WebProcess/WebCoreSupport/WebPlugInClient.h:
  • WebProcess/WebCoreSupport/WebProgressTrackerClient.h:
  • WebProcess/WebCoreSupport/WebSpeechSynthesisClient.h:
  • WebProcess/WebCoreSupport/WebUserMediaClient.h:
  • WebProcess/WebPage/Cocoa/TextCheckingControllerProxy.h:
  • WebProcess/WebPage/FindController.h:
  • WebProcess/WebPage/ViewGestureGeometryCollector.h:
  • WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
  • WebProcess/WebPage/ios/FindIndicatorOverlayClientIOS.h:
  • WebProcess/WebProcess.h:
  • WebProcess/cocoa/UserMediaCaptureManager.h:

Source/WebKitLegacy/ios:

  • WebCoreSupport/WebChromeClientIOS.h:
  • WebCoreSupport/WebFixedPositionContent.mm:

Source/WebKitLegacy/mac:

  • Plugins/Hosted/NetscapePluginInstanceProxy.h:
  • Plugins/Hosted/WebHostedNetscapePluginView.mm:
  • Plugins/WebNetscapePluginEventHandlerCocoa.h:
  • Storage/WebDatabaseManagerClient.mm:
  • WebCoreSupport/WebAlternativeTextClient.h:
  • WebCoreSupport/WebCachedFramePlatformData.h:
  • WebCoreSupport/WebChromeClient.h:
  • WebCoreSupport/WebContextMenuClient.h:
  • WebCoreSupport/WebDragClient.h:
  • WebCoreSupport/WebEditorClient.h:
  • WebCoreSupport/WebGeolocationClient.h:
  • WebCoreSupport/WebInspectorClient.h:
  • WebCoreSupport/WebNotificationClient.h:
  • WebCoreSupport/WebSelectionServiceController.h:
  • WebView/WebMediaPlaybackTargetPicker.h:

Source/WebKitLegacy/win:

  • FullscreenVideoController.cpp:
  • FullscreenVideoController.h:
  • Plugins/PluginMessageThrottlerWin.h:
  • WebCachedFramePlatformData.h:
  • WebCoreSupport/AcceleratedCompositingContext.h:
  • WebCoreSupport/WebChromeClient.h:
  • WebCoreSupport/WebContextMenuClient.h:
  • WebCoreSupport/WebDesktopNotificationsDelegate.h:
  • WebCoreSupport/WebDragClient.h:
  • WebCoreSupport/WebEditorClient.h:
  • WebCoreSupport/WebFrameLoaderClient.cpp:
  • WebCoreSupport/WebGeolocationClient.h:
  • WebCoreSupport/WebInspectorClient.h:
  • WebDatabaseManager.cpp:
  • WebKitQuartzCoreAdditions/CAD3DRenderer.h:
  • WebNodeHighlight.h:
  • WebNotificationCenter.cpp:
  • WebNotificationCenter.h:

Tools:

  • DumpRenderTree/AccessibilityController.h:
  • DumpRenderTree/GCController.h:
  • DumpRenderTree/win/DRTDataObject.cpp:
  • DumpRenderTree/win/DRTDataObject.h:
  • DumpRenderTree/win/DRTDesktopNotificationPresenter.h:
  • DumpRenderTree/win/DRTDropSource.h:
  • DumpRenderTree/win/DraggingInfo.h:
  • DumpRenderTree/win/EditingDelegate.h:
  • DumpRenderTree/win/EventSender.cpp:
  • DumpRenderTree/win/FrameLoadDelegate.h:
  • DumpRenderTree/win/HistoryDelegate.h:
  • DumpRenderTree/win/MD5.h:
  • DumpRenderTree/win/PolicyDelegate.h:
  • DumpRenderTree/win/ResourceLoadDelegate.h:
  • DumpRenderTree/win/TextInputController.h:
  • DumpRenderTree/win/UIDelegate.cpp:
  • DumpRenderTree/win/UIDelegate.h:
  • TestRunnerShared/UIScriptContext/UIScriptContext.h:
  • TestRunnerShared/cocoa/ClassMethodSwizzler.h:
  • TestRunnerShared/cocoa/InstanceMethodSwizzler.h:
  • TestWebKitAPI/Counters.h:
  • TestWebKitAPI/PlatformWebView.h:
  • TestWebKitAPI/Tests/WTF/Expected.cpp:
  • TestWebKitAPI/Tests/WTF/HashMap.cpp:

(TestWebKitAPI::DerefObserver::ref):
(TestWebKitAPI::DerefObserver::deref):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WTF/HashSet.cpp:

(TestWebKitAPI::DerefObserver::ref):
(TestWebKitAPI::DerefObserver::deref):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WTF/UniqueRef.cpp:
  • TestWebKitAPI/Tests/WTF/WeakPtr.cpp:
  • TestWebKitAPI/Tests/WebCore/CalculationValue.cpp:
  • TestWebKitAPI/Tests/WebKitGLib/TestAuthentication.cpp:
  • TestWebKitAPI/Tests/WebKitGLib/WebProcessTest.h:
  • TestWebKitAPI/glib/WebKitGLib/WebKitTestServer.h:
  • WebKitTestRunner/EventSenderProxy.h:
  • WebKitTestRunner/GeolocationProviderMock.h:
  • WebKitTestRunner/InjectedBundle/AccessibilityController.h:
  • WebKitTestRunner/InjectedBundle/EventSendingController.cpp:
  • WebKitTestRunner/InjectedBundle/InjectedBundlePage.h:
  • WebKitTestRunner/PlatformWebView.h:
  • WebKitTestRunner/TestInvocation.h:
9:28 PM Changeset in webkit [248761] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[ContentChangeObserver] Rename contentVisibilityDidChange to elementDidBecomeVisible
https://bugs.webkit.org/show_bug.cgi?id=200780
<rdar://problem/54358330>

Reviewed by Simon Fraser.

"elementDidBecomeVisible" name is more accurate and also we'll probably start tracking changes from visible to hidden soon.

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::didFinishTransition):
(WebCore::ContentChangeObserver::visibilityChangedFromHiddenToVisible):
(WebCore::ContentChangeObserver::adjustObservedState):
(WebCore::ContentChangeObserver::StyleChangeScope::~StyleChangeScope):
(WebCore::ContentChangeObserver::contentVisibilityDidChange): Deleted.

  • page/ios/ContentChangeObserver.h:
8:03 PM Changeset in webkit [248760] by Joseph Pecoraro
  • 22 edits
    2 adds in trunk

Web Inspector: Update Esprima to support modern JavaScript language features
https://bugs.webkit.org/show_bug.cgi?id=200796

Reviewed by Ross Kirsling.

Source/WebInspectorUI:

Use a fork of Esprima to support modern JavaScript language features
while going through the process to upstream support:

ES2018 Feature: Async Iteration (for-await-of)
https://github.com/jquery/esprima/issues/1990

ES2019 Feature: Numeric Separator
https://github.com/jquery/esprima/issues/1989

ES2019 Feature: Optional catch binding
https://github.com/jquery/esprima/issues/1953

ES2020 Feature: BigInt
https://github.com/jquery/esprima/issues/1988

ESTree compatible AST changes are summarized as:

  • CatchClause param property is now nullable
  • ForOfStatement now has a boolean await property
  • Literal can be a "bigint" type (works if the environment has BigInt or not)

The pretty printer only needed to have additional handling for for-await-of.

  • UserInterface/External/Esprima/esprima.js:

New version. Typescript output expects a modern JavaScript environment
instead of just ES6.

  • Tools/Formatting/index.html:

Update the formatting tool for easier use in case of errors.

  • UserInterface/Models/ScriptSyntaxTree.js:

(WI.ScriptSyntaxTree.prototype._createInternalSyntaxTree):

  • UserInterface/Test/TestHarness.js:

(TestHarness.prototype.passOrFail):
Convenience for pass/fail with the same message based on a condition.

  • UserInterface/Workers/Formatter/EsprimaFormatter.js:

(EsprimaFormatter.prototype._handleTokenAtNode):
Ensure a space after await in for await syntax.

LayoutTests:

  • inspector/formatting/resources/javascript-tests/classes-expected.js:
  • inspector/formatting/resources/javascript-tests/classes.js:
  • inspector/formatting/resources/javascript-tests/for-statements-expected.js:
  • inspector/formatting/resources/javascript-tests/for-statements.js:
  • inspector/formatting/resources/javascript-tests/generators-expected.js:
  • inspector/formatting/resources/javascript-tests/generators.js:
  • inspector/formatting/resources/javascript-tests/numbers-expected.js: Added.
  • inspector/formatting/resources/javascript-tests/numbers.js: Added.
  • inspector/formatting/resources/javascript-tests/try-catch-finally-statements-expected.js:
  • inspector/formatting/resources/javascript-tests/try-catch-finally-statements.js:
  • inspector/formatting/resources/javascript-tests/unary-binary-expressions-expected.js:
  • inspector/formatting/resources/javascript-tests/unary-binary-expressions.js:

Test formatting of new JavaScript language features.

  • inspector/formatting/formatting-css-expected.txt:
  • inspector/formatting/formatting-javascript-expected.txt:
  • inspector/formatting/formatting-javascript.html:
  • inspector/formatting/resources/utilities.js:

(TestPage.registerInitializer.async.runFormattingTest):
(TestPage.registerInitializer.window.addFormattingTests):
(TestPage.registerInitializer):
Cleaner output and better handling for debugging failures.

  • inspector/model/parse-script-syntax-tree.html:

Test new AST permutations.

7:20 PM Changeset in webkit [248759] by Alan Bujtas
  • 6 edits
    2 adds in trunk

[ContentChangeObserver] Keep track of all the visibility candidates.
https://bugs.webkit.org/show_bug.cgi?id=200777
<rdar://problem/54356331>

Reviewed by Simon Fraser.

Source/WebCore:

In order to find out whether a visible (and actionable) content change happened, we need to keep track of all the candidate elements.

Test: fast/events/touch/ios/content-observation/going-from-hidden-to-visible-and-to-hidden2.html

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::reset):
(WebCore::ContentChangeObserver::rendererWillBeDestroyed):
(WebCore::ContentChangeObserver::contentVisibilityDidChange):
(WebCore::ContentChangeObserver::shouldObserveVisibilityChangeForElement):

  • page/ios/ContentChangeObserver.h:

Source/WTF:

  • wtf/WeakHashSet.h:

LayoutTests:

  • fast/events/touch/ios/content-observation/going-from-hidden-to-visible-and-to-hidden2-expected.txt: Added.
  • fast/events/touch/ios/content-observation/going-from-hidden-to-visible-and-to-hidden2.html: Added.
7:08 PM Changeset in webkit [248758] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: REGRESSION(r244268): "Show Scope Chain on pause" setting has no effect
https://bugs.webkit.org/show_bug.cgi?id=200797

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/DebuggerTabContentView.js:

(WI.DebuggerTabContentView.prototype.showDetailsSidebarPanels):

  • UserInterface/Views/SourcesTabContentView.js:

(WI.SourcesTabContentView.prototype.showDetailsSidebarPanels):
When the sidebar panel isn't visible parentSidebar is null. Use WI.DetailsSidebar instead.

6:58 PM Changeset in webkit [248757] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Uncaught Exception: TypeError: null is not an object (evaluating 'this._resource.initiatorSourceCodeLocation')
https://bugs.webkit.org/show_bug.cgi?id=200798

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/ResourceDetailsSidebarPanel.js:

(WI.ResourceDetailsSidebarPanel.prototype.set resource):
(WI.ResourceDetailsSidebarPanel.prototype.layout):
Cancel the Throttler whenever the _resource is updated, as otherwise the Throttler may
fire later on with an unset _resource.

6:54 PM Changeset in webkit [248756] by mmaxfield@apple.com
  • 3 edits
    2 adds in trunk

[WHLSL] Add unary plus
https://bugs.webkit.org/show_bug.cgi?id=200753

Reviewed by Saam Barati.

Source/WebCore:

HLSL has these, so we should too.

Test: webgpu/whlsl/vector-matrix-addition-subtraction.html

  • Modules/webgpu/WHLSL/WHLSLStandardLibrary.txt:

LayoutTests:

  • webgpu/whlsl/vector-matrix-addition-subtraction-expected.txt: Added.
  • webgpu/whlsl/vector-matrix-addition-subtraction.html: Added.
6:50 PM Changeset in webkit [248755] by Brent Fulgham
  • 15 edits in trunk/Source

[FTW] Enable CoreFoundation use if building for Apple target
https://bugs.webkit.org/show_bug.cgi?id=200799

Reviewed by Alex Christensen.

Source/JavaScriptCore:

  • PlatformFTW.cmake: Add missing files.

Source/WebKit:

Fix the build and remove an unused method.

  • PlatformFTW.cmake:
  • Shared/ShareableBitmap.h:
  • Shared/win/ShareableBitmapDirect2D.cpp:

(WebKit::ShareableBitmap::createDirect2DSurface):
(WebKit::ShareableBitmap::releaseSurfaceData): Deleted.

Source/WebKitLegacy:

  • PlatformFTW.cmake:

Source/WebKitLegacy/win:

  • FullscreenVideoController.cpp:

(FullscreenVideoController::FullscreenVideoController):
(FullscreenVideoController::enterFullscreen):
(FullscreenVideoController::exitFullscreen):
(FullscreenVideoController::createHUDWindow):

  • FullscreenVideoController.h:
  • WebView.cpp:

(WebView::exitFullscreenIfNeeded):

Source/WTF:

  • wtf/PlatformFTW.cmake: Add missing files.
6:39 PM Changeset in webkit [248754] by mmaxfield@apple.com
  • 3 edits
    2 adds in trunk

[WHLSL] Matrices should have constructors that take a flattened list of scalars
https://bugs.webkit.org/show_bug.cgi?id=200804

Reviewed by Saam Barati.

Source/WebCore:

HLSL has them, so we should too.

Test: webgpu/whlsl/matrix-constructors-list-of-scalars.html

  • Modules/webgpu/WHLSL/WHLSLStandardLibrary.txt:

LayoutTests:

  • webgpu/whlsl/matrix-constructors-list-of-scalars-expected.txt: Added.
  • webgpu/whlsl/matrix-constructors-list-of-scalars.html: Added.
5:43 PM Changeset in webkit [248753] by Devin Rousso
  • 14 edits in trunk

Web Inspector: Sources: provide a way to create an arbitrary Inspector Style Sheet
https://bugs.webkit.org/show_bug.cgi?id=200425

Reviewed by Joseph Pecoraro.

Source/WebInspectorUI:

Right now, the only way to create an Inspector Style Sheet is by creating a new rule in the
Styles sidebar of the Elements Tab. This is unnecessarily restrictive, especially for those
who don't use the Elements tab.

Add a + button after the filter bar in the Navigation sidebar. Clicking on the + button will
show a menu with the following (more likely to be added later):

  • Inspector Style Sheet
  • Frames (if there are subframes)
    • (name of subframe)
      • Inspector Style Sheet
  • UserInterface/Views/SourcesNavigationSidebarPanel.js:

(WI.SourcesNavigationSidebarPanel):
(WI.SourcesNavigationSidebarPanel.prototype.treeElementForRepresentedObject): Added.
(WI.SourcesNavigationSidebarPanel.prototype._filterByResourcesWithIssues): Added.
(WI.SourcesNavigationSidebarPanel.prototype._compareTreeElements):
(WI.SourcesNavigationSidebarPanel.prototype._updateMainFrameTreeElement):
(WI.SourcesNavigationSidebarPanel.prototype._addResource):
(WI.SourcesNavigationSidebarPanel.prototype._handleTreeSelectionDidChange):
(WI.SourcesNavigationSidebarPanel.prototype._populateCreateResourceContextMenu): Added.
(WI.SourcesNavigationSidebarPanel.prototype._handleResourceGroupingModeChanged):
(WI.SourcesNavigationSidebarPanel.prototype._handleFrameWasAdded): Added.
(WI.SourcesNavigationSidebarPanel.prototype._handleMainFrameDidChange): Deleted.

  • UserInterface/Views/GeneralTreeElement.js:

(WI.GeneralTreeElement.prototype.createFoldersAsNeededForSubpath):
Drive-by: sort WI.ResourceTreeElements alongside WI.FolderTreeElements for easier readability.

  • UserInterface/Views/FrameTreeElement.js:

(WI.FrameTreeElement.prototype.onpopulate):
Add all inspectorStyleSheetsForFrame instead of just the preferred one so that they all
are visible/selectable for editing.

  • UserInterface/Views/FilterBar.js:

(WI.FilterBar):

  • UserInterface/Views/FilterBar.css:

(.filter-bar > .navigation-bar > .item):
(.filter-bar > input[type="search"]):
(.filter-bar > .navigation-bar + input[type="search"]): Added.
(.filter-bar > input[type="search"] + .navigation-bar:empty): Added.
Move the position of the filter bar buttons to be after the filter bar itself, so that other
parents can add action items before the filter bar to keep a consistent positioning.

  • to the left of the filter bar are action items (e.g. "+")
  • the filter bar itself
  • to the right of the filter bar are filter buttons (e.g. "filter by resoure with issue")
  • UserInterface/Controllers/NetworkManager.js:

(WI.NetworkManager.prototype.get frames):
Drive-by: use Array.from, instead of [...map.values()].

  • UserInterface/Models/Frame.js:

(WI.Frame.prototype.get url):
(WI.Frame.prototype.get urlComponents): Added.

  • UserInterface/Base/URLUtilities.js.js:

(parseURL):
Calculate and include the origin string with the output.

  • UserInterface/Controllers/CSSManager.js:

(WI.CSSManager.prototype.preferredInspectorStyleSheetForFrame):
Remove doNotCreateIfMissing now that the last caller has been removed.

  • Localizations/en.lproj/localizedStrings.js:

LayoutTests:

  • inspector/unit-tests/url-utilities.html:
  • inspector/unit-tests/url-utilities-expected.txt:
5:37 PM Changeset in webkit [248752] by Wenson Hsieh
  • 2 edits in trunk/LayoutTests

Tidy up some event stream helpers in basic-gestures.js
https://bugs.webkit.org/show_bug.cgi?id=200783

Reviewed by Tim Horton.

  • resources/basic-gestures.js:

Make a few small adjustments:
(1) Invoke uiScriptComplete within the completion callback of sendEventStream. This actually doesn't result in

any behavior differences, since UIScriptController will, by default, wait for non-persistent asynchronous
tasks to finish before allowing the UI-side script invocation to finish.

(2) Fix some minor indentation issues in longPressAndHoldAtPoint, touchAndDragFromPointToPoint, holdAtPoint,

and continueTouchAndDragFromPointToPoint.

5:12 PM Changeset in webkit [248751] by sihui_liu@apple.com
  • 12 edits
    2 adds in trunk/Source/WebCore

Use one VM per thread for IDB serialization work in network process
https://bugs.webkit.org/show_bug.cgi?id=200526

Reviewed by Geoffrey Garen.

We had one static VM in UniqueIDBDatabase for serialization/deserialization in MemoryObjectStore. This VM was
never destroyed and could be used on different background threads.

We also had one VM per SQLiteIDBBackingStore for serialization/deserialization in SQLiteIDBBackingStore. If
there were multiple IndexedDB databases of the same session opened, we would have multiple VMs created
on the same thread. Each VM has its memory allocator and garbage collector, which takes up memory.

To be more memory efficient and safe, we can use one VM per thread in the network process, and create/destroy
the VMs on demand.

  • Modules/indexeddb/server/IDBSerializationContext.cpp: Added.

(WebCore::IDBServer::IDBSerializationContext::getOrCreateIDBSerializationContext):
(WebCore::IDBServer::IDBSerializationContext::~IDBSerializationContext):
(WebCore::IDBServer::IDBSerializationContext::initializeVM):
(WebCore::IDBServer::IDBSerializationContext::vm):
(WebCore::IDBServer::IDBSerializationContext::execState):
(WebCore::IDBServer::IDBSerializationContext::IDBSerializationContext):

  • Modules/indexeddb/server/IDBSerializationContext.h: Added.
  • Modules/indexeddb/server/IDBServer.cpp:

(WebCore::IDBServer::IDBServer::createBackingStore):

  • Modules/indexeddb/server/MemoryIDBBackingStore.cpp:

(WebCore::IDBServer::MemoryIDBBackingStore::create):
(WebCore::IDBServer::MemoryIDBBackingStore::MemoryIDBBackingStore):
(WebCore::IDBServer::MemoryIDBBackingStore::createObjectStore):

  • Modules/indexeddb/server/MemoryIDBBackingStore.h:
  • Modules/indexeddb/server/MemoryObjectStore.cpp:

(WebCore::IDBServer::MemoryObjectStore::create):
(WebCore::IDBServer::MemoryObjectStore::MemoryObjectStore):
(WebCore::IDBServer::MemoryObjectStore::updateIndexesForPutRecord):
(WebCore::IDBServer::MemoryObjectStore::populateIndexWithExistingRecords):

  • Modules/indexeddb/server/MemoryObjectStore.h:
  • Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:

(WebCore::IDBServer::SQLiteIDBBackingStore::SQLiteIDBBackingStore):
(WebCore::IDBServer::SQLiteIDBBackingStore::~SQLiteIDBBackingStore):
(WebCore::IDBServer::SQLiteIDBBackingStore::updateOneIndexForAddRecord):
(WebCore::IDBServer::SQLiteIDBBackingStore::updateAllIndexesForAddRecord):
(WebCore::IDBServer::SQLiteIDBBackingStore::initializeVM): Deleted.
(WebCore::IDBServer::SQLiteIDBBackingStore::vm): Deleted.
(WebCore::IDBServer::SQLiteIDBBackingStore::globalObject): Deleted.

  • Modules/indexeddb/server/SQLiteIDBBackingStore.h:
  • Modules/indexeddb/server/UniqueIDBDatabase.cpp:

(WebCore::IDBServer::UniqueIDBDatabase::databaseThreadVM): Deleted.
(WebCore::IDBServer::UniqueIDBDatabase::databaseThreadExecState): Deleted.

  • Modules/indexeddb/server/UniqueIDBDatabase.h:
  • Sources.txt:
3:18 PM Changeset in webkit [248750] by Alan Bujtas
  • 4 edits
    2 adds in trunk

[ContentChangeObserver] Dispatch synthetic click when the visibility candidate element becomes hidden again.
https://bugs.webkit.org/show_bug.cgi?id=200773
<rdar://problem/54351728>

Reviewed by Simon Fraser.

Source/WebCore:

This patch fixes the case when the candidate element (going from hidden to visible) becomes hidden by the end of the observation window. It essentially means that no visible change has happened
and we should proceed with dispatching the synthetic click event.
We now keep track of the candidate element and reset the visiblity state when it loses its renderer.

Test: fast/events/touch/ios/content-observation/going-from-hidden-to-visible-and-to-hidden.html

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::didAddTransition):
(WebCore::ContentChangeObserver::didFinishTransition):
(WebCore::ContentChangeObserver::didInstallDOMTimer):
(WebCore::ContentChangeObserver::reset):
(WebCore::ContentChangeObserver::rendererWillBeDestroyed):
(WebCore::ContentChangeObserver::contentVisibilityDidChange):
(WebCore::ContentChangeObserver::touchEventDidStart):
(WebCore::ContentChangeObserver::touchEventDidFinish):
(WebCore::ContentChangeObserver::mouseMovedDidStart):
(WebCore::ContentChangeObserver::mouseMovedDidFinish):
(WebCore::ContentChangeObserver::adjustObservedState):
(WebCore::ContentChangeObserver::StyleChangeScope::~StyleChangeScope):
(WebCore::ContentChangeObserver::hasDeterminateState const): Deleted.

  • page/ios/ContentChangeObserver.h:

(WebCore::ContentChangeObserver::hasObservedTransition const):
(WebCore::ContentChangeObserver::setTouchEventIsBeingDispatched):
(WebCore::ContentChangeObserver::isTouchEventBeingDispatched const):
(WebCore::ContentChangeObserver::setMouseMovedEventIsBeingDispatched):
(WebCore::ContentChangeObserver::isMouseMovedEventBeingDispatched const):
(WebCore::ContentChangeObserver::isObservingContentChanges const):

LayoutTests:

  • fast/events/touch/ios/content-observation/going-from-hidden-to-visible-and-to-hidden-expected.html: Added.
  • fast/events/touch/ios/content-observation/going-from-hidden-to-visible-and-to-hidden.html: Added.
3:15 PM Changeset in webkit [248749] by Justin Fan
  • 2 edits in trunk/Source/WebCore

Unreviewed suggested patch follow-up to https://bugs.webkit.org/show_bug.cgi?id=200740.

  • platform/graphics/gpu/GPURequestAdapterOptions.h:

(): Deleted.

2:49 PM Changeset in webkit [248748] by Brent Fulgham
  • 21 edits
    2 adds in trunk/Source/WebCore

[FTW] Support web fonts
https://bugs.webkit.org/show_bug.cgi?id=200771
<rdar://problem/54350291>

Reviewed by Dean Jackson.

The current code path for handling web fonts uses 'AddFontMemResourceEx'. Unfortunately, this only updates the font caches used by GDI, and is not exposed to DirectWrite.

This patch does the following:

  1. Moves some code into a new DirectWriteUtilities file, similar to how Direct2D is handled, so we can share code in more places.
  2. After adding the font to GDI, it adds the font information to the DirectWrite font cache.
  3. Add logic to check the overall system DirectWrite fonts, as well as the custom font cache used for downloaded fonts.
  • PlatformFTW.cmake: Add DirectWriteUtilities.cpp
  • css/CSSFontFaceSource.cpp:
  • loader/cache/CachedFont.cpp:
  • loader/cache/CachedSVGFont.cpp:
  • platform/graphics/Font.cpp:
  • platform/graphics/Font.h:
  • platform/graphics/FontCache.cpp:
  • platform/graphics/FontPlatformData.cpp:
  • platform/graphics/FontPlatformData.h:
  • platform/graphics/opentype/OpenTypeUtilities.cpp:

(WebCore::renameAndActivateFont):

  • platform/graphics/win/DirectWriteUtilities.cpp: Added.
  • platform/graphics/win/DirectWriteUtilities.h: Added.
  • platform/graphics/win/FontCacheWin.cpp:

(WebCore::createGDIFont):

  • platform/graphics/win/FontCascadeDirect2D.cpp:
  • platform/graphics/win/FontCustomPlatformData.cpp:

(WebCore::FontCustomPlatformData::fontPlatformData):

  • platform/graphics/win/FontPlatformDataDirect2D.cpp:

(WebCore::FontPlatformData::platformDataInit):
(WebCore::FontPlatformData::FontPlatformData):
(WebCore::FontPlatformData::createFallbackFont):

  • platform/graphics/win/FontPlatformDataWin.cpp:
  • platform/graphics/win/GlyphPageTreeNodeDirect2D.cpp:

(WebCore::GlyphPage::fill):

  • platform/graphics/win/GraphicsContextDirect2D.cpp:
  • platform/graphics/win/SimpleFontDataDirect2D.cpp:

(WebCore::Font::systemDWriteFactory): Deleted.
(WebCore::Font::systemDWriteGdiInterop): Deleted.

  • platform/graphics/win/SimpleFontDataWin.cpp:
2:39 PM Changeset in webkit [248747] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

[Cocoa] Adopt -preventDisplaySleepForVideoPlayback
https://bugs.webkit.org/show_bug.cgi?id=200774

Reviewed by Eric Carlson.

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

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureLayer):

2:18 PM Changeset in webkit [248746] by rmorisset@apple.com
  • 4 edits in trunk
[WHLSL] Don't accept operator&& or operator
in the Lexer

https://bugs.webkit.org/show_bug.cgi?id=200785

Reviewed by Saam Barati.

Source/WebCore:

Implementing && or
as function calls would lose us short-circuiting.

2 new tests in LayoutTests/webgpu/whlsl/lexing.html

  • Modules/webgpu/WHLSL/WHLSLLexer.cpp:

(WebCore::WHLSL::Lexer::consumeTokenFromStream):

LayoutTests:

  • webgpu/whlsl/lexing.html:
1:50 PM Changeset in webkit [248745] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKitLegacy/mac

Cherry-pick r248741. rdar://problem/54360841

Yellow Lookup highlight gets stuck over Mail messages
https://bugs.webkit.org/show_bug.cgi?id=200778
<rdar://problem/53868514>

Reviewed by Wenson Hsieh.

  • WebView/WebView.mm: (-[WebView _showDictionaryLookupPopup:]): Add a dismissal callback so that when Reveal hides the panel, it also dismisses the yellow indicator. This matches the behavior in modern WebKit.

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

1:50 PM Changeset in webkit [248744] by Alan Coon
  • 7 edits in branches/safari-608-branch/Source

Cherry-pick r248731. rdar://problem/54360857

Unreviewed, rolling out r248440.
https://bugs.webkit.org/show_bug.cgi?id=200772

Introduced regressions related to loading of local files.
(Requested by perarne on #webkit).

Reverted changeset:

"[Mac] Use the PID of the WebContent process when issuing
local file read sandbox extensions"
https://bugs.webkit.org/show_bug.cgi?id=200543
https://trac.webkit.org/changeset/248440

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

1:49 PM Changeset in webkit [248743] by Alan Coon
  • 3 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248722. rdar://problem/54360866

Negative size box with border radius causes hang under WebCore::approximateAsRegion
https://bugs.webkit.org/show_bug.cgi?id=200769
<rdar://problem/53380674>

Reviewed by Alex Christensen.

Source/WebCore:

If a box's width or height computes negative the rounded border rect will also be negative.
This caused near-infinite loop during rounded border region approximation.

Test: fast/css/border-radius-negative-size.html

  • platform/graphics/RoundedRect.cpp: (WebCore::approximateAsRegion):

Bail out if the region is empty (which includes negative sizes).
For safety also limit the number of rectangles we generate for corner arc approximation.

LayoutTests:

  • fast/css/border-radius-negative-size-expected.txt: Added.
  • fast/css/border-radius-negative-size.html: Added.

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

1:49 PM Changeset in webkit [248742] by Alan Coon
  • 4 edits in branches/safari-608-branch

Cherry-pick r248717. rdar://problem/54360854

WKUIDelegate's webView:contextMenuDidEndForElement: should be called when context menus end
https://bugs.webkit.org/show_bug.cgi?id=200750
<rdar://problem/54232261> and <rdar://problem/52355829>

Patch by Alex Christensen <achristensen@webkit.org> on 2019-08-15
Reviewed by Tim Horton.

Source/WebKit:

  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView contextMenuInteraction:willEndForConfiguration:animator:]):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/ContextMenus.mm: (-[TestContextMenuUIDelegate webView:contextMenuConfigurationForElement:completionHandler:]): (-[TestContextMenuUIDelegate webView:contextMenuForElement:willCommitWithAnimator:]): (-[TestContextMenuUIDelegate webView:contextMenuDidEndForElement:]): (contextMenuWebViewDriver): (TEST):

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

1:21 PM Changeset in webkit [248741] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKitLegacy/mac

Yellow Lookup highlight gets stuck over Mail messages
https://bugs.webkit.org/show_bug.cgi?id=200778
<rdar://problem/53868514>

Reviewed by Wenson Hsieh.

  • WebView/WebView.mm:

(-[WebView _showDictionaryLookupPopup:]):
Add a dismissal callback so that when Reveal hides the panel, it also
dismisses the yellow indicator. This matches the behavior in modern WebKit.

1:13 PM Changeset in webkit [248740] by sbarati@apple.com
  • 2 edits in trunk/Source/WebCore

Unreviewed. Debug build fix after r248730.

  • Modules/webgpu/WHLSL/Metal/WHLSLNativeFunctionWriter.cpp:

(WebCore::WHLSL::Metal::inlineNativeFunction):

12:32 PM Changeset in webkit [248739] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: CodeMirror still inserts a tab even when "Prefer indent using" is set to "Spaces"
https://bugs.webkit.org/show_bug.cgi?id=200770

Reviewed by Ross Kirsling.

  • UserInterface/Views/CodeMirrorAdditions.js:

Remap the insertTab command to use insertSoftTab when "Prefer indent using" is set to
"Spaces" so that CodeMirror inserts the number of spaces that would match a tab ("\t") being
inserted at the same spot.

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

DateConversion::formatDateTime incorrectly formats negative years
https://bugs.webkit.org/show_bug.cgi?id=199964

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-08-15
Reviewed by Ross Kirsling.

JSTests:

  • test262/expectations.yaml: Mark 6 test cases as passing.

Source/JavaScriptCore:

Currently, year is always padded to max length of 4, including the minus sign "-".
With this change, only absolute value of year is padded to max length of 4 and
preceded by minus sign "-" if the year is negative.
(steps 6-10 of https://tc39.es/ecma262/#sec-datestring)

  • runtime/DateConversion.cpp:

(JSC::appendNumber):

12:18 PM Changeset in webkit [248737] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Sources: the "No Filter Results" message sits on top of all of the content, preventing any interaction
https://bugs.webkit.org/show_bug.cgi?id=200755

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/SourcesNavigationSidebarPanel.js:

(WI.SourcesNavigationSidebarPanel):

  • UserInterface/Views/SourcesNavigationSidebarPanel.css:

(.sidebar > .panel.navigation.sources > .content > .resources-container): Added.
(@media (min-height: 650px) .sidebar > .panel.navigation.sources > .content > :matches(.call-stack-container, .breakpoints-container, .resources-container)): Added.
(@media (min-height: 650px) .sidebar > .panel.navigation.sources > .content > .call-stack-container):
(@media (min-height: 650px) .sidebar > .panel.navigation.sources > .content > .breakpoints-container):
(@media (min-height: 650px) .sidebar > .panel.navigation.sources > .content > .resources-container): Added.
(@media (min-height: 650px) .sidebar > .panel.navigation.sources > .content > :matches(.call-stack-container, .breakpoints-container, .resources)): Deleted.
(@media (min-height: 650px) .sidebar > .panel.navigation.sources > .content > .resources): Deleted.
Wrap the resources WI.TreeOutline in a <div> so the empty message placeholder that gets
inserted after it can be constrained to the size of the WI.TreeOutline.

12:16 PM Changeset in webkit [248736] by Devin Rousso
  • 5 edits in trunk

Web Inspector: support console.screenshot with detached <canvas>
https://bugs.webkit.org/show_bug.cgi?id=200723

Reviewed by Joseph Pecoraro.

Source/WebCore:

  • page/PageConsoleClient.cpp:

(WebCore::snapshotCanvas): Added.
(WebCore::PageConsoleClient::screenshot):

LayoutTests:

  • inspector/console/console-screenshot.html:
  • inspector/console/console-screenshot-expected.txt:
12:13 PM Changeset in webkit [248735] by Devin Rousso
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: Layers: background of 3D area doesn't update when transitioning to/from Dark mode
https://bugs.webkit.org/show_bug.cgi?id=200775

Reviewed by Ross Kirsling.

  • UserInterface/Views/Layers3DContentView.js:

(WI.Layers3DContentView.prototype.initialLayout):
Add a matchMedia listener for (prefers-color-scheme: dark) and update the clear color
of the WebGL renderer whenever it changes.

  • UserInterface/Views/ErrorObjectView.css:

(@media (prefers-color-scheme: dark)): Added.
(@media (prefers-dark-interface)): Deleted.

  • UserInterface/Views/SourcesNavigationSidebarPanel.css:

(@media (prefers-color-scheme: dark)): Added.
(@media (prefers-dark-interface)): Deleted.
Drive-by: replace older prefers-dark-interface with modern prefers-color-scheme: dark.

11:41 AM Changeset in webkit [248734] by sihui_liu@apple.com
  • 89 edits
    3 adds
    1 delete in trunk

Some improvements on web storage
https://bugs.webkit.org/show_bug.cgi?id=200373

Reviewed by Geoffrey Garen.
Source/WebCore:

Remove storage type EphemeralLocalStorage, which is used for localStorage in ephemeral session, and use
LocalStorage instead.

Add SessionID to StorageNamespace to make StorageNamespace session-specific.

No new test, updating existing tests for new behavior.

  • loader/EmptyClients.cpp:

(WebCore::EmptyStorageNamespaceProvider::createLocalStorageNamespace):
(WebCore::EmptyStorageNamespaceProvider::createTransientLocalStorageNamespace):
(WebCore::EmptyStorageNamespaceProvider::createEphemeralLocalStorageNamespace): Deleted.

  • page/Chrome.cpp:

(WebCore::Chrome::createWindow const): ephemeral localStorage of different windows will connect to the same
StorageArea in network process, so no need to copy from parent window to child window.

  • page/DOMWindow.cpp:

(WebCore::DOMWindow::prewarmLocalStorageIfNecessary): localStorage will be prewarmed in network process in the
initialization of StorageAreaMap.

  • page/Page.cpp:

(WebCore::m_applicationManifest):
(WebCore::Page::~Page):
(WebCore::Page::setSessionID):
(WebCore::Page::ephemeralLocalStorage): Deleted.
(WebCore::Page::setEphemeralLocalStorage): Deleted.
(WebCore::Page::setStorageNamespaceProvider): Deleted.

  • page/Page.h:

(WebCore::Page::storageNamespaceProvider):

  • storage/Storage.cpp:

(WebCore::Storage::prewarm): Deleted.

  • storage/Storage.h:
  • storage/StorageArea.h:

(WebCore::StorageArea::closeDatabaseIfIdle):
(WebCore::StorageArea::prewarm): Deleted.

  • storage/StorageNamespace.h:
  • storage/StorageNamespaceProvider.cpp:

(WebCore::StorageNamespaceProvider::~StorageNamespaceProvider):
(WebCore::StorageNamespaceProvider::localStorageArea):
(WebCore::StorageNamespaceProvider::localStorageNamespace):
(WebCore::StorageNamespaceProvider::transientLocalStorageNamespace):
(WebCore::StorageNamespaceProvider::enableLegacyPrivateBrowsingForTesting): change SessionID of storageNamespace
and update every StorageArea in this namespace.
(WebCore::StorageNamespaceProvider::addPage): Deleted.
(WebCore::StorageNamespaceProvider::removePage): Deleted.

  • storage/StorageNamespaceProvider.h:
  • storage/StorageType.h:

(WebCore::isLocalStorage):

Source/WebKit:

Fix some issues in web storage architecture. For example, sessionStorageNameSpace for web page is prepared and
destroyed in the network process when the page comes and goes, even though the page may not use sessionStorage
at all. The messages about page state sent from web process to network process can be waste.

Here are some general ideas of this patch:

  1. Network process owns the web storage, and web process keeps a small local copy (based on session and

origins that are visited). There is a virtual connection from the local copy in the web process to the original
copy in the network process. The connection is created by web process when some page asks for web storage.

  1. If connection is lost because network process is gone, storage in memory will be lost. The local copy in web

processs will be discarded.

  1. (SessionID, StorageNamespaceID, SecurityOrigin) is used to identify a storage area. If session is changed in

web process (like enabling private browsing in layout test now), a re-connection with different sessionID would
suffice to load another copy of storage.

  1. localStorage in ephemeral session has the same behavior as localStorage instead of sessionStorage, which

means different pages in the same ephemeral session share the same localStorage.

Also, this patch introduces StorageManagerSet to network process. It handles web storage stuff, including
receiving storage messages from web process, on one background thread. Previously each session has its own
StorageManager and each StorageManager has its own WorkQueue.

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • NetworkProcess/NetworkConnectionToWebProcess.cpp: remove message handlers that are no longer needed. Network

process no longer needs to know page states from web process.
(WebKit::NetworkConnectionToWebProcess::didClose):
(WebKit::NetworkConnectionToWebProcess::webPageWasAdded): Deleted.
(WebKit::NetworkConnectionToWebProcess::webPageWasRemoved): Deleted.
(WebKit::NetworkConnectionToWebProcess::webProcessSessionChanged): Deleted.

  • NetworkProcess/NetworkConnectionToWebProcess.h:
  • NetworkProcess/NetworkConnectionToWebProcess.messages.in:
  • NetworkProcess/NetworkProcess.cpp: NetworkProcess uses StorageManagerSet instead of StorageManager from

different sessions to deal with web storage.
(WebKit::NetworkProcess::NetworkProcess):
(WebKit::NetworkProcess::initializeNetworkProcess):
(WebKit::NetworkProcess::createNetworkConnectionToWebProcess): StorageManagerSet starts handling
StorageManagerSet messages from the new connection.
(WebKit::NetworkProcess::addWebsiteDataStore):
(WebKit::NetworkProcess::destroySession):
(WebKit::NetworkProcess::hasLocalStorage):
(WebKit::NetworkProcess::fetchWebsiteData):
(WebKit::NetworkProcess::deleteWebsiteData):
(WebKit::NetworkProcess::deleteWebsiteDataForOrigins):
(WebKit::NetworkProcess::deleteWebsiteDataForRegistrableDomains):
(WebKit::NetworkProcess::actualPrepareToSuspend):
(WebKit::NetworkProcess::resume):
(WebKit::NetworkProcess::syncLocalStorage):
(WebKit::NetworkProcess::clearLegacyPrivateBrowsingLocalStorage): added for clearing in-memory ephemeral
localStorage.
(WebKit::NetworkProcess::getLocalStorageOriginDetails):
(WebKit::NetworkProcess::connectionToWebProcessClosed):
(WebKit::NetworkProcess::webPageWasAdded): Deleted.
(WebKit::NetworkProcess::webPageWasRemoved): Deleted.
(WebKit::NetworkProcess::webProcessWasDisconnected): Deleted.
(WebKit::NetworkProcess::webProcessSessionChanged): Deleted.

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/NetworkSession.cpp: StorageManager is moved out of NetworkSession. It is now managed by

StorageManagerSet.
(WebKit::NetworkSession::NetworkSession):
(WebKit::NetworkSession::~NetworkSession):

  • NetworkProcess/NetworkSession.h:

(WebKit::NetworkSession::storageManager): Deleted.

  • NetworkProcess/NetworkSessionCreationParameters.cpp: creation parameters of StorageManager is moved out of

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

  • NetworkProcess/NetworkSessionCreationParameters.h:
  • NetworkProcess/WebStorage/LocalStorageDatabase.cpp:

(WebKit::LocalStorageDatabase::updateDatabase): remove an assertion that is no longer true as we can force an
update with syncLocalStorage now.

  • NetworkProcess/WebStorage/LocalStorageDatabase.h: make updateDatabase public for syncLocalStorage.
  • NetworkProcess/WebStorage/LocalStorageDatabaseTracker.cpp: LocalStorageDatabaseTracker is created on the

background thread now, so it does not hold WorkQueue to do the file operation.
(WebKit::LocalStorageDatabaseTracker::create):
(WebKit::LocalStorageDatabaseTracker::LocalStorageDatabaseTracker):
(WebKit::LocalStorageDatabaseTracker::~LocalStorageDatabaseTracker):

  • NetworkProcess/WebStorage/LocalStorageDatabaseTracker.h:
  • NetworkProcess/WebStorage/LocalStorageNamespace.cpp:

(WebKit::LocalStorageNamespace::getOrCreateStorageArea):
(WebKit::LocalStorageNamespace::cloneTo): Deleted.

  • NetworkProcess/WebStorage/LocalStorageNamespace.h:
  • NetworkProcess/WebStorage/SessionStorageNamespace.cpp:

(WebKit::SessionStorageNamespace::getOrCreateStorageArea):
(WebKit::SessionStorageNamespace::addAllowedConnection): Deleted.
(WebKit::SessionStorageNamespace::removeAllowedConnection): Deleted.

  • NetworkProcess/WebStorage/SessionStorageNamespace.h:

(WebKit::SessionStorageNamespace::allowedConnections const): Deleted.

  • NetworkProcess/WebStorage/StorageArea.cpp:

(WebKit::generateStorageAreaIdentifier): each StorageArea has an identifier. StorageAreaMap in web process uses
this identifier to indicate which StorageArea it is connecting to.
(WebKit::StorageArea::StorageArea):
(WebKit::StorageArea::~StorageArea): StorageArea may still have listeners because StorageArea should be
destroyed by requests from UI process, and listeners are connections to web processses.
(WebKit::StorageArea::addListener): load localStorageDatabase in advance if there is some connection to this
LocalStorage area.
(WebKit::StorageArea::removeListener):
(WebKit::StorageArea::hasListener const):
(WebKit::StorageArea::clear):
(WebKit::StorageArea::openDatabaseAndImportItemsIfNeeded const):
(WebKit::StorageArea::dispatchEvents const):
(WebKit::StorageArea::syncToDatabase):
(WebKit::StorageArea::setItems): Deleted. Stop syncing from web process to network process after network process
is relaunched.

  • NetworkProcess/WebStorage/StorageArea.h:

(WebKit::StorageArea::identifier):
(WebKit::StorageArea::setWorkQueue):

  • NetworkProcess/WebStorage/StorageManager.cpp: StorageManager should be accessed by only background thread now.

(WebKit::StorageManager::StorageManager):
(WebKit::StorageManager::~StorageManager):
(WebKit::StorageManager::createSessionStorageNamespace):
(WebKit::StorageManager::destroySessionStorageNamespace): this is not used now but keep it for future
improvement to remove in-memory sessionStorage in network process if we know some web page is gone forever.
(WebKit::StorageManager::cloneSessionStorageNamespace): previously each page had its own ephemeral
localStorageNamespace and now all pages in the same session share one localStorage, so we don't need to clone
localStorageNamespace.
(WebKit::StorageManager::getSessionStorageOrigins):
(WebKit::StorageManager::deleteSessionStorageOrigins):
(WebKit::StorageManager::deleteSessionStorageEntriesForOrigins):
(WebKit::StorageManager::getLocalStorageOrigins):
(WebKit::StorageManager::getLocalStorageOriginDetails):
(WebKit::StorageManager::deleteLocalStorageOriginsModifiedSince):
(WebKit::StorageManager::deleteLocalStorageEntriesForOrigins):
(WebKit::StorageManager::createLocalStorageArea):
(WebKit::StorageManager::createTransientLocalStorageArea):
(WebKit::StorageManager::createSessionStorageArea):
(WebKit::StorageManager::getOrCreateLocalStorageNamespace):
(WebKit::StorageManager::getOrCreateTransientLocalStorageNamespace):
(WebKit::StorageManager::getOrCreateSessionStorageNamespace):
(WebKit::StorageManager::clearStorageNamespaces):
(WebKit::StorageManager::addAllowedSessionStorageNamespaceConnection): Deleted.
(WebKit::StorageManager::removeAllowedSessionStorageNamespaceConnection): Deleted.
(WebKit::StorageManager::processDidCloseConnection): Deleted.
(WebKit::StorageManager::deleteLocalStorageEntriesForOrigin): Deleted.
(WebKit::StorageManager::createLocalStorageMap): Deleted.
(WebKit::StorageManager::createTransientLocalStorageMap): Deleted.
(WebKit::StorageManager::createSessionStorageMap): Deleted.
(WebKit::StorageManager::destroyStorageMap): Deleted.
(WebKit::StorageManager::prewarm): Deleted.
(WebKit::StorageManager::getValues): Deleted.
(WebKit::StorageManager::setItem): Deleted.
(WebKit::StorageManager::setItems): Deleted.
(WebKit::StorageManager::removeItem): Deleted.
(WebKit::StorageManager::clear): Deleted.
(WebKit::StorageManager::waitUntilTasksFinished): Deleted.
(WebKit::StorageManager::suspend): Deleted.
(WebKit::StorageManager::resume): Deleted.
(WebKit::StorageManager::findStorageArea const): Deleted.

  • NetworkProcess/WebStorage/StorageManager.h:

(WebKit::StorageManager::workQueue const): Deleted.
(): Deleted.

  • NetworkProcess/WebStorage/StorageManager.messages.in: Removed. Moved to StorageManagerSet.messages.in.
  • NetworkProcess/WebStorage/StorageManagerSet.cpp: Added.

(WebKit::StorageManagerSet::create):
(WebKit::StorageManagerSet::StorageManagerSet):
(WebKit::StorageManagerSet::~StorageManagerSet):
(WebKit::StorageManagerSet::add):
(WebKit::StorageManagerSet::remove):
(WebKit::StorageManagerSet::contains):
(WebKit::StorageManagerSet::addConnection):
(WebKit::StorageManagerSet::removeConnection):
(WebKit::StorageManagerSet::waitUntilTasksFinished):
(WebKit::StorageManagerSet::waitUntilSyncingLocalStorageFinished):
(WebKit::StorageManagerSet::suspend):
(WebKit::StorageManagerSet::resume):
(WebKit::StorageManagerSet::getSessionStorageOrigins):
(WebKit::StorageManagerSet::deleteSessionStorage):
(WebKit::StorageManagerSet::deleteSessionStorageForOrigins):
(WebKit::StorageManagerSet::getLocalStorageOrigins):
(WebKit::StorageManagerSet::deleteLocalStorageModifiedSince):
(WebKit::StorageManagerSet::deleteLocalStorageForOrigins):
(WebKit::StorageManagerSet::getLocalStorageOriginDetails):
(WebKit::StorageManagerSet::connectToLocalStorageArea):
(WebKit::StorageManagerSet::connectToTransientLocalStorageArea):
(WebKit::StorageManagerSet::connectToSessionStorageArea):
(WebKit::StorageManagerSet::disconnectFromStorageArea):
(WebKit::StorageManagerSet::getValues):
(WebKit::StorageManagerSet::setItem):
(WebKit::StorageManagerSet::removeItem):
(WebKit::StorageManagerSet::clear):
(WebKit::StorageManagerSet::cloneSessionStorageNamespace):

  • NetworkProcess/WebStorage/StorageManagerSet.h: Added.
  • NetworkProcess/WebStorage/StorageManagerSet.messages.in: Added.
  • Shared/WebsiteDataStoreParameters.cpp: creation parameters of StorageManager are moved to

WebsiteDataStoreParameters.
(WebKit::WebsiteDataStoreParameters::encode const):
(WebKit::WebsiteDataStoreParameters::decode):
(WebKit::WebsiteDataStoreParameters::privateSessionParameters):

  • Shared/WebsiteDataStoreParameters.h:
  • Sources.txt:
  • UIProcess/API/C/WKContext.cpp: add SPI for tests.

(WKContextSyncLocalStorage):
(WKContextClearLegacyPrivateBrowsingLocalStorage):

  • UIProcess/API/C/WKContextPrivate.h:
  • UIProcess/API/C/WKWebsiteDataStoreRef.cpp:

(WKWebsiteDataStoreRemoveLocalStorage):

  • UIProcess/API/C/WKWebsiteDataStoreRef.h:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::ensureNetworkProcess):
(WebKit::WebProcessPool::syncLocalStorage):
(WebKit::WebProcessPool::clearLegacyPrivateBrowsingLocalStorage):

  • UIProcess/WebProcessPool.h:
  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::WebsiteDataStore::parameters):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::parameters):

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/InjectedBundle/InjectedBundle.cpp: session change of web storage is done via

WebStorageNamespaceProvider instead of WebProcess now.
(WebKit::InjectedBundle::setPrivateBrowsingEnabled):

  • WebProcess/WebProcess.cpp: web process no longer sends messsages about page state to network process.

(WebKit::WebProcess::createWebPage):
(WebKit::WebProcess::removeWebPage):
(WebKit::WebProcess::ensureNetworkProcessConnection):
(WebKit::WebProcess::networkProcessConnectionClosed):
(WebKit::WebProcess::storageAreaMap const):
(WebKit::WebProcess::enablePrivateBrowsingForTesting): Deleted. This was used for changing session via
WebProcess.

  • WebProcess/WebProcess.h:
  • WebProcess/WebStorage/StorageAreaImpl.cpp:

(WebKit::StorageAreaImpl::StorageAreaImpl):
(WebKit::StorageAreaImpl::length):
(WebKit::StorageAreaImpl::key):
(WebKit::StorageAreaImpl::item):
(WebKit::StorageAreaImpl::setItem):
(WebKit::StorageAreaImpl::removeItem):
(WebKit::StorageAreaImpl::clear):
(WebKit::StorageAreaImpl::contains):
(WebKit::StorageAreaImpl::storageType const):
(WebKit::StorageAreaImpl::incrementAccessCount):
(WebKit::StorageAreaImpl::decrementAccessCount):
(WebKit::StorageAreaImpl::prewarm): Deleted.
(WebKit::StorageAreaImpl::securityOrigin const): Deleted.

  • WebProcess/WebStorage/StorageAreaImpl.h: make StorageAreaImpl hold a weak reference to StorageAreaMap and

StorageNamespaceImpl hold a strong reference. In this way lifeime of localStorage StorageAreraMap stays align
with StorageNameSpaceProvider and Page.

  • WebProcess/WebStorage/StorageAreaMap.cpp: identifier of StorageAreaMap is the same as identifier of

StorageArea it connects to. If the identifier is 0, it means the StorageAreaMap is disconnected.
(WebKit::StorageAreaMap::StorageAreaMap):
(WebKit::StorageAreaMap::~StorageAreaMap):
(WebKit::StorageAreaMap::setItem):
(WebKit::StorageAreaMap::removeItem):
(WebKit::StorageAreaMap::clear):
(WebKit::StorageAreaMap::resetValues):
(WebKit::StorageAreaMap::loadValuesIfNeeded):
(WebKit::StorageAreaMap::applyChange):
(WebKit::StorageAreaMap::dispatchStorageEvent):
(WebKit::StorageAreaMap::dispatchSessionStorageEvent):
(WebKit::StorageAreaMap::dispatchLocalStorageEvent):
(WebKit::StorageAreaMap::connect):
(WebKit::StorageAreaMap::disconnect):
(WebKit::generateStorageMapID): Deleted.
(WebKit::StorageAreaMap::prewarm): Deleted.
(WebKit::StorageAreaMap::didGetValues): Deleted. This is useless as GetValues is a synchronous operation.

  • WebProcess/WebStorage/StorageAreaMap.h:

(): Deleted.

  • WebProcess/WebStorage/StorageAreaMap.messages.in: there are two synchronous messages, one for connection and

one for getting values. We may merge them into one in future improvement.

  • WebProcess/WebStorage/StorageNamespaceImpl.cpp:

(WebKit::StorageNamespaceImpl::createSessionStorageNamespace):
(WebKit::StorageNamespaceImpl::createLocalStorageNamespace):
(WebKit::StorageNamespaceImpl::createTransientLocalStorageNamespace):
(WebKit::StorageNamespaceImpl::StorageNamespaceImpl):
(WebKit::StorageNamespaceImpl::storageArea):
(WebKit::StorageNamespaceImpl::copy):
(WebKit::StorageNamespaceImpl::setSessionIDForTesting):
(WebKit::StorageNamespaceImpl::createEphemeralLocalStorageNamespace): Deleted.

  • WebProcess/WebStorage/StorageNamespaceImpl.h:
  • WebProcess/WebStorage/WebStorageNamespaceProvider.cpp:

(WebKit::WebStorageNamespaceProvider::createSessionStorageNamespace):
(WebKit::WebStorageNamespaceProvider::createLocalStorageNamespace):
(WebKit::WebStorageNamespaceProvider::createTransientLocalStorageNamespace):
(WebKit::WebStorageNamespaceProvider::createEphemeralLocalStorageNamespace): Deleted.

  • WebProcess/WebStorage/WebStorageNamespaceProvider.h:

Source/WebKitLegacy:

Do some clean-up and add support for session change of web storage in layout tests.

  • Storage/StorageAreaImpl.cpp:

(WebKit::StorageAreaImpl::sessionChanged):

  • Storage/StorageAreaImpl.h:

(): Deleted.

  • Storage/StorageAreaSync.h: make sure StorageAreaSync is destructed on the main thread, as it can be

dereferenced in StorageAreaImpl::sessionChanged and its last reference for final sync could be released on the
background thread.

  • Storage/StorageNamespaceImpl.cpp: replace EphemeralLocalStorage with LocalStorage, and store SessionID in

StorageNamespace.
(WebKit::StorageNamespaceImpl::createSessionStorageNamespace):
(WebKit::StorageNamespaceImpl::getOrCreateLocalStorageNamespace):
(WebKit::StorageNamespaceImpl::StorageNamespaceImpl):
(WebKit::StorageNamespaceImpl::copy):
(WebKit::StorageNamespaceImpl::close):
(WebKit::StorageNamespaceImpl::setSessionIDForTesting):
(WebKit::StorageNamespaceImpl::createEphemeralLocalStorageNamespace): Deleted.

  • Storage/StorageNamespaceImpl.h:
  • Storage/WebStorageNamespaceProvider.cpp:

(WebKit::WebStorageNamespaceProvider::createSessionStorageNamespace):
(WebKit::WebStorageNamespaceProvider::createLocalStorageNamespace):
(WebKit::WebStorageNamespaceProvider::createTransientLocalStorageNamespace):
(WebKit::WebStorageNamespaceProvider::createEphemeralLocalStorageNamespace): Deleted.

  • Storage/WebStorageNamespaceProvider.h:

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]): notify storageNamespaceProvider about session change.

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/LocalStoragePersistence.mm:

(TEST): update expectation for behavior change.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl: new SPI to synchronously flush localStorage to

database file.

  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::syncLocalStorage):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp: clear local storage between test runs to make each test isolated.

(WTR::TestController::resetStateToConsistentValues):
(WTR::StorageVoidCallbackContext::StorageVoidCallbackContext):
(WTR::StorageVoidCallback):
(WTR::TestController::clearIndexedDatabases):
(WTR::TestController::clearLocalStorage):
(WTR::TestController::syncLocalStorage):
(WTR::RemoveAllIndexedDatabasesCallbackContext::RemoveAllIndexedDatabasesCallbackContext): Deleted. Replaced
with StorageVoidCallbackContext for general usage.
(WTR::RemoveAllIndexedDatabasesCallback): Deleted. Replaced with StorageVoidCallback.
(WTR::TestController::ClearIndexedDatabases): Deleted. Use lowercase for consistent style.

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle): add handler for new message
SyncLocalStorage.

LayoutTests:

Modify tests for a behavior change: sessionStorage will be lost when network process crashes.

For tests which use sessionStorage to store items, crash network process, then read from sessionStorage and
expect items to be in sessionStorage, replace sessionStorage with localStorage. Also, to make sure localStorage
is stored persistently before network process gets terminated, adopt a newly introduced SPI to
synchronously flush localStorage content to disk before terminating network process.

  • platform/ios-simulator-wk2/TestExpectations:
  • platform/mac-wk2/TestExpectations:
  • storage/domstorage/localstorage/private-browsing-affects-storage-expected.txt:
  • storage/indexeddb/IDBObject-leak.html:
  • storage/indexeddb/modern/opendatabase-after-storage-crash-expected.txt:
  • storage/indexeddb/modern/opendatabase-after-storage-crash.html:
11:39 AM Changeset in webkit [248733] by Wenson Hsieh
  • 4 edits
    2 adds in trunk

Occasional hang under -[UIKeyboardTaskQueue lockWhenReadyForMainThread] when long-pressing non-editable text
https://bugs.webkit.org/show_bug.cgi?id=200731
<rdar://problem/54315371>

Reviewed by Tim Horton.

Source/WebKit:

When handling a single tap in non-editable content, keyboards logic in UIKit may attempt to wait for all
pending tasks in UIKeyboardTaskQueue to finish executing (e.g. by calling -waitUntilAllTasksAreFinished]). If
the task queue has a pending task at this moment - for example, a text selection update that is waiting for a
response from the web process - this will result in a permanent deadlock, since the main thread will be blocked,
and therefore cannot receive any IPC communication from the web process.

One way to trigger this is to activate both the loupe gesture and non-editable text tap gesture simultaneously,
by tapping in a non-editable part of the web page, while an ongoing loupe gesture is driving selection updates
(see the layout test for more details).

To avoid getting into this scenario, prevent the text tap gesture recognizer from firing in a few edge cases
that could lead to hangs under keyboard code in UIKit. See comments below.

Test: editing/selection/ios/tap-during-loupe-gesture.html

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

(-[WKContentView textInteractionGesture:shouldBeginAtPoint:]):

Don't allow the text tap gesture recognizer to fire if the user is actively modifying the text selection using
the loupe gesture, or if there's other pending selection change updates that are pending responses from the web
content process.

(-[WKContentView selectTextWithGranularity:atPoint:completionHandler:]):
(-[WKContentView updateSelectionWithExtentPoint:withBoundary:completionHandler:]):

Increment and decrement _suppressNonEditableSingleTapTextInteractionCount while handling these selection
updates.

LayoutTests:

Add a layout test to verify that tapping the page while handling a text loupe gesture doesn't cause the UI
process to hang indefinitely.

  • editing/selection/ios/tap-during-loupe-gesture-expected.txt: Added.
  • editing/selection/ios/tap-during-loupe-gesture.html: Added.
11:14 AM Changeset in webkit [248732] by Joseph Pecoraro
  • 8 edits in trunk

Web Inspector: Update Esprima to trunk (minor fixes)
https://bugs.webkit.org/show_bug.cgi?id=200691
<rdar://problem/54276170>

Rubber-stamped by Devin Rousso.

Source/WebInspectorUI:

  • UserInterface/External/Esprima/esprima.js:

Updated to jquery/esprima@5e55171feb5adbc2b1d28ef4b2628d5ea9af0848.

  • UserInterface/Models/ScriptSyntaxTree.js:

(WI.ScriptSyntaxTree.prototype._gatherIdentifiersInDeclaration.gatherIdentifiers):
(WI.ScriptSyntaxTree.prototype._gatherIdentifiersInDeclaration):
(WI.ScriptSyntaxTree.prototype._recurse):
(WI.ScriptSyntaxTree.prototype._createInternalSyntaxTree):
(WI.ScriptSyntaxTree):

  • UserInterface/Workers/Formatter/ESTreeWalker.js:

(ESTreeWalker.prototype._walkChildren):
(ESTreeWalker):

  • UserInterface/Workers/Formatter/EsprimaFormatter.js:

(EsprimaFormatter.prototype._handleTokenAtNode):

  • SpreadProperty => SpreadElement.
  • RestProperty => RestElement.

Source/WebInspectorUI/../../LayoutTests:

  • inspector/model/parse-script-syntax-tree-expected.txt:
  • inspector/model/parse-script-syntax-tree.html:
  • SpreadProperty => SpreadElement.
  • RestProperty => RestElement.
11:02 AM Changeset in webkit [248731] by commit-queue@webkit.org
  • 7 edits in trunk/Source

Unreviewed, rolling out r248440.
https://bugs.webkit.org/show_bug.cgi?id=200772

Introduced regressions related to loading of local files.
(Requested by perarne on #webkit).

Reverted changeset:

"[Mac] Use the PID of the WebContent process when issuing
local file read sandbox extensions"
https://bugs.webkit.org/show_bug.cgi?id=200543
https://trac.webkit.org/changeset/248440

11:01 AM Changeset in webkit [248730] by sbarati@apple.com
  • 5 edits
    18 adds in trunk

[WHLSL] Make length, clamp, operator+, operator-, operator*, operator/, operator[], operator[]=, operator.xy, operator.xy=, native
https://bugs.webkit.org/show_bug.cgi?id=200700

Reviewed by Robin Morisset.

Source/WebCore:

This makes us 50% faster in compute_boids.

Tests: webgpu/whlsl/clamp-stdlib.html

webgpu/whlsl/length-stdlib.html
webgpu/whlsl/operator-div.html
webgpu/whlsl/operator-minus.html
webgpu/whlsl/operator-plus.html
webgpu/whlsl/operator-times.html
webgpu/whlsl/operator-vector-assign.html
webgpu/whlsl/operator-vector-load.html
webgpu/whlsl/operator-xy.html

  • Modules/webgpu/WHLSL/Metal/WHLSLNativeFunctionWriter.cpp:

(WebCore::WHLSL::Metal::inlineNativeFunction):

  • Modules/webgpu/WHLSL/WHLSLStandardLibrary.txt:
  • Modules/webgpu/WHLSL/WHLSLStandardLibraryUtilities.cpp:

(WebCore::WHLSL::includeStandardLibrary):

LayoutTests:

  • webgpu/whlsl/clamp-stdlib-expected.txt: Added.
  • webgpu/whlsl/clamp-stdlib.html: Added.
  • webgpu/whlsl/length-stdlib-expected.txt: Added.
  • webgpu/whlsl/length-stdlib.html: Added.
  • webgpu/whlsl/operator-div-expected.txt: Added.
  • webgpu/whlsl/operator-div.html: Added.
  • webgpu/whlsl/operator-minus-expected.txt: Added.
  • webgpu/whlsl/operator-minus.html: Added.
  • webgpu/whlsl/operator-plus-expected.txt: Added.
  • webgpu/whlsl/operator-plus.html: Added.
  • webgpu/whlsl/operator-times-expected.txt: Added.
  • webgpu/whlsl/operator-times.html: Added.
  • webgpu/whlsl/operator-vector-assign-expected.txt: Added.
  • webgpu/whlsl/operator-vector-assign.html: Added.
  • webgpu/whlsl/operator-vector-load-expected.txt: Added.
  • webgpu/whlsl/operator-vector-load.html: Added.
  • webgpu/whlsl/operator-xy-expected.txt: Added.
  • webgpu/whlsl/operator-xy.html: Added.
10:49 AM Changeset in webkit [248729] by rmorisset@apple.com
  • 2 edits in trunk/Source/WebCore

[WHLSL] Trivial clean-up of the MSL code generated
https://bugs.webkit.org/show_bug.cgi?id=200525

Reviewed by Darin Adler.

Emit simpler code for ternary expressions
Remove duplicate {} around functions

No new tests as it is covered by the existing ones.

  • Modules/webgpu/WHLSL/Metal/WHLSLFunctionWriter.cpp:

(WebCore::WHLSL::Metal::FunctionDefinitionWriter::visit):

10:44 AM Changeset in webkit [248728] by youenn@apple.com
  • 36 edits in trunk/Source

Always create a Document with a valid SessionID
https://bugs.webkit.org/show_bug.cgi?id=200727

Reviewed by Alex Christensen.

Source/WebCore:

Pass a valid SessionID to the Document constructor.
This allows getting us closer to use SessionID like ObjectIdentifier.
Add a SessionID getter from Frame and use it when constructing a Document.
Otherwise, retrieve the SessionID from the corresponding context.
No change of behavior.

  • dom/DOMImplementation.cpp:

(WebCore::createXMLDocument):
(WebCore::DOMImplementation::createDocument):
(WebCore::DOMImplementation::createHTMLDocument):

  • dom/DOMImplementation.h:
  • dom/Document.cpp:

(WebCore::Document::Document):
(WebCore::m_undoManager):
(WebCore::Document::create):
(WebCore::Document::createNonRenderedPlaceholder):
(WebCore::Document::cloneDocumentWithoutChildren const):
(WebCore::Document::ensureTemplateDocument):

  • dom/Document.h:

(WebCore::Document::create):
(WebCore::Document::createNonRenderedPlaceholder): Deleted.

  • dom/XMLDocument.h:

(WebCore::XMLDocument::create):
(WebCore::XMLDocument::createXHTML):
(WebCore::XMLDocument::XMLDocument):

  • html/FTPDirectoryDocument.cpp:

(WebCore::FTPDirectoryDocument::FTPDirectoryDocument):

  • html/FTPDirectoryDocument.h:
  • html/HTMLDocument.cpp:

(WebCore::HTMLDocument::createSynthesizedDocument):
(WebCore::HTMLDocument::HTMLDocument):
(WebCore::HTMLDocument::cloneDocumentWithoutChildren const):

  • html/HTMLDocument.h:

(WebCore::HTMLDocument::create):
(WebCore::HTMLDocument::createSynthesizedDocument): Deleted.

  • html/ImageDocument.cpp:

(WebCore::ImageDocument::ImageDocument):

  • html/MediaDocument.cpp:

(WebCore::MediaDocument::MediaDocument):

  • html/MediaDocument.h:
  • html/PluginDocument.cpp:

(WebCore::PluginDocument::PluginDocument):

  • html/PluginDocument.h:
  • html/TextDocument.cpp:

(WebCore::TextDocument::TextDocument):

  • html/TextDocument.h:
  • inspector/DOMPatchSupport.cpp:

(WebCore::DOMPatchSupport::patchDocument):

  • loader/DocumentWriter.cpp:

(WebCore::DocumentWriter::createDocument):
(WebCore::DocumentWriter::begin):

  • loader/SinkDocument.cpp:

(WebCore::SinkDocument::SinkDocument):

  • loader/SinkDocument.h:
  • loader/cache/CachedSVGDocument.cpp:

(WebCore::CachedSVGDocument::finishLoading):

  • loader/cache/CachedSVGFont.cpp:

(WebCore::CachedSVGFont::ensureCustomFontData):

  • page/Frame.cpp:

(WebCore::Frame::sessionID const):

  • page/Frame.h:
  • svg/SVGDocument.cpp:

(WebCore::SVGDocument::SVGDocument):
(WebCore::SVGDocument::cloneDocumentWithoutChildren const):

  • svg/SVGDocument.h:

(WebCore::SVGDocument::create):

  • xml/DOMParser.cpp:

(WebCore::DOMParser::parseFromString):

  • xml/DOMParser.h:
  • xml/DOMParser.idl:
  • xml/XMLHttpRequest.cpp:
  • xml/XSLTProcessor.cpp:

(WebCore::XSLTProcessor::createDocumentFromSource):

Source/WebKitLegacy/mac:

Implement WebKit1 sessionID getter like done for WebKit2.
Either the loader client has a page in which case the page session ID is used
or the client has no page, in which case the default session ID is used.
This is the same behavior as CachedResourceLoader.

  • WebCoreSupport/WebFrameLoaderClient.mm:

(WebFrameLoaderClient::sessionID const):

Source/WebKitLegacy/win:

Implement WebKit1 sessionID getter like done for WebKit2.
Either the loader client has a page in which case the page session ID is used
or the client has no page, in which case the default session ID is used.
This is the same behavior as CachedResourceLoader.

  • WebCoreSupport/WebFrameLoaderClient.cpp:

(WebFrameLoaderClient::sessionID const):

10:35 AM Changeset in webkit [248727] by Jonathan Bedard
  • 2 edits in trunk/Tools

results.webkit.org: Add content hook to FlaskRequestsResponse
https://bugs.webkit.org/show_bug.cgi?id=200721

Rubber-stamped by Aakash Jain.

  • resultsdbpy/resultsdbpy/flask_support/flask_testcase.py:

(FlaskRequestsResponse):
(FlaskRequestsResponse.content): Return the encoded raw bytes value of the
Response, conforming to request's API.

10:21 AM Changeset in webkit [248726] by Alan Coon
  • 2 edits in branches/safari-608-branch/Tools

Cherry-pick r248701. rdar://problem/54333796

[iOS](REGRESSION: r200487): WebKit.RequestActivatedElementInfoForRotatedImage fails on iOS 13
https://bugs.webkit.org/show_bug.cgi?id=200726

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-14
Reviewed by Simon Fraser.

To get the pixels as an array of colors, draw the image into a memory
context. The backing memory buffer can then be accessed to get the image
pixels' colors.

  • TestWebKitAPI/Tests/WebKitCocoa/WKRequestActivatedElementInfo.mm: (TestWebKitAPI::TEST):

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

10:20 AM Changeset in webkit [248725] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248690. rdar://problem/54333950

v3: CrashTracer: Regression : MobileSafari at UIKitCore: -[UITargetedPreview initWithView:parameters:]
https://bugs.webkit.org/show_bug.cgi?id=200634

Patch by Luming Yin <luming_yin@apple.com> on 2019-08-14
Reviewed by Simon Fraser.

Under rare race conditions, the WKContentView may no longer have an associated window. However,
UIContextMenuInteraction may still attempt initialize a UITargetedPreview with the orphaned
WKContentView. Speculative fix for crashes under such scenarios, so that we can continue without
a context menu configuration to prevent the UIKit exception.

  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView continueContextMenuInteraction:]):

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

10:20 AM Changeset in webkit [248724] by Alan Coon
  • 1 edit
    4 adds in branches/safari-608-branch/LayoutTests

Cherry-pick r248662. rdar://problem/54333792

[iPadOS] slides.google.com: Cannot dismiss the context menu by tapping on the canvas
https://bugs.webkit.org/show_bug.cgi?id=200219
<rdar://problem/53650423>

Reviewed by Zalan Bujtas.

While the code change for this bug is all in code private to Safari, we add tests that check that removing implicit pointer capture
or removing the original target element while the pointer is active correctly fires the "pointerup" event at the element that hit tests
at the touch release point.

  • pointerevents/ios/pointer-events-implicit-capture-element-removed-while-pointer-active-expected.txt: Added.
  • pointerevents/ios/pointer-events-implicit-capture-element-removed-while-pointer-active.html: Added.
  • pointerevents/ios/pointer-events-implicit-capture-released-while-pointer-active-expected.txt: Added.
  • pointerevents/ios/pointer-events-implicit-capture-released-while-pointer-active.html: Added.

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

10:20 AM Changeset in webkit [248723] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebCore

Cherry-pick r248648. rdar://problem/54333931

Focus rings are black
https://bugs.webkit.org/show_bug.cgi?id=200593
<rdar://problem/54145925>

Patch by Daniel Bates <dabates@apple.com> on 2019-08-13
Reviewed by Wenson Hsieh.

Work around <rdar://problem/50838886> and make focus rings a pretty blue.

  • rendering/RenderThemeIOS.mm: (WebCore::RenderThemeIOS::platformFocusRingColor const):

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

10:20 AM Changeset in webkit [248722] by Antti Koivisto
  • 3 edits
    2 adds in trunk

Negative size box with border radius causes hang under WebCore::approximateAsRegion
https://bugs.webkit.org/show_bug.cgi?id=200769
<rdar://problem/53380674>

Reviewed by Alex Christensen.

Source/WebCore:

If a box's width or height computes negative the rounded border rect will also be negative.
This caused near-infinite loop during rounded border region approximation.

Test: fast/css/border-radius-negative-size.html

  • platform/graphics/RoundedRect.cpp:

(WebCore::approximateAsRegion):

Bail out if the region is empty (which includes negative sizes).
For safety also limit the number of rectangles we generate for corner arc approximation.

LayoutTests:

  • fast/css/border-radius-negative-size-expected.txt: Added.
  • fast/css/border-radius-negative-size.html: Added.
10:17 AM Changeset in webkit [248721] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[GStreamer] Deal with slow buffer consumption in GStreamerMediaStreamSource
https://bugs.webkit.org/show_bug.cgi?id=200633

Refactoring the GStreamerMediaStreamSource factoring out streams specific
data in a dedicated structure.

Patch by Thibault Saunier <tsaunier@igalia.com> on 2019-08-15
Reviewed by Philippe Normand.

No new tests, since I do not see how to reproduce that in a test in a simple way,
this aims at enhancing user experience when running under high load.

  • platform/mediastream/gstreamer/GStreamerMediaStreamSource.cpp:

(WebCore::_WebKitMediaStreamSrc::SourceData::reset):
(WebCore::_WebKitMediaStreamSrc::SourceData::src):
(WebCore::_WebKitMediaStreamSrc::SourceData::setSrc):
(WebCore::_WebKitMediaStreamSrc::SourceData::isUsed):
(WebCore::_WebKitMediaStreamSrc::SourceData::pushSample):
(WebCore::webkitMediaStreamSrcDispose):
(WebCore::webkit_media_stream_src_init):
(WebCore::webkitMediaStreamSrcNeedDataCb):
(WebCore::webkitMediaStreamSrcEnoughDataCb):
(WebCore::webkitMediaStreamSrcSetupAppSrc):
(WebCore::webkitMediaStreamSrcRemoveTrackByType):
(WebCore::webkitMediaStreamSrcPushVideoSample):
(WebCore::webkitMediaStreamSrcPushAudioSample):

10:15 AM Changeset in webkit [248720] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Uncaught Exception: Content request failed.
https://bugs.webkit.org/show_bug.cgi?id=200704
<rdar://problem/54279372>

Reviewed by Brian Burg.

  • UserInterface/Models/WebSocketResource.js:

(WI.WebSocketResource.prototype.requestContentFromBackend): Added.
Add an "assert not reached", as WebSocket resources don't really have "content", instead
having a list of send/receive frames.

  • UserInterface/Views/ResourceClusterContentView.js:

(WI.ResourceClusterContentView.prototype._tryEnableCustomResponseContentView):
Don't attempt to request the content of any WI.WebSocketResource for the reason above.

10:13 AM Changeset in webkit [248719] by Alan Coon
  • 7 edits in branches/safari-608-branch/Source

Versioning.

10:12 AM Changeset in webkit [248718] by youenn@apple.com
  • 20 edits in trunk

Make mock libwebrtc tests run with unified plan
https://bugs.webkit.org/show_bug.cgi?id=200713

Reviewed by Alex Christensen.

Source/ThirdParty/libwebrtc:

  • Configurations/libwebrtc.iOS.exp:
  • Configurations/libwebrtc.iOSsim.exp:
  • Configurations/libwebrtc.mac.exp:

Source/WebCore:

Update mock endpoint to pass mock webrtc tests with unified plan.
This requires implementing support for mock transceivers.
Covered by existing tests.

  • testing/Internals.cpp:

(WebCore::Internals::useMockRTCPeerConnectionFactory):
Update assert to mandate unified plan.

  • testing/MockLibWebRTCPeerConnection.cpp:

(WebCore::MockLibWebRTCPeerConnection::~MockLibWebRTCPeerConnection):
(WebCore::MockLibWebRTCPeerConnection::GetTransceivers const):
(WebCore::MockLibWebRTCPeerConnection::AddTrack):
(WebCore::MockLibWebRTCPeerConnection::RemoveTrack):
(WebCore::MockLibWebRTCPeerConnection::CreateOffer):
(WebCore::MockLibWebRTCPeerConnection::CreateAnswer):

  • testing/MockLibWebRTCPeerConnection.h:

(WebCore::MockRtpSender::MockRtpSender):
(WebCore::MockRtpReceiver::id const):
(WebCore::MockRtpReceiver::GetParameters const):
(WebCore::MockRtpReceiver::SetParameters):
(WebCore::MockRtpReceiver::SetObserver):
(WebCore::MockRtpTransceiver::MockRtpTransceiver):
(WebCore::MockLibWebRTCPeerConnection::MockLibWebRTCPeerConnection):
(WebCore::MockLibWebRTCPeerConnection::gotLocalDescription):

LayoutTests:

Enable unified plan.

  • fast/mediastream/RTCPeerConnection-icecandidate-event.html:
  • fast/mediastream/RTCPeerConnection-iceconnectionstatechange-event.html:
  • fast/mediastream/RTCPeerConnection-inspect-answer.html:
  • fast/mediastream/RTCPeerConnection-inspect-offer.html:
  • fast/mediastream/RTCPeerConnection-media-setup-single-dialog.html:
  • fast/mediastream/RTCPeerConnection-remotely-assigned-transceiver-mid.html:
  • fast/mediastream/RTCPeerConnection-setLocalDescription-offer.html:
  • fast/mediastream/RTCPeerConnection-setRemoteDescription-offer.html:
  • webrtc/libwebrtc/release-while-creating-offer.html:
  • webrtc/libwebrtc/release-while-getting-stats.html:
  • webrtc/libwebrtc/release-while-setting-local-description.html:
9:34 AM Changeset in webkit [248717] by commit-queue@webkit.org
  • 4 edits in trunk

WKUIDelegate's webView:contextMenuDidEndForElement: should be called when context menus end
https://bugs.webkit.org/show_bug.cgi?id=200750
<rdar://problem/54232261> and <rdar://problem/52355829>

Patch by Alex Christensen <achristensen@webkit.org> on 2019-08-15
Reviewed by Tim Horton.

Source/WebKit:

  • UIProcess/ios/WKContentViewInteraction.mm:

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

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/ContextMenus.mm:

(-[TestContextMenuUIDelegate webView:contextMenuConfigurationForElement:completionHandler:]):
(-[TestContextMenuUIDelegate webView:contextMenuForElement:willCommitWithAnimator:]):
(-[TestContextMenuUIDelegate webView:contextMenuDidEndForElement:]):
(contextMenuWebViewDriver):
(TEST):

9:31 AM Changeset in webkit [248716] by mark.lam@apple.com
  • 3 edits
    3 adds in trunk

More missing exception checks in String.prototype.
https://bugs.webkit.org/show_bug.cgi?id=200762
<rdar://problem/54333896>

Reviewed by Michael Saboff.

JSTests:

  • stress/missing-exception-check-in-string-lastIndexOf.js: Added.
  • stress/missing-exception-check-in-string-toLower.js: Added.
  • stress/missing-exception-check-in-string-toUpper.js: Added.

Source/JavaScriptCore:

  • runtime/StringPrototype.cpp:

(JSC::replaceUsingRegExpSearch):
(JSC::operationStringProtoFuncReplaceRegExpString):
(JSC::stringProtoFuncLastIndexOf):
(JSC::stringProtoFuncToLowerCase):
(JSC::stringProtoFuncToUpperCase):

9:02 AM Changeset in webkit [248715] by BJ Burg
  • 8 edits in trunk/Source/WebKit

Web Automation: mouse buttons are not correctly printed in SimulatedInputDispatcher log spew
https://bugs.webkit.org/show_bug.cgi?id=200729

Reviewed by Devin Rousso.

This was printing out gibberish because it was trying to decode a WebMouseEvent button
as an Automation protocol button. The logging was less useful because of it.

To fix this, push usage of Automation protocol-based MouseButton type alias all the way
to the platform-specific methods. The mouse buttons are the same for WebMouseEvent::Button
and the Automation protocol type, except the automation type has an auto-generated toString.

  • UIProcess/Automation/SimulatedInputDispatcher.h:
  • UIProcess/Automation/SimulatedInputDispatcher.cpp:

(WebKit::SimulatedInputDispatcher::transitionInputSourceToState):
(WebKit::SimulatedInputDispatcher::run):
Fix types.

  • UIProcess/Automation/WebAutomationSession.h:
  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::simulateMouseInteraction):
(WebKit::WebAutomationSession::performMouseInteraction):
(WebKit::WebAutomationSession::performInteractionSequence):
(WebKit::protocolMouseButtonToWebMouseEventButton): Deleted.
Fix types.

  • UIProcess/Automation/mac/WebAutomationSessionMac.mm:

(WebKit::automationMouseButtonToPlatformMouseButton):
(WebKit::WebAutomationSession::platformSimulateMouseInteraction):

  • UIProcess/Automation/gtk/WebAutomationSessionGtk.cpp:

(WebKit::mouseButtonToGdkButton):
(WebKit::WebAutomationSession::platformSimulateMouseInteraction):

  • UIProcess/Automation/wpe/WebAutomationSessionWPE.cpp:

(WebKit::mouseButtonToWPEButton):
(WebKit::WebAutomationSession::platformSimulateMouseInteraction):
Move translation between MouseButton and native button values to platform methods.

8:56 AM Changeset in webkit [248714] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Unreviewed WinCairo build fix after r248713.

  • platform/network/curl/NetworkStorageSessionCurl.cpp:

(WebCore::NetworkStorageSession::setCookiesFromDOM const):
(WebCore::NetworkStorageSession::cookiesForDOM const):
(WebCore::NetworkStorageSession::getRawCookies const):
(WebCore::NetworkStorageSession::cookieRequestHeaderFieldValue const):

8:35 AM Changeset in webkit [248713] by Simon Fraser
  • 118 edits
    1 copy in trunk/Source

Use ObjectIdentifier<FrameIdentifierType> for frameIDs
https://bugs.webkit.org/show_bug.cgi?id=199986

Reviewed by Ryosuke Niwa.

Use the strongly-typed FrameIdentifier instead of uint64_t as frame identifiers everywhere.

Source/WebCore:

  • WebCore.xcodeproj/project.pbxproj:
  • loader/CookieJar.cpp:

(WebCore::CookieJar::cookies const):
(WebCore::CookieJar::setCookies):
(WebCore::CookieJar::cookieRequestHeaderFieldValue const):
(WebCore::CookieJar::getRawCookies const):

  • loader/CookieJar.h:
  • loader/EmptyFrameLoaderClient.h:
  • loader/FrameLoaderClient.h:
  • loader/NavigationAction.cpp:
  • loader/NavigationAction.h:

(WebCore::NavigationAction::Requester::frameID const):

  • page/ChromeClient.h:
  • page/GlobalFrameIdentifier.h:

(WebCore::GlobalFrameIdentifier::decode):

  • platform/network/CookieRequestHeaderFieldProxy.h:
  • platform/network/NetworkStorageSession.cpp:

(WebCore::NetworkStorageSession::shouldBlockCookies const):
(WebCore::NetworkStorageSession::hasStorageAccess const):
(WebCore::NetworkStorageSession::grantStorageAccess):
(WebCore::NetworkStorageSession::removeStorageAccessForFrame):

  • platform/network/NetworkStorageSession.h:
  • platform/network/cocoa/NetworkStorageSessionCocoa.mm:

(WebCore::cookiesForURL):
(WebCore::cookiesForSession):
(WebCore::NetworkStorageSession::cookiesForDOM const):
(WebCore::NetworkStorageSession::cookieRequestHeaderFieldValue const):
(WebCore::NetworkStorageSession::setCookiesFromDOM const):
(WebCore::NetworkStorageSession::getRawCookies const):

Source/WebKit:

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::hasStorageAccess):
(WebKit::ResourceLoadStatisticsDatabaseStore::requestStorageAccess):
(WebKit::ResourceLoadStatisticsDatabaseStore::grantStorageAccess):
(WebKit::ResourceLoadStatisticsDatabaseStore::grantStorageAccessInternal):

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.cpp:

(WebKit::ResourceLoadStatisticsMemoryStore::hasStorageAccess):
(WebKit::ResourceLoadStatisticsMemoryStore::requestStorageAccess):
(WebKit::ResourceLoadStatisticsMemoryStore::grantStorageAccess):
(WebKit::ResourceLoadStatisticsMemoryStore::grantStorageAccessInternal):

  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::hasStorageAccess):
(WebKit::WebResourceLoadStatisticsStore::hasStorageAccessForFrame):
(WebKit::WebResourceLoadStatisticsStore::callHasStorageAccessForFrameHandler):
(WebKit::WebResourceLoadStatisticsStore::requestStorageAccess):
(WebKit::WebResourceLoadStatisticsStore::grantStorageAccess):
(WebKit::WebResourceLoadStatisticsStore::callGrantStorageAccessHandler):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:
  • NetworkProcess/NetworkCORSPreflightChecker.h:
  • NetworkProcess/NetworkConnectionToWebProcess.cpp:

(WebKit::NetworkConnectionToWebProcess::cookiesForDOM):
(WebKit::NetworkConnectionToWebProcess::setCookiesFromDOM):
(WebKit::NetworkConnectionToWebProcess::cookieRequestHeaderFieldValue):
(WebKit::NetworkConnectionToWebProcess::getRawCookies):
(WebKit::NetworkConnectionToWebProcess::removeStorageAccessForFrame):
(WebKit::NetworkConnectionToWebProcess::hasStorageAccess):
(WebKit::NetworkConnectionToWebProcess::requestStorageAccess):

  • NetworkProcess/NetworkConnectionToWebProcess.h:
  • NetworkProcess/NetworkConnectionToWebProcess.messages.in:
  • NetworkProcess/NetworkLoadChecker.cpp:

(WebKit::NetworkLoadChecker::NetworkLoadChecker):

  • NetworkProcess/NetworkLoadChecker.h:
  • NetworkProcess/NetworkLoadParameters.h:
  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::start):
(WebKit::NetworkResourceLoader::retrieveCacheEntry):
(WebKit::NetworkResourceLoader::startNetworkLoad):
(WebKit::NetworkResourceLoader::convertToDownload):
(WebKit::NetworkResourceLoader::abort):
(WebKit::NetworkResourceLoader::didReceiveResponse):
(WebKit::NetworkResourceLoader::didReceiveBuffer):
(WebKit::NetworkResourceLoader::didFinishLoading):
(WebKit::NetworkResourceLoader::didFailLoading):
(WebKit::NetworkResourceLoader::continueWillSendRequest):
(WebKit::escapeIDForJSON):
(WebKit::logBlockedCookieInformation):
(WebKit::logCookieInformationInternal):
(WebKit::NetworkResourceLoader::logCookieInformation):

  • NetworkProcess/NetworkResourceLoader.h:
  • NetworkProcess/cache/NetworkCache.h:
  • NetworkProcess/cocoa/NetworkDataTaskCocoa.h:
  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):
(WebKit::NetworkDataTaskCocoa::willPerformHTTPRedirection):

  • Scripts/webkit/messages.py:
  • Shared/API/APIFrameHandle.cpp:

(API::FrameHandle::create):
(API::FrameHandle::createAutoconverting):
(API::FrameHandle::FrameHandle):
(API::FrameHandle::decode):

  • Shared/API/APIFrameHandle.h:

(API::FrameHandle::frameID const):

  • Shared/API/Cocoa/_WKFrameHandle.mm:

(-[_WKFrameHandle hash]):
(-[_WKFrameHandle _frameID]):
(-[_WKFrameHandle initWithCoder:]):
(-[_WKFrameHandle encodeWithCoder:]):

  • Shared/Authentication/AuthenticationManager.cpp:

(WebKit::AuthenticationManager::didReceiveAuthenticationChallenge):

  • Shared/Authentication/AuthenticationManager.h:
  • Shared/FrameInfoData.h:
  • UIProcess/API/C/WKFrameHandleRef.cpp:

(WKFrameHandleGetFrameID):

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _printOperationWithPrintInfo:forFrame:]):
(-[WKWebView _canChangeFrameLayout:]):

  • UIProcess/API/Cocoa/_WKInspector.mm:

(-[_WKInspector showMainResourceForFrame:]):

  • UIProcess/Automation/SimulatedInputDispatcher.cpp:

(WebKit::SimulatedInputDispatcher::run):

  • UIProcess/Automation/SimulatedInputDispatcher.h:
  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::webFrameIDForHandle):
(WebKit::WebAutomationSession::handleForWebFrameID):
(WebKit::WebAutomationSession::switchToBrowsingContext):
(WebKit::WebAutomationSession::waitForNavigationToComplete):
(WebKit::findPageForFrameID):
(WebKit::WebAutomationSession::respondToPendingFrameNavigationCallbacksWithTimeout):
(WebKit::WebAutomationSession::evaluateJavaScriptFunction):
(WebKit::WebAutomationSession::resolveChildFrameHandle):
(WebKit::WebAutomationSession::resolveParentFrameHandle):
(WebKit::WebAutomationSession::computeElementLayout):
(WebKit::WebAutomationSession::selectOptionElement):
(WebKit::WebAutomationSession::getAllCookies):
(WebKit::WebAutomationSession::deleteSingleCookie):
(WebKit::WebAutomationSession::viewportInViewCenterPointOfElement):
(WebKit::WebAutomationSession::takeScreenshot):

  • UIProcess/Automation/WebAutomationSession.h:
  • UIProcess/Cocoa/UIDelegate.mm:

(WebKit::UIDelegate::UIClient::checkUserMediaPermissionForOrigin):

  • UIProcess/Cocoa/WKReloadFrameErrorRecoveryAttempter.mm:

(-[WKReloadFrameErrorRecoveryAttempter attemptRecovery]):

  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::WebPageProxy::contentFilterDidBlockLoadForFrame):
(WebKit::WebPageProxy::contentFilterDidBlockLoadForFrameShared):

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::didReceiveAuthenticationChallenge):
(WebKit::NetworkProcessProxy::requestStorageAccessConfirm):

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

(WebKit::ProvisionalPageProxy::validateInput):
(WebKit::ProvisionalPageProxy::didCreateMainFrame):
(WebKit::ProvisionalPageProxy::didPerformClientRedirect):
(WebKit::ProvisionalPageProxy::didStartProvisionalLoadForFrame):
(WebKit::ProvisionalPageProxy::didFailProvisionalLoadForFrame):
(WebKit::ProvisionalPageProxy::didCommitLoadForFrame):
(WebKit::ProvisionalPageProxy::didNavigateWithNavigationData):
(WebKit::ProvisionalPageProxy::didChangeProvisionalURLForFrame):
(WebKit::ProvisionalPageProxy::decidePolicyForNavigationActionAsync):
(WebKit::ProvisionalPageProxy::decidePolicyForResponse):
(WebKit::ProvisionalPageProxy::didPerformServerRedirect):
(WebKit::ProvisionalPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame):
(WebKit::ProvisionalPageProxy::decidePolicyForNavigationActionSync):
(WebKit::ProvisionalPageProxy::contentFilterDidBlockLoadForFrame):

  • UIProcess/ProvisionalPageProxy.h:
  • UIProcess/ServiceWorkerProcessProxy.cpp:

(WebKit::ServiceWorkerProcessProxy::didReceiveAuthenticationChallenge):

  • UIProcess/ServiceWorkerProcessProxy.h:
  • UIProcess/SuspendedPageProxy.cpp:

(WebKit::SuspendedPageProxy::SuspendedPageProxy):

  • UIProcess/SuspendedPageProxy.h:
  • UIProcess/UserMediaPermissionCheckProxy.cpp:

(WebKit::UserMediaPermissionCheckProxy::UserMediaPermissionCheckProxy):

  • UIProcess/UserMediaPermissionCheckProxy.h:

(WebKit::UserMediaPermissionCheckProxy::create):
(WebKit::UserMediaPermissionCheckProxy::frameID const):

  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::resetAccess):
(WebKit::UserMediaPermissionRequestManagerProxy::searchForGrantedRequest const):
(WebKit::UserMediaPermissionRequestManagerProxy::wasRequestDenied):
(WebKit::UserMediaPermissionRequestManagerProxy::requestUserMediaPermissionForFrame):
(WebKit::UserMediaPermissionRequestManagerProxy::getUserMediaPermissionInfo):
(WebKit::UserMediaPermissionRequestManagerProxy::wasGrantedVideoOrAudioAccess):
(WebKit::UserMediaPermissionRequestManagerProxy::enumerateMediaDevicesForFrame):

  • UIProcess/UserMediaPermissionRequestManagerProxy.h:
  • UIProcess/UserMediaPermissionRequestProxy.cpp:

(WebKit::UserMediaPermissionRequestProxy::UserMediaPermissionRequestProxy):

  • UIProcess/UserMediaPermissionRequestProxy.h:

(WebKit::UserMediaPermissionRequestProxy::create):
(WebKit::UserMediaPermissionRequestProxy::mainFrameID const):
(WebKit::UserMediaPermissionRequestProxy::frameID const):

  • UIProcess/WebFrameProxy.cpp:

(WebKit::WebFrameProxy::WebFrameProxy):

  • UIProcess/WebFrameProxy.h:

(WebKit::WebFrameProxy::create):
(WebKit::WebFrameProxy::frameID const):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::suspendCurrentPageIfPossible):
(WebKit::WebPageProxy::commitProvisionalPage):
(WebKit::WebPageProxy::runJavaScriptInFrame):
(WebKit::WebPageProxy::didCreateMainFrame):
(WebKit::WebPageProxy::didCreateSubframe):
(WebKit::WebPageProxy::didCreateWindow):
(WebKit::WebPageProxy::didStartProvisionalLoadForFrame):
(WebKit::WebPageProxy::didStartProvisionalLoadForFrameShared):
(WebKit::WebPageProxy::didExplicitOpenForFrame):
(WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame):
(WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrameShared):
(WebKit::WebPageProxy::willPerformClientRedirectForFrame):
(WebKit::WebPageProxy::didCancelClientRedirectForFrame):
(WebKit::WebPageProxy::didChangeProvisionalURLForFrame):
(WebKit::WebPageProxy::didChangeProvisionalURLForFrameShared):
(WebKit::WebPageProxy::didFailProvisionalLoadForFrame):
(WebKit::WebPageProxy::didFailProvisionalLoadForFrameShared):
(WebKit::WebPageProxy::didCommitLoadForFrame):
(WebKit::WebPageProxy::didFinishDocumentLoadForFrame):
(WebKit::WebPageProxy::didFinishLoadForFrame):
(WebKit::WebPageProxy::didFailLoadForFrame):
(WebKit::WebPageProxy::didSameDocumentNavigationForFrame):
(WebKit::WebPageProxy::didChangeMainDocument):
(WebKit::WebPageProxy::didReceiveTitleForFrame):
(WebKit::WebPageProxy::didFirstLayoutForFrame):
(WebKit::WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame):
(WebKit::WebPageProxy::didDisplayInsecureContentForFrame):
(WebKit::WebPageProxy::didRunInsecureContentForFrame):
(WebKit::WebPageProxy::didDetectXSSForFrame):
(WebKit::WebPageProxy::frameDidBecomeFrameSet):
(WebKit::WebPageProxy::decidePolicyForNavigationActionAsync):
(WebKit::WebPageProxy::decidePolicyForNavigationActionAsyncShared):
(WebKit::WebPageProxy::decidePolicyForNavigationActionSync):
(WebKit::WebPageProxy::decidePolicyForNavigationActionSyncShared):
(WebKit::WebPageProxy::decidePolicyForNewWindowAction):
(WebKit::WebPageProxy::decidePolicyForResponse):
(WebKit::WebPageProxy::decidePolicyForResponseShared):
(WebKit::WebPageProxy::unableToImplementPolicy):
(WebKit::WebPageProxy::willSubmitForm):
(WebKit::WebPageProxy::didNavigateWithNavigationData):
(WebKit::WebPageProxy::didNavigateWithNavigationDataShared):
(WebKit::WebPageProxy::didPerformClientRedirect):
(WebKit::WebPageProxy::didPerformClientRedirectShared):
(WebKit::WebPageProxy::didPerformServerRedirect):
(WebKit::WebPageProxy::didPerformServerRedirectShared):
(WebKit::WebPageProxy::didUpdateHistoryTitle):
(WebKit::WebPageProxy::runJavaScriptAlert):
(WebKit::WebPageProxy::runJavaScriptConfirm):
(WebKit::WebPageProxy::runJavaScriptPrompt):
(WebKit::WebPageProxy::runBeforeUnloadConfirmPanel):
(WebKit::WebPageProxy::runOpenPanel):
(WebKit::WebPageProxy::printFrame):
(WebKit::WebPageProxy::focusedFrameChanged):
(WebKit::WebPageProxy::frameSetLargestFrameChanged):
(WebKit::WebPageProxy::didReceiveAuthenticationChallengeProxy):
(WebKit::WebPageProxy::exceededDatabaseQuota):
(WebKit::WebPageProxy::requestStorageSpace):
(WebKit::WebPageProxy::makeStorageSpaceRequest):
(WebKit::WebPageProxy::requestGeolocationPermissionForFrame):
(WebKit::WebPageProxy::requestUserMediaPermissionForFrame):
(WebKit::WebPageProxy::enumerateMediaDevicesForFrame):
(WebKit::WebPageProxy::shouldAllowDeviceOrientationAndMotionAccess):
(WebKit::WebPageProxy::requestStorageAccessConfirm):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebPageProxy.messages.in:
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::webFrame const):
(WebKit::WebProcessProxy::canCreateFrame const):
(WebKit::WebProcessProxy::frameCreated):
(WebKit::WebProcessProxy::didDestroyFrame):

  • UIProcess/WebProcessProxy.h:
  • UIProcess/WebProcessProxy.messages.in:
  • UIProcess/ios/WKContentView.mm:

(-[WKContentView _wk_pageCountForPrintFormatter:]):

  • UIProcess/ios/WebPageProxyIOS.mm:

(WebKit::WebPageProxy::computePagesForPrintingAndDrawToPDF):

  • WebProcess/Automation/WebAutomationSessionProxy.cpp:

(WebKit::evaluateJavaScriptCallback):
(WebKit::WebAutomationSessionProxy::didClearWindowObjectForFrame):
(WebKit::WebAutomationSessionProxy::evaluateJavaScriptFunction):
(WebKit::WebAutomationSessionProxy::didEvaluateJavaScriptFunction):
(WebKit::WebAutomationSessionProxy::resolveChildFrameWithOrdinal):
(WebKit::WebAutomationSessionProxy::resolveChildFrameWithNodeHandle):
(WebKit::WebAutomationSessionProxy::resolveChildFrameWithName):
(WebKit::WebAutomationSessionProxy::resolveParentFrame):
(WebKit::WebAutomationSessionProxy::focusFrame):
(WebKit::WebAutomationSessionProxy::computeElementLayout):
(WebKit::WebAutomationSessionProxy::selectOptionElement):
(WebKit::WebAutomationSessionProxy::takeScreenshot):
(WebKit::WebAutomationSessionProxy::getCookiesForFrame):
(WebKit::WebAutomationSessionProxy::deleteCookie):

  • WebProcess/Automation/WebAutomationSessionProxy.h:
  • WebProcess/Automation/WebAutomationSessionProxy.messages.in:
  • WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm:

(+[WKWebProcessPlugInFrame lookUpFrameFromHandle:]):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoad):
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
(WebKit::WebLoaderStrategy::loadResourceSynchronously):

  • WebProcess/Network/WebResourceLoader.cpp:

(WebKit::WebResourceLoader::willSendRequest):
(WebKit::WebResourceLoader::didReceiveResponse):
(WebKit::WebResourceLoader::didReceiveData):
(WebKit::WebResourceLoader::didFinishResourceLoad):
(WebKit::WebResourceLoader::didFailResourceLoad):
(WebKit::WebResourceLoader::didBlockAuthenticationChallenge):
(WebKit::WebResourceLoader::stopLoadingAfterXFrameOptionsOrContentSecurityPolicyDenied):
(WebKit::WebResourceLoader::didReceiveResource):

  • WebProcess/Network/WebResourceLoader.h:
  • WebProcess/Storage/WebSWContextManagerConnection.cpp:

(WebKit::WebSWContextManagerConnection::installServiceWorker):

  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::focusedFrameChanged):
(WebKit::WebChromeClient::contentsSizeChanged const):
(WebKit::WebChromeClient::hasStorageAccess):
(WebKit::WebChromeClient::requestStorageAccess):

  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::frameID const):
(WebKit::WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDidFailLoad):

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
  • WebProcess/WebPage/WebCookieJar.cpp:

(WebKit::WebCookieJar::cookies const):
(WebKit::WebCookieJar::setCookies):
(WebKit::WebCookieJar::cookieRequestHeaderFieldValue const):
(WebKit::WebCookieJar::getRawCookies const):

  • WebProcess/WebPage/WebCookieJar.h:
  • WebProcess/WebPage/WebFrame.cpp:

(WebKit::WebFrame::WebFrame):
(WebKit::generateFrameID): Deleted.

  • WebProcess/WebPage/WebFrame.h:

(WebKit::WebFrame::frameID const):

  • WebProcess/WebPage/WebInspector.cpp:

(WebKit::WebInspector::showMainResourceForFrame):

  • WebProcess/WebPage/WebInspector.h:
  • WebProcess/WebPage/WebInspector.messages.in:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::loadURLInFrame):
(WebKit::WebPage::loadDataInFrame):
(WebKit::WebPage::stopLoadingFrame):
(WebKit::WebPage::didReceivePolicyDecision):
(WebKit::WebPage::continueWillSubmitForm):
(WebKit::WebPage::runJavaScriptInFrame):
(WebKit::WebPage::getSourceForFrame):
(WebKit::WebPage::getMainResourceDataOfFrame):
(WebKit::WebPage::getResourceDataFromFrame):
(WebKit::WebPage::getWebArchiveOfFrame):
(WebKit::WebPage::addConsoleMessage):
(WebKit::WebPage::sendCSPViolationReport):
(WebKit::WebPage::enqueueSecurityPolicyViolationEvent):
(WebKit::WebPage::beginPrinting):
(WebKit::WebPage::computePagesForPrinting):
(WebKit::WebPage::computePagesForPrintingImpl):
(WebKit::WebPage::drawRectToImage):
(WebKit::WebPage::drawPagesToPDF):
(WebKit::WebPage::drawPagesToPDFImpl):
(WebKit::WebPage::drawPagesForPrinting):
(WebKit::WebPage::frameBecameRemote):
(WebKit::WebPage::hasStorageAccess):
(WebKit::WebPage::requestStorageAccess):
(WebKit::WebPage::shouldAllowDeviceOrientationAndMotionAccess):

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/WebPage.messages.in:
  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::computePagesForPrintingPDFDocument):
(WebKit::WebPage::computePagesForPrintingAndDrawToPDF):

  • WebProcess/WebPage/mac/WebPageMac.mm:

(WebKit::WebPage::computePagesForPrintingPDFDocument):

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::webFrame const):
(WebKit::WebProcess::addWebFrame):
(WebKit::WebProcess::removeWebFrame):

  • WebProcess/WebProcess.h:

Source/WebKitLegacy/mac:

  • WebCoreSupport/WebFrameLoaderClient.h:
  • WebCoreSupport/WebFrameLoaderClient.mm:

(WebFrameLoaderClient::frameID const):

6:38 AM Changeset in webkit [248712] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[GStreamer][WebRTC]: openh264 encoder bitrate is in bits per second
https://bugs.webkit.org/show_bug.cgi?id=200578

Patch by Thibault Saunier <tsaunier@igalia.com> on 2019-08-15
Reviewed by Philippe Normand.

Not really testable as is.

  • platform/mediastream/libwebrtc/GStreamerVideoEncoder.cpp:

(gst_webrtc_video_encoder_class_init):

1:40 AM Changeset in webkit [248711] by Joseph Pecoraro
  • 2 edits in trunk/Source/JavaScriptCore

for-await-of has bad error message if used in non-async function
https://bugs.webkit.org/show_bug.cgi?id=200758

Reviewed by Ross Kirsling.

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseForStatement):
Improve error message.

Aug 14, 2019:

11:39 PM Changeset in webkit [248710] by ysuzuki@apple.com
  • 7 edits in trunk/Source/JavaScriptCore

[JSC] Air does not appropriately propagate ConstFloatValue to stackmap
https://bugs.webkit.org/show_bug.cgi?id=200759

Reviewed by Saam Barati.

In B3MoveConstant phase, we convert ConstFloatValue and ConstDoubleValue to memory access to the table
to avoid large immediates *except for* stackmap argument case. This is because materializing constant doubles
and floats as memory-access before passing it to stackmap is wasteful: the stackmap may not use it actually, or
stackmap can do better job if it knows the parameter is constant.

Based on the above operation, B3LowerToAir phase strongly assumes that all ConstFloatValue and ConstDoubleValue
are removed except for the case used for parameter of stackmap. With r192377, B3LowerToAir catch this case, and
propagate constant double value as ValueRep in stackmap. While B3LowerToAir does this correctly for ConstDoubleValue,
we missed adding this support for ConstFloatValue.

This patch adds r192377's support for ConstFloatValue to propagate ConstFloatValue correctly to the stackmap.
This issue starts appearing since Wasm BBQ-B3 OSR starts putting ConstFloatValue to OSR-tier-up patchpoint.

  • b3/B3LowerToAir.cpp:
  • b3/B3ValueKey.h:

(JSC::B3::ValueKey::ValueKey):
(JSC::B3::ValueKey::floatValue const):

  • b3/B3ValueRep.h:

(JSC::B3::ValueRep::constantFloat):
(JSC::B3::ValueRep::floatValue const):

  • b3/testb3.h:
  • b3/testb3_1.cpp:

(run):

  • b3/testb3_5.cpp:

(testPatchpointManyWarmAnyImms):
(testPatchpointManyColdAnyImms):
(testPatchpointManyImms): Deleted.

11:20 PM Changeset in webkit [248709] by mark.lam@apple.com
  • 4 edits
    1 add in trunk

JSTests:
ProxyObject should not be allow to access its target's private properties.
https://bugs.webkit.org/show_bug.cgi?id=200739
<rdar://problem/53972768>

Reviewed by Yusuke Suzuki.

  • stress/proxy-should-not-be-allowed-to-access-private-properties-of-target.js: Added.
  • stress/proxy-with-private-symbols.js: Rebased.

Source/JavaScriptCore:
Remove support for macOS < 10.13
https://bugs.webkit.org/show_bug.cgi?id=200694
<rdar://problem/54278851>

Patch by Keith Rollin <Keith Rollin> on 2019-08-14
Reviewed by Youenn Fablet.

Update conditionals that reference MAC_OS_X_VERSION_MIN_REQUIRED and
MAC_OS_X_VERSION_MAX_ALLOWED, assuming that they both have values >=

  1. This means that expressions like

"MAC_OS_X_VERSION_MIN_REQUIRED < 101300" are always False and
"
MAC_OS_X_VERSION_MIN_REQUIRED >= 101300" are always True.

  • API/WebKitAvailability.h:
11:11 PM Changeset in webkit [248708] by commit-queue@webkit.org
  • 4 edits in trunk

Error thrown during "acceptNode" lookup is overridden
https://bugs.webkit.org/show_bug.cgi?id=200735

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-08-14
Reviewed by Ross Kirsling.

LayoutTests/imported/w3c:

  • web-platform-tests/dom/traversal/TreeWalker-acceptNode-filter-expected.txt:

Source/WebCore:

Test: imported/w3c/web-platform-tests/dom/traversal/TreeWalker-acceptNode-filter-expected.html

  • bindings/js/JSCallbackData.cpp:

(WebCore::JSCallbackData::invokeCallback): Catch and return exception of callback->get call.

9:55 PM Changeset in webkit [248707] by Alan Coon
  • 1 copy in tags/Safari-609.1.2

Tag Safari-609.1.2.

8:36 PM Changeset in webkit [248706] by mmaxfield@apple.com
  • 3 edits
    2 adds in trunk

[WHLSL] Variables shouldn't be able to have void type
https://bugs.webkit.org/show_bug.cgi?id=200751

Reviewed by Robin Morisset.

Source/WebCore:

Trivial fix. Found by https://github.com/gpuweb/WHLSL/issues/320.

Test: webgpu/whlsl/void-variable-parameter.html

  • Modules/webgpu/WHLSL/WHLSLChecker.cpp:

(WebCore::WHLSL::Checker::visit):

LayoutTests:

  • webgpu/whlsl/void-variable-parameter-expected.txt: Added.
  • webgpu/whlsl/void-variable-parameter.html: Added.
7:36 PM Changeset in webkit [248705] by commit-queue@webkit.org
  • 14 edits
    1 move
    2 adds in trunk/LayoutTests/imported/w3c

Re-sync web-platform-tests/dom/traversal from upstream
https://bugs.webkit.org/show_bug.cgi?id=200737

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-08-14
Reviewed by Ryosuke Niwa.

Re-sync web-platform-tests/dom/traversal from upstream 91adbef87678.

  • resources/import-expectations.json:
  • web-platform-tests/dom/traversal/*: Updated.
7:34 PM Changeset in webkit [248704] by Justin Fan
  • 3 edits in trunk/Source/WebCore

[WebGPU] Use of WebGPU should not force discrete GPU
https://bugs.webkit.org/show_bug.cgi?id=200740

Reviewed by Myles C. Maxfield.

Request a low-power device from Metal by default.

No change in testable behavior.

  • platform/graphics/gpu/GPURequestAdapterOptions.h:
  • platform/graphics/gpu/cocoa/GPUDeviceMetal.mm:

(WebCore::GPUDevice::tryCreate):

7:20 PM Changeset in webkit [248703] by Chris Dumez
  • 3 edits in trunk/Source/WebCore

Potentially non thread-safe usage of WebCore::MediaSample
https://bugs.webkit.org/show_bug.cgi?id=200734

Reviewed by Eric Carlson.

ImageSource is a main thread object but ends up getting passed to a background queue for image
decoding. In some cases, the background queue ends up being the last one holding a ref to the
ImageSource which ends up destroying the ImageSource on a background thread. Doing so is not
safe as shown by the crash.

To address the issue, have ImageSource subclass ThreadSafeRefCounted<ImageSource, WTF::DestructionThread::Main>
so that it is always destroyed on the main thread.

No new tests, currently crashing on the debug bots.

  • platform/graphics/ImageSource.cpp:

(WebCore::ImageSource::ImageSource):
(WebCore::ImageSource::~ImageSource):

  • platform/graphics/ImageSource.h:
6:58 PM Changeset in webkit [248702] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

FileSystem::deleteFile should log error status (178347)
https://bugs.webkit.org/show_bug.cgi?id=178347

Patch by Kate Cheney <Kate Cheney> on 2019-08-14
Reviewed by Brent Fulgham.

I added logging to the FileSystem::deleteFile function so that the debugger will
be able to see the associated errno string and better understand the reason for an
unlink failure or will know if the fileSystemRepresentation call was not
successful (or returned null).

  • wtf/posix/FileSystemPOSIX.cpp:

(WTF::FileSystemImpl::deleteFile):

6:17 PM Changeset in webkit [248701] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

[iOS](REGRESSION: r200487): WebKit.RequestActivatedElementInfoForRotatedImage fails on iOS 13
https://bugs.webkit.org/show_bug.cgi?id=200726

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-14
Reviewed by Simon Fraser.

To get the pixels as an array of colors, draw the image into a memory
context. The backing memory buffer can then be accessed to get the image
pixels' colors.

  • TestWebKitAPI/Tests/WebKitCocoa/WKRequestActivatedElementInfo.mm:

(TestWebKitAPI::TEST):

5:54 PM Changeset in webkit [248700] by Wenson Hsieh
  • 3 edits in trunk/Source/WebKit

Remove m_blockRectForTextSelection (along with related code)
https://bugs.webkit.org/show_bug.cgi?id=200695

Reviewed by Megan Gardner.

This member variable was consulted by block selection codepaths which no longer exist.
No change in behavior.

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::selectTextWithGranularityAtPoint):
(WebKit::selectionBoxForRange): Deleted.

5:30 PM Changeset in webkit [248699] by Ryan Haddad
  • 39 edits in trunk

Unreviewed, rolling out r248526.

Caused two IndexedDB perf tests to fail

Reverted changeset:

"Remove IDB-specific quota"
https://bugs.webkit.org/show_bug.cgi?id=196545
https://trac.webkit.org/changeset/248526

5:18 PM Changeset in webkit [248698] by aestes@apple.com
  • 2 edits in trunk/Source/WebKit

Fix the build when ENABLE(APPLE_PAY) is false.

  • Shared/Cocoa/WebCoreArgumentCodersCocoa.mm:
5:17 PM Changeset in webkit [248697] by Keith Rollin
  • 76 edits in trunk

Remove support for macOS < 10.13
https://bugs.webkit.org/show_bug.cgi?id=200694
<rdar://problem/54278851>

Reviewed by Youenn Fablet.

Update conditionals that reference MAC_OS_X_VERSION_MIN_REQUIRED and
MAC_OS_X_VERSION_MAX_ALLOWED, assuming that they both have values >=

  1. This means that expressions like

"MAC_OS_X_VERSION_MIN_REQUIRED < 101300" are always False and
"
MAC_OS_X_VERSION_MIN_REQUIRED >= 101300" are always True.

PerformanceTests:

  • StitchMarker/wtf/Platform.h:
  • StitchMarker/wtf/dependencies/bmalloc/BPlatform.h:
  • StitchMarker/wtf/text/icu/TextBreakIteratorICU.h:

(WTF::TextBreakIteratorICU::TextBreakIteratorICU):
(WTF::caretRules): Deleted.

Source/JavaScriptCore:

  • API/WebKitAvailability.h:

Source/ThirdParty/libwebrtc:

  • Source/webrtc/sdk/WebKit/VideoProcessingSoftLink.h:
  • WebKit/libwebrtc.diff:

Source/WebCore:

No new tests -- no added or changed functionality.

  • Modules/applepay/cocoa/PaymentContactCocoa.mm:

(WebCore::subLocality):
(WebCore::setSubLocality):
(WebCore::subAdministrativeArea):
(WebCore::setSubAdministrativeArea):

  • WebCorePrefix.h:
  • crypto/mac/CryptoKeyRSAMac.cpp:
  • editing/cocoa/WebContentReaderCocoa.mm:
  • page/mac/TextIndicatorWindow.mm:

(-[WebTextIndicatorView initWithFrame:textIndicator:margin:offset:]):

  • platform/PlatformScreen.h:
  • platform/cocoa/NetworkExtensionContentFilter.mm:

(WebCore::NetworkExtensionContentFilter::initialize):

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::seekableTimeRangesLastModifiedTime const):
(WebCore::MediaPlayerPrivateAVFoundationObjC::liveUpdateInterval const):

  • platform/graphics/cocoa/FontCacheCoreText.cpp:

(WebCore::FontDatabase::fontForPostScriptName):
(WebCore::variationCapabilitiesForFontDescriptor):
(WebCore::FontCache::lastResortFallbackFont):

  • platform/graphics/cocoa/FontPlatformDataCocoa.mm:

(WebCore::cascadeToLastResortAndVariationsFontDescriptor):

  • platform/graphics/cocoa/GraphicsContext3DCocoa.mm:

(WebCore::setGPUByRegistryID):
(WebCore::GraphicsContext3D::GraphicsContext3D):
(WebCore::GraphicsContext3D::screenDidChange):
(WebCore::setGPUByDisplayMask): Deleted.

  • platform/graphics/cv/VideoTextureCopierCV.cpp:
  • platform/graphics/gpu/cocoa/GPUDeviceMetal.mm:

(WebCore::isAcceptableDevice):

  • platform/graphics/mac/FontCacheMac.mm:

(WebCore::platformFontWithFamilySpecialCase):

  • platform/graphics/mac/FontCustomPlatformData.cpp:

(WebCore::createFontCustomPlatformData):

  • platform/mac/DragImageMac.mm:

(WebCore::LinkImageLayout::LinkImageLayout):
(WebCore::createDragImageForLink):

  • platform/mac/PlatformScreenMac.mm:

(WebCore::collectScreenProperties):
(WebCore::gpuIDForDisplayMask):

  • platform/mac/WebPlaybackControlsManager.h:
  • platform/mac/WebPlaybackControlsManager.mm:

(toAVTouchBarMediaSelectionOptionType):
(mediaSelectionOptions):
(-[WebPlaybackControlsManager generateFunctionBarThumbnailsForTimes:size:completionHandler:]): Deleted.
(-[WebPlaybackControlsManager generateFunctionBarAudioAmplitudeSamples:completionHandler:]): Deleted.
(-[WebPlaybackControlsManager canBeginFunctionBarScrubbing]): Deleted.
(-[WebPlaybackControlsManager beginFunctionBarScrubbing]): Deleted.
(-[WebPlaybackControlsManager endFunctionBarScrubbing]): Deleted.

  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::platformActiveTextSearchHighlightColor const):
(WebCore::RenderThemeMac::systemColor const):

Source/WebCore/PAL:

  • pal/spi/cf/CFNetworkSPI.h:
  • pal/spi/cocoa/AVKitSPI.h:
  • pal/spi/cocoa/CommonCryptoSPI.h:
  • pal/spi/cocoa/IOSurfaceSPI.h:
  • pal/spi/cocoa/NEFilterSourceSPI.h:
  • pal/spi/cocoa/NSAttributedStringSPI.h:
  • pal/spi/cocoa/NSKeyedArchiverSPI.h:
  • pal/spi/cocoa/NSTouchBarSPI.h:
  • pal/spi/cocoa/PassKitSPI.h:
  • pal/spi/mac/AVFoundationSPI.h:

Source/WebKit:

  • NetworkProcess/Downloads/cocoa/WKDownloadProgress.mm:

(-[WKDownloadProgress initWithDownloadTask:download:URL:sandboxExtension:]):

  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(-[WKNetworkSessionDelegate URLSession:task:didFinishCollectingMetrics:]):

  • Shared/WebPreferencesDefaultValues.cpp:

(WebKit::defaultCustomPasteboardDataEnabled):

  • Shared/WebPreferencesDefaultValues.h:
  • Shared/mac/AuxiliaryProcessMac.mm:
  • UIProcess/Cocoa/WebViewImpl.h:
  • UIProcess/Cocoa/WebViewImpl.mm:

(-[WKTextTouchBarItemController itemForIdentifier:]):
(WebKit::WebViewImpl::mediaPlaybackControlsView const):
(WebKit::WebViewImpl::updateMediaTouchBar):

  • UIProcess/mac/WebColorPickerMac.mm:
  • WebProcess/Plugins/PDF/PDFLayerControllerSPI.h:
  • WebProcess/Plugins/PDF/PDFPlugin.h:
  • WebProcess/Plugins/PDF/PDFPlugin.mm:

(-[WKPDFPluginAccessibilityObject setPdfLayerController:]):
(-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:]):
(-[WKPDFPluginAccessibilityObject ALLOW_DEPRECATED_IMPLEMENTATIONS_END]):
(-[WKPDFPluginAccessibilityObject accessibilityFocusedUIElement]):
(-[WKPDFPluginAccessibilityObject accessibilityAssociatedControlForAnnotation:]):
(-[WKPDFPluginAccessibilityObject accessibilityHitTest:]):
(WebKit::PDFPlugin::pdfDocumentDidLoad):
(WebKit::PDFPlugin::handleMouseEvent):
(WebKit::PDFPlugin::handleMouseEnterEvent):
(WebKit::PDFPlugin::handleContextMenuEvent):
(WebKit::PDFPlugin::pluginHandlesContentOffsetForAccessibilityHitTest const):
(WebKit::PDFPlugin::accessibilityAssociatedPluginParentForElement const):
(WebKit::PDFPlugin::updateCursor): Deleted.

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::initializeWebProcess):

Source/WebKitLegacy/mac:

  • WebCoreSupport/WebEditorClient.mm:
  • WebView/PDFViewSPI.h:
  • WebView/WebHTMLView.mm:

(-[WebHTMLView _recursive:displayRectIgnoringOpacity:inContext:stopAtLayerBackedViews:_recursive:displayRectIgnoringOpacity:inContext:shouldChangeFontReferenceColor:stopAtLayerBackedViews:_recursive:displayRectIgnoringOpacity:inContext:shouldChangeFontReferenceColor:]):
(-[WebHTMLView _recursive:displayRectIgnoringOpacity:inGraphicsContext:shouldChangeFontReferenceColor:]):
(-[WebHTMLView _recursive:displayRectIgnoringOpacity:inContext:stopAtLayerBackedViews:_recursive:displayRectIgnoringOpacity:inContext:shouldChangeFontReferenceColor:stopAtLayerBackedViews:_recursive:displayRectIgnoringOpacity:inContext:shouldChangeFontReferenceColor:_recursive:displayRectIgnoringOpacity:inContext:topView:]): Deleted.
(-[WebHTMLView _recursive:displayRectIgnoringOpacity:inGraphicsContext:shouldChangeFontReferenceColor:_recursive:displayRectIgnoringOpacity:inGraphicsContext:CGContext:topView:shouldChangeFontReferenceColor:]): Deleted.

  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):

  • WebView/WebView.mm:

(-[WebView performDragOperation:]):
(LayerFlushController::flushLayers):
(-[WebView updateMediaTouchBar]):

  • WebView/WebViewData.h:

Source/WTF:

  • wtf/FeatureDefines.h:
  • wtf/Platform.h:
  • wtf/mac/AppKitCompatibilityDeclarations.h:
  • wtf/spi/darwin/SandboxSPI.h:

Tools:

  • MiniBrowser/AppKitCompatibilityDeclarations.h:
  • MiniBrowser/mac/SettingsController.m:

(-[SettingsController init]):

  • TestWebKitAPI/Tests/WebCore/FontCache.cpp:

(TestWebKitAPI::FontCacheTest::SetUp): Deleted.
(TestWebKitAPI::createPlatformFont): Deleted.
(TestWebKitAPI::compareFonts): Deleted.
(TestWebKitAPI::TEST_F): Deleted.

  • TestWebKitAPI/Tests/WebCore/cocoa/AVFoundationSoftLinkTest.mm:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/ExitFullscreenOnEnterPiP.mm:
  • TestWebKitAPI/Tests/WebKitCocoa/PictureInPictureDelegate.mm:
  • TestWebKitAPI/Tests/WebKitCocoa/WKAttachmentTests.mm:
  • TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:

(runWebsiteDataStoreCustomPaths):

  • TestWebKitAPI/mac/NSFontPanelTesting.mm:
4:57 PM Changeset in webkit [248696] by BJ Burg
  • 4 edits in trunk/Source/WebKit

REGRESSION(r245320): Web Automation: Perform Actions hangs when pointerdown happens near top of page
https://bugs.webkit.org/show_bug.cgi?id=200728
<rdar://problem/54260518>

Reviewed by Devin Rousso.

In the last major refactoring for this code, it seems that the argument to
platformSimulateMouseInteraction was not unified to use viewport coordinates
in all code paths. This patch fixes both callers to *not* add in topContentInset,
and instead this is added back in when doing platform-specific event simulation.

This has no effect on iOS since it's guarded by ENABLE(WEBDRIVER_MOUSE_INTERACTIONS),
which is only built on macOS.

  • UIProcess/Automation/WebAutomationSession.h:
  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::performMouseInteraction):

  • UIProcess/Automation/mac/WebAutomationSessionMac.mm:

(WebKit::WebAutomationSession::platformSimulateMouseInteraction):

4:53 PM Changeset in webkit [248695] by Alan Bujtas
  • 6 edits
    2 adds in trunk

[ContentChangeObserver] Any previously destroyed renderer should not be considered a candidate for content observation.
https://bugs.webkit.org/show_bug.cgi?id=200732
<rdar://problem/54319654>

Reviewed by Simon Fraser.

Source/WebCore:

A visible element should not be considered a candidate to content change observation when it loses the visiblity status momentarily.
This patch extends the check of re-constructed renderers for the duration of the content change observation (as opposed to just a single render tree update cycle)

Test: fast/events/touch/ios/content-observation/visible-content-gains-new-renderer2.html

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::reset):
(WebCore::ContentChangeObserver::rendererWillBeDestroyed):
(WebCore::ContentChangeObserver::adjustObservedState):
(WebCore::ContentChangeObserver::renderTreeUpdateDidStart): Deleted.
(WebCore::ContentChangeObserver::renderTreeUpdateDidFinish): Deleted.
(WebCore::ContentChangeObserver::stopContentObservation): Deleted.
(WebCore::ContentChangeObserver::willDestroyRenderer): Deleted.
(WebCore::ContentChangeObserver::RenderTreeUpdateScope::RenderTreeUpdateScope): Deleted.
(WebCore::ContentChangeObserver::RenderTreeUpdateScope::~RenderTreeUpdateScope): Deleted.

  • page/ios/ContentChangeObserver.h:

(WebCore::ContentChangeObserver::isObservingContentChanges const):

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::willBeDestroyed):

  • rendering/updating/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::updateRenderTree):
(WebCore::RenderTreeUpdater::tearDownRenderers):

LayoutTests:

  • fast/events/touch/ios/content-observation/visible-content-gains-new-renderer2-expected.txt: Added.
  • fast/events/touch/ios/content-observation/visible-content-gains-new-renderer2.html: Added.
4:36 PM Changeset in webkit [248694] by mark.lam@apple.com
  • 3 edits
    1 add in trunk

Missing exception check in string compare.
https://bugs.webkit.org/show_bug.cgi?id=200743
<rdar://problem/53975356>

Reviewed by Michael Saboff.

JSTests:

  • stress/missing-exception-check-in-string-compare.js: Added.

Source/JavaScriptCore:

  • runtime/JSString.cpp:

(JSC::JSString::equalSlowCase const):

4:33 PM Changeset in webkit [248693] by Ryan Haddad
  • 3 edits in trunk/LayoutTests

Unreviewed, rolling out r248638.

These test expectations aren't necessary

Reverted changeset:

"Unreviewed test gardening, land test expectations for
rdar://49790831."
https://trac.webkit.org/changeset/248638

3:55 PM Changeset in webkit [248692] by aestes@apple.com
  • 13 edits in trunk/Source

[Cocoa] Add some WKA extension points
https://bugs.webkit.org/show_bug.cgi?id=200506
<rdar://problem/51682474>

Reviewed by Tim Horton.

Source/WebCore:

  • Modules/applepay/ApplePayPayment.h:
  • Modules/applepay/ApplePayPaymentMethod.h:
  • Modules/applepay/ApplePayRequestBase.cpp:

(WebCore::finishConverting):
(WebCore::convertAndValidate):

  • Modules/applepay/ApplePayRequestBase.h:
  • Modules/applepay/ApplePaySessionPaymentRequest.h:
  • Modules/applepay/PaymentCoordinatorClient.cpp:

(WebCore::PaymentCoordinatorClient::supportsVersion):

  • Modules/applepay/cocoa/PaymentCocoa.mm:

(WebCore::convert):

  • Modules/applepay/cocoa/PaymentMethodCocoa.mm:

(WebCore::finishConverting):
(WebCore::convert):

Source/WebKit:

  • Shared/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm:

(WebKit::finishCreating):
(WebKit::WebPaymentCoordinatorProxy::platformPaymentRequest):

  • Shared/Cocoa/WebCoreArgumentCodersCocoa.mm:

(IPC::finishDecoding):
(IPC::finishEncoding):
(IPC::ArgumentCoder<ApplePaySessionPaymentRequest>::encode):
(IPC::ArgumentCoder<ApplePaySessionPaymentRequest>::decode):

  • Shared/WebCoreArgumentCoders.h:
3:38 PM Changeset in webkit [248691] by Alan Coon
  • 1 copy in tags/Safari-608.2.5

Tag Safari-608.2.5.

3:13 PM Changeset in webkit [248690] by dino@apple.com
  • 2 edits in trunk/Source/WebKit

v3: CrashTracer: Regression : MobileSafari at UIKitCore: -[UITargetedPreview initWithView:parameters:]
https://bugs.webkit.org/show_bug.cgi?id=200634

Patch by Luming Yin <luming_yin@apple.com> on 2019-08-14
Reviewed by Simon Fraser.

Under rare race conditions, the WKContentView may no longer have an associated window. However,
UIContextMenuInteraction may still attempt initialize a UITargetedPreview with the orphaned
WKContentView. Speculative fix for crashes under such scenarios, so that we can continue without
a context menu configuration to prevent the UIKit exception.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView continueContextMenuInteraction:]):

3:08 PM Changeset in webkit [248689] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, build fix for MacroAssemblerARM64E change
https://bugs.webkit.org/show_bug.cgi?id=200703

  • assembler/MacroAssemblerARM64E.h:

(JSC::MacroAssemblerARM64E::farJump):

2:59 PM Changeset in webkit [248688] by Devin Rousso
  • 5 edits in trunk

Web Inspector: support console.screenshot with dataURL strings
https://bugs.webkit.org/show_bug.cgi?id=199307

Reviewed by Joseph Pecoraro.

Source/WebCore:

Test: inspector/console/console-screenshot.html

  • page/PageConsoleClient.cpp:

(WebCore::PageConsoleClient::screenshot):

LayoutTests:

  • inspector/console/console-screenshot.html:
  • inspector/console/console-screenshot-expected.txt:
1:33 PM Changeset in webkit [248687] by ysuzuki@apple.com
  • 7 edits in trunk

[JSC] Less contended MetaAllocator
https://bugs.webkit.org/show_bug.cgi?id=200278

Reviewed by Mark Lam.

Source/JavaScriptCore:

The profiler result of JetStream2/bomb-workers shows that we are having contention under MetaAllocator::currentStatistics.
This function is called in ExecutableAllocator::memoryPressureMultiplier, and it is called from ExecutableCounter's threshold
calculation. But MetaAllocator::currentStatistics takes a global lock inside MetaAllocator and causes contention. However,
we do not need to have a lock actually: clients of MetaAllocator::currentStatistics typically use bytesReserved and bytesAllocated
information. However, since our executable allocator is fixed-sized, bytesReserved is always the fixed size. So just reading bytesAllocated
racily is enough.

This patch attempts to reduce the contention by the following two things.

  1. Read bytesAllocated racily instead of calling MetaAllocator::currentStatistics. Then ExecutableCounter does not need to take a lock.
  2. page lifetime management APIs of MetaAllocator should take a second count parameter to batch the system calls.
  • jit/ExecutableAllocator.cpp:

(JSC::ExecutableAllocator::underMemoryPressure):
(JSC::ExecutableAllocator::memoryPressureMultiplier):
(JSC::ExecutableAllocator::allocate):
(JSC::FixedVMPoolExecutableAllocator::FixedVMPoolExecutableAllocator): Deleted.
(JSC::FixedVMPoolExecutableAllocator::memoryStart): Deleted.
(JSC::FixedVMPoolExecutableAllocator::memoryEnd): Deleted.
(JSC::FixedVMPoolExecutableAllocator::isJITPC): Deleted.
(JSC::FixedVMPoolExecutableAllocator::initializeSeparatedWXHeaps): Deleted.
(JSC::FixedVMPoolExecutableAllocator::jitWriteThunkGenerator): Deleted.
(JSC::FixedVMPoolExecutableAllocator::genericWriteToJITRegion): Deleted.

Source/WTF:

  • wtf/MetaAllocator.cpp:

(WTF::MetaAllocator::incrementPageOccupancy):
(WTF::MetaAllocator::decrementPageOccupancy):

  • wtf/MetaAllocator.h:

Tools:

Update the interface.

  • TestWebKitAPI/Tests/WTF/MetaAllocator.cpp:
1:15 PM Changeset in webkit [248686] by ysuzuki@apple.com
  • 26 edits in trunk/Source/JavaScriptCore

[JSC] Make PAC jump and return more explicit
https://bugs.webkit.org/show_bug.cgi?id=200703

Reviewed by Mark Lam.

This patch refactors our macro assembler, mainly related to PAC.

  1. Make far-jump explicit by renaming jump to farJump.
  2. Remove unused makeTailRecursiveCall and tailRecursiveCall.
  3. Do not make ARM64EAssembler::ret as retab. MacroAssemblerARM64E should call retab explicitly instead.
  • assembler/ARM64EAssembler.h:

(JSC::ARM64EAssembler::ret): Deleted.

  • assembler/MacroAssembler.h:
  • assembler/MacroAssemblerARM64.h:

(JSC::MacroAssemblerARM64::farJump):
(JSC::MacroAssemblerARM64::makeTailRecursiveCall): Deleted.
(JSC::MacroAssemblerARM64::tailRecursiveCall): Deleted.

  • assembler/MacroAssemblerARM64E.h:

(JSC::MacroAssemblerARM64E::farJump):
(JSC::MacroAssemblerARM64E::ret):

  • assembler/MacroAssemblerARMv7.h:

(JSC::MacroAssemblerARMv7::farJump):
(JSC::MacroAssemblerARMv7::relativeTableJump):
(JSC::MacroAssemblerARMv7::tailRecursiveCall): Deleted.
(JSC::MacroAssemblerARMv7::makeTailRecursiveCall): Deleted.

  • assembler/MacroAssemblerMIPS.h:

(JSC::MacroAssemblerMIPS::farJump):
(JSC::MacroAssemblerMIPS::tailRecursiveCall): Deleted.
(JSC::MacroAssemblerMIPS::makeTailRecursiveCall): Deleted.

  • assembler/MacroAssemblerX86.h:

(JSC::MacroAssemblerX86::farJump):
(JSC::MacroAssemblerX86::jump): Deleted.
(JSC::MacroAssemblerX86::tailRecursiveCall): Deleted.
(JSC::MacroAssemblerX86::makeTailRecursiveCall): Deleted.

  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::farJump):

  • assembler/MacroAssemblerX86_64.h:

(JSC::MacroAssemblerX86_64::farJump):
(JSC::MacroAssemblerX86_64::jump): Deleted.
(JSC::MacroAssemblerX86_64::tailRecursiveCall): Deleted.
(JSC::MacroAssemblerX86_64::makeTailRecursiveCall): Deleted.

  • b3/B3LowerMacros.cpp:
  • b3/testb3_6.cpp:

(testInterpreter):

  • dfg/DFGOSRExitCompilerCommon.cpp:

(JSC::DFG::adjustAndJumpToTarget):

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::emitSwitchIntJump):
(JSC::DFG::SpeculativeJIT::emitSwitchImm):
(JSC::DFG::SpeculativeJIT::emitSwitchStringOnString):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGThunks.cpp:

(JSC::DFG::osrExitGenerationThunkGenerator):
(JSC::DFG::osrEntryThunkGenerator):

  • jit/CCallHelpers.h:

(JSC::CCallHelpers::jumpToExceptionHandler):

  • jit/JIT.cpp:

(JSC::JIT::emitEnterOptimizationCheck):

  • jit/JITOpcodes.cpp:

(JSC::JIT::emit_op_catch):
(JSC::JIT::emit_op_switch_imm):
(JSC::JIT::emit_op_switch_char):
(JSC::JIT::emit_op_switch_string):
(JSC::JIT::emitSlow_op_loop_hint):

  • jit/JITOpcodes32_64.cpp:

(JSC::JIT::emit_op_catch):
(JSC::JIT::emit_op_switch_imm):
(JSC::JIT::emit_op_switch_char):
(JSC::JIT::emit_op_switch_string):

  • jit/ThunkGenerators.cpp:

(JSC::slowPathFor):
(JSC::virtualThunkFor):

  • llint/LLIntThunks.cpp:

(JSC::LLInt::generateThunkWithJumpTo):

  • wasm/WasmBinding.cpp:

(JSC::Wasm::wasmToWasm):

  • wasm/WasmThunks.cpp:

(JSC::Wasm::throwExceptionFromWasmThunkGenerator):

  • wasm/js/WasmToJS.cpp:

(JSC::Wasm::emitThrowWasmToJSException):

  • yarr/YarrJIT.cpp:

(JSC::Yarr::YarrGenerator::loadFromFrameAndJump):

12:47 PM Changeset in webkit [248685] by Alan Bujtas
  • 5 edits in trunk/Source

[ContentChangeObserver] Stop content change observation explicitly.
https://bugs.webkit.org/show_bug.cgi?id=200689
<rdar://problem/54274887>

Reviewed by Simon Fraser.

Source/WebCore:

This helps to clean up some temporary state. There are 2 exit points when content observation needs to stop.

  1. Soon after the synthetic mouseMove event when we decide not to continue with further observation (see WebPage::handleSyntheticClick)
  2. When we asynchronously notify the client about the visible content change after all pending events have been processed.
  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::stopContentObservation):
(WebCore::ContentChangeObserver::adjustObservedState):

  • page/ios/ContentChangeObserver.h:

(WebCore::ContentChangeObserver::stopContentObservation const):
(WebCore::ContentChangeObserver::isObservingContentChanges const):
(WebCore::ContentChangeObserver::observedContentChange const): Deleted.

Source/WebKit:

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::handleSyntheticClick):

12:16 PM Changeset in webkit [248684] by Jonathan Bedard
  • 2 edits in trunk/Tools

results.webkit.org: 500 errors on API endpoints don't return JSON
https://bugs.webkit.org/show_bug.cgi?id=200722

Reviewed by Aakash Jain.

  • resultsdbpy/resultsdbpy/controller/api_routes.py:

(APIRoutes.response_500): We should return the response, instead of abort.

11:45 AM Changeset in webkit [248683] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: Computed: move the Box Model section to the top
https://bugs.webkit.org/show_bug.cgi?id=200555

Reviewed by Joseph Pecoraro.

For nodes that use a lot of different CSS properties, having the Box Model section all the
way at the bottom isn't as useful for taking a quick glance at the node's box model data.

  • UserInterface/Views/ComputedStyleDetailsPanel.js:

(WI.ComputedStyleDetailsPanel.prototype.initialLayout):

11:43 AM Changeset in webkit [248682] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: Computed: the collapsed state of the Variables section should be separate from the collapsed state of the Properties section
https://bugs.webkit.org/show_bug.cgi?id=200725

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/ComputedStyleDetailsPanel.js:

(WI.ComputedStyleDetailsPanel.prototype.initialLayout):
Use a different identifier string for the Variable section so it preserves its own collapsed
collapsed state independent of the Properties section.

11:41 AM Changeset in webkit [248681] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: Computed: the background of the Properties/Variables sections should match the Box Model section when expanded
https://bugs.webkit.org/show_bug.cgi?id=200724

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/ComputedStyleDetailsPanel.css:

(.sidebar > .panel.details.css-style > .content > .computed > .details-section:not(.collapsed) > :matches(.header, .content)): Added.
(.sidebar > .panel.details.css-style > .content > .computed .computed-style-properties): Added.
(.sidebar > .panel.details.css-style > .content > .computed .computed-style-properties .property .go-to-arrow): Added.
(.sidebar > .panel.details.css-style > .content > .computed .computed-style-properties .property:hover .go-to-arrow): Added.
(.sidebar > .panel.details.css-style > .content > .computed .details-section:matches(.computed-style-properties, .computed-style-variables) > .content): Added.
(.details-section:matches(.computed-style-properties, .computed-style-box-model):not(.collapsed) > :matches(.header, .content)): Deleted.
(.computed-style-properties): Deleted.
(.computed-style-properties .property .go-to-arrow): Deleted.
(.computed-style-properties .property:hover .go-to-arrow): Deleted.
(.details-section.computed-style-properties:not(.collapsed) > :matches(.header, .content)): Deleted.
(.details-section.computed-style-properties > .content): Deleted.
(@media (prefers-color-scheme: dark)): Deleted.
Use more specific selectors to match overall Web Inspector style.

  • UserInterface/Views/ComputedStyleSection.css:

(.computed-style-section .computed-property-item.expanded):
Darken the background of any expanded computed property in light mode.

11:20 AM Changeset in webkit [248680] by Joseph Pecoraro
  • 7 edits in trunk/Source/JavaScriptCore

Web Inspector: Remove bad semicolon in generation of ObjC methods
https://bugs.webkit.org/show_bug.cgi?id=200655

Reviewed by Devin Rousso.

  • inspector/scripts/codegen/generate_objc_frontend_dispatcher_implementation.py:

(ObjCFrontendDispatcherImplementationGenerator._generate_event_dispatcher_implementations):
Do not include a semicolon in the method implementation.

  • inspector/scripts/tests/all/expected/definitions-with-mac-platform.json-result:
  • inspector/scripts/tests/generic/expected/enum-values.json-result:
  • inspector/scripts/tests/generic/expected/events-with-optional-parameters.json-result:
  • inspector/scripts/tests/generic/expected/generate-domains-with-feature-guards.json-result:
  • inspector/scripts/tests/mac/expected/definitions-with-mac-platform.json-result:

Updated results.

11:13 AM Changeset in webkit [248679] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

[WebAuthN] Enable LocalAuthenticator for macOS
https://bugs.webkit.org/show_bug.cgi?id=182772

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations: Skip two more tests that are only expected to run on internal bots.
11:05 AM Changeset in webkit [248678] by Jonathan Bedard
  • 2 edits in trunk/Tools

results.webkit.org: Don't save configuration multiple times in upload
https://bugs.webkit.org/show_bug.cgi?id=200719

Reviewed by Aakash Jain.

  • resultsdbpy/resultsdbpy/model/upload_context.py:

(UploadContext.upload_test_results): Move registering of the configuration out
of the branch loop.

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

Remove use of emptySessionID from NetworkLoadParameters
https://bugs.webkit.org/show_bug.cgi?id=200712

Reviewed by Alex Christensen.

Make NetworkLoadParameters constructor take a session ID.
Update call sites accordingly.

  • NetworkProcess/AdClickAttributionManager.cpp:

(WebKit::AdClickAttributionManager::fireConversionRequest):

  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::startDownload):

  • NetworkProcess/NetworkCORSPreflightChecker.cpp:

(WebKit::NetworkCORSPreflightChecker::startPreflight):

  • NetworkProcess/NetworkLoadParameters.h:

(WebKit::NetworkLoadParameters::NetworkLoadParameters):

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::preconnectTo):

  • NetworkProcess/NetworkResourceLoadParameters.cpp:

(WebKit::NetworkResourceLoadParameters::encode const):
(WebKit::NetworkResourceLoadParameters::decode):

  • NetworkProcess/NetworkResourceLoadParameters.h:

(WebKit::NetworkResourceLoadParameters::NetworkResourceLoadParameters):

  • NetworkProcess/cache/NetworkCacheSpeculativeLoad.cpp:

(WebKit::NetworkCache::SpeculativeLoad::SpeculativeLoad):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
(WebKit::WebLoaderStrategy::loadResourceSynchronously):
(WebKit::WebLoaderStrategy::startPingLoad):
(WebKit::WebLoaderStrategy::preconnectTo):

10:21 AM Changeset in webkit [248676] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

Update Worker::notifyFinished to not use emptySessionID
https://bugs.webkit.org/show_bug.cgi?id=200710

Reviewed by Alex Christensen.

No change of behavior.

Exit early if context is gone since we should not dispatch events or create worker.
Make sure to unset pending activity using a ScopeExit.

  • workers/Worker.cpp:

(WebCore::Worker::notifyFinished):

10:16 AM Changeset in webkit [248675] by youenn@apple.com
  • 4 edits in trunk/Source/WebKit

Remove use of emptySessionID from WebPageCreationParameters
https://bugs.webkit.org/show_bug.cgi?id=200708

Reviewed by Alex Christensen.

Make WebPageCreationParameters constructor take a SessionID.
Update constructor call sites.

  • Shared/WebPageCreationParameters.cpp:

(WebKit::WebPageCreationParameters::decode):

  • Shared/WebPageCreationParameters.h:

(WebKit::WebPageCreationParameters::WebPageCreationParameters):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):

10:12 AM Changeset in webkit [248674] by youenn@apple.com
  • 5 edits in trunk/Source/WebKit

Remove API::PageConfiguration::m_sessionID
https://bugs.webkit.org/show_bug.cgi?id=200670

Reviewed by Alex Christensen.

We can remove this member since it is only accessed for a debug assertion that can be removed without any harm.

  • UIProcess/API/APIPageConfiguration.cpp:

(API::PageConfiguration::PageConfiguration):
(API::PageConfiguration::copy const):
(API::PageConfiguration::setWebsiteDataStore):

  • UIProcess/API/APIPageConfiguration.h:
  • UIProcess/API/glib/WebKitWebContext.cpp:

(webkitWebContextCreatePageForWebView):

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::createWebPage):

10:10 AM Changeset in webkit [248673] by youenn@apple.com
  • 2 edits in trunk/Tools

Reenable Update ContentFiltering.LazilyLoadPlatformFrameworks test for NetworkExtension
https://bugs.webkit.org/show_bug.cgi?id=200706

Reviewed by Alex Christensen.

Libwebrtc is now soft-linked so we can reenable this test.

  • TestWebKitAPI/Tests/WebKitCocoa/ContentFiltering.mm:

(-[LazilyLoadPlatformFrameworksController expectParentalControlsLoaded:networkExtensionLoaded:]):

9:39 AM Changeset in webkit [248672] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

[JSCOnly] JSCOnly port doesn't build on macOS
https://bugs.webkit.org/show_bug.cgi?id=200667

spi/darwin/ProcessMemoryFootprint.h is required by jsc.cpp so we add it to the WTF_PUBLIC_HEADERS.

Patch by Samuel Groß <saelo@google.com> on 2019-08-14
Reviewed by Alex Christensen.

  • wtf/PlatformJSCOnly.cmake:
  • wtf/PlatformMac.cmake:
8:39 AM Changeset in webkit [248671] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

[LFC][TFC] Implement TableFormattingContext::computePreferredWidthForColumns
https://bugs.webkit.org/show_bug.cgi?id=200701
<rdar://problem/54287828>

Reviewed by Antti Koivisto.

Compute cells' min/max width first.

  • layout/tableformatting/TableFormattingContext.cpp:

(WebCore::Layout::TableFormattingContext::computePreferredWidthForColumns const):

  • layout/tableformatting/TableGrid.cpp:

(WebCore::Layout::TableGrid::slot):
(WebCore::Layout::TableGrid::appendCell):

  • layout/tableformatting/TableGrid.h:

(WebCore::Layout::TableGrid::cells):

6:42 AM Changeset in webkit [248670] by youenn@apple.com
  • 34 edits in trunk/Source

ThreadableBlobRegistry::blobSize should take a SessionID as parameter
https://bugs.webkit.org/show_bug.cgi?id=200671

Source/WebCore:

Reviewed by Alex Christensen.

Update FormData to compute its byte size based on a SessionID.
We keep a WK1 byte length computation for FormDataElement.
Update FormData call sites accordingly.
Update CacheStorageConnection to implement a SessionID getter.
No change of behavior.

  • Modules/cache/CacheStorageConnection.cpp:

(WebCore::CacheStorageConnection::computeRealBodySize):
(WebCore::computeRealBodySize): Deleted.

  • Modules/cache/CacheStorageConnection.h:
  • Modules/cache/WorkerCacheStorageConnection.cpp:

(WebCore::WorkerCacheStorageConnection::sessionID const):

  • Modules/cache/WorkerCacheStorageConnection.h:
  • fileapi/Blob.cpp:

(WebCore::Blob::size const):

  • fileapi/ThreadableBlobRegistry.cpp:

(WebCore::ThreadableBlobRegistry::blobSize):

  • fileapi/ThreadableBlobRegistry.h:
  • loader/cache/KeepaliveRequestTracker.cpp:

(WebCore::KeepaliveRequestTracker::tryRegisterRequest):
(WebCore::KeepaliveRequestTracker::registerRequest):
(WebCore::KeepaliveRequestTracker::unregisterRequest):

  • page/CacheStorageProvider.h:

(WebCore::CacheStorageProvider::createCacheStorageConnection):

  • platform/network/BlobRegistry.h:
  • platform/network/FormData.cpp:

(WebCore::computeLengthInBytes):
(WebCore::FormDataElement::lengthInBytes const):
(WebCore::FormData::lengthInBytes const):

  • platform/network/FormData.h:
  • platform/network/cf/FormDataStreamCFNet.cpp:

(WebCore::createHTTPBodyCFReadStream):

  • platform/network/curl/CurlFormDataStream.cpp:

(WebCore::m_sessionID):
(WebCore::CurlFormDataStream::computeContentLength):
(WebCore::CurlFormDataStream::CurlFormDataStream): Deleted.

  • platform/network/curl/CurlFormDataStream.h:
  • platform/network/curl/CurlRequest.cpp:

(WebCore::CurlRequest::CurlRequest):

  • platform/network/curl/CurlRequest.h:

(WebCore::CurlRequest::create):

  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::createRequest):

Source/WebKit:

Reviewed by Alex Christensen.

Update WebCacheStorageConnection to implement sessionID getter.
Update NetworkConnectionToWebProcess to get a sessionID as parameter to blobSize computation.

  • NetworkProcess/curl/NetworkDataTaskCurl.cpp:

(WebKit::NetworkDataTaskCurl::createCurlRequest):

  • NetworkProcess/NetworkConnectionToWebProcess.cpp:

(WebKit::NetworkConnectionToWebProcess::blobSize):
(WebKit::NetworkConnectionToWebProcess::writeBlobsToTemporaryFiles):

  • NetworkProcess/NetworkConnectionToWebProcess.h:
  • NetworkProcess/NetworkConnectionToWebProcess.messages.in:
  • NetworkProcess/NetworkProcessPlatformStrategies.cpp:

(WebKit::NetworkProcessPlatformStrategies::createBlobRegistry):

  • WebProcess/Cache/WebCacheStorageConnection.h:
  • WebProcess/FileAPI/BlobRegistryProxy.cpp:

(WebKit::BlobRegistryProxy::blobSize):

  • WebProcess/FileAPI/BlobRegistryProxy.h:

Source/WebKitLegacy/mac:

Reviewed by ALex Christensen.

  • WebCoreSupport/WebPlatformStrategies.mm:

Source/WebKitLegacy/win:

Reviewed by Alex Christensen.

  • WebCoreSupport/WebPlatformStrategies.cpp:
4:54 AM Changeset in webkit [248669] by Antti Koivisto
  • 3 edits in trunk/Source/WebCore

Remove TouchActionData
https://bugs.webkit.org/show_bug.cgi?id=199668

  • dom/Element.cpp:

(WebCore::Element::nearestScrollingNodeIDUsingTouchOverflowScrolling const): Deleted.

As a follow-up also remove this now-unused function.

  • dom/Element.h:
4:06 AM Changeset in webkit [248668] by youenn@apple.com
  • 16 edits in trunk/Source

Remove SessionID default constructor
https://bugs.webkit.org/show_bug.cgi?id=200669

Reviewed by Alex Christensen.

Source/WebCore:

Remove SessionID default constructor

Update CookieRequestHeaderFiledProxy decoder to use an Optional<SessionID>.
Update ServiceWorkerContextData accordingly.
Update RegistrationStore/RegistrationDatabase to store a map of changed registration as follows:

  • The RegistrationStore map contains an Optional value. In case of removing, the map will contain WTF::nullopt.
  • RegistrationDatabase computes two vectors for removed registrations and updated registrations.

No change of behavior.

  • dom/Document.cpp:
  • loader/CookieJar.cpp:

(WebCore::CookieJar::cookieRequestHeaderFieldProxy):

  • platform/network/CookieRequestHeaderFieldProxy.h:

(WebCore::CookieRequestHeaderFieldProxy::decode):

  • workers/Worker.cpp:

(WebCore::Worker::notifyFinished):

  • workers/service/ServiceWorkerContextData.h:

(WebCore::ServiceWorkerContextData::decode):

  • workers/service/server/RegistrationDatabase.cpp:

(WebCore::RegistrationDatabase::pushChanges):
(WebCore::RegistrationDatabase::doPushChanges):

  • workers/service/server/RegistrationDatabase.h:
  • workers/service/server/RegistrationStore.cpp:

(WebCore::RegistrationStore::pushChangesToDatabase):
(WebCore::RegistrationStore::clearAll):
(WebCore::RegistrationStore::flushChanges):
(WebCore::RegistrationStore::startSuspension):
(WebCore::RegistrationStore::removeRegistration):

  • workers/service/server/RegistrationStore.h:

Source/WebCore/PAL:

  • pal/SessionID.h:

Source/WebKit:

Update IPC decoder to use an Optional<SessionID>.
Update PageConfiguration to use emptySessionID instead of default constructor.

  • NetworkProcess/NetworkSessionCreationParameters.cpp:

(WebKit::NetworkSessionCreationParameters::decode):

  • Shared/WebPageCreationParameters.h:
  • UIProcess/API/APIPageConfiguration.cpp:

(API::PageConfiguration::PageConfiguration):
(API::PageConfiguration::sessionID): Deleted.
(API::PageConfiguration::setSessionID): Deleted.

3:25 AM Changeset in webkit [248667] by youenn@apple.com
  • 7 edits in trunk/Source/WebCore

Make privateBrowsingStateDidChange take an explicit SessionID
https://bugs.webkit.org/show_bug.cgi?id=200666

Reviewed by Alex Christensen.

Instead of stating that the page session ID changed and get it from the page,
pass it directly to privateBrowsingStateDidChange.
No change of behavior.

  • dom/Document.cpp:

(WebCore::Document::privateBrowsingStateDidChange):

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

(WebCore::Element::privateBrowsingStateDidChange):

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::privateBrowsingStateDidChange):

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

(WebCore::Page::setSessionID):

3:13 AM Changeset in webkit [248666] by youenn@apple.com
  • 3 edits in trunk/Source/WebKit

Make WebSWOriginStore::m_webSWServerConnections a WeakHashSet
https://bugs.webkit.org/show_bug.cgi?id=200661

Reviewed by Alex Christensen.

  • NetworkProcess/ServiceWorker/WebSWOriginStore.cpp:

(WebKit::WebSWOriginStore::importComplete):
(WebKit::WebSWOriginStore::registerSWServerConnection):
(WebKit::WebSWOriginStore::unregisterSWServerConnection):
(WebKit::WebSWOriginStore::didInvalidateSharedMemory):

  • NetworkProcess/ServiceWorker/WebSWOriginStore.h:
3:11 AM Changeset in webkit [248665] by youenn@apple.com
  • 3 edits in trunk/Source/WebKit

NetworkProcess::m_swServerConnections should use WeakPtr
https://bugs.webkit.org/show_bug.cgi?id=200660

Reviewed by Geoffrey Garen.

Use WeakPtr for SWServer connections as an extra safety measure.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::postMessageToServiceWorkerClient):
(WebKit::NetworkProcess::postMessageToServiceWorker):
(WebKit::NetworkProcess::registerSWServerConnection):
(WebKit::NetworkProcess::unregisterSWServerConnection):

  • NetworkProcess/NetworkProcess.h:
2:40 AM Changeset in webkit [248664] by youenn@apple.com
  • 2 edits in trunk/Source/WebKit

Move some WebRTC runtime flags from experimental to internal
https://bugs.webkit.org/show_bug.cgi?id=200672

Reviewed by Eric Carlson.

  • Shared/WebPreferences.yaml:
2:27 AM Changeset in webkit [248663] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore/PAL

Fail decoding an invalid SessionID
https://bugs.webkit.org/show_bug.cgi?id=200663

Reviewed by Alex Christensen.

  • pal/SessionID.h:

(PAL::SessionID::isValid const):
(PAL::SessionID::isValidSessionIDValue):
(PAL::SessionID::encode const):
Add a release assert to catch bad sessionID senders.
(PAL::SessionID::decode):
Fail decoding if session ID is not a valid value.

Aug 13, 2019:

11:06 PM Changeset in webkit [248662] by graouts@webkit.org
  • 1 edit
    4 adds in trunk/LayoutTests

[iPadOS] slides.google.com: Cannot dismiss the context menu by tapping on the canvas
https://bugs.webkit.org/show_bug.cgi?id=200219
<rdar://problem/53650423>

Reviewed by Zalan Bujtas.

While the code change for this bug is all in code private to Safari, we add tests that check that removing implicit pointer capture
or removing the original target element while the pointer is active correctly fires the "pointerup" event at the element that hit tests
at the touch release point.

  • pointerevents/ios/pointer-events-implicit-capture-element-removed-while-pointer-active-expected.txt: Added.
  • pointerevents/ios/pointer-events-implicit-capture-element-removed-while-pointer-active.html: Added.
  • pointerevents/ios/pointer-events-implicit-capture-released-while-pointer-active-expected.txt: Added.
  • pointerevents/ios/pointer-events-implicit-capture-released-while-pointer-active.html: Added.
8:38 PM Changeset in webkit [248661] by sbarati@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

Add a way to opt out of kern TCSM for layout tests
https://bugs.webkit.org/show_bug.cgi?id=200649
<rdar://problem/51304923>

Reviewed by Alexey Proskuryakov.

  • assembler/CPU.cpp:

(JSC::isKernTCSMAvailable):

  • runtime/Options.h:
8:17 PM Changeset in webkit [248660] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

Fix the WPE build.

  • platform/libwpe/PlatformKeyboardEventLibWPE.cpp:

(WebCore::PlatformKeyboardEvent::keyValueForWPEKeyCode):
(WebCore::PlatformKeyboardEvent::singleCharacterString):
Update for rename from StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32).

8:15 PM Changeset in webkit [248659] by weinig@apple.com
  • 15 edits in trunk

Rename StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32) to avoid accidental change in behavior when replacing append with flexibleAppend
https://bugs.webkit.org/show_bug.cgi?id=200675

Reviewed by Darin Adler.

Source/JavaScriptCore:

  • yarr/YarrParser.h:

(JSC::Yarr::Parser::tryConsumeGroupName):
(JSC::Yarr::Parser::tryConsumeUnicodePropertyExpression):
Update for rename from StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32).

Source/WebCore:

  • bindings/js/JSDOMConvertStrings.cpp:

(WebCore::stringToUSVString):

  • css/CSSMarkup.cpp:

(WebCore::serializeCharacter):
(WebCore::serializeIdentifier):
(WebCore::serializeString):

  • css/parser/CSSTokenizer.cpp:

(WebCore::CSSTokenizer::consumeStringTokenUntil):
(WebCore::CSSTokenizer::consumeUrlToken):
(WebCore::CSSTokenizer::consumeName):

  • html/parser/HTMLEntityParser.cpp:

(WebCore::HTMLEntityParser::consumeNamedEntity):

  • platform/mock/mediasource/MockBox.cpp:

(WebCore::MockBox::peekType):
(WebCore::MockTrackBox::MockTrackBox):

  • rendering/RenderText.cpp:

(WebCore::capitalize):

  • xml/parser/CharacterReferenceParserInlines.h:

(WebCore::consumeCharacterReference):
Update for rename from StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32).

Source/WTF:

When we switch StringBuilder::append(...) to be based on the StringConcatenate/makeString flexibleAppend
implementation, if we don't change anything, the behavior of StringBuilder::append(UChar32) will go from
appending a character to appending a stringified number.

To work around this, we can rename StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32)
and update all the call sites.

  • wtf/text/StringBuilder.h:

(WTF::StringBuilder::appendCharacter):
Renamed StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32).

  • wtf/FileSystem.cpp:

(WTF::FileSystemImpl::decodeFromFilename):
Update for new name.

Tools:

  • TestWebKitAPI/Tests/WTF/StringBuilder.cpp:

(TestWebKitAPI::TEST):
Update for rename from StringBuilder::append(UChar32) to StringBuilder::appendCharacter(UChar32).

8:00 PM Changeset in webkit [248658] by sbarati@apple.com
  • 4 edits
    4 adds in trunk

[WHLSL] Make lexing faster
https://bugs.webkit.org/show_bug.cgi?id=200596

Reviewed by Myles C. Maxfield.

Source/WebCore:

Previously, our lexer would just branch on a series of string compares.
We'd have code like this to match keywords:
`
...
if (matchCurrent("false"))

return FalseToken;

if (matchCurrent("true"))

return TrueToken;

...
`

However, this is extremely inefficient. We now lex using a trie, which means
we never backtrack in the lexer.

This patch is a 3ms speedup in compute_boids.

Tests: webgpu/whlsl/lexing.html

webgpu/whlsl/literals.html

  • Modules/webgpu/WHLSL/WHLSLLexer.cpp:

(WebCore::WHLSL::isValidIdentifierStart):
(WebCore::WHLSL::isValidNonStartingIdentifierChar):
(WebCore::WHLSL::isHexadecimalCharacter):
(WebCore::WHLSL::isDigit):
(WebCore::WHLSL::Lexer::consumeTokenFromStream):
(WebCore::WHLSL::Lexer::recognizeKeyword): Deleted.
(WebCore::WHLSL::Lexer::coreDecimalIntLiteral const): Deleted.
(WebCore::WHLSL::Lexer::decimalIntLiteral const): Deleted.
(WebCore::WHLSL::Lexer::decimalUintLiteral const): Deleted.
(WebCore::WHLSL::Lexer::coreHexadecimalIntLiteral const): Deleted.
(WebCore::WHLSL::Lexer::hexadecimalIntLiteral const): Deleted.
(WebCore::WHLSL::Lexer::hexadecimalUintLiteral const): Deleted.
(WebCore::WHLSL::Lexer::intLiteral const): Deleted.
(WebCore::WHLSL::Lexer::uintLiteral const): Deleted.
(WebCore::WHLSL::Lexer::digit const): Deleted.
(WebCore::WHLSL::Lexer::digitStar const): Deleted.
(WebCore::WHLSL::Lexer::character const): Deleted.
(WebCore::WHLSL::Lexer::coreFloatLiteralType1 const): Deleted.
(WebCore::WHLSL::Lexer::coreFloatLiteral const): Deleted.
(WebCore::WHLSL::Lexer::floatLiteral const): Deleted.
(WebCore::WHLSL::Lexer::validIdentifier const): Deleted.
(WebCore::WHLSL::Lexer::identifier const): Deleted.
(WebCore::WHLSL::Lexer::completeOperatorName const): Deleted.

  • Modules/webgpu/WHLSL/WHLSLLexer.h:

(WebCore::WHLSL::Lexer::string const): Deleted.

LayoutTests:

  • webgpu/whlsl/lexing-expected.txt: Added.
  • webgpu/whlsl/lexing.html: Added.
  • webgpu/whlsl/literals-expected.txt: Added.
  • webgpu/whlsl/literals.html: Added.
6:58 PM Changeset in webkit [248657] by commit-queue@webkit.org
  • 73 edits
    1 delete in trunk/Source

shouldRespectImageOrientation should be a value in ImageOrientation
https://bugs.webkit.org/show_bug.cgi?id=200553

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-13
Reviewed by Simon Fraser.

Source/WebCore:

This patch is a step towards implementing the css image-orientation.

Instead of having ImageOrientationEnum, ImageOrientationDescription,
ImageOrientation and RespectImageOrientationEnum we are going to have a
single structure named 'ImageOrientation' which is a wrapper for the enum
type "Orientation".

This structure will have a constructor and casting operator such that
assigning an enum value and comparing with an enum value will be done
implicitly.

RespectImageOrientation is represented as a new enum value 'FromImage'.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • css/CSSPrimitiveValueMappings.h:

(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator ImageOrientation const):
(WebCore::CSSPrimitiveValue::operator ImageOrientationEnum const): Deleted.

  • dom/DataTransfer.cpp:

(WebCore::DataTransfer::createDragImage const):

  • html/HTMLCanvasElement.cpp:

(WebCore::HTMLCanvasElement::paint):

  • loader/cache/CachedImage.cpp:

(WebCore::CachedImage::imageSizeForRenderer const):

  • page/DragController.cpp:

(WebCore::DragController::doImageDrag):

  • platform/DragImage.cpp:

(WebCore::createDragImageFromSnapshot):
(WebCore::createDragImageFromImage):

  • platform/DragImage.h:
  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::draw):
(WebCore::BitmapImage::drawPattern):

  • platform/graphics/BitmapImage.h:
  • platform/graphics/CrossfadeGeneratedImage.cpp:

(WebCore::CrossfadeGeneratedImage::draw):

  • platform/graphics/CrossfadeGeneratedImage.h:
  • platform/graphics/CustomPaintImage.cpp:

(WebCore::CustomPaintImage::draw):

  • platform/graphics/CustomPaintImage.h:
  • platform/graphics/GeneratedImage.h:
  • platform/graphics/GradientImage.cpp:

(WebCore::GradientImage::draw):

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

(WebCore::GraphicsContext::drawImage):
(WebCore::GraphicsContext::drawTiledImage):

  • platform/graphics/GraphicsContext.h:

(WebCore::ImagePaintingOptions::ImagePaintingOptions):

  • platform/graphics/GraphicsContextImpl.cpp:

(WebCore::GraphicsContextImpl::drawImageImpl):
(WebCore::GraphicsContextImpl::drawTiledImageImpl):

  • platform/graphics/Image.cpp:

(WebCore::Image::drawTiled):

  • platform/graphics/Image.h:
  • platform/graphics/ImageFrame.h:
  • platform/graphics/ImageOrientation.cpp: Removed.
  • platform/graphics/ImageOrientation.h:

(WebCore::ImageOrientation::ImageOrientation):
(WebCore::ImageOrientation::fromEXIFValue):
(WebCore::ImageOrientation::operator Orientation const):
(WebCore::ImageOrientation::usesWidthAsHeight const):
(WebCore::ImageOrientation::transformFromDefault const):
(WebCore::ImageOrientation::isValidOrientation):
(WebCore::ImageOrientation::isValidEXIFOrientation):
(WebCore::ImageOrientationDescription::ImageOrientationDescription): Deleted.
(WebCore::ImageOrientationDescription::setRespectImageOrientation): Deleted.
(WebCore::ImageOrientationDescription::respectImageOrientation): Deleted.
(WebCore::ImageOrientationDescription::setImageOrientationEnum): Deleted.
(WebCore::ImageOrientationDescription::imageOrientation): Deleted.
(WebCore::ImageOrientation::operator ImageOrientationEnum const): Deleted.
(WebCore::ImageOrientation::operator== const): Deleted.
(WebCore::ImageOrientation::operator!= const): Deleted.

  • platform/graphics/ImageSource.cpp:

(WebCore::ImageSource::dump):

  • platform/graphics/NamedImageGeneratedImage.cpp:

(WebCore::NamedImageGeneratedImage::draw):

  • platform/graphics/NamedImageGeneratedImage.h:
  • platform/graphics/NativeImage.h:
  • platform/graphics/avfoundation/objc/ImageDecoderAVFObjC.mm:

(WebCore::ImageDecoderAVFObjC::frameOrientationAtIndex const):

  • platform/graphics/cairo/CairoOperations.cpp:

(WebCore::Cairo::drawShadowLayerBuffer):
(WebCore::Cairo::drawShadowImage):
(WebCore::Cairo::drawNativeImage):

  • platform/graphics/cairo/ImageBufferCairo.cpp:

(WebCore::ImageBuffer::draw):

  • platform/graphics/cairo/NativeImageCairo.cpp:

(WebCore::drawNativeImage):

  • platform/graphics/cg/GraphicsContextCG.cpp:

(WebCore::GraphicsContext::drawNativeImage):

  • platform/graphics/cg/ImageDecoderCG.cpp:

(WebCore::orientationFromProperties):
(WebCore::ImageDecoderCG::frameOrientationAtIndex const):

  • platform/graphics/cg/NativeImageCG.cpp:

(WebCore::drawNativeImage):

  • platform/graphics/cg/PDFDocumentImage.cpp:

(WebCore::PDFDocumentImage::draw):

  • platform/graphics/cg/PDFDocumentImage.h:
  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:

(WebCore::MediaPlayerPrivateGStreamer::handleMessage):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:

(WebCore::MediaPlayerPrivateGStreamerBase::paint):
(WebCore::MediaPlayerPrivateGStreamerBase::setVideoSourceOrientation):
(WebCore::MediaPlayerPrivateGStreamerBase::updateTextureMapperFlags):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
  • platform/graphics/gstreamer/VideoTextureCopierGStreamer.cpp:

(WebCore::VideoTextureCopierGStreamer::updateTextureSpaceMatrix):
(WebCore::VideoTextureCopierGStreamer::copyVideoTextureToPlatformTexture):

  • platform/graphics/gstreamer/VideoTextureCopierGStreamer.h:
  • platform/graphics/win/Direct2DOperations.cpp:

(WebCore::Direct2D::drawNativeImage):

  • platform/graphics/win/ImageCGWin.cpp:

(WebCore::BitmapImage::getHBITMAPOfSize):
(WebCore::BitmapImage::drawFrameMatchingSourceSize):

  • platform/graphics/win/ImageCairoWin.cpp:

(WebCore::BitmapImage::getHBITMAPOfSize):
(WebCore::BitmapImage::drawFrameMatchingSourceSize):

  • platform/graphics/win/ImageDecoderDirect2D.cpp:

(WebCore::ImageDecoderDirect2D::frameOrientationAtIndex const):

  • platform/graphics/win/ImageDirect2D.cpp:

(WebCore::BitmapImage::drawFrameMatchingSourceSize):

  • platform/graphics/win/NativeImageDirect2D.cpp:

(WebCore::drawNativeImage):

  • platform/gtk/DragImageGtk.cpp:

(WebCore::createDragImageFromImage):

  • platform/image-decoders/ScalableImageDecoderFrame.h:
  • platform/image-decoders/jpeg/JPEGImageDecoder.cpp:

(WebCore::readImageOrientation):

  • platform/ios/DragImageIOS.mm:

(WebCore::createDragImageFromImage):

  • platform/mac/DragImageMac.mm:

(WebCore::createDragImageFromImage):

  • platform/win/DragImageCGWin.cpp:

(WebCore::createDragImageFromImage):

  • platform/win/DragImageCairoWin.cpp:

(WebCore::createDragImageFromImage):

  • platform/win/DragImageDirect2D.cpp:

(WebCore::createDragImageFromImage):

  • rendering/RenderBoxModelObject.cpp:

(WebCore::RenderBoxModelObject::paintFillLayerExtended):

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::imageOrientation const):
(WebCore::RenderElement::shouldRespectImageOrientation const): Deleted.

  • rendering/RenderElement.h:
  • rendering/RenderEmbeddedObject.cpp:

(WebCore::RenderEmbeddedObject::paintSnapshotImage):

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::paintReplaced):
(WebCore::RenderImage::paintIntoRect):

  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::isDirectlyCompositedImage const):

  • rendering/RenderSnapshottedPlugIn.cpp:

(WebCore::RenderSnapshottedPlugIn::paintSnapshot):

  • rendering/style/RenderStyle.h:

(WebCore::RenderStyle::setImageOrientation):
(WebCore::RenderStyle::initialImageOrientation):
(WebCore::RenderStyle::imageOrientation const):

  • rendering/style/StyleRareInheritedData.h:
  • svg/graphics/SVGImage.cpp:

(WebCore::SVGImage::drawForContainer):
(WebCore::SVGImage::nativeImageForCurrentFrame):
(WebCore::SVGImage::nativeImage):
(WebCore::SVGImage::draw):

  • svg/graphics/SVGImage.h:
  • svg/graphics/SVGImageForContainer.cpp:

(WebCore::SVGImageForContainer::draw):

  • svg/graphics/SVGImageForContainer.h:

Source/WebKit:

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::imagePositionInformation):

6:36 PM Changeset in webkit [248656] by rmorisset@apple.com
  • 2 edits in trunk/Source/WebCore

[WHLSL] Move Qualifiers and Semantic from VariableDeclaration to VariableDeclaration::RareData
https://bugs.webkit.org/show_bug.cgi?id=200696

Reviewed by Myles C. Maxfield.

Shrinking VariableDeclaration by 16 bytes in the common case.

No new tests as there is no intended functional change.

  • Modules/webgpu/WHLSL/AST/WHLSLVariableDeclaration.h:
6:19 PM Changeset in webkit [248655] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248634. rdar://problem/54282811

Fix potential thread safety issue under WebResourceLoadStatisticsStore::hasHadUserInteraction()
https://bugs.webkit.org/show_bug.cgi?id=200688

Reviewed by Alex Christensen.

Fix potential thread safety issue under WebResourceLoadStatisticsStore::hasHadUserInteraction().
It passes a RegistrableDomain to another thread without isolated copying it.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp: (WebKit::WebResourceLoadStatisticsStore::hasHadUserInteraction):

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

6:19 PM Changeset in webkit [248654] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248633. rdar://problem/54282803

Fix potential thread safety issue under StorageManager::getSessionStorageOrigins()
https://bugs.webkit.org/show_bug.cgi?id=200684

Reviewed by Geoffrey Garen.

Fix potential thread safety issue under StorageManager::getSessionStorageOrigins(). The origins are being
passed from the background queue to the main thread without isolated copy.

  • NetworkProcess/WebStorage/StorageManager.cpp: (WebKit::StorageManager::getSessionStorageOrigins):

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

6:19 PM Changeset in webkit [248653] by Alan Coon
  • 6 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248604. rdar://problem/54282801

Source/WebCore:
Event region collection should take clipping into account
https://bugs.webkit.org/show_bug.cgi?id=200668
<rdar://problem/53826561>

Reviewed by Simon Fraser.

Test: pointerevents/ios/touch-action-region-clip-and-transform.html

  • rendering/EventRegion.cpp: (WebCore::EventRegionContext::pushClip): (WebCore::EventRegionContext::popClip):

Maintain clip rect stack.

(WebCore::EventRegionContext::unite):

Apply both transforms and clipping.

  • rendering/EventRegion.h:
  • rendering/RenderBlock.cpp:
  • rendering/RenderBox.cpp: (WebCore::RenderBox::pushContentsClip): (WebCore::RenderBox::popContentsClip):

Update clip for non-self-painting layers.

  • rendering/RenderLayer.cpp: (WebCore::RenderLayer::clipToRect): (WebCore::RenderLayer::restoreClip):

Update clip for self-painting layers.

LayoutTests:
Event regions collection should take clipping into account
https://bugs.webkit.org/show_bug.cgi?id=200668
<rdar://problem/53826561>

Reviewed by Simon Fraser.

  • pointerevents/ios/touch-action-region-clip-and-transform-expected.txt: Added.
  • pointerevents/ios/touch-action-region-clip-and-transform.html: Added.

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

6:19 PM Changeset in webkit [248652] by Alan Coon
  • 5 edits in branches/safari-608-branch

Cherry-pick r248598. rdar://problem/54282797

Crash under IPC::Connection::markCurrentlyDispatchedMessageAsInvalid()
https://bugs.webkit.org/show_bug.cgi?id=200674
<rdar://problem/50692748>

Reviewed by Geoff Garen.

Source/WebKit:

When the client terminates a provisional process (e.g. via the [WKWebView _killWebContentProcessAndResetState]
SPI), the WebProcessProxy would notify its associated WebPageProxy objects that it had terminated but would fail
to notify its associated ProvisionalPageProxy objects. As a result, those objects would not get destroyed and
would still think that they were in the middle of a provisional load the next time a load started. This inconsistent
state would lead to crashes such as the one in the radar.

  • UIProcess/ProvisionalPageProxy.cpp: (WebKit::ProvisionalPageProxy::cancel):
  • UIProcess/WebProcessProxy.cpp: (WebKit::WebProcessProxy::requestTermination):

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:

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

6:19 PM Changeset in webkit [248651] by Alan Coon
  • 5 edits in branches/safari-608-branch/Source/WebCore

Cherry-pick r248597. rdar://problem/54282817

Make sure UniqueIDBDatabaseConnection unregister itself from IDBServer
https://bugs.webkit.org/show_bug.cgi?id=200650
<rdar://problem/54236010>

Reviewed by Youenn Fablet.

We register UniqueIDBDatabaseConnection unconditionally to IDBServer but fail to unregister if UniqueIDBDatabase
of UniqueIDBDatabaseConnection is gone.

  • Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp: (WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection): (WebCore::IDBServer::UniqueIDBDatabaseConnection::~UniqueIDBDatabaseConnection):
  • Modules/indexeddb/server/UniqueIDBDatabaseConnection.h: (WebCore::IDBServer::UniqueIDBDatabaseConnection::server):
  • Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp: (WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction): (WebCore::IDBServer::UniqueIDBDatabaseTransaction::~UniqueIDBDatabaseTransaction):
  • Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:

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

6:05 PM Changeset in webkit [248650] by rmorisset@apple.com
  • 8 edits in trunk/Source/WebCore

[WHLSL] Don't generate empty comma expressions for bare ';'
https://bugs.webkit.org/show_bug.cgi?id=200681

Reviewed by Myles C. Maxfield.

Currently we emit a comma expression with no sub-expression for bare ';', as well as for the initialization of for loops with no initializers.
This crashes the Checker, as it tries to access the last sub-expression of comma expressions.
Instead we should generate an empty statement block for that case.

This problem was found (and originally fixed before the commit was reverted) in https://bugs.webkit.org/show_bug.cgi?id=199726.
I am just isolating the fix here for easier review and debugging.

New test: LayoutTests/webgpu/whlsl/for-loop.html

  • Modules/webgpu/WHLSL/AST/WHLSLForLoop.h:
  • Modules/webgpu/WHLSL/Metal/WHLSLFunctionWriter.cpp:

(WebCore::WHLSL::Metal::FunctionDefinitionWriter::visit):

  • Modules/webgpu/WHLSL/WHLSLASTDumper.cpp:

(WebCore::WHLSL::ASTDumper::visit):

  • Modules/webgpu/WHLSL/WHLSLChecker.cpp:

(WebCore::WHLSL::Checker::visit):

  • Modules/webgpu/WHLSL/WHLSLParser.cpp:

(WebCore::WHLSL::Parser::parseForLoop):
(WebCore::WHLSL::Parser::parseStatement):
(WebCore::WHLSL::Parser::parseEffectfulExpression):

  • Modules/webgpu/WHLSL/WHLSLParser.h:
  • Modules/webgpu/WHLSL/WHLSLVisitor.cpp:

(WebCore::WHLSL::Visitor::visit):

6:03 PM Changeset in webkit [248649] by zhifei_fang@apple.com
  • 3 edits in trunk/Tools

[results.webkit.org Timeline] Performance improvement - Skip render offscreen canvas
https://bugs.webkit.org/show_bug.cgi?id=200456

Reviewed by Jonathan Bedard.

This patch disable use the new batch draw method to render canvas directly without any caches, this will save a lot of memory, so that we won't go into the "low memory mode".

This patch also change the axis label collision detact box from a rect to polygon, so that we can dectact click more accurate.

  • resultsdbpy/resultsdbpy/view/static/library/js/Utils.js:
  • resultsdbpy/resultsdbpy/view/static/library/js/components/TimelineComponents.js:

(pointPolygonCollisionDetect): Detact
(pointRightRayLineSegmentCollisionDetect):
(ColorBatchRender):
(ColorBatchRender.prototype.lazyCreateColorSeqs):
(ColorBatchRender.prototype.addSeq):
(ColorBatchRender.prototype.batchRender):
(ColorBatchRender.prototype.clear):
(xScrollStreamRenderFactory):
(Timeline.CanvasSeriesComponent):
(offscreenCachedRenderFactory): Deleted.

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

Focus rings are black
https://bugs.webkit.org/show_bug.cgi?id=200593
<rdar://problem/54145925>

Patch by Daniel Bates <dabates@apple.com> on 2019-08-13
Reviewed by Wenson Hsieh.

Work around <rdar://problem/50838886> and make focus rings a pretty blue.

  • rendering/RenderThemeIOS.mm:

(WebCore::RenderThemeIOS::platformFocusRingColor const):

5:29 PM Changeset in webkit [248647] by commit-queue@webkit.org
  • 20 edits
    24 adds in trunk/LayoutTests

Re-sync web-platform-tests/dom/events from upstream
https://bugs.webkit.org/show_bug.cgi?id=200592

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-08-13
Reviewed by Ryosuke Niwa.

Re-sync web-platform-tests/dom/events from upstream 1e6fef09eae3.

LayoutTests/imported/w3c:

  • resources/import-expectations.json:
  • web-platform-tests/dom/events/*: Updated.

LayoutTests:

  • TestExpectations:
  • platform/ios/TestExpectations:
  • platform/ios/imported/w3c/web-platform-tests/dom/events/EventTarget-dispatchEvent-expected.txt:
  • tests-options.json:
4:58 PM Changeset in webkit [248646] by Ryan Haddad
  • 3 edits in branches/safari-608-branch/LayoutTests

Cherry-pick r248600. rdar://problem/53779679

Reverting change in r248379
rdar://53779679

Unreviewed Test Gardening.
Removed previously set TestExpectations.

  • platform/ios-12/TestExpectations:
  • platform/ios/TestExpectations:

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

4:58 PM Changeset in webkit [248645] by Ryan Haddad
  • 3 edits in branches/safari-608-branch/LayoutTests

Cherry-pick r248468. rdar://problem/54049321

Correcting Expectation Typo from r248388.
rdar://54049321

Unreviewed Test Gardening.

  • platform/ios-12/TestExpectations:
  • platform/ios/TestExpectations:

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

4:58 PM Changeset in webkit [248644] by Ryan Haddad
  • 26 edits
    25 copies
    19 adds in branches/safari-608-branch/LayoutTests

Cherry-pick r248424. rdar://problem/53836015

Add Catalina Baselines for Font-related Tests.
rdar://53836015

Unreviewed Test Gardening.

  • platform/mac-mojave/css1/basic/inheritance-expected.txt: Copied from LayoutTests/platform/mac/css1/basic/inheritance-expected.txt.
  • platform/mac-mojave/css2.1/t0602-c13-inh-underlin-00-e-expected.txt: Copied from LayoutTests/platform/mac/css2.1/t0602-c13-inh-underlin-00-e-expected.txt.
  • platform/mac-mojave/css2.1/t0805-c5522-brdr-02-e-expected.txt: Copied from LayoutTests/platform/mac/css2.1/t0805-c5522-brdr-02-e-expected.txt.
  • platform/mac-mojave/css3/selectors3/html/css3-modsel-18-expected.txt: Copied from LayoutTests/platform/mac/css3/selectors3/html/css3-modsel-18-expected.txt.
  • platform/mac-mojave/css3/selectors3/xhtml/css3-modsel-18-expected.txt: Copied from LayoutTests/platform/mac/css3/selectors3/xhtml/css3-modsel-18-expected.txt.
  • platform/mac-mojave/css3/selectors3/xml/css3-modsel-18-expected.txt: Copied from LayoutTests/platform/mac/css3/selectors3/xml/css3-modsel-18-expected.txt.
  • platform/mac-mojave/fast/block/basic/001-expected.txt: Copied from LayoutTests/platform/mac/fast/block/basic/001-expected.txt.
  • platform/mac-mojave/fast/css/css3-nth-child-expected.txt: Copied from LayoutTests/platform/mac/fast/css/css3-nth-child-expected.txt.
  • platform/mac-mojave/fast/dom/34176-expected.txt: Copied from LayoutTests/platform/mac/fast/dom/34176-expected.txt.
  • platform/mac-mojave/fast/dom/clone-node-dynamic-style-expected.txt: Copied from LayoutTests/platform/mac/fast/dom/clone-node-dynamic-style-expected.txt.
  • platform/mac-mojave/fast/forms/plaintext-mode-2-expected.txt: Copied from LayoutTests/platform/mac/fast/forms/plaintext-mode-2-expected.txt.
  • platform/mac-mojave/fast/invalid/003-expected.txt: Copied from LayoutTests/platform/mac/fast/invalid/003-expected.txt.
  • platform/mac-mojave/fast/invalid/004-expected.txt: Copied from LayoutTests/platform/mac/fast/invalid/004-expected.txt.
  • platform/mac-mojave/fast/invalid/nestedh3s-expected.txt: Copied from LayoutTests/platform/mac/fast/invalid/nestedh3s-expected.txt.
  • platform/mac-mojave/fast/selectors/018-expected.txt: Copied from LayoutTests/platform/mac/fast/selectors/018-expected.txt.
  • platform/mac-mojave/fast/table/frame-and-rules-expected.txt: Copied from LayoutTests/platform/mac/fast/table/frame-and-rules-expected.txt.
  • platform/mac-mojave/fast/text/atsui-multiple-renderers-expected.txt: Copied from LayoutTests/platform/mac/fast/text/atsui-multiple-renderers-expected.txt.
  • platform/mac-mojave/fast/text/bidi-embedding-pop-and-push-same-expected.txt: Copied from LayoutTests/platform/mac/fast/text/bidi-embedding-pop-and-push-same-expected.txt.
  • platform/mac-mojave/fast/text/font-weights-expected.txt: Copied from LayoutTests/platform/mac/fast/text/font-weights-expected.txt.
  • platform/mac-mojave/fast/text/font-weights-zh-expected.txt: Copied from LayoutTests/platform/mac/fast/text/font-weights-zh-expected.txt.
  • platform/mac-mojave/svg/W3C-SVG-1.1/animate-elem-46-t-expected.txt: Copied from LayoutTests/platform/mac/svg/W3C-SVG-1.1/animate-elem-46-t-expected.txt.
  • platform/mac-mojave/svg/W3C-SVG-1.1/struct-use-01-t-expected.txt: Copied from LayoutTests/platform/mac/svg/W3C-SVG-1.1/struct-use-01-t-expected.txt.
  • platform/mac-mojave/svg/batik/text/textStyles-expected.txt: Copied from LayoutTests/platform/mac/svg/batik/text/textStyles-expected.txt.
  • platform/mac-mojave/tables/mozilla/other/wa_table_thtd_rowspan-expected.txt: Copied from LayoutTests/platform/mac/tables/mozilla/other/wa_table_thtd_rowspan-expected.txt.
  • platform/mac-mojave/tables/mozilla/other/wa_table_tr_align-expected.txt: Copied from LayoutTests/platform/mac/tables/mozilla/other/wa_table_tr_align-expected.txt.
  • platform/mac/css1/basic/inheritance-expected.txt:
  • platform/mac/css2.1/t0602-c13-inh-underlin-00-e-expected.txt:
  • platform/mac/css2.1/t0805-c5522-brdr-02-e-expected.txt:
  • platform/mac/css3/selectors3/html/css3-modsel-18-expected.txt:
  • platform/mac/css3/selectors3/xhtml/css3-modsel-18-expected.txt:
  • platform/mac/css3/selectors3/xml/css3-modsel-18-expected.txt:
  • platform/mac/fast/block/basic/001-expected.txt:
  • platform/mac/fast/css/css3-nth-child-expected.txt:
  • platform/mac/fast/dom/34176-expected.txt:
  • platform/mac/fast/dom/clone-node-dynamic-style-expected.txt:
  • platform/mac/fast/forms/plaintext-mode-2-expected.txt:
  • platform/mac/fast/invalid/003-expected.txt:
  • platform/mac/fast/invalid/004-expected.txt:
  • platform/mac/fast/invalid/nestedh3s-expected.txt:
  • platform/mac/fast/selectors/018-expected.txt:
  • platform/mac/fast/table/frame-and-rules-expected.txt:
  • platform/mac/fast/text/atsui-multiple-renderers-expected.txt:
  • platform/mac/fast/text/bidi-embedding-pop-and-push-same-expected.txt:
  • platform/mac/fast/text/font-weights-expected.txt:
  • platform/mac/fast/text/font-weights-zh-expected.txt:
  • platform/mac/svg/W3C-SVG-1.1/animate-elem-46-t-expected.txt:
  • platform/mac/svg/W3C-SVG-1.1/struct-use-01-t-expected.txt:
  • platform/mac/svg/batik/text/textStyles-expected.txt:
  • platform/mac/tables/mozilla/other/wa_table_thtd_rowspan-expected.txt:
  • platform/mac/tables/mozilla/other/wa_table_tr_align-expected.txt:

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

4:58 PM Changeset in webkit [248643] by Ryan Haddad
  • 2 edits in branches/safari-608-branch/Tools

Cherry-pick r248496. rdar://problem/54280310

KeyboardInputTests.CaretSelectionRectAfterRestoringFirstResponder API tests time out on iPad
https://bugs.webkit.org/show_bug.cgi?id=200604
<rdar://problem/51273130>

Reviewed by Megan Gardner.

Tweak some API tests so that they work on iPad simulator. These tests checked that the final caret rect was
{{16, 13}, {2, 15}}; however, this is only correct behavior on iPhone, where we will scale the page so that the
focused element's font size is legible. Note that when the page is scaled, we scale the height but not the
width of the caret, which is why the width of the caret (in content coordinates) decreases while the height
remains the same.

We don't have the same behavior on iPad, so the expected caret rect is {{16, 13}, {3, 15}}, which is equal to
the caret rect at initial scale 1.

  • TestWebKitAPI/Tests/ios/KeyboardInputTestsIOS.mm:

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

4:31 PM Changeset in webkit [248642] by mark.lam@apple.com
  • 9 edits in trunk/Source/JavaScriptCore

Add phase, block, and node numbers to left margin of DFG graph dumps.
https://bugs.webkit.org/show_bug.cgi?id=200693

Reviewed by Saam Barati.

When scrolling through the DFG graph dumps, it's easy to get lost as to which phase
or block one is looking at, especially if the blocks are long. This patch adds
node index, block number, and phase number on the left margin of the dumps.
Here's a sample:

53: %Bd:Function = 0x1079fd960:[Function, {}, NonArray, Proto:0x1079d8000, Leaf]
53: %Bf:Function = 0x1079b0700:[Function, {name:100, prototype:101, length:102, stackTraceLimit:103}, NonArray, Proto:0x1079d8000, Leaf]
53: %Bj:Function = 0x1079fd5e0:[Function, {name:100, length:101, toString:102, apply:103, call:104, bind:105, Symbol.hasInstance:106, caller:107, arguments:108, constructor:109}, NonArray, Proto:0x1079c0000, Leaf]
53: %CV:JSGlobalLexicalEnvironment = 0x1079fd6c0:[JSGlobalLexicalEnvironment, {}, NonArray, Leaf]

53: Phase liveness analysis changed the IR.

54: Beginning DFG phase OSR availability analysis.
54: Before OSR availability analysis:

54: DFG for foo#DXMNag:[0x1079a4850->0x1079a4130->0x1079c7600, DFGFunctionCall, 204 (NeverInline)]:
54: Fixpoint state: FixpointConverged; Form: SSA; Unification state: GloballyUnified; Ref count state: ExactRefCount
54: Argument formats for entrypoint index: 0 : FlushedJSValue, FlushedCell, FlushedJSValue

0 54: Block #0 (bc#0): (OSR target)
0 54: Execution count: 1.000000
0 54: Predecessors:
0 54: Successors:
0 54: Dominated by: #0
0 54: Dominates: #0
0 54: Dominance Frontier:
0 54: Iterated Dominance Frontier:
0 54: Backwards dominates by: #root #0
0 54: Backwards dominates: #0
0 54: Control equivalent to: #0
0 54: States: StructuresAreWatched
0 54: Live:
0 54: Values

0 0 54: 53:< 1:-> JSConstant(JS|UseAsOther, Other, Null, bc#0, ExitValid)
1 0 54: 64:< 2:-> JSConstant(JS|UseAsOther, NonBoolInt32, Int32: 10, bc#0, ExitValid)
2 0 54: 3:< 5:-> JSConstant(JS|PureInt, Other, Undefined, bc#0, ExitValid)
3 0 54: 32:< 1:-> JSConstant(JS|UseAsOther, Bool, False, bc#0, ExitValid)
4 0 54: 19:< 2:-> JSConstant(JS|UseAsOther, OtherObj, Weak:Object: 0x1079d4000 with butterfly 0x0 (Structure %CV:JSGlobalLexicalEnvironment), StructureID: 31423, bc#0, ExitValid)

The numbers in the left margin before the ':' are node index (i.e. the index of the
node in the block, not to be confused with node->index() which is the node ID), block
number, and phase number respectively. Now, we can scroll thru the dumps quickly
and tell at a glance when we've scrolled passed the end of a phase, or block.
These sets of numbers can also serve as a positional marker that we can search for
to return to a node in the dump after scrolling away.

Currently, these numbers are only added to the DFG part. The FTL (from lowering
to B3 onwards) does not have this feature yet.

  • dfg/DFGDesiredWatchpoints.cpp:

(JSC::DFG::DesiredWatchpoints::dumpInContext const):

  • dfg/DFGDesiredWatchpoints.h:
  • dfg/DFGGraph.cpp:

(JSC::DFG::Graph::dumpCodeOrigin):
(JSC::DFG::Graph::dump):
(JSC::DFG::Graph::dumpBlockHeader):
(JSC::DFG::Prefix::dump const):

  • dfg/DFGGraph.h:

(JSC::DFG::Prefix::Prefix):
(JSC::DFG::Prefix::clearBlockIndex):
(JSC::DFG::Prefix::clearNodeIndex):
(JSC::DFG::Prefix::enable):
(JSC::DFG::Prefix::disable):
(JSC::DFG::Graph::prefix):
(JSC::DFG::Graph::nextPhase):

  • dfg/DFGPhase.cpp:

(JSC::DFG::Phase::beginPhase):

  • dfg/DFGPhase.h:

(JSC::DFG::runAndLog):

  • dfg/DFGPlan.cpp:

(JSC::DFG::Plan::compileInThreadImpl):

  • dfg/DFGValueRepReductionPhase.cpp:

(JSC::DFG::ValueRepReductionPhase::convertValueRepsToDouble):

4:03 PM Changeset in webkit [248641] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[ContentChangeObserver] adjustStateAndNotifyContentChangeIfNeeded should check isObservationTimeWindowActive()
https://bugs.webkit.org/show_bug.cgi?id=200687
<rdar://problem/54271221>

Reviewed by Simon Fraser.

Move the check to adjustStateAndNotifyContentChangeIfNeeded.

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::adjustObservedState):

3:34 PM Changeset in webkit [248640] by wilander@apple.com
  • 38 edits
    4 adds in trunk

Resource Load Statistics: Switch NSURLSession on top navigation to prevalent resource with user interaction
https://bugs.webkit.org/show_bug.cgi?id=200642
<rdar://problem/53962073>

Reviewed by Alex Christensen.

Source/WebCore:

Tests: http/tests/resourceLoadStatistics/do-not-switch-session-on-navigation-to-prevalent-without-interaction.html

http/tests/resourceLoadStatistics/switch-session-on-navigation-to-prevalent-with-interaction.html

This patch splits m_registrableDomainsToBlockCookieFor in WebCore:NetworkStorageSession into:

  • m_registrableDomainsToBlockAndDeleteCookiesFor
  • m_registrableDomainsToBlockButKeepCookiesFor

... to support different network load policies based on this distinction.

  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setITPSessionSwitchingEnabled):
(WebCore::RuntimeEnabledFeatures::itpSessionSwitchingEnabled const):

  • page/Settings.yaml:
  • platform/network/NetworkStorageSession.cpp:

(WebCore::NetworkStorageSession::shouldBlockThirdPartyCookies const):
(WebCore::NetworkStorageSession::shouldBlockThirdPartyCookiesButKeepFirstPartyCookiesFor const):
(WebCore::NetworkStorageSession::setPrevalentDomainsToBlockAndDeleteCookiesFor):
(WebCore::NetworkStorageSession::setPrevalentDomainsToBlockButKeepCookiesFor):
(WebCore::NetworkStorageSession::removePrevalentDomains):
(WebCore::NetworkStorageSession::setPrevalentDomainsToBlockCookiesFor): Deleted.

  • platform/network/NetworkStorageSession.h:

Source/WebKit:

Since prevalent resources with user interaction get to keep their cookies and website
data, we should use a different NSURLSessions for when they are first-party websites
and have access to that data. This patch achieves that.

The WebKit::NetworkDataTaskCocoa constructor now checks with the network storage session
if the first party for this load should be isolated. The category for which this is true
is checked in the new function
WebCore:NetworkStorageSession::shouldBlockThirdPartyCookiesButKeepFirstPartyCookiesFor()
which in turn is backed by a new split of m_registrableDomainsToBlockCookieFor into:

  • m_registrableDomainsToBlockAndDeleteCookiesFor
  • m_registrableDomainsToBlockButKeepCookiesFor

... in WebCore:NetworkStorageSession.

Non-isolated sessions are now picked up through the convenience function
WebKit::NetworkSessionCocoa::session() whereas isolated sessions are created lazily and
picked up through WebKit::NetworkSessionCocoa::isolatedSession().

The number of isolated NSURLSessions in memory is capped to 10. When the cap is hit,
the session that's been unused the longest is aged out.

The C API changes are test infrastructure.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::clear):
(WebKit::ResourceLoadStatisticsDatabaseStore::domainsToBlockAndDeleteCookiesFor const):
(WebKit::ResourceLoadStatisticsDatabaseStore::domainsToBlockButKeepCookiesFor const):
(WebKit::ResourceLoadStatisticsDatabaseStore::updateCookieBlocking):
(WebKit::ResourceLoadStatisticsDatabaseStore::domainsToBlock const): Deleted.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.cpp:

(WebKit::ResourceLoadStatisticsMemoryStore::clear):
(WebKit::ResourceLoadStatisticsMemoryStore::updateCookieBlocking):

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.cpp:

(WebKit::ResourceLoadStatisticsStore::updateCookieBlockingForDomains):
(WebKit::ResourceLoadStatisticsStore::debugLogDomainsInBatches):

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::callUpdatePrevalentDomainsToBlockCookiesForHandler):
(WebKit::WebResourceLoadStatisticsStore::scheduleCookieBlockingUpdateForDomains): Deleted.
(WebKit::WebResourceLoadStatisticsStore::scheduleClearBlockingStateForDomains): Deleted.

Dead code.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:

(WebKit::RegistrableDomainsToBlockCookiesFor::isolatedCopy const):

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::updatePrevalentDomainsToBlockCookiesFor):
(WebKit::NetworkProcess::scheduleClearInMemoryAndPersistent):
(WebKit::NetworkProcess::hasIsolatedSession const):

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

(WebKit::NetworkSession::shouldIsolateSessionsForPrevalentTopFrames const):
(WebKit::NetworkSession::hasIsolatedSession const):
(WebKit::NetworkSession::clearIsolatedSessions):

  • NetworkProcess/NetworkSessionCreationParameters.cpp:

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

  • NetworkProcess/NetworkSessionCreationParameters.h:
  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):

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

(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):
(WebKit::NetworkSessionCocoa::session):
(WebKit::NetworkSessionCocoa::isolatedSession):
(WebKit::NetworkSessionCocoa::hasIsolatedSession const):
(WebKit::NetworkSessionCocoa::clearIsolatedSessions):
(WebKit::NetworkSessionCocoa::invalidateAndCancel):
(WebKit::NetworkSessionCocoa::clearCredentials):

  • Shared/WebPreferences.yaml:
  • UIProcess/API/C/WKWebsiteDataStoreRef.cpp:

(WKWebsiteDataStoreStatisticsHasIsolatedSession):

  • UIProcess/API/C/WKWebsiteDataStoreRef.h:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::hasIsolatedSession):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::WebsiteDataStore::parameters):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::hasLocalStorageForTesting const):
(WebKit::WebsiteDataStore::hasIsolatedSessionForTesting const):

  • UIProcess/WebsiteData/WebsiteDataStore.h:

Tools:

This patch adds test infrastructure to query whether an origin has an
isolated NSURLSession or not.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::hasStatisticsIsolatedSession):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::hasStatisticsIsolatedSession):

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

LayoutTests:

  • http/tests/resourceLoadStatistics/do-not-switch-session-on-navigation-to-prevalent-without-interaction-expected.txt: Added.
  • http/tests/resourceLoadStatistics/do-not-switch-session-on-navigation-to-prevalent-without-interaction.html: Added.
  • http/tests/resourceLoadStatistics/switch-session-on-navigation-to-prevalent-with-interaction-expected.txt: Added.
  • http/tests/resourceLoadStatistics/switch-session-on-navigation-to-prevalent-with-interaction.html: Added.
3:30 PM Changeset in webkit [248639] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

[WebAuthN] Enable LocalAuthenticator for macOS
https://bugs.webkit.org/show_bug.cgi?id=182772

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations: Skip tests that are only expected to run on internal bots.
3:30 PM Changeset in webkit [248638] by Ryan Haddad
  • 3 edits in trunk/LayoutTests

Unreviewed test gardening, land test expectations for rdar://49790831.

  • platform/ios-12/TestExpectations:
  • platform/ios/TestExpectations:
3:14 PM Changeset in webkit [248637] by Joseph Pecoraro
  • 2 edits in trunk/Source/WebInspectorUI

Uncaught Exception: content.isJSON is not a function selecting image resource
https://bugs.webkit.org/show_bug.cgi?id=200680

Reviewed by Devin Rousso.

  • UserInterface/Views/ResourceClusterContentView.js:

(WI.ResourceClusterContentView.prototype._canUseJSONContentViewForContent):
Protect against non-string data, such as Blob response content.

3:13 PM Changeset in webkit [248636] by zhifei_fang@apple.com
  • 2 edits in trunk/Tools

Update my status in contributors.json to committer.

Reviewed by Unreviewed

  • Scripts/webkitpy/common/config/contributors.json:
3:12 PM Changeset in webkit [248635] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[ContentChangeObserver] setShouldObserveDOMTimerScheduling and setShouldObserveTransitions are always called in pairs.
https://bugs.webkit.org/show_bug.cgi?id=200685
<rdar://problem/54269778>

Reviewed by Simon Fraser.

Let's merge these 2 functions.

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::stopObservingPendingActivities):
(WebCore::ContentChangeObserver::adjustObservedState):

  • page/ios/ContentChangeObserver.h:

(WebCore::ContentChangeObserver::isObservingDOMTimerScheduling const):
(WebCore::ContentChangeObserver::isObservingContentChanges const):
(WebCore::ContentChangeObserver::setShouldObserveDOMTimerSchedulingAndTransitions):
(WebCore::ContentChangeObserver::setShouldObserveDOMTimerScheduling): Deleted.
(WebCore::ContentChangeObserver::setShouldObserveTransitions): Deleted.

2:00 PM Changeset in webkit [248634] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Fix potential thread safety issue under WebResourceLoadStatisticsStore::hasHadUserInteraction()
https://bugs.webkit.org/show_bug.cgi?id=200688

Reviewed by Alex Christensen.

Fix potential thread safety issue under WebResourceLoadStatisticsStore::hasHadUserInteraction().
It passes a RegistrableDomain to another thread without isolated copying it.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::hasHadUserInteraction):

1:58 PM Changeset in webkit [248633] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Fix potential thread safety issue under StorageManager::getSessionStorageOrigins()
https://bugs.webkit.org/show_bug.cgi?id=200684

Reviewed by Geoffrey Garen.

Fix potential thread safety issue under StorageManager::getSessionStorageOrigins(). The origins are being
passed from the background queue to the main thread without isolated copy.

  • NetworkProcess/WebStorage/StorageManager.cpp:

(WebKit::StorageManager::getSessionStorageOrigins):

1:55 PM Changeset in webkit [248632] by Alan Coon
  • 3 edits in branches/safari-608-branch/Source/WebKit

Apply patch. rdar://problem/54236234

1:43 PM Changeset in webkit [248631] by jiewen_tan@apple.com
  • 6 edits
    1 copy
    4 moves in trunk/Source/WebKit

[WebAuthn] Make CtapHidAuthenticator/U2fHidAuthenticator to CtapAuthenticator/U2fAuthenticator
https://bugs.webkit.org/show_bug.cgi?id=191527
<rdar://problem/54237146>

Reviewed by Chris Dumez.

This patch makes an ABC CtapDriver, which services as an abstract interface for CtapAuthenticator/U2fAuthenticator to talk to
the actual object that implement the specific CTAP protocol that mananges communications over different transports, for example,
CtapHidDriver, such that CtapAuthenticator/U2fAuthenticator can be shared across different transports.

This patch also renames CtapHidAuthenticator/U2fHidAuthenticator to CtapAuthenticator/U2fAuthenticator correspondingly.

  • Sources.txt:
  • UIProcess/WebAuthentication/Cocoa/HidService.mm:

(WebKit::HidService::continueAddDeviceAfterGetInfo):

  • UIProcess/WebAuthentication/fido/CtapAuthenticator.cpp: Renamed from Source/WebKit/UIProcess/WebAuthentication/fido/CtapHidAuthenticator.cpp.

(WebKit::CtapAuthenticator::CtapAuthenticator):
(WebKit::CtapAuthenticator::makeCredential):
(WebKit::CtapAuthenticator::continueMakeCredentialAfterResponseReceived const):
(WebKit::CtapAuthenticator::getAssertion):
(WebKit::CtapAuthenticator::continueGetAssertionAfterResponseReceived):
(WebKit::CtapAuthenticator::tryDowngrade):

  • UIProcess/WebAuthentication/fido/CtapAuthenticator.h: Copied from Source/WebKit/UIProcess/WebAuthentication/fido/CtapHidAuthenticator.h.
  • UIProcess/WebAuthentication/fido/CtapDriver.h: Renamed from Source/WebKit/UIProcess/WebAuthentication/fido/CtapHidAuthenticator.h.
  • UIProcess/WebAuthentication/fido/CtapHidDriver.h:

(WebKit::CtapHidDriver::setProtocol):

  • UIProcess/WebAuthentication/fido/U2fAuthenticator.cpp: Renamed from Source/WebKit/UIProcess/WebAuthentication/fido/U2fHidAuthenticator.cpp.

(WebKit::U2fAuthenticator::U2fAuthenticator):
(WebKit::U2fAuthenticator::makeCredential):
(WebKit::U2fAuthenticator::checkExcludeList):
(WebKit::U2fAuthenticator::issueRegisterCommand):
(WebKit::U2fAuthenticator::getAssertion):
(WebKit::U2fAuthenticator::issueSignCommand):
(WebKit::U2fAuthenticator::issueNewCommand):
(WebKit::U2fAuthenticator::issueCommand):
(WebKit::U2fAuthenticator::responseReceived):
(WebKit::U2fAuthenticator::continueRegisterCommandAfterResponseReceived):
(WebKit::U2fAuthenticator::continueCheckOnlyCommandAfterResponseReceived):
(WebKit::U2fAuthenticator::continueBogusCommandAfterResponseReceived):
(WebKit::U2fAuthenticator::continueSignCommandAfterResponseReceived):

  • UIProcess/WebAuthentication/fido/U2fAuthenticator.h: Renamed from Source/WebKit/UIProcess/WebAuthentication/fido/U2fHidAuthenticator.h.
  • WebKit.xcodeproj/project.pbxproj:
1:26 PM Changeset in webkit [248630] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[ContentChangeObserver] Scope events in adjustObservedState
https://bugs.webkit.org/show_bug.cgi?id=200679
<rdar://problem/54266172>

Reviewed by Simon Fraser.

This is in preparation for simplifying adjustObservedState.

  • page/ios/ContentChangeObserver.cpp:

(WebCore::ContentChangeObserver::didFinishTransition):
(WebCore::ContentChangeObserver::adjustObservedState):

  • page/ios/ContentChangeObserver.h:
1:08 PM Changeset in webkit [248629] by Alan Coon
  • 3 edits in branches/safari-608-branch/Source/WebCore

Cherry-pick r248499. rdar://problem/54237800

Can’t sort videos on a YouTube channel page on iPad
https://bugs.webkit.org/show_bug.cgi?id=200573
<rdar://problem/53415195>

Reviewed by Darin Adler.

Add a quirk to make touch events non-cancelable (preventDefault() does nothing).

  • page/Quirks.cpp: (WebCore::Quirks::shouldMakeTouchEventNonCancelableForTarget const):
  • page/Quirks.h:

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

1:08 PM Changeset in webkit [248628] by Alan Coon
  • 7 edits in branches/safari-608-branch/Source

Cherry-pick r248440. rdar://problem/54237795

[Mac] Use the PID of the WebContent process when issuing local file read sandbox extensions
https://bugs.webkit.org/show_bug.cgi?id=200543
Source/WebKit:

Reviewed by Brent Fulgham.

Adopt SPI to issue a process-specific sandbox extension for local file read, passing it the process
identifier of the WebContent process.

  • Shared/Cocoa/SandboxExtensionCocoa.mm: (WebKit::SandboxExtensionImpl::sandboxExtensionForType): (WebKit::SandboxExtension::createHandleForReadByPid):
  • Shared/SandboxExtension.h:
  • UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):

Source/WTF:

<rdar://problem/49394015>

Reviewed by Brent Fulgham.

Add new SPI.

  • wtf/Platform.h:
  • wtf/spi/darwin/SandboxSPI.h:

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

1:01 PM Changeset in webkit [248627] by Alan Coon
  • 4 edits in branches/safari-608-branch

Cherry-pick r248548. rdar://problem/54237813

Fix Crash in Mail Search
https://bugs.webkit.org/show_bug.cgi?id=200589
Source/WebKit:

<rdar://problem/53666720>

Reviewed by Tim Horton.

If we search in Mail backwards first, for AppKit reasons
we get a -1 for the index of the found item.
Do not try and insert data in this case.

  • UIProcess/mac/WKTextFinderClient.mm:

Tools:

Reviewed by Tim Horton.

If you search backwards first in mail, we would crash,
this tests that codepath.

  • TestWebKitAPI/Tests/WebKitCocoa/FindInPage.mm: (TEST):

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

1:01 PM Changeset in webkit [248626] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248543. rdar://problem/54237801

Clear m_sessionStorageNamespaces on the background thread
https://bugs.webkit.org/show_bug.cgi?id=200631
<rdar://problem/54149638>

Reviewed by Chris Dumez.

Network process receives messages about web page state from web process and destroys sessionStorageNamespace if
needed. It also receives messages about session state from UI process and destroys StorageManager, which owns
SessionStorageNamespaces, if needed. Because of the race in receiving the messages from different processes,
network process may decide to destroy StorageManager before destroying all SessionStorageNamespaces, and
SessionStorageNamespaces are destroyed with StorageManager on the main thread.

  • NetworkProcess/WebStorage/StorageManager.cpp: (WebKit::StorageManager::waitUntilTasksFinished):

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

1:01 PM Changeset in webkit [248625] by Alan Coon
  • 7 edits in branches/safari-608-branch

Cherry-pick r248513. rdar://problem/54237806

Accessibility client cannot navigate to internal links targets on iOS.
https://bugs.webkit.org/show_bug.cgi?id=200559
<rdar://problem/45242534>

Patch by Andres Gonzalez <Andres Gonzalez> on 2019-08-10
Reviewed by Zalan Bujtas.

Source/WebCore:

The cause of the problem on iOS is that AccessibilityObject::firstAccessibleObjectFromNode
used in AccessibilityRenderObject::linkedUIElements may return an object
that is ignored by accessibility clients on iOS, and thus the client
would not track the target of an internal link. This change ensures that
accessibilityLinkedElement will return a valid accessibility element to
the client, if it is exists.

  • accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::firstAccessibleObjectFromNode): (WebCore::firstAccessibleObjectFromNode):
  • accessibility/AccessibilityObject.h:
  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm: (-[WebAccessibilityObjectWrapper accessibilityLinkedElement]):

LayoutTests:

Extneded this test to not only check that internal links expose their
target, but also that the target is an accessible element. Added a
second test case where the target is contained in a grouping element.

  • accessibility/ios-simulator/internal-link-expected.txt:
  • accessibility/ios-simulator/internal-link.html:

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

1:01 PM Changeset in webkit [248624] by Alan Coon
  • 6 edits in branches/safari-608-branch

Cherry-pick r248166. rdar://problem/54237837

[macOS 10.15] Image dragged from Safari does not appear in Notes
https://bugs.webkit.org/show_bug.cgi?id=188490
<rdar://problem/39462717>

Reviewed by Andy Estes.

Source/WebKit:

Removes some logic that clears out the cached promised drag image in the UI process when WebKit is asked to
provide TIFF image data. This prevents the drop destination from asking for promised image data, if anything
else (e.g. the system) also asks the web view to provide the same data. Additionally, this logic didn't
previously guarantee that the promised image would be cleared anyways, since it is dependent on the drop target
actually requesting the promised image in order to perform the cleanup.

In lieu of clearing the promised drag image when it's requested, we instead clear it out upon mainframe
navigation, in PageClientImpl::didCommitLoadForMainFrame.

Test: DragAndDropTests.MultiplePromisedImageDataRequests

  • UIProcess/Cocoa/WebViewImpl.h:
  • UIProcess/Cocoa/WebViewImpl.mm: (WebKit::WebViewImpl::clearPromisedDragImage): (WebKit::WebViewImpl::pasteboardChangedOwner): (WebKit::WebViewImpl::provideDataForPasteboard):

Fix the bug by not immediately clearing out the promised drag image.

  • UIProcess/mac/PageClientImplMac.mm: (WebKit::PageClientImpl::didCommitLoadForMainFrame):

Tools:

Add a test to verify that promised image data can be delivered to multiple pasteboards when performing a drop.

  • TestWebKitAPI/Tests/mac/DragAndDropTestsMac.mm:

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

1:01 PM Changeset in webkit [248623] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248550. rdar://problem/54237677

Contextual menu Hide and Show Link Previews should not have a symbol
https://bugs.webkit.org/show_bug.cgi?id=200645
<rdar://problem/54129647>

Reviewed by Wenson Hsieh.

Don't use an image on the UIMenuItem.

  • UIProcess/API/Cocoa/_WKElementAction.mm: (+[_WKElementAction imageForElementActionType:]): Return nil for Show/Hide Link Previews.

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

1:01 PM Changeset in webkit [248622] by Alan Coon
  • 4 edits in branches/safari-608-branch

Cherry-pick r248541. rdar://problem/54237768

[iPadOS] Web pages sometimes load at half width in Safari
https://bugs.webkit.org/show_bug.cgi?id=200624
<rdar://problem/52694257>

Reviewed by Simon Fraser.

Source/WebKit:

Whenever WKWebView's size changes, it normally notifies the web …
setViewportConfigurationViewLayoutSize, which remembers this view layout size using a member variable, m_viewportConfigurationViewLayoutSize. Later, m_viewportConfigurationViewLayoutSize is consulted as a part of constructing the creation parameters used to set up a new page.

However, during animated resize, WKWebView avoids these calls to setViewportConfigurationViewLayoutSize via the
dynamic viewport update mode check in -[WKWebView _frameOrBoundsChanged]. Instead, the new view layout size is
pushed to the web process by calling WebPageProxy::dynamicViewportSizeUpdate.

Since dynamicViewportSizeUpdate doesn't update m_viewportConfigurationViewLayoutSize, the next
WebPageCreationParameters that are created with this WebPageProxy (e.g. after a process swap, or after
reloading, if the process was terminated) will use the size of the WKWebView prior to the most recent animated
resize.

To fix the bug, we simply make sure that m_viewportConfigurationViewLayoutSize is updated in the dynamic
viewport size update (i.e. animated resize) case as well.

Test: WebKit.CreateWebPageAfterAnimatedResize

  • UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::dynamicViewportSizeUpdate):

Tools:

Add an API test to verify that after performing an animated resize and killing the web process, the subsequent
web page is created using the post-animated-resize web view dimensions, rather than the original layout
dimensions.

  • TestWebKitAPI/Tests/WebKitCocoa/AnimatedResize.mm:

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

1:01 PM Changeset in webkit [248621] by Alan Coon
  • 6 edits
    3 adds in branches/safari-608-branch

Cherry-pick r248514. rdar://problem/54236213

REGRESSION (r245974): Missing content on habitburger.com, amazon.com
https://bugs.webkit.org/show_bug.cgi?id=200618
rdar://problem/53920224

Reviewed by Zalan Bujtas.

Source/WebCore:

In r245974 TileController::adjustTileCoverageRect() started to intersect the coverage
rect with the bounds of the layer, which is wrong because this coverage rect is passed down
to descendant layers, and they may project outside the bounds of this tiled layer.

This caused missing dropdowns on amazon.com, and a missing menu on habitburger.com on iPhone.

The fix is to just not do the intersection with the bounds. TileGrid::getTileIndexRangeForRect()
already ensures that we never make tiles outside the bounds of a TileController.

Test: compositing/backing/layer-outside-tiled-parent.html

  • platform/graphics/ca/TileController.cpp: (WebCore::TileController::adjustTileCoverageRect):
  • platform/graphics/ca/TileGrid.cpp: (WebCore::TileGrid::ensureTilesForRect):

LayoutTests:

  • compositing/backing/layer-outside-tiled-parent-expected.txt: Added.
  • compositing/backing/layer-outside-tiled-parent.html: Added.
  • platform/ios-wk2/compositing/backing/layer-outside-tiled-parent-expected.txt: Added.
  • tiled-drawing/tile-coverage-iframe-to-zero-coverage-expected.txt:
  • tiled-drawing/tiled-backing-in-window-expected.txt:

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

1:01 PM Changeset in webkit [248620] by Alan Coon
  • 5 edits in branches/safari-608-branch

Cherry-pick r248487. rdar://problem/54237679

[iOS 13] Google Docs/Slides/Sheets: paste often doesn't work and sometimes produces an error
https://bugs.webkit.org/show_bug.cgi?id=200591
<rdar://problem/54102238>

Reviewed by Ryosuke Niwa and Tim Horton.

Source/WebKit:

Adopts UIKit SPI to avoid incrementing the general pasteboard's change count whenever an editable element is
focused. This is due to how, in iOS 13, UIKit temporarily writes an image to the pasteboard when showing the
keyboard, to determine whether or not to show the Memojis in the input view.

This causes UIPasteboard's changeCount to increment twice due to adding and then removing the image, which means
that the changeCount sanity checks in the web process will race against the pasteboard gaining and then losing
this temporary image.

Instead, the new -supportsImagePaste SPI may be used to short-circuit this step, and avoid updating the
changeCount when UIKeyboardImpl's delegate changes.

  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView supportsImagePaste]):

Tools:

Add a new API test to exercise -supportsImagePaste.

  • TestWebKitAPI/Tests/ios/KeyboardInputTestsIOS.mm: (TestWebKitAPI::TEST):
  • TestWebKitAPI/ios/UIKitSPI.h:

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

1:01 PM Changeset in webkit [248619] by Alan Coon
  • 6 edits
    6 adds in branches/safari-608-branch

Cherry-pick r248433. rdar://problem/54237689

[iOS 13] Taps that interrupt momentum scrolling are recognized as clicks
https://bugs.webkit.org/show_bug.cgi?id=200516
<rdar://problem/53889373>

Reviewed by Tim Horton.

Source/WebKit:

After <https://trac.webkit.org/r247656>, the -tracksImmediatelyWhileDecelerating property of WKScrollView and
WKChildScrollView is set to NO. This means that if a user interacts with the page while the scroll view is
decelerating (e.g. after momentum scrolling), the pan gesture recognizer will not be immediately recognized.
This gives other gesture recognizers, such as the synthetic click (single tap) gesture a chance to instead
recognize first. In this particular bug, this causes taps on the web view that are intended to only stop
momentum scrolling to instead activate clickable elements beneath the touch, such as links and buttons.

To mitigate this, we add some logic to prevent the click gesture recognizer from firing in the case where the
tap also causes the scroll view to decelerate. This heuristic is similar to the one introduced in r219310, which
has the same purpose of hiding gestures that stop momentum scrolling from the page, and also consults
-[UIScrollView _isInterruptingDeceleration].

Tests: fast/scrolling/ios/click-events-during-momentum-scroll-in-main-frame.html

fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow-after-tap-on-body.html
fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow.html

  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView gestureRecognizerShouldBegin:]):

Return NO in the case of the single tap gesture if the UIScrollView most recently touched by the single tap
gesture (or one of its enclosing scroll views, up to the main WKScrollView) is being interrupted while
decelerating.

  • UIProcess/ios/WKSyntheticTapGestureRecognizer.h:
  • UIProcess/ios/WKSyntheticTapGestureRecognizer.mm: (-[WKSyntheticTapGestureRecognizer reset]): (-[WKSyntheticTapGestureRecognizer touchesBegan:withEvent:]):

Teach WKSyntheticTapGestureRecognizer to keep track of the last WKScrollView that was touched, for later use in
-gestureRecognizerShouldBegin:. To do this, we keep a weak reference to the first UIScrollView we find in the
set of touches.

(-[WKSyntheticTapGestureRecognizer lastTouchedScrollView]):

LayoutTests:

Add new layout tests. See below for details.

  • fast/scrolling/ios/click-events-during-momentum-scroll-in-main-frame-expected.txt: Added.
  • fast/scrolling/ios/click-events-during-momentum-scroll-in-main-frame.html: Added.

Add a test to verify that interrupting scrolling in the main frame using a tap doesn't fire a click event.

  • fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow-after-tap-on-body-expected.txt: Added.
  • fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow-after-tap-on-body.html: Added.

Add a test to verify that after triggering momentum scrolling in a fast subscrollable region, tapping outside of
the scroller will still fire a click event.

  • fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow-expected.txt: Added.
  • fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow.html: Added.

Add a test to verify that interrupting scrolling in a fast subscrollable region using a tap doesn't fire a
click event.

  • resources/ui-helper.js: (window.UIHelper.dragFromPointToPoint): (window.UIHelper):

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

1:01 PM Changeset in webkit [248618] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248430. rdar://problem/54237652

Use "safari" glyph for "Show Link Previews" contextual menu
https://bugs.webkit.org/show_bug.cgi?id=200544
<rdar://problem/54087842>

Reviewed by Tim Horton.

Use the system image for the compass.

  • UIProcess/API/Cocoa/_WKElementAction.mm: (+[_WKElementAction imageForElementActionType:]):

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

1:01 PM Changeset in webkit [248617] by Alan Coon
  • 7 edits
    1 copy
    1 add
    2 deletes in branches/safari-608-branch

Cherry-pick r248338. rdar://problem/54237654

[iPadOS] slides.google.com: tapping near cursor in a slide title focuses the speaker notes
https://bugs.webkit.org/show_bug.cgi?id=200216

Reviewed by Wenson Hsieh.

Source/WebKit:

The bug was caused by a race condition between Google slides removing inputmode="none" from the hidden
content editable and updating the focused region upon receiving a pointerup event, which happens after
the Google slides had already updated its page layout & coordinates based on new visual viewport with
the software keyboard's boudning rect taken into account.

Delay bringing up the software keyboard for a inputmode change until all touches are released.

In the future, we could consider also delaying the software keyboard to be brought in general until
touchend / pointerup events are dispatched but this is rather risky since that could affact random
other websites while Google suites is the only major site to make use of inputmode="none".

This patch also reverts r243044, which was added for Google slides, since it's no longer needed and
interferes with this patch by adding another way to bring up the software keyboard.

Note: Adjusting touchend / pointerup coordinates while the keyboard is being brought up doesn't work
because the page had already updated the layout by then based on new visual viewport size.

Test: fast/forms/ios/inputmode-change-update-keyboard-after-pointerup.html

  • UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::handleTouchEventSynchronously): Call didReleaseAllTouchPoints when all touches are released. (WebKit::WebPageProxy::handleTouchEventAsynchronously): Ditto. (WebKit::WebPageProxy::handleTouchEvent): Ditto.
  • UIProcess/WebPageProxy.h: (WebKit::WebPageProxy::didReleaseAllTouchPoints): Added for non-iOS platforms. (WebKit::WebPageProxy::m_pendingInputModeChange): Added. Used when inputmode is changed while there is an on-going touch interaction.
  • UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::elementDidFocus): Clear m_pendingInputModeChange when a new element is focused. (WebKit::WebPageProxy::elementDidBlur): Ditto for bluring. (WebKit::WebPageProxy::focusedElementDidChangeInputMode): Don't bring up the software keyboard now if there are on-going touches by exiting early after setting m_pendingInputModeChange. (WebKit::WebPageProxy::didReleaseAllTouchPoints): Bring up the software keyboard if inputmode had changed from "none" to something else.
  • WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::dispatchTouchEvent): Removed the code added by r243044.

LayoutTests:

Added a new regression test and removed the one added for r243044.

  • fast/events/touch/ios/show-keyboard-after-preventing-touchstart-expected.txt: Removed.
  • fast/events/touch/ios/show-keyboard-after-preventing-touchstart.html: Removed.
  • fast/forms/ios/inputmode-change-update-keyboard-after-pointerup-expected.txt: Added.
  • fast/forms/ios/inputmode-change-update-keyboard-after-pointerup.html: Added.
  • fast/forms/ios/inputmode-change-update-keyboard.html: Fixed the test for manual testing.

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

1:01 PM Changeset in webkit [248616] by Alan Coon
  • 12 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248301. rdar://problem/54237793

Adopt -expectMinimumUpcomingSampleBufferPresentationTime:
https://bugs.webkit.org/show_bug.cgi?id=200457
<rdar://problem/53961130>

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/media-source/media-source-minimumupcomingpresentationtime.html

Adopt a new API vended by AVSampleBufferDisplayLayer, piped from SourceBuffer down
through SourceBufferPrivate to SourceBufferPrivateAVFObjC. This value should be
reset and updated when new samples are appended.

  • Modules/mediasource/SourceBuffer.cpp: (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): (WebCore::SourceBuffer::provideMediaData): (WebCore::SourceBuffer::updateMinimumUpcomingPresentationTime): (WebCore::SourceBuffer::resetMinimumUpcomingPresentationTime): (WebCore::SourceBuffer::minimumUpcomingPresentationTimeForTrackID): (WebCore::SourceBuffer::setMaximumQueueDepthForTrackID):
  • Modules/mediasource/SourceBuffer.h:
  • platform/graphics/SourceBufferPrivate.h: (WebCore::SourceBufferPrivate::canSetMinimumUpcomingPresentationTime const): (WebCore::SourceBufferPrivate::setMinimumUpcomingPresentationTime): (WebCore::SourceBufferPrivate::clearMinimumUpcomingPresentationTime): (WebCore::SourceBufferPrivate::enqueuedSamplesForTrackID): (WebCore::SourceBufferPrivate::minimumUpcomingPresentationTimeForTrackID): (WebCore::SourceBufferPrivate::setMaximumQueueDepthForTrackID):
  • platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
  • platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::canSetMinimumUpcomingPresentationTime const): (WebCore::SourceBufferPrivateAVFObjC::setMinimumUpcomingPresentationTime): (WebCore::SourceBufferPrivateAVFObjC::clearMinimumUpcomingPresentationTime):
  • platform/mock/mediasource/MockSourceBufferPrivate.cpp: (WebCore::MockSourceBufferPrivate::minimumUpcomingPresentationTimeForTrackID): (WebCore::MockSourceBufferPrivate::setMaximumQueueDepthForTrackID): (WebCore::MockSourceBufferPrivate::canSetMinimumUpcomingPresentationTime const): (WebCore::MockSourceBufferPrivate::setMinimumUpcomingPresentationTime): (WebCore::MockSourceBufferPrivate::clearMinimumUpcomingPresentationTime):
  • platform/mock/mediasource/MockSourceBufferPrivate.h:
  • testing/Internals.cpp: (WebCore::Internals::minimumUpcomingPresentationTimeForTrackID): (WebCore::Internals::setMaximumQueueDepthForTrackID):
  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

  • media/media-source/media-source-minimumupcomingpresentationtime-expected.txt: Added.
  • media/media-source/media-source-minimumupcomingpresentationtime.html: Added.

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

1:00 PM Changeset in webkit [248615] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebCore

Cherry-pick r248295. rdar://problem/54237762

REGRESSION: Cannot tap on any buttons on m.naver.com home screen on iPad
https://bugs.webkit.org/show_bug.cgi?id=200466

Reviewed by Zalan Bujtas.

The page calls preventDefault() for a mouse event generated by a site specific quirk.

  • page/Quirks.cpp: (WebCore::Quirks::shouldDispatchSimulatedMouseEvents const):

Disable the quirk for the "m." subdomain. This is a mobile site that don't need or expect them.

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

1:00 PM Changeset in webkit [248614] by Alan Coon
  • 4 edits
    6 adds in branches/safari-608-branch

Cherry-pick r248292. rdar://problem/54236220

[iPadOS] Unable to increase zoom level on Google using the Aa menu
https://bugs.webkit.org/show_bug.cgi?id=200453
<rdar://problem/52278579>

Reviewed by Tim Horton.

Source/WebCore:

Makes a couple of minor adjustments to how layout size scale factor is handled in ViewportConfiguration, to
address some scenarios in which adjusting WKWebView's _viewScale does not have any apparent effect on the page.
See changes below for more detail.

Tests: fast/viewport/ios/non-responsive-viewport-after-changing-view-scale.html

fast/viewport/ios/responsive-viewport-with-minimum-width-after-changing-view-scale.html

  • page/ViewportConfiguration.cpp: (WebCore::ViewportConfiguration::initialScaleFromSize const):

When the page is either zoomed in or zoomed out using _viewScale, let the specified initial scale take
precedence over the scale computed by fitting the content width to the view width, or the scale computed by
fitting the content height to the view height.

This avoids a scenario in which nothing happens when increasing view scale in a responsively designed web page
that has a fixed minimum width. Before this change, when computing the initial scale at a view scale that would
not allow the entire content width of the page to fit within the viewport, the new initial scale would remain
unchanged if the initial scale in the meta viewport is not also set to 1, because a new initial scale would be
computed in ViewportConfiguration::initialScaleFromSize to accomodate for the entire content width.

Our new behavior allows us to zoom into the page, even if doing so would cause horizontal scrolling.

(WebCore::ViewportConfiguration::updateConfiguration):

When the page is either zoomed in or zoomed out using _viewScale and the default viewport configuration has a
fixed width (e.g. on iPhone), then adjust the width of the default viewport configuration to account for the
_viewScale. For example, the default width of a viewport-less web page is 980px on iPhone; at a view scale of 2,
this would become 490px instead, and at 0.5 view scale, it would become 1960px.

This ensures that on iPhone, for web pages without a meta viewport, changing the view scale still changes the
layout and initial scale of the web page.

  • page/ViewportConfiguration.h: (WebCore::ViewportConfiguration::layoutSizeIsExplicitlyScaled const):

LayoutTests:

Adds a couple of layout tests (with device-specific expectations) to verify that the two scenarios targeted by
this change are fixed.

  • fast/viewport/ios/non-responsive-viewport-after-changing-view-scale-expected.txt: Added.
  • fast/viewport/ios/non-responsive-viewport-after-changing-view-scale.html: Added.

Verifies that, for a page with no viewport meta tag (where we fall back to a fixed 980px viewport on iPhone),
changing view scale still changes page scale and window size.

  • fast/viewport/ios/responsive-viewport-with-minimum-width-after-changing-view-scale-expected.txt: Added.
  • fast/viewport/ios/responsive-viewport-with-minimum-width-after-changing-view-scale.html: Added.

Verifies that, for a page with a responsive meta viewport tag containing a fixed-width element that forces a
minimum width for the page, setting the view scale such that the page scrolls horizontally (2.5) doesn't result
in the initial scale being adjusted back to the maximum scale that would accomodate the full contents of the
page (2).

  • platform/ipad/fast/viewport/ios/non-responsive-viewport-after-changing-view-scale-expected.txt: Added.
  • platform/ipad/fast/viewport/ios/responsive-viewport-with-minimum-width-after-changing-view-scale-expected.txt: Added.

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

1:00 PM Changeset in webkit [248613] by Alan Coon
  • 4 edits in branches/safari-608-branch

Cherry-pick r248281. rdar://problem/54237787

iOS 13: Overflow:hidden on body prevents PDF scroll
https://bugs.webkit.org/show_bug.cgi?id=200435
rdar://problem/53942888

Reviewed by Tim Horton.
Source/WebKit:

When we navigate from an overflow:hidden HTML page to a custom view (like PDF), we need
to make sure that the scroll view is scrollable.

  • UIProcess/API/Cocoa/WKWebView.mm: (-[WKWebView _setHasCustomContentView:loadedMIMEType:]):

Tools:

When we navigate from an overflow:hidden HTML page to a custom view (like PDF), we need
to make sure that the scroll view is scrollable.

  • TestWebKitAPI/Tests/ios/ScrollViewScrollabilityTests.mm: (TestWebKitAPI::TEST):

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

1:00 PM Changeset in webkit [248612] by Alan Coon
  • 3 edits
    1 add in branches/safari-608-branch

Cherry-pick r248271. rdar://problem/54237771

JSC: assertion failure in SpeculativeJIT::compileGetByValOnIntTypedArray
https://bugs.webkit.org/show_bug.cgi?id=199997

Reviewed by Saam Barati.

JSTests:

New test.

  • stress/typedarray-no-alreadyChecked-assert.js: Added. (checkIntArray): (checkFloatArray):

Source/JavaScriptCore:

No need to ASSERT(node->arrayMode().alreadyChecked(...)) in SpeculativeJIT::compileGetByValOnIntTypedArray()
and compileGetByValOnFloatTypedArray() as the abstract interpreter is conservative and can insert a
CheckStructureOrEmpty which will fail the ASSERT as it checks for the SpecType of the array
and not for SpecEmpty. If we added a check for the SpecEmpty in the ASSERT, there are cases where
it won't be set.

  • dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::compileGetByValOnIntTypedArray): (JSC::DFG::SpeculativeJIT::compileGetByValOnFloatTypedArray):

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

1:00 PM Changeset in webkit [248611] by Alan Coon
  • 2 edits in branches/safari-608-branch/LayoutTests

Cherry-pick r248189. rdar://problem/54237682

[ Mac ] Layout Test accessibility/mac/press-not-work-for-disabled-menu-list.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=196505
<rdar://problem/49532620>

Patch by Andres Gonzalez <Andres Gonzalez> on 2019-08-02
Reviewed by Chris Fleizach.

Re-wrote test in a timing independent way. This should fix the intermittent failures.

  • accessibility/mac/press-not-work-for-disabled-menu-list.html:

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

1:00 PM Changeset in webkit [248610] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebCore

Cherry-pick r248188. rdar://problem/54237663

Add accessibility object method to determine whether an element is inside a table cell. Needed for iOS accessibility client.
https://bugs.webkit.org/show_bug.cgi?id=200394
<rdar://problem/52914964>

Patch by Andres Gonzalez <Andres Gonzalez> on 2019-08-02
Reviewed by Chris Fleizach.

Explicitly returning BOOL to avoid error in some compiler configurations.

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm: (-[WebAccessibilityObjectWrapper _accessibilityIsInTableCell]):

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

1:00 PM Changeset in webkit [248609] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248174. rdar://problem/54237758

[iPadOS] slides.google.com: Full Screen API warning is presented when swiping through slides
https://bugs.webkit.org/show_bug.cgi?id=200313
<rdar://problem/53777001>

Reviewed by Eric Carlson.

Only run the secheuristic scoring during UIGestureRecognizerStateEnded, rather than both
UIGestureRecognizerStateEnded and UIGestureRecognizerStateBegan. The goal of the heuristic is
to detect fake on-screen keyboards by detecting gestures that look like "typing". Using only
UIGestureRecognizerStateEnded still allows us to do this (as typing will usually have identical
geometries for both Ended and Began) without generating false-positives during swipe gestures.

  • UIProcess/ios/fullscreen/WKFullScreenViewController.mm: (-[WKFullScreenViewController _touchDetected:]):

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

1:00 PM Changeset in webkit [248608] by Alan Coon
  • 8 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248169. rdar://problem/54237663

Add accessibility object method to determine whether an element is inside a table cell. Needed for iOS accessibility client.
https://bugs.webkit.org/show_bug.cgi?id=200394
<rdar://problem/52914964>

Patch by Andres Gonzalez <Andres Gonzalez> on 2019-08-02
Reviewed by Chris Fleizach.

Source/WebCore:

Test: accessibility/ios-simulator/element-in-table-cell.html

Added _accessibilityIsInTableCell needed for iOS accessibility client.

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm: (-[WebAccessibilityObjectWrapper _accessibilityIsInTableCell]):

Tools:

Glue code to exercise new method [WebAccessibilityObjectWrapper _accessibilityIsInTableCell].

  • WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp: (WTR::AccessibilityUIElement::isInTableCell const):
  • WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
  • WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
  • WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm: (WTR::AccessibilityUIElement::isInTableCell const):

LayoutTests:

New test that exercises [WebAccessibilityObjectWrapper _accessibilityIsInTableCell].

  • accessibility/ios-simulator/element-in-table-cell-expected.txt: Added.
  • accessibility/ios-simulator/element-in-table-cell.html: Added.

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

1:00 PM Changeset in webkit [248607] by Alan Coon
  • 5 edits
    1 add in branches/safari-608-branch

Cherry-pick r248149. rdar://problem/54237692

GetterSetter type confusion during DFG compilation
https://bugs.webkit.org/show_bug.cgi?id=199903

Reviewed by Mark Lam.

JSTests:

  • stress/cse-propagated-constant-may-not-follow-structure-restrictions.js: Added.

Source/JavaScriptCore:

In AI, we are strongly assuming that GetGetter's child constant value should be GetterSetter if it exists.
However, this can be wrong since nobody ensures that. AI assumed so because the control-flow and preceding
CheckStructure ensures that. But this preceding check can be eliminated if the node becomes (at runtime) unreachable.

Let's consider the following graph.

129:<!0:-> PutByOffset(KnownCell:@115, KnownCell:@115, Check:Untyped:@124, MustGen, id5{length}, 0, W:NamedProperties(5), ClobbersExit, bc#154, ExitValid)
130:<!0:-> PutStructure(KnownCell:@115, MustGen, %C8:Object -> %C3:Object, ID:7726, R:JSObject_butterfly, W:JSCell_indexingType,JSCell_structureID,JSCell_typeInfoFlags,JSCell_typeInfoType, ClobbersExit, bc#154, ExitInvalid)
...
158:<!0:-> GetLocal(Check:Untyped:@197, JS|MustGen|UseAsOther, Final, loc7(R<Final>/FlushedCell), R:Stack(-8), bc#187, ExitValid) predicting Final
210:< 1:-> DoubleRep(Check:NotCell:@158, Double|PureInt, BytecodeDouble, Exits, bc#187, ExitValid)
...
162:<!0:-> CheckStructure(Cell:@158, MustGen, [%Ad:Object], R:JSCell_structureID, Exits, bc#192, ExitValid)
163:< 1:-> GetGetterSetterByOffset(KnownCell:@158, KnownCell:@158, JS|UseAsOther, OtherCell, id5{length}, 0, R:NamedProperties(5), Exits, bc#192, ExitValid)
164:< 1:-> GetGetter(KnownCell:@163, JS|UseAsOther, Function, R:GetterSetter_getter, Exits, bc#192, ExitValid)

At @163 and @164, AI proves that @158's AbstractValue is None because @210's edge filters out Cells @158 is a cell. But we do not invalidate graph status as "Invalid" even if edge filters out all possible value.
This is because the result of edge can be None in a valid program. For example, we can put a dependency edge between a consuming node and a producing node, where the producing node is just like a check and it
does not produce a value actually. So, @163 and @164 are not invalidated. This is totally fine in our compiler pipeline right now.

But after that, global CSE phase found that @115 and @158 are same and @129 dominates @158. As a result, we can replace GetGetter child's @163 with @124. Since CheckStructure is already removed (and now, at runtime,
@163 and @164 are never executed), we do not have any structure guarantee on @158 and the result of @163. This means that @163's CSE result can be non-GetterSetter value.

124:< 2:-> JSConstant(JS|UseAsOther, Final, Weak:Object: 0x1199e82a0 with butterfly 0x0 (Structure %B4:Object), StructureID: 49116, bc#0, ExitValid)
...
126:< 2:-> GetGetter(KnownCell:Kill:@124, JS|UseAsOther, Function, R:GetterSetter_getter, Exits, bc#192, ExitValid)

AI filters out @124's non-cell values. But @126 can get non-GetterSetter cell at AI phase. But our AI code is like the following.

JSValue base = forNode(node->child1()).m_value;
if (base) {

GetterSetter* getterSetter = jsCast<GetterSetter*>(base);
...

Then, jsCast casts the above object with GetterSetter accidentally.

In general, DFG AI can get a proven constant value, which could not be shown at runtime. This happens if the processing node is unreachable at runtime while the graph is not invalid yet, because preceding edge
filters already filter out all the possible execution. DFG AI already considered about this possibility, and it attempts to fold a node into a constant only when the constant input matches against the expected one.
But several DFG nodes are not handling this correctly: GetGetter, GetSetter, and SkipScope.

In this patch, we use jsDynamicCast to ensure that the constant input matches against the expected (foldable) one, and fold it only when the expectation is met.
We also remove DFG::Node::castConstant and its use. We should not rely on the constant folded value based on graph's control-flow.

  • dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
  • dfg/DFGNode.h: (JSC::DFG::Node::castConstant): Deleted.
  • ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileMaterializeCreateActivation):

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

12:49 PM Changeset in webkit [248606] by Justin Fan
  • 23 edits
    1 copy
    1 add in trunk

[WebGPU] Improve GPUBindGroup performance using one device-shared argument MTLBuffer
https://bugs.webkit.org/show_bug.cgi?id=200606

Reviewed by Myles C. Maxfield.

Source/WebCore:

Manage all argument buffer storage for GPUBindGroups in one large MTLBuffer for a GPUDevice.
Vastly improves GPUProgrammablePassEncoder.setBindGroup performance; in alpha MotionMark WebGPU benchmark,
score improves from ~12000 to ~90000.

No expected change in WebGPU behavior, though bind-groups.html has been updated to cover more cases.

  • Modules/webgpu/WebGPUDevice.cpp:

(WebCore::WebGPUDevice::createBindGroup const):

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/gpu/GPUBindGroup.h: No longer manages one unique MTLBuffer per MTLArgumentEncoder.

(WebCore::GPUBindGroup::argumentBuffer const): Delegates to GPUBindGroupAllocator for current argument buffer.
(WebCore::GPUBindGroup::vertexArgsBuffer const): Deleted.
(WebCore::GPUBindGroup::fragmentArgsBuffer const): Deleted.
(WebCore::GPUBindGroup::computeArgsBuffer const): Deleted.

  • platform/graphics/gpu/GPUBindGroupAllocator.h: Added. Allocates MTLBuffer for and assigns offsets for argument buffers.

(WebCore::GPUBindGroupAllocator::argumentBuffer const):

  • platform/graphics/gpu/GPUBindGroupLayout.h:
  • platform/graphics/gpu/GPUBuffer.h: Move MTLResourceUsage calculation to GPUBuffer construction.

(WebCore::GPUBuffer::platformUsage const):

  • platform/graphics/gpu/GPUComputePassEncoder.h: Prevent any potiential narrowing issues, as offset can be large.
  • platform/graphics/gpu/GPUDevice.cpp: Now owns a GPUBindGroupAllocator for owning all its argument buffer storage.

(WebCore::GPUDevice::tryCreateBindGroup const):

  • platform/graphics/gpu/GPUDevice.h:
  • platform/graphics/gpu/GPUProgrammablePassEncoder.h:

(WebCore::GPUProgrammablePassEncoder::setVertexBuffer):
(WebCore::GPUProgrammablePassEncoder::setFragmentBuffer):
(WebCore::GPUProgrammablePassEncoder::setComputeBuffer):

  • platform/graphics/gpu/GPURenderPassEncoder.h:
  • platform/graphics/gpu/GPUTexture.h: Move MTLResourceUsage calculation to GPUTexture construction.

(WebCore::GPUTexture::platformUsage const):

  • platform/graphics/gpu/cocoa/GPUBindGroupAllocatorMetal.mm: Added.

(WebCore::GPUBindGroupAllocator::create):
(WebCore::GPUBindGroupAllocator::GPUBindGroupAllocator):
(WebCore::GPUBindGroupAllocator::allocateAndSetEncoders): Ensures that MTLArgumentEncoders have appropriate allocation for encoding.
(WebCore::GPUBindGroupAllocator::reallocate): Create new MTLBuffer large enough for new encoder requirement, and copy over old argument buffer data.
(WebCore::GPUBindGroupAllocator::tryReset): For now, resets argument buffer if all GPUBindGroups created with this allocator are destroyed.

  • platform/graphics/gpu/cocoa/GPUBindGroupMetal.mm:

(WebCore::tryGetResourceAsBufferBinding): Add size check.
(WebCore::GPUBindGroup::tryCreate): No longer owns new MTLBuffers. Requests argument buffer space from GPUBindGroupAllocator.
(WebCore::GPUBindGroup::GPUBindGroup):
(WebCore::GPUBindGroup::~GPUBindGroup): Remind allocator to check for possible reset.
(WebCore::tryCreateArgumentBuffer): Deleted.

  • platform/graphics/gpu/cocoa/GPUBufferMetal.mm:

(WebCore::GPUBuffer::GPUBuffer):

  • platform/graphics/gpu/cocoa/GPUComputePassEncoderMetal.mm:

(WebCore::GPUComputePassEncoder::setComputeBuffer):

  • platform/graphics/gpu/cocoa/GPUDeviceMetal.mm:
  • platform/graphics/gpu/cocoa/GPUProgrammablePassEncoderMetal.mm:

(WebCore::GPUProgrammablePassEncoder::setBindGroup): No need to recalculate usage every time. Set appropriate argument buffer and offsets for new bind group model.

  • platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:

(WebCore::GPURenderPassEncoder::setVertexBuffer):
(WebCore::GPURenderPassEncoder::setFragmentBuffer):

  • platform/graphics/gpu/cocoa/GPUTextureMetal.mm:

(WebCore::GPUTexture::GPUTexture):

LayoutTests:

Update bind-groups.html to better stress GPUBindGroup implementation.

  • webgpu/bind-groups-expected.txt:
  • webgpu/bind-groups.html:
12:35 PM Changeset in webkit [248605] by msaboff@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION (r248533): JSC Command - Need to initializeMainThread() before processing config file
https://bugs.webkit.org/show_bug.cgi?id=200677

Reviewed by Mark Lam.

We need to initialize the main thread before calling processConfigFile() since it uses RefCounted objects
which have "is main thread" ASSERTS.

  • jsc.cpp:

(jscmain):

12:26 PM Changeset in webkit [248604] by Antti Koivisto
  • 6 edits
    2 adds in trunk

Source/WebCore:
Event region collection should take clipping into account
https://bugs.webkit.org/show_bug.cgi?id=200668
<rdar://problem/53826561>

Reviewed by Simon Fraser.

Test: pointerevents/ios/touch-action-region-clip-and-transform.html

  • rendering/EventRegion.cpp:

(WebCore::EventRegionContext::pushClip):
(WebCore::EventRegionContext::popClip):

Maintain clip rect stack.

(WebCore::EventRegionContext::unite):

Apply both transforms and clipping.

  • rendering/EventRegion.h:
  • rendering/RenderBlock.cpp:
  • rendering/RenderBox.cpp:

(WebCore::RenderBox::pushContentsClip):
(WebCore::RenderBox::popContentsClip):

Update clip for non-self-painting layers.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::clipToRect):
(WebCore::RenderLayer::restoreClip):

Update clip for self-painting layers.

LayoutTests:
Event regions collection should take clipping into account
https://bugs.webkit.org/show_bug.cgi?id=200668
<rdar://problem/53826561>

Reviewed by Simon Fraser.

  • pointerevents/ios/touch-action-region-clip-and-transform-expected.txt: Added.
  • pointerevents/ios/touch-action-region-clip-and-transform.html: Added.
11:54 AM Changeset in webkit [248603] by ysuzuki@apple.com
  • 2 edits in trunk/Source/WTF

Unreviewed, build fix for Windows
https://bugs.webkit.org/show_bug.cgi?id=200611

  • wtf/win/GDIObject.h:
11:28 AM Changeset in webkit [248602] by Devin Rousso
  • 20 edits
    1 move in trunk

Web Inspector: Styles: show @supports CSS groupings
https://bugs.webkit.org/show_bug.cgi?id=200419
<rdar://problem/53971948>

Reviewed by Joseph Pecoraro.

Source/JavaScriptCore:

  • inspector/protocol/CSS.json:

Rename CSSMedia to Grouping and remove the sourceLine value, as it was never populated
and wasn't used by Web Inspector.

  • inspector/scripts/codegen/objc_generator_templates.py:
  • inspector/scripts/codegen/generate_objc_header.py:

(ObjCHeaderGenerator.generate_output):
Add support for including files at the end of <WebInspector/RWIProtocol.h> for compatibility
statements so that changes to the Web Inspector protocol don't break other clients.

Source/WebCore:

Test: inspector/css/getMatchedStylesForNode.html

  • inspector/InspectorStyleSheet.cpp:

(WebCore::buildArrayForGroupings): Added.
(WebCore::InspectorStyleSheet::buildObjectForRule):
(WebCore::buildMediaObject): Deleted.
(WebCore::fillMediaListChain): Deleted.

  • css/MediaList.h:
  • css/MediaList.cpp:

(WebCore::MediaQuerySet::MediaQuerySet):
Remove the lastLine as it was never set by anyone and wasn't used by Web Inspector.

Source/WebInspectorUI:

  • UserInterface/Models/CSSGrouping.js: Renamed from Source/WebInspectorUI/UserInterface/Models/CSSMedia.js.

(WI.CSSGrouping):
(WI.CSSGrouping.prototype.get type):
(WI.CSSGrouping.prototype.get text):
(WI.CSSGrouping.prototype.get sourceCodeLocation):
(WI.CSSGrouping.prototype.get isMedia): Added.
(WI.CSSGrouping.prototype.get isSupports): Added.
(WI.CSSGrouping.prototype.get prefix): Added.

  • UserInterface/Models/CSSStyleDeclaration.js:

(WI.CSSStyleDeclaration.prototype.get groupings): Added.
(WI.CSSStyleDeclaration.prototype.generateCSSRuleString):
(WI.CSSStyleDeclaration.prototype.get mediaList): Deleted.

  • UserInterface/Models/CSSRule.js:

(WI.CSSRule):
(WI.CSSRule.prototype.get groupings): Added.
(WI.CSSRule.prototype.update):
(WI.CSSRule.prototype._selectorResolved):
(WI.CSSRule.prototype.get mediaList): Deleted.

  • UserInterface/Models/DOMNodeStyles.js:

(WI.DOMNodeStyles.prototype._parseRulePayload):
(WI.DOMNodeStyles.prototype.rulesForSelector): Deleted.

  • UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:

(WI.SpreadsheetCSSStyleDeclarationSection):
(WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
(WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleEditorFilterApplied):
(WI.SpreadsheetCSSStyleDeclarationSection.prototype._createMediaHeader): Deleted.

  • UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:

(.spreadsheet-css-declaration :matches(.header, .header-groupings)): Added.
(.spreadsheet-css-declaration :matches(.header, .header-groupings):first-child): Added.
(.spreadsheet-css-declaration .header-groupings > .grouping): Added.
(.spreadsheet-css-declaration :matches(.header, .header-media)): Deleted.
(.spreadsheet-css-declaration :matches(.header, .header-media):first-child): Deleted.
(.spreadsheet-css-declaration .media-label): Deleted.

  • UserInterface/Controllers/CSSManager.js:

(WI.CSSManager.protocolGroupingTypeToEnum): Added.
(WI.CSSManager.protocolMediaSourceToEnum): Deleted.

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

LayoutTests:

  • inspector/css/getMatchedStylesForNode.html:
  • inspector/css/getMatchedStylesForNode-expected.txt:
11:11 AM Changeset in webkit [248601] by jiewen_tan@apple.com
  • 2 edits in trunk/Tools

Adds WebAuthn and AppSSO into watchlist
https://bugs.webkit.org/show_bug.cgi?id=200647

Reviewed by Dewei Zhu.

  • Scripts/webkitpy/common/config/watchlist:
10:34 AM Changeset in webkit [248600] by russell_e@apple.com
  • 3 edits in trunk/LayoutTests

Reverting change in r248379
rdar://53779679

Unreviewed Test Gardening.
Removed previously set TestExpectations.

  • platform/ios-12/TestExpectations:
  • platform/ios/TestExpectations:
10:16 AM Changeset in webkit [248599] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

Incorrect head in fast/canvas/webgl/gl-get-calls.html causes test failure
https://bugs.webkit.org/show_bug.cgi?id=200673

Patch by Chris Lord <Chris Lord> on 2019-08-13
Reviewed by Alexey Proskuryakov.

  • fast/canvas/webgl/gl-get-calls.html:
10:12 AM Changeset in webkit [248598] by Chris Dumez
  • 5 edits in trunk

Crash under IPC::Connection::markCurrentlyDispatchedMessageAsInvalid()
https://bugs.webkit.org/show_bug.cgi?id=200674
<rdar://problem/50692748>

Reviewed by Geoff Garen.

Source/WebKit:

When the client terminates a provisional process (e.g. via the [WKWebView _killWebContentProcessAndResetState]
SPI), the WebProcessProxy would notify its associated WebPageProxy objects that it had terminated but would fail
to notify its associated ProvisionalPageProxy objects. As a result, those objects would not get destroyed and
would still think that they were in the middle of a provisional load the next time a load started. This inconsistent
state would lead to crashes such as the one in the radar.

  • UIProcess/ProvisionalPageProxy.cpp:

(WebKit::ProvisionalPageProxy::cancel):

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::requestTermination):

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
10:08 AM Changeset in webkit [248597] by sihui_liu@apple.com
  • 5 edits in trunk/Source/WebCore

Make sure UniqueIDBDatabaseConnection unregister itself from IDBServer
https://bugs.webkit.org/show_bug.cgi?id=200650
<rdar://problem/54236010>

Reviewed by Youenn Fablet.

We register UniqueIDBDatabaseConnection unconditionally to IDBServer but fail to unregister if UniqueIDBDatabase
of UniqueIDBDatabaseConnection is gone.

  • Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:

(WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection):
(WebCore::IDBServer::UniqueIDBDatabaseConnection::~UniqueIDBDatabaseConnection):

  • Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

(WebCore::IDBServer::UniqueIDBDatabaseConnection::server):

  • Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:

(WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction):
(WebCore::IDBServer::UniqueIDBDatabaseTransaction::~UniqueIDBDatabaseTransaction):

  • Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
10:05 AM Changeset in webkit [248596] by Alan Bujtas
  • 8 edits
    1 copy
    1 add in trunk/Source/WebCore

[LFC][TFC] Introduce TableGrid
https://bugs.webkit.org/show_bug.cgi?id=200656
<rdar://problem/54240833>

Reviewed by Antti Koivisto.

table grid:
A matrix containing as many rows and columns as needed to describe the position of all the table-rows
and table-cells of a table-root, as determined by the grid-dimensioning algorithm.
Each row of the grid might correspond to a table-row, and each column to a table-column.

slot of the table grid:
A slot (r,c) is an available space created by the intersection of a row r and a column c in the table grid.

https://www.w3.org/TR/css-tables-3/#terminology

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/layouttree/LayoutBox.h:

(WebCore::Layout::Box::isTableHeader const):
(WebCore::Layout::Box::isTableBody const):
(WebCore::Layout::Box::isTableFooter const):

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::createLayoutBox):

  • layout/tableformatting/TableFormattingContext.cpp:

(WebCore::Layout::TableFormattingContext::layout const):
(WebCore::Layout::TableFormattingContext::ensureTableGrid const):
(WebCore::Layout::TableFormattingContext::computePreferredWidthForColumns const):
(WebCore::Layout::TableFormattingContext::computeTableWidth const):
(WebCore::Layout::TableFormattingContext::distributeAvailabeWidth const):
(WebCore::Layout::TableFormattingContext::computeTableHeight const):
(WebCore::Layout::TableFormattingContext::distributeAvailableHeight const):

  • layout/tableformatting/TableFormattingContext.h:

(WebCore::Layout::TableFormattingContext::formattingState const):

  • layout/tableformatting/TableFormattingState.h:

(WebCore::Layout::TableFormattingState::tableGrid):

  • layout/tableformatting/TableGrid.cpp: Added.

(WebCore::Layout::TableGrid::CellInfo::CellInfo):
(WebCore::Layout::TableGrid::SlotInfo::SlotInfo):
(WebCore::Layout::TableGrid::TableGrid):
(WebCore::Layout::TableGrid::appendCell):
(WebCore::Layout::TableGrid::insertCell):
(WebCore::Layout::TableGrid::removeCell):

  • layout/tableformatting/TableGrid.h: Copied from Source/WebCore/layout/tableformatting/TableFormattingContext.h.
8:34 AM Changeset in webkit [248595] by Joseph Pecoraro
  • 2 edits in trunk/Source/JavaScriptCore

JSContext Inspector: Basic CommandLineAPI doesn't work
https://bugs.webkit.org/show_bug.cgi?id=200659
<rdar://problem/54245476>

Reviewed by Brian Burg.

  • inspector/InjectedScriptSource.js:

(BasicCommandLineAPI):
Use method directly since it already has been setup nicely and doesn't
need to be bound. Technically this allows someone to add properties to
the CommandLineAPI methods in basic mode (dir.property = 1) but that
seems harmless.

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

[LFC][TFC] Add rowSpan and colSpan to Box
https://bugs.webkit.org/show_bug.cgi?id=200654
<rdar://problem/54239281>

Reviewed by Antti Koivisto.

colSpan and rowSpan are not part of the RenderStyle. We eventually need to find a more appropriate place for the "random DOM things".

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::setRowSpan):
(WebCore::Layout::Box::setColumnSpan):
(WebCore::Layout::Box::rowSpan const):
(WebCore::Layout::Box::columnSpan const):

  • layout/layouttree/LayoutBox.h:
  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::createLayoutBox):

3:06 AM Changeset in webkit [248593] by youenn@apple.com
  • 45 edits
    1 delete in trunk/Source

Blob registries should be keyed by session IDs
https://bugs.webkit.org/show_bug.cgi?id=200567
Source/WebCore:

<rdar://problem/54120212>

Reviewed by Alex Christensen.

Pass session IDs to all BlobRegistry methods in particular ThreadableLoaderRegistry.
The only exception is blobSize which should be dealt with a follow-up patch.
blobSize blob registry is retrieved from the connection -> sessionID map in Network Process.
Covered by existing tests.

  • Modules/fetch/FetchLoader.cpp:

(WebCore::FetchLoader::~FetchLoader):
(WebCore::FetchLoader::startLoadingBlobURL):

  • Modules/fetch/FetchLoader.h:
  • fileapi/FileReaderLoader.cpp:

(WebCore::FileReaderLoader::~FileReaderLoader):
(WebCore::FileReaderLoader::start):

  • fileapi/FileReaderLoader.h:
  • fileapi/ThreadableBlobRegistry.cpp:

(WebCore::ThreadableBlobRegistry::registerFileBlobURL):
(WebCore::ThreadableBlobRegistry::registerBlobURL):
(WebCore::ThreadableBlobRegistry::registerBlobURLOptionallyFileBacked):

  • fileapi/ThreadableBlobRegistry.h:
  • html/PublicURLManager.cpp:
  • loader/PolicyChecker.cpp:

(WebCore::PolicyChecker::extendBlobURLLifetimeIfNecessary const):

  • platform/network/BlobRegistry.h:
  • platform/network/BlobRegistryImpl.cpp:

(WebCore::createBlobResourceHandle):
(WebCore::loadBlobResourceSynchronously):
(WebCore::BlobRegistryImpl::filesInBlob const):

  • platform/network/BlobRegistryImpl.h:
  • platform/network/FormData.cpp:

(WebCore::appendBlobResolved):
(WebCore::FormData::resolveBlobReferences):

  • platform/network/FormData.h:
  • platform/network/cf/FormDataStreamCFNet.cpp:

(WebCore::createHTTPBodyCFReadStream):

  • platform/network/soup/ResourceRequest.h:
  • platform/network/soup/ResourceRequestSoup.cpp:

(WebCore::ResourceRequest::updateSoupMessageBody const):
(WebCore::ResourceRequest::updateSoupMessage const):

Source/WebKit:

<rdar://problem/54120212>

Reviewed by Alex Christensen.

Move blob registry to NetworkSession so that it is partitioned by session ID.
In case session ID is not given through IPC, use the connection as key to get the network session.
This is used for blobSize.

  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::startDownload):

  • NetworkProcess/Downloads/DownloadManager.h:
  • NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
  • NetworkProcess/FileAPI/NetworkBlobRegistry.h: Removed.
  • NetworkProcess/NetworkConnectionToWebProcess.cpp:

(WebKit::NetworkConnectionToWebProcess::didClose):
(WebKit::NetworkConnectionToWebProcess::resolveBlobReferences):
(WebKit::NetworkConnectionToWebProcess::registerFileBlobURL):
(WebKit::NetworkConnectionToWebProcess::registerBlobURL):
(WebKit::NetworkConnectionToWebProcess::registerBlobURLFromURL):
(WebKit::NetworkConnectionToWebProcess::registerBlobURLOptionallyFileBacked):
(WebKit::NetworkConnectionToWebProcess::registerBlobURLForSlice):
(WebKit::NetworkConnectionToWebProcess::unregisterBlobURL):
(WebKit::NetworkConnectionToWebProcess::blobSize):
(WebKit::NetworkConnectionToWebProcess::writeBlobsToTemporaryFiles):
(WebKit::NetworkConnectionToWebProcess::filesInBlob):

  • NetworkProcess/NetworkConnectionToWebProcess.h:
  • NetworkProcess/NetworkConnectionToWebProcess.messages.in:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::blobRegistry):

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcessPlatformStrategies.cpp:

(WebKit::NetworkProcessPlatformStrategies::createBlobRegistry):

  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::startNetworkLoad):

  • NetworkProcess/NetworkSession.h:

(WebKit::NetworkSession::blobRegistry):

  • NetworkProcess/soup/NetworkDataTaskSoup.cpp:

(WebKit::NetworkDataTaskSoup::createRequest):

  • NetworkProcess/soup/NetworkSessionSoup.cpp:

(WebKit::NetworkSessionSoup::createWebSocketTask):

  • Sources.txt:
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/FileAPI/BlobRegistryProxy.cpp:

(WebKit::BlobRegistryProxy::registerFileBlobURL):
(WebKit::BlobRegistryProxy::registerBlobURL):
(WebKit::BlobRegistryProxy::registerBlobURLOptionallyFileBacked):
(WebKit::BlobRegistryProxy::unregisterBlobURL):
(WebKit::BlobRegistryProxy::registerBlobURLForSlice):
(WebKit::BlobRegistryProxy::writeBlobsToTemporaryFiles):

  • WebProcess/FileAPI/BlobRegistryProxy.h:
  • WebProcess/Network/NetworkProcessConnection.cpp:

(WebKit::NetworkProcessConnection::writeBlobsToTemporaryFiles):

  • WebProcess/Network/NetworkProcessConnection.h:

Source/WebKitLegacy/mac:

Reviewed by Alex Christensen.

  • WebCoreSupport/WebPlatformStrategies.mm:

(WebPlatformStrategies::createBlobRegistry):
Ignore sessionID parameter for WK1.

Source/WebKitLegacy/win:

<rdar://problem/54120212>

Reviewed by Alex Christensen.

  • WebCoreSupport/WebPlatformStrategies.cpp:

(WebPlatformStrategies::createBlobRegistry):

1:54 AM Changeset in webkit [248592] by youenn@apple.com
  • 19 edits
    1 add in trunk/Source

User Agent and SessionID should be given to NetworkRTCProvider to set up the correct proxy information
https://bugs.webkit.org/show_bug.cgi?id=200583

Reviewed by Eric Carlson.

Source/ThirdParty/libwebrtc:

Export of some symbols.

  • Configurations/libwebrtc.iOS.exp:
  • Configurations/libwebrtc.iOSsim.exp:
  • Configurations/libwebrtc.mac.exp:

Source/WebCore:

Use a socket factory that is specific to the user agent and session ID.
This factory is stored in the media endpoint.
Not testable without proxy infrastructure.

  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:

(WebCore::LibWebRTCMediaEndpoint::setConfiguration):

  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h:
  • platform/mediastream/libwebrtc/LibWebRTCProvider.cpp:

(WebCore::LibWebRTCProvider::createPeerConnection):

  • platform/mediastream/libwebrtc/LibWebRTCProvider.h:

Source/WebKit:

Pass session id and user agent whenever creating a TCP client socket.
Use this information to get the proxy information from NetworkSession and pass it to libwebrtc socket creation.

  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/webrtc/NetworkRTCProvider.cpp:

(WebKit::NetworkRTCProvider::proxyInfoFromSession):
(WebKit::NetworkRTCProvider::createClientTCPSocket):

  • NetworkProcess/webrtc/NetworkRTCProvider.h:
  • NetworkProcess/webrtc/NetworkRTCProvider.messages.in:
  • WebKit.xcodeproj/project.pbxproj:
  • NetworkProcess/webrtc/NetworkRTCProvider.mm: Added.

(WebKit::NetworkRTCProvider::proxyInfoFromSession):

  • WebProcess/Network/webrtc/LibWebRTCProvider.cpp:

(WebKit::LibWebRTCProvider::createPeerConnection):
(WebKit::LibWebRTCProvider::createSocketFactory):

  • WebProcess/Network/webrtc/LibWebRTCProvider.h:
  • WebProcess/Network/webrtc/LibWebRTCSocketFactory.cpp:

(WebKit::LibWebRTCSocketFactory::createServerTcpSocket):
(WebKit::LibWebRTCSocketFactory::createUdpSocket):
(WebKit::LibWebRTCSocketFactory::createClientTcpSocket):
(WebKit::LibWebRTCSocketFactory::createAsyncResolver):

  • WebProcess/Network/webrtc/LibWebRTCSocketFactory.h:

Aug 12, 2019:

10:18 PM Changeset in webkit [248591] by rniwa@webkit.org
  • 7 edits
    2 adds in trunk

FrameLoader::open can execute scritps via style recalc in Frame::setDocument
https://bugs.webkit.org/show_bug.cgi?id=200377

Reviewed by Antti Koivisto.

Source/WebCore:

Fixed the bug that FrameLoader::open can execute arbitrary author scripts via post style update callbacks
by adding PostResolutionCallbackDisabler, WidgetHierarchyUpdatesSuspensionScope, and NavigationDisabler
to CachedFrameBase::restore and FrameLoader::open.

This ensures all frames are restored from the page cache before any of them would start running scripts.

Test: fast/frames/restoring-page-cache-should-not-run-scripts-via-style-update.html

  • history/CachedFrame.cpp:

(WebCore::CachedFrameBase::restore):

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::open):

  • page/FrameViewLayoutContext.cpp:

(WebCore::FrameViewLayoutContext::layout): Fixed the debug assertion. The layout of a document may be
updated while we're preparing to put a page into the page cache.

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::updateCompositingLayers): Ditto.

LayoutTests:

Added a regression test.

  • fast/frames/restoring-page-cache-should-not-run-scripts-via-style-update-expected.txt: Added.
  • fast/frames/restoring-page-cache-should-not-run-scripts-via-style-update.html: Added.
  • platform/win/TestExpectations: Skip the newly added test.
8:56 PM Changeset in webkit [248590] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

REGRESSION(r248391): Web Inspector: changing Layout Direction Debug setting no longer adds dir="ltr" to body element
https://bugs.webkit.org/show_bug.cgi?id=200564

Reviewed by Joseph Pecoraro.

WI.resolvedLayoutDirection was called before WI.runBootstrapOperations, which is what
instantiates WI.showDebugUISetting. Without it, WI.resolvedLayoutDirection will ignore
the value of WI.settings.debugLayoutDirection and instead use the system.

Moving the instantiation of WI.showDebugUISetting outside WI.runBootstrapOperations
allows the setting to be created when the Bootstrap.js script is loaded, rather than after
the DOMContentLoaded event is fired. This means that it's guaranteed to exist before any
interface/view code runs.

  • UserInterface/Debug/Bootstrap.js:

(WI.runBootstrapOperations):

8:54 PM Changeset in webkit [248589] by Devin Rousso
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: remove WI.DeprecatedRemoteObjectProperty
https://bugs.webkit.org/show_bug.cgi?id=200549

Reviewed by Joseph Pecoraro.

  • UserInterface/Protocol/RemoteObject.js:

(WI.RemoteObject.prototype.deprecatedGetOwnProperties): Deleted.
(WI.RemoteObject.prototype.deprecatedGetAllProperties): Deleted.
(WI.RemoteObject.prototype.deprecatedGetDisplayableProperties): Deleted.
(WI.RemoteObject.prototype._deprecatedGetProperties): Deleted.
(WI.RemoteObject.prototype._deprecatedGetPropertiesResolver): Deleted.
(WI.DeprecatedRemoteObjectProperty): Deleted.
(WI.DeprecatedRemoteObjectProperty.prototype.fromPrimitiveValue): Deleted.

  • UserInterface/Models/CallFrame.js:

(WI.CallFrame.prototype.collectScopeChainVariableNames):

  • UserInterface/Views/DOMNodeDetailsSidebarPanel.js:

(WI.DOMNodeDetailsSidebarPanel.prototype._refreshProperties):

8:52 PM Changeset in webkit [248588] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: REGRESSION(r248201): DOMDebugger: unable to add event breakpoint when All Events breakpoint is enabled
https://bugs.webkit.org/show_bug.cgi?id=200561

Reviewed by Joseph Pecoraro.

  • UserInterface/Controllers/DOMDebuggerManager.js:

(WI.DOMDebuggerManager.prototype.addEventBreakpoint):
(WI.DOMDebuggerManager.prototype.removeEventBreakpoint):

8:50 PM Changeset in webkit [248587] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: REGRESSION: DOMDebugger: breakpoints are forcibly enabled when resolving DOM breakpoints for newly added nodes
https://bugs.webkit.org/show_bug.cgi?id=200639

Reviewed by Joseph Pecoraro.

Since DOM breakpoints revolve around a given DOM node, we attempt to restore DOM breakpoints
whenever new nodes are added by matching them to the path of the DOM breakpoint. When doing
so, we should be in a "temporarily restoring breakpoints" mode so that we don't forcibly
enable all breakpoints.

  • UserInterface/Controllers/DOMDebuggerManager.js:

(WI.DOMDebuggerManager.prototype._speculativelyResolveDOMBreakpointsForURL):
(WI.DOMDebuggerManager.prototype._nodeInserted):

8:01 PM Changeset in webkit [248586] by commit-queue@webkit.org
  • 5 edits in trunk

[WTF] Thread::removeFromThreadGroup leaks weak pointers.
https://bugs.webkit.org/show_bug.cgi?id=199857

Patch by Takashi Komori <Takashi.Komori@sony.com> on 2019-08-12
Reviewed by Yusuke Suzuki.

Source/WTF:

Fix leaking of ThreadGroup's weak pointers.

Tests: WTF.ThreadGroupRemove API tests

  • wtf/Threading.cpp:

(WTF::Thread::didExit):
(WTF::Thread::addToThreadGroup):
(WTF::Thread::removeFromThreadGroup):
(WTF::Thread::numberOfThreadGroups):

  • wtf/Threading.h:

Tools:

  • TestWebKitAPI/Tests/WTF/ThreadGroup.cpp:

(TestWebKitAPI::countThreadGroups):
(TestWebKitAPI::TEST):

6:23 PM Changeset in webkit [248585] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Fix bad RELEASE_LOG_ERROR under ProvisionalPageProxy::ProvisionalPageProxy()
https://bugs.webkit.org/show_bug.cgi?id=200646

Reviewed by Alex Christensen.

Fix bad RELEASE_LOG_ERROR under ProvisionalPageProxy::ProvisionalPageProxy(). Should be a
simple RELEASE_LOG() as this is not an error.

  • UIProcess/ProvisionalPageProxy.cpp:

(WebKit::ProvisionalPageProxy::ProvisionalPageProxy):

5:52 PM Changeset in webkit [248584] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

AX: Homebrew is not allowed to run any script under sudo.
https://bugs.webkit.org/show_bug.cgi?id=173801

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-08-12
Reviewed by Carlos Alberto Lopez Perez.

Latest versions of Homebrew throw an error when run as root.
Dependencies are successfully installed w/o sudo on macOS, so skip it.

  • gtk/install-dependencies:
4:43 PM Changeset in webkit [248583] by Jonathan Bedard
  • 2 edits in trunk/Tools

[REGRESSION] run-webkit-tests: No PID defined when searching for simulator crashlogs
https://bugs.webkit.org/show_bug.cgi?id=200644

Reviewed by Aakash Jain.

  • Scripts/webkitpy/port/simulator_process.py:

(SimulatorProcess._start): Define system PID after launching app.

4:43 PM Changeset in webkit [248582] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKitLegacy/win

Cherry-pick r248472. rdar://problem/54225658

[Win] Remove compiler workaround for VS2013
https://bugs.webkit.org/show_bug.cgi?id=200582

Reviewed by Don Olmstead.

A VS2013 compiler workaround can be removed now.

  • WebKitQuartzCoreAdditions/API/WebKitQuartzCoreAdditions.cpp: (DllMain):

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

4:43 PM Changeset in webkit [248581] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/JavaScriptCore

Apply patch. rdar://problem/54171876

4:42 PM Changeset in webkit [248580] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebCore/PAL

Cherry-pick r248081. rdar://problem/54223700

Use CTFontCreateForCharactersWithLanguageAndOption if available instead of CTFontCreateForCharactersWithLanguage
https://bugs.webkit.org/show_bug.cgi?id=200241
<rdar://problem/53495386>

Build fix for older MacOS for which CTFontFallbackOption is not defined.
Unreviewed.

  • pal/spi/cocoa/CoreTextSPI.h:

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

4:42 PM Changeset in webkit [248579] by Alan Coon
  • 11 edits in branches/safari-608-branch/Source

Cherry-pick r248502. rdar://problem/54130670

Disable ContentChangeObserver TouchEvent adjustment on youtube.com on iOS in mobile browsing mode
https://bugs.webkit.org/show_bug.cgi?id=200609
<rdar://problem/54015403>

Reviewed by Maciej Stachowiak.

Source/WebCore:

When watching a youtube video on iOS with "Autoplay" switched to off,
upon finishing the video all clicks anywhere on the page are effectively ignored.
Disabling ContentChangeObserver's TouchEvent adjustment fixes this bug. I verified this manually.
This switch was introduced in r242621, and it disables part of a new feature, so there is low risk of fallout.

  • loader/DocumentLoader.h: (WebCore::DocumentLoader::setAllowContentChangeObserverQuirk): (WebCore::DocumentLoader::allowContentChangeObserverQuirk const):
  • page/Quirks.cpp: (WebCore::Quirks::shouldDisableContentChangeObserverTouchEventAdjustment const):
  • page/Quirks.h:
  • page/ios/ContentChangeObserver.cpp: (WebCore::ContentChangeObserver::touchEventDidStart):

Source/WebKit:

  • Shared/WebsitePoliciesData.cpp: (WebKit::WebsitePoliciesData::encode const): (WebKit::WebsitePoliciesData::decode): (WebKit::WebsitePoliciesData::applyToDocumentLoader):
  • Shared/WebsitePoliciesData.h:
  • UIProcess/API/APIWebsitePolicies.cpp: (API::WebsitePolicies::copy const): (API::WebsitePolicies::data):
  • UIProcess/API/APIWebsitePolicies.h:
  • UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):

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

4:42 PM Changeset in webkit [248578] by Alan Coon
  • 9 edits in branches/safari-608-branch/Source

Cherry-pick r248501. rdar://problem/54130614

[iOS] Add a quirk for gmail.com messages on iPhone iOS13
https://bugs.webkit.org/show_bug.cgi?id=200605

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-10
Reviewed by Maciej Stachowiak.

Source/WebCore:

Add a quirk which sets the user agent for gmail.com messages on iPhone
OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
it is fixed.

  • page/Quirks.cpp: (WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
  • page/Quirks.h:
  • platform/UserAgent.h:
  • platform/ios/UserAgentIOS.mm: (WebCore::osNameForUserAgent): (WebCore::standardUserAgentWithApplicationName):
  • platform/mac/UserAgentMac.mm: (WebCore::standardUserAgentWithApplicationName):

Source/WebKit:

Use WebPage::platformUserAgent() to add the gmail.com quirk.

  • UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::platformUserAgent const):

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

4:42 PM Changeset in webkit [248577] by Alan Coon
  • 14 edits
    3 adds in branches/safari-608-branch

Cherry-pick r248494. rdar://problem/54171876

Universal XSS in JSObject::putInlineSlow and JSValue::putToPrimitive
https://bugs.webkit.org/show_bug.cgi?id=199864

Reviewed by Saam Barati.

Source/JavaScriptCore:

Our JSObject::put implementation is not correct in term of the spec. Our Put? implementation is something like this.

JSObject::put(object):

if (can-do-fast-path(object))

return fast-path(object);

slow-path
do {

object-put-check-and-setter-calls(object); (1)
object = object->prototype;

} while (is-object(object));
return do-put(object);

Since JSObject::put is registered in the methodTable, the derived classes can override it. Some of classes are adding
extra checks to this put.

Derived::put(object):

if (do-extra-check(object))

fail

return JSObject::put(object)

The problem is that Derived::put is only called when the |this| object is the Derived class. When traversing Prototype? in
JSObject::put, at (1), we do not perform the extra checks added in Derived::put even if object is Derived one. This means that
we skip the check.

Currently, JSObject::put and WebCore checking mechanism are broken. JSObject::put should call getOwnPropertySlot at (1) to
perform the additional checks. This behavior is matching against the spec. However, currently, our JSObject::getOwnPropertySlot
does not propagate setter information. This is required to cache cacheable Put? at (1) for CustomValue, CustomAccessor, and
Accessors. We also need to reconsider how to integrate static property setters to this mechanism. So, basically, this involves
large refactoring to renew our JSObject::put and JSObject::getOwnPropertySlot.

To work-around for now, we add a new TypeInfo flag, HasPutPropertySecurityCheck . And adding this flag to DOM objects
that implements the addition checks. We also add doPutPropertySecurityCheck method hook to perform the check in JSObject.
When we found this flag at (1), we perform doPutPropertySecurityCheck to properly perform the checks.

Since our JSObject::put code is old and it does not match against the spec now, we should refactor it largely. This is tracked separately in [1].

[1]: https://bugs.webkit.org/show_bug.cgi?id=200562

  • runtime/ClassInfo.h:
  • runtime/JSCJSValue.cpp: (JSC::JSValue::putToPrimitive):
  • runtime/JSCell.cpp: (JSC::JSCell::doPutPropertySecurityCheck):
  • runtime/JSCell.h:
  • runtime/JSObject.cpp: (JSC::JSObject::putInlineSlow): (JSC::JSObject::getOwnPropertyDescriptor):
  • runtime/JSObject.h: (JSC::JSObject::doPutPropertySecurityCheck):
  • runtime/JSTypeInfo.h: (JSC::TypeInfo::hasPutPropertySecurityCheck const):

Source/WebCore:

Test: http/tests/security/cross-frame-access-object-put-optimization.html

  • bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::doPutPropertySecurityCheck):
  • bindings/js/JSLocationCustom.cpp: (WebCore::JSLocation::doPutPropertySecurityCheck):
  • bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader):
  • bindings/scripts/test/JS/JSTestActiveDOMObject.h:

LayoutTests:

  • http/tests/security/cross-frame-access-object-put-optimization-expected.txt: Added.
  • http/tests/security/cross-frame-access-object-put-optimization.html: Added.
  • http/tests/security/resources/cross-frame-iframe-for-object-put-optimization-test.html: Added.

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

4:42 PM Changeset in webkit [248576] by Alan Coon
  • 12 edits
    16 adds in branches/safari-608-branch

Cherry-pick r248491. rdar://problem/54130636

Don't allow cross-origin iframes to autofocus
https://bugs.webkit.org/show_bug.cgi?id=200515
<rdar://problem/54092988>

Reviewed by Ryosuke Niwa.

Source/WebCore:

According to Step 6 in the WhatWG Spec (https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#autofocusing-a-form-control:-the-autofocus-attribute),
the 'autofocus' attribute shouldn't work for cross-origin iframes.

This change is based on the Blink change (patch by <mustaq@chromium.org>):
<https://chromium-review.googlesource.com/c/chromium/src/+/1593026>

Also disallow cross-origin iframes from focusing programmatically without ever having
had any user interaction.

  • dom/Element.cpp: Check if an invalid frame is trying to grab the focus. (WebCore::Element::focus):
  • html/HTMLFormControlElement.cpp: Check if the focus is moving to an invalid frame. (WebCore::shouldAutofocus):
  • page/DOMWindow.cpp: Check if an invalid frame is trying to grab the focus. (WebCore::DOMWindow::focus):

Tools:

Make WebKit.FocusedFrameAfterCrash use same-origin iframes instead
of cross-origin iframes, since it depends on focusing one of the
frames.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit/ReloadPageAfterCrash.cpp: (TestWebKitAPI::TEST):
  • TestWebKitAPI/Tests/WebKit/many-same-origin-iframes.html: Added.

LayoutTests:

Add test coverage, and simulate user interaction in existing tests
that require focusing a cross-origin frame.

  • http/tests/security/clipboard/resources/copy-html.html:
  • http/tests/security/clipboard/resources/copy-mso-list.html:
  • http/tests/security/clipboard/resources/copy-url.html:
  • http/wpt/html/interaction/focus/no-cross-origin-element-focus-expected.txt: Added.
  • http/wpt/html/interaction/focus/no-cross-origin-element-focus.html: Added.
  • http/wpt/html/interaction/focus/no-cross-origin-window-focus-expected.txt: Added.
  • http/wpt/html/interaction/focus/no-cross-origin-window-focus.html: Added.
  • http/wpt/html/interaction/focus/resources/child-focus-element.html: Added.
  • http/wpt/html/interaction/focus/resources/child-focus-window.html: Added.
  • http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub-expected.txt: Added.
  • http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub.html: Added.
  • http/wpt/html/semantics/forms/autofocus/resources/child-autofocus.html: Added.
  • http/wpt/webauthn/resources/last-layer-frame.https.html:

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

4:42 PM Changeset in webkit [248575] by Alan Coon
  • 3 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248481. rdar://problem/54130658

[iOS WK2] Remove context menu hints on navigation
https://bugs.webkit.org/show_bug.cgi?id=200588
rdar://problem/54061796

Reviewed by Tim Horton.

Make sure the context menu hint doesn't linger across navigations by hosting it in its
own container view (shared with drag previews), and hiding that view on navigation (unparenting
may have bad consequences). We remove the view when the animation ends.

  • UIProcess/ios/WKContentViewInteraction.h:
  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView _didCommitLoadForMainFrame]): (-[WKContentView containerViewForTargetedPreviews]): (-[WKContentView _hideContextMenu]): (-[WKContentView contextMenuInteraction:willEndForConfiguration:animator:]):

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

4:42 PM Changeset in webkit [248574] by Alan Coon
  • 7 edits in branches/safari-608-branch/Source

Cherry-pick r248471. rdar://problem/54130624

Disable CSSOM View Scrolling API for IMDb iOS app
https://bugs.webkit.org/show_bug.cgi?id=200586
<rdar://problem/53645833>

Patch by Alex Christensen <achristensen@webkit.org> on 2019-08-09
Reviewed by Simon Fraser.

Source/WebCore:

They are calling scrollHeight on the HTML element and it is running new code introduced in r235806
Disable this new feature until they update their app to use the iOS13 SDK.

  • platform/RuntimeApplicationChecks.h:
  • platform/cocoa/RuntimeApplicationChecksCocoa.mm: (WebCore::IOSApplication::isIMDb):

Source/WebKit:

Change the CSSOMViewScrollingAPIEnabled default value to be off for the IMDb app's WKWebViews.
I manually verified this is effective in those WKWebViews but no other WKWebViews and that it fixes the radar.

  • Shared/WebPreferences.yaml:
  • Shared/WebPreferencesDefaultValues.cpp: (WebKit::defaultCSSOMViewScrollingAPIEnabled):
  • Shared/WebPreferencesDefaultValues.h:

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

4:42 PM Changeset in webkit [248573] by Alan Coon
  • 5 edits in branches/safari-608-branch/Source

Cherry-pick r248469. rdar://problem/54130688

Tapping buttons in Data Detectors lookup previews doesn't work
https://bugs.webkit.org/show_bug.cgi?id=200579
<rdar://problem/54056519>

Reviewed by Megan Gardner.

Source/WebCore/PAL:

  • pal/spi/ios/DataDetectorsUISPI.h:

Source/WebKit:

  • Platform/spi/ios/UIKitSPI.h:
  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView _contextMenuInteraction:styleForMenuWithConfiguration:]): If a Data Detectors context menu wants the action menu style, provide it.

(-[WKContentView contextMenuInteraction:willPerformPreviewActionForMenuWithConfiguration:animator:]):
If a Data Detectors context menu provides a view controller to present
on context menu commit, present it. We present on top of the same view
controller that is currently presenting the context menu, but modally
instead of inside the context menu.

If a Data Detectors context menu instead provides a URL to launch on
context menu commit, call openURL.

In both cases, change the commit style to pop, since we're committing
instead of dismissing.

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

4:42 PM Changeset in webkit [248572] by Alan Coon
  • 4 edits in branches/safari-608-branch/Source/WebCore

Cherry-pick r248463. rdar://problem/54139782

REGRESSION (iOS 13): united.com web forms do not respond to taps
https://bugs.webkit.org/show_bug.cgi?id=200531

Reviewed by Antti Koivisto and Wenson Hsieh.

The bug is caused by the content change observer detecting “Site Feedback” link at the bottom of
the page (https://www.united.com/ual/en/US/account/enroll/default) constantly getting re-generated
in every frame via requestAnimationFrame when the page is opened with iPhone UA string.
Note that the content re-generation can be reproduced even in Chrome if iPhone UA string is used.

Ignore this constant content change in ContentChangeObserver as a site specific quirk.

In the future, we should make ContentChangeObserver observe the final location of each element
being observed so that we can ignore content that like this which is placed outside the viewport,
and/or far away from where the user tapped.

  • page/Quirks.cpp: (WebCore::Quirks::shouldIgnoreContentChange const): Added.
  • page/Quirks.h:
  • page/ios/ContentChangeObserver.cpp: (WebCore::ContentChangeObserver::shouldObserveVisibilityChangeForElement):

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

4:42 PM Changeset in webkit [248571] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248456. rdar://problem/54109877

REGRESSION (52279987): Most of the WKUIDelegate contextMenu delegate methods are not being called
https://bugs.webkit.org/show_bug.cgi?id=200557
<rdar://problem/53717962>

Reviewed by Wenson Hsieh.

UIKit changed the name of delegates recently. We ignored the warning because
it was still calling the old methods. However, it will only do so for applications
authored by Apple, breaking 3rd parties.

The change here is just adopting the new methods in place of the old ones.
It does not change the API that WebKit vends (they still use the older names).

  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView contextMenuInteraction:willDisplayMenuForConfiguration:animator:]): (-[WKContentView contextMenuInteraction:willPerformPreviewActionForMenuWithConfiguration:animator:]): (-[WKContentView contextMenuInteraction:willEndForConfiguration:animator:]): (-[WKContentView contextMenuInteractionWillPresent:]): Deleted. (-[WKContentView contextMenuInteraction:willCommitWithAnimator:]): Deleted. (-[WKContentView contextMenuInteractionDidEnd:]): Deleted.

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

4:42 PM Changeset in webkit [248570] by Alan Coon
  • 3 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248455. rdar://problem/54109872

[iOS WK2] Hide previews when an inner overflow or frame scrollview scrolls
https://bugs.webkit.org/show_bug.cgi?id=200552
rdar://problem/54086338

Reviewed by Wenson Hsieh.

Give UITargetedPreview the UIScrollView that the target element is inside of,
so it can clean up if the user starts to scroll that view.

  • Platform/spi/ios/UIKitSPI.h:
  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView _createTargetedPreviewIfPossible]):

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

4:42 PM Changeset in webkit [248569] by Alan Coon
  • 9 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248438. rdar://problem/54093220

[iOS] Position image information should respect the image orientation
https://bugs.webkit.org/show_bug.cgi?id=200487

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-08
Reviewed by Simon Fraser.

Source/WebCore:

Re-factor CachedImage::imageSizeForRenderer() into another overriding
function which does not scale the imageSize. Therefore the new function
returns FloatSize while the original function returns LayoutSize.

  • loader/cache/CachedImage.cpp: (WebCore::CachedImage::imageSizeForRenderer const):
  • loader/cache/CachedImage.h:
  • rendering/RenderElement.h:

Source/WebKit:

imagePositionInformation() should respect the image orientation when
drawing an Image to a ShareableBitmap context.

boundsPositionInformation() already takes care of the image orientation
because it gets RenderImage::enclosingBoundingBox().

  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::imagePositionInformation):

Tools:

Add an API test to verify the position image information is drawn rotated
because of respecting its image orientation.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/WKRequestActivatedElementInfo.mm: (TestWebKitAPI::TEST):
  • TestWebKitAPI/Tests/WebKitCocoa/exif-orientation-8-llo.jpg: Added.
  • TestWebKitAPI/Tests/WebKitCocoa/img-with-rotated-image.html: Added.

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

4:42 PM Changeset in webkit [248568] by Alan Coon
  • 3 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248436. rdar://problem/54093228

Set WKWebView opaque based on drawsBackground in PageConfiguration.
https://bugs.webkit.org/show_bug.cgi?id=200528

Reviewed by Tim Horton.

  • UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _initializeWithConfiguration:]): Set self.opaque = NO when !self.opaque
!pageConfiguration->drawsBackground().

It is almost impossible to have !self.opaque be NO at this point, since we are still inside initWithFrame:. A subclass could
override opaque and return NO, but checking pageConfiguration's drawsBackground is a good alternative.

  • WebProcess/WebPage/WebPage.h: Remove unused m_drawsBackground member.

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

4:42 PM Changeset in webkit [248567] by Alan Coon
  • 6 edits
    1 add in branches/safari-608-branch

Cherry-pick r248410. rdar://problem/54084721

Do not allow navigations of frames about to get replaced by the result of evaluating javascript: URLs
<rdar://problem/53788893> and https://bugs.webkit.org/show_bug.cgi?id=198786

Reviewed by Geoff Garen.

Source/WebCore:

Covered by API Test

Add a "willReplaceWithResultOfExecutingJavascriptURL" flag which is respected inside FrameLoader::isNavigationAllowed

  • bindings/js/ScriptController.cpp: (WebCore::ScriptController::executeIfJavaScriptURL):
  • bindings/js/ScriptController.h: (WebCore::ScriptController::willReplaceWithResultOfExecutingJavascriptURL const):
  • loader/FrameLoader.cpp: (WebCore::FrameLoader::isNavigationAllowed const):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/mac/JavascriptURLNavigation.mm: Added.

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

4:42 PM Changeset in webkit [248566] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248393. rdar://problem/54066682

Regression(r247784) ResourceLoadStatisticsMemoryStore / ResourceLoadStatisticsPersistentStorage may get destroyed on the wrong thread
https://bugs.webkit.org/show_bug.cgi?id=200517

Reviewed by Geoffrey Garen.

The issue is that WebResourceLoadStatisticsStore::flushAndDestroyPersistentStore() is null checking
m_persistentStorage and m_statisticsStore on the main thread, even though those members are initialized
and destroyed on the background thread. As a result, if flushAndDestroyPersistentStore() is called *before*
the background task to initialize those members has had a chance to run, then we'd return early without
destroying those members. Later on, the background task would then initialize those data members and we
would then destroy them on the main thread when the WebResourceLoadStatisticsStore is destroyed on the
main thread.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp: (WebKit::WebResourceLoadStatisticsStore::flushAndDestroyPersistentStore):

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

4:42 PM Changeset in webkit [248565] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebCore/PAL

Cherry-pick r248381. rdar://problem/54018115

Context menu on a universal link produces a blank preview
https://bugs.webkit.org/show_bug.cgi?id=200485
<rdar://problem/53699620>

Reviewed by Tim Horton.

Use the umbrella #import.

  • pal/spi/cocoa/LaunchServicesSPI.h:

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

4:42 PM Changeset in webkit [248564] by Alan Coon
  • 4 edits in branches/safari-608-branch/Source

Cherry-pick r248380. rdar://problem/54018115

Context menu on a universal link produces a blank preview
https://bugs.webkit.org/show_bug.cgi?id=200485
<rdar://problem/53699620>

Reviewed by Dean Jackson.

Source/WebCore/PAL:

Define iTunesStoreURL from CoreServices.

  • pal/spi/cocoa/LaunchServicesSPI.h:

Source/WebKit:

If the context menu is activated on an iTunesStore URL, pass it
on to DataDetectors, who should know how to handle it.

Two drive-by fixes:

  • make it clear that early returns do not produce a value. Instead call the completion handler first, then return.
  • The new API DataDetectors case doesn't need to worry about hiding link previews as DataDetectors itself will handle that.
  • UIProcess/ios/WKContentViewInteraction.mm: If the URL is an iTunesStoreURL (as defined by CoreServices), let DataDetectors handle it. (-[WKContentView assignLegacyDataForContextMenuInteraction]): (-[WKContentView continueContextMenuInteraction:]): (-[WKContentView continueContextMenuInteractionWithDataDetectors:]): New method to use DataDetectors if possible.

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

4:42 PM Changeset in webkit [248563] by Alan Coon
  • 4 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248368. rdar://problem/54037153

Extra space inserted at start of line when inserting a newline in Mail compose
https://bugs.webkit.org/show_bug.cgi?id=200490
<rdar://problem/53501354>

Reviewed by Antti Koivisto.

Source/WebCore:

This started happening after r244494, which deferred editor state computation until the next layer tree flush
when changing selection. After inserting a paragraph, the act of computing an editor state ensured that the text
node containing the caret drops out of simple line layout, while grabbing the characters near the selection
(i.e., calling charactersAroundPosition). This meant that when we subsequently ask positionAfterSplit whether it
isRenderedCharacter() at the end of the command, we are guaranteed to have line boxes, so we get a meaningful
answer and avoid inserting an extra non-breaking space.

However, after r244494, we defer the editor state computation until the end of the edit command; this means that
we may not have line boxes for positionAfterSplit's text node renderer, due to remaining in simple line layout.
In turn, this means that we end up hitting the assertion in containsRenderedCharacterOffset in debug builds; on
release builds, we simply return false from containsRenderedCharacterOffset, which causes us to insert an extra
space.

To fix this, we educate RenderText::containsRenderedCharacterOffset about simple line layout.

Test: editing/inserting/insert-paragraph-in-designmode-document.html

  • rendering/RenderText.cpp: (WebCore::RenderText::containsRenderedCharacterOffset const): (WebCore::RenderText::containsCaretOffset const):

Changed to use SimpleLineLayout::containsOffset.

  • rendering/SimpleLineLayoutFunctions.h: (WebCore::SimpleLineLayout::containsOffset):

I first contrasted the behavior of RenderTextLineBoxes::containsOffset in the cases where the OffsetType is
CaretOffset or CharacterOffset, and found that the only interesting differences were:

  1. The caret offset type case has special handling for line breaks.
  2. Both offset types have handling for reversed text.
  3. The end offset of a line box contains a caret offset, but not a character offset.

For the purposes of OffsetType CharacterOffset, (1) is irrelevant; furthermore, (2) is already not handled by
logic in containsCaretOffset(). Thus, the only major difference in the CharacterOffset case should be (3), which
we handle by only allowing the case where the given offset is equal to the very end of a text run for caret
offsets, and not character offsets.

(WebCore::SimpleLineLayout::containsCaretOffset): Deleted.

Renamed to just containsOffset.

LayoutTests:

Add a new test to verify that inserting a newline in the middle of text in a document with designMode "on"
doesn't insert an extra space at the beginning of the newly inserted line.

  • editing/inserting/insert-paragraph-in-designmode-document-expected.txt: Added.
  • editing/inserting/insert-paragraph-in-designmode-document.html: Added.

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

4:41 PM Changeset in webkit [248562] by Alan Coon
  • 7 edits
    4 adds in branches/safari-608-branch

Cherry-pick r248265. rdar://problem/54017842

Ping loads should not prevent page caching
https://bugs.webkit.org/show_bug.cgi?id=200418
<rdar://problem/53901632>

Reviewed by Darin Adler.

Source/WebCore:

We normally prevent page caching if there were any pending subresource loads when navigating,
to avoid caching partial / broken content. However, this should not apply to Ping / Beacon
loads since those do not impact page rendering and can outlive the page.

Tests: http/tests/navigation/page-cache-pending-ping-load-cross-origin.html

http/tests/navigation/page-cache-pending-ping-load-same-origin.html

  • history/PageCache.cpp: (WebCore::PageCache::addIfCacheable): After we've fired the 'pagehide' event in each frame, stop all the loads again. This is needed since pages are allowed to start ping / beacon loads in their 'pagehide' handlers. If we do not stop those loads, then the next call to canCachePage() would fail because the DocumentLoader is still loading. Note that we're not actually preventing these ping loads from hitting the server since we never cancel page loads and those can outlive their page.
  • loader/DocumentLoader.cpp: (WebCore::shouldPendingCachedResourceLoadPreventPageCache): (WebCore::areAllLoadersPageCacheAcceptable): Make sure that Ping / Beacon / Prefetches / Icon loads do not prevent page caching.

(WebCore::DocumentLoader::addSubresourceLoader):
Tweak assertion that was incorrect since we actually allow ping / beacon loads when the
document is about to enter PageCache (while firing pagehide event).

Tools:

Add TestOption to enable PageCache at UIProcess-level so that we can test
page caching when navigating cross-origin with PSON enabled.

  • WebKitTestRunner/TestController.cpp: (WTR::TestController::resetPreferencesToConsistentValues): (WTR::updateTestOptionsFromTestHeader):
  • WebKitTestRunner/TestOptions.h: (WTR::TestOptions::hasSameInitializationOptions const):

LayoutTests:

Add layout test coverage.

  • http/tests/navigation/page-cache-pending-ping-load-cross-origin-expected.txt: Added.
  • http/tests/navigation/page-cache-pending-ping-load-cross-origin.html: Added.
  • http/tests/navigation/page-cache-pending-ping-load-same-origin-expected.txt: Added.
  • http/tests/navigation/page-cache-pending-ping-load-same-origin.html: Added.

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

4:41 PM Changeset in webkit [248561] by Alan Coon
  • 5 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248148. rdar://problem/54017840

Pages using MessagePorts should be PageCacheable
https://bugs.webkit.org/show_bug.cgi?id=200366
<rdar://problem/53837882>

Reviewed by Geoffrey Garen.

Source/WebCore:

Allow a page to enter PageCache, even if it has MessagePorts (potentially with
pending messages). If there are pending messages on the MessagePorts when
entering PageCache, those will get dispatched upon restoring from PageCache.

Test: fast/history/page-cache-MessagePort-pending-message.html

  • dom/MessagePort.cpp: (WebCore::MessagePort::messageAvailable): (WebCore::MessagePort::dispatchMessages): Do not dispatch messages while in PageCache.

(WebCore::MessagePort::canSuspendForDocumentSuspension const):
Allow pages with MessagePort objects to enter PageCache.

  • dom/ScriptExecutionContext.cpp: (WebCore::ScriptExecutionContext::resumeActiveDOMObjects): Make sure pending messages on MessagePorts get dispatched asynchronously after restoring from PageCache.
  • loader/DocumentLoader.cpp: (WebCore::areAllLoadersPageCacheAcceptable): Make sure only CachedResources that are still loading upon load cancelation prevent entering PageCache.

LayoutTests:

Add layout test coverage.

  • fast/history/page-cache-MessagePort-pending-message-expected.txt: Added.
  • fast/history/page-cache-MessagePort-pending-message.html: Added.

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

4:41 PM Changeset in webkit [248560] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r248129. rdar://problem/53836595

REGRESSION: HSBC Personal Banking download/print dialog is usually positioned off screen on iPad
https://bugs.webkit.org/show_bug.cgi?id=200356
<rdar://problem/51885199>

Reviewed by Beth Dakin.

  • UIProcess/ios/WebPageProxyIOS.mm: (WebKit::desktopClassBrowsingRecommendedForRequest): Add HSBC domains to the list of sites that recommend mobile mode by default.

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

4:41 PM Changeset in webkit [248559] by Alan Coon
  • 8 edits
    2 adds in branches/safari-608-branch

Cherry-pick r248112. rdar://problem/53836593

[Text autosizing] [iPadOS] Add targeted hacks to address some remaining text autosizing issues
https://bugs.webkit.org/show_bug.cgi?id=200271
<rdar://problem/51734741>

Reviewed by Zalan Bujtas.

Source/WebCore:

Makes some targeted adjustments to the text autosizing heuristic, to ensure compatibility with several high-
profile websites. See changes below for more detail.

Tests: fast/text-autosizing/ios/idempotentmode/idempotent-autosizing-candidate-special-cases.html

fast/text-autosizing/ios/idempotentmode/line-height-boosting.html

  • css/StyleResolver.cpp: (WebCore::StyleResolver::adjustRenderStyleForTextAutosizing):

Avoid clipped sidebar links on sohu.com by not performing line-height boosting in the case where the element
probably has a small, fixed number of lines. See below for more detail. Additionally, don't attempt to adjust
the line height using the boosted font size, in the case where the element is not a candidate for idempotent
text autosizing.

  • rendering/style/RenderStyle.cpp: (WebCore::RenderStyle::isIdempotentTextAutosizingCandidate const):

Make various targeted hacks to fix a few websites:

  • Add a special case for top navigation bar links on yandex.ru, where line height greatly exceeds the

specified font size.

  • Avoid boosting some related video links on v.youku.com by considering the line-clamp CSS property when

determining the maximum number of lines of text an element is expected to contain.

  • Avoid boosting some front page links on asahi.com, which have non-repeating background images.
  • Add several other adjustments to more aggressively boost pieces of text on Google search results, such as

taking the word-break CSS property into account.

The bottom few pixels of sidebar links on naver.com are also no longer clipped after these changes.

  • rendering/style/TextSizeAdjustment.cpp: (WebCore::AutosizeStatus::probablyContainsASmallFixedNumberOfLines):

Pulls out a piece of the heuristic added to fix sephora.com in r247467 out into a separate helper method. To
recap, this heuristic identifies elements with both a fixed height and fixed line height, for which the fixed
height is close to an integer multiple of the line height.

Also makes several small tweaks in the process: (1) change the max difference between fixed line height and
font size from 6 to 5 to ensure that some multiline caption text on Google search results is boosted, and (2)
replace usages of lineHeight() with specifiedLineHeight(), which current prevents this function from being
truly idempotent.

(WebCore::AutosizeStatus::updateStatus):

  • rendering/style/TextSizeAdjustment.h:

LayoutTests:

Add tests to cover some changes to line height boosting and the idempotent text autosizing candidate heuristic.

  • fast/text-autosizing/ios/idempotentmode/idempotent-autosizing-candidate-special-cases-expected.txt: Added.
  • fast/text-autosizing/ios/idempotentmode/idempotent-autosizing-candidate-special-cases.html: Added.
  • fast/text-autosizing/ios/idempotentmode/line-height-boosting-expected.txt:
  • fast/text-autosizing/ios/idempotentmode/line-height-boosting.html:

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

4:41 PM Changeset in webkit [248558] by Alan Coon
  • 8 edits
    3 adds in branches/safari-608-branch

Cherry-pick r248104. rdar://problem/53836566

UserMediaPermissionRequestManagerProxy should not use audio+video denied requests to deny audio-only or video-only requests
https://bugs.webkit.org/show_bug.cgi?id=200317

Reviewed by Eric Carlson.

Source/WebKit:

Only match audio+video denied requests with new audio+video requests.
That will ensure that audio can still be captured if user denied access to the camera through preferences
and website started with a getUserMedia({audio: true, video: true}) call.
Covered by added API test.

  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp: (WebKit::UserMediaPermissionRequestManagerProxy::wasRequestDenied):

Tools:

  • TestWebKitAPI/Tests/WebKit/getUserMediaAudioVideoCapture.html: Added
  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit/GetUserMediaReprompt.mm: (-[GetUserMediaOnlyAudioUIDelegate _webView:requestMediaCaptureAuthorization:decisionHandler:]): (-[GetUserMediaOnlyAudioUIDelegate _webView:checkUserMediaPermissionForURL:mainFrameURL:frameIdentifier:decisionHandler:]): (TestWebKitAPI::TEST):

LayoutTests:

Update existing test with new behavior.
Added new test for the case where video is blocked but not audio.

  • fast/mediastream/getUserMedia-deny-persistency3-expected.txt:
  • fast/mediastream/getUserMedia-deny-persistency3.html:
  • fast/mediastream/getUserMedia-deny-persistency4-expected.txt: Added.
  • fast/mediastream/getUserMedia-deny-persistency4.html: Added.

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

4:41 PM Changeset in webkit [248557] by Alan Coon
  • 6 edits
    1 move in branches/safari-608-branch

Cherry-pick r248095. rdar://problem/53820658

REGRESSION (r240942): first visually non-empty layout milestone is not reached in media documents until after the video finishes loading
https://bugs.webkit.org/show_bug.cgi?id=200293
<rdar://problem/52937749>

Reviewed by Alex Christensen.

Source/WebCore:

r240942 changed FrameView::qualifiesAsVisuallyNonEmpty() to consider only documents in the
Interactive or Complete ready states as "finished parsing". Documents considered finished
parsing can qualify as visually non-empty even without exceeding the visual character or
pixel thresholds, but documents considered not finished must first exceed one of these
thresholds in order to qualify as visually non-empty.

HTMLDocuments are placed in the Interactive ready state by their HTMLDocumentParsers.
However, HTMLDocument subclasses like ImageDocument and MediaDocument use their own custom
parsers that never set the Interactive ready state on their documents; these documents go
from Loading directly to Complete.

In order for these HTMLDocument subclasses to be considered visually non-empty before they
finish loading they must render something that exceeds the visual character or pixel
thresholds. For image documents, rendering the image is usually enough to cross the
threshold, but for media documents the visual pixel threshold was never crossed because
videos did not contribute to the visually non-empty pixel count.

As a result, media documents are not considered visually non-empty until the main resource
finishes loading. On iOS this means that the layer tree remains frozen until this point,
even though the media might have started autoplaying with audio long before it finished
loading.

Fix this by teaching RenderVideo to contribute the video player's size to FrameView's
visually non-empty pixel count once the video player has loaded enough data to determine its
intrinsic size. Videos that render more than 1024 pixels will qualify a media document as
visually non-empty even when it is still loading its main resource.

Added a new API test.

  • rendering/RenderImage.cpp: (WebCore::RenderImage::imageChanged): (WebCore::RenderImage::incrementVisuallyNonEmptyPixelCountIfNeeded):
  • rendering/RenderImage.h:
  • rendering/RenderVideo.cpp: (WebCore::RenderVideo::updateIntrinsicSize):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/FirstVisuallyNonEmptyMilestone.mm: Renamed from Tools/TestWebKitAPI/Tests/WebKit/FirstVisuallyNonEmptyMilestoneWithDeferredScript.mm. (-[FirstPaintMessageHandler userContentController:didReceiveScriptMessage:]): (-[RenderingProgressNavigationDelegate _webView:renderingProgressDidChange:]): (-[RenderingProgressNavigationDelegate webView:didFinishNavigation:]): (TEST):

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

4:41 PM Changeset in webkit [248556] by Alan Coon
  • 11 edits in branches/safari-608-branch/Source/JavaScriptCore

Cherry-pick r248027. rdar://problem/53836556

[JSC] Emit write barrier after storing instead of before storing
https://bugs.webkit.org/show_bug.cgi?id=200193

Reviewed by Saam Barati.

I reviewed tricky GC-related code including visitChildren and manual writeBarrier, and I found that we have several problems with write-barriers.

  1. Some write-barriers are emitted before stores happen

Some code like LazyProperty emits write-barrier before we store the value. This is wrong since JSC has concurrent collector. Let's consider the situation like this.

  1. Cell "A" is not marked yet
  2. Write-barrier is emitted onto "A"
  3. Concurrent collector scans "A"
  4. Store to "A"'s field happens
  5. (4)'s field is not rescaned

We should emit write-barrier after stores. This patch places write-barriers after stores happen.

  1. Should emit write-barrier after the stored fields are reachable from the owner.

We have code that is logically the same to the following.

`
auto data = std::make_unique<XXX>();
data->m_field.set(vm, owner, value);

storeStoreBarrier();
owner->m_data = WTFMove(data);
`

This is not correct. When write-barrier is emitted, the owner cannot reach to the field that is stored.
The actual example is AccessCase. We are emitting write-barriers with owner when creating AccessCase, but this is not
effective until this AccessCase is chained to StructureStubInfo, which is reachable from CodeBlock.

I don't think this is actually an issue because currently AccessCase generation is guarded by CodeBlock->m_lock. And CodeBlock::visitChildren takes this lock.
But emitting a write-barrier at the right place is still better. This patch places write-barriers when StructureStubInfo::addAccessCase is called.

Speculative GC fix, it was hard to reproduce the crash since we need to control concurrent collector and main thread's scheduling in an instruction-level.

  • bytecode/BytecodeList.rb:
  • bytecode/CodeBlock.cpp: (JSC::CodeBlock::finishCreation):
  • bytecode/StructureStubInfo.cpp: (JSC::StructureStubInfo::addAccessCase):
  • bytecode/StructureStubInfo.h: (JSC::StructureStubInfo::considerCaching):
  • dfg/DFGPlan.cpp: (JSC::DFG::Plan::finalizeWithoutNotifyingCallback):
  • jit/JITOperations.cpp:
  • llint/LLIntSlowPaths.cpp: (JSC::LLInt::LLINT_SLOW_PATH_DECL): (JSC::LLInt::setupGetByIdPrototypeCache):
  • runtime/CommonSlowPaths.cpp: (JSC::SLOW_PATH_DECL):
  • runtime/LazyPropertyInlines.h: (JSC::ElementType>::setMayBeNull):
  • runtime/RegExpCachedResult.h: (JSC::RegExpCachedResult::record):

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

4:41 PM Changeset in webkit [248555] by Alan Coon
  • 2 edits in branches/safari-608-branch/Source/WebKit

Cherry-pick r247914. rdar://problem/53762618

UI process occasionally hangs in -[UIKeyboardTaskQueue lockWhenReadyForMainThread]
https://bugs.webkit.org/show_bug.cgi?id=200215
<rdar://problem/52976965>

Reviewed by Tim Horton.

To implement autocorrection on iOS, UIKit sometimes needs to request contextual information from WebKit. This is
handled as a sync IPC message in WebKit, since UIKit would otherwise proceed to block the main thread after
sending the request, preventing WebKit from handling any IPC responses in the UI process (potentially resulting
in deadlock if any other sync IPC messages were to arrive in the UI process during this time).

The synchronous nature of this autocorrection request means that if any sync IPC message were to be
simultaneously dispatched in the opposite direction (i.e. web to UI process), we need to immediately handle the
incoming sync message in the UI process (otherwise, we'd end up deadlocking for 1 second until the
autocorrection context request hits a 1-second IPC timeout).

One such synchronous message from the web process to the UI process is WebPageProxy::CreateNewPage, triggered as
a result of synchronously opening a new window. Due to Safari changes in iOS 13 (<rdar://problem/51755088>),
this message now calls into code which then causes UIKit to call *back into* -[WKContentView
requestAutocorrectionContextWithCompletionHandler:] for the newly opened web view, under the scope of the call
to -requestAutocorrectionContextWithCompletionHandler: in the original web view.

This caused a crash, which was tracked in <rdar://problem/52590170>. There was an attempt to fix this in r247345
by invoking the existing handler well before storing the new one; while this avoided the crash, it didn't solve
the root problem, which was that keyboard task queues would get into a bad state after this scenario; this would
manifest in a UI process hang under -[UIKeyboardTaskQueue lockWhenReadyForMainThread] during the next user
gesture, which is tracked by this bug (<rdar://problem/52976965>).

As it turns out, the keyboard task queue gets into a bad state because it is architected in such a way that
tasks added to the queue under the scope of parent task must be finished executing before their parents;
otherwise, the call to -[UIKeyboardTaskExecutionContext returnExecutionToParentWithInfo:] never happens when
handling the child task. This has the effect of causing the keyboard task queue to end up with a
UIKeyboardTaskExecutionContext that can never return execution to its parent context, such that if the task
queue is then told to wait until any future task is finished executing, it will hang forever, waiting for these
stuck tasks to finish executing (which never happens, because they're all waiting to return execution to their
parents which are already done executing!)

To fix this hang and avoid ever getting into this bad state, we need to invoke the autocorrection request
handlers in this order:

(1) Receive outer autocorrection context request.
(2) Receive inner autocorrection context request.
(3) Invoke inner autocorrection context request completion handler.
(4) Invoke outer autocorrection context request completion handler.

...instead of swapping (3) and (4), like we do currently.

  • UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView resignFirstResponderForWebView]):

Remove the hack added in r247345 to try and avoid reentrant autocorrection context requests; we don't need this
anymore, since we should now be able to handle these reentrant requests in the way UIKit expects.

(-[WKContentView requestAutocorrectionContextWithCompletionHandler:]):

Add an early return in the case where the request is synchronous and there's already a pending autocorrection
context to ensure that the completion handler for the nested request is invoked before the outer request is
finished.

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

4:41 PM Changeset in webkit [248554] by Alan Coon
  • 16 edits in branches/safari-608-branch/Source

Cherry-pick r248447. rdar://problem/54218162

Add to InteractionInformationAtPosition information about whether the element is in a subscrollable region
https://bugs.webkit.org/show_bug.cgi?id=200374
rdar://problem/54095519

Reviewed by Tim Horton.
Source/WebCore:

Add to InteractionInformationAtPosition a ScrollingNodeID which represents the enclosing scrolling
node that affects the targeted element's position. We use this to find a UIScrollView in the UI process.

The entrypoint to finding the enclosing scrolling node is ScrollingCoordinator::scrollableContainerNodeID(),
which calls RenderLayerCompositor::asyncScrollableContainerNodeID() to look for a scrolling ancestor in
the current frame, and then looks for an enclosing scrollable frame, or a scrolling ancestor in
the enclosing frame.

There's a bit of subtlety in RenderLayerCompositor::asyncScrollableContainerNodeID() because if you're asking
for the node that scrolls the renderer, if the renderer itself has a layer and is scrollable, you want
its enclosing scroller.

  • page/scrolling/AsyncScrollingCoordinator.cpp: (WebCore::AsyncScrollingCoordinator::scrollableContainerNodeID const):
  • page/scrolling/AsyncScrollingCoordinator.h:
  • page/scrolling/ScrollingCoordinator.cpp: (WebCore::scrollableContainerNodeID const):
  • page/scrolling/ScrollingCoordinator.h:
  • rendering/RenderLayer.h:
  • rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::asyncScrollableContainerNodeID):
  • rendering/RenderLayerCompositor.h:

Source/WebKit:

Add InteractionInformationAtPosition.containerScrollingNodeID and initialize it in elementPositionInformation()
by asking the scrolling coordinator.

Also add a way to get from a ScrollingNodeID to a UIScrollView to RemoteScrollingCoordinatorProxy,
which gets the scrolling node and asks the delegate for the UIView.

  • Shared/ios/InteractionInformationAtPosition.h:
  • Shared/ios/InteractionInformationAtPosition.mm: (WebKit::InteractionInformationAtPosition::encode const): (WebKit::InteractionInformationAtPosition::decode):
  • UIProcess/RemoteLayerTree/RemoteScrollingCoordinatorProxy.h:
  • UIProcess/RemoteLayerTree/ios/RemoteScrollingCoordinatorProxyIOS.mm: (WebKit::RemoteScrollingCoordinatorProxy::scrollViewForScrollingNodeID const):
  • UIProcess/RemoteLayerTree/ios/ScrollingTreeOverflowScrollingNodeIOS.h:
  • UIProcess/RemoteLayerTree/ios/ScrollingTreeOverflowScrollingNodeIOS.mm: (WebKit::ScrollingTreeOverflowScrollingNodeIOS::scrollView const):
  • UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h:
  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::elementPositionInformation):

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

4:30 PM Changeset in webkit [248553] by Alan Coon
  • 7 edits in branches/safari-608.1-branch/Source

Versioning.

4:09 PM Changeset in webkit [248552] by weinig@apple.com
  • 28 edits in trunk

Replace multiparameter overloads of append() in StringBuilder as a first step toward standardizinging on the flexibleAppend() implementation
https://bugs.webkit.org/show_bug.cgi?id=200614

Reviewed by Darin Adler.

Renames StringBuilder::append(const LChar*, unsigned), StringBuilder::append(const UChar*, unsigned) and
StringBuilder::append(const char*, unsigned) to StringBuilder::appendCharacters(...).

Renames StringBuilder::append(const String& string, unsigned offset, unsigned length) to
StringBuilder::appendSubstring(...).

Source/JavaScriptCore:

  • dfg/DFGStrengthReductionPhase.cpp:

(JSC::DFG::StrengthReductionPhase::handleNode):

  • runtime/ConfigFile.cpp:

(JSC::ConfigFile::parse):

  • runtime/LiteralParser.cpp:

(JSC::LiteralParser<CharType>::Lexer::lexStringSlow):

  • tools/FunctionOverrides.cpp:

(JSC::parseClause):
Update for renames.

Source/WebCore:

  • dom/Range.cpp:

(WebCore::Range::toString const):

  • editing/Editing.cpp:

(WebCore::stringWithRebalancedWhitespace):

  • editing/MarkupAccumulator.cpp:

(WebCore::appendCharactersReplacingEntitiesInternal):

  • editing/TextIterator.cpp:

(WebCore::TextIteratorCopyableText::appendToStringBuilder const):

  • html/HTMLTextFormControlElement.cpp:

(WebCore::HTMLTextFormControlElement::valueWithHardLineBreaks const):

  • html/parser/HTMLTokenizer.cpp:

(WebCore::HTMLTokenizer::bufferedCharacters const):

  • platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:

(WebCore::InbandTextTrackPrivateAVF::processNativeSamples):

  • platform/text/SegmentedString.cpp:

(WebCore::SegmentedString::Substring::appendTo const):

  • platform/text/TextCodecICU.cpp:

(WebCore::TextCodecICU::decode):

  • xml/XSLTProcessorLibxslt.cpp:

(WebCore::writeToStringBuilder):
Update for renames.

Source/WebKit:

  • Shared/mac/AuxiliaryProcessMac.mm:

(WebKit::setAndSerializeSandboxParameters):

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::didReceiveInvalidMessage):
Update for renames.

Source/WTF:

  • wtf/HexNumber.h:

(WTF::appendUnsignedAsHexFixedSize):
Add overload that explicitly takes a StringBuilder to work around rename from append to appendCharacters.

  • wtf/text/StringBuilder.cpp:

(WTF::StringBuilder::appendCharacters):
(WTF::StringBuilder::append):

  • wtf/text/StringBuilder.h:

(WTF::StringBuilder::appendCharacters):
(WTF::StringBuilder::append):
(WTF::StringBuilder::appendSubstring):
(WTF::StringBuilder::appendLiteral):
(WTF::IntegerToStringConversionTrait<StringBuilder>::flush):
Update for renames.

Tools:

  • TestWebKitAPI/Tests/WTF/StringBuilder.cpp:

(TestWebKitAPI::TEST):
Update for renames.

3:26 PM Changeset in webkit [248551] by Adrian Perez de Castro
  • 1 copy in releases/WPE WebKit/webkit-2.25.2

WPE WebKit 2.25.2

3:23 PM Changeset in webkit [248550] by dino@apple.com
  • 2 edits in trunk/Source/WebKit

Contextual menu Hide and Show Link Previews should not have a symbol
https://bugs.webkit.org/show_bug.cgi?id=200645
<rdar://problem/54129647>

Reviewed by Wenson Hsieh.

Don't use an image on the UIMenuItem.

  • UIProcess/API/Cocoa/_WKElementAction.mm:

(+[_WKElementAction imageForElementActionType:]): Return nil for Show/Hide Link Previews.

2:43 PM Changeset in webkit [248549] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Unreviewed, add missing WTF::initializeMainThread() call to fix some crashes on the bots after r248533.

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

(WebKit::XPCServiceMain):

2:40 PM Changeset in webkit [248548] by Megan Gardner
  • 4 edits in trunk

Fix Crash in Mail Search
https://bugs.webkit.org/show_bug.cgi?id=200589
Source/WebKit:

<rdar://problem/53666720>

Reviewed by Tim Horton.

If we search in Mail backwards first, for AppKit reasons
we get a -1 for the index of the found item.
Do not try and insert data in this case.

  • UIProcess/mac/WKTextFinderClient.mm:

Tools:

Reviewed by Tim Horton.

If you search backwards first in mail, we would crash,
this tests that codepath.

  • TestWebKitAPI/Tests/WebKitCocoa/FindInPage.mm:

(TEST):

2:37 PM Changeset in webkit [248547] by Adrian Perez de Castro
  • 8 edits in trunk/Source

[WPE][GTK] Fix building without unified sources
https://bugs.webkit.org/show_bug.cgi?id=200641

Reviewed by Žan Doberšek.

Source/JavaScriptCore:

  • b3/B3PatchpointSpecial.cpp: Add missing inclusion of the B3ProcedureInlines.h header.
  • heap/SlotVisitor.cpp: Add missing inclusion of the BlockDirectoryInlines.h header.

Source/WebCore:

  • CMakeLists.txt: Add WebCore as the list of libraries to link into WebCoreTestSupport, to

avoid underlinking, which makes it possible to link with LDFLAGS="-Wl,--no-undefined".

  • editing/WebCorePasteboardFileReader.h: Add missing inclusion of the pal/SessionID.h

header.

Source/WebKit:

  • UIProcess/gtk/WebDataListSuggestionsDropdownGtk.cpp: Add missing inclusions for headers

WebCore/GtkUtilities.h (for convertWidgetPointToScreenPoint), WebCore/IntPoint.h, and
WebPageProxy.h (the two latter to avoid usage of undefined types).
(WebKit::WebDataListSuggestionsDropdownGtk::show): Add namespace prefix to use
WebCore::IntPoint.

1:57 PM Changeset in webkit [248546] by ysuzuki@apple.com
  • 194 edits in trunk/Source

[WTF][JSC] Make JSC and WTF aggressively-fast-malloced
https://bugs.webkit.org/show_bug.cgi?id=200611

Reviewed by Saam Barati.

Source/JavaScriptCore:

This patch aggressively puts many classes into FastMalloc. In JSC side, we grep std::make_unique etc. to find potentially system-malloc-allocated classes.
After this patch, all the JSC related allocations in JetStream2 cli is done from bmalloc. In the future, it would be nice that we add WTF::makeUnique<T> helper
function and throw a compile error if T is not FastMalloc annotated[1].

Putting WebKit classes in FastMalloc has many benefits.

  1. Simply, it is fast.
  2. vmmap can tell the amount of memory used for WebKit.
  3. bmalloc can isolate WebKit memory allocation from the rest of the world. This is useful since we can know more about what component is corrupting the memory from the memory corruption crash.

[1]: https://bugs.webkit.org/show_bug.cgi?id=200620

  • API/ObjCCallbackFunction.mm:
  • assembler/AbstractMacroAssembler.h:
  • b3/B3PhiChildren.h:
  • b3/air/AirAllocateRegistersAndStackAndGenerateCode.h:
  • b3/air/AirDisassembler.h:
  • bytecode/AccessCaseSnippetParams.h:
  • bytecode/CallVariant.h:
  • bytecode/DeferredSourceDump.h:
  • bytecode/ExecutionCounter.h:
  • bytecode/GetByIdStatus.h:
  • bytecode/GetByIdVariant.h:
  • bytecode/InByIdStatus.h:
  • bytecode/InByIdVariant.h:
  • bytecode/InstanceOfStatus.h:
  • bytecode/InstanceOfVariant.h:
  • bytecode/PutByIdStatus.h:
  • bytecode/PutByIdVariant.h:
  • bytecode/ValueProfile.h:
  • dfg/DFGAbstractInterpreter.h:
  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::newVariableAccessData):

  • dfg/DFGFlowIndexing.h:
  • dfg/DFGFlowMap.h:
  • dfg/DFGLiveCatchVariablePreservationPhase.cpp:

(JSC::DFG::LiveCatchVariablePreservationPhase::newVariableAccessData):

  • dfg/DFGMaximalFlushInsertionPhase.cpp:

(JSC::DFG::MaximalFlushInsertionPhase::newVariableAccessData):

  • dfg/DFGOSRExit.h:
  • dfg/DFGSpeculativeJIT.h:
  • dfg/DFGVariableAccessData.h:
  • disassembler/ARM64/A64DOpcode.h:
  • inspector/remote/socket/RemoteInspectorMessageParser.h:
  • inspector/remote/socket/RemoteInspectorSocket.h:
  • inspector/remote/socket/RemoteInspectorSocketEndpoint.h:
  • jit/PCToCodeOriginMap.h:
  • runtime/BasicBlockLocation.h:
  • runtime/DoublePredictionFuzzerAgent.h:
  • runtime/JSRunLoopTimer.h:
  • runtime/PromiseDeferredTimer.h:

(JSC::PromiseDeferredTimer::create): PromiseDeferredTimer should be allocated as Ref<> instead of std::unique_ptr since it is inheriting ThreadSafeRefCounted<>.
Holding such a class with std::unique_ptr could lead to potentially dangerous operations (like, someone holds it with Ref<> while it is deleted by std::unique_ptr<>).

  • runtime/RandomizingFuzzerAgent.h:
  • runtime/SymbolTable.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:
  • tools/JSDollarVM.cpp:
  • tools/SigillCrashAnalyzer.cpp:
  • wasm/WasmFormat.h:
  • wasm/WasmMemory.cpp:
  • wasm/WasmSignature.h:
  • yarr/YarrJIT.h:

Source/WebCore:

Changed the accessor since we changed std::unique_ptr to Ref for this field.

No behavior change.

  • bindings/js/WorkerScriptController.cpp:

(WebCore::WorkerScriptController::addTimerSetNotification):
(WebCore::WorkerScriptController::removeTimerSetNotification):

Source/WTF:

WTF has many data structures, in particular, containers. And these containers can be allocated like std::make_unique<Container>().
Without WTF_MAKE_FAST_ALLOCATED, this container itself is allocated from the system malloc. This patch attaches WTF_MAKE_FAST_ALLOCATED
more aggressively not to allocate them from the system malloc. And we add some final to containers and classes that would be never inherited.

  • wtf/Assertions.cpp:
  • wtf/Atomics.h:
  • wtf/AutodrainedPool.h:
  • wtf/Bag.h:

(WTF::Bag::Bag): Deleted.
(WTF::Bag::~Bag): Deleted.
(WTF::Bag::clear): Deleted.
(WTF::Bag::add): Deleted.
(WTF::Bag::iterator::iterator): Deleted.
(WTF::Bag::iterator::operator! const): Deleted.
(WTF::Bag::iterator::operator* const): Deleted.
(WTF::Bag::iterator::operator++): Deleted.
(WTF::Bag::iterator::operator== const): Deleted.
(WTF::Bag::iterator::operator!= const): Deleted.
(WTF::Bag::begin): Deleted.
(WTF::Bag::begin const): Deleted.
(WTF::Bag::end const): Deleted.
(WTF::Bag::isEmpty const): Deleted.
(WTF::Bag::unwrappedHead const): Deleted.

  • wtf/BitVector.h:

(WTF::BitVector::BitVector): Deleted.
(WTF::BitVector::~BitVector): Deleted.
(WTF::BitVector::operator=): Deleted.
(WTF::BitVector::size const): Deleted.
(WTF::BitVector::ensureSize): Deleted.
(WTF::BitVector::quickGet const): Deleted.
(WTF::BitVector::quickSet): Deleted.
(WTF::BitVector::quickClear): Deleted.
(WTF::BitVector::get const): Deleted.
(WTF::BitVector::contains const): Deleted.
(WTF::BitVector::set): Deleted.
(WTF::BitVector::add): Deleted.
(WTF::BitVector::ensureSizeAndSet): Deleted.
(WTF::BitVector::clear): Deleted.
(WTF::BitVector::remove): Deleted.
(WTF::BitVector::merge): Deleted.
(WTF::BitVector::filter): Deleted.
(WTF::BitVector::exclude): Deleted.
(WTF::BitVector::bitCount const): Deleted.
(WTF::BitVector::isEmpty const): Deleted.
(WTF::BitVector::findBit const): Deleted.
(WTF::BitVector::isEmptyValue const): Deleted.
(WTF::BitVector::isDeletedValue const): Deleted.
(WTF::BitVector::isEmptyOrDeletedValue const): Deleted.
(WTF::BitVector::operator== const): Deleted.
(WTF::BitVector::hash const): Deleted.
(WTF::BitVector::iterator::iterator): Deleted.
(WTF::BitVector::iterator::operator* const): Deleted.
(WTF::BitVector::iterator::operator++): Deleted.
(WTF::BitVector::iterator::isAtEnd const): Deleted.
(WTF::BitVector::iterator::operator== const): Deleted.
(WTF::BitVector::iterator::operator!= const): Deleted.
(WTF::BitVector::begin const): Deleted.
(WTF::BitVector::end const): Deleted.
(WTF::BitVector::bitsInPointer): Deleted.
(WTF::BitVector::maxInlineBits): Deleted.
(WTF::BitVector::byteCount): Deleted.
(WTF::BitVector::makeInlineBits): Deleted.
(WTF::BitVector::cleanseInlineBits): Deleted.
(WTF::BitVector::bitCount): Deleted.
(WTF::BitVector::findBitFast const): Deleted.
(WTF::BitVector::findBitSimple const): Deleted.
(WTF::BitVector::OutOfLineBits::numBits const): Deleted.
(WTF::BitVector::OutOfLineBits::numWords const): Deleted.
(WTF::BitVector::OutOfLineBits::bits): Deleted.
(WTF::BitVector::OutOfLineBits::bits const): Deleted.
(WTF::BitVector::OutOfLineBits::OutOfLineBits): Deleted.
(WTF::BitVector::isInline const): Deleted.
(WTF::BitVector::outOfLineBits const): Deleted.
(WTF::BitVector::outOfLineBits): Deleted.
(WTF::BitVector::bits): Deleted.
(WTF::BitVector::bits const): Deleted.

  • wtf/Bitmap.h:

(WTF::Bitmap::size): Deleted.
(WTF::Bitmap::iterator::iterator): Deleted.
(WTF::Bitmap::iterator::operator* const): Deleted.
(WTF::Bitmap::iterator::operator++): Deleted.
(WTF::Bitmap::iterator::operator== const): Deleted.
(WTF::Bitmap::iterator::operator!= const): Deleted.
(WTF::Bitmap::begin const): Deleted.
(WTF::Bitmap::end const): Deleted.

  • wtf/Box.h:
  • wtf/BumpPointerAllocator.h:
  • wtf/CPUTime.h:
  • wtf/CheckedBoolean.h:
  • wtf/CommaPrinter.h:

(WTF::CommaPrinter::CommaPrinter): Deleted.
(WTF::CommaPrinter::dump const): Deleted.
(WTF::CommaPrinter::didPrint const): Deleted.

  • wtf/CompactPointerTuple.h:

(WTF::CompactPointerTuple::encodeType): Deleted.
(WTF::CompactPointerTuple::decodeType): Deleted.
(WTF::CompactPointerTuple::CompactPointerTuple): Deleted.
(WTF::CompactPointerTuple::pointer const): Deleted.
(WTF::CompactPointerTuple::setPointer): Deleted.
(WTF::CompactPointerTuple::type const): Deleted.
(WTF::CompactPointerTuple::setType): Deleted.

  • wtf/CompilationThread.h:

(WTF::CompilationScope::CompilationScope): Deleted.
(WTF::CompilationScope::~CompilationScope): Deleted.
(WTF::CompilationScope::leaveEarly): Deleted.

  • wtf/CompletionHandler.h:

(WTF::CompletionHandler<Out):
(WTF::Detail::CallableWrapper<CompletionHandler<Out):
(WTF::CompletionHandlerCallingScope::CompletionHandlerCallingScope): Deleted.
(WTF::CompletionHandlerCallingScope::~CompletionHandlerCallingScope): Deleted.
(WTF::CompletionHandlerCallingScope::CompletionHandler<void): Deleted.

  • wtf/ConcurrentBuffer.h:

(WTF::ConcurrentBuffer::ConcurrentBuffer): Deleted.
(WTF::ConcurrentBuffer::~ConcurrentBuffer): Deleted.
(WTF::ConcurrentBuffer::growExact): Deleted.
(WTF::ConcurrentBuffer::grow): Deleted.
(WTF::ConcurrentBuffer::array const): Deleted.
(WTF::ConcurrentBuffer::operator[]): Deleted.
(WTF::ConcurrentBuffer::operator[] const): Deleted.
(WTF::ConcurrentBuffer::createArray): Deleted.

  • wtf/ConcurrentPtrHashSet.h:

(WTF::ConcurrentPtrHashSet::contains): Deleted.
(WTF::ConcurrentPtrHashSet::add): Deleted.
(WTF::ConcurrentPtrHashSet::size const): Deleted.
(WTF::ConcurrentPtrHashSet::Table::maxLoad const): Deleted.
(WTF::ConcurrentPtrHashSet::hash): Deleted.
(WTF::ConcurrentPtrHashSet::cast): Deleted.
(WTF::ConcurrentPtrHashSet::containsImpl const): Deleted.
(WTF::ConcurrentPtrHashSet::addImpl): Deleted.

  • wtf/ConcurrentVector.h:

(WTF::ConcurrentVector::~ConcurrentVector): Deleted.
(WTF::ConcurrentVector::size const): Deleted.
(WTF::ConcurrentVector::isEmpty const): Deleted.
(WTF::ConcurrentVector::at): Deleted.
(WTF::ConcurrentVector::at const): Deleted.
(WTF::ConcurrentVector::operator[]): Deleted.
(WTF::ConcurrentVector::operator[] const): Deleted.
(WTF::ConcurrentVector::first): Deleted.
(WTF::ConcurrentVector::first const): Deleted.
(WTF::ConcurrentVector::last): Deleted.
(WTF::ConcurrentVector::last const): Deleted.
(WTF::ConcurrentVector::takeLast): Deleted.
(WTF::ConcurrentVector::append): Deleted.
(WTF::ConcurrentVector::alloc): Deleted.
(WTF::ConcurrentVector::removeLast): Deleted.
(WTF::ConcurrentVector::grow): Deleted.
(WTF::ConcurrentVector::begin): Deleted.
(WTF::ConcurrentVector::end): Deleted.
(WTF::ConcurrentVector::segmentExistsFor): Deleted.
(WTF::ConcurrentVector::segmentFor): Deleted.
(WTF::ConcurrentVector::subscriptFor): Deleted.
(WTF::ConcurrentVector::ensureSegmentsFor): Deleted.
(WTF::ConcurrentVector::ensureSegment): Deleted.
(WTF::ConcurrentVector::allocateSegment): Deleted.

  • wtf/Condition.h:

(WTF::Condition::waitUntil): Deleted.
(WTF::Condition::waitFor): Deleted.
(WTF::Condition::wait): Deleted.
(WTF::Condition::notifyOne): Deleted.
(WTF::Condition::notifyAll): Deleted.

  • wtf/CountingLock.h:

(WTF::CountingLock::LockHooks::lockHook): Deleted.
(WTF::CountingLock::LockHooks::unlockHook): Deleted.
(WTF::CountingLock::LockHooks::parkHook): Deleted.
(WTF::CountingLock::LockHooks::handoffHook): Deleted.
(WTF::CountingLock::tryLock): Deleted.
(WTF::CountingLock::lock): Deleted.
(WTF::CountingLock::unlock): Deleted.
(WTF::CountingLock::isHeld const): Deleted.
(WTF::CountingLock::isLocked const): Deleted.
(WTF::CountingLock::Count::operator bool const): Deleted.
(WTF::CountingLock::Count::operator== const): Deleted.
(WTF::CountingLock::Count::operator!= const): Deleted.
(WTF::CountingLock::tryOptimisticRead): Deleted.
(WTF::CountingLock::validate): Deleted.
(WTF::CountingLock::doOptimizedRead): Deleted.
(WTF::CountingLock::tryOptimisticFencelessRead): Deleted.
(WTF::CountingLock::fencelessValidate): Deleted.
(WTF::CountingLock::doOptimizedFencelessRead): Deleted.
(WTF::CountingLock::getCount): Deleted.

  • wtf/CrossThreadQueue.h:
  • wtf/CrossThreadTask.h:
  • wtf/CryptographicallyRandomNumber.cpp:
  • wtf/DataMutex.h:
  • wtf/DateMath.h:
  • wtf/Deque.h:

(WTF::Deque::size const): Deleted.
(WTF::Deque::isEmpty const): Deleted.
(WTF::Deque::begin): Deleted.
(WTF::Deque::end): Deleted.
(WTF::Deque::begin const): Deleted.
(WTF::Deque::end const): Deleted.
(WTF::Deque::rbegin): Deleted.
(WTF::Deque::rend): Deleted.
(WTF::Deque::rbegin const): Deleted.
(WTF::Deque::rend const): Deleted.
(WTF::Deque::first): Deleted.
(WTF::Deque::first const): Deleted.
(WTF::Deque::last): Deleted.
(WTF::Deque::last const): Deleted.
(WTF::Deque::append): Deleted.

  • wtf/Dominators.h:
  • wtf/DoublyLinkedList.h:
  • wtf/Expected.h:
  • wtf/FastBitVector.h:
  • wtf/FileMetadata.h:
  • wtf/FileSystem.h:
  • wtf/GraphNodeWorklist.h:
  • wtf/GregorianDateTime.h:

(WTF::GregorianDateTime::GregorianDateTime): Deleted.
(WTF::GregorianDateTime::year const): Deleted.
(WTF::GregorianDateTime::month const): Deleted.
(WTF::GregorianDateTime::yearDay const): Deleted.
(WTF::GregorianDateTime::monthDay const): Deleted.
(WTF::GregorianDateTime::weekDay const): Deleted.
(WTF::GregorianDateTime::hour const): Deleted.
(WTF::GregorianDateTime::minute const): Deleted.
(WTF::GregorianDateTime::second const): Deleted.
(WTF::GregorianDateTime::utcOffset const): Deleted.
(WTF::GregorianDateTime::isDST const): Deleted.
(WTF::GregorianDateTime::setYear): Deleted.
(WTF::GregorianDateTime::setMonth): Deleted.
(WTF::GregorianDateTime::setYearDay): Deleted.
(WTF::GregorianDateTime::setMonthDay): Deleted.
(WTF::GregorianDateTime::setWeekDay): Deleted.
(WTF::GregorianDateTime::setHour): Deleted.
(WTF::GregorianDateTime::setMinute): Deleted.
(WTF::GregorianDateTime::setSecond): Deleted.
(WTF::GregorianDateTime::setUtcOffset): Deleted.
(WTF::GregorianDateTime::setIsDST): Deleted.
(WTF::GregorianDateTime::operator tm const): Deleted.
(WTF::GregorianDateTime::copyFrom): Deleted.

  • wtf/HashTable.h:
  • wtf/Hasher.h:
  • wtf/HexNumber.h:
  • wtf/Indenter.h:
  • wtf/IndexMap.h:
  • wtf/IndexSet.h:
  • wtf/IndexSparseSet.h:
  • wtf/IndexedContainerIterator.h:
  • wtf/Insertion.h:
  • wtf/IteratorAdaptors.h:
  • wtf/IteratorRange.h:
  • wtf/KeyValuePair.h:
  • wtf/ListHashSet.h:

(WTF::ListHashSet::begin): Deleted.
(WTF::ListHashSet::end): Deleted.
(WTF::ListHashSet::begin const): Deleted.
(WTF::ListHashSet::end const): Deleted.
(WTF::ListHashSet::random): Deleted.
(WTF::ListHashSet::random const): Deleted.
(WTF::ListHashSet::rbegin): Deleted.
(WTF::ListHashSet::rend): Deleted.
(WTF::ListHashSet::rbegin const): Deleted.
(WTF::ListHashSet::rend const): Deleted.

  • wtf/Liveness.h:
  • wtf/LocklessBag.h:

(WTF::LocklessBag::LocklessBag): Deleted.
(WTF::LocklessBag::add): Deleted.
(WTF::LocklessBag::iterate): Deleted.
(WTF::LocklessBag::consumeAll): Deleted.
(WTF::LocklessBag::consumeAllWithNode): Deleted.
(WTF::LocklessBag::~LocklessBag): Deleted.

  • wtf/LoggingHashID.h:
  • wtf/MD5.h:
  • wtf/MachSendRight.h:
  • wtf/MainThreadData.h:
  • wtf/Markable.h:
  • wtf/MediaTime.h:
  • wtf/MemoryPressureHandler.h:
  • wtf/MessageQueue.h:

(WTF::MessageQueue::MessageQueue): Deleted.

  • wtf/MetaAllocator.h:
  • wtf/MonotonicTime.h:

(WTF::MonotonicTime::MonotonicTime): Deleted.
(WTF::MonotonicTime::fromRawSeconds): Deleted.
(WTF::MonotonicTime::infinity): Deleted.
(WTF::MonotonicTime::nan): Deleted.
(WTF::MonotonicTime::secondsSinceEpoch const): Deleted.
(WTF::MonotonicTime::approximateMonotonicTime const): Deleted.
(WTF::MonotonicTime::operator bool const): Deleted.
(WTF::MonotonicTime::operator+ const): Deleted.
(WTF::MonotonicTime::operator- const): Deleted.
(WTF::MonotonicTime::operator% const): Deleted.
(WTF::MonotonicTime::operator+=): Deleted.
(WTF::MonotonicTime::operator-=): Deleted.
(WTF::MonotonicTime::operator== const): Deleted.
(WTF::MonotonicTime::operator!= const): Deleted.
(WTF::MonotonicTime::operator< const): Deleted.
(WTF::MonotonicTime::operator> const): Deleted.
(WTF::MonotonicTime::operator<= const): Deleted.
(WTF::MonotonicTime::operator>= const): Deleted.
(WTF::MonotonicTime::isolatedCopy const): Deleted.
(WTF::MonotonicTime::encode const): Deleted.
(WTF::MonotonicTime::decode): Deleted.

  • wtf/NaturalLoops.h:
  • wtf/NoLock.h:
  • wtf/OSAllocator.h:
  • wtf/OptionSet.h:
  • wtf/Optional.h:
  • wtf/OrderMaker.h:
  • wtf/Packed.h:

(WTF::alignof):

  • wtf/PackedIntVector.h:

(WTF::PackedIntVector::PackedIntVector): Deleted.
(WTF::PackedIntVector::operator=): Deleted.
(WTF::PackedIntVector::size const): Deleted.
(WTF::PackedIntVector::ensureSize): Deleted.
(WTF::PackedIntVector::resize): Deleted.
(WTF::PackedIntVector::clearAll): Deleted.
(WTF::PackedIntVector::get const): Deleted.
(WTF::PackedIntVector::set): Deleted.
(WTF::PackedIntVector::mask): Deleted.

  • wtf/PageBlock.h:
  • wtf/ParallelJobsOpenMP.h:
  • wtf/ParkingLot.h:
  • wtf/PriorityQueue.h:

(WTF::PriorityQueue::size const): Deleted.
(WTF::PriorityQueue::isEmpty const): Deleted.
(WTF::PriorityQueue::enqueue): Deleted.
(WTF::PriorityQueue::peek const): Deleted.
(WTF::PriorityQueue::dequeue): Deleted.
(WTF::PriorityQueue::decreaseKey): Deleted.
(WTF::PriorityQueue::increaseKey): Deleted.
(WTF::PriorityQueue::begin const): Deleted.
(WTF::PriorityQueue::end const): Deleted.
(WTF::PriorityQueue::isValidHeap const): Deleted.
(WTF::PriorityQueue::parentOf): Deleted.
(WTF::PriorityQueue::leftChildOf): Deleted.
(WTF::PriorityQueue::rightChildOf): Deleted.
(WTF::PriorityQueue::siftUp): Deleted.
(WTF::PriorityQueue::siftDown): Deleted.

  • wtf/RandomDevice.h:
  • wtf/Range.h:
  • wtf/RangeSet.h:

(WTF::RangeSet::RangeSet): Deleted.
(WTF::RangeSet::~RangeSet): Deleted.
(WTF::RangeSet::add): Deleted.
(WTF::RangeSet::contains const): Deleted.
(WTF::RangeSet::overlaps const): Deleted.
(WTF::RangeSet::clear): Deleted.
(WTF::RangeSet::dump const): Deleted.
(WTF::RangeSet::dumpRaw const): Deleted.
(WTF::RangeSet::begin const): Deleted.
(WTF::RangeSet::end const): Deleted.
(WTF::RangeSet::addAll): Deleted.
(WTF::RangeSet::compact): Deleted.
(WTF::RangeSet::overlapsNonEmpty): Deleted.
(WTF::RangeSet::subsumesNonEmpty): Deleted.
(WTF::RangeSet::findRange const): Deleted.

  • wtf/RecursableLambda.h:
  • wtf/RedBlackTree.h:

(WTF::RedBlackTree::Node::successor const): Deleted.
(WTF::RedBlackTree::Node::predecessor const): Deleted.
(WTF::RedBlackTree::Node::successor): Deleted.
(WTF::RedBlackTree::Node::predecessor): Deleted.
(WTF::RedBlackTree::Node::reset): Deleted.
(WTF::RedBlackTree::Node::parent const): Deleted.
(WTF::RedBlackTree::Node::setParent): Deleted.
(WTF::RedBlackTree::Node::left const): Deleted.
(WTF::RedBlackTree::Node::setLeft): Deleted.
(WTF::RedBlackTree::Node::right const): Deleted.
(WTF::RedBlackTree::Node::setRight): Deleted.
(WTF::RedBlackTree::Node::color const): Deleted.
(WTF::RedBlackTree::Node::setColor): Deleted.
(WTF::RedBlackTree::RedBlackTree): Deleted.
(WTF::RedBlackTree::insert): Deleted.
(WTF::RedBlackTree::remove): Deleted.
(WTF::RedBlackTree::findExact const): Deleted.
(WTF::RedBlackTree::findLeastGreaterThanOrEqual const): Deleted.
(WTF::RedBlackTree::findGreatestLessThanOrEqual const): Deleted.
(WTF::RedBlackTree::first const): Deleted.
(WTF::RedBlackTree::last const): Deleted.
(WTF::RedBlackTree::size): Deleted.
(WTF::RedBlackTree::isEmpty): Deleted.
(WTF::RedBlackTree::treeMinimum): Deleted.
(WTF::RedBlackTree::treeMaximum): Deleted.
(WTF::RedBlackTree::treeInsert): Deleted.
(WTF::RedBlackTree::leftRotate): Deleted.
(WTF::RedBlackTree::rightRotate): Deleted.
(WTF::RedBlackTree::removeFixup): Deleted.

  • wtf/ResourceUsage.h:
  • wtf/RunLoop.cpp:
  • wtf/RunLoopTimer.h:
  • wtf/SHA1.h:
  • wtf/Seconds.h:

(WTF::Seconds::Seconds): Deleted.
(WTF::Seconds::value const): Deleted.
(WTF::Seconds::minutes const): Deleted.
(WTF::Seconds::seconds const): Deleted.
(WTF::Seconds::milliseconds const): Deleted.
(WTF::Seconds::microseconds const): Deleted.
(WTF::Seconds::nanoseconds const): Deleted.
(WTF::Seconds::minutesAs const): Deleted.
(WTF::Seconds::secondsAs const): Deleted.
(WTF::Seconds::millisecondsAs const): Deleted.
(WTF::Seconds::microsecondsAs const): Deleted.
(WTF::Seconds::nanosecondsAs const): Deleted.
(WTF::Seconds::fromMinutes): Deleted.
(WTF::Seconds::fromHours): Deleted.
(WTF::Seconds::fromMilliseconds): Deleted.
(WTF::Seconds::fromMicroseconds): Deleted.
(WTF::Seconds::fromNanoseconds): Deleted.
(WTF::Seconds::infinity): Deleted.
(WTF::Seconds::nan): Deleted.
(WTF::Seconds::operator bool const): Deleted.
(WTF::Seconds::operator+ const): Deleted.
(WTF::Seconds::operator- const): Deleted.
(WTF::Seconds::operator* const): Deleted.
(WTF::Seconds::operator/ const): Deleted.
(WTF::Seconds::operator% const): Deleted.
(WTF::Seconds::operator+=): Deleted.
(WTF::Seconds::operator-=): Deleted.
(WTF::Seconds::operator*=): Deleted.
(WTF::Seconds::operator/=): Deleted.
(WTF::Seconds::operator%=): Deleted.
(WTF::Seconds::operator== const): Deleted.
(WTF::Seconds::operator!= const): Deleted.
(WTF::Seconds::operator< const): Deleted.
(WTF::Seconds::operator> const): Deleted.
(WTF::Seconds::operator<= const): Deleted.
(WTF::Seconds::operator>= const): Deleted.
(WTF::Seconds::isolatedCopy const): Deleted.
(WTF::Seconds::encode const): Deleted.
(WTF::Seconds::decode): Deleted.

  • wtf/SegmentedVector.h:

(WTF::SegmentedVector::~SegmentedVector): Deleted.
(WTF::SegmentedVector::size const): Deleted.
(WTF::SegmentedVector::isEmpty const): Deleted.
(WTF::SegmentedVector::at): Deleted.
(WTF::SegmentedVector::at const): Deleted.
(WTF::SegmentedVector::operator[]): Deleted.
(WTF::SegmentedVector::operator[] const): Deleted.
(WTF::SegmentedVector::first): Deleted.
(WTF::SegmentedVector::first const): Deleted.
(WTF::SegmentedVector::last): Deleted.
(WTF::SegmentedVector::last const): Deleted.
(WTF::SegmentedVector::takeLast): Deleted.
(WTF::SegmentedVector::append): Deleted.
(WTF::SegmentedVector::alloc): Deleted.
(WTF::SegmentedVector::removeLast): Deleted.
(WTF::SegmentedVector::grow): Deleted.
(WTF::SegmentedVector::clear): Deleted.
(WTF::SegmentedVector::begin): Deleted.
(WTF::SegmentedVector::end): Deleted.
(WTF::SegmentedVector::shrinkToFit): Deleted.
(WTF::SegmentedVector::deleteAllSegments): Deleted.
(WTF::SegmentedVector::segmentExistsFor): Deleted.
(WTF::SegmentedVector::segmentFor): Deleted.
(WTF::SegmentedVector::subscriptFor): Deleted.
(WTF::SegmentedVector::ensureSegmentsFor): Deleted.
(WTF::SegmentedVector::ensureSegment): Deleted.
(WTF::SegmentedVector::allocateSegment): Deleted.

  • wtf/SetForScope.h:
  • wtf/SingleRootGraph.h:
  • wtf/SinglyLinkedList.h:
  • wtf/SmallPtrSet.h:
  • wtf/SpanningTree.h:
  • wtf/Spectrum.h:
  • wtf/StackBounds.h:
  • wtf/StackShot.h:
  • wtf/StackShotProfiler.h:
  • wtf/StackStats.h:
  • wtf/StackTrace.h:
  • wtf/StreamBuffer.h:
  • wtf/SynchronizedFixedQueue.h:

(WTF::SynchronizedFixedQueue::create): Deleted.
(WTF::SynchronizedFixedQueue::open): Deleted.
(WTF::SynchronizedFixedQueue::close): Deleted.
(WTF::SynchronizedFixedQueue::isOpen): Deleted.
(WTF::SynchronizedFixedQueue::enqueue): Deleted.
(WTF::SynchronizedFixedQueue::dequeue): Deleted.
(WTF::SynchronizedFixedQueue::SynchronizedFixedQueue): Deleted.

  • wtf/SystemTracing.h:
  • wtf/ThreadGroup.h:

(WTF::ThreadGroup::create): Deleted.
(WTF::ThreadGroup::threads const): Deleted.
(WTF::ThreadGroup::getLock): Deleted.
(WTF::ThreadGroup::weakFromThis): Deleted.

  • wtf/ThreadSpecific.h:
  • wtf/ThreadingPrimitives.h:

(WTF::Mutex::impl): Deleted.

  • wtf/TimeWithDynamicClockType.h:

(WTF::TimeWithDynamicClockType::TimeWithDynamicClockType): Deleted.
(WTF::TimeWithDynamicClockType::fromRawSeconds): Deleted.
(WTF::TimeWithDynamicClockType::secondsSinceEpoch const): Deleted.
(WTF::TimeWithDynamicClockType::clockType const): Deleted.
(WTF::TimeWithDynamicClockType::withSameClockAndRawSeconds const): Deleted.
(WTF::TimeWithDynamicClockType::operator bool const): Deleted.
(WTF::TimeWithDynamicClockType::operator+ const): Deleted.
(WTF::TimeWithDynamicClockType::operator- const): Deleted.
(WTF::TimeWithDynamicClockType::operator+=): Deleted.
(WTF::TimeWithDynamicClockType::operator-=): Deleted.
(WTF::TimeWithDynamicClockType::operator== const): Deleted.
(WTF::TimeWithDynamicClockType::operator!= const): Deleted.

  • wtf/TimingScope.h:
  • wtf/TinyLRUCache.h:
  • wtf/TinyPtrSet.h:
  • wtf/URLParser.cpp:
  • wtf/URLParser.h:
  • wtf/Unexpected.h:
  • wtf/Variant.h:
  • wtf/WTFSemaphore.h:

(WTF::Semaphore::Semaphore): Deleted.
(WTF::Semaphore::signal): Deleted.
(WTF::Semaphore::waitUntil): Deleted.
(WTF::Semaphore::waitFor): Deleted.
(WTF::Semaphore::wait): Deleted.

  • wtf/WallTime.h:

(WTF::WallTime::WallTime): Deleted.
(WTF::WallTime::fromRawSeconds): Deleted.
(WTF::WallTime::infinity): Deleted.
(WTF::WallTime::nan): Deleted.
(WTF::WallTime::secondsSinceEpoch const): Deleted.
(WTF::WallTime::approximateWallTime const): Deleted.
(WTF::WallTime::operator bool const): Deleted.
(WTF::WallTime::operator+ const): Deleted.
(WTF::WallTime::operator- const): Deleted.
(WTF::WallTime::operator+=): Deleted.
(WTF::WallTime::operator-=): Deleted.
(WTF::WallTime::operator== const): Deleted.
(WTF::WallTime::operator!= const): Deleted.
(WTF::WallTime::operator< const): Deleted.
(WTF::WallTime::operator> const): Deleted.
(WTF::WallTime::operator<= const): Deleted.
(WTF::WallTime::operator>= const): Deleted.
(WTF::WallTime::isolatedCopy const): Deleted.

  • wtf/WeakHashSet.h:

(WTF::WeakHashSet::WeakHashSetConstIterator::WeakHashSetConstIterator): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::get const): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::operator* const): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::operator-> const): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::operator++): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::skipEmptyBuckets): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::operator== const): Deleted.
(WTF::WeakHashSet::WeakHashSetConstIterator::operator!= const): Deleted.
(WTF::WeakHashSet::WeakHashSet): Deleted.
(WTF::WeakHashSet::begin const): Deleted.
(WTF::WeakHashSet::end const): Deleted.
(WTF::WeakHashSet::add): Deleted.
(WTF::WeakHashSet::remove): Deleted.
(WTF::WeakHashSet::contains const): Deleted.
(WTF::WeakHashSet::capacity const): Deleted.
(WTF::WeakHashSet::computesEmpty const): Deleted.
(WTF::WeakHashSet::hasNullReferences const): Deleted.
(WTF::WeakHashSet::computeSize const): Deleted.
(WTF::WeakHashSet::checkConsistency const): Deleted.

  • wtf/WeakRandom.h:

(WTF::WeakRandom::WeakRandom): Deleted.
(WTF::WeakRandom::setSeed): Deleted.
(WTF::WeakRandom::seed const): Deleted.
(WTF::WeakRandom::get): Deleted.
(WTF::WeakRandom::getUint32): Deleted.
(WTF::WeakRandom::lowOffset): Deleted.
(WTF::WeakRandom::highOffset): Deleted.
(WTF::WeakRandom::nextState): Deleted.
(WTF::WeakRandom::generate): Deleted.
(WTF::WeakRandom::advance): Deleted.

  • wtf/WordLock.h:

(WTF::WordLock::lock): Deleted.
(WTF::WordLock::unlock): Deleted.
(WTF::WordLock::isHeld const): Deleted.
(WTF::WordLock::isLocked const): Deleted.
(WTF::WordLock::isFullyReset const): Deleted.

  • wtf/generic/MainThreadGeneric.cpp:
  • wtf/glib/GMutexLocker.h:
  • wtf/linux/CurrentProcessMemoryStatus.h:
  • wtf/posix/ThreadingPOSIX.cpp:

(WTF::Semaphore::Semaphore): Deleted.
(WTF::Semaphore::~Semaphore): Deleted.
(WTF::Semaphore::wait): Deleted.
(WTF::Semaphore::post): Deleted.

  • wtf/text/ASCIILiteral.h:

(WTF::ASCIILiteral::operator const char* const): Deleted.
(WTF::ASCIILiteral::fromLiteralUnsafe): Deleted.
(WTF::ASCIILiteral::null): Deleted.
(WTF::ASCIILiteral::characters const): Deleted.
(WTF::ASCIILiteral::ASCIILiteral): Deleted.

  • wtf/text/AtomString.h:

(WTF::AtomString::operator=): Deleted.
(WTF::AtomString::isHashTableDeletedValue const): Deleted.
(WTF::AtomString::existingHash const): Deleted.
(WTF::AtomString::operator const String& const): Deleted.
(WTF::AtomString::string const): Deleted.
(WTF::AtomString::impl const): Deleted.
(WTF::AtomString::is8Bit const): Deleted.
(WTF::AtomString::characters8 const): Deleted.
(WTF::AtomString::characters16 const): Deleted.
(WTF::AtomString::length const): Deleted.
(WTF::AtomString::operator[] const): Deleted.
(WTF::AtomString::contains const): Deleted.
(WTF::AtomString::containsIgnoringASCIICase const): Deleted.
(WTF::AtomString::find const): Deleted.
(WTF::AtomString::findIgnoringASCIICase const): Deleted.
(WTF::AtomString::startsWith const): Deleted.
(WTF::AtomString::startsWithIgnoringASCIICase const): Deleted.
(WTF::AtomString::endsWith const): Deleted.
(WTF::AtomString::endsWithIgnoringASCIICase const): Deleted.
(WTF::AtomString::toInt const): Deleted.
(WTF::AtomString::toDouble const): Deleted.
(WTF::AtomString::toFloat const): Deleted.
(WTF::AtomString::percentage const): Deleted.
(WTF::AtomString::isNull const): Deleted.
(WTF::AtomString::isEmpty const): Deleted.
(WTF::AtomString::operator NSString * const): Deleted.

  • wtf/text/AtomStringImpl.h:

(WTF::AtomStringImpl::lookUp): Deleted.
(WTF::AtomStringImpl::add): Deleted.
(WTF::AtomStringImpl::addWithStringTableProvider): Deleted.

  • wtf/text/CString.h:

(WTF::CStringBuffer::data): Deleted.
(WTF::CStringBuffer::length const): Deleted.
(WTF::CStringBuffer::CStringBuffer): Deleted.
(WTF::CStringBuffer::mutableData): Deleted.
(WTF::CString::CString): Deleted.
(WTF::CString::data const): Deleted.
(WTF::CString::length const): Deleted.
(WTF::CString::isNull const): Deleted.
(WTF::CString::buffer const): Deleted.
(WTF::CString::isHashTableDeletedValue const): Deleted.

  • wtf/text/ExternalStringImpl.h:

(WTF::ExternalStringImpl::freeExternalBuffer): Deleted.

  • wtf/text/LineBreakIteratorPoolICU.h:
  • wtf/text/NullTextBreakIterator.h:
  • wtf/text/OrdinalNumber.h:
  • wtf/text/StringBuffer.h:
  • wtf/text/StringBuilder.h:
  • wtf/text/StringConcatenateNumbers.h:
  • wtf/text/StringHasher.h:
  • wtf/text/StringImpl.h:
  • wtf/text/StringView.cpp:
  • wtf/text/StringView.h:

(WTF::StringView::left const): Deleted.
(WTF::StringView::right const): Deleted.
(WTF::StringView::underlyingStringIsValid const): Deleted.
(WTF::StringView::setUnderlyingString): Deleted.

  • wtf/text/SymbolImpl.h:

(WTF::SymbolImpl::StaticSymbolImpl::StaticSymbolImpl): Deleted.
(WTF::SymbolImpl::StaticSymbolImpl::operator SymbolImpl&): Deleted.
(WTF::PrivateSymbolImpl::PrivateSymbolImpl): Deleted.
(WTF::RegisteredSymbolImpl::symbolRegistry const): Deleted.
(WTF::RegisteredSymbolImpl::clearSymbolRegistry): Deleted.
(WTF::RegisteredSymbolImpl::RegisteredSymbolImpl): Deleted.

  • wtf/text/SymbolRegistry.h:
  • wtf/text/TextBreakIterator.h:
  • wtf/text/TextPosition.h:
  • wtf/text/TextStream.h:
  • wtf/text/WTFString.h:

(WTF::String::swap): Deleted.
(WTF::String::adopt): Deleted.
(WTF::String::isNull const): Deleted.
(WTF::String::isEmpty const): Deleted.
(WTF::String::impl const): Deleted.
(WTF::String::releaseImpl): Deleted.
(WTF::String::length const): Deleted.
(WTF::String::characters8 const): Deleted.
(WTF::String::characters16 const): Deleted.
(WTF::String::is8Bit const): Deleted.
(WTF::String::sizeInBytes const): Deleted.
(WTF::String::operator[] const): Deleted.
(WTF::String::find const): Deleted.
(WTF::String::findIgnoringASCIICase const): Deleted.
(WTF::String::reverseFind const): Deleted.
(WTF::String::contains const): Deleted.
(WTF::String::containsIgnoringASCIICase const): Deleted.
(WTF::String::startsWith const): Deleted.
(WTF::String::startsWithIgnoringASCIICase const): Deleted.
(WTF::String::hasInfixStartingAt const): Deleted.
(WTF::String::endsWith const): Deleted.
(WTF::String::endsWithIgnoringASCIICase const): Deleted.
(WTF::String::hasInfixEndingAt const): Deleted.
(WTF::String::append): Deleted.
(WTF::String::left const): Deleted.
(WTF::String::right const): Deleted.
(WTF::String::createUninitialized): Deleted.
(WTF::String::fromUTF8WithLatin1Fallback): Deleted.
(WTF::String::isAllASCII const): Deleted.
(WTF::String::isAllLatin1 const): Deleted.
(WTF::String::isSpecialCharacter const): Deleted.
(WTF::String::isHashTableDeletedValue const): Deleted.
(WTF::String::hash const): Deleted.
(WTF::String::existingHash const): Deleted.

  • wtf/text/cf/TextBreakIteratorCF.h:
  • wtf/text/icu/TextBreakIteratorICU.h:
  • wtf/text/icu/UTextProviderLatin1.h:
  • wtf/threads/BinarySemaphore.h:

(WTF::BinarySemaphore::waitFor): Deleted.
(WTF::BinarySemaphore::wait): Deleted.

  • wtf/unicode/Collator.h:
  • wtf/win/GDIObject.h:
  • wtf/win/PathWalker.h:
  • wtf/win/Win32Handle.h:
1:38 PM Changeset in webkit [248545] by Alan Coon
  • 1 copy in tags/Safari-608.1.48

Tag Safari-608.1.48.

1:15 PM Changeset in webkit [248544] by Chris Dumez
  • 2 edits in trunk/Source/WTF

Unreviewed, fix post landing review comments for r248533 from Darin.

  • wtf/RefCounted.h:

(WTF::RefCountedBase::ref const):
(WTF::RefCountedBase::applyRefDerefThreadingCheck const):
(WTF::RefCountedBase::derefBase const):
(WTF::RefCountedBase::areThreadingCheckedEnabled const): Deleted.

12:46 PM Changeset in webkit [248543] by sihui_liu@apple.com
  • 2 edits in trunk/Source/WebKit

Clear m_sessionStorageNamespaces on the background thread
https://bugs.webkit.org/show_bug.cgi?id=200631
<rdar://problem/54149638>

Reviewed by Chris Dumez.

Network process receives messages about web page state from web process and destroys sessionStorageNamespace if
needed. It also receives messages about session state from UI process and destroys StorageManager, which owns
SessionStorageNamespaces, if needed. Because of the race in receiving the messages from different processes,
network process may decide to destroy StorageManager before destroying all SessionStorageNamespaces, and
SessionStorageNamespaces are destroyed with StorageManager on the main thread.

  • NetworkProcess/WebStorage/StorageManager.cpp:

(WebKit::StorageManager::waitUntilTasksFinished):

12:33 PM Changeset in webkit [248542] by sihui_liu@apple.com
  • 2 edits in trunk/Source/WebKit

Remove an assertion in ~StorageArea()
https://bugs.webkit.org/show_bug.cgi?id=200630
<rdar://problem/54097722>

Reviewed by Chris Dumez.

In r247370, we clear the LocalStorageNamespace before the destructor of LocalStorageNamespace is invoked, to
make sure StorageArea gets destroyed on the background thread.
StorageArea can get destroyed before LocalStorageNamespace, so the assertion in ~StorageArea() is not true any
more.

  • NetworkProcess/WebStorage/StorageArea.cpp:

(WebKit::StorageArea::~StorageArea):

12:31 PM Changeset in webkit [248541] by Wenson Hsieh
  • 4 edits in trunk

[iPadOS] Web pages sometimes load at half width in Safari
https://bugs.webkit.org/show_bug.cgi?id=200624
<rdar://problem/52694257>

Reviewed by Simon Fraser.

Source/WebKit:

Whenever WKWebView's size changes, it normally notifies the web content process by calling into WebPageProxy::
setViewportConfigurationViewLayoutSize, which remembers this view layout size using a member variable,
m_viewportConfigurationViewLayoutSize. Later, m_viewportConfigurationViewLayoutSize is consulted as a part of
constructing the creation parameters used to set up a new page.

However, during animated resize, WKWebView avoids these calls to setViewportConfigurationViewLayoutSize via the
dynamic viewport update mode check in -[WKWebView _frameOrBoundsChanged]. Instead, the new view layout size is
pushed to the web process by calling WebPageProxy::dynamicViewportSizeUpdate.

Since dynamicViewportSizeUpdate doesn't update m_viewportConfigurationViewLayoutSize, the next
WebPageCreationParameters that are created with this WebPageProxy (e.g. after a process swap, or after
reloading, if the process was terminated) will use the size of the WKWebView prior to the most recent animated
resize.

To fix the bug, we simply make sure that m_viewportConfigurationViewLayoutSize is updated in the dynamic
viewport size update (i.e. animated resize) case as well.

Test: WebKit.CreateWebPageAfterAnimatedResize

  • UIProcess/ios/WebPageProxyIOS.mm:

(WebKit::WebPageProxy::dynamicViewportSizeUpdate):

Tools:

Add an API test to verify that after performing an animated resize and killing the web process, the subsequent
web page is created using the post-animated-resize web view dimensions, rather than the original layout
dimensions.

  • TestWebKitAPI/Tests/WebKitCocoa/AnimatedResize.mm:
12:22 PM Changeset in webkit [248540] by Chris Dumez
  • 3 edits in trunk/Source/WebKit

Crash under NetworkResourceLoader::start()
https://bugs.webkit.org/show_bug.cgi?id=200628

Reviewed by Youenn Fablet.

Make sure the NetworkResourceLoader is still alive when the lambda passed to NetworkLoadChecker::check()
gets executed.

  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::start):
(WebKit::NetworkResourceLoader::retrieveCacheEntry):

  • NetworkProcess/NetworkResourceLoader.h:
12:17 PM Changeset in webkit [248539] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: Styles: add space between media query and style icon
https://bugs.webkit.org/show_bug.cgi?id=200623

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:

(WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):

  • UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:

(.spreadsheet-css-declaration .header:not(:first-child), .spreadsheet-css-declaration .header:not(.editing-selector) .selector, .spreadsheet-css-declaration.has-icon .header.editing-selector .selector): Added.
(.spreadsheet-css-declaration .header.editing-selector .selector): Deleted.
Ensure the selector field doesn't shift vertically when entering/exiting editing mode.

12:13 PM Changeset in webkit [248538] by youenn@apple.com
  • 7 edits in trunk/Source/WebCore

Make Blob::m_size an Optional
https://bugs.webkit.org/show_bug.cgi?id=200617

Reviewed by Alex Christensen.

Use an Optional instead of -1 to know that m_size is initialized or not.
No change of behavior.

Refactoring to make all Blob members private.
Remove one static Blob create method.

Covered by existing tests.

  • Modules/fetch/FetchBody.cpp:

(WebCore::FetchBody::fromFormData):

  • fileapi/Blob.cpp:

(WebCore::Blob::Blob):
(WebCore::Blob::size const):

  • fileapi/Blob.h:

(WebCore::Blob::setInternalURL):

  • fileapi/File.cpp:

(WebCore::File::create):
(WebCore::File::File):
(WebCore::File::computeNameAndContentType):

  • fileapi/File.h:
  • html/FileListCreator.cpp:

(WebCore::FileListCreator::createFileList):

11:49 AM Changeset in webkit [248537] by Joseph Pecoraro
  • 21 edits in trunk/Source/WebInspectorUI

Web Inspector: Address some ESLint warnings
https://bugs.webkit.org/show_bug.cgi?id=200598

Reviewed by Devin Rousso.

  • UserInterface/Base/Utilities.js:
  • UserInterface/Controllers/TimelineManager.js:
  • UserInterface/Models/DOMNodeStyles.js:
  • UserInterface/Models/LayoutTimelineRecord.js:
  • UserInterface/Models/ServerTimingEntry.js:
  • UserInterface/Models/TimelineRecording.js:
  • UserInterface/Protocol/RemoteObject.js:
  • UserInterface/Test/FrontendTestHarness.js:
  • UserInterface/Test/Test.js:
  • UserInterface/Views/CPUTimelineView.js:
  • UserInterface/Views/CPUUsageCombinedView.js:
  • UserInterface/Views/ChangesDetailsSidebarPanel.js:
  • UserInterface/Views/DOMTreeContentView.js:
  • UserInterface/Views/DOMTreeElement.js:
  • UserInterface/Views/DebuggerSidebarPanel.js:
  • UserInterface/Views/NetworkTableContentView.js:
  • UserInterface/Views/ResourceTimingBreakdownView.js:
  • UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
  • UserInterface/Views/TreeOutline.js:
11:45 AM Changeset in webkit [248536] by Joseph Pecoraro
  • 13 edits in trunk/Source/WebInspectorUI

Web Inspector: Better organize manager / observer API groups
https://bugs.webkit.org/show_bug.cgi?id=200594

Reviewed by Devin Rousso.

  • UserInterface/Controllers/DebuggerManager.js:

(WI.DebuggerManager.prototype.globalObjectCleared):
(WI.DebuggerManager.prototype.reset): Deleted.
Renamed.

  • UserInterface/Protocol/DebuggerObserver.js:

(WI.DebuggerObserver.prototype.globalObjectCleared):

  • UserInterface/Controllers/CSSManager.js:
  • UserInterface/Controllers/CanvasManager.js:
  • UserInterface/Controllers/ConsoleManager.js:
  • UserInterface/Controllers/DOMManager.js:
  • UserInterface/Controllers/DOMStorageManager.js:
  • UserInterface/Controllers/LayerTreeManager.js:
  • UserInterface/Controllers/NetworkManager.js:
  • UserInterface/Controllers/TargetManager.js:
  • UserInterface/Controllers/TimelineManager.js:
  • UserInterface/Controllers/WorkerManager.js:
11:42 AM Changeset in webkit [248535] by Jonathan Bedard
  • 2 edits in trunk/Source/WebKit

Tapping buttons in Data Detectors lookup previews doesn't work (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=200579
<rdar://problem/54056519>

Reviewed by Megan Gardner.

  • Platform/spi/ios/UIKitSPI.h: Add _UIContextMenuStyle SPI.
11:20 AM Changeset in webkit [248534] by Alan Coon
  • 7 edits in branches/safari-608.1-branch/Source

Versioning.

11:10 AM Changeset in webkit [248533] by Chris Dumez
  • 15 edits
    1 add in trunk/Source

Add threading assertions to RefCounted
https://bugs.webkit.org/show_bug.cgi?id=200507

Reviewed by Ryosuke Niwa.

Source/JavaScriptCore:

  • dfg/DFGPlan.cpp:

(JSC::DFG::Plan::Plan):
Disable threading assertions for DFG::Plan::m_inlineCallFrames while the JSC team
investigates.

Source/WebKit:

Enable new RefCounted threading assertions for WebKit2
(UIProcess + auxiliary processes).

  • Shared/AuxiliaryProcess.cpp:

(WebKit::AuxiliaryProcess::initialize):

  • Shared/Cocoa/WebKit2InitializeCocoa.mm:

(WebKit::runInitializationCode):

  • Shared/WebKit2Initialize.cpp:

(WebKit::InitializeWebKit2):

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:

(+[WebView initialize]):
Enable new RefCounted threading assertions for WebKitLegacy.

Source/WTF:

Add threading assertions to RefCounted to try and catch unsafe concurrent ref'ing / derefing of
RefCounted objects from several threads. If you hit these new assertions, it likely means you either
need to:

  1. Have your class subclass ThreadSafeRefCounted instead of RefCounted

or

  1. Make sure your objects always gets ref'd / deref'd from the same thread.

These assertions already found several thread safety bugs in our code base, which I fixed via
dependency bugs.

These assertions are currently enabled in WebKit (UIProcess, child processes and
WebKitLegacy), they do not apply other JavascriptCore API clients.

  • WTF.xcodeproj/project.pbxproj:
  • wtf/CMakeLists.txt:
  • wtf/RefCounted.cpp: Added.
  • wtf/RefCounted.h:

(WTF::RefCountedBase::ref const):
(WTF::RefCountedBase::disableThreadingChecks):
(WTF::RefCountedBase::enableThreadingChecksGlobally):
(WTF::RefCountedBase::RefCountedBase):
(WTF::RefCountedBase::areThreadingCheckedEnabled const):
(WTF::RefCountedBase::derefBase const):

  • wtf/SizeLimits.cpp:
10:27 AM Changeset in webkit [248532] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

GPUBuffer seems to be ref'd / deref'd from multiple thread concurrently but is not ThreadSafeRefCounted
https://bugs.webkit.org/show_bug.cgi?id=200629

Reviewed by Geoffrey Garen.

Make sure GPUBuffer only gets ref'd / deref'd on the main thread, since it is not
ThreadSafeRefCounted.

  • platform/graphics/gpu/cocoa/GPUBufferMetal.mm:

(WebCore::GPUBuffer::commandBufferCommitted):
(WebCore::GPUBuffer::commandBufferCompleted):

10:13 AM Changeset in webkit [248531] by dbates@webkit.org
  • 7 edits
    2 adds in trunk

Add a test to ensure that we dispatch keydown and keyup events when multiple keys are pressed at the same time
https://bugs.webkit.org/show_bug.cgi?id=200548

Reviewed by Darin Adler.

Tools:

Expose infrastructure to simulate a literal raw key down and a literal key up event.

  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
  • TestRunnerShared/UIScriptContext/UIScriptController.h:

(WTR::UIScriptController::rawKeyDown):
(WTR::UIScriptController::rawKeyUp):

  • WebKitTestRunner/ios/UIScriptControllerIOS.h:
  • WebKitTestRunner/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptControllerIOS::rawKeyDown):
(WTR::UIScriptControllerIOS::rawKeyUp):

LayoutTests:

Add a test. Skip the test for now until we have the fixes for <rdar://problem/53613454> and <rdar://problem/54001139>.

  • fast/events/ios/multiple-key-press-and-release-ordering-expected.txt: Added.
  • fast/events/ios/multiple-key-press-and-release-ordering.html: Added.
  • platform/ios/TestExpectations:
9:56 AM Changeset in webkit [248530] by commit-queue@webkit.org
  • 6 edits
    1 add in trunk

[GStreamer][WebRTC] Handle broken data in the libwebrtc GStreamer decoders
https://bugs.webkit.org/show_bug.cgi?id=200584

Patch by Thibault Saunier <tsaunier@igalia.com> on 2019-08-12
Reviewed by Philippe Normand.

Source/WebCore:

Listening to parsers warnings and error messages (synchronously so that we react
right away) and requesting keyframes from the peer.

Also simplify the decoder code by trying to make decoding happen
in one single pass, also hiding away GStreamer threading and allowing
us to react as soon as the decoder/parser fails.

  • platform/mediastream/libwebrtc/GStreamerVideoDecoderFactory.cpp:

(WebCore::GStreamerVideoDecoder::GStreamerVideoDecoder):
(WebCore::GStreamerVideoDecoder::pullSample):
(WebCore::H264Decoder::H264Decoder):

  • platform/mediastream/libwebrtc/GStreamerVideoEncoderFactory.cpp:

Tools:

Added a h264parse patch to post WARNING on the bus when a broken frame is detected.
Ignore style libwebrtc optionnal 'style issue'

  • Scripts/webkitpy/style/checker.py:
  • gstreamer/jhbuild.modules:
  • gstreamer/patches/gst-plugins-bad-0001-h264parse-Post-a-WARNING-when-data-is-broken.patch: Added.
9:06 AM Changeset in webkit [248529] by Chris Dumez
  • 13 edits
    1 delete in trunk/Source

Unreviewed, rolling out r248525.

Revert new threading assertions while I work on fixing the
issues they exposed

Reverted changeset:

"Add threading assertions to RefCounted"
https://bugs.webkit.org/show_bug.cgi?id=200507
https://trac.webkit.org/changeset/248525

8:31 AM Changeset in webkit [248528] by Antti Koivisto
  • 10 edits in trunk/Source/WebCore

Only construct ComplexLineLayout when needed
https://bugs.webkit.org/show_bug.cgi?id=200625

Reviewed by Zalan Bujtas.

  • rendering/ComplexLineLayout.cpp:

(WebCore::ComplexLineLayout::createInlineBoxForRenderer):
(WebCore::ComplexLineLayout::createLineBoxes):
(WebCore::ComplexLineLayout::constructLine):
(WebCore::ComplexLineLayout::updateLogicalWidthForAlignment):

Make static so this can be invoked without constructing complex line layout (from startAlignedOffsetForLine).

(WebCore::ComplexLineLayout::computeInlineDirectionPositionsForSegment):
(WebCore::ComplexLineLayout::deleteEllipsisLineBoxes):
(WebCore::ComplexLineLayout::checkLinesForTextOverflow):
(WebCore::ComplexLineLayout::startAlignedOffsetForLine): Deleted.

This is also used in block layout to set static positions of positioned objects.
Move to RenderBlockFlow where its only caller is.

  • rendering/ComplexLineLayout.h:
  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::RenderBlockFlow):
(WebCore::RenderBlockFlow::willBeDestroyed):
(WebCore::RenderBlockFlow::layoutInlineChildren):
(WebCore::RenderBlockFlow::updateStaticInlinePositionForChild):
(WebCore::RenderBlockFlow::startAlignedOffsetForLine):
(WebCore::RenderBlockFlow::deleteLines):
(WebCore::RenderBlockFlow::hitTestInlineChildren):
(WebCore::RenderBlockFlow::addOverflowFromInlineChildren):
(WebCore::RenderBlockFlow::paintInlineChildren):
(WebCore::RenderBlockFlow::hasLines const):
(WebCore::RenderBlockFlow::layoutSimpleLines):
(WebCore::RenderBlockFlow::deleteLineBoxesBeforeSimpleLineLayout):
(WebCore::RenderBlockFlow::ensureLineBoxes):

  • rendering/RenderBlockFlow.h:

(WebCore::RenderBlockFlow::firstRootBox const):
(WebCore::RenderBlockFlow::lastRootBox const):
(WebCore::RenderBlockFlow::complexLineLayout):
(WebCore::RenderBlockFlow::lineBoxes): Deleted.
(WebCore::RenderBlockFlow::lineBoxes const): Deleted.

  • rendering/RootInlineBox.cpp:

(WebCore::RootInlineBox::removeLineBoxFromRenderObject):
(WebCore::RootInlineBox::extractLineBoxFromRenderObject):
(WebCore::RootInlineBox::attachLineBoxToRenderObject):

  • rendering/SimpleLineLayoutFunctions.cpp:

(WebCore::SimpleLineLayout::generateLineBoxTree):

4:39 AM Changeset in webkit [248527] by youenn@apple.com
  • 11 edits in trunk/Source/WebCore

Remove IDBValue::m_sessionID
https://bugs.webkit.org/show_bug.cgi?id=199320

Reviewed by Alex Christensen.

Remove sessionID from IDBValue.
This does not seem to be really used in any way.
No change of behavior.

  • Modules/indexeddb/IDBValue.cpp:

(WebCore::IDBValue::IDBValue):

  • Modules/indexeddb/IDBValue.h:

(WebCore::IDBValue::blobURLs const):
(WebCore::IDBValue::encode const):
(WebCore::IDBValue::decode):
(WebCore::IDBValue::sessionID const): Deleted.

  • Modules/indexeddb/shared/IDBRequestData.cpp:

(WebCore::IDBRequestData::isolatedCopy):

  • Modules/indexeddb/shared/IDBRequestData.h:

(WebCore::IDBRequestData::databaseIdentifier const):
(WebCore::IDBRequestData::decode):

  • bindings/js/IDBBindingUtilities.cpp:

(WebCore::deserializeIDBValueToJSValue):

  • bindings/js/SerializedScriptValue.cpp:

(WebCore::CloneSerializer::serialize):
(WebCore::CloneSerializer::CloneSerializer):
(WebCore::CloneSerializer::dumpIfTerminal):
(WebCore::CloneDeserializer::deserialize):
(WebCore::CloneDeserializer::CloneDeserializer):
(WebCore::SerializedScriptValue::SerializedScriptValue):
(WebCore::SerializedScriptValue::create):
(WebCore::SerializedScriptValue::deserialize):
(WebCore::SerializedScriptValue::writeBlobsToDiskForIndexedDB):

  • bindings/js/SerializedScriptValue.h:

(WebCore::SerializedScriptValue::sessionID const): Deleted.

3:07 AM Changeset in webkit [248526] by youenn@apple.com
  • 39 edits in trunk

Remove IDB-specific quota
https://bugs.webkit.org/show_bug.cgi?id=196545

Reviewed by Alex Christensen.

Source/WebCore:

No change of behavior as IDB specific quota is no longer used.
Instead a global quota is used. This quota currently handles IDB and Cache API.

  • Modules/indexeddb/server/IDBBackingStore.h:
  • Modules/indexeddb/server/IDBServer.cpp:

(WebCore::IDBServer::IDBServer::createBackingStore):
(WebCore::IDBServer::IDBServer::setPerOriginQuota): Deleted.

  • Modules/indexeddb/server/IDBServer.h:

(WebCore::IDBServer::IDBServer::perOriginQuota const): Deleted.

  • Modules/indexeddb/server/MemoryIDBBackingStore.h:
  • Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:

(WebCore::IDBServer::SQLiteIDBBackingStore::SQLiteIDBBackingStore):
(WebCore::IDBServer::SQLiteIDBBackingStore::beginTransaction):
(WebCore::IDBServer::SQLiteIDBBackingStore::createObjectStore):
(WebCore::IDBServer::SQLiteIDBBackingStore::renameObjectStore):
(WebCore::IDBServer::SQLiteIDBBackingStore::createIndex):
(WebCore::IDBServer::SQLiteIDBBackingStore::uncheckedPutIndexRecord):
(WebCore::IDBServer::SQLiteIDBBackingStore::renameIndex):
(WebCore::IDBServer::SQLiteIDBBackingStore::addRecord):
(WebCore::IDBServer::SQLiteIDBBackingStore::uncheckedSetKeyGeneratorValue):
(WebCore::IDBServer::SQLiteIDBBackingStore::quotaForOrigin const): Deleted.
(WebCore::IDBServer::SQLiteIDBBackingStore::maximumSize const): Deleted.

  • Modules/indexeddb/server/SQLiteIDBBackingStore.h:
  • Modules/indexeddb/server/UniqueIDBDatabase.cpp:

(WebCore::IDBServer::UniqueIDBDatabase::setQuota): Deleted.

  • Modules/indexeddb/server/UniqueIDBDatabase.h:

Source/WebKit:

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::createIDBServer):
(WebKit::NetworkProcess::addIndexedDatabaseSession):
(WebKit::NetworkProcess::setIDBPerOriginQuota): Deleted.

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • UIProcess/API/C/WKContext.cpp:

(WKContextSetIDBPerOriginQuota): Deleted.

  • UIProcess/API/C/WKContextPrivate.h:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::setIDBPerOriginQuota): Deleted.

  • UIProcess/WebProcessPool.h:

Source/WebKitLegacy:

  • Storage/WebDatabaseProvider.cpp:

(WebDatabaseProvider::idbConnectionToServerForSession):
(WebDatabaseProvider::deleteAllDatabases):
(WebDatabaseProvider::setIDBPerOriginQuota): Deleted.

  • Storage/WebDatabaseProvider.h:

Source/WebKitLegacy/mac:

  • Storage/WebDatabaseManager.mm:

(-[WebDatabaseManager setIDBPerOriginQuota:]): Deleted.

  • Storage/WebDatabaseManagerPrivate.h:

Source/WebKitLegacy/win:

  • Interfaces/IWebDatabaseManager.idl:
  • WebDatabaseManager.cpp:

(WebDatabaseManager::setIDBPerOriginQuota): Deleted.

  • WebDatabaseManager.h:

Tools:

  • DumpRenderTree/TestRunner.cpp:

(TestRunner::staticFunctions):
(setIDBPerOriginQuotaCallback): Deleted.

  • DumpRenderTree/TestRunner.h:
  • DumpRenderTree/mac/DumpRenderTree.mm:

(runTest):

  • DumpRenderTree/mac/TestRunnerMac.mm:

(TestRunner::setIDBPerOriginQuota): Deleted.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::setIDBPerOriginQuota): Deleted.

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetStateToConsistentValues):
(WTR::TestController::setIDBPerOriginQuota): Deleted.

  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

Aug 11, 2019:

7:00 PM Changeset in webkit [248525] by Chris Dumez
  • 13 edits
    1 add in trunk/Source

Add threading assertions to RefCounted
https://bugs.webkit.org/show_bug.cgi?id=200507

Reviewed by Ryosuke Niwa.

Source/JavaScriptCore:

  • dfg/DFGPlan.cpp:

(JSC::DFG::Plan::Plan):
Disable threading assertions for DFG::Plan::m_inlineCallFrames while the JSC team
investigates.

Source/WebKit:

Enable new RefCounted threading assertions for WebKit2
(UIProcess + auxiliary processes).

  • Shared/AuxiliaryProcess.cpp:

(WebKit::AuxiliaryProcess::initialize):

  • Shared/Cocoa/WebKit2InitializeCocoa.mm:

(WebKit::runInitializationCode):

  • Shared/WebKit2Initialize.cpp:

(WebKit::InitializeWebKit2):

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:

(+[WebView initialize]):
Enable new RefCounted threading assertions for WebKitLegacy.

Source/WTF:

Add threading assertions to RefCounted to try and catch unsafe concurrent ref'ing / derefing of
RefCounted objects from several threads. If you hit these new assertions, it likely means you either
need to:

  1. Have your class subclass ThreadSafeRefCounted instead of RefCounted

or

  1. Make sure your objects always gets ref'd / deref'd from the same thread.

These assertions already found several thread safety bugs in our code base, which I fixed via
dependency bugs.

These assertions are currently enabled in WebKit (UIProcess, child processes and
WebKitLegacy), they do not apply other JavascriptCore API clients.

  • WTF.xcodeproj/project.pbxproj:
  • wtf/CMakeLists.txt:
  • wtf/RefCounted.cpp: Added.
  • wtf/RefCounted.h:

(WTF::RefCountedBase::ref const):
(WTF::RefCountedBase::disableThreadingChecks):
(WTF::RefCountedBase::enableThreadingChecksGlobally):
(WTF::RefCountedBase::RefCountedBase):
(WTF::RefCountedBase::areThreadingCheckedEnabled const):
(WTF::RefCountedBase::derefBase const):

  • wtf/SizeLimits.cpp:
4:27 PM Changeset in webkit [248524] by bshafiei@apple.com
  • 1 copy in tags/Safari-608.1.42.2

Tag Safari-608.1.42.2.

4:25 PM Changeset in webkit [248523] by bshafiei@apple.com
  • 1 copy in tags/Safari-608.1.47

Tag Safari-608.1.47.

12:11 PM Changeset in webkit [248522] by Wenson Hsieh
  • 15 edits in trunk/Source/WebKit

WebPage and ViewportConfiguration have differing notions of viewLayoutSize
https://bugs.webkit.org/show_bug.cgi?id=200619

Reviewed by Tim Horton.

The notion of a "view layout size" exists on WebPage and WebPageProxy for the purpose of specifying an intrinsic
content size for the entire web view on macOS. However, it also exists in ViewportConfiguration (as
viewLayoutSize) and WebPageProxy (under the name m_viewportConfigurationViewLayoutSize) for the purposes of
specifying the minimum layout size of the page's viewport.

This is especially confusing in WebPageProxy, which has both m_viewportConfigurationViewLayoutSize and
m_viewLayoutSize. To remedy this, rename "*viewLayoutSize" for the purposes of specifying an intrinsic web view
size to "*minimumSizeForAutoLayout" instead, which is consistent with the corresponding SPI property name on
WKView.

No change in behavior.

  • Shared/WebPageCreationParameters.cpp:

(WebKit::WebPageCreationParameters::encode const):
(WebKit::WebPageCreationParameters::decode):

  • Shared/WebPageCreationParameters.h:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _minimumLayoutWidth]):
(-[WKWebView _setMinimumLayoutWidth:]):

  • UIProcess/Cocoa/WebViewImpl.mm:

(WebKit::WebViewImpl::setMinimumSizeForAutoLayout):
(WebKit::WebViewImpl::minimumSizeForAutoLayout const):
(WebKit::WebViewImpl::setIntrinsicContentSize):

  • UIProcess/DrawingAreaProxy.h:

(WebKit::DrawingAreaProxy::minimumSizeForAutoLayoutDidChange):
(WebKit::DrawingAreaProxy::viewLayoutSizeDidChange): Deleted.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::minimumSizeForAutoLayout const):
(WebKit::WebPageProxy::viewLayoutSize const): Deleted.

  • UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
  • UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:

(WebKit::TiledCoreAnimationDrawingAreaProxy::minimumSizeForAutoLayoutDidChange):
(WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
(WebKit::TiledCoreAnimationDrawingAreaProxy::willSendUpdateGeometry):
(WebKit::TiledCoreAnimationDrawingAreaProxy::viewLayoutSizeDidChange): Deleted.

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_textAutoSizingAdjustmentTimer):
(WebKit::WebPage::reinitializeWebPage):
(WebKit::WebPage::setMinimumSizeForAutoLayout):
(WebKit::WebPage::updateIntrinsicContentSizeIfNeeded):
(WebKit::WebPage::setViewLayoutSize): Deleted.

  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::minimumSizeForAutoLayout const):
(WebKit::WebPage::viewLayoutSize const): Deleted.

  • WebProcess/WebPage/WebPage.messages.in:
  • WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:

(WebKit::TiledCoreAnimationDrawingArea::updateGeometry):

9:21 AM Changeset in webkit [248521] by aboya@igalia.com
  • 4 edits in trunk

[MSE][GStreamer] Don't use vorbisparse
https://bugs.webkit.org/show_bug.cgi?id=200622

Reviewed by Philippe Normand.

Source/WebCore:

This patch has been splitted from the original WebKitMediaSrc rework
patch (https://bugs.webkit.org/show_bug.cgi?id=199719).

Unlike other parsers, vorbisparse has latency (in the sense that when
it gets a chain call with a series of complete frames, it may not emit
the parsed frames until another chain in the future), which makes it
inappropriate for AppendPipeline, as there is no good way I know to
flush it.

But actually vorbisparse is not known to be necessary and it was only
introduced for consistency with other formats. Parsers are used in
AppendPipeline to reconstruct information that is lost due to poor
muxes. There have been no reported cases of this being a problem with
Vorbis in WebM, so I'm just removing the parser.

Fixes imported/w3c/web-platform-tests/media-source/mediasource-config-change-webm-a-bitrate.html

  • platform/graphics/gstreamer/mse/AppendPipeline.cpp:

(WebCore::createOptionalParserForFormat):

LayoutTests:

  • platform/gtk/TestExpectations:
7:34 AM Changeset in webkit [248520] by bshafiei@apple.com
  • 2 edits in branches/safari-608.1.42-branch/Source/JavaScriptCore

Apply patch. rdar://problem/54171864

7:30 AM Changeset in webkit [248519] by bshafiei@apple.com
  • 2 edits in branches/safari-608.1-branch/Source/WebCore

Apply patch. rdar://problem/54139834

7:30 AM Changeset in webkit [248518] by bshafiei@apple.com
  • 2 edits in branches/safari-608.1-branch/Source/JavaScriptCore

Apply patch. rdar://problem/54171879

4:02 AM Changeset in webkit [248517] by Antti Koivisto
  • 19 edits
    1 move
    1 add in trunk/Source/WebCore

Factor complex line layout path out from RenderBlockFlow
https://bugs.webkit.org/show_bug.cgi?id=200612

Reviewed by Zalan Bujtas.

This patch factors the line layout code that is currently part of the RenderBlockFlow and lives in RenderBlockLineLayout.cpp
into a new ComplexLineLayout class. ComplexLineLayout is a member of RenderBlockFlow.

In the future we can stop constructing ComplexLineLayout at all when using other line layout paths.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • rendering/ComplexLineLayout.cpp: Copied from Source/WebCore/rendering/RenderBlockLineLayout.cpp.

(WebCore::ComplexLineLayout::ComplexLineLayout):
(WebCore::ComplexLineLayout::appendRunsForObject):
(WebCore::ComplexLineLayout::createRootInlineBox):
(WebCore::ComplexLineLayout::createAndAppendRootInlineBox):
(WebCore::ComplexLineLayout::createInlineBoxForRenderer):
(WebCore::ComplexLineLayout::createLineBoxes):
(WebCore::ComplexLineLayout::constructLine):
(WebCore::ComplexLineLayout::textAlignmentForLine const):
(WebCore::ComplexLineLayout::setMarginsForRubyRun):
(WebCore::ComplexLineLayout::updateRubyForJustifiedText):
(WebCore::ComplexLineLayout::computeExpansionForJustifiedText):
(WebCore::ComplexLineLayout::updateLogicalWidthForAlignment):
(WebCore::ComplexLineLayout::computeInlineDirectionPositionsForLine):
(WebCore::ComplexLineLayout::computeInlineDirectionPositionsForSegment):
(WebCore::ComplexLineLayout::removeInlineBox const):
(WebCore::ComplexLineLayout::computeBlockDirectionPositionsForLine):
(WebCore::ComplexLineLayout::handleTrailingSpaces):
(WebCore::ComplexLineLayout::appendFloatingObjectToLastLine):
(WebCore::ComplexLineLayout::createLineBoxesFromBidiRuns):
(WebCore::ComplexLineLayout::layoutRunsAndFloats):
(WebCore::ComplexLineLayout::restartLayoutRunsAndFloatsInRange):
(WebCore::ComplexLineLayout::layoutRunsAndFloatsInRange):
(WebCore::ComplexLineLayout::reattachCleanLineFloats):
(WebCore::ComplexLineLayout::linkToEndLineIfNeeded):
(WebCore::ComplexLineLayout::layoutLineBoxes):
(WebCore::ComplexLineLayout::checkFloatInCleanLine):
(WebCore::ComplexLineLayout::determineStartPosition):
(WebCore::ComplexLineLayout::determineEndPosition):
(WebCore::ComplexLineLayout::checkPaginationAndFloatsAtEndLine):
(WebCore::ComplexLineLayout::lineWidthForPaginatedLineChanged const):
(WebCore::ComplexLineLayout::matchedEndLine):
(WebCore::ComplexLineLayout::addOverflowFromInlineChildren):
(WebCore::ComplexLineLayout::deleteEllipsisLineBoxes):
(WebCore::ComplexLineLayout::checkLinesForTextOverflow):
(WebCore::ComplexLineLayout::positionNewFloatOnLine):
(WebCore::ComplexLineLayout::startAlignedOffsetForLine):
(WebCore::ComplexLineLayout::updateFragmentForLine const):
(WebCore::ComplexLineLayout::style const):
(WebCore::ComplexLineLayout::layoutContext const):
(WebCore::RenderBlockFlow::appendRunsForObject): Deleted.
(WebCore::RenderBlockFlow::createRootInlineBox): Deleted.
(WebCore::RenderBlockFlow::createAndAppendRootInlineBox): Deleted.
(WebCore::createInlineBoxForRenderer): Deleted.
(WebCore::RenderBlockFlow::createLineBoxes): Deleted.
(WebCore::RenderBlockFlow::constructLine): Deleted.
(WebCore::RenderBlockFlow::textAlignmentForLine const): Deleted.
(WebCore::RenderBlockFlow::setMarginsForRubyRun): Deleted.
(WebCore::RenderBlockFlow::updateRubyForJustifiedText): Deleted.
(WebCore::RenderBlockFlow::computeExpansionForJustifiedText): Deleted.
(WebCore::RenderBlockFlow::updateLogicalWidthForAlignment): Deleted.
(WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine): Deleted.
(WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment): Deleted.
(WebCore::RenderBlockFlow::removeInlineBox const): Deleted.
(WebCore::RenderBlockFlow::computeBlockDirectionPositionsForLine): Deleted.
(WebCore::RenderBlockFlow::handleTrailingSpaces): Deleted.
(WebCore::RenderBlockFlow::appendFloatingObjectToLastLine): Deleted.
(WebCore::RenderBlockFlow::createLineBoxesFromBidiRuns): Deleted.
(WebCore::RenderBlockFlow::layoutRunsAndFloats): Deleted.
(WebCore::RenderBlockFlow::restartLayoutRunsAndFloatsInRange): Deleted.
(WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange): Deleted.
(WebCore::RenderBlockFlow::reattachCleanLineFloats): Deleted.
(WebCore::RenderBlockFlow::linkToEndLineIfNeeded): Deleted.
(WebCore::RenderBlockFlow::layoutLineBoxes): Deleted.
(WebCore::RenderBlockFlow::checkFloatInCleanLine): Deleted.
(WebCore::RenderBlockFlow::determineStartPosition): Deleted.
(WebCore::RenderBlockFlow::determineEndPosition): Deleted.
(WebCore::RenderBlockFlow::checkPaginationAndFloatsAtEndLine): Deleted.
(WebCore::RenderBlockFlow::lineWidthForPaginatedLineChanged const): Deleted.
(WebCore::RenderBlockFlow::matchedEndLine): Deleted.
(WebCore::RenderBlock::generatesLineBoxesForInlineChild): Deleted.
(WebCore::RenderBlockFlow::addOverflowFromInlineChildren): Deleted.
(WebCore::RenderBlockFlow::deleteEllipsisLineBoxes): Deleted.
(WebCore::RenderBlockFlow::checkLinesForTextOverflow): Deleted.
(WebCore::RenderBlockFlow::positionNewFloatOnLine): Deleted.
(WebCore::RenderBlockFlow::startAlignedOffsetForLine): Deleted.
(WebCore::RenderBlockFlow::updateFragmentForLine const): Deleted.

  • rendering/ComplexLineLayout.h: Added.

(WebCore::ComplexLineLayout::lineBoxes):
(WebCore::ComplexLineLayout::lineBoxes const):
(WebCore::ComplexLineLayout::firstRootBox const):
(WebCore::ComplexLineLayout::lastRootBox const):

  • rendering/InlineIterator.h:

(WebCore::IsolateTracker::addFakeRunIfNecessary):
(WebCore::InlineBidiResolver::appendRunInternal):

  • rendering/RenderBlock.h:
  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::RenderBlockFlow):
(WebCore::RenderBlockFlow::willBeDestroyed):
(WebCore::RenderBlockFlow::layoutInlineChildren):
(WebCore::RenderBlockFlow::updateStaticInlinePositionForChild):
(WebCore::RenderBlockFlow::deleteLines):
(WebCore::RenderBlockFlow::hitTestInlineChildren):
(WebCore::RenderBlockFlow::addOverflowFromInlineChildren):
(WebCore::RenderBlockFlow::paintInlineChildren):
(WebCore::RenderBlockFlow::layoutSimpleLines):
(WebCore::RenderBlockFlow::ensureLineBoxes):

  • rendering/RenderBlockFlow.h:

(WebCore::RenderBlockFlow::lineBoxes):
(WebCore::RenderBlockFlow::lineBoxes const):
(WebCore::RenderBlockFlow::firstRootBox const):
(WebCore::RenderBlockFlow::lastRootBox const):
(WebCore::RenderBlockFlow::floatingObjects):
(WebCore::RenderBlockFlow::complexLineLayout):
(WebCore::RenderBlockFlow::overrideTextAlignmentForLine const):
(WebCore::RenderBlockFlow::adjustInlineDirectionLineBounds const):

  • rendering/RenderBlockLineLayout.cpp: Removed.
  • rendering/RenderRubyBase.cpp:

(WebCore::RenderRubyBase::overrideTextAlignmentForLine const):
(WebCore::RenderRubyBase::textAlignmentForLine const): Deleted.

  • rendering/RenderRubyBase.h:
  • rendering/RenderRubyText.cpp:

(WebCore::RenderRubyText::overrideTextAlignmentForLine const):
(WebCore::RenderRubyText::textAlignmentForLine const): Deleted.

  • rendering/RenderRubyText.h:
  • rendering/SimpleLineLayoutFunctions.cpp:

(WebCore::SimpleLineLayout::generateLineBoxTree):

  • rendering/line/LineBreaker.cpp:

(WebCore::LineBreaker::skipLeadingWhitespace):

  • rendering/line/LineBreaker.h:

(WebCore::LineBreaker::positionNewFloatOnLine):

  • rendering/line/LineInlineHeaders.h:

(WebCore::setStaticPositions):

  • rendering/svg/RenderSVGText.cpp:

(WebCore::RenderSVGText::createRootInlineBox): Deleted.

  • rendering/svg/RenderSVGText.h:
  • rendering/updating/RenderTreeBuilderList.cpp:

(WebCore::generatesLineBoxesForInlineChild):
(WebCore::getParentOfFirstLineBox):

Note: See TracTimeline for information about the timeline view.