Dec 31, 2017:

1:25 AM Changeset in webkit [226314] by jiewen_tan@apple.com
  • 3 edits in trunk/Source/WebCore

[WebCrypto] Avoid promises being destroyed in secondary threads

Reviewed by Youenn Fablet.

This patch adds pending promise queue to SubtleCrypto such that it no longer
passes promises around different threads, which could cause crashes when
promises are destroyed in secondary threads.

Covered by existing tests.

  • crypto/SubtleCrypto.cpp:


  • crypto/SubtleCrypto.h:

Dec 30, 2017:

8:38 PM Changeset in webkit [226313] by mitz@apple.com
  • 2 edits in trunk/Source/WebCore

REGRESSION (r225494): Mouse pointer reappears shortly after hiding when scrolling using arrow keys

Reviewed by Alexey Proskuryakov.

  • page/EventHandler.cpp:

(WebCore::EventHandler::cancelAutoHideCursorTimer): Removed a call to unhide the cursor


11:30 AM Changeset in webkit [226312] by Wenson Hsieh
  • 25 edits in trunk/Source

[Attachment Support] Remove current macOS support for dragging file-backed attachments

Reviewed by Dan Bernstein.


Support for dragging attachments out as files on the NSPasteboard was introduced in r181760. However, this is
(1) a macOS-specific implementation, and (2) does not support attachments whose files are backed by inline data
rather than a filepath. As part of adding further WebKit attachment element support, subsequent patches will
reimplement support for dragging attachment elements in a cross-Cocoa-platform way that also allows for either
data- or file-backed blobs to be written to the pasteboard.

No new functionality; no new tests. All existing layout and API tests still pass.

  • page/DragClient.h:

(WebCore::DragClient::declareAndWriteAttachment): Deleted.

  • page/DragController.cpp:


  • page/DragController.h:

(WebCore::DragController::draggingImageURL const):
(WebCore::DragController::draggingAttachmentURL const): Deleted.

  • page/gtk/DragControllerGtk.cpp:

(WebCore::DragController::declareAndWriteAttachment): Deleted.

  • page/mac/DragControllerMac.mm:

(WebCore::DragController::declareAndWriteAttachment): Deleted.

  • page/win/DragControllerWin.cpp:

(WebCore::DragController::declareAndWriteAttachment): Deleted.

  • rendering/HitTestResult.cpp:

(WebCore::HitTestResult::absoluteAttachmentURL const): Deleted.

  • rendering/HitTestResult.h:


See WebCore/ChangeLog for more detail.

  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::WebPageProxy::setPromisedDataForAttachment): Deleted.

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

(WebKit::WebViewImpl::setPromisedDataForAttachment): Deleted.

  • UIProcess/PageClient.h:
  • UIProcess/WebPageProxy.h:
  • UIProcess/WebPageProxy.messages.in:
  • UIProcess/mac/PageClientImplMac.h:
  • UIProcess/mac/PageClientImplMac.mm:

(WebKit::PageClientImpl::setPromisedDataForAttachment): Deleted.

  • UIProcess/mac/WebPageProxyMac.mm:

(WebKit::WebPageProxy::setPromisedDataForAttachment): Deleted.

  • WebProcess/WebCoreSupport/WebDragClient.h:
  • WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:

(WebKit::WebDragClient::declareAndWriteAttachment): Deleted.


See WebCore/ChangeLog for more detail.

  • WebCoreSupport/WebDragClient.h:
  • WebCoreSupport/WebDragClient.mm:

(WebDragClient::declareAndWriteAttachment): Deleted.

  • WebView/WebHTMLView.mm:

(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):

11:05 AM Changeset in webkit [226311] by Yusuke Suzuki
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Remove unused JSTypes

Reviewed by Saam Barati.

JSType includes some unused types such as NullType. They are for
primitive values in old days. But now JSType is only used for JSCells.

  • runtime/JSType.h:
  • runtime/TypedArrayType.cpp:


