Timeline
Apr 17, 2016:
- 11:52 PM Changeset in webkit [199651] by
-
- 2 edits in trunk/Source/JavaScriptCore
Fix incorrect assumption that APPLE implies Mac.
https://bugs.webkit.org/show_bug.cgi?id=156683
Addresses build failure introduced in r199094
Patch by Jeremy Huddleston Sequoia <jeremyhu@apple.com> on 2016-04-17
Reviewed by Alex Christensen.
- CMakeLists.txt:
- 11:06 PM Changeset in webkit [199650] by
-
- 25 edits9 adds in trunk
Initial Link preload support
https://bugs.webkit.org/show_bug.cgi?id=156334
Source/WebCore:
Added basic
<link rel=preload>functionality that enables preloading
of resources according to their type.
Reviewed by Darin Adler.
Tests: http/tests/preload/download_resources.html
http/tests/preload/dynamic_adding_preload.html
http/tests/preload/dynamic_remove_preload_href.html
http/tests/preload/dynamic_removing_preload.html
- bindings/generic/RuntimeEnabledFeatures.cpp: Added a runtime flag for the feature.
(WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures):
- bindings/generic/RuntimeEnabledFeatures.h: Added a runtime flag for the feature.
(WebCore::RuntimeEnabledFeatures::setLinkPreloadEnabled):
(WebCore::RuntimeEnabledFeatures::linkPreloadEnabled):
- html/HTMLAttributeNames.in: Added an
asattribute. - html/HTMLLinkElement.cpp:
(WebCore::HTMLLinkElement::process): Added
asandcrossoriginattribute values to the loadLink() call.
(WebCore::HTMLLinkElement::setCrossOrigin): Setter for crossOrigin.
(WebCore::HTMLLinkElement::crossOrigin): Getter for crossOrigin.
- html/HTMLLinkElement.idl: Added
asandcrossoriginto HTMLLinkElement. - html/HTMLLinkElement.h: Added getter and setter for crossorigin.
- html/LinkRelAttribute.cpp:
(WebCore::LinkRelAttribute::LinkRelAttribute): Added "preload" as a potential value.
- html/LinkRelAttribute.h: Added isLinkPreload.
- loader/LinkLoader.cpp:
(WebCore::LinkLoader::resourceTypeFromAsAttribute): Translates an
asvalue into a resource type.
(WebCore::preloadIfNeeded): Triggers a resource preload when link element is a preload one.
(WebCore::LinkLoader::loadLink): Added a call to preloadIfNeeded.
- loader/LinkLoader.h: Added signatures.
- loader/ResourceLoadInfo.cpp:
(WebCore::toResourceType): Added LinkPreload as a possible CachedResource::type.
- loader/SubresourceLoader.cpp:
(WebCore::logResourceLoaded): Added LinkPreload as a possible CachedResource::type.
- loader/cache/CachedResource.cpp: Turned defaultPriorityForResourceType into a static member, as it's now also called from LinkLoader.
(WebCore::CachedResource::defaultPriorityForResourceType): Added LinkPreload as a possible CachedResource::type, giving it low priority.
(WebCore::defaultPriorityForResourceType): Deleted.
- loader/cache/CachedResource.h: Added LinkPreload as a possible CachedResource::type. Added defaultPriorityForResourceType as static.
- loader/cache/CachedResourceLoader.cpp:
(WebCore::contentTypeFromResourceType): Added LinkPreload as a possible CachedResource::type.
(WebCore::createResource): Added creation of a LinkPreload resource if needed.
(WebCore::CachedResourceLoader::checkInsecureContent): Added LinkPreload as a possible CachedResource::type.
(WebCore::CachedResourceLoader::canRequest): Added LinkPreload as a possible CachedResource::type.
- testing/Internals.cpp: Added function to turn on the link preload feature.
(WebCore::setLinkPreloadSupport):
- testing/Internals.idl: Added function to turn on the link preload feature.
- testing/Internals.h: Added function signature to turn on the link preload feature.
Source/WebKit2:
Reviewed by Darin Adler.
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::maximumBufferingTime): Added LinkPreload as a possible CachedResource::type.
LayoutTests:
Added tests that make sure that
<link rel=preload>performs its basic
tasks and preloads resources.
Reviewed by Darin Adler.
- http/tests/preload/download_resources-expected.txt: Added.
- http/tests/preload/download_resources.html: Added.
- http/tests/preload/dynamic_adding_preload-expected.txt: Added.
- http/tests/preload/dynamic_adding_preload.html: Added.
- http/tests/preload/dynamic_remove_preload_href-expected.txt: Added.
- http/tests/preload/dynamic_remove_preload_href.html: Added.
- http/tests/preload/dynamic_removing_preload-expected.txt: Added.
- http/tests/preload/dynamic_removing_preload.html: Added.
- imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt: Adjusted expected results to progressions.
- imported/w3c/web-platform-tests/html/dom/reflection-metadata-expected.txt: Adjusted expected results to progressions.
- platform/ios-simulator/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt: Adjusted expected results to progressions.
- 10:36 PM Changeset in webkit [199649] by
-
- 3 edits1 delete in trunk/Tools
[EFL] Bump gstreamer from 1.4.4 to 1.6.3
https://bugs.webkit.org/show_bug.cgi?id=156655
Reviewed by Antonio Gomes.
To support html5 video feature, we should bump gstreamer version.
- efl/jhbuild.modules:
- efl/patches/gst-libav.patch: Update against newer version.
- efl/patches/gst-plugins-bad-remove-gnustep-support.patch: Removed because this patch was merged.
- 10:13 PM Changeset in webkit [199648] by
-
- 3 edits2 adds in trunk/Source/JavaScriptCore
[JSC] ReduceDoubleToFloat should work accross Phis
https://bugs.webkit.org/show_bug.cgi?id=156603
<rdar://problem/25736205>
Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-04-17
Reviewed by Saam Barati and Filip Pizlo.
This patch extends B3's ReduceDoubleToFloat phase to work accross
Upsilon-Phis. This is important to optimize loops and some crazy cases.
In its simplest form, we can have conversion propagated from something
like this:
Double @1 = Phi()
Float @2 = DoubleToFloat(@1)
When that happens, we just need to propagate that the result only
need float precision accross all values coming to this Phi.
There are more complicated cases when the value produced is effectively Float
but the user of the value does not do DoubleToFloat.
Typically, we have something like:
#1
@1 = ConstDouble(1)
@2 = Upsilon(@1, 5)
#2
@3 = FloatToDouble(@x)
@4 = Upsilon(@3, 5)
#3
@5 = Phi()
@6 = Add(@5, @somethingFloat)
@7 = DoubleToFloat(@6)
Here with a Phi-Upsilon that is a Double but can be represented
as Float without loss of precision.
It is valuable to convert such Phis to float if and only if the value
is used as float. Otherwise, you may be just adding useless conversions
(for example, two double constants that flow into a double Add should not
turn into two float constant flowing into a FloatToDouble then Add).
ReduceDoubleToFloat do two analysis passes to gather the necessary
meta information. Then we have a simplify() phase to actually reduce
operation. Finally, the cleanup() pass put the graph into a valid
state again.
The two analysis passes work by disproving that something is float.
-findCandidates() accumulates anything used as Double.
-findPhisContainingFloat() accumulates phis that would lose precision
by converting the input to float.
With this change, Unity3D improves by ~1.5%, box2d-f32 improves
by ~2.8% (on Haswell).
- b3/B3ReduceDoubleToFloat.cpp:
(JSC::B3::reduceDoubleToFloat):
- b3/testb3.cpp:
(JSC::B3::testCompareTwoFloatToDouble):
(JSC::B3::testCompareOneFloatToDouble):
(JSC::B3::testCompareFloatToDoubleThroughPhi):
(JSC::B3::testDoubleToFloatThroughPhi):
(JSC::B3::testDoubleProducerPhiToFloatConversion):
(JSC::B3::testDoubleProducerPhiToFloatConversionWithDoubleConsumer):
(JSC::B3::testDoubleProducerPhiWithNonFloatConst):
(JSC::B3::testStoreDoubleConstantAsFloat):
(JSC::B3::run):
- tests/stress/double-compare-to-float.js: Added.
(canSimplifyToFloat):
(canSimplifyToFloatWithConstant):
(cannotSimplifyA):
(cannotSimplifyB):
- tests/stress/double-to-float.js: Added.
(upsilonReferencingItsPhi):
(upsilonReferencingItsPhiAllFloat):
(upsilonReferencingItsPhiWithoutConversion):
(conversionPropagages):
(chainedUpsilonBothConvert):
(chainedUpsilonFirstConvert):
- 2:53 PM Changeset in webkit [199647] by
-
- 3 edits2 adds in trunk/Source/JavaScriptCore
[ES6] Use @isObject to check Object Type instead of using instanceof
https://bugs.webkit.org/show_bug.cgi?id=156676
Reviewed by Darin Adler.
Use @isObject instead of
instanceof @Object.
Theinstanceofcheck is not enough to check Object Type.
For example, given 2 realms, the object created in one realm does not inherit the Object of another realm.
Another example is that the object which does not inherit Object.
This object can be easily created by callingObject.create(null).
- builtins/RegExpPrototype.js:
(match):
- jsc.cpp:
(GlobalObject::finishCreation):
(functionCreateGlobalObject):
- tests/stress/regexp-match-in-other-realm-should-work.js: Added.
(shouldBe):
- tests/stress/regexp-match-should-work-with-objects-not-inheriting-object-prototype.js: Added.
(shouldBe):
(regexp.exec):
- 12:33 PM Changeset in webkit [199646] by
-
- 2 edits in trunk/Source/WebCore
Try (again) to fix debug builds after r199643.
Unreviewed.
- dom/ScriptExecutionContext.cpp:
Add another missing include.
- 12:28 PM Changeset in webkit [199645] by
-
- 2 edits in trunk/Source/WebCore
Try to fix debug builds after r199643.
Unreviewed.
- Modules/indexeddb/IDBObjectStore.cpp:
Add a missing include.
- 11:58 AM Changeset in webkit [199644] by
-
- 8 edits in trunk/Source
[WK2][iOS] Do not dlopen() QuickLook in the NetworkProcess
https://bugs.webkit.org/show_bug.cgi?id=156639
Reviewed by Darin Adler.
Source/WebCore:
Do not unnecessarily dlopen() QuickLook in the NetworkProcess on iOS, as
we already dlopen() this library in the WebContent process. This patch
moves the resource response MIME type adjusting code for QuickLook from
adjustMIMETypeIfNecessary() to a new adjustMIMETypeForQuickLook() function.
adjustMIMETypeIfNecessary() is called in didReceiveResponse() in the Network
process side, for *every* resource response, even though QuickLook can only
be used to preview main resources. The new adjustMIMETypeForQuickLook()
function is called in the QuickLookHandle::createIfNecessary() factory
function, right before checking the MIME type to determine if we need to
use QuickLook, and after checking that the load is for a main resource.
In the WebKit2 case, the factory function is called from
WebResourceLoader::didReceiveResponse(), on the WebContent process side.
This patch speeds up the first page load during PLT by ~22%, because the
first load no longer triggers a dlopen() to QuickLook in the NetworkProcess.
The overall PLT score seems to be progressed by 0.9-1% as well. The change
should also be memory-positive as we no longer need to dlopen() the
QuickLook library in the NetworkProcess at all (and we would already dlopen()
it on the WebContent process side anyway). Sadly, PLUM benchmark does not
show the memory benefit because it does not measure the memory used by the
Network process.
- platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
(WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveResponse):
Refactor the code a bit for clarity, so that we only
ResourceHandle::setQuickLookHandle() when QuickLookHandle::createIfNecessary()
returns a non-null pointer.
- platform/network/ios/QuickLook.h:
- Rename the factories from create() to createIfNecessary() given that they return nullptr when it is unnecessary to create such handle (i.e. this is not a main resource loader, or it is unecessary given the response's MIME type.
- Make shouldCreateForMIMEType() private now that this is always called inside the factory functions.
- platform/network/ios/QuickLook.mm:
(adjustMIMETypeForQuickLook):
Extracted code for adjusting the MIME type for QuickLook from the generic
adjustMIMETypeIfNecessary() in WebCoreURLResponseIOS.mm to its own function
here.
(WebCore::QuickLookHandle::createIfNecessary):
Call adjustMIMETypeForQuickLook() before checking the MIME type.
- platform/network/ios/WebCoreURLResponseIOS.mm:
(WebCore::adjustMIMETypeIfNecessary):
Extracted QuickLook-specific code to QuickLook.mm.
- platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
(-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
Refactor the code a bit for clarity, so that we only
ResourceHandle::setQuickLookHandle() when QuickLookHandle::createIfNecessary()
returns a non-null pointer.
Source/WebKit2:
- WebProcess/Network/WebResourceLoader.cpp:
(WebKit::WebResourceLoader::didReceiveResponse):
Move checks for main resource load and for MIME type inside of
QuickLookHandle::createIfNecessary(), for consistency with the
other QuickLookHandle factory functions.
- 11:49 AM Changeset in webkit [199643] by
-
- 27 edits in trunk/Source/WebCore
Clean up IDBBindingUtilities.
https://bugs.webkit.org/show_bug.cgi?id=156472
Reviewed by Alex Christensen.
No new tests (No change in behavior).
- Get rid of a whole bunch of unused functions (since we got rid of Legacy IDB).
- Make more functions deal in ExecState/ScriptExecutionContexts instead of DOMRequestState.
- Make more functions deal in JSValue (as JSC::Strong<JSC::Unknown>) instead of Deprecated::ScriptValue.
- bindings/scripts/IDLAttributes.txt: Add a new attribute to signify that an implementation returns JSValues instead of Deprecated::ScriptState
- bindings/scripts/CodeGeneratorJS.pm:
(NativeToJSValue): Use that new attribute.
- Modules/indexeddb/IDBAny.cpp:
(WebCore::IDBAny::IDBAny):
(WebCore::IDBAny::scriptValue):
- Modules/indexeddb/IDBAny.h:
(WebCore::IDBAny::create):
- Modules/indexeddb/IDBCursor.cpp:
(WebCore::IDBCursor::key):
(WebCore::IDBCursor::primaryKey):
(WebCore::IDBCursor::value):
(WebCore::IDBCursor::update):
(WebCore::IDBCursor::continueFunction):
(WebCore::IDBCursor::deleteFunction):
(WebCore::IDBCursor::setGetResult):
- Modules/indexeddb/IDBCursor.h:
- Modules/indexeddb/IDBCursor.idl:
- Modules/indexeddb/IDBCursorWithValue.idl:
- Modules/indexeddb/IDBFactory.cpp:
(WebCore::IDBFactory::cmp):
- Modules/indexeddb/IDBIndex.cpp:
(WebCore::IDBIndex::count):
(WebCore::IDBIndex::get):
(WebCore::IDBIndex::getKey):
- Modules/indexeddb/IDBKeyRange.cpp:
(WebCore::IDBKeyRange::lowerValue):
(WebCore::IDBKeyRange::upperValue):
(WebCore::IDBKeyRange::only):
(WebCore::IDBKeyRange::lowerBound):
(WebCore::IDBKeyRange::upperBound):
(WebCore::IDBKeyRange::bound):
- Modules/indexeddb/IDBKeyRange.h:
- Modules/indexeddb/IDBKeyRange.idl:
- Modules/indexeddb/IDBObjectStore.cpp:
(WebCore::IDBObjectStore::get):
(WebCore::IDBObjectStore::modernDelete):
(WebCore::IDBObjectStore::count):
- Modules/indexeddb/IDBRequest.cpp:
(WebCore::IDBRequest::setResult):
(WebCore::IDBRequest::setResultToStructuredClone):
- Modules/indexeddb/server/MemoryObjectStore.cpp:
(WebCore::IDBServer::MemoryObjectStore::updateIndexesForPutRecord):
(WebCore::IDBServer::MemoryObjectStore::populateIndexWithExistingRecords):
- Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:
(WebCore::IDBServer::SQLiteIDBBackingStore::updateOneIndexForAddRecord):
(WebCore::IDBServer::SQLiteIDBBackingStore::updateAllIndexesForAddRecord):
- Modules/indexeddb/server/UniqueIDBDatabase.cpp:
(WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):
- bindings/js/IDBBindingUtilities.cpp:
(WebCore::idbKeyPathFromValue):
(WebCore::internalCreateIDBKeyFromScriptValueAndKeyPath):
(WebCore::injectIDBKeyIntoScriptValue):
(WebCore::maybeCreateIDBKeyFromScriptValueAndKeyPath):
(WebCore::canInjectIDBKeyIntoScriptValue):
(WebCore::deserializeIDBValueToJSValue):
(WebCore::deserializeIDBValueDataToJSValue):
(WebCore::scriptValueToIDBKey):
(WebCore::idbKeyDataToScriptValue):
(WebCore::idbKeyDataToJSValue): Deleted.
(WebCore::createIDBKeyFromScriptValueAndKeyPath): Deleted.
(WebCore::deserializeIDBValue): Deleted.
(WebCore::deserializeIDBValueData): Deleted.
(WebCore::deserializeIDBValueBuffer): Deleted.
(WebCore::idbValueDataToJSValue): Deleted.
(WebCore::idbKeyToScriptValue): Deleted.
- bindings/js/IDBBindingUtilities.h:
- bindings/js/JSIDBAnyCustom.cpp:
(WebCore::toJS):
- bindings/js/JSIDBDatabaseCustom.cpp:
(WebCore::JSIDBDatabase::createObjectStore):
- bindings/js/JSIDBObjectStoreCustom.cpp:
(WebCore::JSIDBObjectStore::createIndex):
- dom/ScriptExecutionContext.cpp:
(WebCore::ScriptExecutionContext::execState):
- dom/ScriptExecutionContext.h:
- inspector/InspectorIndexedDBAgent.cpp:
- 11:39 AM Changeset in webkit [199642] by
-
- 44 edits in trunk/Source
Remove more uses of Deprecated::ScriptXXX
https://bugs.webkit.org/show_bug.cgi?id=156660
Reviewed by Antti Koivisto.
Source/JavaScriptCore:
- bindings/ScriptFunctionCall.cpp:
(Deprecated::ScriptCallArgumentHandler::appendArgument): Deleted
unneeded overloads that take a ScriptObject and ScriptValue.
- bindings/ScriptFunctionCall.h: Ditto.
- bindings/ScriptObject.h: Added operator so this can change
itself into a JSObject*. Helps while phasing this class out.
- bindings/ScriptValue.h: Export toInspectorValue so it can be
used in WebCore.
- inspector/InjectedScriptManager.cpp:
(Inspector::InjectedScriptManager::createInjectedScript): Changed
return value from Deprecated::ScriptObject to JSObject*.
(Inspector::InjectedScriptManager::injectedScriptFor): Updated for
the return value change above.
- inspector/InjectedScriptManager.h: Ditto.
Source/WebCore:
- Modules/mediacontrols/MediaControlsHost.h: Removed unneeded include.
- Modules/plugins/PluginReplacement.h: Removed unneeded include.
Changed argument to installReplacement into a reference. Changed return
value for creation function from PassRefPtr to Ref.
- Modules/plugins/QuickTimePluginReplacement.h: Removed unneeded includes and
forward declarations. Marked class final. Made almost everything private.
- Modules/plugins/QuickTimePluginReplacement.mm:
(WebCore::QuickTimePluginReplacement::create): Changed to return Ref.
(WebCore::QuickTimePluginReplacement::installReplacement): Changed to take
a reference.
- Modules/plugins/YouTubePluginReplacement.cpp:
(WebCore::YouTubePluginReplacement::create): Changed to return Ref.
(WebCore::YouTubePluginReplacement::installReplacement): Changed to take
a reference.
- Modules/plugins/YouTubePluginReplacement.h: Removed unneeded includes and
forward declarations. Marked class final. Changed return type of create.
- Modules/websockets/WebSocket.cpp:
(WebCore::WebSocket::didReceiveBinaryData): Removed local variable so the
MessageEvent::create function gets a Ref&& instead of a RefPtr without having
to add explicit WTFMove.
- bindings/js/DOMRequestState.h: Removed code that set m_exec twice.
- bindings/js/Dictionary.h: Reformatted function templates to use a single
line so they are easier to look at.
(WebCore::Dictionary::getEventListener): Rewrote this so it no longer uses
a Deprecated::ScriptValue and also make it a little more compact and terse.
- bindings/js/JSCommandLineAPIHostCustom.cpp:
(WebCore::JSCommandLineAPIHost::inspect): Rewrote to use JSValue instead of
Deprecated::ScriptValue. Considerably more efficient.
- bindings/js/JSMessageEventCustom.cpp:
(WebCore::JSMessageEvent::data): Streamlined to use Deprecated::ScriptValue
a little bit less.
- bindings/js/JSNodeCustom.cpp: Moved include here from header.
- bindings/js/JSNodeCustom.h: Moved include from here to cpp file.
- bindings/js/JSPopStateEventCustom.cpp:
(WebCore::JSPopStateEvent::state): Updated for changes to return value of the
state() and serializedState functions.
- bindings/js/ScriptState.h: Removed the ScriptState typedef.
- bindings/js/SerializedScriptValue.cpp: Moved include here from header.
- bindings/js/SerializedScriptValue.h: Moved include from here to cpp file.
- css/FontFace.cpp:
(WebCore::FontFace::create): Changed argument to JSValue instead of ScriptValue.
- css/FontFace.h: Ditto.
- dom/MessageEvent.cpp: Moved create functions in here from header file.
Removed some unused ones including one that took a Deprecated::ScriptValue.
- dom/MessageEvent.h: Streamlined create functions, removing unused functions,
unused arguments, and unused default values for arguments. Also moved them all
into the cpp file instead of inlining them. Also changed the return type of
dataAsScriptValue to JSValue.
- dom/NodeFilterCondition.h: Removed unneeded include. Tweaked formatting.
- dom/PopStateEvent.h: Changed return value of state to be a JSValue and of
serializedState to be a raw pointer, not a PassRefPtr.
- dom/Traversal.h: Removed unneeded include. Removed unnecessary use of
unsigned long instead of unsigned. Fixed indentation.
- html/HTMLPlugInElement.cpp:
(WebCore::HTMLPlugInElement::didAddUserAgentShadowRoot): Pass reference.
- inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::buildObjectForEventListener): Pass JSValue instead
of constructing a Deprecated::ScriptValue.
- inspector/InspectorFrontendHost.cpp:
(WebCore::FrontendMenuProvider::disconnect): Initialize without explicitly
mentioning the Deprecated::ScriptObject type.
- inspector/InspectorIndexedDBAgent.cpp: Removed unneeded include.
- inspector/InspectorInstrumentation.h: Removed unneeded include and also
declaration of two non-existent functions.
- page/DOMWindow.cpp:
(WebCore::PostMessageTimer::PostMessageTimer): Tweaked types a little bit to
match what is used in MessageEvent now.
(WebCore::PostMessageTimer::event): Streamlined a bit and changed type to
reference.
(WebCore::DOMWindow::postMessage): Updated for changes above.
(WebCore::DOMWindow::postMessageTimerFired): Ditto.
- page/EventSource.cpp:
(WebCore::EventSource::createMessageEvent): Removed now-unneeded
"false, false" from MessageEvent::create function call.
- page/csp/ContentSecurityPolicy.h: Removed unneeded include.
- page/csp/ContentSecurityPolicyDirectiveList.h: Removed unneeded
include and also unneeded non-copyable, since the class has a reference as
a data member and so is automatically non-copyable.
- testing/Internals.cpp:
(WebCore::Internals::description): Changed to take JSValue.
(WebCore::Internals::parserMetaData): Ditto.
(WebCore::Internals::serializeObject): Removed unnecessary copying of vector.
(WebCore::Internals::isFromCurrentWorld): Changed to take JSValue.
(WebCore::Internals::isReadableStreamDisturbed): Changed to not rely on the
ScriptState typedef and call it JSC::ExecState.
- testing/Internals.h: Removed unneeded includes. Removed unneeded and
inappropriate use of ASSERT_NO_EXCEPTION.
- 11:04 AM Changeset in webkit [199641] by
-
- 24 edits5 copies18 adds in trunk
LayoutTests/imported/w3c:
[Fetch API] Consume HTTP data as a ReadableStream
https://bugs.webkit.org/show_bug.cgi?id=138968
Reviewed by Alex Christensen.
- web-platform-tests/fetch/api/basic/stream-response-expected.txt:
- web-platform-tests/fetch/api/basic/stream-response-worker-expected.txt:
- web-platform-tests/fetch/api/request/request-consume.html:
- web-platform-tests/fetch/api/resources/data.json: Added.
- web-platform-tests/fetch/api/resources/utils.js:
(validateStreamFromString):
- web-platform-tests/fetch/api/response/response-cancel-stream-expected.txt: Added.
- web-platform-tests/fetch/api/response/response-cancel-stream.html: Added.
- web-platform-tests/fetch/api/response/response-clone-expected.txt:
- web-platform-tests/fetch/api/response/response-consume-stream-expected.txt: Added.
- web-platform-tests/fetch/api/response/response-consume-stream.html: Added.
- web-platform-tests/fetch/api/response/response-init-002-expected.txt:
- web-platform-tests/fetch/api/response/response-stream-disturbed-expected-1.txt: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-1.html: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-expected-2.txt: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-2.html: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-expected-3.txt: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-3.html: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-expected-4.txt: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-4.html: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-expected-5.txt: Added.
- web-platform-tests/fetch/api/response/response-stream-disturbed-5.html: Added.
Source/WebCore:
[Fetch API] Consume HTTP data as a ReadableStream
https://bugs.webkit.org/show_bug.cgi?id=138968
Reviewed by Alex Christensen.
This patch introduces ReadableStreamSource and ReadableStreamController which allow feeding a ReadableStream from DOM classes.
ReadableStreamSource is a base class for all DOM ReadableStream sources.
ReadableStreamController is a wrapper around JSReadableStreamController that can be invoked by DOM code to enqueue/close/error a ReadableStream.
A createReadableStream function is introduced to allow DOM classes creating ReadableStream.
Added support for a FetchResponse ReadableStream source.
Both synthetic FetchResponse and loading FetchResponse are supported.
A new "Stream" FetchLoader::Type is introduced to allow receiving data as chunks and feeding them to a ReadableStream through ReadableStreamSource.
Currently, FetchResponse is consumed and marked as disturbed as soon as a ReadableStreamSource is created.
This should be changed so that consumption happens on the first read call to the ReadableStreamReader, i.e. when stream gets disturbed.
FetchResponseSource never fulfills the start promise, which allows to enqueue, error or close the stream at any time.
FetchResponseSource must therefore always ensure to close or error the stream.
Added support for locked check in FetchResponse.
Tests: imported/w3c/web-platform-tests/fetch/api/response/response-cancel-stream.html
imported/w3c/web-platform-tests/fetch/api/response/response-consume-stream.html
imported/w3c/web-platform-tests/fetch/api/response/response-stream-disturbed-1.html
imported/w3c/web-platform-tests/fetch/api/response/response-stream-disturbed-2.html
imported/w3c/web-platform-tests/fetch/api/response/response-stream-disturbed-3.html
imported/w3c/web-platform-tests/fetch/api/response/response-stream-disturbed-4.html
imported/w3c/web-platform-tests/fetch/api/response/response-stream-disturbed-5.html
Also covered by rebased tests.
- CMakeLists.txt:
- DerivedSources.make:
- Modules/fetch/FetchBody.cpp:
(WebCore::FetchBody::consumeAsStream): Fill stream with body data.
- Modules/fetch/FetchBody.h:
(WebCore::FetchBody::type): Added accessor to body type, used for assertions.
- Modules/fetch/FetchBodyOwner.cpp:
(WebCore::FetchBodyOwner::isDisturbed): Adding stream isLocked check.
(WebCore::FetchBodyOwner::blobLoadingSucceeded): Added assertion that body type is blob. Closing stream if created.
(WebCore::FetchBodyOwner::blobLoadingFailed): Erroring the stream if created and not cancelled.
(WebCore::FetchBodyOwner::blobChunk): Filling stream with chunk.
(WebCore::FetchBodyOwner::stop): Rmoved call to finishBlobLoading as it should be called as part of FetchLoaderCLient::didFail callbacki.
- Modules/fetch/FetchBodyOwner.h:
- Modules/fetch/FetchLoader.cpp: Fixing the case of cancel being called when creating the ThreadableLoader by introducing FetchLoader::m_isStarted.
(WebCore::FetchLoader::start): Setting m_isStarted at the end of the start method.
(WebCore::FetchLoader::stop): Fixing the case that FetchLoader can be destroyed when cancelling its loader.
(WebCore::FetchLoader::startStreaming): Introduced to switch the loading type from ArayBuffer to Stream. Already buffered data is returned.
(WebCore::FetchLoader::didReceiveData): Handling of the new Stream type.
(WebCore::FetchLoader::didFinishLoading):
- Modules/fetch/FetchLoader.h:
- Modules/fetch/FetchLoaderClient.h:
(WebCore::FetchLoaderClient::didReceiveData): Callback to get data as chunks if loader is of type Stream.
- Modules/fetch/FetchResponse.cpp:
(WebCore::FetchResponse::clone): Removed m_isLocked as it is handled within isDisturbed().
(WebCore::FetchResponse::isDisturbed): Checking whether related ReadableStream is locked.
(WebCore::FetchResponse::BodyLoader::didSucceed): Introduced to handle ReadableStream case.
(WebCore::FetchResponse::BodyLoader::didFail): Ditto.
(WebCore::FetchResponse::BodyLoader::didReceiveData): Ditto.
(WebCore::FetchResponse::BodyLoader::startStreaming): Ditto.
(WebCore::FetchResponse::consumeBodyAsStream): Start filling the ReadableStream with data. Changing loader to Stream if there is one.
(WebCore::FetchResponse::createReadableStreamSource): Called by custom binding to create the source.
(WebCore::FetchResponse::stop): Fixing potential crash in case of cancelling the ibody stream.
(WebCore::FetchResponse::startFetching):
(WebCore::FetchResponse::BodyLoader::didFinishLoadingAsArrayBuffer):
- Modules/fetch/FetchResponse.h:
- Modules/fetch/FetchResponse.idl:
- Modules/fetch/FetchResponseSource.cpp: Specialization of ReadableStreamSource for FetchResponse. It is a push source that never resolves the start promise.
(WebCore::FetchResponseSource::FetchResponseSource):
(WebCore::FetchResponseSource::isReadableStreamLocked):
(WebCore::FetchResponseSource::setActive):
(WebCore::FetchResponseSource::setInactive):
(WebCore::FetchResponseSource::doStart):
(WebCore::FetchResponseSource::doCancel):
(WebCore::FetchResponseSource::close):
(WebCore::FetchResponseSource::error):
- Modules/fetch/FetchResponseSource.h: Added.
- Modules/streams/ReadableStreamController.js:
(error):
- Modules/streams/ReadableStreamSource.h: Added (base class for ReadableStream DOM sources).
(WebCore::ReadableStreamSource::~ReadableStreamSource):
(WebCore::ReadableStreamSource::isStarting):
(WebCore::ReadableStreamSource::isPulling):
(WebCore::ReadableStreamSource::isCancelling):
(WebCore::ReadableStreamSource::controller):
(WebCore::ReadableStreamSource::doStart):
(WebCore::ReadableStreamSource::doCancel):
(WebCore::ReadableStreamSource::start):
(WebCore::ReadableStreamSource::cancel):
(WebCore::ReadableStreamSource::startFinished):
(WebCore::ReadableStreamSource::clean):
- Modules/streams/ReadableStreamSource.idl: Added.
- WebCore.xcodeproj/project.pbxproj:
- bindings/js/JSDOMGlobalObject.h:
- bindings/js/JSFetchResponseCustom.cpp: In case body is not created, call createReadableStreamSource.
(WebCore::JSFetchResponse::body):
- bindings/js/JSReadableStreamSourceCustom.cpp: Added.
(WebCore::JSReadableStreamSource::start):
(WebCore::JSReadableStreamSource::pull):
(WebCore::JSReadableStreamSource::controller):
- bindings/js/ReadableStreamController.cpp: Added.
(WebCore::callFunction):
(WebCore::ReadableStreamController::invoke):
(WebCore::ReadableStreamController::isControlledReadableStreamLocked):
(WebCore::createReadableStream):
- bindings/js/ReadableStreamController.h: The DOM wrapper for JSReadableStreamController.
(WebCore::ReadableStreamController::ReadableStreamController):
(WebCore::ReadableStreamController::close):
(WebCore::ReadableStreamController::error):
(WebCore::ReadableStreamController::enqueue):
(WebCore::ReadableStreamController::globalObject):
(WebCore::ReadableStreamController::enqueue<RefPtr<JSC::ArrayBuffer>>):
(WebCore::ReadableStreamController::error<String>):
LayoutTests:
[Streams] Consume HTTP data as a ReadableStream
https://bugs.webkit.org/show_bug.cgi?id=138968
Reviewed by Alex Christensen.
- fast/xmlhttprequest/xmlhttprequest-responsetype-stream-expected.txt: Added.
- fast/xmlhttprequest/xmlhttprequest-responsetype-stream.html: Added.
- http/tests/xmlhttprequest/streams/streams-read-api-cancelled-expected.txt: Added.
- http/tests/xmlhttprequest/streams/streams-read-api-cancelled.html: Added.
- http/tests/xmlhttprequest/streams/streams-read-api-closed-expected.txt: Added.
- http/tests/xmlhttprequest/streams/streams-read-api-closed.html: Added.
- http/tests/xmlhttprequest/streams/streams-read-api-expected.txt: Added.
- http/tests/xmlhttprequest/streams/streams-read-api.html: Added.
- http/tests/xmlhttprequest/streams/streams-read-expected.txt: Added.
- http/tests/xmlhttprequest/streams/streams-read.html: Added.
- 10:56 AM Changeset in webkit [199640] by
-
- 17 edits in trunk/Source/WebCore
Element should be const in StyleResolver
https://bugs.webkit.org/show_bug.cgi?id=156672
Reviewed by Darin Adler.
Resolving element style shouldn't mutate it.
This patch just does Element* -> const Element*, all the groundwork has been done already.
- css/StyleResolver.cpp:
(WebCore::StyleResolver::sweepMatchedPropertiesCache):
(WebCore::StyleResolver::State::State):
(WebCore::StyleResolver::State::setStyle):
(WebCore::isAtShadowBoundary):
(WebCore::StyleResolver::styleForElement):
(WebCore::doesNotInheritTextDecoration):
(WebCore::StyleResolver::adjustStyleForInterCharacterRuby):
(WebCore::StyleResolver::adjustRenderStyle):
(WebCore::StyleResolver::checkRegionStyle):
(WebCore::StyleResolver::updateFont):
(WebCore::StyleResolver::styleRulesForElement):
(WebCore::StyleResolver::pseudoStyleRulesForElement):
(WebCore::StyleResolver::applyMatchedProperties):
- css/StyleResolver.h:
(WebCore::StyleResolver::style):
(WebCore::StyleResolver::parentStyle):
(WebCore::StyleResolver::rootElementStyle):
(WebCore::StyleResolver::element):
(WebCore::StyleResolver::document):
(WebCore::StyleResolver::documentSettings):
(WebCore::StyleResolver::usesFirstLineRules):
(WebCore::StyleResolver::usesFirstLetterRules):
(WebCore::StyleResolver::State::State):
(WebCore::StyleResolver::State::document):
(WebCore::StyleResolver::State::element):
(WebCore::StyleResolver::State::style):
(WebCore::StyleResolver::hasSelectorForId):
(WebCore::checkRegionSelector):
- rendering/RenderTheme.cpp:
(WebCore::RenderTheme::RenderTheme):
(WebCore::RenderTheme::adjustStyle):
(WebCore::RenderTheme::adjustCheckboxStyle):
(WebCore::RenderTheme::adjustRadioStyle):
(WebCore::RenderTheme::adjustButtonStyle):
(WebCore::RenderTheme::adjustInnerSpinButtonStyle):
(WebCore::RenderTheme::adjustTextFieldStyle):
(WebCore::RenderTheme::adjustTextAreaStyle):
(WebCore::RenderTheme::adjustMenuListStyle):
(WebCore::RenderTheme::adjustMeterStyle):
(WebCore::RenderTheme::paintMeter):
(WebCore::RenderTheme::adjustCapsLockIndicatorStyle):
(WebCore::RenderTheme::paintCapsLockIndicator):
(WebCore::RenderTheme::adjustAttachmentStyle):
(WebCore::RenderTheme::animationDurationForProgressBar):
(WebCore::RenderTheme::adjustProgressBarStyle):
(WebCore::RenderTheme::shouldHaveCapsLockIndicator):
(WebCore::RenderTheme::adjustMenuListButtonStyle):
(WebCore::RenderTheme::adjustMediaControlStyle):
(WebCore::RenderTheme::adjustSliderTrackStyle):
(WebCore::RenderTheme::adjustSliderThumbStyle):
(WebCore::RenderTheme::adjustSliderThumbSize):
(WebCore::RenderTheme::adjustSearchFieldStyle):
(WebCore::RenderTheme::adjustSearchFieldCancelButtonStyle):
(WebCore::RenderTheme::adjustSearchFieldDecorationPartStyle):
(WebCore::RenderTheme::adjustSearchFieldResultsDecorationPartStyle):
(WebCore::RenderTheme::adjustSearchFieldResultsButtonStyle):
- rendering/RenderTheme.h:
(WebCore::RenderTheme::minimumMenuListSize):
(WebCore::RenderTheme::popupInternalPaddingBox):
(WebCore::RenderTheme::popupOptionSupportsTextIndent):
(WebCore::RenderTheme::paintRadioDecorations):
(WebCore::RenderTheme::paintButtonDecorations):
(WebCore::RenderTheme::paintTextField):
(WebCore::RenderTheme::paintTextFieldDecorations):
(WebCore::RenderTheme::paintTextArea):
(WebCore::RenderTheme::paintTextAreaDecorations):
(WebCore::RenderTheme::paintMenuList):
(WebCore::RenderTheme::paintMenuListDecorations):
(WebCore::RenderTheme::paintMenuListButtonDecorations):
(WebCore::RenderTheme::paintPushButtonDecorations):
(WebCore::RenderTheme::paintSquareButtonDecorations):
(WebCore::RenderTheme::paintProgressBar):
(WebCore::RenderTheme::paintSliderTrack):
(WebCore::RenderTheme::paintSliderThumb):
(WebCore::RenderTheme::paintSliderThumbDecorations):
(WebCore::RenderTheme::paintSearchField):
(WebCore::RenderTheme::paintSearchFieldDecorations):
(WebCore::RenderTheme::paintSearchFieldCancelButton):
(WebCore::RenderTheme::paintSearchFieldDecorationPart):
(WebCore::RenderTheme::paintSearchFieldResultsDecorationPart):
(WebCore::RenderTheme::paintSearchFieldResultsButton):
(WebCore::RenderTheme::paintMediaFullscreenButton):
(WebCore::RenderTheme::paintMediaPlayButton):
(WebCore::RenderTheme::paintMediaOverlayPlayButton):
- rendering/RenderThemeEfl.cpp:
(WebCore::RenderThemeEfl::paintSliderTrack):
(WebCore::RenderThemeEfl::adjustSliderTrackStyle):
(WebCore::RenderThemeEfl::adjustSliderThumbStyle):
(WebCore::RenderThemeEfl::adjustSliderThumbSize):
(WebCore::RenderThemeEfl::paintSliderThumb):
(WebCore::RenderThemeEfl::adjustCheckboxStyle):
(WebCore::RenderThemeEfl::paintCheckbox):
(WebCore::RenderThemeEfl::adjustRadioStyle):
(WebCore::RenderThemeEfl::paintRadio):
(WebCore::RenderThemeEfl::adjustButtonStyle):
(WebCore::RenderThemeEfl::paintButton):
(WebCore::RenderThemeEfl::adjustMenuListStyle):
(WebCore::RenderThemeEfl::paintMenuList):
(WebCore::RenderThemeEfl::adjustMenuListButtonStyle):
(WebCore::RenderThemeEfl::paintMenuListButtonDecorations):
(WebCore::RenderThemeEfl::adjustTextFieldStyle):
(WebCore::RenderThemeEfl::paintTextField):
(WebCore::RenderThemeEfl::adjustTextAreaStyle):
(WebCore::RenderThemeEfl::paintTextArea):
(WebCore::RenderThemeEfl::adjustSearchFieldResultsButtonStyle):
(WebCore::RenderThemeEfl::paintSearchFieldResultsButton):
(WebCore::RenderThemeEfl::adjustSearchFieldResultsDecorationPartStyle):
(WebCore::RenderThemeEfl::paintSearchFieldResultsDecorationPart):
(WebCore::RenderThemeEfl::adjustSearchFieldCancelButtonStyle):
(WebCore::RenderThemeEfl::paintSearchFieldCancelButton):
(WebCore::RenderThemeEfl::adjustSearchFieldStyle):
(WebCore::RenderThemeEfl::paintSearchField):
(WebCore::RenderThemeEfl::adjustInnerSpinButtonStyle):
(WebCore::RenderThemeEfl::updateCachedSystemFontDescription):
(WebCore::RenderThemeEfl::adjustProgressBarStyle):
- rendering/RenderThemeEfl.h:
- rendering/RenderThemeGtk.cpp:
(WebCore::RenderThemeGtk::adjustRepaintRect):
(WebCore::RenderThemeGtk::adjustButtonStyle):
(WebCore::RenderThemeGtk::paintButton):
(WebCore::RenderThemeGtk::adjustMenuListStyle):
(WebCore::RenderThemeGtk::adjustMenuListButtonStyle):
(WebCore::RenderThemeGtk::paintMenuListButtonDecorations):
(WebCore::RenderThemeGtk::adjustTextFieldStyle):
(WebCore::RenderThemeGtk::paintTextField):
(WebCore::RenderThemeGtk::paintTextArea):
(WebCore::RenderThemeGtk::adjustSearchFieldResultsButtonStyle):
(WebCore::RenderThemeGtk::paintSearchFieldResultsButton):
(WebCore::RenderThemeGtk::adjustSearchFieldResultsDecorationPartStyle):
(WebCore::RenderThemeGtk::adjustSearchFieldCancelButtonStyle):
(WebCore::RenderThemeGtk::paintSearchFieldCancelButton):
(WebCore::RenderThemeGtk::adjustSearchFieldStyle):
(WebCore::RenderThemeGtk::shouldHaveCapsLockIndicator):
(WebCore::RenderThemeGtk::adjustSliderTrackStyle):
(WebCore::RenderThemeGtk::adjustSliderThumbStyle):
(WebCore::RenderThemeGtk::paintSliderTrack):
(WebCore::RenderThemeGtk::adjustSliderThumbSize):
(WebCore::RenderThemeGtk::innerSpinButtonLayout):
(WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
(WebCore::spinButtonArrowSize):
(WebCore::RenderThemeGtk::paintMediaCurrentTime):
(WebCore::RenderThemeGtk::adjustProgressBarStyle):
- rendering/RenderThemeGtk.h:
- rendering/RenderThemeIOS.h:
- rendering/RenderThemeIOS.mm:
(WebCore::RenderThemeIOS::addRoundedBorderClip):
(WebCore::RenderThemeIOS::adjustCheckboxStyle):
(WebCore::RenderThemeIOS::isControlStyled):
(WebCore::RenderThemeIOS::adjustRadioStyle):
(WebCore::adjustInputElementButtonStyle):
(WebCore::RenderThemeIOS::adjustMenuListButtonStyle):
(WebCore::RenderThemeIOS::adjustSliderTrackStyle):
(WebCore::RenderThemeIOS::paintSliderTrack):
(WebCore::RenderThemeIOS::adjustSliderThumbSize):
(WebCore::RenderThemeIOS::sliderTickOffsetFromTrackCenter):
(WebCore::RenderThemeIOS::adjustSearchFieldStyle):
(WebCore::RenderThemeIOS::paintSearchFieldDecorations):
(WebCore::RenderThemeIOS::adjustButtonStyle):
- rendering/RenderThemeMac.h:
- rendering/RenderThemeMac.mm:
(WebCore::RenderThemeMac::paintTextField):
(WebCore::RenderThemeMac::adjustTextFieldStyle):
(WebCore::RenderThemeMac::paintTextArea):
(WebCore::RenderThemeMac::adjustTextAreaStyle):
(WebCore::RenderThemeMac::animationDurationForProgressBar):
(WebCore::RenderThemeMac::adjustProgressBarStyle):
(WebCore::menuListButtonSizes):
(WebCore::RenderThemeMac::adjustMenuListStyle):
(WebCore::RenderThemeMac::popupMenuSize):
(WebCore::RenderThemeMac::adjustMenuListButtonStyle):
(WebCore::RenderThemeMac::adjustSliderTrackStyle):
(WebCore::RenderThemeMac::paintSliderTrack):
(WebCore::RenderThemeMac::adjustSliderThumbStyle):
(WebCore::RenderThemeMac::setSearchFieldSize):
(WebCore::RenderThemeMac::adjustSearchFieldStyle):
(WebCore::RenderThemeMac::cancelButtonSizes):
(WebCore::RenderThemeMac::adjustSearchFieldCancelButtonStyle):
(WebCore::RenderThemeMac::resultsButtonSizes):
(WebCore::RenderThemeMac::adjustSearchFieldDecorationPartStyle):
(WebCore::RenderThemeMac::paintSearchFieldDecorationPart):
(WebCore::RenderThemeMac::adjustSearchFieldResultsDecorationPartStyle):
(WebCore::RenderThemeMac::paintSearchFieldResultsDecorationPart):
(WebCore::RenderThemeMac::adjustSearchFieldResultsButtonStyle):
(WebCore::RenderThemeMac::adjustSliderThumbSize):
- rendering/RenderThemeWin.cpp:
(WebCore::RenderThemeWin::paintButton):
(WebCore::RenderThemeWin::adjustInnerSpinButtonStyle):
(WebCore::RenderThemeWin::paintMenuList):
(WebCore::RenderThemeWin::adjustMenuListStyle):
(WebCore::RenderThemeWin::adjustMenuListButtonStyle):
(WebCore::RenderThemeWin::adjustSliderThumbSize):
(WebCore::RenderThemeWin::paintSearchField):
(WebCore::RenderThemeWin::adjustSearchFieldStyle):
(WebCore::RenderThemeWin::paintSearchFieldCancelButton):
(WebCore::RenderThemeWin::adjustSearchFieldCancelButtonStyle):
(WebCore::RenderThemeWin::adjustSearchFieldDecorationPartStyle):
(WebCore::RenderThemeWin::adjustSearchFieldResultsDecorationPartStyle):
(WebCore::RenderThemeWin::paintSearchFieldResultsDecorationPart):
(WebCore::RenderThemeWin::adjustSearchFieldResultsButtonStyle):
(WebCore::RenderThemeWin::adjustMeterStyle):
- rendering/RenderThemeWin.h:
Apr 16, 2016:
- 9:55 PM Changeset in webkit [199639] by
-
- 3 edits1 add in trunk/Source/JavaScriptCore
[JSC] DFG should support relational comparisons of Number and Other
https://bugs.webkit.org/show_bug.cgi?id=156669
Patch by Benjamin Poulain <bpoulain@webkit.org> on 2016-04-16
Reviewed by Darin Adler.
In Sunspider/3d-raytrace, DFG falls back to JSValue in some important
relational compare because profiling sees "undefined" from time to time.
This case is fairly common outside Sunspider too because of out-of-bounds array access.
Unfortunately for us, our fallback for compare is really inefficient.
Fortunately, relational comparison with null/undefined/true/false are trival.
We can just convert both side to Double. That's what this patch adds.
I also extended constant folding for those cases because I noticed
a bunch of "undefined" constant going through DoubleRep at runtime.
- dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
- dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
- tests/stress/compare-number-and-other.js: Added.
(opaqueSideEffect):
(let.operator.of.operators.eval.testPolymorphic):
(let.operator.of.operators.let.left.of.typeCases.let.right.of.typeCases.eval.testMonomorphic):
(let.operator.of.operators.let.left.of.typeCases.let.right.of.typeCases.testMonomorphicLeftConstant):
(let.operator.of.operators.let.left.of.typeCases.let.right.of.typeCases.testMonomorphicRightConstant):
(let.operator.of.operators.let.left.of.typeCases.let.right.of.typeCases.i.testPolymorphic):
- 8:44 PM Changeset in webkit [199638] by
-
- 2 edits in trunk/Source/JavaScriptCore
[JSC] FRound/Negate can produce an impure NaN out of a pure NaN
https://bugs.webkit.org/show_bug.cgi?id=156528
Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-04-16
Reviewed by Filip Pizlo.
If you fround a double with the bits 0xfff7000000000000
you get 0xfffe000000000000. The first is a pure NaN, the second isn't.
This is without test because I could not find a way to create a 0xfff7000000000000
while convincing DFG that its pure.
When we purify NaNs from typed array, we use a specific value of NaN if the input
is any NaN, making testing tricky.
- bytecode/SpeculatedType.cpp:
(JSC::typeOfDoubleNegation):
- 7:39 PM Changeset in webkit [199637] by
-
- 11 edits in trunk/Source/WebCore/platform/gtk/po
Localization files with empty Language: block build with gettext 0.19
https://bugs.webkit.org/show_bug.cgi?id=133611
Reviewed by Darin Adler.
Fix the language tags. Note that the build error is not actually important here as it only
occurs with an older version of gettext, but presumably it's bad for the language tags to be
wrong.
- as.po:
- en_CA.po:
- gu.po: Also correct the translation team to Gujarati.
- hu.po:
- id.po:
- ko.po:
- lv.po:
- pa.po:
- ru.po:
- sl.po:
- 6:29 PM Changeset in webkit [199636] by
-
- 2 edits in trunk/Source/JavaScriptCore
JS::DFG::nodeValuePairListDump does not compile with libstdc++ 4.8
https://bugs.webkit.org/show_bug.cgi?id=156670
Patch by Konstantin Tokarev <Konstantin Tokarev> on 2016-04-16
Reviewed by Darin Adler.
- dfg/DFGNode.h:
(JSC::DFG::nodeValuePairListDump): Modified to use lambda as comparator.
- 6:26 PM Changeset in webkit [199635] by
-
- 10 edits2 adds in trunk
Web Inspector: Adopt Number.prototype.toLocaleString For All Sizes and Times
https://bugs.webkit.org/show_bug.cgi?id=152033
<rdar://problem/23815589>
Reviewed by Timothy Hatcher.
Source/WebInspectorUI:
Update string formatters to localize float and percentage strings. Hook up
console message formatters to use String.standardFormatters so that console
statements (e.g. console.log("%.3f", 3.14159)) are properly formatted.
- Localizations/en.lproj/localizedStrings.js:
- UserInterface/Base/Utilities.js:
(value):
tokenizeFormatString should default to 6 digits when no precision
sub-specifier is provided.
percentageString should localize formatting, and take a fraction value
(0 to 1) instead of a percentage.
secondsToString should perform special-case formatting for zero values
("0ms") instead of the general purpose float formatter.
(value.d):
Switch to parseInt to floor floating point values and support numeric strings.
Return NaN instead of zero when passed a value that can't be converted to integer.
(value.f):
Switch to parseFloat to support numeric strings, and localize formatting.
Remove precision check, as it will never be less than zero. Return NaN
instead of zero when passed a value that can't be converted to float.
(prettyFunctionName):
Convert substitutions (an arguments object) to an array before calling join.
- UserInterface/Views/ConsoleMessageView.js:
(WebInspector.ConsoleMessageView.prototype._formatWithSubstitutionString.floatFormatter):
Use String.standardFormatters.f.
(WebInspector.ConsoleMessageView.prototype._formatWithSubstitutionString.integerFormatter):
Use String.standardFormatters.d.
- UserInterface/Views/LayoutTimelineDataGridNode.js:
(WebInspector.LayoutTimelineDataGridNode.prototype.createCellContent):
(WebInspector.LayoutTimelineDataGridNode):
Use integer formatting for pixel values.
- UserInterface/Views/ProfileDataGridNode.js:
(WebInspector.ProfileDataGridNode.prototype._recalculateData):
(WebInspector.ProfileDataGridNode.prototype._totalTimeContent):
Treat percentage as a fraction from 0 to 1.
- UserInterface/Views/ResourceDetailsSidebarPanel.js:
(WebInspector.ResourceDetailsSidebarPanel.prototype._refreshImageSizeSection):
Use integer formatting for pixel values.
LayoutTests:
Add test coverage for string formatters, and additional test cases for
Number.percentageString and Number.secondsToString.
- inspector/unit-tests/number-utilities-expected.txt:
- inspector/unit-tests/number-utilities.html:
- inspector/unit-tests/string-utilities-expected.txt: Added.
- inspector/unit-tests/string-utilities.html: Added.
- 6:20 PM Changeset in webkit [199634] by
-
- 8 edits in trunk/Source/WebInspectorUI
display:inline on the tbody is causing the width of the iframe to be shrunk to the minimum size of its text.
https://bugs.webkit.org/show_bug.cgi?id=15666
Reviewed by Timothy Hatcher.
Fix a regression caused by the recent Timelines UI redesign, and
reorder TimelineDataGrid's constructor arguments now that most
timeline views no longer have an associated tree outline.
- UserInterface/Views/HeapAllocationsTimelineView.js:
(WebInspector.HeapAllocationsTimelineView):
- UserInterface/Views/LayoutTimelineView.js:
(WebInspector.LayoutTimelineView):
- UserInterface/Views/NetworkGridContentView.js:
(WebInspector.NetworkGridContentView):
- UserInterface/Views/NetworkTimelineView.js:
(WebInspector.NetworkTimelineView):
- UserInterface/Views/RenderingFrameTimelineView.js:
(WebInspector.RenderingFrameTimelineView):
- UserInterface/Views/ScriptDetailsTimelineView.js:
(WebInspector.ScriptDetailsTimelineView):
Reorder constructor parameters and omit optional treeOutline and
synchronizerDelegate arguments when they aren't needed.
- UserInterface/Views/TimelineDataGrid.js:
(WebInspector.TimelineDataGrid):
Reorder constructor arguments so that treeOutline can be optional.
(WebInspector.TimelineDataGrid.prototype._refreshDirtyDataGridNodes):
Nodes should be refreshed and re-inserted in the data grid without
requiring a grid synchronizer. If a synchronizer exists, re-insert
the tree element for the node. Since the syncronizer is disabled the
order of grid/tree operations doesn't matter.
- 5:40 PM Changeset in webkit [199633] by
-
- 2 edits in trunk/Tools
More build fixing.
- MiniBrowser/mac/BrowserWindowController.m:
(-[BrowserWindowController share:]):
- 5:26 PM Changeset in webkit [199632] by
-
- 2 edits in trunk/Tools
Another build fix.
- MiniBrowser/mac/BrowserWindowController.m:
(-[BrowserWindowController sharingServicePicker:sharingServicesForItems:proposedSharingServices:]):
- 5:19 PM Changeset in webkit [199631] by
-
- 2 edits in trunk/Tools
Fix 32-bit build.
- MiniBrowser/mac/BrowserWindowController.m:
(-[BrowserWindowController share:]):
(-[BrowserWindowController fetch:]):
(-[BrowserWindowController sharingService:transitionImageForShareItem:contentRect:]):
- 5:10 PM Changeset in webkit [199630] by
-
- 6 edits in trunk/Tools
Add support for NSSharingService to MiniBrowser, for no great reasons
https://bugs.webkit.org/show_bug.cgi?id=156658
Reviewed by Darin Adler.
- MiniBrowser/mac/BrowserWindow.xib:
- MiniBrowser/mac/BrowserWindowController.h:
Add the share button.
- MiniBrowser/mac/BrowserWindowController.m:
(-[BrowserWindowController windowDidLoad]):
Set the share button to fire it's actions on mouse down, as it is supposed to act like a menu.
(-[BrowserWindowController share:]):
Show the picker when the button is pressed.
(-[BrowserWindowController mainContentView]):
Add a new override to get the main content view of derived classes (either a WKWebView or the WebView).
(-[BrowserWindowController sharingServicePicker:sharingServicesForItems:proposedSharingServices:]):
(-[BrowserWindowController sharingServicePicker:delegateForSharingService:]):
(-[BrowserWindowController sharingServicePicker:didChooseSharingService:]):
(-[BrowserWindowController sharingService:sourceFrameOnScreenForShareItem:]):
(-[BrowserWindowController sharingService:transitionImageForShareItem:contentRect:]):
(-[BrowserWindowController sharingService:sourceWindowForShareItems:sharingContentScope:]):
Add delegate methods.
- MiniBrowser/mac/WK1BrowserWindowController.m:
(-[WK1BrowserWindowController mainContentView]):
- MiniBrowser/mac/WK2BrowserWindowController.m:
(-[WK2BrowserWindowController mainContentView]):
Implement to return the web view.
- 3:52 PM Changeset in webkit [199629] by
-
- 2 edits in trunk/Source/WebCore/platform/gtk/po
[GTK] [l10n] Updated Turkish translation of WebKitGTK+
https://bugs.webkit.org/show_bug.cgi?id=156667
Patch by Muhammet Kara <muhammetk@gmail.com> on 2016-04-16
Rubber-stamped by Michael Catanzaro.
- tr.po:
- 2:37 PM Changeset in webkit [199628] by
-
- 2 edits in trunk/Source/WebKit2
[Mac] Web Content service with a restricted entitlement may load arbitrary dylibs
https://bugs.webkit.org/show_bug.cgi?id=156668
<rdar://problem/25429784>
Reviewed by Anders Carlsson.
- Configurations/WebContentService.xcconfig: Enable library validation when the Web Content service is given the XPC domain extension entitlement.
- 11:16 AM Changeset in webkit [199627] by
-
- 2 edits in trunk/Tools
Build fix.
Temporary workaround for rdar://problem/25754945.
- LayoutTestRelay/LayoutTestRelay/CoreSimulatorSPI.h:
- 10:59 AM Changeset in webkit [199626] by
-
- 2 edits in trunk/Source/JavaScriptCore
[mips] Implemented moveZeroToDouble.
https://bugs.webkit.org/show_bug.cgi?id=155429
Patch by Konstantin Tokarev <Konstantin Tokarev> on 2016-04-16
Reviewed by Darin Adler.
This function is required to fix compilation after r197687.
- assembler/MacroAssemblerMIPS.h:
(JSC::MacroAssemblerMIPS::moveZeroToDouble):
- 10:53 AM Changeset in webkit [199625] by
-
- 11 edits in trunk/Source/WebCore
CSSCursorImageValue shouldn't mutate element during style resolution
https://bugs.webkit.org/show_bug.cgi?id=156659
Reviewed by Darin Adler.
CSSCursorImageValue::updateIfSVGCursorIsUsed may mutate the argument element.
This patch removes the code that caches cursor element and image to SVGElement rare data.
The whole things is basically unused. CSSCursorImageValue now maintains a weak map to
SVGCursorElements directly instead of indirectly via the using SVGElements.
- css/CSSCursorImageValue.cpp:
(WebCore::CSSCursorImageValue::CSSCursorImageValue):
(WebCore::CSSCursorImageValue::~CSSCursorImageValue):
(WebCore::CSSCursorImageValue::customCSSText):
(WebCore::CSSCursorImageValue::updateCursorElement):
We no longer rely on SVGElement rare data so no need to test for SVGElement.
(WebCore::CSSCursorImageValue::cursorElementRemoved):
(WebCore::CSSCursorImageValue::cursorElementChanged):
Factor to a function.
(WebCore::CSSCursorImageValue::cachedImage):
(WebCore::CSSCursorImageValue::clearCachedImage):
(WebCore::CSSCursorImageValue::equals):
(WebCore::CSSCursorImageValue::removeReferencedElement): Deleted.
Don't track client elements anymore. Just track referenced SVGCursorElements.
- css/CSSCursorImageValue.h:
- css/StyleBuilderCustom.h:
(WebCore::StyleBuilderCustom::applyValueCursor):
No need to make style unique. Initialization is now done in updateSVGCursorElement.
- svg/SVGCursorElement.cpp:
(WebCore::SVGCursorElement::~SVGCursorElement):
(WebCore::SVGCursorElement::isSupportedAttribute):
(WebCore::SVGCursorElement::parseAttribute):
(WebCore::SVGCursorElement::addClient):
(WebCore::SVGCursorElement::removeClient):
Client is now an CSSCursorImageValue rather than SVGElement.
(WebCore::SVGCursorElement::svgAttributeChanged):
Instead of invalidating element style just invalidate the CSSCursorImageValue directly.
(WebCore::SVGCursorElement::addSubresourceAttributeURLs):
(WebCore::SVGCursorElement::removeReferencedElement): Deleted.
- svg/SVGCursorElement.h:
- svg/SVGElement.cpp:
(WebCore::SVGElement::~SVGElement):
(WebCore::SVGElement::getBoundingBox):
(WebCore::SVGElement::correspondingElement):
(WebCore::SVGElement::setCursorElement): Deleted.
(WebCore::SVGElement::cursorElementRemoved): Deleted.
(WebCore::SVGElement::setCursorImageValue): Deleted.
(WebCore::SVGElement::cursorImageValueRemoved): Deleted.
SVGElements no longer need to know about their cursors.
- svg/SVGElement.h:
- svg/SVGElementRareData.h:
(WebCore::SVGElementRareData::instanceUpdatesBlocked):
(WebCore::SVGElementRareData::setInstanceUpdatesBlocked):
(WebCore::SVGElementRareData::correspondingElement):
(WebCore::SVGElementRareData::setCorrespondingElement):
(WebCore::SVGElementRareData::animatedSMILStyleProperties):
(WebCore::SVGElementRareData::ensureAnimatedSMILStyleProperties):
(WebCore::SVGElementRareData::cursorElement): Deleted.
(WebCore::SVGElementRareData::setCursorElement): Deleted.
(WebCore::SVGElementRareData::cursorImageValue): Deleted.
(WebCore::SVGElementRareData::setCursorImageValue): Deleted.
- 9:08 AM Changeset in webkit [199624] by
-
- 1 edit1 add in trunk/Source/WebCore/platform/gtk/po
Submit the first version of Finnish translation
https://bugs.webkit.org/show_bug.cgi?id=153406
Patch by Jiri Grönroos <jiri.gronroos+l10n@iki.fi> on 2016-04-16
Rubber-stamped by Michael Catanzaro. For FINLAN.
- fi.po: Added. Note it's pretty incomplete as of yet.
- 8:54 AM Changeset in webkit [199623] by
-
- 2 edits in trunk/Source/WebCore/platform/gtk/po
[GTK] [l10n] Updated Bulgarian translation of WebKitGTK+
https://bugs.webkit.org/show_bug.cgi?id=156656
Patch by Zahari Yurukov <zahari.yurukov@gmail.com> on 2016-04-16
Rubber-stamped by Michael Catanzaro.
- bg.po: