jiewen_tan@apple.com [Wed, 30 May 2018 19:23:57 +0000 (19:23 +0000)]
Unreviewed, a quick build fix for r232276.
Enabled SecItemShim again as it turns out to be useful for CFNetwork APIs that
query Keychains underneath us.
* NetworkProcess/ios/NetworkProcessIOS.mm:
(WebKit::NetworkProcess::platformInitializeNetworkProcess):
* NetworkProcess/mac/NetworkProcessMac.mm:
(WebKit::NetworkProcess::platformInitializeNetworkProcess):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232303
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Wed, 30 May 2018 19:21:34 +0000 (19:21 +0000)]
Reduce String allocations
https://bugs.webkit.org/show_bug.cgi?id=186059
Patch by Alex Christensen <achristensen@webkit.org> on 2018-05-30
Reviewed by Darin Adler.
Source/WebCore:
Don't allocate Strings just to convert it to another form.
Based mostly on Darin's feedback on bug 185986.
No change in behavior.
* Modules/websockets/WebSocketHandshake.cpp:
(WebCore::hostName):
(WebCore::WebSocketHandshake::host const):
* css/parser/CSSSelectorParser.cpp:
(WebCore::CSSSelectorParser::consumePseudo):
(WebCore::CSSSelectorParser::consumeANPlusB):
* loader/mac/LoaderNSURLExtras.mm:
(suggestedFilenameWithMIMEType):
* page/SecurityOriginData.h:
(WebCore::SecurityOriginData::fromURL):
* page/csp/ContentSecurityPolicySource.cpp:
(WebCore::wildcardMatches):
(WebCore::ContentSecurityPolicySource::hostMatches const):
* platform/URL.cpp:
(WebCore::URL::hostAndPort const):
* platform/network/cf/SocketStreamHandleImplCFNet.cpp:
(WebCore::SocketStreamHandleImpl::createStreams):
Source/WTF:
* wtf/text/StringView.cpp:
(WTF::convertASCIICase):
(WTF::StringView::convertToASCIILowercase const):
(WTF::StringView::convertToASCIIUppercase const):
* wtf/text/StringView.h:
* wtf/text/cf/StringViewCF.cpp:
(WTF::StringView::createCFString const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232302
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jer.noble@apple.com [Wed, 30 May 2018 18:00:27 +0000 (18:00 +0000)]
Auto-pip should use main content heuristic.
https://bugs.webkit.org/show_bug.cgi?id=186065
<rdar://problem/
35862502>
Reviewed by Eric Carlson.
Make the m_pipStandbyElement clearable, which will allow the auto-pip mechanism to be torn down. Add
a WebProcess-side notification when the main content changes, to facilitate this.
* WebProcess/FullScreen/WebFullScreenManager.cpp:
(WebKit::WebFullScreenManager::videoControlsManagerDidChange):
(WebKit::WebFullScreenManager::setPIPStandbyElement):
(WebKit::WebFullScreenManager::didEnterFullScreen):
(WebKit::WebFullScreenManager::willExitFullScreen):
* WebProcess/FullScreen/WebFullScreenManager.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::videoControlsManagerDidChange):
* WebProcess/WebPage/WebPage.h:
* WebProcess/cocoa/PlaybackSessionManager.h:
* WebProcess/cocoa/PlaybackSessionManager.mm:
(WebKit::PlaybackSessionManager::setUpPlaybackControlsManager):
(WebKit::PlaybackSessionManager::clearPlaybackControlsManager):
(WebKit::PlaybackSessionManager::currentPlaybackControlsElement const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232301
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jer.noble@apple.com [Wed, 30 May 2018 18:00:23 +0000 (18:00 +0000)]
Media elements outside fullscreen should not be considered main content.
https://bugs.webkit.org/show_bug.cgi?id=186063
<rdar://problem/
40630437>
Reviewed by Eric Carlson.
Source/WebCore:
Test: platform/mac/media/video-best-element-for-playback-controls-purpose.html
Media elements outside the current fullscreen element are not visible, and thus should not be considered
main content.
Drive-by fix: set the m_hasEverNotifiedAboutPlaying before dispatching the 'playing' event, so that
tests can check bestMediaElementForShowingPlaybackControlsManager() in the 'playing' handler.
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::notifyAboutPlaying):
* html/HTMLMediaElement.h:
* html/MediaElementSession.cpp:
(WebCore::MediaElementSession::canShowControlsManager const):
* testing/Internals.cpp:
(WebCore::Internals::bestMediaElementForShowingPlaybackControlsManager):
* testing/Internals.h:
* testing/Internals.idl:
LayoutTests:
* platform/mac/media/video-best-element-for-playback-controls-purpose-expected.txt: Added.
* platform/mac/media/video-best-element-for-playback-controls-purpose.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232300
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jer.noble@apple.com [Wed, 30 May 2018 17:46:49 +0000 (17:46 +0000)]
Fix a few issues in WKFullScreenViewController
https://bugs.webkit.org/show_bug.cgi?id=186067
<rdar://problem/
40630944>
Reviewed by Darin Adler.
The check in setInterface() is checking the wrong pointer:
* UIProcess/ios/fullscreen/WKFullScreenViewController.mm:
(WKFullScreenViewControllerPlaybackSessionModelClient::setInterface):
The check in -_effectiveFullscreenInsetTop is backwards:
(-[WKFullScreenViewController _effectiveFullscreenInsetTop]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232299
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cdumez@apple.com [Wed, 30 May 2018 17:42:51 +0000 (17:42 +0000)]
Take a background process assertion in WebPageProxy::callAfterNextPresentationUpdate()
https://bugs.webkit.org/show_bug.cgi?id=186097
<rdar://problem/
40651225>
Reviewed by Tim Horton.
Take a background process assertion in WebPageProxy::callAfterNextPresentationUpdate(). Otherwise,
apps may get stuck on _doAfterNextPresentationUpdate because the WebProcess got suspended.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::callAfterNextPresentationUpdate):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232298
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mcatanzaro@igalia.com [Wed, 30 May 2018 17:06:09 +0000 (17:06 +0000)]
Unreviewed, silence a -Wreturn-type warning
* css/SVGCSSComputedStyleDeclaration.cpp:
(WebCore::glyphOrientationToCSSPrimitiveValue):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232297
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
Ms2ger@igalia.com [Wed, 30 May 2018 16:46:02 +0000 (16:46 +0000)]
[GTK] Unreviewed test gardening
https://bugs.webkit.org/show_bug.cgi?id=186098
Unreviewed gardening.
Tools:
* TestWebKitAPI/glib/TestExpectations.json: update expectations.
LayoutTests:
* platform/gtk/TestExpectations:
- css3/blending/blend-mode-clip-accelerated-transformed-blending.html: passing since r230479, failing again since 230991.
- fast/text/font-collection.html: fails due to a lack of font collection support
- editing/caret/caret-in-empty-cell.html: fails since it was added
- css3/color-filters/color-filter-color-property-list-item.html: fails since it was added
- css3/color-filters/color-filter-opacity.html: fails since it was added
- fast/hidpi/filters-turbulence.html: fails since it was added
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232296
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ticaiolima@gmail.com [Wed, 30 May 2018 16:40:17 +0000 (16:40 +0000)]
[ESNext][BigInt] Implement support for "%" operation
https://bugs.webkit.org/show_bug.cgi?id=184327
Reviewed by Yusuke Suzuki.
JSTests:
* bigIntTests.yaml:
* stress/big-int-mod-memory-stress.js: Added.
* stress/big-int-mod-to-primitive-precedence.js: Added.
* stress/big-int-mod-to-primitive.js: Added.
* stress/big-int-mod-type-error.js: Added.
* stress/big-int-mod-wrapped-value.js: Added.
* stress/big-int-mod.js: Added.
Source/JavaScriptCore:
We are introducing the support of BigInt into remainder (a.k.a mod)
operation.
* runtime/CommonSlowPaths.cpp:
(JSC::SLOW_PATH_DECL):
* runtime/JSBigInt.cpp:
(JSC::JSBigInt::remainder):
(JSC::JSBigInt::rightTrim):
* runtime/JSBigInt.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232295
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sbarati@apple.com [Wed, 30 May 2018 16:20:58 +0000 (16:20 +0000)]
AI for Atomics.load() is too conservative in always clobbering world
https://bugs.webkit.org/show_bug.cgi?id=185738
<rdar://problem/
40342214>
Reviewed by Yusuke Suzuki.
It fails the assertion that Fil added for catching disagreements between
AI and clobberize. This patch fixes that. You'd run into this if you
manually enabled SAB in a build and ran any SAB tests.
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232294
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
msaboff@apple.com [Wed, 30 May 2018 16:09:01 +0000 (16:09 +0000)]
REGRESSION(r232212): Broke Win32 Builds
https://bugs.webkit.org/show_bug.cgi?id=186061
Reviewed by Yusuke Suzuki.
Changed Windows builds with the JIT disabled to generate and use LLIntAssembly.h
instead of LowLevelInterpreterWin.asm.
* CMakeLists.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232293
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ap@apple.com [Wed, 30 May 2018 15:47:41 +0000 (15:47 +0000)]
Build fix attempt after https://trac.webkit.org/r232198
* platform/network/cf/ResourceHandleCFNet.cpp:
(WebCore::ResourceHandle::createCFURLConnection): Added some toString() calls.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232292
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Wed, 30 May 2018 15:26:51 +0000 (15:26 +0000)]
[LFC] Miscellaneous fixes to get closer to geometry correctness
https://bugs.webkit.org/show_bug.cgi?id=186083
Reviewed by Antti Koivisto.
* layout/FormattingContextGeometry.cpp:
(WebCore::Layout::FormattingContext::Geometry::computedBorder):
* layout/LayoutContext.cpp:
(WebCore::Layout::LayoutContext::initializeRoot):
* layout/Verification.cpp:
(WebCore::Layout::outputMismatchingBoxInformationIfNeeded):
* layout/blockformatting/BlockFormattingContextGeometry.cpp:
(WebCore::Layout::isStretchedToViewport):
(WebCore::Layout::initialContainingBlock):
(WebCore::Layout::computedInFlowNonReplacedComputedHeight):
(WebCore::Layout::inFlowNonReplacedComputedWidth):
(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeight): lambda should capture the specification part.
(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidth):
* layout/displaytree/DisplayBox.cpp:
(WebCore::Display::Box::marginBox const):
(WebCore::Display::Box::paddingBox const):
(WebCore::Display::Box::contentBox const):
* layout/layouttree/LayoutBox.cpp:
(WebCore::Layout::Box::isDocumentBox const):
(WebCore::Layout::Box::isBodyBox const):
* layout/layouttree/LayoutBox.h:
* rendering/style/BorderValue.h: ignore border-width when type is hidden or none.
(WebCore::BorderValue::boxModelWidth const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232291
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Wed, 30 May 2018 14:13:22 +0000 (14:13 +0000)]
[MIPS] Fix build on MIPS32r1
https://bugs.webkit.org/show_bug.cgi?id=185944
Patch by Dominik Infuehr <dinfuehr@igalia.com> on 2018-05-30
Reviewed by Yusuke Suzuki.
Source/JavaScriptCore:
Only use instructions on MIPS32r2 or later. mthc1 and mfhc1 are not supported
on MIPS32r1.
* offlineasm/mips.rb:
Source/WTF:
Added WTF_MIPS_ISA_REV_AT_LEAST to test for certain release or later.
* wtf/Platform.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232290
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Wed, 30 May 2018 13:35:49 +0000 (13:35 +0000)]
iOS: setting 'defaultValue' of input type=date from script should cause a UI update
https://bugs.webkit.org/show_bug.cgi?id=185982
Patch by Stephen McGruer <smcgruer@chromium.org> on 2018-05-30
Reviewed by Darin Adler.
Source/WebCore:
Test: fast/forms/date/date-appearance-defaultValue.html
* html/BaseChooserOnlyDateAndTimeInputType.cpp:
(WebCore::BaseChooserOnlyDateAndTimeInputType::valueAttributeChanged):
* html/BaseChooserOnlyDateAndTimeInputType.h:
* html/HTMLInputElement.cpp:
(WebCore::HTMLInputElement::parseAttribute):
* html/InputType.cpp:
(WebCore::InputType::valueAttributeChanged):
* html/InputType.h:
LayoutTests:
* fast/forms/date/date-appearance-defaultValue-expected.html: Added.
* fast/forms/date/date-appearance-defaultValue.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232289
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fred.wang@free.fr [Wed, 30 May 2018 09:28:52 +0000 (09:28 +0000)]
Import WPT tests for CSS animations
https://bugs.webkit.org/show_bug.cgi?id=186046
Patch by Frederic Wang <fwang@igalia.com> on 2018-05-29
Reviewed by Youenn Fablet.
LayoutTests/imported/w3c:
* resources/import-expectations.json:
* web-platform-tests/css/css-animations/OWNERS: Added.
* web-platform-tests/css/css-animations/animation-delay-008-expected.html: Added.
* web-platform-tests/css/css-animations/animation-delay-008.html: Added.
* web-platform-tests/css/css-animations/animation-delay-009-expected.html: Added.
* web-platform-tests/css/css-animations/animation-delay-009.html: Added.
* web-platform-tests/css/css-animations/animation-delay-010-expected.html: Added.
* web-platform-tests/css/css-animations/animation-delay-010.html: Added.
* web-platform-tests/css/css-animations/animation-delay-011-expected.html: Added.
* web-platform-tests/css/css-animations/animation-delay-011.html: Added.
* web-platform-tests/css/css-animations/animation-iteration-count-calc-expected.txt: Added.
* web-platform-tests/css/css-animations/animation-iteration-count-calc.html: Added.
* web-platform-tests/css/css-animations/animationevent-interface-expected.txt: Added.
* web-platform-tests/css/css-animations/animationevent-interface.html: Added.
* web-platform-tests/css/css-animations/animationevent-interface.js: Added.
(test):
* web-platform-tests/css/css-animations/animationevent-pseudoelement-expected.txt: Added.
* web-platform-tests/css/css-animations/animationevent-pseudoelement.html: Added.
* web-platform-tests/css/css-animations/animationevent-types-expected.txt: Added.
* web-platform-tests/css/css-animations/animationevent-types.html: Added.
* web-platform-tests/css/css-animations/pending-style-changes-001-expected.txt: Added.
* web-platform-tests/css/css-animations/pending-style-changes-001.html: Added.
* web-platform-tests/css/css-animations/w3c-import.log: Added.
LayoutTests:
* TestExpectations: Mark some tests requiring support for reftest-wait as failing/flacky.
* tests-options.json: Mark animationevent-types.html as slow.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232288
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
n_wang@apple.com [Wed, 30 May 2018 06:30:02 +0000 (06:30 +0000)]
Unreviewed, follow-up after r232285
https://bugs.webkit.org/show_bug.cgi?id=180871
Removed redundant null check.
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::isExpanded const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232287
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sbarati@apple.com [Wed, 30 May 2018 04:36:07 +0000 (04:36 +0000)]
Add a version of JSVirtualMachine shrinkFootprint that runs when the VM goes idle
https://bugs.webkit.org/show_bug.cgi?id=186064
Reviewed by Mark Lam.
shrinkFootprint was implemented as:
```
sanitizeStackForVM(this);
deleteAllCode(DeleteAllCodeIfNotCollecting);
heap.collectNow(Synchronousness::Sync);
WTF::releaseFastMallocFreeMemory();
```
However, for correctness reasons, deleteAllCode is implemented to do
work when the VM is idle: no JS is running on the stack. This means
that if shrinkFootprint is called when JS is running on the stack, it
ends up freeing less memory than it could have if it waited to run until
the VM goes idle.
This patch makes it so we wait until idle before doing work. I'm seeing a
10% footprint progression when testing this against a client of the JSC SPI.
Because this is a semantic change in how the SPI works, this patch
adds new SPI named shrinkFootprintWhenIdle. The plan is to move
all clients of the shrinkFootprint SPI to shrinkFootprintWhenIdle.
Once that happens, we will delete shrinkFootprint. Until then,
we make shrinkFootprint do exactly what shrinkFootprintWhenIdle does.
* API/JSVirtualMachine.mm:
(-[JSVirtualMachine shrinkFootprint]):
(-[JSVirtualMachine shrinkFootprintWhenIdle]):
* API/JSVirtualMachinePrivate.h:
* runtime/VM.cpp:
(JSC::VM::shrinkFootprintWhenIdle):
(JSC::VM::shrinkFootprint): Deleted.
* runtime/VM.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232286
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
n_wang@apple.com [Wed, 30 May 2018 04:01:14 +0000 (04:01 +0000)]
AX: macOS VoiceOver doesn't announce when details element is expanded when using role group
https://bugs.webkit.org/show_bug.cgi?id=180866
<rdar://problem/
36074338>
Reviewed by Chris Fleizach.
Source/WebCore:
We should use is<HTMLDetailsElement> to check for the details parent instead
of using the role.
Added test cases to the existing test.
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::isExpanded const):
LayoutTests:
* accessibility/mac/details-summary-expected.txt:
* accessibility/mac/details-summary.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232285
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Wed, 30 May 2018 03:36:34 +0000 (03:36 +0000)]
Fix the build
https://bugs.webkit.org/show_bug.cgi?id=186078
Unreviewed build fix.
Source/WebKit:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _denyNextUserMediaRequest]):
Source/WTF:
* wtf/Platform.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232284
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
aestes@apple.com [Wed, 30 May 2018 00:47:00 +0000 (00:47 +0000)]
[Wi-Fi Assertions] Track whether WiFiAssertionHolder should actually hold a Wi-Fi assertion
https://bugs.webkit.org/show_bug.cgi?id=185983
<rdar://problem/
40205486>
Reviewed by Tim Horton.
* Configurations/Network-iOS.entitlements:
Added a needed entitlement.
* NetworkProcess/cocoa/NetworkDataTaskCocoa.h:
* NetworkProcess/cocoa/WiFiAssertionHolder.h:
(WebKit::WiFiAssertionHolder::shouldHoldWiFiAssertion const):
Track whether WiFiAssertionHolder should actually hold a Wi-Fi assertion.
* NetworkProcess/cocoa/WiFiAssertionHolder.mm: Renamed from Source/WebKit/NetworkProcess/cocoa/WiFiAssertionHolder.cpp.
(holdWiFiAssertion):
(releaseWiFiAssertion):
(WebKit::WiFiAssertionHolder::WiFiAssertionHolder):
(WebKit::WiFiAssertionHolder::~WiFiAssertionHolder):
Changed holdWiFiAssertion() and releaseWiFiAssertion() to take the
WiFiAssertionHolder as an argument.
* Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:
Added a needed sandbox extension.
* WebKit.xcodeproj/project.pbxproj:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232283
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
caitp@igalia.com [Wed, 30 May 2018 00:40:28 +0000 (00:40 +0000)]
[JSTests] update test262 expectations after r232261
https://bugs.webkit.org/show_bug.cgi?id=184267
Reviewed by Saam Barati.
* test262/expectations.yaml:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232282
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
youenn@apple.com [Wed, 30 May 2018 00:18:39 +0000 (00:18 +0000)]
Add a consistency check between URL and CFURL
Source/WebCore:
https://bugs.webkit.org/show_bug.cgi?id=186057
<rdar://problem/
40258457>
Reviewed by Geoff Garen.
It is important that WebCore::URL used in WebCore and CFURL that gets serialized in the network pipe remain consistent.
Otherwise, we will end-up with odd bugs.
We add such a check when creating a CFURL from an URL.
To make things more consistent, we also rely now more on WebCore::URL instead of directly creating a CFURL.
* platform/URL.h:
* platform/cf/CFURLExtras.cpp:
(WebCore::isCFURLSameOrigin):
* platform/cf/CFURLExtras.h:
* platform/cf/URLCF.cpp:
(WebCore::URL::createCFURL const):
* platform/mac/URLMac.mm:
(WebCore::URL::createCFURL const):
* platform/mac/WebCoreNSURLExtras.mm:
(WebCore::URLWithUserTypedString):
Source/WebKit:
https://bugs.webkit.org/show_bug.cgi?id=186057
<rdar://problem/
40258457>
Reviewed by Geoff Garen.
* Shared/Cocoa/WKNSURLExtras.mm:
(+[NSURL _web_URLWithWTFString:relativeToURL:]):
(urlWithWTFString): Deleted.
(+[NSURL _web_URLWithWTFString:]): Deleted.
Tools:
https://bugs.webkit.org/show_bug.cgi?id=182444
<rdar://problem/
37164835>
Reviewed by Geoff Garen.
DRT code expected a non null URL which is no longer the case now.
Updated DRT to remove that assumption.
* DumpRenderTree/TestRunner.cpp:
(TestRunner::redirectionDestinationForURL):
* DumpRenderTree/TestRunner.h:
* DumpRenderTree/mac/ResourceLoadDelegate.mm:
(-[ResourceLoadDelegate webView:resource:willSendRequest:redirectResponse:fromDataSource:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232281
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Wed, 30 May 2018 00:03:33 +0000 (00:03 +0000)]
Remove unused WebPage::dummy
https://bugs.webkit.org/show_bug.cgi?id=186068
Patch by Alex Christensen <achristensen@webkit.org> on 2018-05-29
Reviewed by Sam Weinig.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::dummy): Deleted.
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232280
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sbarati@apple.com [Tue, 29 May 2018 23:48:35 +0000 (23:48 +0000)]
shrinkFootprint needs to request a full collection
https://bugs.webkit.org/show_bug.cgi?id=186069
Reviewed by Mark Lam.
* runtime/VM.cpp:
(JSC::VM::shrinkFootprint):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232279
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy@apple.com [Tue, 29 May 2018 23:41:39 +0000 (23:41 +0000)]
Printing does not apply the right colors in all cases.
https://bugs.webkit.org/show_bug.cgi?id=186066
rdar://problem/
40274975
Reviewed by Tim Horton.
* inspector/agents/InspectorPageAgent.cpp:
(WebCore::InspectorPageAgent::setEmulatedMedia): Call RenderTheme::platformColorsDidChange
to invalidate the color cache.
* page/FrameView.cpp:
(WebCore::FrameView::adjustMediaTypeForPrinting): Ditto.
* page/Page.cpp:
(WebCore::Page::defaultAppearance const): Added. Use default when not screen.
* page/Page.h:
(WebCore::Page::defaultAppearance const): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232278
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
pvollan@apple.com [Tue, 29 May 2018 23:28:41 +0000 (23:28 +0000)]
Create typedef for HashMap<PlatformDisplayID, ScreenProperties>
https://bugs.webkit.org/show_bug.cgi?id=186056
Reviewed by Brent Fulgham.
Source/WebCore:
No new tests, no change in behavior.
* platform/PlatformScreen.h:
* platform/mac/PlatformScreenMac.mm:
(WebCore::screenProperties):
(WebCore::getScreenProperties):
(WebCore::setScreenProperties):
Source/WebKit:
* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232277
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jiewen_tan@apple.com [Tue, 29 May 2018 22:59:08 +0000 (22:59 +0000)]
Tighten sandbox profiles for Networking Processes to restrict accesses to macOS/iOS Keychains
https://bugs.webkit.org/show_bug.cgi?id=162948
<rdar://problem/
40558894>
Reviewed by Brent Fulgham.
The patch conditionally tighten sandbox profiles for Networking Processes to remove Keychain related
permissions and some security permisssions that are not needed. Also it conditionally remove the
Process Privilege for Networking Processes to access Credentials.
In addition, it remove process privilege assertions for SecItemShim as it is supposed to work in processes
that don't have privileges to access Keychains and delegate all operations to UI Process via IPC. Also,
the patch disables SecItemShim for Networking Process conditionally.
* Configurations/Network-iOS.entitlements:
* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::initializeNetworkProcess):
* NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in:
* Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:
* Shared/mac/SecItemShim.cpp:
(WebKit::sendSecItemRequest):
(WebKit::webSecItemCopyMatching):
(WebKit::webSecItemAdd):
(WebKit::webSecItemUpdate):
(WebKit::webSecItemDelete):
(WebKit::initializeSecItemShim):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232276
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cdumez@apple.com [Tue, 29 May 2018 22:14:03 +0000 (22:14 +0000)]
Store 0-lifetime stylesheets / scripts into the disk cache for faster history navigations
https://bugs.webkit.org/show_bug.cgi?id=186060
<rdar://problem/
40627270>
Reviewed by Geoffrey Garen.
Tweak our storeUnconditionallyForHistoryNavigation logic to match resources whose priority
is High, not just VeryHigh. Per logic in CachedResource::defaultPriorityForResourceType(Type),
This now matches stylesheets and scripts in addition to main resources.
I found that in case of a history navigation to apple.com, a significant number of scripts
and stylesheets had to be loaded from the network because our previous heuristic decided
not to store them (because their priority was not VeryHigh and because their max-age was
0).
* NetworkProcess/cache/NetworkCache.cpp:
(WebKit::NetworkCache::makeStoreDecision):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232275
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 29 May 2018 21:29:57 +0000 (21:29 +0000)]
Export changes to web-platform-test as part of the webkit-patch upload workflow
https://bugs.webkit.org/show_bug.cgi?id=184914
Patch by Brendan McLoughlin <brendan@bocoup.com> on 2018-05-29
Reviewed by Youenn Fablet.
* Scripts/webkitpy/tool/commands/upload.py:
(Upload):
(CreateBug.execute):
(WPTChangeExport):
* Scripts/webkitpy/tool/steps/__init__.py:
* Scripts/webkitpy/tool/steps/wptchangeexport.py: Added.
(WPTChangeExport):
(WPTChangeExport.options):
(WPTChangeExport.run):
* Scripts/webkitpy/w3c/common.py:
* Scripts/webkitpy/w3c/test_exporter.py:
(WebPlatformTestExporter):
(WebPlatformTestExporter.__init__):
(WebPlatformTestExporter.username):
(WebPlatformTestExporter.token):
(WebPlatformTestExporter._github):
(WebPlatformTestExporter._wpt_fork_branch_github_url):
(WebPlatformTestExporter._wpt_fork_remote):
(WebPlatformTestExporter._wpt_fork_push_url):
(WebPlatformTestExporter._git):
(WebPlatformTestExporter._branch_name):
(WebPlatformTestExporter._public_branch_name):
(WebPlatformTestExporter._wpt_patch):
(WebPlatformTestExporter.has_wpt_changes):
(WebPlatformTestExporter._find_filename):
(WebPlatformTestExporter._is_ignored_file):
(WebPlatformTestExporter._strip_ignored_files_from_diff):
(WebPlatformTestExporter.write_git_patch_file):
(WebPlatformTestExporter._prompt_for_token):
(WebPlatformTestExporter._prompt_for_username):
(WebPlatformTestExporter._ensure_username_and_token):
(WebPlatformTestExporter._validate_and_save_token):
(WebPlatformTestExporter.create_branch_with_patch):
(WebPlatformTestExporter.push_to_wpt_fork):
(WebPlatformTestExporter.make_pull_request):
(WebPlatformTestExporter.delete_local_branch):
(WebPlatformTestExporter.create_upload_remote_if_needed):
(WebPlatformTestExporter.do_export):
(parse_args):
(TestExporter): Deleted.
(TestExporter.__init__): Deleted.
(TestExporter._ensure_wpt_repository): Deleted.
(TestExporter._fetch_wpt_repository): Deleted.
(TestExporter._ensure_new_branch_name): Deleted.
(TestExporter.download_and_commit_patch): Deleted.
(TestExporter.clean): Deleted.
(TestExporter.create_branch_with_patch): Deleted.
(TestExporter.push_to_wpt_fork): Deleted.
(TestExporter.make_pull_request): Deleted.
(TestExporter.create_wpt_pull_request): Deleted.
(TestExporter.delete_local_branch): Deleted.
(TestExporter.create_git_patch): Deleted.
(TestExporter.create_upload_remote): Deleted.
(TestExporter.do_export): Deleted.
* Scripts/webkitpy/w3c/test_exporter_unittest.py:
(TestExporterTest.MockGit):
(TestExporterTest.MockGit.create_patch):
(TestExporterTest.test_export):
(TestExporterTest.test_export_with_specific_branch):
(TestExporterTest):
(TestExporterTest.test_export_interactive_mode):
(TestExporterTest.test_export_invalid_token):
(TestExporterTest.test_export_wrong_token):
(TestExporterTest.test_has_wpt_changes):
(TestExporterTest.test_has_no_wpt_changes_for_no_diff):
(TestExporterTest.test_ignore_changes_to_expected_file):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232274
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ticaiolima@gmail.com [Tue, 29 May 2018 21:15:24 +0000 (21:15 +0000)]
[ESNext][BigInt] Implement support for "<" and ">" relational operation
https://bugs.webkit.org/show_bug.cgi?id=185379
Reviewed by Yusuke Suzuki.
JSTests:
* stress/big-int-greater-than-general.js: Added.
* stress/big-int-greater-than-jit.js: Added.
* stress/big-int-greater-than-order-of-evaluation.js: Added.
* stress/big-int-greater-than-wrapped-values.js: Added.
* stress/big-int-less-than-general.js: Added.
* stress/big-int-less-than-jit.js: Added.
* stress/big-int-less-than-order-of-evaluation.js: Added.
* stress/big-int-less-than-wrapped-values.js: Added.
Source/JavaScriptCore:
This patch is changing the ``jsLess``` operation to follow the
semantics of Abstract Relational Comparison[1] that supports BigInt.
For that, we create 2 new helper functions ```bigIntCompareLess``` and
```toPrimitiveNumeric``` that considers BigInt as a valid type to be
compared.
[1] - https://tc39.github.io/proposal-bigint/#sec-abstract-relational-comparison
* runtime/JSBigInt.cpp:
(JSC::JSBigInt::unequalSign):
(JSC::JSBigInt::absoluteGreater):
(JSC::JSBigInt::absoluteLess):
(JSC::JSBigInt::compare):
(JSC::JSBigInt::absoluteCompare):
* runtime/JSBigInt.h:
* runtime/JSCJSValueInlines.h:
(JSC::JSValue::isPrimitive const):
* runtime/Operations.h:
(JSC::bigIntCompareLess):
(JSC::toPrimitiveNumeric):
(JSC::jsLess):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232273
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rniwa@webkit.org [Tue, 29 May 2018 20:30:18 +0000 (20:30 +0000)]
iOS WK1: Occasional crash in sanitizedMarkupForFragmentInDocument
https://bugs.webkit.org/show_bug.cgi?id=186011
Reviewed by David Kilzer.
The crash was caused by the HTML parser in sanitizedMarkupForFragmentInDocument yielding in the web thread
when _WebThreadLock() sets webThreadShouldYield to true in the main thread.
No new tests. This is occasionally caught by existing tests.
* editing/markup.cpp:
(WebCore::createPageForSanitizingWebContent): Fixed the bug by making the HTML parser never yield.
Also release-assert that the body is never null here.
(WebCore::sanitizedMarkupForFragmentInDocument): Removed superflous call to WTFMove since appendChild
takes a reference, not a Ref.
* inspector/InspectorOverlay.cpp:
(WebCore::InspectorOverlay::overlayPage): Deployed the same fix.
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::insertDataSynchronously): Added.
* loader/DocumentWriter.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232272
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Tue, 29 May 2018 20:04:14 +0000 (20:04 +0000)]
[Baseline] Merge loading functionalities
https://bugs.webkit.org/show_bug.cgi?id=185907
Reviewed by Saam Barati.
This patch unifies emitXXXLoad functions in 32bit and 64bit.
* jit/JITInlines.h:
(JSC::JIT::emitDoubleGetByVal):
* jit/JITPropertyAccess.cpp:
(JSC::JIT::emitDoubleLoad):
(JSC::JIT::emitContiguousLoad):
(JSC::JIT::emitArrayStorageLoad):
(JSC::JIT::emitIntTypedArrayGetByVal):
(JSC::JIT::emitFloatTypedArrayGetByVal):
Define register usage first, and share the same code in 32bit and 64bit.
* jit/JITPropertyAccess32_64.cpp:
(JSC::JIT::emitSlow_op_put_by_val):
Now C-stack is always enabled in JIT platform and temporary registers increases from 5 to 6 in x86.
We can remove this special handling.
(JSC::JIT::emitContiguousLoad): Deleted.
(JSC::JIT::emitDoubleLoad): Deleted.
(JSC::JIT::emitArrayStorageLoad): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232271
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
Hironori.Fujii@sony.com [Tue, 29 May 2018 19:27:13 +0000 (19:27 +0000)]
[Win][MiniBrowser] Move WK1 specific code from Common.cpp to MiniBrowser.cpp
https://bugs.webkit.org/show_bug.cgi?id=186029
Reviewed by Alex Christensen.
This is a sub task of Bug 184770.
* MiniBrowser/win/Common.cpp:
(ToggleMenuItem): Extracted WK1 specific code to MiniBrowser::setPreference.
(Caches): Call MiniBrowser::updateStatistics instead of updateStatistics.
(AbortProc): Moved to MiniBrowser.cpp.
(getPrinterDC): Ditto.
(initDocStruct): Ditto.
(PrintView): Ditto.
(ToggleMenuFlag): Ditto.
(setWindowText): Ditto.
(updateStatistics): Ditto.
* MiniBrowser/win/MainWindow.cpp:
(MainWindow::WndProc): Call MiniBrowser::print instead of PrintView.
* MiniBrowser/win/MiniBrowser.cpp:
(AbortProc): Moved from Common.cpp.
(getPrinterDC): Moved from Common.cpp.
(initDocStruct): Moved from Common.cpp.
(setWindowText): Moved from Common.cpp.
(MiniBrowser::print): Renamed from PrintView of Common.cpp.
(MiniBrowser::updateStatistics): Renamed from updateStatistics of Common.cpp.
(MiniBrowser::setPreference): Extracted from ToggleMenuItem of Common.cpp.
* MiniBrowser/win/MiniBrowser.h: Add method declarations.
* MiniBrowser/win/MiniBrowserWebHost.cpp: Removed duplicated IWebFramePtr typedef.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232270
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sbarati@apple.com [Tue, 29 May 2018 18:56:05 +0000 (18:56 +0000)]
JSC should put bmalloc's scavenger into mini mode
https://bugs.webkit.org/show_bug.cgi?id=185988
Reviewed by Michael Saboff.
Source/bmalloc:
We expose an API for putting bmalloc into mini mode. All that means now
is that we'll run the scavenger more aggressively.
* bmalloc/Scavenger.cpp:
(bmalloc::Scavenger::enableMiniMode):
(bmalloc::Scavenger::threadRunLoop):
* bmalloc/Scavenger.h:
* bmalloc/Sizes.h:
* bmalloc/bmalloc.cpp:
(bmalloc::api::enableMiniMode):
* bmalloc/bmalloc.h:
Source/JavaScriptCore:
When we InitializeThreading, we'll now enable bmalloc's mini mode
if the VM is in mini mode. This is an 8-10% progression on the footprint
at end score in run-testmem, making it a 4-5% memory score progression.
It's between a 0-1% regression in its time score.
* runtime/InitializeThreading.cpp:
(JSC::initializeThreading):
Source/WTF:
* wtf/FastMalloc.cpp:
(WTF::fastEnableMiniMode):
* wtf/FastMalloc.h:
Tools:
This patch makes it so that we turn off the JIT when running run-testmem
that way we make JSC use its mini mode.
* Scripts/run-testmem:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232269
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cdumez@apple.com [Tue, 29 May 2018 18:32:00 +0000 (18:32 +0000)]
Avoid unnecessary String allocation in isPublicSuffix(const String&)
https://bugs.webkit.org/show_bug.cgi?id=186054
Reviewed by Sam Weinig.
Avoid unnecessary String allocation in isPublicSuffix(const String&) by calling directly
the decodeHostName() overload taking in a NSString*. This overload returns a NSString*,
which is what we need. We would previously call the overloading taking in a String, which
would return a String, which we would have to convert back to a NSString*.
* platform/mac/PublicSuffixMac.mm:
(WebCore::isPublicSuffix):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232268
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 29 May 2018 18:24:52 +0000 (18:24 +0000)]
Do even fewer allocations in URL host operations
https://bugs.webkit.org/show_bug.cgi?id=186003
Patch by Alex Christensen <achristensen@webkit.org> on 2018-05-29
Reviewed by Geoffrey Garen.
* loader/ResourceLoadStatistics.cpp:
(WebCore::ResourceLoadStatistics::primaryDomain):
* loader/ResourceLoadStatistics.h:
* platform/URL.cpp:
(WebCore::URL::hostIsIPAddress):
* platform/URL.h:
* platform/mac/URLMac.mm:
(WebCore::URL::hostIsIPAddress):
* platform/soup/URLSoup.cpp:
(WebCore::URL::hostIsIPAddress):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232267
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jeffm@apple.com [Tue, 29 May 2018 18:10:55 +0000 (18:10 +0000)]
Expose additional WKMenuItemIdentifier strings
https://bugs.webkit.org/show_bug.cgi?id=186041
Reviewed by Dan Bernstein.
Expose identifiers for media-related menu items.
* UIProcess/API/Cocoa/WKMenuItemIdentifiers.mm:
Define new identifiers.
* UIProcess/API/Cocoa/WKMenuItemIdentifiersPrivate.h:
Declare new identifiers.
* UIProcess/mac/WebContextMenuProxyMac.mm:
(WebKit::menuItemIdentifier):
Map to new identifiers.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232266
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 29 May 2018 18:10:50 +0000 (18:10 +0000)]
Don't assert on m_actionsStart when setting actions on DFA nodes
https://bugs.webkit.org/show_bug.cgi?id=185979
<rdar://problem/
39669458>
Patch by Tadeu Zagallo <tzagallo@apple.com> on 2018-05-29
Reviewed by Geoffrey Garen.
DFANode::setActions is called immediately after the node is created, and once again to set
the actions of catch-all regular expressions (.*) on the root node. That works because
m_actionsStart is initially 0, since the root was the first node to be created, but may fail
after minimizing the DFA, when the root may no longer be the first node, and therefore
m_actionsStart would not be 0, even if there are no actions attached to that node.
Source/WebCore:
Test: http/tests/contentextensions/root-actions.html
* contentextensions/DFANode.h:
LayoutTests:
* http/tests/contentextensions/root-actions-expected.txt: Added.
* http/tests/contentextensions/root-actions.html: Added.
* http/tests/contentextensions/root-actions.html.json: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232265
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Tue, 29 May 2018 17:56:47 +0000 (17:56 +0000)]
Unreviewed, follow-up after r232244
https://bugs.webkit.org/show_bug.cgi?id=186023
_BitScanReverse64 is available only in X86_64 and ARM.
* wtf/MathExtras.h:
(WTF::clz64):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232264
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ggaren@apple.com [Tue, 29 May 2018 17:31:16 +0000 (17:31 +0000)]
Removed some unused WebSQL trackers
https://bugs.webkit.org/show_bug.cgi?id=186026
Reviewed by Dan Bernstein.
* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::NetworkProcess):
* NetworkProcess/NetworkProcess.h:
* WebProcess/WebProcess.cpp:
(WebKit::m_nonVisibleProcessCleanupTimer):
(WebKit::m_webSQLiteDatabaseTracker): Deleted.
* WebProcess/WebProcess.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232263
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ggaren@apple.com [Tue, 29 May 2018 17:28:50 +0000 (17:28 +0000)]
Fixed the bmalloc build
https://bugs.webkit.org/show_bug.cgi?id=186025
Reviewed by Sam Weinig.
* bmalloc.xcodeproj/project.pbxproj: Link Foundation because the
gigacage check needs it.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232262
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
caitp@igalia.com [Tue, 29 May 2018 16:56:29 +0000 (16:56 +0000)]
[JSC] Fix Array.prototype.concat fast case when single argument is Proxy
https://bugs.webkit.org/show_bug.cgi?id=184267
Reviewed by Saam Barati.
JSTests:
* stress/array-concat-fast-spread-proxy.js: Copied from JSTests/stress/array-concat-spread-proxy.js.
(arrayEq):
(catch):
* stress/array-concat-spread-proxy.js:
Source/JavaScriptCore:
Before this patch, the fast case for Array.prototype.concat was taken if
there was a single argument passed to the function, which is either a
non-JSCell, or an ObjectType JSCell not marked as concat-spreadable.
This incorrectly prevented Proxy objects from being spread when
they were the only argument passed to A.prototype.concat(), violating ECMA-262.
* builtins/ArrayPrototype.js:
(concat):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232261
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
pvollan@apple.com [Tue, 29 May 2018 16:50:12 +0000 (16:50 +0000)]
Follow-up fixes after r228907.
https://bugs.webkit.org/show_bug.cgi?id=183338
Reviewed by Brent Fulgham.
Add screen properties to the WebProcess creation parameters, instead of sending
them in a message to the WebProcess just after starting it up.
* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::platformInitializeWebProcess):
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::initializeNewWebProcess):
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::platformInitializeWebProcess):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232260
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
n_wang@apple.com [Tue, 29 May 2018 16:19:09 +0000 (16:19 +0000)]
AX: setValue on contenteditable should preserve whitespace
https://bugs.webkit.org/show_bug.cgi?id=185897
Reviewed by Ryosuke Niwa.
Source/WebCore:
We should mimic typing when setting value to a contenteditable from accessibility
instead of mutating the DOM by using setInnerText.
Updated tests to cover this change.
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::setValue):
LayoutTests:
* accessibility/mac/AOM-event-accessiblesetvalue-expected.txt:
* accessibility/mac/AOM-event-accessiblesetvalue.html:
* accessibility/mac/set-value-editable-types-expected.txt:
* accessibility/mac/set-value-editable-types.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232259
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sihui_liu@apple.com [Tue, 29 May 2018 16:12:22 +0000 (16:12 +0000)]
Unable to remove IndexedDB Databases with Cocoa API removeDataOfTypes
https://bugs.webkit.org/show_bug.cgi?id=185835
<rdar://problem/
39142257>
Reviewed by Chris Dumez.
Source/WebKit:
Fix a wrong if condition: databases should be closed and deleted if websiteDataTypes contains
WebsiteDataType::IndexedDBDatabases.
* StorageProcess/StorageProcess.cpp:
(WebKit::StorageProcess::deleteWebsiteDataForOrigins):
Tools:
Add API test coverage.
* TestWebKitAPI/Tests/WebKitCocoa/IndexedDBPersistence.mm:
(TEST):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232258
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Tue, 29 May 2018 15:19:49 +0000 (15:19 +0000)]
[LFC] Miscellaneous fixes to ensure no assertion in LayoutContext::layout
https://bugs.webkit.org/show_bug.cgi?id=186052
Reviewed by Antti Koivisto.
With this patch, LayoutContext::layout() does not assert on <html><body><div></div></body></html> anymore.
* layout/LayoutContext.cpp:
(WebCore::Layout::LayoutContext::initializeRoot): New context root is always a layout root.
* layout/LayoutContext.h:
* layout/Verification.cpp:
(WebCore::Layout::outputMismatchingBoxInformationIfNeeded):
* layout/blockformatting/BlockFormattingContext.cpp:
(WebCore::Layout::BlockFormattingContext::layout const): we need computed margin/border/padding for width computation
* layout/displaytree/DisplayBox.cpp: Add clone() method to be able to carry over the 'hasValid*' bits.
(WebCore::Display::Box::Style::Style):
(WebCore::Display::Box::borderBox const):
(WebCore::Display::Box::contentBox const):
* layout/displaytree/DisplayBox.h:
(WebCore::Display::Box::Rect::operator LayoutRect const):
(WebCore::Display::Box::setSize):
(WebCore::Display::Box::setHasValidMargin):
(WebCore::Display::Box::setHasValidBorder):
(WebCore::Display::Box::setHasValidPadding):
(WebCore::Display::Box::Rect::setHasValidPosition):
(WebCore::Display::Box::Rect::setHasValidSize):
(WebCore::Display::Box::Rect::setSize):
(WebCore::Display::Box::Rect::clone const):
(WebCore::Display::Box::setMargin):
(WebCore::Display::Box::setBorder):
(WebCore::Display::Box::setPadding):
(WebCore::Display::Box::Rect::Rect): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232257
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
wenson_hsieh@apple.com [Tue, 29 May 2018 15:00:09 +0000 (15:00 +0000)]
[Extra zoom mode] "Significant area painted" rendering progress event is rarely fired
https://bugs.webkit.org/show_bug.cgi?id=186042
<rdar://problem/
40604182>
Reviewed by Tim Horton.
Source/WebCore:
Makes a minor tweak to the size of the relevant view rect in extra zoom mode, such that it's no wider than the
visible content rect. Previously, the width of this rect has hard-coded to a value optimized for macOS (980),
which makes it difficult for content laid out at device width in extra zoom mode to cover a significant portion
of the relevant view rect.
Test: RenderingProgressTests.FirstPaintWithSignificantArea
* page/Page.cpp:
(WebCore::relevantViewRect):
Tools:
Adds a new API test to check that the "significant area painting" rendering milestone is dispatched when a
significant portion of the page has been painted before document load is finished.
* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKitCocoa/paint-significant-area-milestone.html: Added.
* TestWebKitAPI/Tests/ios/RenderingProgressTests.mm: Added.
(-[MissingResourceSchemeHandler webView:stopURLSchemeTask:]):
(-[MissingResourceSchemeHandler webView:startURLSchemeTask:]):
(-[RenderingProgressHandler initWithHandler:]):
(-[RenderingProgressHandler _webView:renderingProgressDidChange:]):
(TEST):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232256
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
graouts@webkit.org [Tue, 29 May 2018 11:59:56 +0000 (11:59 +0000)]
[Web Animations] Handle relative length units
https://bugs.webkit.org/show_bug.cgi?id=186047
Reviewed by Dean Jackson.
LayoutTests/imported/w3c:
Record WPT test progressions.
* web-platform-tests/web-animations/animation-model/keyframe-effects/effect-value-context-expected.txt:
Source/WebCore:
In order to correctly handle relative units, such as "em", "vw" and "vh", we need to do two things.
First, because we need to apply the cascade to correctly compute relative lengths, we need to delay the computation of
"blending keyframes" to when we have both keyframes data and a valid target. This also means that we need to reset blending
keyframes when the target changes. As a result, old call sites of updateBlendingKeyframes() have been replaced by a call to
m_blendingKeyframes.clear() and the method now gets called as part of apply() with the RenderStyle of the targeted element
as a parameter.
Second, and as a result of the first change, we need to update the accelerated animation state based on animation
progress rather than when calling specific methods, such as Animation.play() and Animation.pause(), since blending
keyframes may not be available at those more specific call sites. We now have a new updateAcceleratedAnimationState()
method that gets called as part of apply(). We also rename animationPlayStateDidChange() to animationSuspensionStateDidChange()
since this method was specific to suspension and had a confusing name.
* animation/AnimationEffectReadOnly.h: Rename animationPlayStateDidChange() to animationSuspensionStateDidChange().
* animation/KeyframeEffectReadOnly.cpp:
(WebCore::KeyframeEffectReadOnly::getKeyframes): Fix a crash that revealed itself after other changes in this patch. We would later
call into ComputedStyleExtractor::animationSuspensionStateDidChange() and this would yield an assertion because we'd call potentially
call it with a custom CSS property.
(WebCore::KeyframeEffectReadOnly::processKeyframes): Reset blending keyframes instead of calling updateBlendingKeyframes() since
blending keyframes is now performed asynchronously upon style resolution.
(WebCore::KeyframeEffectReadOnly::updateBlendingKeyframes): Take the target's RenderStyle as a parameter and use it to reset the
associated StyleResolver's state, just like we do in StyleResolver::keyframeStylesForAnimation(), so that the CSS cascade is correctly
accounted for when computing values using relative length units. Since blending keyframes can now be computed several times for a
given set of keyframes, since the effect's target may change, we also need to create a copy of the MutableStyleProperties to pass
to StyleRuleKeyframe::create().
(WebCore::KeyframeEffectReadOnly::setTarget): Reset blending keyframes instead of calling updateBlendingKeyframes() since
blending keyframes is now performed asynchronously upon style resolution.
(WebCore::KeyframeEffectReadOnly::apply): Update blending keyframes and the accelerated animation state.
(WebCore::KeyframeEffectReadOnly::getAnimatedStyle): Make sure we have blending keyframes with a call to updateBlendingKeyframes()
in case the animation hasn't naturally progressed when this method is called.
(WebCore::KeyframeEffectReadOnly::setAnimatedPropertiesInStyle): Make sure we have blending keyframes with a call to
updateBlendingKeyframes() in case the animation hasn't naturally progressed when this method is called.
(WebCore::KeyframeEffectReadOnly::updateAcceleratedAnimationState): Account for the animation's local time and play state to update
the accelerated animation state.
(WebCore::KeyframeEffectReadOnly::addPendingAcceleratedAction): Record the last accelerated action in a member variable which we can
use to determine if we're running accelerated accounting for uncommited changes.
(WebCore::KeyframeEffectReadOnly::animationDidSeek): Only record an AcceleratedAction::Seek action if we're already running accelerated.
(WebCore::KeyframeEffectReadOnly::animationSuspensionStateDidChange): Only record an AcceleratedAction::Pause or AcceleratedAction::Play
action if we're already running accelerated.
(WebCore::KeyframeEffectReadOnly::applyPendingAcceleratedActions): Ensure we clone and clear the list of accelerated actions and check that
we have any cloned actions before proceeding any further. Then we can stop accounting for m_startedAccelerated since the list of accelerated
actions already account for animation state changes.
(WebCore::KeyframeEffectReadOnly::animationPlayStateDidChange): Deleted.
* animation/KeyframeEffectReadOnly.h:
(WebCore::KeyframeEffectReadOnly::isRunningAccelerated const): Account for the m_lastRecordedAcceleratedAction to identify whether we're running.
* animation/WebAnimation.cpp:
(WebCore::WebAnimation::play): Stop calling animationPlayStateDidChange() directly since the accelerated animation state is now updated when
the animation's effect is applied.
(WebCore::WebAnimation::pause): Stop calling animationPlayStateDidChange() directly since the accelerated animation state is now updated when
the animation's effect is applied.
(WebCore::WebAnimation::resolve): Make sure we update the finished state prior to applying the animation's effect since the play state can
change when updating the finished state and KeyframeEffectReadOnly::updateAcceleratedAnimationState(), which is called when calling into
KeyframeEffectReadOnly::apply(), relies on it to correctly update the accelerated animation state.
(WebCore::WebAnimation::setSuspended): Rename animationPlayStateDidChange() to animationSuspensionStateDidChange().
* css/StyleResolver.cpp:
(WebCore::StyleResolver::setNewStateWithElement): Add a new public method to reset a StyleResolver's state such that we can call it when creating
blending keyframes for JS-originated animations just like we do when creating blending keyframes for CSS Animations in keyframeStylesForAnimation().
(WebCore::StyleResolver::keyframeStylesForAnimation): Use the new setNewStateWithElement() method.
* css/StyleResolver.h:
LayoutTests:
Record WPT test progressions and updated failures.
* platform/ios/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt:
* platform/ios/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-expected.txt:
* platform/ios/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt:
* platform/mac/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt:
* platform/mac/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-expected.txt:
* platform/mac/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt:
* platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt:
* platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-expected.txt:
* platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232255
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 29 May 2018 08:45:17 +0000 (08:45 +0000)]
[GStreamer] Update "qtdemux: Clarify field name about stream-encryption-system" patch
https://bugs.webkit.org/show_bug.cgi?id=186040
Source/WebCore:
Patch by Thibault Saunier <tsaunier@igalia.com> on 2018-05-29
Reviewed by Xabier Rodriguez-Calvar.
s/avalaible-stream-encryption-systems/available-stream-encryption-systems/g
Tests: imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-*
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::extractEventsAndSystemsFromMessage):
Tools:
The patch we merge contained a type and was merged in upstream GStreamer fixing that
(s/avalaible/available/).
Patch by Thibault Saunier <tsaunier@igalia.com> on 2018-05-29
Reviewed by Xabier Rodriguez-Calvar.
* gstreamer/patches/gst-plugins-good-0003-qtdemux-Clarify-field-name-about-stream-encryption-s.patch:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232254
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Tue, 29 May 2018 06:43:38 +0000 (06:43 +0000)]
[JSC] JSBigInt::digitDiv has undefined behavior which causes test failures
https://bugs.webkit.org/show_bug.cgi?id=186022
Reviewed by Darin Adler.
digitDiv performs Value64Bit >> 64 / Value32Bit >> 32, which is undefined behavior. And zero mask
creation has an issue (`s` should be casted to signed one before negating). They cause test failures
in non x86 / x86_64 environments. x86 and x86_64 work well since they have a fast path written
in asm.
This patch fixes digitDiv by carefully avoiding undefined behaviors. We mask the left value of the
rshift with `digitBits - 1`, which makes `digitBits` 0 while it keeps 0 <= n < digitBits values.
This makes the target rshift well-defined in C++. While produced value by the rshift covers 0 <= `s` < 64 (32
in 32bit envirnoment) cases, this rshift does not shift if `s` is 0. sZeroMask clears the value
if `s` is 0, so that `s == 0` case is also covered. Note that `s == 64` never happens since `divisor`
is never 0 here. We add assertion for that. We also fixes `sZeroMask` calculation.
This patch also fixes naming convention for constant values.
* runtime/JSBigInt.cpp:
(JSC::JSBigInt::digitMul):
(JSC::JSBigInt::digitDiv):
* runtime/JSBigInt.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232253
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sihui_liu@apple.com [Tue, 29 May 2018 03:46:35 +0000 (03:46 +0000)]
Add an API test to check process privilege when using Cookie API
https://bugs.webkit.org/show_bug.cgi?id=185406
Reviewed by Geoffrey Garen.
Add API test coverage.
* TestWebKitAPI/Tests/WebKitCocoa/WKHTTPCookieStore.mm:
(TEST):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232252
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Tue, 29 May 2018 02:40:43 +0000 (02:40 +0000)]
Unreviewed build fix.
* layout/displaytree/DisplayBox.h:
(WebCore::Display::Box::Rect::operator LayoutRect const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232251
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Mon, 28 May 2018 20:39:14 +0000 (20:39 +0000)]
[LFC] Add Rect interface to Display::Box
https://bugs.webkit.org/show_bug.cgi?id=186019
Reviewed by Antti Koivisto.
Having a dedicated Rect class and moving the geometry invalidation to it enables us to call
displayBox.contentBox().left() even when the widht/height are not computed yet.
Also having Rect with top/left/bottom/right interface is more aligned with the rest of the layout code than x/y/maxX/maxY.
* layout/FormattingContextGeometry.cpp:
(WebCore::Layout::contentHeightForFormattingContextRoot):
* layout/blockformatting/BlockFormattingContextGeometry.cpp:
(WebCore::Layout::BlockFormattingContext::Geometry::staticPosition):
* layout/displaytree/DisplayBox.cpp:
(WebCore::Display::Box::marginBox const):
(WebCore::Display::Box::borderBox const):
(WebCore::Display::Box::paddingBox const):
(WebCore::Display::Box::contentBox const):
* layout/displaytree/DisplayBox.h:
(WebCore::Display::Box::Rect::invalidateTop):
(WebCore::Display::Box::Rect::invalidateLeft):
(WebCore::Display::Box::Rect::invalidateWidth):
(WebCore::Display::Box::Rect::invalidateHeight):
(WebCore::Display::Box::Rect::hasValidPosition const):
(WebCore::Display::Box::Rect::hasValidSize const):
(WebCore::Display::Box::Rect::hasValidGeometry const):
(WebCore::Display::Box::rect const):
(WebCore::Display::Box::top const):
(WebCore::Display::Box::left const):
(WebCore::Display::Box::bottom const):
(WebCore::Display::Box::right const):
(WebCore::Display::Box::topLeft const):
(WebCore::Display::Box::bottomRight const):
(WebCore::Display::Box::size const):
(WebCore::Display::Box::width const):
(WebCore::Display::Box::height const):
(WebCore::Display::Box::setTopLeft):
(WebCore::Display::Box::setTop):
(WebCore::Display::Box::setLeft):
(WebCore::Display::Box::setWidth):
(WebCore::Display::Box::setHeight):
(WebCore::Display::Box::Rect::invalidatePosition):
(WebCore::Display::Box::Rect::setHasValidPosition):
(WebCore::Display::Box::Rect::Rect):
(WebCore::Display::Box::Rect::top const):
(WebCore::Display::Box::Rect::left const):
(WebCore::Display::Box::Rect::bottom const):
(WebCore::Display::Box::Rect::right const):
(WebCore::Display::Box::Rect::topLeft const):
(WebCore::Display::Box::Rect::bottomRight const):
(WebCore::Display::Box::Rect::size const):
(WebCore::Display::Box::Rect::width const):
(WebCore::Display::Box::Rect::height const):
(WebCore::Display::Box::Rect::setTopLeft):
(WebCore::Display::Box::Rect::setTop):
(WebCore::Display::Box::Rect::setLeft):
(WebCore::Display::Box::Rect::setWidth):
(WebCore::Display::Box::Rect::setHeight):
(WebCore::Display::Box::Rect::shiftLeftTo):
(WebCore::Display::Box::Rect::shiftRightTo):
(WebCore::Display::Box::Rect::shiftTopTo):
(WebCore::Display::Box::Rect::shiftBottomTo):
(WebCore::Display::Box::Rect::expand):
(WebCore::Display::Box::invalidateTop): Deleted.
(WebCore::Display::Box::invalidateLeft): Deleted.
(WebCore::Display::Box::invalidateWidth): Deleted.
(WebCore::Display::Box::invalidateHeight): Deleted.
(WebCore::Display::Box::hasValidPosition const): Deleted.
(WebCore::Display::Box::hasValidSize const): Deleted.
(WebCore::Display::Box::hasValidGeometry const): Deleted.
(WebCore::Display::Box::invalidatePosition): Deleted.
(WebCore::Display::Box::setHasValidPosition): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232250
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Mon, 28 May 2018 18:56:34 +0000 (18:56 +0000)]
[LFC] Add formatting context testing codepath in FrameViewLayoutContext
https://bugs.webkit.org/show_bug.cgi?id=186036
Reviewed by Antti Koivisto.
This is to verify the formatting context layout correctness.
* layout/LayoutContext.cpp:
(WebCore::Layout::LayoutContext::LayoutContext):
(WebCore::Layout::LayoutContext::initializeRoot):
* layout/LayoutContext.h:
(WebCore::Layout::LayoutContext::displayBoxForLayoutBox const):
* page/FrameViewLayoutContext.cpp:
(WebCore::layoutUsingFormattingContext):
(WebCore::FrameViewLayoutContext::layout):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232249
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Mon, 28 May 2018 17:55:18 +0000 (17:55 +0000)]
[LFC] Add layout tree verification.
https://bugs.webkit.org/show_bug.cgi?id=186018
Reviewed by Antti Koivisto.
Compare layout and render tree geometry and output the mismtaching rectangles.
* Sources.txt:
* WebCore.xcodeproj/project.pbxproj: Add missing headers and make then private.
* layout/LayoutContext.h:
* layout/Verification.cpp: Added.
(WebCore::Layout::outputMismatchedBoxInformationIfNeeded):
(WebCore::Layout::verifySubtree):
(WebCore::Layout::LayoutContext::verifyAndOutputLayoutTree const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232248
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
csaavedra@igalia.com [Mon, 28 May 2018 16:03:39 +0000 (16:03 +0000)]
[GTK][WPE] AppCache test gardening
Some appcache tests were flaky due to console output, see
https://bugs.webkit.org/show_bug.cgi?id=185431 for more info.
Fixing those by dumping the output to stderr instead.
At the same time, clean up the expectations for appcache tests,
many were now passing, so several old bugs got closed now.
Unreviewed gardening.
* platform/gtk/TestExpectations:
* platform/wpe/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232247
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 28 May 2018 15:20:04 +0000 (15:20 +0000)]
Modernize SVGRenderStyleDefs.h
https://bugs.webkit.org/show_bug.cgi?id=186024
Patch by Sam Weinig <sam@webkit.org> on 2018-05-28
Reviewed by Daniel Bates.
Source/WebCore:
Modernized the set of enums in SVGRenderStyleDefs.h and WindRule.h by:
- Converting them to enum classes
- Renaming them to remove unnecessary prefix 'E's
- Renaming values to take advantage of enum class scoping (e.g. StyleDifferenceEqual -> StyleDifference::Equal)
- Renaming to match modern conventions (e.g BNONE -> None)
Modernizes the following enums:
SVGPaintType
BaselineShift (renamed from EBaselineShift)
TextAnchor (renamed from ETextAnchor)
ColorInterpolation (renamed from EColorInterpolation)
ColorRendering (renamed from EColorRendering)
ShapeRendering (renamed from EShapeRendering)
GlyphOrientation (renamed from EGlyphOrientation)
AlignmentBaseline (renamed from EAlignmentBaseline)
DominantBaseline (renamed from EDominantBaseline)
VectorEffect (renamed from EVectorEffect)
BufferedRendering (renamed from EBufferedRendering)
MaskType (renamed from EMaskType)
WindRule
* css/CSSBasicShapes.cpp:
(WebCore::buildPathString):
(WebCore::buildPolygonString):
* css/CSSBasicShapes.h:
* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator WindRule const):
(WebCore::CSSPrimitiveValue::operator AlignmentBaseline const):
(WebCore::CSSPrimitiveValue::operator BufferedRendering const):
(WebCore::CSSPrimitiveValue::operator ColorInterpolation const):
(WebCore::CSSPrimitiveValue::operator ColorRendering const):
(WebCore::CSSPrimitiveValue::operator DominantBaseline const):
(WebCore::CSSPrimitiveValue::operator ShapeRendering const):
(WebCore::CSSPrimitiveValue::operator TextAnchor const):
(WebCore::CSSPrimitiveValue::operator VectorEffect const):
(WebCore::CSSPrimitiveValue::operator MaskType const):
(WebCore::CSSPrimitiveValue::operator EAlignmentBaseline const): Deleted.
(WebCore::CSSPrimitiveValue::operator EBufferedRendering const): Deleted.
(WebCore::CSSPrimitiveValue::operator EColorInterpolation const): Deleted.
(WebCore::CSSPrimitiveValue::operator EColorRendering const): Deleted.
(WebCore::CSSPrimitiveValue::operator EDominantBaseline const): Deleted.
(WebCore::CSSPrimitiveValue::operator EShapeRendering const): Deleted.
(WebCore::CSSPrimitiveValue::operator ETextAnchor const): Deleted.
(WebCore::CSSPrimitiveValue::operator EVectorEffect const): Deleted.
(WebCore::CSSPrimitiveValue::operator EMaskType const): Deleted.
* css/SVGCSSComputedStyleDeclaration.cpp:
(WebCore::glyphOrientationToCSSPrimitiveValue):
(WebCore::ComputedStyleExtractor::adjustSVGPaintForCurrentColor const):
(WebCore::ComputedStyleExtractor::svgPropertyValue):
* css/StyleBuilderConverter.h:
(WebCore::StyleBuilderConverter::convertGlyphOrientation):
(WebCore::StyleBuilderConverter::convertGlyphOrientationOrAuto):
* css/StyleBuilderCustom.h:
(WebCore::StyleBuilderCustom::applyValueBaselineShift):
(WebCore::StyleBuilderCustom::applyValueFill):
(WebCore::StyleBuilderCustom::applyValueStroke):
* css/parser/CSSPropertyParser.cpp:
(WebCore::consumeBasicShapePolygon):
(WebCore::consumeBasicShapePath):
* html/canvas/CanvasRenderingContext2DBase.cpp:
(WebCore::toWindRule):
* page/animation/CSSPropertyAnimation.cpp:
(WebCore::PropertyWrapperSVGPaint::PropertyWrapperSVGPaint):
* platform/graphics/FloatPolygon.cpp:
(WebCore::FloatPolygon::contains const):
* platform/graphics/GraphicsContext.cpp:
(WebCore::GraphicsContext::fillRectWithRoundedHole):
* platform/graphics/GraphicsContext.h:
* platform/graphics/GraphicsLayer.cpp:
(WebCore::GraphicsLayer::shapeLayerWindRule const):
* platform/graphics/GraphicsLayer.h:
* platform/graphics/GraphicsTypes.cpp:
(WebCore::operator<<):
* platform/graphics/Path.h:
* platform/graphics/ShadowBlur.cpp:
(WebCore::ShadowBlur::drawInsetShadow):
(WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
(WebCore::ShadowBlur::drawInsetShadowWithTiling):
* platform/graphics/WindRule.h:
(): Deleted.
* platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
(PlatformCALayerCocoa::shapeWindRule const):
(PlatformCALayerCocoa::setShapeWindRule):
* platform/graphics/cg/GraphicsContextCG.cpp:
(WebCore::calculateDrawingMode):
(WebCore::GraphicsContext::fillPath):
(WebCore::GraphicsContext::fillRectWithRoundedHole):
(WebCore::GraphicsContext::clipPath):
* platform/graphics/cg/PathCG.cpp:
(WebCore::Path::contains const):
* platform/mock/MockRealtimeVideoSource.cpp:
(WebCore::MockRealtimeVideoSource::drawAnimation):
* rendering/FilterEffectRenderer.cpp:
(WebCore::FilterEffectRenderer::buildReferenceFilter):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::paintBorder):
(WebCore::RenderBoxModelObject::clipBorderSidePolygon):
* rendering/RenderElement.cpp:
(WebCore::RenderElement::paintOutline):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::computeClipPath const):
* rendering/style/BasicShapes.h:
(WebCore::BasicShape::windRule const):
* rendering/style/RenderStyle.h:
(WebCore::RenderStyle::fillPaintType const):
(WebCore::RenderStyle::setFillPaintColor):
(WebCore::RenderStyle::strokePaintType const):
(WebCore::RenderStyle::setStrokePaintColor):
* rendering/style/SVGRenderStyle.h:
(WebCore::SVGRenderStyle::initialAlignmentBaseline):
(WebCore::SVGRenderStyle::initialDominantBaseline):
(WebCore::SVGRenderStyle::initialBaselineShift):
(WebCore::SVGRenderStyle::initialVectorEffect):
(WebCore::SVGRenderStyle::initialBufferedRendering):
(WebCore::SVGRenderStyle::initialClipRule):
(WebCore::SVGRenderStyle::initialColorInterpolation):
(WebCore::SVGRenderStyle::initialColorInterpolationFilters):
(WebCore::SVGRenderStyle::initialColorRendering):
(WebCore::SVGRenderStyle::initialFillRule):
(WebCore::SVGRenderStyle::initialShapeRendering):
(WebCore::SVGRenderStyle::initialTextAnchor):
(WebCore::SVGRenderStyle::initialGlyphOrientationHorizontal):
(WebCore::SVGRenderStyle::initialGlyphOrientationVertical):
(WebCore::SVGRenderStyle::initialFillPaintType):
(WebCore::SVGRenderStyle::initialStrokePaintType):
(WebCore::SVGRenderStyle::initialMaskType):
(WebCore::SVGRenderStyle::setAlignmentBaseline):
(WebCore::SVGRenderStyle::setDominantBaseline):
(WebCore::SVGRenderStyle::setBaselineShift):
(WebCore::SVGRenderStyle::setVectorEffect):
(WebCore::SVGRenderStyle::setBufferedRendering):
(WebCore::SVGRenderStyle::setClipRule):
(WebCore::SVGRenderStyle::setColorInterpolation):
(WebCore::SVGRenderStyle::setColorInterpolationFilters):
(WebCore::SVGRenderStyle::setColorRendering):
(WebCore::SVGRenderStyle::setFillRule):
(WebCore::SVGRenderStyle::setShapeRendering):
(WebCore::SVGRenderStyle::setTextAnchor):
(WebCore::SVGRenderStyle::setGlyphOrientationHorizontal):
(WebCore::SVGRenderStyle::setGlyphOrientationVertical):
(WebCore::SVGRenderStyle::setMaskType):
(WebCore::SVGRenderStyle::alignmentBaseline const):
(WebCore::SVGRenderStyle::dominantBaseline const):
(WebCore::SVGRenderStyle::baselineShift const):
(WebCore::SVGRenderStyle::vectorEffect const):
(WebCore::SVGRenderStyle::bufferedRendering const):
(WebCore::SVGRenderStyle::clipRule const):
(WebCore::SVGRenderStyle::colorInterpolation const):
(WebCore::SVGRenderStyle::colorInterpolationFilters const):
(WebCore::SVGRenderStyle::colorRendering const):
(WebCore::SVGRenderStyle::fillRule const):
(WebCore::SVGRenderStyle::shapeRendering const):
(WebCore::SVGRenderStyle::textAnchor const):
(WebCore::SVGRenderStyle::glyphOrientationHorizontal const):
(WebCore::SVGRenderStyle::glyphOrientationVertical const):
(WebCore::SVGRenderStyle::fillPaintType const):
(WebCore::SVGRenderStyle::strokePaintType const):
(WebCore::SVGRenderStyle::maskType const):
(WebCore::SVGRenderStyle::visitedLinkFillPaintType const):
(WebCore::SVGRenderStyle::visitedLinkStrokePaintType const):
(WebCore::SVGRenderStyle::hasStroke const):
(WebCore::SVGRenderStyle::hasFill const):
(WebCore::SVGRenderStyle::setBitDefaults):
* rendering/style/SVGRenderStyleDefs.h:
(WebCore::StyleFillData::create):
(WebCore::StyleFillData::operator!= const):
(WebCore::StyleStrokeData::create):
(WebCore::StyleStrokeData::operator!= const):
(WebCore::StyleStopData::create):
(WebCore::StyleStopData::operator!= const):
(WebCore::StyleTextData::create):
(WebCore::StyleTextData::operator!= const):
(WebCore::StyleMiscData::create):
(WebCore::StyleMiscData::operator!= const):
(WebCore::StyleShadowSVGData::create):
(WebCore::StyleShadowSVGData::operator!= const):
(WebCore::StyleResourceData::create):
(WebCore::StyleResourceData::operator!= const):
(WebCore::StyleInheritedResourceData::create):
(WebCore::StyleInheritedResourceData::operator!= const):
(WebCore::StyleLayoutData::create):
(WebCore::StyleLayoutData::operator!= const):
(): Deleted.
* rendering/svg/RenderSVGImage.cpp:
(WebCore::RenderSVGImage::paint):
* rendering/svg/RenderSVGRect.cpp:
(WebCore::RenderSVGRect::updateShapeFromElement):
* rendering/svg/RenderSVGResource.cpp:
(WebCore::requestPaintingResource):
* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::pathOnlyClipping):
* rendering/svg/RenderSVGResourceFilter.cpp:
(WebCore::RenderSVGResourceFilter::buildPrimitives const):
* rendering/svg/RenderSVGResourceGradient.cpp:
(WebCore::RenderSVGResourceGradient::applyResource):
* rendering/svg/RenderSVGResourceMasker.cpp:
(WebCore::RenderSVGResourceMasker::applyResource):
(WebCore::RenderSVGResourceMasker::drawContentIntoMaskImage):
* rendering/svg/RenderSVGResourcePattern.cpp:
(WebCore::RenderSVGResourcePattern::applyResource):
* rendering/svg/RenderSVGShape.cpp:
(WebCore::RenderSVGShape::paint):
* rendering/svg/RenderSVGShape.h:
(WebCore::RenderSVGShape::hasNonScalingStroke const):
* rendering/svg/SVGRenderTreeAsText.cpp:
(WebCore::writeStyle):
(WebCore::writeSVGInlineTextBox):
* rendering/svg/SVGResources.cpp:
(WebCore::paintingResourceFromSVGPaint):
* rendering/svg/SVGTextChunk.cpp:
(WebCore::SVGTextChunk::SVGTextChunk):
* rendering/svg/SVGTextLayoutEngineBaseline.cpp:
(WebCore::SVGTextLayoutEngineBaseline::calculateBaselineShift const):
(WebCore::SVGTextLayoutEngineBaseline::dominantBaselineToAlignmentBaseline const):
(WebCore::SVGTextLayoutEngineBaseline::calculateAlignmentBaselineShift const):
(WebCore::SVGTextLayoutEngineBaseline::calculateGlyphOrientationAngle const):
* rendering/svg/SVGTextLayoutEngineBaseline.h:
Source/WebKit:
* Shared/RemoteLayerTree/RemoteLayerTreePropertyApplier.mm:
(WebKit::applyPropertiesToLayer):
* Shared/RemoteLayerTree/RemoteLayerTreeTransaction.mm:
(WebKit::RemoteLayerTreeTransaction::LayerProperties::LayerProperties):
Update for new enum names.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232246
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
csaavedra@igalia.com [Mon, 28 May 2018 13:25:01 +0000 (13:25 +0000)]
[GTK][WPE] transitions/interrupted-transition-hardware.html failing
Unreviewed gardening, image-only failure.
* platform/gtk/TestExpectations:
* platform/wpe/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232245
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Mon, 28 May 2018 12:26:05 +0000 (12:26 +0000)]
[WTF] Add clz32 / clz64 for MSVC
https://bugs.webkit.org/show_bug.cgi?id=186023
Reviewed by Daniel Bates.
Source/JavaScriptCore:
Move clz32 and clz64 to WTF.
* runtime/MathCommon.h:
(JSC::clz32): Deleted.
(JSC::clz64): Deleted.
Source/WTF:
This patch adds efficient implementations of clz32 and clz64 for MSVC.
While MSVC has _lzcnt intrinsic, it is only valid if the CPU has lzcnt instruction.
Instead of checking cpuid here, we just use _BitScanReverse and _BitScanReverse64.
* wtf/MathExtras.h:
(WTF::clz32):
(WTF::clz64):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232244
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
carlosgc@webkit.org [Mon, 28 May 2018 10:56:08 +0000 (10:56 +0000)]
Unreviewed. Update OptionsGTK.cmake and NEWS for 2.21.3 release.
.:
* Source/cmake/OptionsGTK.cmake: Bump version numbers.
Source/WebKit:
* gtk/NEWS: Add release notes for 2.21.3.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232242
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 28 May 2018 10:15:45 +0000 (10:15 +0000)]
[Web Animations] Test webanimations/css-animations.html is crashing
https://bugs.webkit.org/show_bug.cgi?id=186031
Patch by Carlos Garcia Campos <cgarcia@igalia.com> on 2018-05-28
Reviewed by Antoine Quint.
This is another case of std::optional value being used while it's nullopt, I guess this started to fail when we
stopped using the WTF implementation of std::optional. The problem is that we try to get the current iteration
of a declarative animation when the active time is unresolved.
* animation/DeclarativeAnimation.cpp:
(WebCore::DeclarativeAnimation::invalidateDOMEvents): Use value_or(0) instead of value() to get the current
iteration of the effect.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232241
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 28 May 2018 08:18:35 +0000 (08:18 +0000)]
[GStreamer] Handle changes in the "drm-preferred-decryption-system-id" NEED_CONTEXT message.
https://bugs.webkit.org/show_bug.cgi?id=185948
Patch by Thibault Saunier <tsaunier@igalia.com> on 2018-05-28
Reviewed by Xabier Rodriguez-Calvar.
Source/WebCore:
- The "stream-encryption-systems" field of the "drm-preferred-decryption-system-id" query was renamed to
"avalaible-stream-encryption-systems"
- It can now be NULL, meaning there is no decryptor avalaible.
Tests: imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-*
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::extractEventsAndSystemsFromMessage): Handle NULL value for "avalaible-stream-encryption-systems",
moved some code to make the order of the Arrays in the pair clearer.
Tools:
When the patch introducing gst_protection_filter_systems_by_available_decryptors was merged, we changed sensibly its behaviour
concerning the way empty results is represented (now returning NULL instead of an array of 1(NULL) element) and this change was not
properly taken into account in the qtdemux patch that uses it and got upstreamed. Those 3 new patches fixe that and change the
NEED_CONTEXT field names to clarify the meaning of "stream-encryption-systems".
* gstreamer/jhbuild.modules:
* gstreamer/patches/gst-plugins-good-0001-qtdemux-Do-not-run-the-preferred-decryptor-context-q.patch: Added. Merged upstream as
3e063703b3a51b8aaa7f75f36c4660c583a60e93
* gstreamer/patches/gst-plugins-good-0002-qtdemux-Do-not-unref-a-NULL-stream_tags.patch: Added. Merged upstream as
43a540b1cd9f162d3dae5d50e36703dfaf558a3e
* gstreamer/patches/gst-plugins-good-0003-qtdemux-Clarify-field-name-about-stream-encryption-s.patch: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232240
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 28 May 2018 05:31:57 +0000 (05:31 +0000)]
Reverted the changes made for https://webkit.org/b/186016
They broke the USE(APPLE_INTERNAL_SDK) Sierra build.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232239
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 28 May 2018 05:04:16 +0000 (05:04 +0000)]
Tried to fix the pre-High Sierra USE(APPLE_INTERNAL_SDK) build
* pal/spi/cg/CoreGraphicsSPI.h: #undef confirm, which is defined by ApplicationServicesPriv.h.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232238
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 28 May 2018 04:31:53 +0000 (04:31 +0000)]
Tried to fix the 32-bit USE(APPLE_INTERNAL_SDK) build.
* pal/spi/mac/QuickDrawSPI.h: Import ApplicationServicesPriv.h instead of QuickDrawPriv.h.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232237
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ddkilzer@apple.com [Mon, 28 May 2018 04:21:09 +0000 (04:21 +0000)]
[iOS] Fix warnings about leaks found by clang static analyzer
<https://webkit.org/b/186009>
<rdar://problem/
40574267>
Reviewed by Daniel Bates.
Source/ThirdParty/libwebrtc:
* Source/third_party/opus/src/src/opus_compare.c:
* Source/third_party/opus/src/src/opus_demo.c:
(main):
- Free allocated memory on early returns.
* Source/third_party/usrsctp/usrsctplib/user_mbuf.c:
(clust_constructor_dup):
(mb_ctor_clust):
- Free allocated memory if `m` is NULL.
* Source/third_party/usrsctp/usrsctplib/user_socket.c:
(usrsctp_connect): Free `sa` memory if getsockaddr() returns an
error, but still allocates memory for `sa`.
* WebKit/patch-opus.diff: Add patch for opus changes.
* WebKit/patch-usrsctp: Rename empty file to patch-usrsctp.diff.
* WebKit/patch-usrsctp.diff: Add patch for usrsctp changes.
* libwebrtc.xcodeproj/project.pbxproj: Remove opus_compare.c,
opus_demo.c, and repacketizer_demo.c from opus target. This
code is for stand-alone tools, and although it may be removed
during dead code linking, we don't need to spend time compiling
it.
Source/WebCore:
* Modules/webauthn/cocoa/LocalAuthenticator.mm:
(WebCore::LocalAuthenticator::makeCredential):
(WebCore::LocalAuthenticator::getAssertion):
(WebCore::LocalAuthenticator::issueClientCertificate const):
- Don't leak CF objects in early return paths, and get rid of
`retained*` variables, by making original variables use
RetainPtr<>.
* bridge/objc/WebScriptObject.mm:
(+[WebUndefined allocWithZone:]): Modernize WebUndefined by
using NeverDestroyed<RetainPr<WebUndefined>> type. Explicitly
retain the object returned on each call.
(+[WebUndefined undefined]): Explicitly autorelease the object
returned. Note that neither of these changes fixes the static
analyzer warnings in this source file.
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::exernalDeviceDisplayNameForPlayer): Use RetainPtr<> to
stop leaking NSString objects in a loop.
* platform/ios/wak/WAKWindow.h:
(-[WAKWindow _newFirstResponderAfterResigning]): Mark as
NS_RETURNS_NOT_RETAINED like the corresponding AppKit method
since this doesn't return a new object. This fixes some
false-positive leaks warnings.
Source/WebKit:
* UIProcess/Automation/ios/WebAutomationSessionIOS.mm:
(WebKit::WebAutomationSession::platformSimulateKeySequence): Fix
leak of two WebEvent objects that happened in a loop.
* UIProcess/Cocoa/SystemPreviewControllerCocoa.mm:
(-[_WKPreviewControllerDelegate previewController:transitionImageForPreviewItem:contentRect:]):
Fix leak of a UIImage.
Source/WebKitLegacy/mac:
* WebView/WebHTMLView.mm:
(-[WebHTMLView doCommandBySelector:]): Fix use of an
uninitialized boolean variable (`eventWasHandled`) that only
happened on iOS.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232236
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 28 May 2018 04:17:47 +0000 (04:17 +0000)]
[Cocoa] Avoid importing directly from subumbrella frameworks
https://bugs.webkit.org/show_bug.cgi?id=186016
Reviewed by Sam Weinig.
Source/WebCore:
* Configurations/WebCore.xcconfig: Removed -iframework options from OTHER_CFLAGS and
OTHER_CPLUSPLUSFLAGS.
* editing/mac/DictionaryLookup.mm: Import Quartz.h instead of a PDFKit header.
* html/HTMLKeygenElement.cpp: Removed "using namespace WebCore" from this WebCore
implementation file.
* platform/mac/PlatformEventFactoryMac.mm: Import Carbon.h instead of HIToolbox headers.
* platform/mac/PlatformScreenMac.mm: Import ApplicationServices.h instead of ColorSync.h
when using SDKs earlier than 10.13.
* platform/mediastream/CaptureDeviceManager.cpp: Enclosed the definitions in the WebCore
namespace and removed "using namespace WebCore" from this WebCore implementation file.
* platform/text/mac/TextEncodingRegistryMac.mm: Import Carbon.h instead of CarbonCore.h.
Source/WebCore/PAL:
* Configurations/PAL.xcconfig: Removed -iframework options from OTHER_CFLAGS and
OTHER_CPLUSPLUSFLAGS.
* pal/spi/cg/CoreGraphicsSPI.h: Import ApplicationServices.h instead of ColorSync.h
when using SDKs earlier than 10.13.
* pal/spi/mac/HIToolboxSPI.h: Import CarbonPriv.h instead of HIToolboxPriv.h.
* pal/spi/mac/QuickLookMacSPI.h: Import Quartz.h instead of a QuickLookUI header.
Source/WebKit:
* Configurations/BaseTarget.xcconfig: Removed -iframework options from OTHER_CFLAGS and
OTHER_CPLUSPLUSFLAGS.
* UIProcess/Automation/mac/WebAutomationSessionMac.mm: Import Carbon.h instead of an
HIToolbox header.
* UIProcess/Cocoa/WebViewImpl.mm: Ditto.
* UIProcess/mac/WKPrintingView.mm: Import Quartz.h instead of a PDFKit header.
* UIProcess/mac/WKTextInputWindowController.mm: Import Carbon.h instead of an HIToolbox
header.
* WebProcess/Plugins/PDF/PDFAnnotationTextWidgetDetails.h: Import Quartz.h instead of a
PDFKit header.
* WebProcess/Plugins/PDF/PDFLayerControllerSPI.h: Ditto.
* WebProcess/Plugins/PDF/PDFPlugin.mm: Ditto.
* WebProcess/Plugins/PDF/PDFPluginAnnotation.mm: Ditto.
* WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm: Ditto.
* WebProcess/Plugins/PDF/PDFPluginPasswordField.mm: Ditto.
* WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm: Ditto.
* WebProcess/WebPage/mac/WebPageMac.mm: Ditto.
Source/WebKitLegacy/mac:
* Carbon/CarbonWindowAdapter.h: Import Carbon.h instead of HIToolbox headers.
* Carbon/CarbonWindowAdapter.mm: Ditto.
* Carbon/CarbonWindowFrame.m: Ditto.
* Carbon/HIViewAdapter.h: Ditto.
* Configurations/WebKitLegacy.xcconfig: Removed -iframework options from OTHER_CFLAGS and
OTHER_CPLUSPLUSFLAGS.
* Plugins/WebNetscapePluginEventHandlerCarbon.mm: Import Carbon.h instead of CarbonEvents.h.
* WebView/WebPDFDocumentExtras.mm: Import Quartz.h instead of a PDFKit header.
* WebView/WebPDFView.h: Ditto.
Tools:
* DumpRenderTree/cg/PixelDumpSupportCG.cpp: Include CoreServices.h instead of a
LaunchServices header.
* DumpRenderTree/mac/Configurations/BaseTarget.xcconfig: Removed -iframework options from
OTHER_CFLAGS and OTHER_CPLUSPLUSFLAGS.
* DumpRenderTree/mac/LayoutTestHelper.m: Import ApplicationServices.h instead of ColorSync.h
when using SDKs earlier than 10.13.
* TestWebKitAPI/Configurations/Base.xcconfig: Removed -iframework options from OTHER_CFLAGS
and OTHER_CPLUSPLUSFLAGS.
* TestWebKitAPI/Tests/mac/MediaPlaybackSleepAssertion.mm: Import Carbon.h instead of an
HIToolbox header.
* WebKitTestRunner/Configurations/BaseTarget.xcconfig: Removed -iframework options from
OTHER_CFLAGS and OTHER_CPLUSPLUSFLAGS.
* WebKitTestRunner/cg/TestInvocationCG.cpp: Include CoreServices.h instead of a
LaunchServices header.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232235
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
Hironori.Fujii@sony.com [Mon, 28 May 2018 03:49:08 +0000 (03:49 +0000)]
[Win][MiniBrowser] Add MainWindow class
https://bugs.webkit.org/show_bug.cgi?id=185814
Reviewed by Per Arne Vollan.
This is a sub task of Bug 184770. Added a new class MainWindow to
represent the main window which will be shared among WK1 and WK2.
This change is partial so that it's easy to review this patch.
I'll move more functions into MainWindow.cpp, and remove more
global variables in forthcoming patches.
* MiniBrowser/win/CMakeLists.txt: Added MainWindow.cpp.
* MiniBrowser/win/Common.cpp: Removed MainWindow related global
variables hMainWnd, hURLBarWnd, hBackButtonWnd and
hForwardButtonWnd. Added a new global variable gMainWindow.
(WndProc): Moved to MainWindow.cpp.
(resizeSubViews): Ditto.
(ToggleMenuFlag): Removed static to be called from MainWindow.cpp.
(ToggleMenuItem): Ditto.
(CustomUserAgent): Follow the global variables removal.
(DisplayAuthDialog): Ditto.
(loadURL): Ditto.
(WndProc): Renamed to MainWindow::WndProc.
* MiniBrowser/win/MainWindow.cpp: Added.
(MainWindow::registerClass): Renamed from MyRegisterClass of WinMain.cpp.
(MainWindow::init): Extracted MainWindow initialization code from wWinMain.
(MainWindow::resizeSubViews): Moved from Common.cpp.
(MainWindow::WndProc): Ditto.
* MiniBrowser/win/MainWindow.h: Added.
(MainWindow::hwnd):
(MainWindow::browserWindow):
* MiniBrowser/win/MiniBrowser.cpp:
(MiniBrowser::init):
(MiniBrowser::prepareViews): Extract some code into MiniBrowser::loadDefaultHTML.
(MiniBrowser::loadDefaultHTML): Extracted from MiniBrowser::prepareViews.
* MiniBrowser/win/MiniBrowser.h:
* MiniBrowser/win/WinMain.cpp:
(wWinMain): Extracted MainWindow initialization code into MainWindow::init.
(MyRegisterClass): Moved to MainWindow.cpp.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232234
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
Hironori.Fujii@sony.com [Mon, 28 May 2018 03:21:52 +0000 (03:21 +0000)]
REGRESSION(r232198) [WinCairo] cannot convert from 'WTF::StringView' to 'const WTF::String'
https://bugs.webkit.org/show_bug.cgi?id=186027
Unreviewed build fix
Source/WebCore:
No new tests (No behavior change).
* platform/network/curl/AuthenticationChallengeCurl.cpp:
(WebCore::AuthenticationChallenge::protectionSpaceFromHandle):
* platform/network/curl/CurlRequest.cpp:
(WebCore::CurlRequest::setupTransfer):
(WebCore::CurlRequest::willSetupSslCtx):
Source/WebKitLegacy/win:
* WebMutableURLRequest.cpp:
(WebMutableURLRequest::setAllowsAnyHTTPSCertificate):
(WebMutableURLRequest::setClientCertificate):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232233
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ticaiolima@gmail.com [Mon, 28 May 2018 03:19:37 +0000 (03:19 +0000)]
[ESNext][BigInt] Implement "+" and "-" unary operation
https://bugs.webkit.org/show_bug.cgi?id=182214
Reviewed by Yusuke Suzuki.
JSTests:
* stress/big-int-negate-basic.js: Added.
* stress/big-int-negate-jit.js: Added.
* stress/big-int-unary-plus.js: Added.
Source/JavaScriptCore:
This Patch is implementing support to "-" unary operation on BigInt.
It is also changing the logic of ASTBuilder::makeNegateNode to
calculate BigInt literals with properly sign, avoiding
unecessary operation. It required a refactoring into
JSBigInt::parseInt to consider the sign as parameter.
We are also introducing a new DFG Node called ValueNegate to handle BigInt negate
operations. With the introduction of BigInt, it is not true
that every negate operation returns a Number. As ArithNegate is a
node that considers its result is always a Number, like all other
Arith<Operation>, we decided to keep this consistency and use ValueNegate when
speculation indicates that the operand is a BigInt.
This design is following the same distinction between ArithAdd and
ValueAdd. Also, this new node will make simpler the introduction of
optimizations when we create speculation paths for BigInt in future
patches.
In the case of "+" unary operation on BigInt, the current semantic we already have
is correctly, since it needs to throw TypeError because of ToNumber call[1].
In such case, we are adding tests to verify other edge cases.
[1] - https://tc39.github.io/proposal-bigint/#sec-unary-plus-operator
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::addBigIntConstant):
* bytecompiler/BytecodeGenerator.h:
* bytecompiler/NodesCodegen.cpp:
(JSC::BigIntNode::jsValue const):
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::makeSafe):
(JSC::DFG::ByteCodeParser::parseBlock):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGDoesGC.cpp:
(JSC::DFG::doesGC):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
* dfg/DFGNode.h:
(JSC::DFG::Node::arithNodeFlags):
* dfg/DFGNodeType.h:
* dfg/DFGPredictionPropagationPhase.cpp:
* dfg/DFGSafeToExecute.h:
(JSC::DFG::safeToExecute):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileValueNegate):
(JSC::DFG::SpeculativeJIT::compileArithNegate):
* dfg/DFGSpeculativeJIT.h:
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLLowerDFGToB3.cpp:
(JSC::FTL::DFG::LowerDFGToB3::compileNode):
(JSC::FTL::DFG::LowerDFGToB3::compileValueNegate):
(JSC::FTL::DFG::LowerDFGToB3::compileArithNegate):
* jit/JITOperations.cpp:
* parser/ASTBuilder.h:
(JSC::ASTBuilder::createBigIntWithSign):
(JSC::ASTBuilder::createBigIntFromUnaryOperation):
(JSC::ASTBuilder::makeNegateNode):
* parser/NodeConstructors.h:
(JSC::BigIntNode::BigIntNode):
* parser/Nodes.h:
* runtime/CommonSlowPaths.cpp:
(JSC::updateArithProfileForUnaryArithOp):
(JSC::SLOW_PATH_DECL):
* runtime/JSBigInt.cpp:
(JSC::JSBigInt::parseInt):
* runtime/JSBigInt.h:
* runtime/JSCJSValueInlines.h:
(JSC::JSValue::strictEqualSlowCaseInline):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232232
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 28 May 2018 02:51:00 +0000 (02:51 +0000)]
Tried to fix the 32-bit !ASSERT_DISABLED build after r232211.
* jit/JITOperations.cpp:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232231
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
Hironori.Fujii@sony.com [Mon, 28 May 2018 02:22:35 +0000 (02:22 +0000)]
[Win][MiniBrowser] Remove URL argument of MiniBrowser::init
https://bugs.webkit.org/show_bug.cgi?id=185969
Reviewed by Alex Christensen.
MiniBrowser::init takes URL argument, but it's used only for
loading default HTML if URL is not given.
- Add a new method MiniBrowser::loadHTMLString
- Remove loadHTMLString process from MiniBrowser::prepareViews
* MiniBrowser/win/MiniBrowser.cpp:
(MiniBrowser::init): Removed `requestedURL` argument.
(MiniBrowser::prepareViews): Ditto.
(MiniBrowser::loadHTMLString): New.
(MiniBrowser::loadURL): Return E_INVALIDARG if passedURL is null instead of calling loadHTMLString.
* MiniBrowser/win/MiniBrowser.h: Removed URL argument. Added loadHTMLString.
* MiniBrowser/win/WinMain.cpp:
(wWinMain): Call MiniBrowser::loadHTMLString if URL is not given.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232230
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 28 May 2018 00:49:21 +0000 (00:49 +0000)]
Modernize RenderStyleConstants.h - Part 3
https://bugs.webkit.org/show_bug.cgi?id=186015
Patch by Sam Weinig <sam@webkit.org> on 2018-05-27
Reviewed by Yusuke Suzuki.
Source/WebCore:
Modernized the third and final set of enums in RenderStyleConstants.h by:
- Converting them to enum classes
- Renaming them to remove unnecessary prefix 'E's
- Renaming values to take advantage of enum class scoping (e.g. StyleDifferenceEqual -> StyleDifference::Equal)
Modernizes the following enums:
TextDecoration
TextDecorationSkip (renamed from TextDecorationSkipItems)
TextUnderlinePosition
HangingPunctuation
SpeakAs (renamed from ESpeakAs)
TextEmphasisPosition (renamed from TextEmphasisPositions)
This final set of enums are mostly (TextUnderlinePosition isn't really) used as bitmasks,
so this change also converts their uses to use OptionSet.
* accessibility/AccessibilityObject.h:
(WebCore::AccessibilityObject::speakAsProperty const):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::speakAsProperty const):
(WebCore::AccessibilityRenderObject::hasPlainText const):
(WebCore::AccessibilityRenderObject::hasUnderline const):
* accessibility/AccessibilityRenderObject.h:
* accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(AXAttributeStringSetStyle):
* accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
(-[WebAccessibilityObjectWrapperBase baseAccessibilitySpeechHint]):
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(AXAttributeStringSetStyle):
* css/CSSComputedStyleDeclaration.cpp:
(WebCore::renderTextDecorationFlagsToCSSValue):
(WebCore::renderTextDecorationSkipFlagsToCSSValue):
(WebCore::renderEmphasisPositionFlagsToCSSValue):
(WebCore::speakAsToCSSValue):
(WebCore::hangingPunctuationToCSSValue):
* css/CSSLineBoxContainValue.h:
* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::operator HangingPunctuation const):
(WebCore::CSSPrimitiveValue::operator TextDecoration const):
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator TextUnderlinePosition const):
(WebCore::CSSPrimitiveValue::operator SpeakAs const):
(WebCore::CSSPrimitiveValue::operator ESpeakAs const): Deleted.
* css/StyleBuilderConverter.h:
(WebCore::StyleBuilderConverter::convertTextDecoration):
(WebCore::StyleBuilderConverter::valueToEmphasisPosition):
(WebCore::StyleBuilderConverter::convertTextEmphasisPosition):
(WebCore::StyleBuilderConverter::convertTextUnderlinePosition):
(WebCore::StyleBuilderConverter::valueToDecorationSkip):
(WebCore::StyleBuilderConverter::convertTextDecorationSkip):
(WebCore::StyleBuilderConverter::convertSpeakAs):
(WebCore::StyleBuilderConverter::convertHangingPunctuation):
* editing/cocoa/EditorCocoa.mm:
(WebCore::Editor::getTextDecorationAttributesRespectingTypingStyle const):
* editing/cocoa/HTMLConverter.mm:
(WebCore::editingAttributedStringFromRange):
* rendering/InlineFlowBox.cpp:
(WebCore::InlineFlowBox::maxLogicalBottomForTextDecorationLine const):
(WebCore::InlineFlowBox::minLogicalTopForTextDecorationLine const):
* rendering/InlineFlowBox.h:
* rendering/InlineTextBox.cpp:
(WebCore::emphasisPositionHasNeitherLeftNorRight):
(WebCore::InlineTextBox::emphasisMarkExistsAndIsAbove const):
(WebCore::InlineTextBox::paint):
(WebCore::InlineTextBox::paintMarkedTextDecoration):
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::computeInlinePreferredLogicalWidths const):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::setLogicalWidthForTextRun):
(WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment):
* rendering/RenderElement.cpp:
(WebCore::RenderElement::enclosingRendererWithTextDecoration const):
* rendering/RenderElement.h:
* rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::addCell):
* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::canUseForStyle):
(WebCore::SimpleLineLayout::canUseForWithReason):
* rendering/SimpleLineLayoutFunctions.cpp:
(WebCore::SimpleLineLayout::paintFlow):
* rendering/TextDecorationPainter.cpp:
(WebCore::TextDecorationPainter::TextDecorationPainter):
(WebCore::TextDecorationPainter::paintTextDecoration):
(WebCore::collectStylesForRenderer):
(WebCore::TextDecorationPainter::stylesForRenderer):
* rendering/TextDecorationPainter.h:
* rendering/TextPaintStyle.cpp:
(WebCore::computeTextPaintStyle):
* rendering/line/BreakingContext.h:
(WebCore::BreakingContext::handleText):
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::RenderStyle):
(WebCore::RenderStyle::changeAffectsVisualOverflow const):
* rendering/style/RenderStyle.h:
(WebCore::RenderStyle::textDecorationsInEffect const):
(WebCore::RenderStyle::textDecoration const):
(WebCore::RenderStyle::textDecorationSkip const):
(WebCore::RenderStyle::hangingPunctuation const):
(WebCore::RenderStyle::textEmphasisPosition const):
(WebCore::RenderStyle::speakAs const):
(WebCore::RenderStyle::addToTextDecorationsInEffect):
(WebCore::RenderStyle::setTextDecorationsInEffect):
(WebCore::RenderStyle::setTextDecoration):
(WebCore::RenderStyle::setTextDecorationSkip):
(WebCore::RenderStyle::setSpeakAs):
(WebCore::RenderStyle::setTextEmphasisPosition):
(WebCore::RenderStyle::setHangingPunctuation):
(WebCore::RenderStyle::initialHangingPunctuation):
(WebCore::RenderStyle::initialTextDecoration):
(WebCore::RenderStyle::initialTextDecorationSkip):
(WebCore::RenderStyle::initialTextUnderlinePosition):
(WebCore::RenderStyle::initialSpeakAs):
(WebCore::RenderStyle::initialTextEmphasisPosition):
* rendering/style/RenderStyleConstants.h:
(WebCore::operator|): Deleted.
(WebCore::operator|=): Deleted.
* rendering/style/StyleRareInheritedData.cpp:
(WebCore::StyleRareInheritedData::StyleRareInheritedData):
* rendering/style/StyleVisualData.cpp:
(WebCore::StyleVisualData::StyleVisualData):
* rendering/svg/SVGInlineTextBox.cpp:
(WebCore::SVGInlineTextBox::paint):
(WebCore::positionOffsetForDecoration):
(WebCore::thicknessForDecoration):
(WebCore::findRendererDefininingTextDecoration):
(WebCore::SVGInlineTextBox::paintDecoration):
(WebCore::SVGInlineTextBox::paintDecorationWithStyle):
* rendering/svg/SVGInlineTextBox.h:
* style/InlineTextBoxStyle.cpp:
(WebCore::computeUnderlineOffset):
(WebCore::visualOverflowForDecorations):
Source/WebKitLegacy/mac:
* WebView/WebView.mm:
(-[WebView updateTextTouchBar]):
Update for new enum name.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232229
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ddkilzer@apple.com [Sun, 27 May 2018 16:50:42 +0000 (16:50 +0000)]
svn-apply fails when a patch has an empty file
<https://webkit.org/b/29684>
Reviewed by Daniel Bates.
Prior to this change, applying the following patches resulted in:
- svn: add empty file (failure)
- svn: delete empty file (failure)
- svn: rename empty file (failure)
- git: add empty file (false-positive success)
- git: delete empty file (success)
- git: rename empty file (failure)
* Scripts/VCSUtils.pm:
(parseSvnDiffHeader): Handle the case when there is no patch
following the header. If the file exists and is empty, that
means it's a deletion. If the file does not exist, that means
it's an addition. Everything else is a fatal error.
* Scripts/svn-apply:
(patch):
- Only apply a patch for deletion if it has one or more text
chunks.
- Add a case to handle adding an empty file (an addition with no
text chunks), and verify the file doesn't exist yet.
- Any unhandled patch is a fatal error.
* Scripts/webkitperl/VCSUtils_unittest/parseSvnDiffHeader.pl:
Add tests for adding an empty file and deleting an empty file.
* Scripts/webkitperl/VCSUtils_unittest/resources/empty.txt: Add.
Used by parseSvnDiffHeader.pl unit test for "add an empty file"
test case.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232228
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Sat, 26 May 2018 20:59:04 +0000 (20:59 +0000)]
testair sometimes crashes due to races in initialization of ARC4RandomNumberGenerator
https://bugs.webkit.org/show_bug.cgi?id=186014
Reviewed by Yusuke Suzuki.
testair launches a bunch of threads and the threads do B3 things that use random numbers.
Sometimes two threads will initialize the random number generator at the same time, because
that's what happens when you use static NeverDestroyed<>.
This changes that code to use std::call_once to initialize the shared
ARC4RandomNumberGenerator.
Also, this adds a diagnostic message to the lock's assertion. This assertion was the symptom
of the race, and knowing the state of the lock when the assertion fired gave a darn good clue
about what was going on: the lock's value was 0 at time of unlock, implying that another
thread reinitialized the lock to zero by rerunning the constructor.
* wtf/CryptographicallyRandomNumber.cpp:
* wtf/LockAlgorithmInlines.h:
(WTF::Hooks>::unlockSlow):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232227
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Sat, 26 May 2018 18:17:09 +0000 (18:17 +0000)]
[JSC] Rename Array#flatten to flat
https://bugs.webkit.org/show_bug.cgi?id=186012
Reviewed by Saam Barati.
JSTests:
* stress/array-flatten.js:
(shouldThrow):
* test262/expectations.yaml:
Source/JavaScriptCore:
Rename Array#flatten to Array#flat. This rename is done in TC39 since flatten
conflicts with the mootools' function name.
* builtins/ArrayPrototype.js:
(globalPrivate.flatIntoArray):
(flat):
(globalPrivate.flatIntoArrayWithCallback):
(flatMap):
(globalPrivate.flattenIntoArray): Deleted.
(flatten): Deleted.
(globalPrivate.flattenIntoArrayWithCallback): Deleted.
* runtime/ArrayPrototype.cpp:
(JSC::ArrayPrototype::finishCreation):
LayoutTests:
* inspector/model/remote-object-get-properties-expected.txt:
* js/Object-getOwnPropertyNames-expected.txt:
* js/script-tests/Object-getOwnPropertyNames.js:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232226
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Sat, 26 May 2018 15:26:03 +0000 (15:26 +0000)]
[LFC] Implement margin computation
https://bugs.webkit.org/show_bug.cgi?id=186008
Reviewed by Antti Koivisto.
* WebCore.xcodeproj/project.pbxproj:
* layout/FormattingContext.cpp:
(WebCore::Layout::FormattingContext::computeMargin const):
(WebCore::Layout::FormattingContext::marginTop const): Deleted.
(WebCore::Layout::FormattingContext::marginLeft const): Deleted.
(WebCore::Layout::FormattingContext::marginBottom const): Deleted.
(WebCore::Layout::FormattingContext::marginRight const): Deleted.
* layout/FormattingContext.h:
* layout/blockformatting/BlockFormattingContext.cpp:
(WebCore::Layout::BlockFormattingContext::layout const):
(WebCore::Layout::BlockFormattingContext::computeMargin const):
(WebCore::Layout::BlockFormattingContext::marginTop const): Deleted.
(WebCore::Layout::BlockFormattingContext::marginBottom const): Deleted.
* layout/blockformatting/BlockFormattingContext.h:
* layout/blockformatting/BlockFormattingContextGeometry.cpp:
(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeight):
(WebCore::Layout::BlockFormattingContext::Geometry::computedMargin):
* layout/blockformatting/BlockMarginCollapse.cpp:
(WebCore::Layout::_isMarginBottomCollapsedWithParent):
(WebCore::Layout::collapsedMarginBottomFromLastChild):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::marginTop):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::marginBottom):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::isMarginBottomCollapsedWithParent):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::isMarginTopCollapsedWithParentMarginBottom):
(WebCore::Layout::BlockMarginCollapse::marginTop): Deleted.
(WebCore::Layout::BlockMarginCollapse::marginBottom): Deleted.
(WebCore::Layout::BlockMarginCollapse::isMarginBottomCollapsedWithParent): Deleted.
(WebCore::Layout::BlockMarginCollapse::isMarginTopCollapsedWithParentMarginBottom): Deleted.
* layout/blockformatting/BlockMarginCollapse.h: Removed.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232225
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Sat, 26 May 2018 10:55:47 +0000 (10:55 +0000)]
Upgrade test262 to May 24 version
https://bugs.webkit.org/show_bug.cgi?id=185937
Reviewed by Darin Adler.
* test262/expectations.yaml:
* test262/harness/doneprintHandle.js:
(DONE):
* test262/latest-changes-summary.txt:
* test262/test/annexB/language/eval-code/direct/global-block-decl-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-block-decl-eval-global-existing-non-enumerable-global-init.js: Added.
* test262/test/annexB/language/eval-code/direct/global-if-decl-else-decl-a-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-if-decl-else-decl-a-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/direct/global-if-decl-else-decl-a-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/direct/global-if-decl-else-decl-b-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-if-decl-else-decl-b-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/direct/global-if-decl-else-decl-b-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/direct/global-if-decl-else-stmt-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-if-decl-else-stmt-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/direct/global-if-decl-else-stmt-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/direct/global-if-decl-no-else-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-if-decl-no-else-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/direct/global-if-decl-no-else-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/direct/global-if-stmt-else-decl-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-if-stmt-else-decl-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/direct/global-if-stmt-else-decl-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/direct/global-switch-case-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-switch-case-eval-global-existing-non-enumerable-global-init.js: Added.
* test262/test/annexB/language/eval-code/direct/global-switch-dflt-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/direct/global-switch-dflt-eval-global-existing-non-enumerable-global-init.js: Added.
* test262/test/annexB/language/eval-code/indirect/global-block-decl-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-block-decl-eval-global-existing-non-enumerable-global-init.js: Added.
* test262/test/annexB/language/eval-code/indirect/global-if-decl-else-decl-a-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-if-decl-else-decl-a-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/indirect/global-if-decl-else-decl-a-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/indirect/global-if-decl-else-decl-b-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-if-decl-else-decl-b-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/indirect/global-if-decl-else-decl-b-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/indirect/global-if-decl-else-stmt-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-if-decl-else-stmt-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/indirect/global-if-decl-else-stmt-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/indirect/global-if-decl-no-else-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-if-decl-no-else-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/indirect/global-if-decl-no-else-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/indirect/global-if-stmt-else-decl-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-if-stmt-else-decl-eval-global-existing-non-enumerable-global-init.js: Copied from JSTests/test262/test/annexB/language/eval-code/indirect/global-if-stmt-else-decl-eval-global-existing-global-init.js.
* test262/test/annexB/language/eval-code/indirect/global-switch-case-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-switch-case-eval-global-existing-non-enumerable-global-init.js: Added.
* test262/test/annexB/language/eval-code/indirect/global-switch-dflt-eval-global-existing-global-init.js:
* test262/test/annexB/language/eval-code/indirect/global-switch-dflt-eval-global-existing-non-enumerable-global-init.js: Added.
* test262/test/annexB/language/global-code/block-decl-global-existing-global-init.js: Added.
(262.evalScript.f):
* test262/test/annexB/language/global-code/block-decl-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.f):
* test262/test/annexB/language/global-code/if-decl-else-decl-a-global-existing-global-init.js: Added.
(262.evalScript.true.f):
(else._f):
* test262/test/annexB/language/global-code/if-decl-else-decl-a-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.true.f):
(else._f):
* test262/test/annexB/language/global-code/if-decl-else-decl-b-global-existing-global-init.js: Added.
(262.evalScript.false._f):
(else.f):
* test262/test/annexB/language/global-code/if-decl-else-decl-b-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.false._f):
(else.f):
* test262/test/annexB/language/global-code/if-decl-else-stmt-global-existing-global-init.js: Added.
(262.evalScript.true.f):
* test262/test/annexB/language/global-code/if-decl-else-stmt-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.true.f):
* test262/test/annexB/language/global-code/if-decl-no-else-global-existing-global-init.js: Added.
(262.evalScript.true.f):
* test262/test/annexB/language/global-code/if-decl-no-else-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.true.f):
* test262/test/annexB/language/global-code/if-stmt-else-decl-global-existing-global-init.js: Added.
(else.f):
* test262/test/annexB/language/global-code/if-stmt-else-decl-global-existing-non-enumerable-global-init.js: Added.
(else.f):
* test262/test/annexB/language/global-code/switch-case-global-existing-global-init.js: Added.
(262.evalScript.switch.case.1):
(262.evalScript.switch):
* test262/test/annexB/language/global-code/switch-case-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.switch.case.1):
(262.evalScript.switch):
* test262/test/annexB/language/global-code/switch-dflt-global-existing-global-init.js: Added.
(262.evalScript.switch.default):
(262.evalScript.switch):
* test262/test/annexB/language/global-code/switch-dflt-global-existing-non-enumerable-global-init.js: Added.
(262.evalScript.switch.default):
(262.evalScript.switch):
* test262/test/built-ins/Array/prototype/flat/array-like-objects.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/array-like-objects.js.
* test262/test/built-ins/Array/prototype/flat/bound-function-call.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/bound-function-call.js.
* test262/test/built-ins/Array/prototype/flat/empty-array-elements.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/empty-array-elements.js.
* test262/test/built-ins/Array/prototype/flat/empty-object-elements.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/empty-object-elements.js.
* test262/test/built-ins/Array/prototype/flat/length.js: Added.
* test262/test/built-ins/Array/prototype/flat/name.js: Added.
* test262/test/built-ins/Array/prototype/flat/non-numeric-depth-should-not-throw.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/non-numeric-depth-should-not-throw.js.
* test262/test/built-ins/Array/prototype/flat/non-object-ctor-throws.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/non-object-ctor-throws.js.
* test262/test/built-ins/Array/prototype/flat/null-undefined-elements.js: Added.
* test262/test/built-ins/Array/prototype/flat/null-undefined-input-throws.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/null-undefined-input-throws.js.
* test262/test/built-ins/Array/prototype/flat/positive-infinity.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/positive-infinity.js.
* test262/test/built-ins/Array/prototype/flat/prop-desc.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/prop-desc.js.
* test262/test/built-ins/Array/prototype/flat/symbol-object-create-null-depth-throws.js: Renamed from JSTests/test262/test/built-ins/Array/prototype/flatten/symbol-object-create-null-depth-throws.js.
* test262/test/built-ins/Array/prototype/flatten/length.js: Removed.
* test262/test/built-ins/Array/prototype/flatten/name.js: Removed.
* test262/test/built-ins/Array/prototype/flatten/null-undefined-elements.js: Removed.
* test262/test/built-ins/AsyncGeneratorPrototype/next/name.js:
* test262/test/built-ins/AsyncGeneratorPrototype/return/name.js:
* test262/test/built-ins/AsyncGeneratorPrototype/throw/name.js:
* test262/test/built-ins/Math/acosh/nan-returns.js:
* test262/test/built-ins/Math/asinh/asinh-specialVals.js:
* test262/test/built-ins/Math/atanh/atanh-specialVals.js:
* test262/test/built-ins/Math/cbrt/cbrt-specialValues.js:
* test262/test/built-ins/Math/cbrt/prop-desc.js:
* test262/test/built-ins/Math/cosh/cosh-specialVals.js:
* test262/test/built-ins/Math/expm1/expm1-specialVals.js:
* test262/test/built-ins/Math/log10/Log10-specialVals.js:
* test262/test/built-ins/Math/log2/log2-basicTests.js:
* test262/test/built-ins/Math/sign/sign-specialVals.js:
* test262/test/built-ins/Math/sinh/sinh-specialVals.js:
* test262/test/built-ins/Math/tanh/tanh-specialVals.js:
* test262/test/built-ins/Math/trunc/trunc-sampleTests.js:
* test262/test/built-ins/Math/trunc/trunc-specialVals.js:
* test262/test/built-ins/Object/internals/DefineOwnProperty/consistent-value-regexp-dollar1.js: Added.
* test262/test/built-ins/Object/internals/DefineOwnProperty/consistent-writable-regexp-dollar1.js: Added.
* test262/test/intl402/Intl/getCanonicalLocales/descriptor.js:
* test262/test/intl402/Intl/getCanonicalLocales/duplicates.js:
* test262/test/intl402/Locale/constructor-getter-order.js: Added.
(new.Intl.Locale.toString):
(get language):
(get script):
(get region):
(get calendar):
(get collation):
(get hourCycle):
(get caseFirst):
(get numeric):
(get numberingSystem):
* test262/test/intl402/Locale/constructor-locale-object.js: Added.
* test262/test/intl402/Locale/constructor-non-iana-canon.js: Added.
* test262/test/intl402/Locale/constructor-options-casefirst-invalid.js: Added.
(valueOf):
(const.invalidCaseFirstOption.of.invalidCaseFirstOptions.new.Intl.Locale):
* test262/test/intl402/Locale/constructor-options-casefirst-valid.js: Added.
(toString):
* test262/test/intl402/Locale/constructor-options-collation-invalid.js: Added.
(const.invalidCollationOption.of.invalidCollationOptions.new.Intl.Locale):
* test262/test/intl402/Locale/constructor-options-collation-valid.js: Added.
* test262/test/intl402/Locale/constructor-options-hourcycle-invalid.js: Added.
(const.invalidHourCycleOption.of.invalidHourCycleOptions.new.Intl.Locale):
* test262/test/intl402/Locale/constructor-options-hourcycle-valid.js: Added.
(toString):
* test262/test/intl402/Locale/constructor-options-language-grandfathered.js: Added.
* test262/test/intl402/Locale/constructor-options-language-valid.js:
(toString):
* test262/test/intl402/Locale/constructor-options-numberingsystem-invalid.js: Added.
(const.invalidNumberingSystemOption.of.invalidNumberingSystemOptions.new.Intl.Locale):
* test262/test/intl402/Locale/constructor-options-numberingsystem-valid.js: Added.
* test262/test/intl402/Locale/constructor-options-numeric-valid.js: Added.
(valueOf):
* test262/test/intl402/Locale/constructor-options-region-valid.js:
* test262/test/intl402/Locale/constructor-options-script-valid.js:
(toString):
* test262/test/intl402/Locale/constructor-parse-twice.js: Added.
* test262/test/intl402/Locale/constructor-tag-tostring.js: Added.
(CustomError):
(WrongCustomError):
(const.errors.get Symbol):
(throw.new.CustomError):
(throw.new.CustomError.get toString):
(throw.new.CustomError.get valueOf):
(throw.new.WrongCustomError.get valueOf):
(throw.new.WrongCustomError):
* test262/test/intl402/Locale/constructor-unicode-ext-invalid.js: Added.
* test262/test/intl402/Locale/constructor-unicode-ext-valid.js: Added.
(canonical.of.Object.entries):
* test262/test/intl402/Locale/extensions-grandfathered.js: Added.
(of.testData.value.of.Object.entries):
* test262/test/intl402/Locale/extensions-private.js: Added.
* test262/test/intl402/Locale/getters-grandfathered.js: Added.
* test262/test/intl402/Locale/getters-missing.js: Added.
* test262/test/intl402/Locale/getters-privateuse.js: Added.
* test262/test/intl402/Locale/getters.js: Added.
* test262/test/intl402/Locale/invalid-tag-throws-symbol.js:
* test262/test/intl402/Locale/likely-subtags-grandfathered.js: Added.
* test262/test/intl402/Locale/prop-desc.js:
* test262/test/intl402/Locale/prototype/baseName/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/calendar/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/caseFirst/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/collation/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/constructor/prop-desc.js: Copied from JSTests/test262/test/intl402/Locale/prototype/constructor.js.
* test262/test/intl402/Locale/prototype/hourCycle/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/language/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/maximize/length.js:
* test262/test/intl402/Locale/prototype/maximize/prop-desc.js:
* test262/test/intl402/Locale/prototype/minimize/length.js: Copied from JSTests/test262/test/intl402/Locale/prototype/maximize/length.js.
* test262/test/intl402/Locale/prototype/minimize/name.js: Added.
* test262/test/intl402/Locale/prototype/minimize/prop-desc.js: Copied from JSTests/test262/test/intl402/Locale/prototype/constructor.js.
* test262/test/intl402/Locale/prototype/numberingSystem/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/numeric/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/region/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/script/prop-desc.js: Added.
* test262/test/intl402/Locale/prototype/toString/prop-desc.js: Renamed from JSTests/test262/test/intl402/Locale/prototype/constructor.js.
* test262/test/intl402/Locale/prototype/toStringTag/toStringTag.js: Renamed from JSTests/test262/test/intl402/Locale/prototype/toStringTag.js.
* test262/test/intl402/Number/prototype/toLocaleString/length.js:
* test262/test/intl402/NumberFormat/length.js:
* test262/test/intl402/NumberFormat/name.js:
* test262/test/intl402/NumberFormat/prop-desc.js:
* test262/test/intl402/PluralRules/length.js:
* test262/test/intl402/PluralRules/name.js:
* test262/test/intl402/PluralRules/prop-desc.js: Copied from JSTests/test262/test/intl402/NumberFormat/prop-desc.js.
* test262/test/language/expressions/addition/bigint-and-number.js:
* test262/test/language/expressions/addition/bigint-arithmetic.js:
(testAdd): Deleted.
* test262/test/language/expressions/addition/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/addition/bigint-toprimitive.js:
* test262/test/language/expressions/addition/bigint-wrapped-values.js:
* test262/test/language/expressions/bitwise-and/bigint-and-number.js:
* test262/test/language/expressions/bitwise-and/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/bitwise-and/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.0b011n.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.0b011n.valueOf):
(assert.sameValue.toString):
(assert.sameValue.0b011n.toString):
* test262/test/language/expressions/bitwise-and/bigint-toprimitive.js:
* test262/test/language/expressions/bitwise-and/bigint-wrapped-values.js:
* test262/test/language/expressions/bitwise-not/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.toString):
* test262/test/language/expressions/bitwise-or/bigint-and-number.js:
* test262/test/language/expressions/bitwise-or/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/bitwise-or/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.0b011n.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.0b011n.valueOf):
(assert.sameValue.toString):
(assert.sameValue.0b011n.toString):
* test262/test/language/expressions/bitwise-or/bigint-toprimitive.js:
* test262/test/language/expressions/bitwise-or/bigint-wrapped-values.js:
* test262/test/language/expressions/bitwise-xor/bigint-and-number.js:
* test262/test/language/expressions/bitwise-xor/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/bitwise-xor/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.0b011n.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.0b011n.valueOf):
(assert.sameValue.toString):
(assert.sameValue.0b011n.toString):
* test262/test/language/expressions/bitwise-xor/bigint-toprimitive.js:
* test262/test/language/expressions/bitwise-xor/bigint-wrapped-values.js:
* test262/test/language/expressions/division/bigint-and-number.js:
* test262/test/language/expressions/division/bigint-arithmetic.js:
(testDiv): Deleted.
* test262/test/language/expressions/division/bigint-complex-infinity.js:
* test262/test/language/expressions/division/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/division/bigint-toprimitive.js:
* test262/test/language/expressions/division/bigint-wrapped-values.js:
* test262/test/language/expressions/does-not-equals/bigint-and-bigint.js:
* test262/test/language/expressions/does-not-equals/bigint-and-boolean.js:
* test262/test/language/expressions/does-not-equals/bigint-and-incomparable-primitive.js:
* test262/test/language/expressions/does-not-equals/bigint-and-non-finite.js:
* test262/test/language/expressions/does-not-equals/bigint-and-number-extremes.js:
* test262/test/language/expressions/does-not-equals/bigint-and-number.js:
* test262/test/language/expressions/does-not-equals/bigint-and-object.js:
(assert.sameValue.0n.valueOf):
(assert.sameValue.valueOf):
(assert.sameValue.0n.toString):
(assert.sameValue.toString):
(assert.sameValue.900719925474099101n.valueOf):
(assert.sameValue.900719925474099101n.toString):
* test262/test/language/expressions/does-not-equals/bigint-and-string.js:
* test262/test/language/expressions/equals/bigint-and-bigint.js:
* test262/test/language/expressions/equals/bigint-and-boolean.js:
* test262/test/language/expressions/equals/bigint-and-incomparable-primitive.js:
* test262/test/language/expressions/equals/bigint-and-non-finite.js:
* test262/test/language/expressions/equals/bigint-and-number-extremes.js:
* test262/test/language/expressions/equals/bigint-and-number.js:
* test262/test/language/expressions/equals/bigint-and-object.js:
(assert.sameValue.0n.valueOf):
(assert.sameValue.valueOf):
(assert.sameValue.0n.toString):
(assert.sameValue.toString):
(assert.sameValue.900719925474099101n.valueOf):
(assert.sameValue.900719925474099101n.toString):
* test262/test/language/expressions/equals/bigint-and-string.js:
* test262/test/language/expressions/exponentiation/bigint-and-number.js:
* test262/test/language/expressions/exponentiation/bigint-arithmetic.js:
(testExpt): Deleted.
* test262/test/language/expressions/exponentiation/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/exponentiation/bigint-negative-exponent-throws.js: Renamed from JSTests/test262/test/language/expressions/exponentiation/bigint-exp-operator-negative-throws.js.
* test262/test/language/expressions/exponentiation/bigint-toprimitive.js:
* test262/test/language/expressions/exponentiation/bigint-wrapped-values.js:
* test262/test/language/expressions/exponentiation/bigint-zero-base-zero-exponent.js:
* test262/test/language/expressions/greater-than-or-equal/bigint-and-bigint.js:
* test262/test/language/expressions/greater-than-or-equal/bigint-and-incomparable-string.js:
* test262/test/language/expressions/greater-than-or-equal/bigint-and-non-finite.js:
* test262/test/language/expressions/greater-than-or-equal/bigint-and-number-extremes.js:
* test262/test/language/expressions/greater-than-or-equal/bigint-and-number.js:
* test262/test/language/expressions/greater-than-or-equal/bigint-and-string.js:
* test262/test/language/expressions/greater-than/11.8.2-1.js:
(obj1.valueOf):
(obj2.valueOf):
* test262/test/language/expressions/greater-than/11.8.2-2.js:
(obj1.valueOf):
(obj2.toString):
* test262/test/language/expressions/greater-than/11.8.2-3.js:
(obj1.toString):
(obj2.valueOf):
* test262/test/language/expressions/greater-than/11.8.2-4.js:
(obj1.toString):
(obj2.toString):
* test262/test/language/expressions/greater-than/bigint-and-bigint.js:
* test262/test/language/expressions/greater-than/bigint-and-boolean.js:
* test262/test/language/expressions/greater-than/bigint-and-incomparable-string.js:
* test262/test/language/expressions/greater-than/bigint-and-non-finite.js:
* test262/test/language/expressions/greater-than/bigint-and-number-extremes.js:
* test262/test/language/expressions/greater-than/bigint-and-number.js:
* test262/test/language/expressions/greater-than/bigint-and-string.js:
* test262/test/language/expressions/greater-than/bigint-and-symbol.js: Added.
* test262/test/language/expressions/left-shift/bigint-and-number.js:
* test262/test/language/expressions/left-shift/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/left-shift/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.toString):
(assert.sameValue.0b101n.Symbol.toPrimitive):
(assert.sameValue.0b101n.valueOf):
(assert.sameValue.0b101n.toString):
(valueOf):
* test262/test/language/expressions/left-shift/bigint-toprimitive.js:
* test262/test/language/expressions/left-shift/bigint-wrapped-values.js:
* test262/test/language/expressions/less-than-or-equal/11.8.3-1.js:
(obj1.valueOf):
(obj2.valueOf):
* test262/test/language/expressions/less-than-or-equal/11.8.3-2.js:
(obj1.valueOf):
(obj2.toString):
* test262/test/language/expressions/less-than-or-equal/11.8.3-3.js:
(obj1.toString):
(obj2.valueOf):
* test262/test/language/expressions/less-than-or-equal/11.8.3-4.js:
(obj1.toString):
(obj2.toString):
* test262/test/language/expressions/less-than-or-equal/11.8.3-5.js: Removed.
* test262/test/language/expressions/less-than-or-equal/bigint-and-bigint.js:
* test262/test/language/expressions/less-than-or-equal/bigint-and-incomparable-string.js:
* test262/test/language/expressions/less-than-or-equal/bigint-and-non-finite.js:
* test262/test/language/expressions/less-than-or-equal/bigint-and-number-extremes.js:
* test262/test/language/expressions/less-than-or-equal/bigint-and-number.js:
* test262/test/language/expressions/less-than-or-equal/bigint-and-string.js:
* test262/test/language/expressions/less-than/bigint-and-bigint.js:
* test262/test/language/expressions/less-than/bigint-and-boolean.js:
* test262/test/language/expressions/less-than/bigint-and-incomparable-string.js:
* test262/test/language/expressions/less-than/bigint-and-non-finite.js:
* test262/test/language/expressions/less-than/bigint-and-number-extremes.js:
* test262/test/language/expressions/less-than/bigint-and-number.js:
* test262/test/language/expressions/less-than/bigint-and-string.js:
* test262/test/language/expressions/less-than/bigint-and-symbol.js: Added.
* test262/test/language/expressions/modulus/bigint-and-number.js:
* test262/test/language/expressions/modulus/bigint-arithmetic.js:
(testMod): Deleted.
* test262/test/language/expressions/modulus/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/modulus/bigint-modulo-zero.js:
* test262/test/language/expressions/modulus/bigint-toprimitive.js:
* test262/test/language/expressions/modulus/bigint-wrapped-values.js:
* test262/test/language/expressions/multiplication/bigint-and-number.js:
* test262/test/language/expressions/multiplication/bigint-arithmetic.js:
(testMul): Deleted.
* test262/test/language/expressions/multiplication/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/multiplication/bigint-toprimitive.js:
* test262/test/language/expressions/multiplication/bigint-wrapped-values.js:
* test262/test/language/expressions/right-shift/bigint-and-number.js:
* test262/test/language/expressions/right-shift/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/right-shift/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.toString):
(assert.sameValue.0b101n.Symbol.toPrimitive):
(assert.sameValue.0b101n.valueOf):
(assert.sameValue.0b101n.toString):
(valueOf):
* test262/test/language/expressions/right-shift/bigint-toprimitive.js:
* test262/test/language/expressions/right-shift/bigint-wrapped-values.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-bigint.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-boolean.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-incomparable-primitive.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-non-finite.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-number-extremes.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-number.js:
* test262/test/language/expressions/strict-does-not-equals/bigint-and-object.js:
(assert.sameValue.0n.valueOf):
(assert.sameValue.valueOf):
(assert.sameValue.0n.toString):
(assert.sameValue.toString):
(assert.sameValue.900719925474099101n.valueOf):
(assert.sameValue.900719925474099101n.toString):
* test262/test/language/expressions/strict-does-not-equals/bigint-and-string.js:
* test262/test/language/expressions/strict-equals/bigint-and-bigint.js:
* test262/test/language/expressions/strict-equals/bigint-and-boolean.js:
* test262/test/language/expressions/strict-equals/bigint-and-incomparable-primitive.js:
* test262/test/language/expressions/strict-equals/bigint-and-non-finite.js:
* test262/test/language/expressions/strict-equals/bigint-and-number-extremes.js:
* test262/test/language/expressions/strict-equals/bigint-and-number.js:
* test262/test/language/expressions/strict-equals/bigint-and-object.js:
(assert.sameValue.0n.valueOf):
(assert.sameValue.valueOf):
(assert.sameValue.0n.toString):
(assert.sameValue.toString):
(assert.sameValue.900719925474099101n.valueOf):
(assert.sameValue.900719925474099101n.toString):
* test262/test/language/expressions/strict-equals/bigint-and-string.js:
* test262/test/language/expressions/subtraction/bigint-and-number.js:
* test262/test/language/expressions/subtraction/bigint-arithmetic.js:
(testSub): Deleted.
* test262/test/language/expressions/subtraction/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/subtraction/bigint-toprimitive.js:
* test262/test/language/expressions/subtraction/bigint-wrapped-values.js:
* test262/test/language/expressions/unary-minus/bigint-non-primitive.js:
(assert.sameValue.Symbol.toPrimitive):
(assert.sameValue.valueOf):
(assert.sameValue.toString):
* test262/test/language/expressions/unary-plus/bigint-throws.js:
* test262/test/language/expressions/unsigned-right-shift/bigint-and-number.js:
* test262/test/language/expressions/unsigned-right-shift/bigint-errors.js:
(Symbol.toPrimitive):
(0n.Symbol.toPrimitive):
(valueOf):
(0n.valueOf):
(toString):
(0n.toString):
* test262/test/language/expressions/unsigned-right-shift/bigint-non-primitive.js:
(Symbol.toPrimitive):
(valueOf):
(toString):
(0b101n.Symbol.toPrimitive):
(0b101n.valueOf):
(0b101n.toString):
(valueOf.valueOf):
* test262/test/language/expressions/unsigned-right-shift/bigint-toprimitive.js:
* test262/test/language/expressions/unsigned-right-shift/bigint-wrapped-values.js:
* test262/test/language/literals/numeric/numeric-followed-by-ident.js: Added.
* test262/test/language/literals/string/line-continuation-double.js: Added.
* test262/test/language/literals/string/line-continuation-single.js: Added.
* test262/test262-Revision.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232224
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mmaxfield@apple.com [Sat, 26 May 2018 05:29:31 +0000 (05:29 +0000)]
[Cocoa] Delete unnecessary WebCascadeList in ComplexTextController
https://bugs.webkit.org/show_bug.cgi?id=186007
Reviewed by Zalan Bujtas.
Inside ComplexTextController::collectComplexTextRuns(), we chop up text based on which fonts should be
used to render which grapheme clusters. For each grapheme cluster, we run through the font-family list
in FontCascade::fontForCombiningCharacterSequence() and find the first font that can render the cluster.
If no items can render the cluster, we construct a WebCascadeList and let CoreText try to figure out
which fonts can render which clusters.
Except there's no point, because we just determined that no font in the list can be used to render the
cluster. CoreText isn't magic; it isn't going to somehow disagree with us. WebCascadeList is just
useless code.
No new tests because there is no behavior change.
* platform/graphics/mac/ComplexTextControllerCoreText.mm:
(WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
(-[WebCascadeList initWithFont:character:]): Deleted.
(-[WebCascadeList count]): Deleted.
(-[WebCascadeList objectAtIndex:]): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232223
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
aakash_jain@apple.com [Sat, 26 May 2018 03:56:45 +0000 (03:56 +0000)]
Display detailed error logs when a script fails in EWS
https://bugs.webkit.org/show_bug.cgi?id=175696
<rdar://problem/
34841885>
Reviewed by Darin Adler.
* Scripts/webkitpy/tool/bot/queueengine.py: Set output_limit to 5000 characters instead of default 500 characters.
* Scripts/webkitpy/tool/commands/abstractsequencedcommand.py: Ditto.
* Scripts/webkitpy/tool/commands/download.py: Ditto.
* Scripts/webkitpy/tool/commands/earlywarningsystem.py: Ditto.
* Scripts/webkitpy/tool/commands/queues.py: Ditto.
* Scripts/webkitpy/tool/commands/stepsequence.py: Ditto.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232222
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mmaxfield@apple.com [Sat, 26 May 2018 03:44:49 +0000 (03:44 +0000)]
Improve the performance of Font::canRenderCombiningCharacterSequence()
https://bugs.webkit.org/show_bug.cgi?id=185933
Reviewed by Ryosuke Niwa.
PerformanceTests:
* Layout/ComplexLongUnique.html: Added.
Source/WebCore:
We don't need to create a whole CTLine just to determine whether or not a font supports rendering a grapheme cluster.
Instead, the right way to do it is just see if the font's cmap table supports every code point in the cluster.
This patch reports a 2% progression on the attached PerformanceTest.
Test: Layout/ComplexLongUnique.html
* platform/graphics/Font.cpp:
(WebCore::Font::canRenderCombiningCharacterSequence const):
* platform/graphics/Font.h:
* platform/graphics/cocoa/FontCocoa.mm:
(WebCore::provideStringAndAttributes): Deleted.
(WebCore::Font::canRenderCombiningCharacterSequence const): Deleted.
* platform/graphics/freetype/SimpleFontDataFreeType.cpp:
(WebCore::Font::canRenderCombiningCharacterSequence const): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232221
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
eric.carlson@apple.com [Sat, 26 May 2018 01:02:44 +0000 (01:02 +0000)]
Captions are sized incorrectly in PiP mode
https://bugs.webkit.org/show_bug.cgi?id=186005
<rdar://problem/
39729718>
Reviewed by Dean Jackson.
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlTextTrackContainerElement::updateSizes): Only sync text track bounds
when the size actually changes.
* platform/graphics/avfoundation/objc/VideoFullscreenLayerManagerObjC.mm:
(WebCore::VideoFullscreenLayerManagerObjC::setVideoFullscreenFrame): Call syncTextTrackBounds.
(WebCore::VideoFullscreenLayerManagerObjC::syncTextTrackBounds): Set the text track layer size
to m_videoFullscreenFrame, it is always set the size of the PiP/Fullscreen layer.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232220
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mark.lam@apple.com [Sat, 26 May 2018 00:23:57 +0000 (00:23 +0000)]
for-in loops should preserve and restore the TDZ stack for each of its internal loops.
https://bugs.webkit.org/show_bug.cgi?id=185995
<rdar://problem/
40173142>
Reviewed by Saam Barati.
JSTests:
* stress/regress-185995.js: Added.
Source/JavaScriptCore:
This is because there's no guarantee that any of the loop bodies will be
executed. Hence, there's no guarantee that the TDZ variables will have been
initialized after each loop body.
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::preserveTDZStack):
(JSC::BytecodeGenerator::restoreTDZStack):
* bytecompiler/BytecodeGenerator.h:
* bytecompiler/NodesCodegen.cpp:
(JSC::ForInNode::emitBytecode):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232219
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy@apple.com [Sat, 26 May 2018 00:13:43 +0000 (00:13 +0000)]
Setting drawsBackground to YES on a WKView doesn't take effect immediately
https://bugs.webkit.org/show_bug.cgi?id=185885
rdar://problem/
39706506
Reviewed by Simon Fraser.
Source/WebCore:
* page/Frame.cpp:
(WebCore::Frame::createView): Always call updateBackgroundRecursively, it handles
invalid colors correctly already.
* page/FrameView.cpp:
(WebCore::FrameView::setTransparent): Call setNeedsLayout() since base background color
and transparent is used to update layers.
(WebCore::FrameView::setBaseBackgroundColor): Ditto.
(WebCore::FrameView::updateBackgroundRecursively): Schedule layout if needed.
* page/FrameView.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::viewHasTransparentBackground const): Use baseBackgroundColor
instead of hardcoding white.
(WebCore::RenderLayerCompositor::rootBackgroundTransparencyChanged): Fixed incorrect changed logging.
Source/WebKit:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _initializeWithConfiguration:]): Removed setBackgroundExtendsBeyondPage(true)
since it is now the default.
* UIProcess/Cocoa/WebViewImpl.mm:
(WebKit::WebViewImpl::setDrawsBackground): Make sure updateLayer gets called on the web view
by calling setNeedsDisplay:YES.
(WebKit::WebViewImpl::setBackgroundColor): Ditto.
(WebKit::WebViewImpl::updateLayer): Removed dead code.
* UIProcess/WebPageProxy.h: Make m_backgroundExtendsBeyondPage default to true. WebKit was
always turning this on during WKWebView initializtion, which would cause the scroll
shadow layer to be created, flash black because of no background, then destroyed soon
after once WebKit's message to turn it on got delivered.
* WebProcess/WebPage/WebPage.cpp:
(WebPage::WebPage): Call setBackgroundExtendsBeyondPage earlier to avoid creating the scroll
shadow layer, since backgroundShouldExtendBeyondPage defautls to false in WebCore for WK1.
(WebKit::WebPage::setDrawsBackground): Use updateBackgroundRecursively to propagate the
correct base background color.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232218
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
youenn@apple.com [Sat, 26 May 2018 00:06:08 +0000 (00:06 +0000)]
Migrate From-Origin to Cross-Origin-Resource-Policy
https://bugs.webkit.org/show_bug.cgi?id=185840
Reviewed by Chris Dumez.
Source/WebCore:
Tests: http/wpt/cross-origin-resource-policy/fetch-in-iframe.html
http/wpt/cross-origin-resource-policy/fetch.html
http/wpt/cross-origin-resource-policy/iframe-loads.html
http/wpt/cross-origin-resource-policy/image-loads.html
http/wpt/cross-origin-resource-policy/script-loads.html
* platform/network/HTTPHeaderNames.in:
* platform/network/HTTPParsers.cpp:
(WebCore::parseCrossOriginResourcePolicyHeader):
* platform/network/HTTPParsers.h:
Source/WebKit:
Do Cross-Origin-Resource-Policy (CORP) checks in NetworkLoadChecker instead of NetworkResourceLoader directly.
Make sure CORP only applies to no-cors loads.
Remove ancestor checks and only consider the document origin making the load.
This means that in case of cross-origin redirection to same-origin, the redirection will be CORP-checked,
the final response will not be CORP-checked but will be opaque.
* NetworkProcess/NetworkLoadChecker.cpp:
(WebKit::NetworkLoadChecker::validateCrossOriginResourcePolicyPolicy):
(WebKit::NetworkLoadChecker::validateResponse):
* NetworkProcess/NetworkLoadChecker.h:
* NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::retrieveCacheEntry):
(WebKit::NetworkResourceLoader::didReceiveResponse):
(WebKit::NetworkResourceLoader::continueWillSendRedirectedRequest):
(WebKit::NetworkResourceLoader::didRetrieveCacheEntry):
(WebKit::NetworkResourceLoader::dispatchWillSendRequestForCacheEntry):
* NetworkProcess/NetworkResourceLoader.h:
* WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
Send ancestor information for navigation loads only.
LayoutTests:
Migrating From-Origin tests to Cross-Origin-Resource-Policy tests.
Given the scope of the header is reduced to no-cors and no ancestor checks,
We cover the new header with fetch/image/script loads.
* TestExpectations:
* http/tests/from-origin: Removed.
* http/wpt/cross-origin-resource-policy/fetch-expected.txt: Added.
* http/wpt/cross-origin-resource-policy/fetch-in-iframe-expected.txt: Added.
* http/wpt/cross-origin-resource-policy/fetch-in-iframe.html: Added.
* http/wpt/cross-origin-resource-policy/fetch.html: Added.
* http/wpt/cross-origin-resource-policy/iframe-loads-expected.txt: Added.
* http/wpt/cross-origin-resource-policy/iframe-loads.html: Added.
* http/wpt/cross-origin-resource-policy/image-loads-expected.txt: Added.
* http/wpt/cross-origin-resource-policy/image-loads.html: Added.
* http/wpt/cross-origin-resource-policy/resources/green.png: Added.
* http/wpt/cross-origin-resource-policy/resources/hello.py: Added.
* http/wpt/cross-origin-resource-policy/resources/iframe.py: Added.
* http/wpt/cross-origin-resource-policy/resources/iframeFetch.html: Added.
* http/wpt/cross-origin-resource-policy/resources/image.py: Added.
* http/wpt/cross-origin-resource-policy/resources/redirect.py: Added.
* http/wpt/cross-origin-resource-policy/resources/script.py: Added.
* http/wpt/cross-origin-resource-policy/script-loads-expected.txt: Added.
* http/wpt/cross-origin-resource-policy/script-loads.html: Added.
* platform/wk2/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232217
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
dbates@webkit.org [Fri, 25 May 2018 23:48:11 +0000 (23:48 +0000)]
NavigationAction should not hold a strong reference to a Document
https://bugs.webkit.org/show_bug.cgi?id=185712
<rdar://problem/
40320916>
Reviewed by Brent Fulgham.
Source/WebCore:
Have NavigationAction store all the relevant details callers need to know about the document
that initiated the navigation in an independent data structure, called NavigationAction::Requester,
as opposed to holding a RefPtr to the document itself. The benefit of this approach is that it
is a step towards ensuring that NavigationAction does not keep the document alive after navigating
to a new document given that DocumentLoader stores the NavigationAction for the last navigation.
* loader/NavigationAction.cpp:
(WebCore::NavigationAction::Requester::Requester): Track all relevant details of the document that
requested this navigation that are needed to support WebKit API/SPI. We hold the SecurityOrigin in
a RefPtr to avoid the need to explicitly define a copy constructor and copy-assignment constructor
because Requester needs to be copyable as NavigationAction, which owns a Requester, is copyable.
(WebCore::shouldTreatAsSameOriginNavigation): Fix some style nits.
(WebCore::NavigationAction::NavigationAction): Instantiate a Requester from the specified document.
* loader/NavigationAction.h:
(WebCore::NavigationAction::Requester::url const): Added.
(WebCore::NavigationAction::Requester::securityOrigin const): Added.
(WebCore::NavigationAction::Requester::pageID const): Added.
(WebCore::NavigationAction::Requester::frameID const): Added.
(WebCore::NavigationAction::requester const): Returns details about the document that requested
this navigation, if applicable.
(WebCore::NavigationAction::isEmpty const): Update criterion for being empty to consider the
requester.
(WebCore::NavigationAction::setOpener): Extracted out the datatype of the parameter into a
type alias to avoid duplication and updated this code to use the alias.
(WebCore::NavigationAction::opener const): Ditto.
(WebCore::NavigationAction::sourceDocument const): Deleted.
Source/WebKit:
Update code to make use of NavigationAction::requester().
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232216
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mark.lam@apple.com [Fri, 25 May 2018 23:45:36 +0000 (23:45 +0000)]
MachineContext's instructionPointer() should handle null PCs correctly.
https://bugs.webkit.org/show_bug.cgi?id=186004
<rdar://problem/
40570067>
Reviewed by Saam Barati.
instructionPointer() returns a MacroAssemblerCodePtr<CFunctionPtrTag>. However,
MacroAssemblerCodePtr's constructor does not accept a null pointer value and will
assert accordingly with a debug ASSERT. This is inconsequential for release
builds, but to avoid this assertion failure, we should check for a null PC and
return MacroAssemblerCodePtr<CFunctionPtrTag>(nullptr) instead (which uses the
MacroAssemblerCodePtr(std::nullptr_t) version of the constructor instead).
Alternatively, we can change all of MacroAssemblerCodePtr's constructors to check
for null pointers, but I rather not do that yet. In general,
MacroAssemblerCodePtrs are constructed with non-null pointers, and I prefer to
leave it that way for now.
Note: this assertion failure only manifests when we have signal traps enabled,
and encounter a null pointer deref.
* runtime/MachineContext.h:
(JSC::MachineContext::instructionPointer):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232215
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
dbates@webkit.org [Fri, 25 May 2018 23:41:19 +0000 (23:41 +0000)]
test-webkitpy messages logged using __main__ logger are not displayed
https://bugs.webkit.org/show_bug.cgi?id=185823
Rubber-stamped by Aakash Jain.
Configure the logger for __main__ so that messages that are logged before it parses its
command line arguments are printed to standard error.
Currently test-webkitpy creates a named logger (__main__) for its logging. However it does
not configure a stream to use for printing until after it parses its command line arguments
via webkitpy.test.printer.Printer.configure(). Messages logged until then are never written
to the console. We explicitly configure the __main__ logger instead of calling webkitpy.test.printer.Printer.configure()
earlier because the latter both configures a stream and filters logged messages based on
the specified verbosity. Logged messaged from code in __main__ should not be subject to
such filtering. So, we explicitly configure the __main__ logger.
* Scripts/webkitpy/test/main.py:
(main):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232214
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Fri, 25 May 2018 23:27:02 +0000 (23:27 +0000)]
fast/text/user-installed-fonts/shadow-family.html and fast/text/user-installed-fonts/shadow-postscript-family.html are flaky
https://bugs.webkit.org/show_bug.cgi?id=185994
Unreviewed test gardening.
Patch by David Fenton <david_fenton@apple.com> on 2018-05-25
* platform/mac-wk2/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232213
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
msaboff@apple.com [Fri, 25 May 2018 23:26:42 +0000 (23:26 +0000)]
JavaScriptCore: Disable 32-bit JIT on Windows
https://bugs.webkit.org/show_bug.cgi?id=185989
Reviewed by Saam Barati.
* wtf/Platform.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232212
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mark.lam@apple.com [Fri, 25 May 2018 23:18:15 +0000 (23:18 +0000)]
Enforce invariant that GetterSetter objects are invariant.
https://bugs.webkit.org/show_bug.cgi?id=185968
<rdar://problem/
40541416>
Reviewed by Saam Barati.
The code already assumes the invariant that GetterSetter objects are immutable.
For example, the use of @tryGetById in builtins expect this invariant to be true.
The existing code mostly enforces this except for one case: JSObject's
validateAndApplyPropertyDescriptor, where it will re-use the same GetterSetter
object.
This patch enforces this invariant by removing the setGetter and setSetter methods
of GetterSetter, and requiring the getter/setter callback functions to be
specified at construction time.
* jit/JITOperations.cpp:
* llint/LLIntSlowPaths.cpp:
(JSC::LLInt::LLINT_SLOW_PATH_DECL):
* runtime/GetterSetter.cpp:
(JSC::GetterSetter::withGetter): Deleted.
(JSC::GetterSetter::withSetter): Deleted.
* runtime/GetterSetter.h:
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* runtime/JSObject.cpp:
(JSC::JSObject::putIndexedDescriptor):
(JSC::JSObject::putDirectNativeIntrinsicGetter):
(JSC::putDescriptor):
(JSC::validateAndApplyPropertyDescriptor):
* runtime/JSTypedArrayViewPrototype.cpp:
(JSC::JSTypedArrayViewPrototype::finishCreation):
* runtime/Lookup.cpp:
(JSC::reifyStaticAccessor):
* runtime/PropertyDescriptor.cpp:
(JSC::PropertyDescriptor::slowGetterSetter):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232211
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sbarati@apple.com [Fri, 25 May 2018 22:47:59 +0000 (22:47 +0000)]
Make JSC have a mini mode that kicks in when the JIT is disabled
https://bugs.webkit.org/show_bug.cgi?id=185931
Reviewed by Mark Lam.
Source/JavaScriptCore:
This patch makes JSC have a mini VM mode. This currently only kicks in
when the process can't JIT. Mini VM now means a few things:
- We always use a 1.27x heap growth factor. This number was the best tradeoff
between memory use progression and time regression in run-testmem. We may
want to tune this more in the future as we make other mini VM changes.
- We always sweep synchronously.
- We disable generational GC.
I'm going to continue to extend what mini VM mode means in future changes.
This patch is a 50% memory progression and an ~8-9% time regression
on run-testmem when running in mini VM mode with the JIT disabled.
* heap/Heap.cpp:
(JSC::Heap::collectNow):
(JSC::Heap::finalize):
(JSC::Heap::useGenerationalGC):
(JSC::Heap::shouldSweepSynchronously):
(JSC::Heap::shouldDoFullCollection):
* heap/Heap.h:
* runtime/Options.h:
* runtime/VM.cpp:
(JSC::VM::isInMiniMode):
* runtime/VM.h:
Tools:
This renames a variable for clarity.
* Scripts/run-testmem:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232210
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Fri, 25 May 2018 21:53:17 +0000 (21:53 +0000)]
Ensure that the Web Content process doesn't sleep during initialization
https://bugs.webkit.org/show_bug.cgi?id=185975
<rdar://problem/
40548159>
Reviewed by Geoffrey Garen.
WebProcessPool::warmInitialProcess isn't worth much (or at least, as much
as it could be) if the Web Content process goes to sleep in the middle
of initializeWebProcess.
Keep the Web Content process alive until it has handled all messages
sent from WebProcessPool::initializeNewWebProcess.
This is a significant speedup on some benchmarks I've been running
that involve prewarming a process long before any content is loaded.
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::initializeNewWebProcess):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232209
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Fri, 25 May 2018 21:53:08 +0000 (21:53 +0000)]
Fullscreen element can be clipped by ancestor.
https://bugs.webkit.org/show_bug.cgi?id=185980
rdar://problem/
40320006
Patch by Jeremy Jones <jeremyj@apple.com> on 2018-05-25
Reviewed by Jer Noble.
Adds style to fullscreen css to prevent the fullscreen element from being clipped by an ancestor element.
* css/fullscreen.css:
(:-webkit-full-screen-ancestor:not(iframe)):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232208
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Fri, 25 May 2018 21:49:01 +0000 (21:49 +0000)]
Use correct AVKit delegate for picture in picture failure.
https://bugs.webkit.org/show_bug.cgi?id=185981
rdar://problem/
40549652
Patch by Jeremy Jones <jeremyj@apple.com> on 2018-05-25
Reviewed by Eric Carlson.
No new tests since we don't have a way to simulate picture-in-picture failure.
Use the new name for this delegate callback.
* platform/ios/VideoFullscreenInterfaceAVKit.mm:
(-[WebAVPlayerViewControllerDelegate playerViewController:failedToStartPictureInPictureWithError:]):
(-[WebAVPlayerViewControllerDelegate playerViewControllerFailedToStartPictureInPicture:withError:]): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232207
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Fri, 25 May 2018 21:42:52 +0000 (21:42 +0000)]
iBooks: text can disappear/flash during finger drag highlight
https://bugs.webkit.org/show_bug.cgi?id=185993
<rdar://problem/
34026943>
Reviewed by Simon Fraser.
Reuse existing tiles when override rect is fully covered by the active grid.
Also, recover dropped tiles if override rect forces us to create new ones.
Unable to create a reproducible test case.
* platform/ios/LegacyTileCache.h:
* platform/ios/LegacyTileCache.mm:
(WebCore::LegacyTileCache::setOverrideVisibleRect):
* platform/ios/LegacyTileLayer.mm:
(-[LegacyTileHostLayer renderInContext:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232206
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cdumez@apple.com [Fri, 25 May 2018 21:35:30 +0000 (21:35 +0000)]
WebsiteDataStore::enableResourceLoadStatisticsAndSetTestingCallback() unexpectedly constructs a process pool
https://bugs.webkit.org/show_bug.cgi?id=185992
Reviewed by Geoffrey Garen.
Update enableResourceLoadStatisticsAndSetTestingCallback() to pass the right parameter to processPools()
to avoid constructing a process pool when none exist. Also drop the 'resourceLoadStatisticsEnabled'
flag on the WebProcessPool and have it query its data store instead to know if the feature is enabled.
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::initializeNewWebProcess):
(WebKit::WebProcessPool::setResourceLoadStatisticsEnabled):
* UIProcess/WebProcessPool.h:
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::enableResourceLoadStatisticsAndSetTestingCallback):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232203
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
eric.carlson@apple.com [Fri, 25 May 2018 21:35:13 +0000 (21:35 +0000)]
Encode ISOWebVTTCue "strings" when logging
https://bugs.webkit.org/show_bug.cgi?id=185991
<rdar://problem/
40563902>
Reviewed by Jer Noble.
* platform/graphics/iso/ISOVTTCue.cpp:
(WebCore::ISOWebVTTCue::toJSONString const): Use encodeWithURLEscapeSequences for all Strings
taken from ISO boxes.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232202
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cdumez@apple.com [Fri, 25 May 2018 21:27:19 +0000 (21:27 +0000)]
Drop support for NSURLCache in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=185990
Reviewed by Geoffrey Garen.
Drop support for NSURLCache in WebKit2 now that the WebKit network cache is stable.
Source/WebCore/PAL:
* pal/spi/cf/CFNetworkSPI.h:
Source/WebKit:
* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::setCacheModel):
* NetworkProcess/NetworkProcess.h:
* NetworkProcess/NetworkProcessCreationParameters.cpp:
(WebKit::NetworkProcessCreationParameters::encode const):
(WebKit::NetworkProcessCreationParameters::decode):
* NetworkProcess/NetworkProcessCreationParameters.h:
* NetworkProcess/cocoa/NetworkProcessCocoa.mm:
(WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
(WebKit::NetworkProcess::clearDiskCache):
(WebKit::NetworkProcess::platformSetURLCacheSize): Deleted.
(WebKit::clearNSURLCache): Deleted.
* NetworkProcess/cocoa/NetworkSessionCocoa.h:
* NetworkProcess/cocoa/NetworkSessionCocoa.mm:
(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):
(): Deleted.
(WebKit::NetworkSessionCocoa::setUsesNetworkCache): Deleted.
* NetworkProcess/curl/NetworkProcessCurl.cpp:
(WebKit::NetworkProcess::platformSetURLCacheSize): Deleted.
* NetworkProcess/soup/NetworkProcessSoup.cpp:
(WebKit::NetworkProcess::platformSetURLCacheSize): Deleted.
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::platformInitializeNetworkProcess):
(WebKit::WebProcessPool::legacyPlatformDefaultNetworkCacheDirectory):
(WebKit::WebProcessPool::isNetworkCacheEnabled): Deleted.
* UIProcess/WebProcessPool.h:
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::suggestedFilenameForResourceWithURL const):
(WebKit::WebFrame::mimeTypeForResourceWithURL const):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::getResourceDataFromFrame):
(WebKit::WebPage::hasLocalDataForURL):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/gtk/WebPageGtk.cpp:
(WebKit::WebPage::platformHasLocalDataForURL): Deleted.
(WebKit::WebPage::cachedResponseMIMETypeForURL): Deleted.
(WebKit::WebPage::cachedSuggestedFilenameForURL): Deleted.
(WebKit::WebPage::cachedResponseDataForURL): Deleted.
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::platformHasLocalDataForURL): Deleted.
(WebKit::WebPage::cachedSuggestedFilenameForURL): Deleted.
(WebKit::WebPage::cachedResponseMIMETypeForURL): Deleted.
(WebKit::WebPage::cachedResponseDataForURL): Deleted.
* WebProcess/WebPage/mac/WebPageMac.mm:
(WebKit::WebPage::accessibilityRemoteObject):
(WebKit::WebPage::platformHasLocalDataForURL): Deleted.
(WebKit::cachedResponseForURL): Deleted.
(WebKit::WebPage::cachedSuggestedFilenameForURL): Deleted.
(WebKit::WebPage::cachedResponseMIMETypeForURL): Deleted.
(WebKit::WebPage::cachedResponseDataForURL): Deleted.
* WebProcess/WebPage/win/WebPageWin.cpp:
(WebKit::WebPage::platformHasLocalDataForURL): Deleted.
(WebKit::WebPage::cachedResponseMIMETypeForURL): Deleted.
(WebKit::WebPage::cachedSuggestedFilenameForURL): Deleted.
(WebKit::WebPage::cachedResponseDataForURL): Deleted.
* WebProcess/WebPage/wpe/WebPageWPE.cpp:
(WebKit::WebPage::platformHasLocalDataForURL): Deleted.
(WebKit::WebPage::cachedResponseMIMETypeForURL): Deleted.
(WebKit::WebPage::cachedSuggestedFilenameForURL): Deleted.
(WebKit::WebPage::cachedResponseDataForURL): Deleted.
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::platformInitializeWebProcess):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232201
268f45cc-cd09-0410-ab3c-
d52691b4dbfc