Dec 28, 2017:

11:52 PM Changeset in webkit [226310] by sbarati@apple.com
  • 14 edits in trunk/Source/JavaScriptCore

Remove op_assert and make @assert in builtins a function call so we have DFG/FTL coverage for builtins that use @assert in debug builds

Reviewed by Yusuke Suzuki.

Previously, op_assert was only implemented in the LLInt and baseline JIT. This
meant that any builtin that used @assert was not tiering up to the DFG/FTL
in debug builds. This patch changes @assert to just call a host function when
!ASSERT_DISABLED. It's a no-op when ASSERT_DISABLED. Now, builtins that use @assert
will tier up to the DFG/FTL on debug builds.

  • builtins/BuiltinNames.h:
  • bytecode/BytecodeDumper.cpp:


  • bytecode/BytecodeIntrinsicRegistry.h:
  • bytecode/BytecodeList.json:
  • bytecode/BytecodeUseDef.h:


  • bytecompiler/BytecodeGenerator.cpp:

(JSC::BytecodeGenerator::emitAssert): Deleted.

  • bytecompiler/BytecodeGenerator.h:
  • bytecompiler/NodesCodegen.cpp:

(JSC::BytecodeIntrinsicNode::emit_intrinsic_assert): Deleted.

  • jit/JIT.cpp:


  • llint/LowLevelInterpreter.asm:
  • runtime/CommonSlowPaths.cpp:
  • runtime/CommonSlowPaths.h:
  • runtime/JSGlobalObject.cpp:


10:18 PM Changeset in webkit [226309] by Alan Bujtas
  • 4 edits
    2 adds in trunk

RenderTreeUpdater::GeneratedContent should hold a weak reference to RenderQuote.

Reviewed by David Kilzer.


Test: fast/css/content/content-quotes-crash-with-details.html

  • rendering/updating/RenderTreeUpdaterGeneratedContent.cpp:


  • rendering/updating/RenderTreeUpdaterGeneratedContent.h:

(): Deleted.


  • fast/css/content/content-quotes-crash-with-details-expected.txt: Added.
  • fast/css/content/content-quotes-crash-with-details.html: Added.
9:56 PM Changeset in webkit [226308] by beidson@apple.com
  • 12 edits
    2 adds in trunk/Source

Add a ProcessIdentifier, vended from the UI process, to each child process

Reviewed by Brent Fulgham.


No new tests (Not yet testable)

More than once we've needed to create an identifier for an object that is unique across
all processes no matter which process it came from.

Sometimes we have an object or proxy object to the UI, Storage, or Network process
that allows us to augment a process-unique identifier to be globally unique. Due to multiple
sessions even this isn't good enough. Other times we have to create more hair-brained solutions.

