rniwa@webkit.org [Tue, 15 Dec 2015 23:57:25 +0000 (23:57 +0000)]
Add /api/measurement-set for v3 UI
https://bugs.webkit.org/show_bug.cgi?id=152312
Rubber-stamped by Chris Dumez.
The new API JSON allows the front end to fetch measured data in chunks called a "cluster" as specified
in config.json for each measurement set specified by the pair of a platform and a metric.
When the front end needs measured data in a given time range (t_0, t_1) for a measurement set, it first
fetches the primary cluster by /api/measurement-set/?platform=<platform-id>&metric=<metric-id>.
The primary cluster is the last cluster in the set (returning the first cluster here is not useful
since we don't typically show very old data), and provides the information needed to fetch other clusters.
Fetching the primary cluster also creates JSON files at:
/data/measurement-set-<platform-id>-<metric-id>-<cluster-end-time>.json
to allow latency free access for secondary clusters. The front end code can also fetch the cache of
the primary cluster at: /data/measurement-set-<platform-id>-<metric-id>.json.
Because the front end code has to behave as if all data is fetched, each cluster contains one data point
immediately before the first data point and one immediately after the last data point. This avoids having
to fetch multiple empty clusters for manually specified baseline data. To support this behavior, we generate
all clusters for a given measurement set at once when the primary cluster is requested.
Furthermore, all measurement sets are divided at the same time into clusters so that the boundary of clusters
won't shift as more data are reported to the server.
* config.json: Added clusterStart and clusterSize as options.
* public/api/measurement-set.php: Added.
(main):
(MeasurementSetFetcher::__construct):
(MeasurementSetFetcher::fetch_config_list): Finds configurations that belongs to this (platform, metric) pair.
(MeasurementSetFetcher::at_end): Returns true if we've reached the end of all clusters for this set.
(MeasurementSetFetcher::fetch_next_cluster): Generates the JSON data for the next cluster. We generate clusters
in increasing chronological order (the oldest first and the newest last).
(MeasurementSetFetcher::execute_query): Executes the main query.
(MeasurementSetFetcher::format_map): Returns the mapping of a measurement field to an array index. This removes
the need to have key names for each measurement and reduces the JSON size by ~10%.
(MeasurementSetFetcher::format_run): Creates an array that contains data for a single measurement. The order
matches that of keys in format_map.
(MeasurementSetFetcher::parse_revisions_array): Added. Copied from runs.php.
* tests/api-measurement-set.js: Added. Added tests for /api/measurement-set.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194120
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Tue, 15 Dec 2015 22:50:43 +0000 (22:50 +0000)]
Try to fix the CMake build
* CMakeLists.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194118
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Tue, 15 Dec 2015 22:46:02 +0000 (22:46 +0000)]
REGRESSION (r191849): There's no yellow bouncy highlight when using Find on Page on iOS
https://bugs.webkit.org/show_bug.cgi?id=152241
<rdar://problem/
23642574>
Reviewed by Simon Fraser.
Tests: pageoverlay/overlay-small-frame-mouse-events.html
pageoverlay/overlay-small-frame-paints.html
* page/PageOverlay.cpp:
(WebCore::PageOverlay::bounds):
Revert r191849's change that made bounds() actually return the frame()
if we frame is manually overriden.
(WebCore::PageOverlay::mouseEvent):
Convert the mouse event the rest of the way into overlay coordinates (by
applying the overlay's frame origin) before deciding whether to handle
the event.
* page/PageOverlay.h:
* DerivedSources.make:
* WebCore.xcodeproj/project.pbxproj:
* testing/Internals.cpp:
(WebCore::Internals::installMockPageOverlay):
* testing/Internals.h:
* testing/Internals.idl:
* testing/MockPageOverlay.cpp: Added.
(WebCore::MockPageOverlay::create):
(WebCore::MockPageOverlay::MockPageOverlay):
(WebCore::MockPageOverlay::setFrame):
* testing/MockPageOverlay.h: Added.
(WebCore::MockPageOverlay::overlay):
* testing/MockPageOverlay.idl: Added.
* testing/MockPageOverlayClient.cpp:
(WebCore::MockPageOverlayClient::installOverlay):
(WebCore::MockPageOverlayClient::uninstallAllOverlays):
(WebCore::MockPageOverlayClient::pageOverlayDestroyed):
(WebCore::MockPageOverlayClient::drawRect):
(WebCore::MockPageOverlayClient::mouseEvent):
* testing/MockPageOverlayClient.h:
Make internals.installMockPageOverlay return a MockPageOverlay object so
tests can manipulate their overlay. For now, expose setFrame.
Also, log when MockPageOverlayClient gets asked to paint or receives a mouse event,
which will show up in test output. Slightly unconventional, but very convenient.
* pageoverlay/overlay-small-frame-mouse-events-expected.txt: Added.
* pageoverlay/overlay-small-frame-mouse-events.html: Added.
Add a test ensuring that small-frame overlays get mouse events.
* pageoverlay/overlay-small-frame-paints-expected.txt: Added.
* pageoverlay/overlay-small-frame-paints.html: Added.
Add a test ensuring that small-frame overlays get paint callbacks.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194117
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mattbaker@apple.com [Tue, 15 Dec 2015 22:33:55 +0000 (22:33 +0000)]
Web Inspector: Convert Sidebar classes to use View
https://bugs.webkit.org/show_bug.cgi?id=152274
Reviewed by Brian Burg.
Updated Sidebar and SidebarPanel to inherit from View. Mostly mechanical changes.
Once the DetailsSection class family inherits from View (https://webkit.org/b/152269),
directly modifying a sidebar's 'contentView' element will rarely be necessary.
* UserInterface/Views/ApplicationCacheDetailsSidebarPanel.js:
(WebInspector.ApplicationCacheDetailsSidebarPanel):
* UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
(WebInspector.CSSStyleDetailsSidebarPanel):
(WebInspector.CSSStyleDetailsSidebarPanel.prototype.refresh):
(WebInspector.CSSStyleDetailsSidebarPanel.prototype._switchPanels):
Add/remove panels as subviews of the sidebar.
(WebInspector.CSSStyleDetailsSidebarPanel.prototype._filterDidChange):
* UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
(WebInspector.DOMNodeDetailsSidebarPanel):
* UserInterface/Views/DebuggerSidebarPanel.js:
(WebInspector.DebuggerSidebarPanel):
(WebInspector.DebuggerSidebarPanel.prototype._debuggerDidPause):
* UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
(WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildLayerInfoSection):
(WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildDataGridSection):
* UserInterface/Views/NavigationSidebarPanel.js:
(WebInspector.NavigationSidebarPanel):
(WebInspector.NavigationSidebarPanel.prototype.createContentTreeOutline):
(WebInspector.NavigationSidebarPanel.prototype._updateContentOverflowShadowVisibility):
* UserInterface/Views/ProbeDetailsSidebarPanel.js:
(WebInspector.ProbeDetailsSidebarPanel.prototype.set inspectedProbeSets):
* UserInterface/Views/ResourceDetailsSidebarPanel.js:
(WebInspector.ResourceDetailsSidebarPanel):
(WebInspector.ResourceDetailsSidebarPanel.prototype._refreshURL):
(WebInspector.ResourceDetailsSidebarPanel.prototype._refreshImageSizeSection):
(WebInspector.ResourceDetailsSidebarPanel.prototype._refreshRequestDataSection):
* UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
(WebInspector.ScopeChainDetailsSidebarPanel):
(WebInspector.ScopeChainDetailsSidebarPanel.prototype.refresh.):
(WebInspector.ScopeChainDetailsSidebarPanel.prototype.refresh):
* UserInterface/Views/SidebarPanel.js:
Inherit from View.
(WebInspector.SidebarPanel):
Replace the content element (the portion of the view excluding navigation
bars, filter bars, etc.) with a View object. A sidebar's content can be a mixture
of unwrapped DOM elements and View objects. For now, the content view's element
will be mutated directly, but once the DetailsSection class family inherits from
the View class the handling of details sections will be simplified.
(WebInspector.SidebarPanel.prototype.get contentView):
(WebInspector.SidebarPanel.prototype.shown):
(WebInspector.SidebarPanel.prototype.hidden):
(WebInspector.SidebarPanel.prototype.get contentElement): Deleted.
Replaced by WebInspector.SidebarPanel.prototype.get contentView.
* UserInterface/Views/StyleDetailsPanel.js:
Inherit from View.
(WebInspector.StyleDetailsPanel):
(WebInspector.StyleDetailsPanel.prototype.get element): Deleted.
Defer to View.element getter.
* UserInterface/Views/TimelineSidebarPanel.js:
(WebInspector.TimelineSidebarPanel.prototype._updateTimelineOverviewHeight):
* UserInterface/Views/VisualStyleDetailsPanel.js:
(WebInspector.VisualStyleDetailsPanel):
(WebInspector.VisualStyleDetailsPanel.prototype._updateSections):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194116
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ddkilzer@apple.com [Tue, 15 Dec 2015 22:10:20 +0000 (22:10 +0000)]
REGRESSION (r192375): DumpRenderTree.app exits immediately with no error
<http://webkit.org/b/152314>
Reviewed by Daniel Bates.
The change to DumpRenderTreeMain.mm in r192375 caused the iOS
code path to exit immediately when calling main().
Unfortunately, DumpRenderTreeMain.mm was used for both
DumpRenderTree command-line binary and DumpRenderTree.app, which
meant that the app would exit immediately with no error code
when run!
The workaround is to introduce a separate source file called
DumpRenderTreeAppMain.mm, similar to what WebKitTestRunner
already does.
* DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj: Add
DumpRenderTreeAppMain.mm to the project. Make it the only
compiled source for the DumpRenderTree.app target.
* DumpRenderTree/ios/DumpRenderTreeAppMain.mm: Copied from Tools/DumpRenderTree/mac/DumpRenderTreeMain.mm.
(main): Call DumpRenderTreeMain() on iOS. Assert on OS X in
case someone tries mistakenly to use the app.
* DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig:
Link to JavaScriptCore.framework on iOS for the assert.
* DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig:
Link to JavaScriptCore.framework on OS X for the assert. Remove
unneeded EXCLUDED_SOURCE_FILE_NAMES setting.
* DumpRenderTree/mac/DumpRenderTreeMain.mm:
(main): Add assert for iOS so that a crash occurs if someone
tries to run the wrong command.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194115
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mmaxfield@apple.com [Tue, 15 Dec 2015 21:55:34 +0000 (21:55 +0000)]
[Font Features] TrueType fonts trigger real features even when synthesis is applied
https://bugs.webkit.org/show_bug.cgi?id=152287
Reviewed by Darin Adler.
Source/WebCore:
When using a font feature that is synthesizable, and synthesis is triggered,
we should make sure to turn off the original font feature. Otherwise, the
feature will be applied twice on top of itself.
This worked for OpenType fonts, but not for TrueType fonts.
Tests: css3/font-variant-petite-caps-synthesis.html
css3/font-variant-small-caps-synthesis.html
css3/font-variant-petite-caps-synthesis-coverage.html
css3/font-variant-small-caps-synthesis-coverage.html
* platform/graphics/cocoa/FontCocoa.mm:
(WebCore::defaultSelectorForTrueTypeFeature):
(WebCore::removedFeature):
(WebCore::createCTFontWithoutSynthesizableFeatures):
LayoutTests:
Adding tests.
* css3/font-variant-petite-caps-synthesis-expected.html:
* css3/font-variant-petite-caps-synthesis.html:
* css3/font-variant-small-caps-synthesis-expected.html:
* css3/font-variant-small-caps-synthesis.html:
* css3/font-variant-petite-caps-synthesis-coverage-expected.html:
* css3/font-variant-petite-caps-synthesis-coverage.html:
* css3/font-variant-small-caps-synthesis-coverage-expected.html:
* css3/font-variant-small-caps-synthesis-coverage.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194114
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mark.lam@apple.com [Tue, 15 Dec 2015 21:19:31 +0000 (21:19 +0000)]
Polymorphic operand types for DFG and FTL bit operators.
https://bugs.webkit.org/show_bug.cgi?id=152191
Reviewed by Saam Barati.
Source/JavaScriptCore:
* bytecode/SpeculatedType.h:
(JSC::isUntypedSpeculationForBitOps):
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
* dfg/DFGNode.h:
(JSC::DFG::Node::shouldSpeculateUntypedForBitOps):
- Added check for types not supported by ValueToInt32, and therefore should be
treated as untyped for bitops.
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
- Handled untyped operands.
* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
- Added DFG slow path functions for bitops.
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::emitUntypedBitOp):
(JSC::DFG::SpeculativeJIT::compileBitwiseOp):
(JSC::DFG::SpeculativeJIT::emitUntypedRightShiftBitOp):
(JSC::DFG::SpeculativeJIT::compileShiftOp):
* dfg/DFGSpeculativeJIT.h:
- Added DFG backend support untyped operands for bitops.
* dfg/DFGStrengthReductionPhase.cpp:
(JSC::DFG::StrengthReductionPhase::handleNode):
- Limit bitops strength reduction only to when we don't have untyped operands.
This is because values that are not int32s need to be converted to int32.
Without untyped operands, the ValueToInt32 node takes care of this.
With untyped operands, we cannot use ValueToInt32, and need to do the conversion
in the code emitted for the bitop node itself. For example:
5.5 | 0; // yields 5 because ValueToInt32 converts the 5.5 to a 5.
"abc" | 0; // would yield "abc" instead of the expected 0 if we let
// strength reduction do its thing.
* ftl/FTLCompileBinaryOp.cpp:
(JSC::FTL::generateBinaryBitOpFastPath):
(JSC::FTL::generateRightShiftFastPath):
(JSC::FTL::generateBinaryOpFastPath):
* ftl/FTLInlineCacheDescriptor.h:
(JSC::FTL::BitAndDescriptor::BitAndDescriptor):
(JSC::FTL::BitAndDescriptor::icSize):
(JSC::FTL::BitAndDescriptor::nodeType):
(JSC::FTL::BitAndDescriptor::opName):
(JSC::FTL::BitAndDescriptor::slowPathFunction):
(JSC::FTL::BitAndDescriptor::nonNumberSlowPathFunction):
(JSC::FTL::BitOrDescriptor::BitOrDescriptor):
(JSC::FTL::BitOrDescriptor::icSize):
(JSC::FTL::BitOrDescriptor::nodeType):
(JSC::FTL::BitOrDescriptor::opName):
(JSC::FTL::BitOrDescriptor::slowPathFunction):
(JSC::FTL::BitOrDescriptor::nonNumberSlowPathFunction):
(JSC::FTL::BitXorDescriptor::BitXorDescriptor):
(JSC::FTL::BitXorDescriptor::icSize):
(JSC::FTL::BitXorDescriptor::nodeType):
(JSC::FTL::BitXorDescriptor::opName):
(JSC::FTL::BitXorDescriptor::slowPathFunction):
(JSC::FTL::BitXorDescriptor::nonNumberSlowPathFunction):
(JSC::FTL::BitLShiftDescriptor::BitLShiftDescriptor):
(JSC::FTL::BitLShiftDescriptor::icSize):
(JSC::FTL::BitLShiftDescriptor::nodeType):
(JSC::FTL::BitLShiftDescriptor::opName):
(JSC::FTL::BitLShiftDescriptor::slowPathFunction):
(JSC::FTL::BitLShiftDescriptor::nonNumberSlowPathFunction):
(JSC::FTL::BitRShiftDescriptor::BitRShiftDescriptor):
(JSC::FTL::BitRShiftDescriptor::icSize):
(JSC::FTL::BitRShiftDescriptor::nodeType):
(JSC::FTL::BitRShiftDescriptor::opName):
(JSC::FTL::BitRShiftDescriptor::slowPathFunction):
(JSC::FTL::BitRShiftDescriptor::nonNumberSlowPathFunction):
(JSC::FTL::BitURShiftDescriptor::BitURShiftDescriptor):
(JSC::FTL::BitURShiftDescriptor::icSize):
(JSC::FTL::BitURShiftDescriptor::nodeType):
(JSC::FTL::BitURShiftDescriptor::opName):
(JSC::FTL::BitURShiftDescriptor::slowPathFunction):
(JSC::FTL::BitURShiftDescriptor::nonNumberSlowPathFunction):
- Added support for bitop ICs.
* ftl/FTLInlineCacheSize.cpp:
(JSC::FTL::sizeOfBitAnd):
(JSC::FTL::sizeOfBitOr):
(JSC::FTL::sizeOfBitXor):
(JSC::FTL::sizeOfBitLShift):
(JSC::FTL::sizeOfBitRShift):
(JSC::FTL::sizeOfBitURShift):
* ftl/FTLInlineCacheSize.h:
- Added new bitop IC sizes. These are just estimates for now that work adequately,
and are shown to not impact performance on benchmarks. We will re-tune these
sizes values later in another patch once all snippet ICs have been added.
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::compileBitAnd):
(JSC::FTL::DFG::LowerDFGToLLVM::compileBitOr):
(JSC::FTL::DFG::LowerDFGToLLVM::compileBitXor):
(JSC::FTL::DFG::LowerDFGToLLVM::compileBitRShift):
(JSC::FTL::DFG::LowerDFGToLLVM::compileBitLShift):
(JSC::FTL::DFG::LowerDFGToLLVM::compileBitURShift):
- Added support for bitop ICs.
* jit/JITLeftShiftGenerator.cpp:
(JSC::JITLeftShiftGenerator::generateFastPath):
* jit/JITLeftShiftGenerator.h:
(JSC::JITLeftShiftGenerator::JITLeftShiftGenerator):
* jit/JITRightShiftGenerator.cpp:
(JSC::JITRightShiftGenerator::generateFastPath):
- The shift MASM operatons need to ensure that the shiftAmount is not in the same
register as the destination register. With the baselineJIT and DFG, this is
ensured in how we allocate these registers, and hence, the bug does not manifest.
With the FTL, these registers are not guaranteed to be unique. Hence, we need
to fix the shift op snippet code to compensate for this.
LayoutTests:
* js/regress/ftl-polymorphic-bitand-expected.txt: Added.
* js/regress/ftl-polymorphic-bitand.html: Added.
* js/regress/ftl-polymorphic-bitor-expected.txt: Added.
* js/regress/ftl-polymorphic-bitor.html: Added.
* js/regress/ftl-polymorphic-bitxor-expected.txt: Added.
* js/regress/ftl-polymorphic-bitxor.html: Added.
* js/regress/ftl-polymorphic-lshift-expected.txt: Added.
* js/regress/ftl-polymorphic-lshift.html: Added.
* js/regress/ftl-polymorphic-rshift-expected.txt: Added.
* js/regress/ftl-polymorphic-rshift.html: Added.
* js/regress/ftl-polymorphic-urshift-expected.txt: Added.
* js/regress/ftl-polymorphic-urshift.html: Added.
* js/regress/script-tests/ftl-polymorphic-bitand.js: Added.
(o1.valueOf):
(foo):
* js/regress/script-tests/ftl-polymorphic-bitor.js: Added.
(o1.valueOf):
(foo):
* js/regress/script-tests/ftl-polymorphic-bitxor.js: Added.
(o1.valueOf):
(foo):
* js/regress/script-tests/ftl-polymorphic-lshift.js: Added.
(o1.valueOf):
(foo):
* js/regress/script-tests/ftl-polymorphic-rshift.js: Added.
(o1.valueOf):
(foo):
* js/regress/script-tests/ftl-polymorphic-urshift.js: Added.
(o1.valueOf):
(foo):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194113
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
adam.bergkvist@ericsson.com [Tue, 15 Dec 2015 20:36:15 +0000 (20:36 +0000)]
WebRTC: Test that RTCPeerConnection promise functions reject on closed state
https://bugs.webkit.org/show_bug.cgi?id=152295
Reviewed by Eric Carlson.
Add test that verifies RTCPeerConnection's behavior in the closed state
(signalingState). Promise functions should reject, and (some) others
should throw. Remove old test that tests incorrect behavior.
* fast/mediastream/RTCPeerConnection-closed-state-expected.txt: Added.
* fast/mediastream/RTCPeerConnection-closed-state.html: Added.
* fast/mediastream/RTCPeerConnection-state-expected.txt: Removed.
* fast/mediastream/RTCPeerConnection-state.html: Removed.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194112
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
peavo@outlook.com [Tue, 15 Dec 2015 19:11:45 +0000 (19:11 +0000)]
[WinCairo][MediaFoundation] Full screen mode is not supported.
https://bugs.webkit.org/show_bug.cgi?id=152300
Reviewed by Darin Adler.
We need to let WebCore know MediaFoundation supports full screen mode.
* platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
(WebCore::MediaPlayerPrivateMediaFoundation::pause):
(WebCore::MediaPlayerPrivateMediaFoundation::supportsFullscreen):
(WebCore::MediaPlayerPrivateMediaFoundation::naturalSize):
* platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194111
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
dbates@webkit.org [Tue, 15 Dec 2015 18:40:30 +0000 (18:40 +0000)]
Guard code that uses class LayerTreeHost with USE(COORDINATED_GRAPHICS) or USE(TEXTURE_MAPPER)
https://bugs.webkit.org/show_bug.cgi?id=152265
Reviewed by Tim Horton.
We neither make use of LayerTreeHost on Mac nor on iOS. We should guard code that makes
use of this class as applicable. This also fixes the iOS Simulator build when using
Apple Internal software.
* WebProcess/WebCoreSupport/WebChromeClient.cpp: Guard code that used LayerTreeHost.
* WebProcess/WebPage/LayerTreeHost.cpp: Guard contents of file with USE(COORDINATED_GRAPHICS) || USE(TEXTURE_MAPPER).
* WebProcess/WebPage/LayerTreeHost.h: Ditto.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::scalePage): Ditto.
(WebKit::WebPage::setDeviceScaleFactor): Ditto.
* WebProcess/WebPage/WebPage.h: Substitute header LayerTreeContext.h for LayerTreeHost.h since we make use
of the enum class LayerHostingMode.
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::updateVisibleContentRects): Remove unnecessary code; DrawingArea::layerTreeHost() always
returns nullptr on iOS.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194108
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 15 Dec 2015 17:58:04 +0000 (17:58 +0000)]
[JSC] SyntaxError if AssignmentElement is `eval` or `arguments` in strict code
https://bugs.webkit.org/show_bug.cgi?id=152302
Patch by Caitlin Potter <caitp@igalia.com> on 2015-12-15
Reviewed by Mark Lam.
`eval` and `arguments` must not be assigned to in strict code. This
change fixes `language/expressions/assignment/destructuring/obj-id-simple-strict.js`
in Test262, as well as a variety of other similar tests.
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseAssignmentElement):
(JSC::Parser<LexerType>::parseDestructuringPattern):
* tests/stress/destructuring-assignment-syntax.js:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194107
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 15 Dec 2015 17:40:09 +0000 (17:40 +0000)]
[GTK] Gardening: Rebaseline tests
https://bugs.webkit.org/show_bug.cgi?id=152301
Unreviewed GTK gardening
Patch by Tomas Popela <tpopela@redhat.com> on 2015-12-15
* platform/gtk/fast/dom/Window/window-lookup-precedence-expected.txt:
Correct the expectations after r189202 when RangeException was
removed.
* platform/gtk/fast/dom/adopt-attribute-crash-expected.txt: Added.
Add a new test expectations after r187148.
* platform/gtk/http/tests/plugins/plugin-javascript-access-expected.txt: Added.
Add a new test expectations after r193363.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194106
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Tue, 15 Dec 2015 16:36:51 +0000 (16:36 +0000)]
Changing expectation for storage/indexeddb/deleted-objects.html to [ Failure Crash ]
https://bugs.webkit.org/show_bug.cgi?id=152264
Unreviewed test gardening.
* platform/mac-wk1/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194105
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jfernandez@igalia.com [Tue, 15 Dec 2015 12:11:56 +0000 (12:11 +0000)]
[css-align][css-grid] Overflow alignment value 'true' renamed to 'unsafe'
https://bugs.webkit.org/show_bug.cgi?id=152251
Source/WebCore:
Reviewed by Darin Adler.
The 'True' Overflow Alignment keyword is now defined in the Box Alignment
specification as 'Unsafe'.
This patch applies the required changes in the CSS parsing logic, as well
Grid Layout specific codebase, so it complies with the last version of the
spec.
No new tests, no change in functionality.
* css/CSSParser.cpp:
(WebCore::isAlignmentOverflowKeyword):
(WebCore::CSSParser::parseItemPositionOverflowPosition):
* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator OverflowAlignment):
* css/CSSValueKeywords.in:
* rendering/RenderGrid.cpp:
(WebCore::computeOverflowAlignmentOffset):
* rendering/style/RenderStyleConstants.h:
LayoutTests:
The 'True' Overflow Alignment keyword is known now as 'Unsafe', so adapting
layout tests using such keyword.
Reviewed by Darin Adler.
* css3/overwrite-content-alignment-expected.txt:
* css3/overwrite-content-alignment.html:
* css3/overwrite-self-alignment-expected.txt:
* css3/overwrite-self-alignment.html:
* css3/parse-align-content-expected.txt:
* css3/parse-align-content.html:
* css3/parse-align-items-expected.txt:
* css3/parse-align-items.html:
* css3/parse-align-self-expected.txt:
* css3/parse-align-self.html:
* css3/parse-justify-content-expected.txt:
* css3/parse-justify-content.html:
* fast/css-grid-layout/grid-align-justify-overflow.html:
* fast/css-grid-layout/grid-content-alignment-overflow.html:
* fast/css/parse-justify-items-expected.txt:
* fast/css/parse-justify-items.html:
* fast/css/parse-justify-self-expected.txt:
* fast/css/parse-justify-self.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194104
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zandobersek@gmail.com [Tue, 15 Dec 2015 11:54:13 +0000 (11:54 +0000)]
[TexMap] Operate with a reference to the TextureMapper wherever possible
https://bugs.webkit.org/show_bug.cgi?id=152118
Reviewed by Martin Robinson.
Source/WebCore:
In most cases where used, the pointer to the TextureMapper is non-null, so it
should really be a reference. The pointer is still used for the
TextureMapperLayer member variable which is null until the TextureMapper object
is created and set on the root layer.
* platform/graphics/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
* platform/graphics/GraphicsContext3DPrivate.h:
* platform/graphics/cairo/ImageBufferCairo.cpp:
(WebCore::ImageBufferData::paintToTextureMapper):
* platform/graphics/cairo/ImageBufferDataCairo.h:
* platform/graphics/efl/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
* platform/graphics/efl/GraphicsContext3DPrivate.h:
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::paintToTextureMapper):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
* platform/graphics/surfaces/GraphicsSurface.cpp:
(WebCore::GraphicsSurface::paintToTextureMapper):
* platform/graphics/surfaces/GraphicsSurface.h:
* platform/graphics/surfaces/efl/GraphicsSurfaceCommon.cpp:
(WebCore::GraphicsSurface::platformPaintToTextureMapper):
* platform/graphics/texmap/BitmapTexture.cpp:
(WebCore::BitmapTexture::updateContents):
* platform/graphics/texmap/BitmapTexture.h:
(WebCore::BitmapTexture::applyFilters):
* platform/graphics/texmap/BitmapTextureGL.cpp:
(WebCore::BitmapTextureGL::applyFilters):
* platform/graphics/texmap/BitmapTextureGL.h:
* platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
(WebCore::GraphicsLayerTextureMapper::updateBackingStoreIfNeeded):
* platform/graphics/texmap/TextureMapperBackingStore.h:
(WebCore::TextureMapperBackingStore::drawRepaintCounter):
* platform/graphics/texmap/TextureMapperFPSCounter.cpp:
(WebCore::TextureMapperFPSCounter::updateFPSAndDisplay):
* platform/graphics/texmap/TextureMapperFPSCounter.h:
* platform/graphics/texmap/TextureMapperLayer.cpp:
(WebCore::TextureMapperPaintOptions::TextureMapperPaintOptions):
(WebCore::TextureMapperLayer::paint):
(WebCore::TextureMapperLayer::paintSelf):
(WebCore::TextureMapperLayer::paintSelfAndChildren):
(WebCore::TextureMapperLayer::paintUsingOverlapRegions):
(WebCore::TextureMapperLayer::applyMask):
(WebCore::TextureMapperLayer::paintIntoSurface):
(WebCore::commitSurface):
(WebCore::TextureMapperLayer::paintWithIntermediateSurface):
* platform/graphics/texmap/TextureMapperPlatformLayer.h:
(WebCore::TextureMapperPlatformLayer::drawBorder):
* platform/graphics/texmap/TextureMapperPlatformLayerBuffer.cpp:
(WebCore::TextureMapperPlatformLayerBuffer::paintToTextureMapper):
* platform/graphics/texmap/TextureMapperPlatformLayerBuffer.h:
* platform/graphics/texmap/TextureMapperSurfaceBackingStore.cpp:
(WebCore::TextureMapperSurfaceBackingStore::paintToTextureMapper):
* platform/graphics/texmap/TextureMapperSurfaceBackingStore.h:
* platform/graphics/texmap/TextureMapperTile.cpp:
(WebCore::TextureMapperTile::updateContents):
(WebCore::TextureMapperTile::paint):
* platform/graphics/texmap/TextureMapperTile.h:
* platform/graphics/texmap/TextureMapperTiledBackingStore.cpp:
(WebCore::TextureMapperTiledBackingStore::updateContentsFromImageIfNeeded):
(WebCore::TextureMapperTiledBackingStore::paintToTextureMapper):
(WebCore::TextureMapperTiledBackingStore::drawBorder):
(WebCore::TextureMapperTiledBackingStore::drawRepaintCounter):
(WebCore::TextureMapperTiledBackingStore::updateContents):
* platform/graphics/texmap/TextureMapperTiledBackingStore.h:
Source/WebKit/win:
* WebCoreSupport/AcceleratedCompositingContext.cpp:
(AcceleratedCompositingContext::compositeLayersToContext): TextureMapper object
is now operated with through a reference.
Source/WebKit2:
Replace pointers to the TextureMapper object with references.
* Shared/CoordinatedGraphics/CoordinatedBackingStore.cpp:
(WebKit::CoordinatedBackingStoreTile::swapBuffers):
(WebKit::CoordinatedBackingStore::paintTilesToTextureMapper):
(WebKit::CoordinatedBackingStore::paintToTextureMapper):
(WebKit::CoordinatedBackingStore::drawBorder):
(WebKit::CoordinatedBackingStore::drawRepaintCounter):
(WebKit::CoordinatedBackingStore::commitTileOperations):
* Shared/CoordinatedGraphics/CoordinatedBackingStore.h:
* Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:
(WebKit::CoordinatedGraphicsScene::paintToCurrentGLContext):
(WebKit::CoordinatedGraphicsScene::paintToGraphicsContext):
(WebKit::CoordinatedGraphicsScene::commitPendingBackingStoreOperations):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194103
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sukolsak@gmail.com [Tue, 15 Dec 2015 10:33:09 +0000 (10:33 +0000)]
Unreviewed, rename ExecState* exec to ExecState* state in Intl code
as reviewed in https://bugs.webkit.org/show_bug.cgi?id=151491
* runtime/IntlCollatorPrototype.cpp:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194102
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ossy@webkit.org [Tue, 15 Dec 2015 09:07:16 +0000 (09:07 +0000)]
URTBF after 194062.
* assembler/MacroAssemblerARM.h:
(JSC::MacroAssemblerARM::supportsFloatingPointCeil): Added.
(JSC::MacroAssemblerARM::ceilDouble): Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194101
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
youenn.fablet@crf.canon.fr [Tue, 15 Dec 2015 08:55:23 +0000 (08:55 +0000)]
WebIDL generator should support the possibility for C++ classes to have a JS Builtin constructor
https://bugs.webkit.org/show_bug.cgi?id=152171
Reviewed by Darin Adler.
Reintroducing JSBuiltinConstructor keyword as a way to run automatically a JS builtin initialization function
to process the arguments passed to the DOM C++ constructor.
Specialized createJSObject for those classes.
Fixing typo in TestCustomConstructor.idl.
Covered by binding tests.
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateConstructorDefinition):
(IsConstructable):
(IsJSBuiltinConstructor):
(AddJSBuiltinIncludesIfNeeded):
* bindings/scripts/test/GObject/WebKitDOMTestClassWithJSBuiltinConstructor.cpp: Added.
* bindings/scripts/test/GObject/WebKitDOMTestClassWithJSBuiltinConstructor.h: Added.
* bindings/scripts/test/GObject/WebKitDOMTestClassWithJSBuiltinConstructorPrivate.h: Added.
* bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp: Added.
* bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h: Added.
* bindings/scripts/test/ObjC/DOMTestClassWithJSBuiltinConstructor.h: Added.
* bindings/scripts/test/ObjC/DOMTestClassWithJSBuiltinConstructor.mm: Added.
* bindings/scripts/test/ObjC/DOMTestClassWithJSBuiltinConstructorInternal.h: Added.
* bindings/scripts/test/TestClassWithJSBuiltinConstructor.idl: Copied from Source/WebCore/bindings/scripts/test/TestCustomConstructor.idl.
* bindings/scripts/test/TestCustomConstructor.idl:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194100
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 15 Dec 2015 06:49:03 +0000 (06:49 +0000)]
[Coordinated Graphics] CSS transition effect is not shown when transformed with "%" unit.
https://bugs.webkit.org/show_bug.cgi?id=152278
Patch by YongGeol Jung <yg48.jung@samsung.com> on 2015-12-14
Reviewed by Darin Adler.
boxSize is encoded as FloatSize type but decoded as IntSize type.
So boxSize gets invalid value after decoding.
Due to this layer goes to out of screen during animation.
* Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
(IPC::ArgumentCoder<TextureMapperAnimation>::decode):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194095
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Tue, 15 Dec 2015 06:08:19 +0000 (06:08 +0000)]
<rdar://problem/
23886216> REGRESSION (r194022): Production builds of PluginProcess crash on launch when not installed in /System
https://bugs.webkit.org/show_bug.cgi?id=152291
Reviewed by Darin Adler.
* Configurations/PluginProcess.xcconfig: Added a FIXME.
* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::addDYLDEnvironmentAdditions): Set DYLD_LIBRARY_PATH to point to where the shims
are. This is needed because starting in El Capitan, the processes’ main executables link
directly against the shims, so the dynamic linker needs to be able to find them in the
non-/System location. Also added a FIXME about not having to set DYLD_INSERT_LIBRARIES when
the main executables link the them directly.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194094
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rniwa@webkit.org [Tue, 15 Dec 2015 05:15:52 +0000 (05:15 +0000)]
Using fake timestamp in OS version make some results invisible
https://bugs.webkit.org/show_bug.cgi?id=152289
Reviewed by Stephanie Lewis.
Fix various bugs after r194088.
* public/api/commits.php:
(format_commit): Include the commit order.
* public/v2/data.js:
(CommitLogs._cacheConsecutiveCommits): Sort by commit order when commit time is missing.
* tools/pull-os-versions.py:
(OSBuildFetcher._assign_order): Use integer instead of fake time for commit order.
(available_builds_from_command): Exit early when an exception is thrown.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194093
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Tue, 15 Dec 2015 04:52:55 +0000 (04:52 +0000)]
FTL B3 should account for localsOffset
https://bugs.webkit.org/show_bug.cgi?id=152288
Reviewed by Saam Barati.
The DFG will build up some data structures that expect to know about offsets from FP. Those data
structures may slide by some offset when the low-level compiler (either LLVM or B3) does stack
allocation. So, the LLVM FTL modifies those data structures based on the real offset that it gets
from LLVM's stackmaps. The B3 code needs to do the same.
I had previously vowed to never put more stuff into FTLB3Compile.cpp, because I didn't want it to
look like FTLCompile.cpp. Up until now, I was successful because I used lambdas installed by
FTLLower. But in this case, I actually think that having code that just does this explicitly in
FTLB3Compile.cpp is least confusing. There is no particular place in FTLLower that would want to
care about this, and we need to ensure that we do this fixup before we run any of the stackmap
generators. In other words, it needs to happen before we call B3::generate(). The ordering
constraints seem like a good reason to have this done explicitly rather than through lambdas.
I wrote a test. The test was failing in trunk because the B3 meaning of anchor().value() is
different from the LLVM meaning. This caused breakage when we used this idiom:
ValueFromBlock foo = m_out.anchor(things);
...(foo.value()) // we were expecting that foo.value() == things
I never liked this idiom to begin with, so instead of trying to change B3's anchor(), I changed
the idiom to:
LValue fooValue = things;
ValueFromBlock foo = m_out.anchor(fooValue);
...(fooValue)
This is probably a good idea, since eventually we want B3's anchor() to just return the
UpsilonValue*. To get there, we want to eliminate any situations where code assumes that
ValueFromBlock is an actual object and not just a typedef for a pointer.
* ftl/FTLB3Compile.cpp:
(JSC::FTL::compile):
* ftl/FTLB3Output.cpp:
(JSC::FTL::Output::appendTo):
(JSC::FTL::Output::lockedStackSlot):
* ftl/FTLB3Output.h:
(JSC::FTL::Output::framePointer):
(JSC::FTL::Output::constBool):
(JSC::FTL::Output::constInt32):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::lower):
(JSC::FTL::DFG::LowerDFGToLLVM::compileGetIndexedPropertyStorage):
(JSC::FTL::DFG::LowerDFGToLLVM::compileGetByVal):
(JSC::FTL::DFG::LowerDFGToLLVM::compileCreateDirectArguments):
(JSC::FTL::DFG::LowerDFGToLLVM::compileStringCharAt):
(JSC::FTL::DFG::LowerDFGToLLVM::compileForwardVarargs):
(JSC::FTL::DFG::LowerDFGToLLVM::compileHasIndexedProperty):
(JSC::FTL::DFG::LowerDFGToLLVM::allocateJSArray):
(JSC::FTL::DFG::LowerDFGToLLVM::sensibleDoubleToInt32):
* ftl/FTLState.h:
(JSC::FTL::verboseCompilationEnabled):
* tests/stress/ftl-function-dot-arguments-with-callee-saves.js: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194092
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Tue, 15 Dec 2015 04:43:03 +0000 (04:43 +0000)]
Re-enabling passing test fast/viewport/ios/width-is-device-width.html, which was accidentally skipped with r194058.
https://bugs.webkit.org/show_bug.cgi?id=152135
Unreviewed test gardening.
* platform/ios-simulator-wk2/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194091
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rniwa@webkit.org [Tue, 15 Dec 2015 04:32:31 +0000 (04:32 +0000)]
Fix a typo in the previous commit.
* public/include/report-processor.php:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194090
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rniwa@webkit.org [Tue, 15 Dec 2015 04:31:30 +0000 (04:31 +0000)]
Build fix after r192965. Suppress a warning about log being referred to as a closure variable.
* public/include/report-processor.php:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194089
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rniwa@webkit.org [Tue, 15 Dec 2015 04:06:44 +0000 (04:06 +0000)]
Using fake timestamp in OS version make some results invisible
https://bugs.webkit.org/show_bug.cgi?id=152289
Reviewed by Stephanie Lewis.
Added commit_order column to explicitly order OS versions. This fixes the bug whereby which
baseline results reported with only OS versions are shown with x coordinate set to 10 years ago.
To migrate the existing database, run:
ALTER TABLE commits ADD COLUMN commit_order integer;
CREATE INDEX commit_order_index ON commits(commit_order);
Then for each repository $1,
UPDATE commits SET (commit_time, commit_order) = (NULL, CAST(EXTRACT(epoch from commit_time) as integer))
WHERE commit_repository = $1;
* init-database.sql: Added the column.
* public/api/commits.php:
(fetch_commits_between): Use commit_order to order commits when commit_time is missing.
* public/api/report-commits.php:
(main): Set commit_order.
* tools/pull-os-versions.py:
(OSBuildFetcher.fetch_and_report_new_builds):
(OSBuildFetcher._assign_order): Renamed from _assign_fake_timestamps. Set the order instead of a fake timestmap.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194088
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Tue, 15 Dec 2015 03:51:42 +0000 (03:51 +0000)]
Math.random should have an intrinsic thunk and it should be later handled as a DFG Node
https://bugs.webkit.org/show_bug.cgi?id=152133
Reviewed by Geoffrey Garen.
Source/JavaScriptCore:
In this patch, we implement new RandomIntrinsic. It emits a machine code to generate random numbers efficiently.
And later it will be recognized by DFG and converted to ArithRandom node.
It provides type information SpecDoubleReal since Math.random only generates a number within [0, 1.0).
Currently, only 64bit version is supported. On 32bit environment, ArithRandom will be converted to callOperation.
While it emits a function call, ArithRandom node on 32bit still represents SpecDoubleReal as a result type.
* dfg/DFGAbstractHeap.h:
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::handleIntrinsicCall):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGDoesGC.cpp:
(JSC::DFG::doesGC):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
* dfg/DFGNodeType.h:
* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::propagate):
* dfg/DFGSafeToExecute.h:
(JSC::DFG::safeToExecute):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::callOperation):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
(JSC::DFG::SpeculativeJIT::compileArithRandom):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
(JSC::DFG::SpeculativeJIT::compileArithRandom):
* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::compileNode):
(JSC::FTL::DFG::LowerDFGToLLVM::compileArithRandom):
* jit/AssemblyHelpers.cpp:
(JSC::emitRandomThunkImpl):
(JSC::AssemblyHelpers::emitRandomThunk):
* jit/AssemblyHelpers.h:
* jit/JITOperations.h:
* jit/ThunkGenerators.cpp:
(JSC::randomThunkGenerator):
* jit/ThunkGenerators.h:
* runtime/Intrinsic.h:
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::weakRandomOffset):
* runtime/MathObject.cpp:
(JSC::MathObject::finishCreation):
* runtime/VM.cpp:
(JSC::thunkGeneratorForIntrinsic):
* tests/stress/random-53bit.js: Added.
(test):
* tests/stress/random-in-range.js: Added.
(test):
Source/WTF:
Change 64bit random to double logic to convert efficiently.
* wtf/WeakRandom.h:
(WTF::WeakRandom::get):
(WTF::WeakRandom::lowOffset):
(WTF::WeakRandom::highOffset):
LayoutTests:
Add new regression test.
* js/regress/math-random-expected.txt: Added.
* js/regress/math-random.html: Added.
* js/regress/script-tests/math-random.js: Added.
(test):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194087
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
simon.fraser@apple.com [Tue, 15 Dec 2015 03:06:13 +0000 (03:06 +0000)]
Dump some more data in the RemoteLayerTreeTransaction
https://bugs.webkit.org/show_bug.cgi?id=152283
Reviewed by Dean Jackson.
Dump some scale factors, viewport meta tag width and render tree size.
* Shared/mac/RemoteLayerTreeTransaction.mm:
(WebKit::RemoteLayerTreeTransaction::description):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194086
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rniwa@webkit.org [Tue, 15 Dec 2015 02:59:36 +0000 (02:59 +0000)]
Perf dashboard can't merge when the destination platform is missing baseline/target
https://bugs.webkit.org/show_bug.cgi?id=152286
Reviewed by Stephanie Lewis.
The bug was caused by the query to migrate test configurations to new platform checking
configuration type and metric separately; that is, it assumes the configuration exists
only if either the same type or the same metric exists in the destination.
Fixed the bug by checking both conditions simultaneously for each configuration.
* public/admin/platforms.php:
* tests/admin-platforms.js: Added a test.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194085
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Tue, 15 Dec 2015 01:14:34 +0000 (01:14 +0000)]
Web Inspector: Stack traces in console incorrectly show "(anonymous function)" for global code
https://bugs.webkit.org/show_bug.cgi?id=152280
Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-12-14
Reviewed by Brian Burg.
Source/WebInspectorUI:
* UserInterface/Images/Program.svg: Added.
* UserInterface/Images/gtk/Program.svg: Added.
Copied from TimelineRecordScriptEvaluated.svg.
* UserInterface/Models/CallFrame.js:
(WebInspector.CallFrame):
(WebInspector.CallFrame.prototype.get programCode):
Add a new property to check if this call frame is in program code.
(WebInspector.CallFrame.fromPayload):
Detect different sources of program code (global, eval, module).
* UserInterface/Views/CallFrameIcons.css:
(.program-icon .icon):
* UserInterface/Views/CallFrameView.js:
(WebInspector.CallFrameView.iconClassNameForCallFrame):
Give program code the [S] global script icon like in profiles.
LayoutTests:
* inspector/debugger/js-stacktrace-expected.txt:
* inspector/debugger/js-stacktrace.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194083
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Tue, 15 Dec 2015 01:11:44 +0000 (01:11 +0000)]
Marking storage/indexeddb/deleted-objects.html as a flaky crash on mac-wk1
https://bugs.webkit.org/show_bug.cgi?id=152264
Unreviewed test gardening.
* platform/mac-wk1/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194082
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Tue, 15 Dec 2015 01:03:35 +0000 (01:03 +0000)]
Marking platform/ios-simulator/ios/scrolling tests as failing on ios-simulator
https://bugs.webkit.org/show_bug.cgi?id=152276
Unreviewed test gardening.
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194081
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
benjamin@webkit.org [Tue, 15 Dec 2015 00:34:37 +0000 (00:34 +0000)]
Rename FTL::Output's ceil64() to doubleCeil()
Rubber-stamped by Filip Pizlo.
ceil64() was a bad name, that's the name convention we use for integers.
* ftl/FTLB3Output.h:
(JSC::FTL::Output::doubleCeil):
(JSC::FTL::Output::ceil64): Deleted.
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::compileArithRound):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194073
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Tue, 15 Dec 2015 00:30:53 +0000 (00:30 +0000)]
FTL B3 should be able to run n-body.js
https://bugs.webkit.org/show_bug.cgi?id=152281
Reviewed by Benjamin Poulain.
Fix a bug where m_captured was pointing to the start of the captured vars slot rather than the
end, like the rest of the FTL expected.
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::lower):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194072
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
benjamin@webkit.org [Tue, 15 Dec 2015 00:11:45 +0000 (00:11 +0000)]
Fix bad copy-paste in r194062
Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-14
* ftl/FTLB3Output.h:
(JSC::FTL::Output::ceil64):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194071
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 23:48:34 +0000 (23:48 +0000)]
Updating ios-simulator expectation for crashing tests http/tests/misc/large-js-program.php and js/dom/line-column-numbers.html
https://bugs.webkit.org/show_bug.cgi?id=152279
Unreviewed test gardening.
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194070
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 23:42:02 +0000 (23:42 +0000)]
Removing ios-simulator TestExpectations for deleted tests: streams/reference-implementation/readable-stream-cancel.html (r192186)
and http/tests/inspector/console/access-inspected-object.html (r192186).
https://bugs.webkit.org/show_bug.cgi?id=152131
Unreviewed test gardening.
* platform/ios-simulator-wk1/TestExpectations:
* platform/ios-simulator-wk2/TestExpectations:
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194069
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Mon, 14 Dec 2015 23:27:15 +0000 (23:27 +0000)]
Unreviewed, fix cloop build.
* jit/GPRInfo.cpp:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194068
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Mon, 14 Dec 2015 23:18:36 +0000 (23:18 +0000)]
FTL B3 should do PutById
https://bugs.webkit.org/show_bug.cgi?id=152268
Reviewed by Saam Barati.
* CMakeLists.txt:
* JavaScriptCore.xcodeproj/project.pbxproj:
* b3/B3LowerToAir.cpp:
(JSC::B3::Air::LowerToAir::createGenericCompare): I realized that we were missing some useful matching rules.
* b3/testb3.cpp: Added a bunch of tests.
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::compilePutById): Do the things.
* jit/GPRInfo.cpp: Added. I had to do this yucky thing because clang was having issues compiling references to this from deeply nested lambdas.
* jit/GPRInfo.h: Added a comment about how patchpointScratchRegister is bizarre and should probably die.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194067
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 14 Dec 2015 23:10:22 +0000 (23:10 +0000)]
Web Inspector: Copy message from console with a stack trace does not include source code locations
https://bugs.webkit.org/show_bug.cgi?id=152270
Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-12-14
Reviewed by Timothy Hatcher.
* UserInterface/Views/ConsoleMessageView.js:
(WebInspector.ConsoleMessageView.prototype.toClipboardString):
When the the StackTrace was upgraded to a real collection of CallFrame
object's the CallFrame's got real SourceCodeLocation properties.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194066
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 23:01:04 +0000 (23:01 +0000)]
Adding a second newline to the iOS simulator expected result for compositing/iframes/page-cache-layer-tree.html
https://bugs.webkit.org/show_bug.cgi?id=152132
Unreviewed test gardening.
* platform/ios-simulator-wk2/compositing/iframes/page-cache-layer-tree-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194063
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 14 Dec 2015 22:44:22 +0000 (22:44 +0000)]
[JSC] Add ceil() support for x86 and expose it to B3
https://bugs.webkit.org/show_bug.cgi?id=152231
Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-14
Reviewed by Geoffrey Garen.
Most x86 CPUs we care about support ceil() natively
with the round instruction.
This patch expose that behind a runtime flag, use it
in the Math.ceil() thunk and expose it to B3.
* assembler/MacroAssemblerARM64.h:
(JSC::MacroAssemblerARM64::supportsFloatingPointCeil):
* assembler/MacroAssemblerARMv7.h:
(JSC::MacroAssemblerARMv7::supportsFloatingPointCeil):
* assembler/MacroAssemblerMIPS.h:
(JSC::MacroAssemblerMIPS::supportsFloatingPointCeil):
* assembler/MacroAssemblerSH4.h:
(JSC::MacroAssemblerSH4::supportsFloatingPointCeil):
* assembler/MacroAssemblerX86Common.cpp:
* assembler/MacroAssemblerX86Common.h:
(JSC::MacroAssemblerX86Common::ceilDouble):
(JSC::MacroAssemblerX86Common::ceilFloat):
(JSC::MacroAssemblerX86Common::supportsFloatingPointCeil):
(JSC::MacroAssemblerX86Common::supportsLZCNT):
* assembler/X86Assembler.h:
(JSC::X86Assembler::roundss_rr):
(JSC::X86Assembler::roundss_mr):
(JSC::X86Assembler::roundsd_rr):
(JSC::X86Assembler::roundsd_mr):
(JSC::X86Assembler::mfence):
(JSC::X86Assembler::X86InstructionFormatter::threeByteOp):
* b3/B3ConstDoubleValue.cpp:
(JSC::B3::ConstDoubleValue::ceilConstant):
* b3/B3ConstDoubleValue.h:
* b3/B3ConstFloatValue.cpp:
(JSC::B3::ConstFloatValue::ceilConstant):
* b3/B3ConstFloatValue.h:
* b3/B3LowerMacrosAfterOptimizations.cpp:
* b3/B3LowerToAir.cpp:
(JSC::B3::Air::LowerToAir::lower):
* b3/B3Opcode.cpp:
(WTF::printInternal):
* b3/B3Opcode.h:
* b3/B3ReduceDoubleToFloat.cpp:
* b3/B3ReduceStrength.cpp:
* b3/B3Validate.cpp:
* b3/B3Value.cpp:
(JSC::B3::Value::ceilConstant):
(JSC::B3::Value::effects):
(JSC::B3::Value::key):
(JSC::B3::Value::typeFor):
* b3/B3Value.h:
* b3/air/AirOpcode.opcodes:
* b3/testb3.cpp:
(JSC::B3::testCeilArg):
(JSC::B3::testCeilImm):
(JSC::B3::testCeilMem):
(JSC::B3::testCeilCeilArg):
(JSC::B3::testCeilIToD64):
(JSC::B3::testCeilIToD32):
(JSC::B3::testCeilArgWithUselessDoubleConversion):
(JSC::B3::testCeilArgWithEffectfulDoubleConversion):
(JSC::B3::populateWithInterestingValues):
(JSC::B3::run):
* ftl/FTLB3Output.h:
(JSC::FTL::Output::ceil64):
* jit/ThunkGenerators.cpp:
(JSC::ceilThunkGenerator):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194062
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 22:26:40 +0000 (22:26 +0000)]
Marking js/regress/generator-with-several-types.html as a flaky timeout on mac-wk1 debug.
https://bugs.webkit.org/show_bug.cgi?id=152272
Unreviewed test gardening.
* platform/mac-wk1/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194061
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Mon, 14 Dec 2015 22:12:02 +0000 (22:12 +0000)]
Frequent crash under -[WKPDFView web_setMinimumSize:]_block_invoke
https://bugs.webkit.org/show_bug.cgi?id=152266
<rdar://problem/
22092676>
Reviewed by Simon Fraser.
Source/WebKit2:
* UIProcess/ios/WKPDFView.mm:
(-[WKPDFView web_setMinimumSize:]):
We weren't retaining the UIScrollView, but depending on it surviving
into this block's invocation.
We don't need to do this asynchronously anymore because the referenced
bug is fixed, so make it happen synchronously. This also fixes the crash
because there's no opportunity for the scroll view to be released.
Tools:
* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKit2Cocoa/WKPDFViewResizeCrash.mm: Added.
Add a test that crashed before this change, and doesn't crash after.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194060
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 22:10:37 +0000 (22:10 +0000)]
Take 2 of updating expectations for fast/events/ios tests by removing the directory's [ Pass ] expectation.
https://bugs.webkit.org/show_bug.cgi?id=152134
Unreviewed test gardening.
* platform/ios-simulator-wk2/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194059
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 22:08:25 +0000 (22:08 +0000)]
Take 2 of updating expectations for fast/viewport/ios tests by removing the directory's [ Pass ] expectation.
https://bugs.webkit.org/show_bug.cgi?id=152135
Unreviewed test gardening.
* platform/ios-simulator-wk2/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194058
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
akling@apple.com [Mon, 14 Dec 2015 21:36:27 +0000 (21:36 +0000)]
ResourceUsageOverlay should show GC timers.
<https://webkit.org/b/152151>
Reviewed by Darin Adler.
Source/JavaScriptCore:
Expose the next fire time (in WTF timestamp style) of a GCActivityCallback.
* heap/GCActivityCallback.cpp:
(JSC::GCActivityCallback::scheduleTimer):
(JSC::GCActivityCallback::cancelTimer):
* heap/GCActivityCallback.h:
Source/WebCore:
Add countdowns until next Eden and Full GC to the overlay. It also shows if there
is no garbage collection scheduled. This will be helpful in understanding why GC
sometimes takes a very long time to happen.
* page/ResourceUsageOverlay.h:
* page/cocoa/ResourceUsageOverlayCocoa.mm:
(WebCore::formatByteNumber): Drive-by silly math fix. :|
(WebCore::gcTimerString):
(WebCore::ResourceUsageOverlay::platformDraw):
(WebCore::nextFireTimeForGCTimer):
(WebCore::runSamplerThread):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194057
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 21:30:31 +0000 (21:30 +0000)]
Rebaseline compositing/iframes/page-cache-layer-tree.html for iOS Simulator
https://bugs.webkit.org/show_bug.cgi?id=152267
Unreviewed test gardening.
* platform/ios-simulator-wk2/compositing/iframes/page-cache-layer-tree-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194056
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 21:30:28 +0000 (21:30 +0000)]
Marking fast/viewport/ios/width-is-device-width-overflowing* tests as failing on iOS simulator
https://bugs.webkit.org/show_bug.cgi?id=152135
Unreviewed test gardening.
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194055
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cfleizach@apple.com [Mon, 14 Dec 2015 21:12:22 +0000 (21:12 +0000)]
AX: iOS: Text field variations do not have the correct traits
https://bugs.webkit.org/show_bug.cgi?id=152237
Reviewed by Mario Sanchez Prada.
Source/WebCore:
Make search fields and text areas use the appropriate iOS traits to
distinguish them.
Test: accessibility/ios-simulator/textentry-traits.html
* accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(-[WebAccessibilityObjectWrapper _accessibilityTraitsFromAncestors]):
(-[WebAccessibilityObjectWrapper _accessibilityTextEntryTraits]):
(-[WebAccessibilityObjectWrapper accessibilityTraits]):
Tools:
Add iOS calls for determing if an object is a search field or a text area.
* DumpRenderTree/AccessibilityUIElement.cpp:
(getIsSearchFieldCallback):
(getIsTextAreaCallback):
(stringForSelectionCallback):
(AccessibilityUIElement::getJSClass):
* DumpRenderTree/AccessibilityUIElement.h:
* DumpRenderTree/ios/AccessibilityUIElementIOS.mm:
(AccessibilityUIElement::identifier):
(AccessibilityUIElement::isTextArea):
(AccessibilityUIElement::isSearchField):
(AccessibilityUIElement::traits):
* WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp:
(WTR::AccessibilityUIElement::scrollPageRight):
(WTR::AccessibilityUIElement::hasContainedByFieldsetTrait):
(WTR::AccessibilityUIElement::fieldsetAncestorElement):
(WTR::AccessibilityUIElement::isSearchField):
(WTR::AccessibilityUIElement::isTextArea):
* WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
* WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
* WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
(WTR::AccessibilityUIElement::fieldsetAncestorElement):
(WTR::AccessibilityUIElement::isTextArea):
(WTR::AccessibilityUIElement::isSearchField):
(WTR::AccessibilityUIElement::rowCount):
LayoutTests:
* accessibility/ios-simulator/textentry-traits-expected.txt: Added.
* accessibility/ios-simulator/textentry-traits.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194054
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 21:03:29 +0000 (21:03 +0000)]
Marking fast/viewport/ios/width-is-device-width-overflowing* tests as failing on iOS simulator
https://bugs.webkit.org/show_bug.cgi?id=152135
Unreviewed test gardening.
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194053
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 21:00:20 +0000 (21:00 +0000)]
Marking fast/picture/image-picture-* as failing on iOS simulator
https://bugs.webkit.org/show_bug.cgi?id=152141
Unreviewed test gardening.
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194052
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 20:43:45 +0000 (20:43 +0000)]
Removing failure expectation for css3/blending tests that are now passing on iOS simulator
https://bugs.webkit.org/show_bug.cgi?id=152131
Unreviewed test gardening.
* platform/ios-simulator/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194051
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Mon, 14 Dec 2015 20:28:23 +0000 (20:28 +0000)]
Unreviewed, fix merge issue in a test.
* b3/testb3.cpp:
(JSC::B3::testCheckTwoMegaCombos):
(JSC::B3::testCheckTwoNonRedundantMegaCombos):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194050
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Mon, 14 Dec 2015 20:25:30 +0000 (20:25 +0000)]
B3 should not give ValueReps for the non-stackmap children of a CheckValue to the generator callback
https://bugs.webkit.org/show_bug.cgi?id=152224
Reviewed by Geoffrey Garen.
Previously, a stackmap generator for a Check had to know how many children the B3 value for the
Check had at the time of code generation. That meant that B3 could not change the kind of Check
that it was - for example it cannot turn a Check into a Patchpoint and it cannot turn a CheckAdd
into a Check. But just changing the contract so that the stackmap generation params only get the
stackmap children of the check means that B3 can transform Checks as it likes.
This is meant to aid sinking values into checks.
Also, I found that the effects of a Check did not include HeapRange::top(). I think it's best if
exitsSideways does not imply reading top, the way that it does in DFG. In the DFG, that makes
sense because the exit analysis is orthogonal, so the clobber analysis tells you about the reads
not counting OSR exit - if you need to you can conditionally merge that with World based on a
separate exit analysis. But in B3, the Effects object tells you about both exiting and reading,
and it's computed by one analysis. Prior to this change, Check was not setting reads to top() so
we were effectively saying that Effects::reads is meaningless when exitsSideways is true. It
seems more sensible to instead force the analysis to set reads to top() when setting
exitsSideways to true, not least because we only have one such analysis and many users. But it
also makes sense for another reason: it allows us to bound the set of things that the program
will read after it exits. That might not be useful to us now, but it's a nice feature to get for
free. I've seen language features that have behave like exitsSideways that don't also read top,
like an array bounds check that causes sudden termination without making any promises about how
pretty the crash dump will look.
* b3/B3CheckSpecial.cpp:
(JSC::B3::CheckSpecial::generate):
* b3/B3Opcode.h:
* b3/B3Value.cpp:
(JSC::B3::Value::effects):
* b3/testb3.cpp:
(JSC::B3::testSimpleCheck):
(JSC::B3::testCheckLessThan):
(JSC::B3::testCheckMegaCombo):
(JSC::B3::testCheckAddImm):
(JSC::B3::testCheckAddImmCommute):
(JSC::B3::testCheckAddImmSomeRegister):
(JSC::B3::testCheckAdd):
(JSC::B3::testCheckAdd64):
(JSC::B3::testCheckSubImm):
(JSC::B3::testCheckSubBadImm):
(JSC::B3::testCheckSub):
(JSC::B3::testCheckSub64):
(JSC::B3::testCheckNeg):
(JSC::B3::testCheckNeg64):
(JSC::B3::testCheckMul):
(JSC::B3::testCheckMulMemory):
(JSC::B3::testCheckMul2):
(JSC::B3::testCheckMul64):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::blessSpeculation):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194048
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Mon, 14 Dec 2015 19:58:14 +0000 (19:58 +0000)]
Remove some Mavericks guards in ServicesOverlayController
https://bugs.webkit.org/show_bug.cgi?id=152238
Reviewed by Darin Adler.
* page/mac/ServicesOverlayController.mm:
(WebCore::ServicesOverlayController::selectionRectsDidChange): Deleted.
(WebCore::ServicesOverlayController::selectedTelephoneNumberRangesChanged): Deleted.
The whole file is already PLATFORM(MAC) guarded, and the 10.9 guards
are no longer necessary.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194047
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Mon, 14 Dec 2015 19:55:46 +0000 (19:55 +0000)]
TiledCoreAnimationDrawingAreaProxy::createFenceForGeometryUpdate() sets fence port on context twice
https://bugs.webkit.org/show_bug.cgi?id=152239
<rdar://problem/
22893289>
Reviewed by Darin Adler.
* UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
(WebKit::TiledCoreAnimationDrawingAreaProxy::createFenceForGeometryUpdate):
No need to setFencePort; createFencePort also installs it on the creating context.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194046
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Mon, 14 Dec 2015 19:54:15 +0000 (19:54 +0000)]
Air: Support Architecture-specific forms and Opcodes
https://bugs.webkit.org/show_bug.cgi?id=151736
Reviewed by Benjamin Poulain.
This adds really awesome architecture selection to the AirOpcode.opcodes file. If an opcode or
opcode form is unavailable on some architecture, you can still mention its name in C++ code (it'll
still be a member of the enum) but isValidForm() and all other reflective queries will tell you
that it doesn't exist. This will make the instruction selector steer clear of it, and it will
also ensure that the spiller doesn't try to use any unavailable architecture-specific address
forms.
The new capability is documented extensively in a comment in AirOpcode.opcodes.
* b3/air/AirOpcode.opcodes:
* b3/air/opcode_generator.rb:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194045
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ryanhaddad@apple.com [Mon, 14 Dec 2015 19:53:04 +0000 (19:53 +0000)]
Rebaselining fast/text/emoji.html for iOS simulator
https://bugs.webkit.org/show_bug.cgi?id=152261
Unreviewed test gardening.
* platform/ios-simulator/fast/text/emoji-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194044
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
achristensen@apple.com [Mon, 14 Dec 2015 19:45:07 +0000 (19:45 +0000)]
Use existing code for redirects when using NETWORK_SESSION
https://bugs.webkit.org/show_bug.cgi?id=152207
rdar://problem/
23860624
Reviewed by Darin Adler.
This fixes http/tests/cookies/set-cookie-on-redirect.html when using NETWORK_SESSION.
* NetworkProcess/NetworkLoad.cpp:
(WebKit::NetworkLoad::continueWillSendRequest):
(WebKit::NetworkLoad::convertTaskToDownload):
(WebKit::NetworkLoad::willPerformHTTPRedirection):
(WebKit::NetworkLoad::didReceiveChallenge):
* NetworkProcess/NetworkLoad.h:
* NetworkProcess/NetworkSession.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194043
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mark.lam@apple.com [Mon, 14 Dec 2015 19:44:56 +0000 (19:44 +0000)]
Misc. small fixes in snippet related code.
https://bugs.webkit.org/show_bug.cgi?id=152259
Reviewed by Saam Barati.
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileArithMul):
- When loading a constant JSValue for a node, use the one that the node already
provides instead of reconstructing it. This is not a bug, but the fix makes
the code cleaner.
* jit/JITBitAndGenerator.cpp:
(JSC::JITBitAndGenerator::generateFastPath):
- No need to do a bitand with a constant int 0xffffffff operand.
* jit/JITBitOrGenerator.cpp:
(JSC::JITBitOrGenerator::generateFastPath):
- Fix comments: bitor is '|', not '&'.
- No need to do a bitor with a constant int 0 operand.
* jit/JITBitXorGenerator.cpp:
(JSC::JITBitXorGenerator::generateFastPath):
- Fix comments: bitxor is '^', not '&'.
* jit/JITRightShiftGenerator.cpp:
(JSC::JITRightShiftGenerator::generateFastPath):
- Renamed a jump target name to be clearer about its purpose.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194042
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sukolsak@gmail.com [Mon, 14 Dec 2015 19:41:45 +0000 (19:41 +0000)]
Make UCharIterator createIterator(StringView) visible to other classes
https://bugs.webkit.org/show_bug.cgi?id=151917
Reviewed by Darin Adler.
Make UCharIterator createIterator(StringView) in CollatorICU.cpp visible
to other classes so that future patches that will ucol_strcollIter
(including Bug 147604) can use it.
* wtf/unicode/Collator.h:
* wtf/unicode/icu/CollatorICU.cpp:
(WTF::createIterator):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194041
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mark.lam@apple.com [Mon, 14 Dec 2015 19:39:45 +0000 (19:39 +0000)]
We should not employ the snippet code in the DFG if no OSR exit was previously encountered.
https://bugs.webkit.org/show_bug.cgi?id=152255
Reviewed by Saam Barati.
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194040
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fpizlo@apple.com [Mon, 14 Dec 2015 19:13:31 +0000 (19:13 +0000)]
B3->Air compare-branch fusion should fuse even if the result of the comparison is used more than once
https://bugs.webkit.org/show_bug.cgi?id=152198
Reviewed by Benjamin Poulain.
If we have a comparison operation that is branched on from multiple places, then we were
previously executing the comparison to get a boolean result in a register and then we were
testing/branching on that register in multiple places. This is actually less efficient than
just fusing the compare/branch multiple times, even though this means that the comparison
executes multiple times. This would only be bad if the comparison fused loads multiple times,
since duplicating loads is both wrong and inefficient. So, this adds the notion of sharing to
compare/branch fusion. If a compare is shared by multiple branches, then we refuse to fuse
the load.
To write the test, I needed to zero-extend 8 to 32. In the process of thinking about how to
do this, I realized that we needed lowerings for SExt8/SExt16. And I realized that the
lowerings for the other extension operations were not fully fleshed out; for example they
were incapable of load fusion. This patch fixes this and also adds some smart strength
reductions for BitAnd(@x, 0xff/0xffff/0xffffffff) - all of which should be lowered to a zero
extension.
This is a big win on asm.js code. It's not enough to bridge the gap to LLVM, but it's a huge
step in that direction.
* assembler/MacroAssemblerX86Common.h:
(JSC::MacroAssemblerX86Common::load8SignedExtendTo32):
(JSC::MacroAssemblerX86Common::zeroExtend8To32):
(JSC::MacroAssemblerX86Common::signExtend8To32):
(JSC::MacroAssemblerX86Common::load16):
(JSC::MacroAssemblerX86Common::load16SignedExtendTo32):
(JSC::MacroAssemblerX86Common::zeroExtend16To32):
(JSC::MacroAssemblerX86Common::signExtend16To32):
(JSC::MacroAssemblerX86Common::store32WithAddressOffsetPatch):
* assembler/X86Assembler.h:
(JSC::X86Assembler::movzbl_rr):
(JSC::X86Assembler::movsbl_rr):
(JSC::X86Assembler::movzwl_rr):
(JSC::X86Assembler::movswl_rr):
(JSC::X86Assembler::cmovl_rr):
* b3/B3LowerToAir.cpp:
(JSC::B3::Air::LowerToAir::createGenericCompare):
(JSC::B3::Air::LowerToAir::lower):
* b3/B3ReduceStrength.cpp:
* b3/air/AirOpcode.opcodes:
* b3/testb3.cpp:
(JSC::B3::testCheckMegaCombo):
(JSC::B3::testCheckTwoMegaCombos):
(JSC::B3::testCheckTwoNonRedundantMegaCombos):
(JSC::B3::testCheckAddImm):
(JSC::B3::testTruncSExt32):
(JSC::B3::testSExt8):
(JSC::B3::testSExt8Fold):
(JSC::B3::testSExt8SExt8):
(JSC::B3::testSExt8SExt16):
(JSC::B3::testSExt8BitAnd):
(JSC::B3::testBitAndSExt8):
(JSC::B3::testSExt16):
(JSC::B3::testSExt16Fold):
(JSC::B3::testSExt16SExt16):
(JSC::B3::testSExt16SExt8):
(JSC::B3::testSExt16BitAnd):
(JSC::B3::testBitAndSExt16):
(JSC::B3::testSExt32BitAnd):
(JSC::B3::testBitAndSExt32):
(JSC::B3::testBasicSelect):
(JSC::B3::run):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194039
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 14 Dec 2015 18:07:19 +0000 (18:07 +0000)]
[iOS] DOM click event may not be dispatched when page has :active style and <input type="search">
https://bugs.webkit.org/show_bug.cgi?id=144451
<rdar://problem/
23099482>
Patch by Daniel Bates <dabates@apple.com> on 2015-12-14
Reviewed by Simon Fraser.
Source/WebCore:
Fixes an issue where a DOM click event is not dispatched to an element in a subframe on a page
that has a <input type="search"> and defines a CSS :active pseudo-class for the HTML body element.
On iOS we only dispatch a DOM click event if the content of the page does not change as part of
dispatching a DOM mousemove event at the tapped element as a means of providing a good user
experience on web pages that reveal or hide content based on mouse hover. Currently we consider
the content of the page to have changed if the visibility of any element on the page changes.
In particular we consider the content of the page to have changed if the visibility of a user
agent shadow DOM element changes (e.g. the search field cancel button). Instead we should only
consider visibility changes to the actual web page content and ignore visibility changes to
user agent shadow DOM elements.
Tests: fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field.html
fast/forms/search/search-cancel-button-visible-when-input-becomes-disabled.html
fast/forms/search/search-cancel-button-visible-when-input-becomes-readonly.html
fast/forms/search/search-cancel-in-formerly-invisible-element.html
fast/forms/search/search-cancel-toggle-visibility-initially-hidden.html
fast/forms/search/search-cancel-toggle-visibility-initially-visible.html
* style/StyleResolveTree.cpp:
(WebCore::Style::CheckForVisibilityChangeOnRecalcStyle::~CheckForVisibilityChangeOnRecalcStyle):
Ignore visibility changes to user agent shadow DOM elements.
LayoutTests:
Add a test to ensure that a DOM click event is dispatched to an element in a subframe on a page
with a search field and that specifies a CSS :active pseudo-class that changes the tap highlight
color.
Additionally, add tests to ensure we update the cancel button visibility whenever the visibility
of the search field changes.
* fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field-expected.txt: Added.
* fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-disabled-expected.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-disabled.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-readonly-expected.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-readonly.html: Added.
* fast/forms/search/search-cancel-in-formerly-invisible-element-expected.html: Added.
* fast/forms/search/search-cancel-in-formerly-invisible-element.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-hidden-expected.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-hidden.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-visible-expected.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-visible.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194038
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ddkilzer@apple.com [Mon, 14 Dec 2015 17:44:17 +0000 (17:44 +0000)]
REGRESSION (r162777): Remove Boost Software License from WTF
<http://webkit.org/b/152243>
Reviewed by Darin Adler.
The source code that the Boost Software License was referring to
was removed in r162777 by switching to std::atomic.
* wtf/Atomics.cpp:
* wtf/Atomics.h:
* wtf/ThreadSafeRefCounted.h:
- Remove Boost Software License.
- Update Apple Inc. copyright as needed.
- Refresh Apple Inc. license text.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194037
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cdumez@apple.com [Mon, 14 Dec 2015 17:37:59 +0000 (17:37 +0000)]
Roll out r193974 and follow-up fixes as it caused JSC crashes
https://bugs.webkit.org/show_bug.cgi?id=152256
Source/JavaScriptCore:
Unreviewed, Roll out r193974 and follow-up fixes as it caused JSC crashes.
* API/JSCallbackObject.h:
* builtins/FunctionPrototype.js:
* bytecode/BytecodeBasicBlock.cpp:
(JSC::isBranch):
* bytecode/BytecodeList.json:
* bytecode/BytecodeUseDef.h:
(JSC::computeUsesForBytecodeOffset):
(JSC::computeDefsForBytecodeOffset):
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::dumpBytecode):
* bytecode/ExitKind.cpp:
(JSC::exitKindToString): Deleted.
* bytecode/ExitKind.h:
* bytecode/PreciseJumpTargets.cpp:
(JSC::getJumpTargetsForBytecodeOffset):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::emitCheckHasInstance):
(JSC::BytecodeGenerator::emitGetById): Deleted.
* bytecompiler/BytecodeGenerator.h:
(JSC::BytecodeGenerator::emitTypeOf): Deleted.
* bytecompiler/NodesCodegen.cpp:
(JSC::InstanceOfNode::emitBytecode):
(JSC::LogicalOpNode::emitBytecode): Deleted.
(JSC::LogicalOpNode::emitBytecodeInConditionContext): Deleted.
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::parseBlock):
* dfg/DFGCapabilities.cpp:
(JSC::DFG::capabilityLevel):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGDoesGC.cpp:
(JSC::DFG::doesGC):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
* dfg/DFGHeapLocation.cpp:
(WTF::printInternal):
* dfg/DFGHeapLocation.h:
* dfg/DFGNode.h:
(JSC::DFG::Node::hasCellOperand): Deleted.
(JSC::DFG::Node::hasTransition): Deleted.
* dfg/DFGNodeType.h:
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::propagate):
* dfg/DFGSafeToExecute.h:
(JSC::DFG::safeToExecute):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileInstanceOf): Deleted.
(JSC::DFG::SpeculativeJIT::compileArithAdd): Deleted.
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::callOperation): Deleted.
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLIntrinsicRepository.h:
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::compileNode):
(JSC::FTL::DFG::LowerDFGToLLVM::compileCheckHasInstance):
(JSC::FTL::DFG::LowerDFGToLLVM::compileInstanceOf): Deleted.
(JSC::FTL::DFG::LowerDFGToLLVM::compileHasIndexedProperty): Deleted.
* jit/CCallHelpers.h:
(JSC::CCallHelpers::setupArguments): Deleted.
(JSC::CCallHelpers::setupArgumentsWithExecState): Deleted.
* jit/JIT.cpp:
(JSC::JIT::privateCompileMainPass):
(JSC::JIT::privateCompileSlowCases):
* jit/JIT.h:
* jit/JITInlines.h:
(JSC::JIT::callOperationNoExceptionCheck): Deleted.
(JSC::JIT::callOperation): Deleted.
* jit/JITOpcodes.cpp:
(JSC::JIT::emit_op_check_has_instance):
(JSC::JIT::emit_op_instanceof):
(JSC::JIT::emitSlow_op_check_has_instance):
(JSC::JIT::emitSlow_op_instanceof):
(JSC::JIT::emit_op_is_undefined): Deleted.
(JSC::JIT::emitSlow_op_to_number): Deleted.
(JSC::JIT::emitSlow_op_to_string): Deleted.
* jit/JITOpcodes32_64.cpp:
(JSC::JIT::emit_op_check_has_instance):
(JSC::JIT::emit_op_instanceof):
(JSC::JIT::emitSlow_op_check_has_instance):
(JSC::JIT::emitSlow_op_instanceof):
(JSC::JIT::emit_op_is_undefined): Deleted.
* jit/JITOperations.cpp:
* jit/JITOperations.h:
* llint/LLIntData.cpp:
(JSC::LLInt::Data::performAssertions): Deleted.
* llint/LLIntSlowPaths.cpp:
(JSC::LLInt::LLINT_SLOW_PATH_DECL):
* llint/LLIntSlowPaths.h:
* llint/LowLevelInterpreter32_64.asm:
* llint/LowLevelInterpreter64.asm:
* runtime/CommonIdentifiers.h:
* runtime/ExceptionHelpers.cpp:
(JSC::invalidParameterInstanceofSourceAppender):
(JSC::createInvalidInstanceofParameterError):
(JSC::createError): Deleted.
(JSC::createNotAFunctionError): Deleted.
(JSC::createNotAnObjectError): Deleted.
* runtime/ExceptionHelpers.h:
* runtime/FunctionPrototype.cpp:
(JSC::FunctionPrototype::addFunctionProperties):
* runtime/FunctionPrototype.h:
* runtime/JSBoundFunction.cpp:
(JSC::JSBoundFunction::create): Deleted.
(JSC::JSBoundFunction::customHasInstance): Deleted.
* runtime/JSBoundFunction.h:
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::visitChildren): Deleted.
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::throwTypeErrorGetterSetter): Deleted.
* runtime/JSObject.cpp:
(JSC::JSObject::hasInstance):
(JSC::JSObject::defaultHasInstance): Deleted.
(JSC::JSObject::getPropertyNames): Deleted.
(JSC::JSObject::getOwnPropertyNames): Deleted.
* runtime/JSObject.h:
(JSC::JSFinalObject::create): Deleted.
* runtime/JSTypeInfo.h:
(JSC::TypeInfo::TypeInfo):
(JSC::TypeInfo::overridesHasInstance):
* runtime/WriteBarrier.h:
(JSC::WriteBarrierBase<Unknown>::slot):
* tests/es6.yaml:
* tests/stress/instanceof-custom-hasinstancesymbol.js: Removed.
* tests/stress/symbol-hasInstance.js: Removed.
LayoutTests:
Unreviewed, roll out r193974 and follow-up fixes as it caused JSC crashes.
* inspector/model/remote-object-get-properties-expected.txt:
* js/Object-getOwnPropertyNames-expected.txt:
* js/exception-for-nonobject-expected.txt:
* js/exception-instanceof-expected.txt:
* js/instance-of-immediates-expected.txt:
* js/regress/instanceof-bound-expected.txt: Removed.
* js/regress/instanceof-bound.html: Removed.
* js/regress/script-tests/instanceof-bound.js: Removed.
* js/script-tests/Object-getOwnPropertyNames.js:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194036
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
youenn.fablet@crf.canon.fr [Mon, 14 Dec 2015 17:27:27 +0000 (17:27 +0000)]
[Streams API] Directly use @then as much as possible
https://bugs.webkit.org/show_bug.cgi?id=151631
Reviewed by Darin Adler.
Moved from @Promise.prototype.@then.@call(promise,...) to promise.@then.(...)
for promise objects that are not exposed to user scripts.
Updated promiseInvokeXX stream utility functions to ensure that returned promise always has a @then.
This allows improving the readability of code calling promiseInvokeXX functions.
Changed invokeOrNoop to promiseInvokeOrNoopNoCatch as invokeOrNoop
result is always wrapped as a promise using Promise.resolve.
No change in behavior.
* Modules/streams/ReadableStream.js:
(initializeReadableStream):
* Modules/streams/ReadableStreamInternals.js:
(teeReadableStream):
(teeReadableStreamBranch2CancelFunction):
(cancelReadableStream):
* Modules/streams/StreamInternals.js:
(shieldingPromiseResolve): introduced this routine to ensure the returned promise has a @then property.
(promiseInvokeOrNoopNoCatch):
(promiseInvokeOrNoop):
(promiseInvokeOrFallbackOrNoop):
* Modules/streams/WritableStream.js:
(initializeWritableStream):
(abort):
* Modules/streams/WritableStreamInternals.js:
(callOrScheduleWritableStreamAdvanceQueue):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194035
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
clopez@igalia.com [Mon, 14 Dec 2015 16:27:42 +0000 (16:27 +0000)]
[GTK] [JHBuild] package libtool-bin is now required on Debian systems.
https://bugs.webkit.org/show_bug.cgi?id=152252
Reviewed by Sergio Villar Senin.
* gtk/install-dependencies: Add libtool-bin to the list of packages required
for building the JHBuild on Debian systems.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194034
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
youenn.fablet@crf.canon.fr [Mon, 14 Dec 2015 15:57:48 +0000 (15:57 +0000)]
[Streams API] Expose ReadableStream and relatives to Worker
https://bugs.webkit.org/show_bug.cgi?id=152066
LayoutTests/imported/w3c:
Reviewed by Darin Adler.
Rebasing all worker tests from FAIL to PASS.
* web-platform-tests/streams-api/byte-length-queuing-strategy-expected.txt:
* web-platform-tests/streams-api/count-queuing-strategy-expected.txt:
* web-platform-tests/streams-api/readable-streams/bad-strategies-expected.txt:
* web-platform-tests/streams-api/readable-streams/bad-underlying-sources-expected.txt:
* web-platform-tests/streams-api/readable-streams/brand-checks-expected.txt:
* web-platform-tests/streams-api/readable-streams/cancel-expected.txt:
* web-platform-tests/streams-api/readable-streams/count-queuing-strategy-integration-expected.txt:
* web-platform-tests/streams-api/readable-streams/garbage-collection-expected.txt:
* web-platform-tests/streams-api/readable-streams/general-expected.txt:
* web-platform-tests/streams-api/readable-streams/pipe-through-expected.txt:
* web-platform-tests/streams-api/readable-streams/readable-stream-reader-expected.txt:
* web-platform-tests/streams-api/readable-streams/tee-expected.txt:
* web-platform-tests/streams-api/readable-streams/templated-expected.txt:
Source/WebCore:
Reviewed by Darin Adler.
Moving the code that links internal functions to the GlobalObject in WebCoreJSBuiltinInternals.cpp.
This file should be generated by the builtin generator once refactoring is done.
This code is located in JSBuiltinFunctions::initialize.
Moving ReadableStream private constructors and constants code from JSDOMWindowBase to JSDOMGlobalObject.
Calling JSBuiltinInternalFunctions::initialize in JSDOMGlobalObject so that internals are also available in Worker.
Made ReadableStream and relatives exposed in Worker.
Rebased and fixed style by Xabier Rodriguez Calvar.
Covered by rebased tests.
* CMakeLists.txt:
* Modules/streams/ByteLengthQueuingStrategy.idl:
* Modules/streams/CountQueuingStrategy.idl:
* Modules/streams/ReadableStream.idl:
* Modules/streams/ReadableStreamController.idl:
* Modules/streams/ReadableStreamReader.idl:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/JSDOMGlobalObject.cpp:
(WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
(WebCore::JSDOMGlobalObject::addBuiltinGlobals):
(WebCore::JSDOMGlobalObject::finishCreation):
(WebCore::JSDOMGlobalObject::visitChildren):
* bindings/js/JSDOMGlobalObject.h:
* bindings/js/JSDOMWindowBase.cpp:
(WebCore::JSDOMWindowBase::finishCreation): Deleted.
(WebCore::JSDOMWindowBase::visitChildren): Deleted.
* bindings/js/JSDOMWindowBase.h:
* bindings/js/WebCoreJSBuiltinInternals.cpp: Added.
(WebCore::JSBuiltinInternalFunctions::JSBuiltinInternalFunctions):
(WebCore::JSBuiltinInternalFunctions::visit):
(WebCore::JSBuiltinInternalFunctions::initialize):
* bindings/js/WebCoreJSBuiltinInternals.h:
* bindings/js/WebCoreJSBuiltins.h:
LayoutTests:
Reviewed by Darin Adler.
Adding ByteLengthQueuingStrategy, CountQueuingStrategy and ReadableStream as worker constructors.
* js/dom/global-constructors-attributes-dedicated-worker-expected.txt:
* platform/efl/js/dom/global-constructors-attributes-dedicated-worker-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194033
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
clopez@igalia.com [Mon, 14 Dec 2015 13:00:42 +0000 (13:00 +0000)]
[GTK] Unreviewed gardening.
* platform/gtk/TestExpectations: Update TestExpectations with the following changes:
- Remove expectations for tests removed after r193411 r193426 and r19366.
- Merge repeated expectations from some tests.
- Mark tests failing after r188159.
- Update list of imported/blink tests failing.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194032
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
fred.wang@free.fr [Mon, 14 Dec 2015 11:48:48 +0000 (11:48 +0000)]
Move MathMLOperatorDictionary features into a separate module.
https://bugs.webkit.org/show_bug.cgi?id=152242
Reviewed by Martin Robinson.
The definitions, properties and search of the MathML operator dictionary are really independent of the renderer object for math operators.
This patch moves them in a separate module/file to make them more manageable and readable.
No new tests. We already have sufficient test coverage.
* CMakeLists.txt:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* rendering/mathml/MathMLOperatorDictionary.cpp:
(WebCore::ExtractKey):
(WebCore::ExtractChar):
(WebCore::ExtractKeyHorizontal):
(WebCore::MathMLOperatorDictionary::getEntry):
(WebCore::MathMLOperatorDictionary::isVertical):
* rendering/mathml/MathMLOperatorDictionary.h: Added.
* rendering/mathml/RenderMathMLOperator.cpp:
(WebCore::RenderMathMLOperator::setOperatorProperties):
(WebCore::MathMLOperatorDictionary::ExtractKey): Deleted.
(WebCore::MathMLOperatorDictionary::ExtractChar): Deleted.
(WebCore::MathMLOperatorDictionary::ExtractKeyHorizontal): Deleted.
* rendering/mathml/RenderMathMLOperator.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194031
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
svillar@igalia.com [Mon, 14 Dec 2015 10:06:08 +0000 (10:06 +0000)]
[css-grid] Fix height computation of grid items with borders
https://bugs.webkit.org/show_bug.cgi?id=151800
Reviewed by Darin Adler.
Source/WebCore:
When computing the logical height of grid items for the
default "min-height: auto;" case we were constraning the
min-content size using constrainLogicalHeightByMinMax()
instead of constrainContentLogicalHeightByMinMax(). The
problem of using the former is that we were adding the borders
twice.
Test: fast/css-grid-layout/grid-item-with-border-in-intrinsic.html
* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeLogicalHeight):
LayoutTests:
* fast/css-grid-layout/grid-item-with-border-in-intrinsic-expected.txt: Added.
* fast/css-grid-layout/grid-item-with-border-in-intrinsic.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194030
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mattbaker@apple.com [Mon, 14 Dec 2015 07:24:01 +0000 (07:24 +0000)]
Web Inspector: Make TimelineOverview's graph container a subview
https://bugs.webkit.org/show_bug.cgi?id=152235
Reviewed by Brian Burg.
* UserInterface/Views/TimelineOverview.js:
(WebInspector.TimelineOverview):
Create graph container subview.
(WebInspector.TimelineOverview.prototype._instrumentAdded):
Add overview to the graph container view.
(WebInspector.TimelineOverview.prototype._instrumentRemoved):
Remove overview from the graph container view.
(WebInspector.TimelineOverview.prototype.layout):
No longer necessary to manually lay out overview graphs.
(WebInspector.TimelineOverview.prototype._needsLayout): Deleted.
Removed dead code.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194029
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
timothy_horton@apple.com [Mon, 14 Dec 2015 05:27:45 +0000 (05:27 +0000)]
Adopt CGIOSurfaceContextCreateImageReference to avoid unnecessary readback
https://bugs.webkit.org/show_bug.cgi?id=150988
<rdar://problem/
18993594>
Reviewed by Darin Adler.
* platform/graphics/GraphicsContext.cpp:
(WebCore::GraphicsContext::drawConsumingImageBuffer):
* platform/graphics/GraphicsContext.h:
* platform/graphics/ImageBuffer.h:
* platform/graphics/cg/ImageBufferCG.cpp:
(WebCore::createBitmapImageAfterScalingIfNeeded):
(WebCore::ImageBuffer::copyImage):
(WebCore::ImageBuffer::sinkIntoImage):
(WebCore::ImageBuffer::sinkIntoNativeImage):
(WebCore::ImageBuffer::drawConsuming):
* platform/graphics/cocoa/IOSurface.h:
* platform/graphics/cocoa/IOSurface.mm:
(IOSurface::createFromImageBuffer):
(IOSurface::sinkIntoImage):
Add sinkIntoImage, sinkIntoNativeImage, and drawConsuming to ImageBuffer,
which all consume the ImageBuffer and allow us to tell the system to
make a CGImage that references the IOSurface, which is in many cases
more efficient than making an image with a "copy" of the IOSurface.
(The copy is done lazily, but we often hit a corner case that causes
it to happen unnecessarily.)
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
* page/TextIndicator.cpp:
(WebCore::takeSnapshot):
* platform/DragImage.cpp:
(WebCore::createDragImageFromSnapshot):
* platform/graphics/filters/FETile.cpp:
(WebCore::FETile::platformApplySoftware):
* platform/mac/ThemeMac.mm:
(WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext):
* platform/mediastream/mac/AVVideoCaptureSource.mm:
(WebCore::AVVideoCaptureSource::currentFrameImage):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::paintFillLayerExtended):
* rendering/RenderThemeMac.mm:
(WebCore::RenderThemeMac::paintProgressBar):
* rendering/svg/RenderSVGResourcePattern.cpp:
(WebCore::RenderSVGResourcePattern::buildPattern):
* svg/graphics/SVGImage.cpp:
(WebCore::SVGImage::drawPatternForContainer):
Adopt sinkIntoImage and drawConsumingImageBuffer in a few places.
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::imageForCurrentSharingServicePickerItem):
Adopt sinkIntoImage and drawConsumingImageBuffer in a few places.
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::createSelectionSnapshot):
Adopt sinkIntoImage and drawConsumingImageBuffer in a few places.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194025
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Mon, 14 Dec 2015 04:30:37 +0000 (04:30 +0000)]
[JSC] Remove FTL::Output's doubleEqualOrUnordered()
https://bugs.webkit.org/show_bug.cgi?id=152234
Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-13
Reviewed by Sam Weinig.
It is unused, one less thing to worry about.
* ftl/FTLB3Output.h:
(JSC::FTL::Output::doubleEqualOrUnordered): Deleted.
* ftl/FTLOutput.h:
(JSC::FTL::Output::doubleEqualOrUnordered): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194024
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 14 Dec 2015 03:31:46 +0000 (03:31 +0000)]
Another fix after r194018.
* Configurations/BaseTarget.xcconfig:
* Configurations/BaseXPCService.xcconfig:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194023
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 14 Dec 2015 03:19:47 +0000 (03:19 +0000)]
[Mac] Shims used by XPC services are installed inside legacy process bundles
https://bugs.webkit.org/show_bug.cgi?id=152233
Reviewed by Sam Weinig.
Have the shim dylibs installed in the framework’s Frameworks directory instead.
* Configurations/BaseLegacyProcess.xcconfig: Simplified now that EXCLUDED_SHIM_FILE_NAME is
no longer defined, because shims aren’t copied into legacy processes.
* Configurations/NetworkProcess.xcconfig: Removed definition of EXCLUDED_SHIM_FILE_NAME.
* Configurations/PluginProcess.xcconfig: Ditto.
* Configurations/WebContentProcess.xcconfig: Ditto.
* Configurations/Shim.xcconfig: Install the shims when building for OS X. Added definitions
of INSTALL_PATH and DYLIB_INSTALL_NAME_BASE which are now common to all shims.
* Configurations/PluginProcessShim.xcconfig: Removed definitions of INSTALL_PATH and
DYLIB_INSTALL_NAME_BASE from here, now that they are defined for all shims in
Shim.xcconfig.
* Configurations/SecItemShim.xcconfig: Ditto.
* Configurations/WebProcessShim.xcconfig:
* Configurations/WebKit.xcconfig: Added the shims to EXCLUDED_SOURCE_FILE_NAMES for iOS.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-OSX-10.9-10.10.plist: Changed
the value of DYLD_INSERT_LIBRARIES to point to the shim’s new location.
* PluginProcess/EntryPoint/mac/XPCService/PluginService.32-64-10.9-10.10.Info.plist: Ditto.
* WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX-10.9-10.10.plist: Ditto.
* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::computeProcessShimPath): Changed to return the new paths, which are all inside the
framework’s Frameworks directory.
* WebKit2.xcodeproj/project.pbxproj:
- Removed references to WRAPPER_NAME from the “Copy XPC services for engineering builds”
build phase in the All target, becase WRAPPER_NAME is empty in an aggregate target.
- Removed the PlugInProcess target’s dependency on the PluginProcessShim target and its
Copy Plug-in Process Shim build phase.
- Removed the NetworkProcess target’s dependency on the SecItemShim target and its Copy
Sec Item Shim build phase.
- Removed the WebProcess target’s dependency on the WebProcessShim target and its Copy
WebProcessShim build phase.
- Made the WebKit target depend on the shim targets, and added to it a Copy Shims build
phase that copies the shims into the framework’s Frameworks directory.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194022
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
utatane.tea@gmail.com [Mon, 14 Dec 2015 02:52:51 +0000 (02:52 +0000)]
[JSC] Should not emit get_by_id for indexed property access
https://bugs.webkit.org/show_bug.cgi?id=151354
Reviewed by Darin Adler.
Before this patch, `a["1"]` is converted to `a.1` get_by_id operation in the bytecode compiler.
get_by_id emits IC. IC rely on the fact that Structure transition occur when adding / removing object's properties.
However, it's not true for indexed element properties. They are stored in the element storage and Structure transition does not occur.
For example, in the following case,
function getOne(a) { return a['1']; }
for (var i = 0; i < 36; ++i)
getOne({2: true});
if (!getOne({1: true}))
throw new Error("OUT");
In this case, `a['1']` creates get_by_id. `getOne({2: true})` calls makes getOne's get_by_id to create IC says that,
"when comming this structure chain, there is no property in "1", so we should return `undefined`".
After that, we call `getOne({1: true})`. But in this case, `{2: true}` and `{1: true}` have the same structure chain,
because indexed property addition does not occur structure transition.
So previous IC fast path is used and return `undefined`. But the correct answer is returning `true`.
This patch fixes the above issue. When there is string bracket access, we only emits get_by_id if the given string is not an index.
There are bugs in get_by_id, put_by_id, put_by_id (direct). But only get_by_id poses user observable issue.
Because in the put_by_id case, the generic path just says "this put is uncacheable".
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::emitGetById):
(JSC::BytecodeGenerator::emitPutById):
(JSC::BytecodeGenerator::emitDirectPutById):
* bytecompiler/NodesCodegen.cpp:
(JSC::isNonIndexStringElement):
(JSC::BracketAccessorNode::emitBytecode):
(JSC::FunctionCallBracketNode::emitBytecode):
(JSC::AssignBracketNode::emitBytecode):
(JSC::ObjectPatternNode::bindValue):
* tests/stress/element-property-get-should-not-handled-with-get-by-id.js: Added.
(getOne):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194021
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Mon, 14 Dec 2015 00:05:54 +0000 (00:05 +0000)]
Build fix.
* Configurations/PluginProcess.xcconfig:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194019
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mitz@apple.com [Sun, 13 Dec 2015 23:21:35 +0000 (23:21 +0000)]
[Mac] Shims aren’t inserted properly on Yosemite when building with the El Capitan SDK
https://bugs.webkit.org/show_bug.cgi?id=152229
Reviewed by Darin Adler.
* Configurations/BaseTarget.xcconfig: Defined WK_LINK_SHIM on OS X to YES or NO based on the
target version.
* Configurations/BaseXPCService.xcconfig: Define WK_XPC_SERVICE_INFOPLIST_SUFFIX to
"-10.9-10.10" when targeting those OS X versions.
* Configurations/NetworkService.xcconfig: Use WK_XPC_SERVICE_INFOPLIST_SUFFIX in the
definition of INFOPLIST_FILE. Use WK_LINK_SHIM in the definition of OTHER_LDFLAGS.
* Configurations/PluginProcess.xcconfig: Use WK_LINK_SHIM in the definition of
LDFLAGS_SHIM_Production for OS X.
* Configurations/PluginService.32.xcconfig: Use WK_XPC_SERVICE_INFOPLIST_SUFFIX in the
definition of INFOPLIST_FILE. Use WK_LINK_SHIM in the definition of OTHER_LDFLAGS.
* Configurations/PluginService.64.xcconfig: Ditto.
* Configurations/WebContentService.xcconfig: Ditto.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194018
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
akling@apple.com [Sun, 13 Dec 2015 20:03:24 +0000 (20:03 +0000)]
CachedScript could have a copy-free path for all-ASCII scripts.
<https://webkit.org/b/152203>
Source/JavaScriptCore:
Reviewed by Antti Koivisto.
Make SourceProvider vend a StringView instead of a String.
This relaxes the promises that providers have to make about string lifetimes.
This means that on the WebCore side, CachedScript is free to cache a String
internally, while only ever exposing it as a temporary StringView.
A few extra copies (CPU, not memory) are introduced, none of them on hot paths.
* API/JSScriptRef.cpp:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::sourceCodeForTools):
(JSC::CodeBlock::dumpSource):
* inspector/ScriptDebugServer.cpp:
(Inspector::ScriptDebugServer::dispatchDidParseSource):
(Inspector::ScriptDebugServer::dispatchFailedToParseSource):
* interpreter/Interpreter.cpp:
(JSC::Interpreter::execute):
* jsc.cpp:
(functionFindTypeForExpression):
(functionHasBasicBlockExecuted):
(functionBasicBlockExecutionCount):
* parser/Lexer.cpp:
(JSC::Lexer<T>::setCode):
* parser/Lexer.h:
(JSC::Lexer<LChar>::setCodeStart):
(JSC::Lexer<UChar>::setCodeStart):
* parser/Parser.h:
(JSC::Parser::getToken):
* parser/SourceCode.cpp:
(JSC::SourceCode::toUTF8):
* parser/SourceCode.h:
(JSC::SourceCode::hash):
(JSC::SourceCode::view):
(JSC::SourceCode::toString): Deleted.
* parser/SourceCodeKey.h:
(JSC::SourceCodeKey::SourceCodeKey):
(JSC::SourceCodeKey::string):
* parser/SourceProvider.h:
(JSC::SourceProvider::getRange):
* runtime/Completion.cpp:
(JSC::loadAndEvaluateModule):
(JSC::loadModule):
* runtime/ErrorInstance.cpp:
(JSC::appendSourceToError):
* runtime/FunctionPrototype.cpp:
(JSC::functionProtoFuncToString):
* tools/FunctionOverrides.cpp:
(JSC::initializeOverrideInfo):
(JSC::FunctionOverrides::initializeOverrideFor):
Source/WebCore:
Reviewed by ANtti Koivisto.
Many (if not most) of script resources on the web contain nothing but ASCII characters.
Such resources, when streamed through a text decoder, will yield the exact same byte
sequence, except in anonymous heap memory instead of delicious file-backed pages.
Care is taken to ensure that the wrapper StringImpl is updated to target newly cached
resource data if an asynchronous caching notification comes in.
* loader/cache/CachedResource.cpp:
(WebCore::CachedResource::tryReplaceEncodedData):
* loader/cache/CachedResource.h:
(WebCore::CachedResource::didReplaceSharedBufferContents):
* loader/cache/CachedScript.cpp:
(WebCore::encodingMayBeAllASCII):
(WebCore::CachedScript::script):
(WebCore::CachedScript::didReplaceSharedBufferContents):
* loader/cache/CachedScript.h:
* platform/SharedBuffer.h:
* platform/cf/SharedBufferCF.cpp:
(WebCore::SharedBuffer::tryReplaceContentsWithPlatformBuffer):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194017
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Sun, 13 Dec 2015 16:18:07 +0000 (16:18 +0000)]
Clean up absolute positioned map properly.
https://bugs.webkit.org/show_bug.cgi?id=152219
rdar://problem/
23861165
Reviewed by Simon Fraser.
We insert positioned renderers into a static map (RenderBlock::gPositionedDescendantsMap) to keep track of them.
Since this static map is at block level, (positioned)inline renderers use their containing block to store
their positioned descendants.
This patch ensures that when an inline element can no longer hold positioned children, we remove them from
the inline's containing block's map. -unless the container itself can hold positioned renderers(see RenderElement::canContainAbsolutelyPositionedObjects).
Source/WebCore:
Test: fast/block/positioning/crash-when-positioned-inline-has-positioned-child.html
* rendering/RenderInline.cpp:
(WebCore::RenderInline::styleWillChange):
* rendering/RenderInline.h:
LayoutTests:
* fast/block/positioning/crash-when-positioned-inline-has-positioned-child-expected.txt: Added.
* fast/block/positioning/crash-when-positioned-inline-has-positioned-child.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194016
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jdiggs@igalia.com [Sun, 13 Dec 2015 14:07:40 +0000 (14:07 +0000)]
AX: [EFL] Anonymous render block flow elements should be exposed as ATK_ROLE_SECTION; not ATK_ROLE_PANEL
https://bugs.webkit.org/show_bug.cgi?id=152079
Reviewed by Chris Fleizach.
Source/WebCore:
Map the element to WebCore AccessibilityRole DivRole for EFL. As with GTK, this
is being done in the shared layer rather than in the platform layer because we
want all subsequent logic to treat anonymous render block flow elements as divs.
No new tests. We already have sufficient test coverage. The expectations
been updated accordingly.
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::determineAccessibilityRole):
LayoutTests:
* platform/efl/accessibility/deleting-iframe-destroys-axcache-expected.txt: Added.
* platform/efl/accessibility/image-link-expected.txt: Updated.
* platform/efl/accessibility/image-with-alt-and-map-expected.txt: Updated.
* platform/efl/accessibility/lists-expected.txt: Updated.
* platform/efl/accessibility/media-element-expected.txt: Updated
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194015
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
beidson@apple.com [Sun, 13 Dec 2015 08:25:40 +0000 (08:25 +0000)]
Modern IDB: TextExpectations gardening to run more tests.
https://bugs.webkit.org/show_bug.cgi?id=152217
Reviewed by Alex Christensen.
* platform/mac-wk1/TestExpectations: 5 crash/timeout tests now either pass or merely have text failures.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194014
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mattbaker@apple.com [Sun, 13 Dec 2015 05:09:44 +0000 (05:09 +0000)]
Web Inspector: CodeMirrorTokenTrackingController handles symbols in class definitions incorrectly
https://bugs.webkit.org/show_bug.cgi?id=152218
Reviewed by Timothy Hatcher.
* UserInterface/Controllers/CodeMirrorTokenTrackingController.js:
(WebInspector.CodeMirrorTokenTrackingController.prototype._processJavaScriptExpression):
Stop checking for object literal shorthand property if an open parenthesis is found.
This check became necessary with the introduction of ES6 class syntax.
* UserInterface/Views/CodeMirrorAdditions.js:
Use localState when available, to prevent passing a state that doesn't define a tokenize property.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194013
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
beidson@apple.com [Sat, 12 Dec 2015 23:49:46 +0000 (23:49 +0000)]
Modern IDB: Update a couple of tests that fail only because of error message differences.
https://bugs.webkit.org/show_bug.cgi?id=152205
Reviewed by Alex Christensen.
* platform/mac-wk1/TestExpectations:
* storage/indexeddb/objectstore-autoincrement-expected.txt:
* storage/indexeddb/open-cursor-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194012
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
benjamin@webkit.org [Sat, 12 Dec 2015 23:04:54 +0000 (23:04 +0000)]
[JSC] Add lowering for B3's Store8 opcode
https://bugs.webkit.org/show_bug.cgi?id=152208
Reviewed by Geoffrey Garen.
B3 has an opcode to store 8bit values but it had
no lowering.
* b3/B3LowerToAir.cpp:
(JSC::B3::Air::LowerToAir::createStore):
(JSC::B3::Air::LowerToAir::lower):
* b3/air/AirOpcode.opcodes:
* b3/testb3.cpp:
(JSC::B3::testStore8Arg):
(JSC::B3::testStore8Imm):
(JSC::B3::testStorePartial8BitRegisterOnX86):
(JSC::B3::run):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194011
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
beidson@apple.com [Sat, 12 Dec 2015 22:03:09 +0000 (22:03 +0000)]
Modern IDB: storage/indexeddb/index-duplicate-keypaths.html fails.
https://bugs.webkit.org/show_bug.cgi?id=152201
Reviewed by Alex Christensen.
Source/WebCore:
No new tests (At least one failing test now passes).
The spec states that if an object store uses a key generator, and then a record is stored whose
key was an explicitly set number, then the key generator value should be bumped to the next
integer higher than the explicit number.
We didn't do that.
Now we do.
* Modules/indexeddb/IndexedDB.h: Add an "OverwriteForCursor" option for overwrite mode.
* Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
(WebCore::IDBClient::IDBObjectStore::putForCursorUpdate): Use the "OverwriteForCursor" mode.
* Modules/indexeddb/server/IDBBackingStore.h: Add maybeUpdateKeyGeneratorNumber
* Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
(WebCore::IDBServer::MemoryIDBBackingStore::maybeUpdateKeyGeneratorNumber): If the number value
from the provided key should bump the key generator value, do so now.
* Modules/indexeddb/server/MemoryIDBBackingStore.h:
* Modules/indexeddb/server/UniqueIDBDatabase.cpp:
(WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd): After successfully adding the new record,
possibly bump the key generator value.
LayoutTests:
* platform/mac-wk1/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194010
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Sat, 12 Dec 2015 17:37:35 +0000 (17:37 +0000)]
REGRESSION (r191613): Web Inspector: Can't type spaces when editing DOM nodes
https://bugs.webkit.org/show_bug.cgi?id=152173
Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-12-12
Reviewed by Timothy Hatcher.
* UserInterface/Views/TimelineSidebarPanel.js:
(WebInspector.TimelineSidebarPanel):
Disable the keyboard shortcuts when they are created. They will be
enabled when the panel is shown / hidden. It doesn't really make sense
that these are on the sidebar panel instead of the tab, but things
will be changing in Timelines soon anyways so just fix this now.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194009
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
nvasilyev@apple.com [Sat, 12 Dec 2015 17:32:15 +0000 (17:32 +0000)]
Web Inspector: "Selected Element" should use sans-serif font, not monospace
https://bugs.webkit.org/show_bug.cgi?id=152212
Reviewed by Timothy Hatcher.
* UserInterface/Views/ConsoleMessageView.css:
(.console-user-command.special-user-log > .console-message-text):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194008
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
ossy@webkit.org [Sat, 12 Dec 2015 11:21:49 +0000 (11:21 +0000)]
[ARM] Add the missing setupArgumentsWithExecState functions after r193974
https://bugs.webkit.org/show_bug.cgi?id=152214
Reviewed by Mark Lam.
* jit/CCallHelpers.h:
(JSC::CCallHelpers::setupArgumentsWithExecState):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194007
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Sat, 12 Dec 2015 09:26:42 +0000 (09:26 +0000)]
Safari background tabs should be fully suspended where possible.
https://bugs.webkit.org/show_bug.cgi?id=150515
Patch by Katlyn Graff <kgraff@apple.com> on 2015-12-12
Reviewed by Ryosuke Niwa.
Source/WebCore:
Support for tab suspension for Mac, enabled by defaults writing to WebKitTabSuspension.
Page-down suspension consolidated with PageCache suspension code in Document::
suspend and Document::resume. Pages canTabSuspend if cacheable, nonvisible, nonprerender,
and nonactive.
* dom/Document.cpp: moved scrollbar handling from setInPageCache to suspend/resume
(WebCore::Document::suspend): moved scrollbar, dom, animation, timer, and visual update suspending into here
(WebCore::Document::resume): moved scrollbar, dom, animation, timer, and visual update resuming into here
* dom/Document.h: added m_isSuspended to prevent repeat calls from PageCache/Tab Suspension contention
* history/CachedFrame.cpp: moved dom, animation, and timer suspension into Document::suspend
(WebCore::CachedFrame::CachedFrame):
* history/PageCache.cpp: Added a few nullchecks to prevent crashes if canCacheFrame is called but document is null
(WebCore::PageCache::canCacheFrame):
* page/Page.cpp:
(WebCore::Page::Page): Added timer to fire delayed suspension
(WebCore::Page::setPageActivityState): Added a call to schedule tab suspension
(WebCore::Page::setIsVisibleInternal): Added a call to schedule tab suspension
(WebCore::Page::canTabSuspend): Added support for suspending if cacheable, nonvisible, nonprerender, and nonactive
(WebCore::Page::setIsTabSuspended): Added a function to suspend or resume tabs
(WebCore::Page::setTabSuspensionEnabled): Added support for a defaults write enable
(WebCore::Page::scheduleTabSuspension): Added ability to schedule the suspension timer to fire or resume
(WebCore::Page::timerFired): Added a suspension timer
* page/Page.h:
* page/PageThrottler.h:
(WebCore::PageThrottler::activityState): Added access to m_activityState for canTabSuspend
Source/WebKit2:
Added a runtime flag enabling tab suspension, default off.
* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
(WebKit::WebProcessCreationParameters::encode):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::registerUserDefaultsIfNeeded):
(WebKit::WebProcessPool::platformInitializeWebProcess):
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::platformInitializeWebProcess):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194006
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
joepeck@webkit.org [Sat, 12 Dec 2015 07:44:07 +0000 (07:44 +0000)]
Web Inspector: Too many derefs when RemoteInspectorXPCConnection fails to validate connection
https://bugs.webkit.org/show_bug.cgi?id=152213
Rubber-stamped by Ryosuke Niwa.
* inspector/remote/RemoteInspectorXPCConnection.mm:
(Inspector::RemoteInspectorXPCConnection::handleEvent):
We should just close the XPC connection triggering XPC_ERROR_CONNECTION_INVALID
which will then graceful teardown the connection as expected.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194005
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
simon.fraser@apple.com [Sat, 12 Dec 2015 06:58:15 +0000 (06:58 +0000)]
Mousewheel events don't work in iframes in RTL documents
https://bugs.webkit.org/show_bug.cgi?id=152200
Reviewed by Beth Dakin.
Source/WebCore:
When dispatching wheel events, the testing of the event point against the
non-fast scrollable region was broken in an RTL document. Fix by taking
the scrollOrigin into account in ScrollingTreeFrameScrollingNode::viewToContentsOffset().
Test: fast/scrolling/rtl-point-in-iframe.html
* page/scrolling/ScrollingTreeFrameScrollingNode.cpp:
(WebCore::ScrollingTreeFrameScrollingNode::viewToContentsOffset):
LayoutTests:
Try dispatching wheel events to an iframe in an RTL document.
* fast/scrolling/rtl-point-in-iframe-expected.txt: Added.
* fast/scrolling/rtl-point-in-iframe.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194004
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
commit-queue@webkit.org [Sat, 12 Dec 2015 06:10:07 +0000 (06:10 +0000)]
[JSC] Add Floating Point Abs() to B3
https://bugs.webkit.org/show_bug.cgi?id=152176
Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-12-11
Reviewed by Geoffrey Garen.
This patch adds an Abs() operation for floating point.
On x86, Abs() is implemented by masking the top bit
of the floating point value. On ARM64, there is a builtin
abs opcode.
To account for those differences, B3 use "Abs" as
the cannonical operation. When we are about to lower
to Air, Abs is extended on x86 to get a clean handling
of the mask constants.
This patch has one cool thing related to FTL.
If you do:
@1 = unboxDouble(@0)
@2 = abs(@1)
@3 = boxDouble(@2)
B3ReduceStrength completely eliminate the Double-Integer
conversion.
The strength reduction of Abs is aware that it can do a bit
mask over the bitcast used by unboxing.
If even works if you use floats by forcing fround: reduceDoubleToFloat()
elminiates the useless conversions, followed by ReduceStrength
that removes the switch from GP to FP.
* CMakeLists.txt:
* JavaScriptCore.xcodeproj/project.pbxproj:
* assembler/MacroAssemblerX86Common.h:
(JSC::MacroAssemblerX86Common::andDouble):
(JSC::MacroAssemblerX86Common::andFloat):
* assembler/X86Assembler.h:
(JSC::X86Assembler::andps_rr):
* b3/B3ConstDoubleValue.cpp:
(JSC::B3::ConstDoubleValue::bitAndConstant):
(JSC::B3::ConstDoubleValue::absConstant):
* b3/B3ConstDoubleValue.h:
* b3/B3ConstFloatValue.cpp:
(JSC::B3::ConstFloatValue::bitAndConstant):
(JSC::B3::ConstFloatValue::absConstant):
* b3/B3ConstFloatValue.h:
* b3/B3Generate.cpp:
(JSC::B3::generateToAir):
* b3/B3LowerMacrosAfterOptimizations.cpp: Added.
(JSC::B3::lowerMacrosAfterOptimizations):
* b3/B3LowerMacrosAfterOptimizations.h: Added.
* b3/B3LowerToAir.cpp:
(JSC::B3::Air::LowerToAir::lower):
* b3/B3Opcode.cpp:
(WTF::printInternal):
* b3/B3Opcode.h:
* b3/B3ReduceDoubleToFloat.cpp:
* b3/B3ReduceStrength.cpp:
* b3/B3Validate.cpp:
* b3/B3Value.cpp:
(JSC::B3::Value::absConstant):
(JSC::B3::Value::effects):
(JSC::B3::Value::key):
(JSC::B3::Value::typeFor):
* b3/B3Value.h:
* b3/air/AirOpcode.opcodes:
* b3/testb3.cpp:
(JSC::B3::bitAndDouble):
(JSC::B3::testBitAndArgDouble):
(JSC::B3::testBitAndArgsDouble):
(JSC::B3::testBitAndArgImmDouble):
(JSC::B3::testBitAndImmsDouble):
(JSC::B3::bitAndFloat):
(JSC::B3::testBitAndArgFloat):
(JSC::B3::testBitAndArgsFloat):
(JSC::B3::testBitAndArgImmFloat):
(JSC::B3::testBitAndImmsFloat):
(JSC::B3::testBitAndArgsFloatWithUselessDoubleConversion):
(JSC::B3::testAbsArg):
(JSC::B3::testAbsImm):
(JSC::B3::testAbsMem):
(JSC::B3::testAbsAbsArg):
(JSC::B3::testAbsBitwiseCastArg):
(JSC::B3::testBitwiseCastAbsBitwiseCastArg):
(JSC::B3::testAbsArgWithUselessDoubleConversion):
(JSC::B3::testAbsArgWithEffectfulDoubleConversion):
(JSC::B3::run):
* ftl/FTLB3Output.h:
(JSC::FTL::Output::doubleAbs):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194003
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
zalan@apple.com [Sat, 12 Dec 2015 03:26:36 +0000 (03:26 +0000)]
ASSERTION FAILED: !rect.isEmpty() in WebCore::GraphicsContext::drawRect
https://bugs.webkit.org/show_bug.cgi?id=151201
Reviewed by Simon Fraser.
Drawing empty rect is a waste.
Source/WebCore:
Test: fast/borders/empty-drawrect-assert-after-pixelsnap.html
* rendering/RenderElement.cpp:
(WebCore::RenderElement::drawLineForBoxSide):
LayoutTests:
* fast/borders/empty-drawrect-assert-after-pixelsnap-expected.txt: Added.
* fast/borders/empty-drawrect-assert-after-pixelsnap.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194002
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jiewen_tan@apple.com [Sat, 12 Dec 2015 02:26:45 +0000 (02:26 +0000)]
Strip out Referer header when requesting subresources or following links for documents with "Content-Disposition: attachment"
https://bugs.webkit.org/show_bug.cgi?id=152102
<rdar://problem/
22124230>
Reviewed by Andy Estes.
Source/WebCore:
Keep the ReferrerPolicy for a document as ReferrerPolicyNever if the document is loaded with
"Content-Disposition: attachment".
Test: http/tests/contentdispositionattachmentsandbox/subresource-request-not-include-referer-header.html
* dom/Document.cpp:
(WebCore::Document::processReferrerPolicy):
(WebCore::Document::applyContentDispositionAttachmentSandbox):
LayoutTests:
* http/tests/contentdispositionattachmentsandbox/resources/echo-http-referer.php: Added.
* http/tests/contentdispositionattachmentsandbox/resources/subresource-request-not-include-referer-header-frame.php: Added.
* http/tests/contentdispositionattachmentsandbox/subresource-request-not-include-referer-header-expected.txt: Added.
* http/tests/contentdispositionattachmentsandbox/subresource-request-not-include-referer-header.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194001
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
eric.carlson@apple.com [Sat, 12 Dec 2015 01:52:43 +0000 (01:52 +0000)]
[MediaStream] Add a setting to allow the mock media capture devices to be enabled and disabled
https://bugs.webkit.org/show_bug.cgi?id=152197
Reviewed by Dean Jackson.
Source/WebCore:
Test: fast/mediastream/mock-media-source.html
* page/Settings.cpp:
(WebCore::Settings::mockCaptureDevicesEnabled):
(WebCore::Settings::setMockCaptureDevicesEnabled):
* page/Settings.h:
* platform/mediastream/RealtimeMediaSourceCenter.cpp:
(WebCore::RealtimeMediaSourceCenter::setSharedStreamCenterOverride): Renamed.
(WebCore::RealtimeMediaSourceCenter::setSharedStreamCenter): Deleted.
* platform/mediastream/RealtimeMediaSourceCenter.h:
* platform/mock/MockRealtimeMediaSourceCenter.cpp:
(WebCore::MockRealtimeMediaSourceCenter::setMockRealtimeMediaSourceCenterEnabled): Renamed. Allow
it to be enabled and disabled.
(WebCore::MockRealtimeMediaSourceCenter::registerMockRealtimeMediaSourceCenter): Deleted.
* platform/mock/MockRealtimeMediaSourceCenter.h:
* testing/Internals.cpp:
(WebCore::Internals::Internals):
(WebCore::Internals::setMockMediaCaptureDevicesEnabled):
* testing/Internals.h:
* testing/Internals.idl:
Source/WebKit/mac:
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.mm:
(+[WebPreferences initialize]):
(-[WebPreferences mockCaptureDevicesEnabled]):
(-[WebPreferences setMockCaptureDevicesEnabled:]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _preferencesChanged:]):
Source/WebKit2:
* Shared/WebPreferencesDefinitions.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetMockCaptureDevicesEnabled):
(WKPreferencesGetMockCaptureDevicesEnabled):
* UIProcess/API/C/WKPreferencesRefPrivate.h:
* UIProcess/API/Cocoa/WKPreferences.mm:
(-[WKPreferences _mockCaptureDevicesEnabled]):
(-[WKPreferences _setMockCaptureDevicesEnabled:]):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences):
LayoutTests:
* fast/mediastream/mock-media-source-expected.txt: Added.
* fast/mediastream/mock-media-source.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194000
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
jer.noble@apple.com [Sat, 12 Dec 2015 01:46:55 +0000 (01:46 +0000)]
[EME] Do not pass in the initialization data to AVContentKeyRequest as the contentIdentifier.
https://bugs.webkit.org/show_bug.cgi?id=152204
rdar://problem/
23867877
Reviewed by Eric Carlson.
The AVContentKeyRequest API has been updated to no longer require a contentId parameter if the
ID can be derived from the initialization data.
* platform/graphics/avfoundation/objc/CDMSessionAVContentKeySession.mm:
(WebCore::CDMSessionAVContentKeySession::update):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@193999
268f45cc-cd09-0410-ab3c-
d52691b4dbfc