In upcoming MessagePort work (Next step is https://bugs.webkit.org/show_bug.cgi?id=181172)
there was no truly workable solution for this.

By introducing a new ProcessIdentifier to each WK2 child processes that is guaranteed to be
unique over the run of a given UI process, we can easily create an object in any process and
identify it uniquely across all processes.

Obviously "process identifier" brings to mind a processes PID but that isn't good enough.
The number of PIDs on the system is fairly low and they are global across all
processes on the system. It is easy to see how a given UI process that runs for long enough
(such as a web browser that the user rarely quits) will start to run in to recycled PIDs,
therefore breaking the uniqueness guarantee that is required.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/Process.cpp: Added.

(WebCore::Process::setIdentifier): Sets the process-wise identifier (to be used during WK2

child process initialization)

(WebCore::Process::identifier): Get the process-wide identifier.

  • platform/Process.h: Added.


  • Shared/ChildProcess.cpp:

(WebKit::ChildProcess::initialize): Set the process-wide identifier if the initialization

parameters have it. Cocoa ASSERTS it exists; non-Cocoa platforms will have to figure this
out soon.

  • Shared/ChildProcess.h:
  • Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:


  • Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:


  • UIProcess/ChildProcessProxy.cpp:


  • UIProcess/ChildProcessProxy.h:

(WebKit::ChildProcessProxy::coreProcessIdentifier const):

  • UIProcess/Launcher/ProcessLauncher.h:
  • UIProcess/Launcher/mac/ProcessLauncherMac.mm:


5:41 PM Changeset in webkit [226307] by Yusuke Suzuki
  • 19 edits in trunk/Source

Remove std::chrono if it is not used for ArgumentCoder or PersistentCoder

Reviewed by Konstantin Tokarev.


We would like to remove std::chrono as much as possible due to the danger of
its overflow unawareness. This patch removes std::chrono if it is not used
for ArgumentCoder or PersistentCoder.

No behavior change.

  • fileapi/FileReader.cpp:


  • fileapi/FileReader.h:
  • inspector/InspectorOverlay.cpp:


  • inspector/InspectorOverlay.h:
  • page/ResourceUsageThread.cpp:


  • page/cocoa/MemoryReleaseCocoa.mm:


  • platform/network/curl/SocketStreamHandleImpl.h:
  • platform/network/curl/SocketStreamHandleImplCurl.cpp:



  • NetworkProcess/cache/NetworkCache.cpp:


  • NetworkProcess/cache/NetworkCacheStatistics.cpp:


  • UIProcess/Cocoa/ViewGestureController.cpp:

(WebKit::ViewGestureController::SnapshotRemovalTracker::log const):

  • UIProcess/Cocoa/ViewGestureController.h:
  • WebProcess/WebPage/WebPage.cpp:


  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::loadCommitTime const):

  • WebProcess/cocoa/WebProcessCocoa.mm:



Make WallTime more constexpr friendly. This change is already applied to MonoTonicTime.

We would like to move std::{isfinite,isinf,isnan} overloadings from std:: to each class scope in a separate patch[1].

[1]: https://bugs.webkit.org/show_bug.cgi?id=181183

  • wtf/WallTime.h:

(WTF::WallTime::secondsSinceEpoch const):
(WTF::WallTime::operator bool const):
(WTF::WallTime::operator+ const):
(WTF::WallTime::operator- const):
(WTF::WallTime::operator== const):
(WTF::WallTime::operator!= const):
(WTF::WallTime::operator< const):
(WTF::WallTime::operator> const):
(WTF::WallTime::operator<= const):
(WTF::WallTime::operator>= const):

2:06 PM Changeset in webkit [226306] by commit-queue@webkit.org
  • 12 edits in trunk

[Win][CMake] Use add_custom_command to copy each forwarding header files

Patch by Fujii Hironori <Fujii Hironori> on 2017-12-28
Reviewed by Brent Fulgham.


Modifying WTF header files didn't trigger the recompilation of
TestWTF because Ninja doesn't know which command generates the
forwarding header.

Use add_custom_command to copy each forwarding header files.

  • Source/cmake/WebKitMacros.cmake: Added a new function WEBKIT_MAKE_FORWARDING_HEADERS.




No new tests because there is no behavior change.





  • wtf/PlatformWin.cmake: Use WEBKIT_MAKE_FORWARDING_HEADERS.


TestWTFLib needs forwarding headers of WebCore. Use
add_dependencies instead of invoking the DerivedSources/WebCore/preBuild.cmd.

  • TestWebKitAPI/PlatformWin.cmake:
10:13 AM Changeset in webkit [226305] by sbarati@apple.com
  • 3 edits
    1 add in trunk

Assertion used to determine if something is an async generator is wrong

Reviewed by Yusuke Suzuki.


  • stress/async-generator-assertion.js: Added.


Previous assertions were doing a get on the base value for @@asyncIterator.
This symbol is defined on AsyncGeneratorPrototype. The base value may change
its prototype, but it's still an async generator as far as our system is
concerned. This patch updates the assertion to check for a private property
on the base value.

  • builtins/AsyncGeneratorPrototype.js:


6:17 AM Changeset in webkit [226304] by Yusuke Suzuki
  • 2 edits in trunk/Source/WTF

[WTF] Add clock_gettime based monotonicallyIncreasingTime implementation for Linux and BSDs

Reviewed by Michael Catanzaro.

Use platform-provided POSIX APIs to get monotonic time.

  • wtf/CurrentTime.cpp:


Dec 27, 2017:

2:55 PM Changeset in webkit [226303] by Dewei Zhu
  • 2 edits in trunk/Websites/perf.webkit.org

Test freshness page should use build time instead of commit time to determine the freshness of the data point.

Reviewed by Alexey Proskuryakov.

Build time is a better data point freshness indicator. Test freshness page is designed to highlight test failures.
Using commit time will result in including the compiling and test running time which does not quite match the
definition of data point fresshness.

  • public/v3/pages/test-freshness-page.js:

(TestFreshnessPage.prototype._fetchTestResults): Use build time instead of commit time.

9:41 AM Changeset in webkit [226302] by clopez@igalia.com
  • 2 edits in trunk/Source/JavaScriptCore

Build fix after r226299 (3)

Unreviewed build fix.

  • API/tests/TypedArrayCTest.cpp: fix typo in header name.
9:38 AM Changeset in webkit [226301] by clopez@igalia.com
  • 2 edits in trunk/Source/JavaScriptCore

Build fix after r226299 (2)

Unreviewed build fix.

  • API/tests/TypedArrayCTest.cpp: Add missing header include.
9:29 AM Changeset in webkit [226300] by clopez@igalia.com
  • 4 edits in trunk/Source

Build fix after r226299

Unreviewed build fix.


  • API/tests/TypedArrayCTest.cpp:

(assertEqualsAsNumber): Disambiguate usage of isnan.


No new tests, its a build fix.

  • platform/graphics/FontSelectionAlgorithm.h: Add missing include.
8:46 AM Changeset in webkit [226299] by clopez@igalia.com
  • 10 edits in trunk/Source

REGRESSION(r225769): Build error with constexpr std::max std::min in libdstdc++4

Reviewed by Myles C. Maxfield.


Disambiguate usage of min and max (Use the version from stdlib).

  • runtime/JSArray.cpp:



No new tests, its a build fix.

  • platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:

(WebCore::MediaPlayerPrivateAVFoundationCF::currentMediaTime const): Disambiguate usage of max (Use the version from stdlib).

  • platform/graphics/FontSelectionAlgorithm.h:

(WebCore::FontSelectionValue::clampFloat): Use WTF::min and WTF::max for constexpr result.

  • platform/graphics/win/UniscribeController.cpp:

(WebCore::UniscribeController::shapeAndPlaceItem): Disambiguate usage of min and max (Use the version from stdlib).


  • Plugins/PluginView.cpp:

(WebCore::PluginView::handlePost): Disambiguate usage of min (Use the version from stdlib).


In libstdc++-4 std::max and std::min are not annotated with constexpr.
This patch adds a WTF::min and WTF::max for using where a constexpr result is expected.
Related: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60271

  • wtf/StdLibExtras.h:


2:52 AM Changeset in webkit [226298] by zandobersek@gmail.com
  • 2 edits in trunk/Source/JavaScriptCore

REGRESSION(r225913): about 30 JSC test failures on ARMv7

Reviewed by Michael Catanzaro.

Fast case in DFG::SpeculativeJIT::compileArraySlice() was enabled in
r225913 on all but 32-bit x86 platform. Other 32-bit platforms have the
same lack of GP registers, so the conditional is changed here to only
enable this optimization explicitly on ARM64 and x86-64.

  • dfg/DFGSpeculativeJIT.cpp:


Note: See TracTimeline for information about the timeline view.