1. 15 Aug, 2013 35 commits
    • fpizlo@apple.com's avatar
      Typed arrays should be rewritten · 0e0d9312
      fpizlo@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119064
      
      .: 
      
      Reviewed by Oliver Hunt.
      
      Automake work courtesy of Zan Dobersek <zdobersek@igalia.com>.
      
      * Source/autotools/symbols.filter:
      
      Source/JavaScriptCore: 
      
      Reviewed by Oliver Hunt.
              
      Typed arrays were previously deficient in several major ways:
              
      - They were defined separately in WebCore and in the jsc shell. The two
        implementations were different, and the jsc shell one was basically wrong.
        The WebCore one was quite awful, also.
              
      - Typed arrays were not visible to the JIT except through some weird hooks.
        For example, the JIT could not ask "what is the Structure that this typed
        array would have if I just allocated it from this global object". Also,
        it was difficult to wire any of the typed array intrinsics, because most
        of the functionality wasn't visible anywhere in JSC.
              
      - Typed array allocation was brain-dead. Allocating a typed array involved
        two JS objects, two GC weak handles, and three malloc allocations.
              
      - Neutering. It involved keeping tabs on all native views but not the view
        wrappers, even though the native views can autoneuter just by asking the
        buffer if it was neutered anytime you touch them; while the JS view
        wrappers are the ones that you really want to reach out to.
              
      - Common case-ing. Most typed arrays have one buffer and one view, and
        usually nobody touches the buffer. Yet we created all of that stuff
        anyway, using data structures optimized for the case where you had a lot
        of views.
              
      - Semantic goofs. Typed arrays should, in the future, behave like ES
        features rather than DOM features, for example when it comes to exceptions.
        Firefox already does this and I agree with them.
              
      This patch cleanses our codebase of these sins:
              
      - Typed arrays are almost entirely defined in JSC. Only the lifecycle
        management of native references to buffers is left to WebCore.
              
      - Allocating a typed array requires either two GC allocations (a cell and a
        copied storage vector) or one GC allocation, a malloc allocation, and a
        weak handle (a cell and a malloc'd storage vector, plus a finalizer for the
        latter). The latter is only used for oversize arrays. Remember that before
        it was 7 allocations no matter what.
              
      - Typed arrays require just 4 words of overhead: Structure*, Butterfly*,
        mode/length, void* vector. Before it was a lot more than that - remember,
        there were five additional objects that did absolutely nothing for anybody.
              
      - Native views aren't tracked by the buffer, or by the wrappers. They are
        transient. In the future we'll probably switch to not even having them be
        malloc'd.
              
      - Native array buffers have an efficient way of tracking all of their JS view
        wrappers, both for neutering, and for lifecycle management. The GC
        special-cases native array buffers. This saves a bunch of grief; for example
        it means that a JS view wrapper can refer to its buffer via the butterfly,
        which would be dead by the time we went to finalize.
              
      - Typed array semantics now match Firefox, which also happens to be where the
        standards are going. The discussion on webkit-dev seemed to confirm that
        Chrome is also heading in this direction. This includes making
        Uint8ClampedArray not a subtype of Uint8Array, and getting rid of
        ArrayBufferView as a JS-visible construct.
              
      This is up to a 10x speed-up on programs that allocate a lot of typed arrays.
      It's a 1% speed-up on Octane. It also opens up a bunch of possibilities for
      further typed array optimizations in the JSC JITs, including inlining typed
      array allocation, inlining more of the accessors, reducing the cost of type
      checks, etc.
              
      An additional property of this patch is that typed arrays are mostly
      implemented using templates. This deduplicates a bunch of code, but does mean
      that we need some hacks for exporting s_info's of template classes. See
      JSGenericTypedArrayView.h and JSTypedArrays.cpp. Those hacks are fairly
      low-impact compared to code duplication.
              
      Automake work courtesy of Zan Dobersek <zdobersek@igalia.com>.
      
      * CMakeLists.txt:
      * DerivedSources.make:
      * GNUmakefile.list.am:
      * JSCTypedArrayStubs.h: Removed.
      * JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
      * JavaScriptCore.xcodeproj/project.pbxproj:
      * Target.pri:
      * bytecode/ByValInfo.h:
      (JSC::hasOptimizableIndexingForClassInfo):
      (JSC::jitArrayModeForClassInfo):
      (JSC::typedArrayTypeForJITArrayMode):
      * bytecode/SpeculatedType.cpp:
      (JSC::speculationFromClassInfo):
      * dfg/DFGArrayMode.cpp:
      (JSC::DFG::toTypedArrayType):
      * dfg/DFGArrayMode.h:
      (JSC::DFG::ArrayMode::typedArrayType):
      * dfg/DFGSpeculativeJIT.cpp:
      (JSC::DFG::SpeculativeJIT::checkArray):
      (JSC::DFG::SpeculativeJIT::compileGetByValOnIntTypedArray):
      (JSC::DFG::SpeculativeJIT::compilePutByValForIntTypedArray):
      (JSC::DFG::SpeculativeJIT::compileGetByValOnFloatTypedArray):
      (JSC::DFG::SpeculativeJIT::compilePutByValForFloatTypedArray):
      (JSC::DFG::SpeculativeJIT::compileGetIndexedPropertyStorage):
      (JSC::DFG::SpeculativeJIT::compileGetArrayLength):
      * dfg/DFGSpeculativeJIT.h:
      * dfg/DFGSpeculativeJIT32_64.cpp:
      (JSC::DFG::SpeculativeJIT::compile):
      * dfg/DFGSpeculativeJIT64.cpp:
      (JSC::DFG::SpeculativeJIT::compile):
      * heap/CopyToken.h:
      * heap/DeferGC.h:
      (JSC::DeferGCForAWhile::DeferGCForAWhile):
      (JSC::DeferGCForAWhile::~DeferGCForAWhile):
      * heap/GCIncomingRefCounted.h: Added.
      (JSC::GCIncomingRefCounted::GCIncomingRefCounted):
      (JSC::GCIncomingRefCounted::~GCIncomingRefCounted):
      (JSC::GCIncomingRefCounted::numberOfIncomingReferences):
      (JSC::GCIncomingRefCounted::incomingReferenceAt):
      (JSC::GCIncomingRefCounted::singletonFlag):
      (JSC::GCIncomingRefCounted::hasVectorOfCells):
      (JSC::GCIncomingRefCounted::hasAnyIncoming):
      (JSC::GCIncomingRefCounted::hasSingleton):
      (JSC::GCIncomingRefCounted::singleton):
      (JSC::GCIncomingRefCounted::vectorOfCells):
      * heap/GCIncomingRefCountedInlines.h: Added.
      (JSC::::addIncomingReference):
      (JSC::::filterIncomingReferences):
      * heap/GCIncomingRefCountedSet.h: Added.
      (JSC::GCIncomingRefCountedSet::size):
      * heap/GCIncomingRefCountedSetInlines.h: Added.
      (JSC::::GCIncomingRefCountedSet):
      (JSC::::~GCIncomingRefCountedSet):
      (JSC::::addReference):
      (JSC::::sweep):
      (JSC::::removeAll):
      (JSC::::removeDead):
      * heap/Heap.cpp:
      (JSC::Heap::addReference):
      (JSC::Heap::extraSize):
      (JSC::Heap::size):
      (JSC::Heap::capacity):
      (JSC::Heap::collect):
      (JSC::Heap::decrementDeferralDepth):
      (JSC::Heap::decrementDeferralDepthAndGCIfNeeded):
      * heap/Heap.h:
      * interpreter/CallFrame.h:
      (JSC::ExecState::dataViewTable):
      * jit/JIT.h:
      * jit/JITPropertyAccess.cpp:
      (JSC::JIT::privateCompileGetByVal):
      (JSC::JIT::privateCompilePutByVal):
      (JSC::JIT::emitIntTypedArrayGetByVal):
      (JSC::JIT::emitFloatTypedArrayGetByVal):
      (JSC::JIT::emitIntTypedArrayPutByVal):
      (JSC::JIT::emitFloatTypedArrayPutByVal):
      * jsc.cpp:
      (GlobalObject::finishCreation):
      * runtime/ArrayBuffer.cpp:
      (JSC::ArrayBuffer::transfer):
      * runtime/ArrayBuffer.h:
      (JSC::ArrayBuffer::createAdopted):
      (JSC::ArrayBuffer::ArrayBuffer):
      (JSC::ArrayBuffer::gcSizeEstimateInBytes):
      (JSC::ArrayBuffer::pin):
      (JSC::ArrayBuffer::unpin):
      (JSC::ArrayBufferContents::tryAllocate):
      * runtime/ArrayBufferView.cpp:
      (JSC::ArrayBufferView::ArrayBufferView):
      (JSC::ArrayBufferView::~ArrayBufferView):
      (JSC::ArrayBufferView::setNeuterable):
      * runtime/ArrayBufferView.h:
      (JSC::ArrayBufferView::isNeutered):
      (JSC::ArrayBufferView::buffer):
      (JSC::ArrayBufferView::baseAddress):
      (JSC::ArrayBufferView::byteOffset):
      (JSC::ArrayBufferView::verifySubRange):
      (JSC::ArrayBufferView::clampOffsetAndNumElements):
      (JSC::ArrayBufferView::calculateOffsetAndLength):
      * runtime/ClassInfo.h:
      * runtime/CommonIdentifiers.h:
      * runtime/DataView.cpp: Added.
      (JSC::DataView::DataView):
      (JSC::DataView::create):
      (JSC::DataView::wrap):
      * runtime/DataView.h: Added.
      (JSC::DataView::byteLength):
      (JSC::DataView::getType):
      (JSC::DataView::get):
      (JSC::DataView::set):
      * runtime/Float32Array.h:
      * runtime/Float64Array.h:
      * runtime/GenericTypedArrayView.h: Added.
      (JSC::GenericTypedArrayView::data):
      (JSC::GenericTypedArrayView::set):
      (JSC::GenericTypedArrayView::setRange):
      (JSC::GenericTypedArrayView::zeroRange):
      (JSC::GenericTypedArrayView::zeroFill):
      (JSC::GenericTypedArrayView::length):
      (JSC::GenericTypedArrayView::byteLength):
      (JSC::GenericTypedArrayView::item):
      (JSC::GenericTypedArrayView::checkInboundData):
      (JSC::GenericTypedArrayView::getType):
      * runtime/GenericTypedArrayViewInlines.h: Added.
      (JSC::::GenericTypedArrayView):
      (JSC::::create):
      (JSC::::createUninitialized):
      (JSC::::subarray):
      (JSC::::wrap):
      * runtime/IndexingHeader.h:
      (JSC::IndexingHeader::arrayBuffer):
      (JSC::IndexingHeader::setArrayBuffer):
      * runtime/Int16Array.h:
      * runtime/Int32Array.h:
      * runtime/Int8Array.h:
      * runtime/JSArrayBuffer.cpp: Added.
      (JSC::JSArrayBuffer::JSArrayBuffer):
      (JSC::JSArrayBuffer::finishCreation):
      (JSC::JSArrayBuffer::create):
      (JSC::JSArrayBuffer::createStructure):
      (JSC::JSArrayBuffer::getOwnPropertySlot):
      (JSC::JSArrayBuffer::getOwnPropertyDescriptor):
      (JSC::JSArrayBuffer::put):
      (JSC::JSArrayBuffer::defineOwnProperty):
      (JSC::JSArrayBuffer::deleteProperty):
      (JSC::JSArrayBuffer::getOwnNonIndexPropertyNames):
      * runtime/JSArrayBuffer.h: Added.
      (JSC::JSArrayBuffer::impl):
      (JSC::toArrayBuffer):
      * runtime/JSArrayBufferConstructor.cpp: Added.
      (JSC::JSArrayBufferConstructor::JSArrayBufferConstructor):
      (JSC::JSArrayBufferConstructor::finishCreation):
      (JSC::JSArrayBufferConstructor::create):
      (JSC::JSArrayBufferConstructor::createStructure):
      (JSC::constructArrayBuffer):
      (JSC::JSArrayBufferConstructor::getConstructData):
      (JSC::JSArrayBufferConstructor::getCallData):
      * runtime/JSArrayBufferConstructor.h: Added.
      * runtime/JSArrayBufferPrototype.cpp: Added.
      (JSC::arrayBufferProtoFuncSlice):
      (JSC::JSArrayBufferPrototype::JSArrayBufferPrototype):
      (JSC::JSArrayBufferPrototype::finishCreation):
      (JSC::JSArrayBufferPrototype::create):
      (JSC::JSArrayBufferPrototype::createStructure):
      * runtime/JSArrayBufferPrototype.h: Added.
      * runtime/JSArrayBufferView.cpp: Added.
      (JSC::JSArrayBufferView::ConstructionContext::ConstructionContext):
      (JSC::JSArrayBufferView::JSArrayBufferView):
      (JSC::JSArrayBufferView::finishCreation):
      (JSC::JSArrayBufferView::getOwnPropertySlot):
      (JSC::JSArrayBufferView::getOwnPropertyDescriptor):
      (JSC::JSArrayBufferView::put):
      (JSC::JSArrayBufferView::defineOwnProperty):
      (JSC::JSArrayBufferView::deleteProperty):
      (JSC::JSArrayBufferView::getOwnNonIndexPropertyNames):
      (JSC::JSArrayBufferView::finalize):
      * runtime/JSArrayBufferView.h: Added.
      (JSC::JSArrayBufferView::sizeOf):
      (JSC::JSArrayBufferView::ConstructionContext::operator!):
      (JSC::JSArrayBufferView::ConstructionContext::structure):
      (JSC::JSArrayBufferView::ConstructionContext::vector):
      (JSC::JSArrayBufferView::ConstructionContext::length):
      (JSC::JSArrayBufferView::ConstructionContext::mode):
      (JSC::JSArrayBufferView::ConstructionContext::butterfly):
      (JSC::JSArrayBufferView::mode):
      (JSC::JSArrayBufferView::vector):
      (JSC::JSArrayBufferView::length):
      (JSC::JSArrayBufferView::offsetOfVector):
      (JSC::JSArrayBufferView::offsetOfLength):
      (JSC::JSArrayBufferView::offsetOfMode):
      * runtime/JSArrayBufferViewInlines.h: Added.
      (JSC::JSArrayBufferView::slowDownAndWasteMemoryIfNecessary):
      (JSC::JSArrayBufferView::buffer):
      (JSC::JSArrayBufferView::impl):
      (JSC::JSArrayBufferView::neuter):
      (JSC::JSArrayBufferView::byteOffset):
      * runtime/JSCell.cpp:
      (JSC::JSCell::slowDownAndWasteMemory):
      (JSC::JSCell::getTypedArrayImpl):
      * runtime/JSCell.h:
      * runtime/JSDataView.cpp: Added.
      (JSC::JSDataView::JSDataView):
      (JSC::JSDataView::create):
      (JSC::JSDataView::createUninitialized):
      (JSC::JSDataView::set):
      (JSC::JSDataView::typedImpl):
      (JSC::JSDataView::getOwnPropertySlot):
      (JSC::JSDataView::getOwnPropertyDescriptor):
      (JSC::JSDataView::slowDownAndWasteMemory):
      (JSC::JSDataView::getTypedArrayImpl):
      (JSC::JSDataView::createStructure):
      * runtime/JSDataView.h: Added.
      * runtime/JSDataViewPrototype.cpp: Added.
      (JSC::JSDataViewPrototype::JSDataViewPrototype):
      (JSC::JSDataViewPrototype::create):
      (JSC::JSDataViewPrototype::createStructure):
      (JSC::JSDataViewPrototype::getOwnPropertySlot):
      (JSC::JSDataViewPrototype::getOwnPropertyDescriptor):
      (JSC::getData):
      (JSC::setData):
      (JSC::dataViewProtoFuncGetInt8):
      (JSC::dataViewProtoFuncGetInt16):
      (JSC::dataViewProtoFuncGetInt32):
      (JSC::dataViewProtoFuncGetUint8):
      (JSC::dataViewProtoFuncGetUint16):
      (JSC::dataViewProtoFuncGetUint32):
      (JSC::dataViewProtoFuncGetFloat32):
      (JSC::dataViewProtoFuncGetFloat64):
      (JSC::dataViewProtoFuncSetInt8):
      (JSC::dataViewProtoFuncSetInt16):
      (JSC::dataViewProtoFuncSetInt32):
      (JSC::dataViewProtoFuncSetUint8):
      (JSC::dataViewProtoFuncSetUint16):
      (JSC::dataViewProtoFuncSetUint32):
      (JSC::dataViewProtoFuncSetFloat32):
      (JSC::dataViewProtoFuncSetFloat64):
      * runtime/JSDataViewPrototype.h: Added.
      * runtime/JSFloat32Array.h: Added.
      * runtime/JSFloat64Array.h: Added.
      * runtime/JSGenericTypedArrayView.h: Added.
      (JSC::JSGenericTypedArrayView::byteLength):
      (JSC::JSGenericTypedArrayView::byteSize):
      (JSC::JSGenericTypedArrayView::typedVector):
      (JSC::JSGenericTypedArrayView::canGetIndexQuickly):
      (JSC::JSGenericTypedArrayView::canSetIndexQuickly):
      (JSC::JSGenericTypedArrayView::getIndexQuicklyAsNativeValue):
      (JSC::JSGenericTypedArrayView::getIndexQuicklyAsDouble):
      (JSC::JSGenericTypedArrayView::getIndexQuickly):
      (JSC::JSGenericTypedArrayView::setIndexQuicklyToNativeValue):
      (JSC::JSGenericTypedArrayView::setIndexQuicklyToDouble):
      (JSC::JSGenericTypedArrayView::setIndexQuickly):
      (JSC::JSGenericTypedArrayView::canAccessRangeQuickly):
      (JSC::JSGenericTypedArrayView::typedImpl):
      (JSC::JSGenericTypedArrayView::createStructure):
      (JSC::JSGenericTypedArrayView::info):
      (JSC::toNativeTypedView):
      * runtime/JSGenericTypedArrayViewConstructor.h: Added.
      * runtime/JSGenericTypedArrayViewConstructorInlines.h: Added.
      (JSC::::JSGenericTypedArrayViewConstructor):
      (JSC::::finishCreation):
      (JSC::::create):
      (JSC::::createStructure):
      (JSC::constructGenericTypedArrayView):
      (JSC::::getConstructData):
      (JSC::::getCallData):
      * runtime/JSGenericTypedArrayViewInlines.h: Added.
      (JSC::::JSGenericTypedArrayView):
      (JSC::::create):
      (JSC::::createUninitialized):
      (JSC::::validateRange):
      (JSC::::setWithSpecificType):
      (JSC::::set):
      (JSC::::getOwnPropertySlot):
      (JSC::::getOwnPropertyDescriptor):
      (JSC::::put):
      (JSC::::defineOwnProperty):
      (JSC::::deleteProperty):
      (JSC::::getOwnPropertySlotByIndex):
      (JSC::::putByIndex):
      (JSC::::deletePropertyByIndex):
      (JSC::::getOwnNonIndexPropertyNames):
      (JSC::::getOwnPropertyNames):
      (JSC::::visitChildren):
      (JSC::::copyBackingStore):
      (JSC::::slowDownAndWasteMemory):
      (JSC::::getTypedArrayImpl):
      * runtime/JSGenericTypedArrayViewPrototype.h: Added.
      * runtime/JSGenericTypedArrayViewPrototypeInlines.h: Added.
      (JSC::genericTypedArrayViewProtoFuncSet):
      (JSC::genericTypedArrayViewProtoFuncSubarray):
      (JSC::::JSGenericTypedArrayViewPrototype):
      (JSC::::finishCreation):
      (JSC::::create):
      (JSC::::createStructure):
      * runtime/JSGlobalObject.cpp:
      (JSC::JSGlobalObject::reset):
      (JSC::JSGlobalObject::visitChildren):
      * runtime/JSGlobalObject.h:
      (JSC::JSGlobalObject::arrayBufferPrototype):
      (JSC::JSGlobalObject::arrayBufferStructure):
      (JSC::JSGlobalObject::typedArrayStructure):
      * runtime/JSInt16Array.h: Added.
      * runtime/JSInt32Array.h: Added.
      * runtime/JSInt8Array.h: Added.
      * runtime/JSTypedArrayConstructors.cpp: Added.
      * runtime/JSTypedArrayConstructors.h: Added.
      * runtime/JSTypedArrayPrototypes.cpp: Added.
      * runtime/JSTypedArrayPrototypes.h: Added.
      * runtime/JSTypedArrays.cpp: Added.
      * runtime/JSTypedArrays.h: Added.
      * runtime/JSUint16Array.h: Added.
      * runtime/JSUint32Array.h: Added.
      * runtime/JSUint8Array.h: Added.
      * runtime/JSUint8ClampedArray.h: Added.
      * runtime/Operations.h:
      * runtime/Options.h:
      * runtime/SimpleTypedArrayController.cpp: Added.
      (JSC::SimpleTypedArrayController::SimpleTypedArrayController):
      (JSC::SimpleTypedArrayController::~SimpleTypedArrayController):
      (JSC::SimpleTypedArrayController::toJS):
      * runtime/SimpleTypedArrayController.h: Added.
      * runtime/Structure.h:
      (JSC::Structure::couldHaveIndexingHeader):
      * runtime/StructureInlines.h:
      (JSC::Structure::hasIndexingHeader):
      * runtime/TypedArrayAdaptors.h: Added.
      (JSC::IntegralTypedArrayAdaptor::toNative):
      (JSC::IntegralTypedArrayAdaptor::toJSValue):
      (JSC::IntegralTypedArrayAdaptor::toDouble):
      (JSC::FloatTypedArrayAdaptor::toNative):
      (JSC::FloatTypedArrayAdaptor::toJSValue):
      (JSC::FloatTypedArrayAdaptor::toDouble):
      (JSC::Uint8ClampedAdaptor::toNative):
      (JSC::Uint8ClampedAdaptor::toJSValue):
      (JSC::Uint8ClampedAdaptor::toDouble):
      (JSC::Uint8ClampedAdaptor::clamp):
      * runtime/TypedArrayController.cpp: Added.
      (JSC::TypedArrayController::TypedArrayController):
      (JSC::TypedArrayController::~TypedArrayController):
      * runtime/TypedArrayController.h: Added.
      * runtime/TypedArrayDescriptor.h: Removed.
      * runtime/TypedArrayInlines.h: Added.
      * runtime/TypedArrayType.cpp: Added.
      (JSC::classInfoForType):
      (WTF::printInternal):
      * runtime/TypedArrayType.h: Added.
      (JSC::toIndex):
      (JSC::isTypedView):
      (JSC::elementSize):
      (JSC::isInt):
      (JSC::isFloat):
      (JSC::isSigned):
      (JSC::isClamped):
      * runtime/TypedArrays.h: Added.
      * runtime/Uint16Array.h:
      * runtime/Uint32Array.h:
      * runtime/Uint8Array.h:
      * runtime/Uint8ClampedArray.h:
      * runtime/VM.cpp:
      (JSC::VM::VM):
      (JSC::VM::~VM):
      * runtime/VM.h:
      
      Source/WebCore: 
      
      Reviewed by Oliver Hunt.
      
      Typed arrays are now implemented in JavaScriptCore, and WebCore is merely a
      client of them. There is only one layering violation: WebCore installs a
      WebCoreTypedArrayController on VM, which makes the
      ArrayBuffer<->JSArrayBuffer relationship resemble DOM wrappers. By default,
      JSC makes the ownership go one way; the JSArrayBuffer keeps the ArrayBuffer
      alive but if ArrayBuffer is kept alive from native code then the
      JSArrayByffer may die. WebCoreTypedArrayController will keep the
      JSArrayBuffer alive if the ArrayBuffer is in the opaque root set.
              
      To make non-JSDOMWrappers behave like DOM wrappers, a bunch of code is
      changed to make most references to wrappers refer to JSObject* rather than
      JSDOMWrapper*.
              
      Array buffer views are now transient; the JS array buffer view wrappers
      don't own them or keep them alive. This required a bunch of changes to make
      bindings code use RefPtr<ArrayBufferView> to hold onto their views.
              
      Also there is a bunch of new code to make JSC-provided array buffers and
      views obey the toJS/to<ClassName> idiom for wrapping and unwrapping.
              
      Finally, the DataView API is now completely different: the JSDataView
      provides the same user-visible JS API but using its own internal magic; the
      C++ code that uses DataView now uses a rather different API that is not
      aware of usual DOM semantics, since it's in JSC and not WebCore. It's
      equally useful for all of WebCore's purposes, but some code had to change
      to adapt the new conventions.
              
      Some tests have been changed or rebased due to changes in behavior, that
      bring us into conformance with where the standards are going and allow us to
      match Firefox behavior.
      
      Automake work and some additional GTK changes courtesy of
      Zan Dobersek <zdobersek@igalia.com>.
              
      Additional Qt changes courtesy of Arunprasad Rajkumar <arurajku@cisco.com>.
      
      * CMakeLists.txt:
      * DerivedSources.make:
      * ForwardingHeaders/runtime/DataView.h: Added.
      * ForwardingHeaders/runtime/JSArrayBuffer.h: Added.
      * ForwardingHeaders/runtime/JSArrayBufferView.h: Added.
      * ForwardingHeaders/runtime/JSDataView.h: Added.
      * ForwardingHeaders/runtime/JSTypedArrays.h: Added.
      * ForwardingHeaders/runtime/TypedArrayController.h: Added.
      * ForwardingHeaders/runtime/TypedArrayInlines.h: Added.
      * ForwardingHeaders/runtime/TypedArrays.h: Added.
      * GNUmakefile.list.am:
      * Modules/webaudio/RealtimeAnalyser.h:
      * Target.pri:
      * UseJSC.cmake:
      * WebCore.exp.in:
      * WebCore.vcxproj/WebCore.vcxproj:
      * WebCore.xcodeproj/project.pbxproj:
      * bindings/js/DOMWrapperWorld.h:
      * bindings/js/JSArrayBufferCustom.cpp: Removed.
      * bindings/js/JSArrayBufferViewHelper.h: Removed.
      * bindings/js/JSAudioContextCustom.cpp:
      * bindings/js/JSBindingsAllInOne.cpp:
      * bindings/js/JSBlobCustom.cpp:
      * bindings/js/JSCSSRuleCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSCSSValueCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSCryptoCustom.cpp:
      (WebCore::JSCrypto::getRandomValues):
      * bindings/js/JSDOMBinding.h:
      (WebCore::wrapperOwner):
      (WebCore::wrapperContext):
      (WebCore::getInlineCachedWrapper):
      (WebCore::setInlineCachedWrapper):
      (WebCore::clearInlineCachedWrapper):
      (WebCore::getCachedWrapper):
      (WebCore::cacheWrapper):
      (WebCore::uncacheWrapper):
      (WebCore::wrap):
      (WebCore::toJS):
      (WebCore::toArrayBufferView):
      (WebCore::toInt8Array):
      (WebCore::toInt16Array):
      (WebCore::toInt32Array):
      (WebCore::toUint8Array):
      (WebCore::toUint8ClampedArray):
      (WebCore::toUint16Array):
      (WebCore::toUint32Array):
      (WebCore::toFloat32Array):
      (WebCore::toFloat64Array):
      (WebCore::toDataView):
      * bindings/js/JSDataViewCustom.cpp: Removed.
      * bindings/js/JSDictionary.cpp:
      * bindings/js/JSDictionary.h:
      * bindings/js/JSDocumentCustom.cpp:
      (WebCore::JSDocument::location):
      (WebCore::toJS):
      * bindings/js/JSEventCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSFileReaderCustom.cpp:
      * bindings/js/JSHTMLCollectionCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSHTMLTemplateElementCustom.cpp:
      (WebCore::JSHTMLTemplateElement::content):
      * bindings/js/JSImageDataCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSInjectedScriptHostCustom.cpp:
      * bindings/js/JSMessageEventCustom.cpp:
      * bindings/js/JSMessagePortCustom.cpp:
      * bindings/js/JSSVGPathSegCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSStyleSheetCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSTrackCustom.cpp:
      (WebCore::toJS):
      * bindings/js/JSWebGLRenderingContextCustom.cpp:
      * bindings/js/JSXMLHttpRequestCustom.cpp:
      (WebCore::JSXMLHttpRequest::send):
      * bindings/js/SerializedScriptValue.cpp:
      (WebCore::SerializedScriptValue::transferArrayBuffers):
      * bindings/js/WebCoreJSClientData.h:
      (WebCore::initNormalWorldClientData):
      * bindings/js/WebCoreTypedArrayController.cpp: Added.
      (WebCore::WebCoreTypedArrayController::WebCoreTypedArrayController):
      (WebCore::WebCoreTypedArrayController::~WebCoreTypedArrayController):
      (WebCore::WebCoreTypedArrayController::toJS):
      (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):
      (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::finalize):
      * bindings/js/WebCoreTypedArrayController.h: Added.
      (WebCore::WebCoreTypedArrayController::wrapperOwner):
      * bindings/scripts/CodeGenerator.pm:
      (ForAllParents):
      (ParseInterface):
      (SkipIncludeHeader):
      (IsTypedArrayType):
      (IsWrapperType):
      * bindings/scripts/CodeGeneratorJS.pm:
      (AddIncludesForType):
      (GenerateHeader):
      (GenerateImplementation):
      (GenerateParametersCheck):
      (GetNativeType):
      (JSValueToNative):
      (NativeToJSValue):
      (GenerateConstructorDefinition):
      (GenerateConstructorHelperMethods):
      * fileapi/WebKitBlobBuilder.cpp:
      (WebCore::BlobBuilder::append):
      * fileapi/WebKitBlobBuilder.h:
      * html/canvas/ArrayBuffer.idl: Removed.
      * html/canvas/ArrayBufferView.idl: Removed.
      * html/canvas/DataView.cpp: Removed.
      * html/canvas/DataView.h: Removed.
      * html/canvas/DataView.idl: Removed.
      * html/canvas/Float32Array.idl: Removed.
      * html/canvas/Float64Array.idl: Removed.
      * html/canvas/Int16Array.idl: Removed.
      * html/canvas/Int32Array.idl: Removed.
      * html/canvas/Int8Array.idl: Removed.
      * html/canvas/Uint16Array.idl: Removed.
      * html/canvas/Uint32Array.idl: Removed.
      * html/canvas/Uint8Array.idl: Removed.
      * html/canvas/Uint8ClampedArray.idl: Removed.
      * html/canvas/WebGLRenderingContext.cpp:
      (WebCore::WebGLRenderingContext::readPixels):
      (WebCore::WebGLRenderingContext::validateTexFuncData):
      * page/Crypto.cpp:
      * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
      (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
      (WebCore::MediaPlayerPrivateAVFoundationObjC::extractKeyURIKeyIDAndCertificateFromInitData):
      * platform/graphics/filters/FECustomFilter.h:
      * platform/graphics/filters/FEGaussianBlur.cpp:
      * platform/graphics/filters/FilterEffect.cpp:
      * testing/MockCDM.cpp:
      
      Source/WebKit2: 
      
      Reviewed by Oliver Hunt.
              
      You don't need to include JSUint8Array anymore if you just want to
      unwrap one; JSDOMBinding gives you all of the things you need.
      
      * WebProcess/InjectedBundle/InjectedBundle.cpp:
      
      Source/WTF: 
      
      Reviewed by Oliver Hunt.
              
      - Added the notion of a reference counted object that can be marked Deferred,
        which is like a special-purpose upref.
              
      - Added a common byte flipper.
      
      Automake work courtesy of Zan Dobersek <zdobersek@igalia.com>.
      
      * GNUmakefile.list.am:
      * WTF.xcodeproj/project.pbxproj:
      * wtf/DeferrableRefCounted.h: Added.
      (WTF::DeferrableRefCountedBase::ref):
      (WTF::DeferrableRefCountedBase::hasOneRef):
      (WTF::DeferrableRefCountedBase::refCount):
      (WTF::DeferrableRefCountedBase::isDeferred):
      (WTF::DeferrableRefCountedBase::DeferrableRefCountedBase):
      (WTF::DeferrableRefCountedBase::~DeferrableRefCountedBase):
      (WTF::DeferrableRefCountedBase::derefBase):
      (WTF::DeferrableRefCountedBase::setIsDeferredBase):
      (WTF::DeferrableRefCounted::deref):
      (WTF::DeferrableRefCounted::setIsDeferred):
      (WTF::DeferrableRefCounted::DeferrableRefCounted):
      (WTF::DeferrableRefCounted::~DeferrableRefCounted):
      * wtf/FlipBytes.h: Added.
      (WTF::needToFlipBytesIfLittleEndian):
      (WTF::flipBytes):
      (WTF::flipBytesIfLittleEndian):
      
      LayoutTests: 
      
      Reviewed by Oliver Hunt.
      
      * fast/canvas/webgl/array-set-invalid-arguments-expected.txt:
      * fast/canvas/webgl/array-set-out-of-bounds-expected.txt:
      * fast/canvas/webgl/array-unit-tests-expected.txt:
      * fast/canvas/webgl/array-unit-tests.html:
      * fast/canvas/webgl/data-view-crash-expected.txt:
      * fast/canvas/webgl/script-tests/arraybuffer-transfer-of-control.js:
      (checkView):
      * fast/dom/call-a-constructor-as-a-function-expected.txt:
      * fast/dom/call-a-constructor-as-a-function.html:
      * fast/js/constructor-length.html:
      * fast/js/global-constructors-attributes-dedicated-worker-expected.txt:
      * fast/js/global-constructors-attributes-expected.txt:
      * fast/js/global-constructors-attributes-shared-worker-expected.txt:
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-expected.txt: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-huge-long-lived-expected.txt: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-huge-long-lived.html: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived-expected.txt: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-large-long-lived.html: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-long-lived-buffer-expected.txt: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-long-lived-buffer.html: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-long-lived-expected.txt: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc-long-lived.html: Added.
      * fast/js/regress/ArrayBuffer-Int8Array-alloc.html: Added.
      * fast/js/regress/Int32Array-Int8Array-view-alloc-expected.txt: Added.
      * fast/js/regress/Int32Array-Int8Array-view-alloc.html: Added.
      * fast/js/regress/Int32Array-alloc-expected.txt: Added.
      * fast/js/regress/Int32Array-alloc-huge-expected.txt: Added.
      * fast/js/regress/Int32Array-alloc-huge-long-lived-expected.txt: Added.
      * fast/js/regress/Int32Array-alloc-huge-long-lived.html: Added.
      * fast/js/regress/Int32Array-alloc-huge.html: Added.
      * fast/js/regress/Int32Array-alloc-large-expected.txt: Added.
      * fast/js/regress/Int32Array-alloc-large-long-lived-expected.txt: Added.
      * fast/js/regress/Int32Array-alloc-large-long-lived.html: Added.
      * fast/js/regress/Int32Array-alloc-large.html: Added.
      * fast/js/regress/Int32Array-alloc-long-lived-expected.txt: Added.
      * fast/js/regress/Int32Array-alloc-long-lived.html: Added.
      * fast/js/regress/Int32Array-alloc.html: Added.
      * fast/js/regress/script-tests/ArrayBuffer-Int8Array-alloc-huge-long-lived.js: Added.
      * fast/js/regress/script-tests/ArrayBuffer-Int8Array-alloc-large-long-lived.js: Added.
      * fast/js/regress/script-tests/ArrayBuffer-Int8Array-alloc-long-lived-buffer.js: Added.
      * fast/js/regress/script-tests/ArrayBuffer-Int8Array-alloc-long-lived.js: Added.
      * fast/js/regress/script-tests/ArrayBuffer-Int8Array-alloc.js: Added.
      * fast/js/regress/script-tests/Int32Array-Int8Array-view-alloc.js: Added.
      * fast/js/regress/script-tests/Int32Array-alloc-huge-long-lived.js: Added.
      * fast/js/regress/script-tests/Int32Array-alloc-huge.js: Added.
      * fast/js/regress/script-tests/Int32Array-alloc-large-long-lived.js: Added.
      * fast/js/regress/script-tests/Int32Array-alloc-large.js: Added.
      * fast/js/regress/script-tests/Int32Array-alloc-long-lived.js: Added.
      * fast/js/regress/script-tests/Int32Array-alloc.js: Added.
      * platform/mac/fast/js/constructor-length-expected.txt:
      * webgl/resources/webgl_test_files/conformance/typedarrays/array-unit-tests.html:
      * webgl/resources/webgl_test_files/conformance/typedarrays/data-view-test.html:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154127 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0e0d9312
    • bjonesbe@adobe.com's avatar
      <https://webkit.org/b/119850> Speed up test importing by doing all the regex... · 1a8ab279
      bjonesbe@adobe.com authored
      <https://webkit.org/b/119850> Speed up test importing by doing all the regex matching in a single pass
      
      Reviewed by Dirk Pranke.
      
      This is a port from Blink of
      https://src.chromium.org/viewvc/blink?revision=155647&view=revision
      originally by Dirk Pranke.
      
      From the original commit:
      
      This gives something like a 15x speedup over compiling and matching
      one property at a time and doing multiple passes over the file.
      
      * Scripts/webkitpy/w3c/test_converter.py:
      (W3CTestConverter.__init__):
      (W3CTestConverter.convert_prefixed_properties):
      (W3CTestConverter.add_webkit_prefix_to_unprefixed_properties):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154126 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      1a8ab279
    • cfleizach@apple.com's avatar
      <https://webkit.org/b/119824> AX: WKView does not become first responder when... · 7f8f5d98
      cfleizach@apple.com authored
      <https://webkit.org/b/119824> AX: WKView does not become first responder when the voiceover cursor lands on it
      
      Reviewed by Darin Adler.
      
      Incorporate review feedback from Darin.
      
      * accessibility/AccessibilityScrollView.cpp:
      (WebCore::AccessibilityScrollView::canSetFocusAttribute):
      (WebCore::AccessibilityScrollView::isFocused):
      * accessibility/AccessibilityScrollView.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154123 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7f8f5d98
    • akling@apple.com's avatar
      <https://webkit.org/b/119826> Page::focusController() should return a reference. · 8825ce75
      akling@apple.com authored
      Reviewed by Anders Carlsson.
      
      Page::focusController() is never null so make it return a reference.
      Some unnecessary checks were removed as a result.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154122 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8825ce75
    • rwlbuis@webkit.org's avatar
      ASSERTION FAILED: !m_adoptionIsRequired in void WebCore::TreeShared<NodeType>::ref() · 905f4c2d
      rwlbuis@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=116979
      
      Reviewed by Alexey Proskuryakov.
      
      Make constructors private since only ::create should use them.
      
      * html/shadow/MeterShadowElement.h:
      * html/shadow/ProgressShadowElement.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154121 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      905f4c2d
    • oliver@apple.com's avatar
      <https://webkit.org/b/119830> Assigning to a readonly global results in DFG byte code parse failure · 0053edb3
      oliver@apple.com authored
      Reviewed by Filip Pizlo.
      
      Source/JavaScriptCore:
      
      Make sure dfgCapabilities doesn't report a Dynamic put as
      being compilable when we don't actually support it.
      
      * bytecode/CodeBlock.cpp:
      (JSC::CodeBlock::dumpBytecode):
      * dfg/DFGCapabilities.cpp:
      (JSC::DFG::capabilityLevel):
      
      LayoutTests:
      
      Add a test
      
      * fast/js/dfg-put-to-readonly-property-expected.txt: Added.
      * fast/js/dfg-put-to-readonly-property.html: Added.
      * fast/js/script-tests/dfg-put-to-readonly-property.js: Added.
      (foo):
      (bar):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154120 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0053edb3
    • bfulgham@apple.com's avatar
      [Windows] Incorrect DLL Linkage for JSC ArrayBuffer and ArrayBufferView · e25646c2
      bfulgham@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119847
      
      Reviewed by Oliver Hunt.
      
      * runtime/ArrayBuffer.h: Switch from WTF_EXPORT_PRIVATE to JS_EXPORT_PRIVATE
      * runtime/ArrayBufferView.h: Ditto.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154119 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e25646c2
    • bfulgham@apple.com's avatar
      [Windows] Build correctsion after r154106 · 2c830cfa
      bfulgham@apple.com authored
      * WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Add missing symbol export.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154118 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2c830cfa
    • mitz@apple.com's avatar
      <https://webkit.org/b/119856> Improve extract-localizable-strings messages · 9114b508
      mitz@apple.com authored
      Reviewed by Darin Adler.
      
      * Scripts/extract-localizable-strings: When the strings file disagrees with the source code,
      added a message that points to the source code. Removed some unnecessary repetition of what
      is already in the file.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154117 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9114b508
    • timothy_horton@apple.com's avatar
      FrameView should have an isMainFrameView() · cef709c0
      timothy_horton@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119435
      
      Reviewed by Simon Fraser.
      
      No new tests, just refactoring.
      
      * page/FrameView.cpp:
      (WebCore::FrameView::FrameView):
      (WebCore::FrameView::isMainFrameView):
      (WebCore::FrameView::setFrameRect):
      (WebCore::FrameView::createScrollbar):
      (WebCore::FrameView::applyOverflowToViewport):
      (WebCore::FrameView::setHeaderHeight):
      (WebCore::FrameView::setFooterHeight):
      (WebCore::FrameView::minimumScrollPosition):
      (WebCore::FrameView::maximumScrollPosition):
      (WebCore::FrameView::performPostLayoutTasks):
      (WebCore::FrameView::sendResizeEventIfNeeded):
      (WebCore::FrameView::pagination):
      (WebCore::FrameView::visibleContentScaleFactor):
      (WebCore::FrameView::setVisibleScrollerThumbRect):
      (WebCore::FrameView::scrollbarStyleChanged):
      (WebCore::FrameView::paintScrollCorner):
      (WebCore::FrameView::paintScrollbar):
      (WebCore::FrameView::paintOverhangAreas):
      * page/FrameView.h:
      Add isMainFrameView and adopt it wherever we were previously checking if
      the FrameView's frame was the same as its page's main frame.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154116 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      cef709c0
    • aestes@apple.com's avatar
      <https://webkit.org/b/119853> REGRESSION (r139343): WebKit crashes when... · 52e98d27
      aestes@apple.com authored
      <https://webkit.org/b/119853> REGRESSION (r139343): WebKit crashes when canceling a load inside webView:resource:didFinishLoadingFromDataSource:
      
      Reviewed by Brady Eidson.
      
      Source/WebCore:
      
      A client implementing webView:resource:didFinishLoadingFromDataSource:
      might decide to call stopLoading: for the identifier that just finished
      loading. If this happens we re-enter the loader and attempt to cancel a
      load that has already finished and been removed from the set of active
      loaders. Prevent this by clearing DocumentLoader's
      m_identifierForLoadWithoutResourceLoader before calling
      dispatchDidFinishLoading().
      
      New API test: WebKit1.StopLoadingFromDidFinishLoading.
      
      * loader/DocumentLoader.cpp:
      (WebCore::DocumentLoader::finishedLoading): Set
      m_identifierForLoadWithoutResourceLoader to 0 before calling
      dispatchDidFinishLoading().
      
      Tools:
      
      Wrote an API test that verifies -[WebView stopLoading:] can be called
      inside webView:resource:didFinishLoadingFromDataSource: without crashing.
      
      * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
      * TestWebKitAPI/Tests/mac/StopLoadingFromDidFinishLoading.mm: Added.
      (-[StopLoadingFromDidFinishLoadingDelegate webView:resource:didFinishLoadingFromDataSource:]):
      (TestWebKitAPI::TEST):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154115 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      52e98d27
    • andersca@apple.com's avatar
      <https://webkit.org/b/119854> REGRESSION (r153379): Serious drawing issues with WebViews · 48482fb6
      andersca@apple.com authored
      <rdar://problem/14698870>
      
      Reviewed by Simon Fraser.
      
      Don't set aside subviews if they have already been set aside.
      
      * WebView/WebHTMLView.mm:
      (-[WebHTMLView _recursive:displayRectIgnoringOpacity:inGraphicsContext:CGContext:topView:shouldChangeFontReferenceColor:]):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154114 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      48482fb6
    • barraclough@apple.com's avatar
      https://bugs.webkit.org/show_bug.cgi?id=119843 · c6cf7cb0
      barraclough@apple.com authored
      PropertySlot::setValue is ambiguous
      
      Reviewed by Geoff Garen.
      
      There are three different versions of PropertySlot::setValue, one for cacheable properties, and two that are used interchangeably and inconsistently.
      The problematic variants are the ones that just take a value, and one that takes a value and also the object containing the property.
      Unify on always providing the object, and remove the version that just takes a value.
      This always works except for JSString, where we optimize out the object (logically we should be instantiating a temporary StringObject on every property access).
      Provide a version of setValue that takes a JSString as the owner of the property.
      We won't store this, but it makes it clear that this interface should only be used from JSString.
      
      * API/JSCallbackObjectFunctions.h:
      (JSC::::getOwnPropertySlot):
      * JSCTypedArrayStubs.h:
      * runtime/Arguments.cpp:
      (JSC::Arguments::getOwnPropertySlotByIndex):
      (JSC::Arguments::getOwnPropertySlot):
      * runtime/JSActivation.cpp:
      (JSC::JSActivation::symbolTableGet):
      (JSC::JSActivation::getOwnPropertySlot):
      * runtime/JSArray.cpp:
      (JSC::JSArray::getOwnPropertySlot):
      * runtime/JSObject.cpp:
      (JSC::JSObject::getOwnPropertySlotByIndex):
      * runtime/JSString.h:
      (JSC::JSString::getStringPropertySlot):
      * runtime/JSSymbolTableObject.h:
      (JSC::symbolTableGet):
      * runtime/SparseArrayValueMap.cpp:
      (JSC::SparseArrayEntry::get):
          - Pass object containing property to PropertySlot::setValue
      * runtime/PropertySlot.h:
      (JSC::PropertySlot::setValue):
          - Logically, the base of a string property access is a temporary StringObject, but we optimize that away.
      (JSC::PropertySlot::setUndefined):
          - removed setValue(JSValue), added setValue(JSString*, JSValue)
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154113 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c6cf7cb0
    • eric.carlson@apple.com's avatar
      [Mac] Remove "legacy" media UI · e323d0c4
      eric.carlson@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119752
      
      Reviewed by Jer Noble.
      
      Source/WebCore: 
      
      * WebCore.exp.in: Remove _wkMediaControllerThemeAvailable.
      
      * platform/mac/WebCoreSystemInterface.h: Update for API change.
      * platform/mac/WebCoreSystemInterface.mm: Ditto.
      
      * rendering/RenderThemeMac.h: Don't override hasOwnDisabledStateHandlingFor.
      * rendering/RenderThemeMac.mm:
      (WebCore::RenderThemeMac::adjustMediaSliderThumbSize): Remove code to deal with legacy theme.
      (WebCore::getUnzoomedRectAndAdjustCurrentContext): Ditto.
      (WebCore::RenderThemeMac::paintMediaFullscreenButton): wkDrawMediaUIPart doesn't need to know
          the current theme.
      (WebCore::RenderThemeMac::paintMediaMuteButton): Ditto.
      (WebCore::RenderThemeMac::paintMediaPlayButton): Ditto.
      (WebCore::RenderThemeMac::paintMediaSeekBackButton): Ditto.
      (WebCore::RenderThemeMac::paintMediaSeekForwardButton): Ditto.
      (WebCore::RenderThemeMac::paintMediaSliderTrack): Ditto.
      (WebCore::RenderThemeMac::paintMediaSliderThumb): Ditto.
      (WebCore::RenderThemeMac::paintMediaRewindButton): Ditto.
      (WebCore::RenderThemeMac::paintMediaReturnToRealtimeButton): Ditto.
      (WebCore::RenderThemeMac::paintMediaControlsBackground): Ditto.
      (WebCore::RenderThemeMac::paintMediaCurrentTime): Ditto.
      (WebCore::RenderThemeMac::paintMediaTimeRemaining): Ditto.
      (WebCore::RenderThemeMac::paintMediaVolumeSliderContainer): Ditto.
      (WebCore::RenderThemeMac::paintMediaVolumeSliderTrack): Ditto.
      (WebCore::RenderThemeMac::paintMediaVolumeSliderThumb): Ditto.
      (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderTrack): Ditto.
      (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderThumb): Ditto.
      (WebCore::RenderThemeMac::extraMediaControlsStyleSheet): We only have one theme.
      (WebCore::RenderThemeMac::extraFullScreenStyleSheet): Ditto.
      (WebCore::RenderThemeMac::usesMediaControlStatusDisplay): Ditto.
      
      Source/WebKit/mac: 
      
      * WebCoreSupport/WebSystemInterface.mm:
      (InitWebCoreSystemInterface): Remove MediaControllerThemeAvailable.
      
      Source/WebKit2: 
      
      * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
      (InitWebCoreSystemInterface): Remove MediaControllerThemeAvailable.
      
      WebKitLibraries: 
      
      * WebKitSystemInterface.h:
      * libWebKitSystemInterfaceLion.a:
      * libWebKitSystemInterfaceMountainLion.a:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154112 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e323d0c4
    • ap@apple.com's avatar
      Adding Myles Maxfield to contributors.json. · 9336e8f0
      ap@apple.com authored
              Oops, wrong section, fixing.
      
              * Scripts/webkitpy/common/config/contributors.json:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154111 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9336e8f0
    • ap@apple.com's avatar
      Adding Myles Maxfield to contributors.json. · 85888c78
      ap@apple.com authored
              * Scripts/webkitpy/common/config/contributors.json:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154110 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      85888c78
    • allan.jensen@digia.com's avatar
      ANGLE doesn't build with bison 3.0 · 7537e6a8
      allan.jensen@digia.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119798
      
      Reviewed by Antti Koivisto.
      
      Make glslang.y compatible with bison 3.0, by using %lex-param
      to set YYLEX_PARAM and getting rid of useless YYID macro.
      
      * src/compiler/glslang.y:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154109 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7537e6a8
    • oliver@apple.com's avatar
      Remove bogus assertion. · 96f6f1a8
      oliver@apple.com authored
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154108 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      96f6f1a8
    • allan.jensen@digia.com's avatar
      [Qt] Do not check specifically for version 5.0 · 7a9dc8c9
      allan.jensen@digia.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119846
      
      Reviewed by Jocelyn Turcotte.
      
      For Qt 5.x we should always use both wk1 and wk2 basepath results.
      
      * Scripts/webkitpy/port/qt.py:
      (QtPort._search_paths):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154107 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7a9dc8c9
    • antti@apple.com's avatar
      <https://webkit.org/b/119834> Remove ElementShadow · 64d69393
      antti@apple.com authored
      Reviewed by Anders Carlsson.
      
      It is 1:1 with ShadowRoot and has virtually no functionality. What little there is can be moved to ShadowRoot or Element.
      
      * CMakeLists.txt:
      * GNUmakefile.list.am:
      * Target.pri:
      * WebCore.exp.in:
      * WebCore.xcodeproj/project.pbxproj:
      * css/StyleResolver.cpp:
      (WebCore::StyleResolver::locateCousinList):
      * css/StyleScopeResolver.cpp:
      (WebCore::StyleScopeResolver::styleSharingCandidateMatchesHostRules):
      (WebCore::StyleScopeResolver::matchHostRules):
      * dom/ComposedShadowTreeWalker.cpp:
      (WebCore::nodeCanBeDistributed):
      (WebCore::ComposedShadowTreeWalker::traverseChild):
      * dom/ContainerNode.cpp:
      (WebCore::childAttachedAllowedWhenAttachingChildren):
      * dom/ContainerNodeAlgorithms.cpp:
      (WebCore::ChildNodeInsertionNotifier::notifyDescendantInsertedIntoDocument):
      (WebCore::ChildNodeRemovalNotifier::notifyDescendantRemovedFromDocument):
      (WebCore::ChildNodeRemovalNotifier::notifyDescendantRemovedFromTree):
      (WebCore::assertConnectedSubrameCountIsConsistent):
      * dom/ContainerNodeAlgorithms.h:
      (WebCore::ChildFrameDisconnector::collectFrameOwners):
      * dom/DOMAllInOne.cpp:
      * dom/Document.cpp:
      * dom/Element.cpp:
      (WebCore::Element::~Element):
      (WebCore::Element::attach):
      (WebCore::Element::detach):
      (WebCore::Element::shadowRoot):
      (WebCore::Element::didAffectSelector):
      (WebCore::Element::addShadowRoot):
      (WebCore::Element::removeShadowRoot):
              
          Move addShadowRoot and removeShadowRoot here from ElementShadow.
      
      (WebCore::Element::createShadowRoot):
      (WebCore::Element::authorShadowRoot):
      (WebCore::Element::userAgentShadowRoot):
      (WebCore::Element::ensureUserAgentShadowRoot):
      (WebCore::Element::childrenChanged):
      (WebCore::Element::removeAllEventListeners):
      * dom/Element.h:
      (WebCore::isShadowHost):
      * dom/ElementRareData.h:
      (WebCore::ElementRareData::clearShadowRoot):
      (WebCore::ElementRareData::shadowRoot):
      (WebCore::ElementRareData::setShadowRoot):
      (WebCore::ElementRareData::~ElementRareData):
      * dom/ElementShadow.cpp: Removed.
      * dom/ElementShadow.h: Removed.
      * dom/EventDispatcher.cpp:
      * dom/EventPathWalker.cpp:
      (WebCore::EventPathWalker::moveToParent):
      * dom/Node.cpp:
      (WebCore::Node::needsShadowTreeWalkerSlow):
      * dom/NodeRenderingContext.cpp:
      * dom/NodeRenderingContext.h:
      * dom/ShadowRoot.cpp:
      (WebCore::ShadowRoot::attach):
      (WebCore::ShadowRoot::detach):
              
          Move attached() tests from ElementShadow.
      
      (WebCore::ShadowRoot::childrenChanged):
      (WebCore::ShadowRoot::removeAllEventListeners):
              
          Move here from ElementShadow.
      
      * dom/ShadowRoot.h:
      (WebCore::Node::shadowRoot):
      * dom/TreeScopeAdopter.cpp:
      * html/ColorInputType.cpp:
      (WebCore::ColorInputType::createShadowSubtree):
      * html/FileInputType.cpp:
      (WebCore::FileInputType::createShadowSubtree):
      (WebCore::FileInputType::disabledAttributeChanged):
      (WebCore::FileInputType::multipleAttributeChanged):
      * html/HTMLFormControlElement.cpp:
      * html/HTMLImageElement.cpp:
      (WebCore::HTMLImageElement::canStartSelection):
      * html/HTMLInputElement.cpp:
      (WebCore::HTMLInputElement::updateType):
      * html/HTMLKeygenElement.cpp:
      * html/HTMLMediaElement.cpp:
      * html/HTMLTextAreaElement.cpp:
      * html/InputType.cpp:
      * html/RangeInputType.cpp:
      (WebCore::RangeInputType::handleMouseDownEvent):
      (WebCore::RangeInputType::createShadowSubtree):
      * html/TextFieldInputType.cpp:
      (WebCore::TextFieldInputType::createShadowSubtree):
      * html/ValidationMessage.cpp:
      * html/shadow/ContentDistributor.cpp:
      (WebCore::ContentDistributor::distribute):
      (WebCore::ContentDistributor::ensureDistribution):
      * html/shadow/ContentDistributor.h:
      (WebCore::ContentDistributor::isValid):
      * html/shadow/InsertionPoint.cpp:
      (WebCore::InsertionPoint::childrenChanged):
      (WebCore::InsertionPoint::insertedInto):
      (WebCore::InsertionPoint::removedFrom):
      (WebCore::resolveReprojection):
      * html/shadow/InsertionPoint.h:
      (WebCore::shadowRootOfParentForDistribution):
      * html/shadow/SliderThumbElement.cpp:
      * inspector/InspectorDOMAgent.cpp:
      (WebCore::InspectorDOMAgent::unbind):
      (WebCore::InspectorDOMAgent::buildObjectForNode):
      * page/FocusController.cpp:
      (WebCore::FocusNavigationScope::focusNavigationScopeOwnedByShadowHost):
      * rendering/RenderFileUploadControl.cpp:
      (WebCore::RenderFileUploadControl::uploadButton):
      * rendering/RenderTheme.cpp:
      * style/StyleResolveTree.cpp:
      (WebCore::Style::resolveTree):
      * svg/SVGTRefElement.cpp:
      (WebCore::SVGTRefElement::updateReferencedText):
      (WebCore::SVGTRefElement::detachTarget):
      * svg/SVGUseElement.cpp:
      (WebCore::SVGUseElement::clearResourceReferences):
      (WebCore::SVGUseElement::buildShadowAndInstanceTree):
      (WebCore::SVGUseElement::buildShadowTree):
      * testing/Internals.cpp:
      (WebCore::Internals::ensureShadowRoot):
      (WebCore::Internals::shadowRoot):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154106 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      64d69393
    • mario@webkit.org's avatar
      [GTK] Unreviewed gardening. Move Mac specific expectation for · ffe31898
      mario@webkit.org authored
      accessibility test to the cross platform directory, as the result
      it's shared with GTK and EFL ports.
      
      * accessibility/heading-title-includes-links-expected.txt: Renamed
      from LayoutTests/platform/mac/accessibility/heading-title-includes-links-expected.txt.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154105 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ffe31898
    • allan.jensen@digia.com's avatar
      [Qt] memory leak in WebCore::FontCache::getLastResortFallbackFont · 87013279
      allan.jensen@digia.com authored
      https://bugs.webkit.org/show_bug.cgi?id=118532
      
      Reviewed by Jocelyn Turcotte.
      
      We don't need to allocate FontPlatformData on the heap
      since getCachedFontData makes a deep copy anyway.
      
      * platform/graphics/qt/FontCacheQt.cpp:
      (WebCore::FontCache::getLastResortFallbackFont):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154103 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      87013279
    • bfulgham@apple.com's avatar
      [Windows] Correct build after r154088 · 0b12893b
      bfulgham@apple.com authored
      * WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Remove unused
      (and now renamed) export symbols.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154102 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0b12893b
    • allan.jensen@digia.com's avatar
      Empty qt-5.0 expectations into qt expectations · 7180b8b7
      allan.jensen@digia.com authored
      Unreviewed gardening.
      
      * platform/qt-5.0/TestExpectations:
      * platform/qt-5.0/editing/selection/editable-html-element-expected.txt: Removed.
      * platform/qt-5.0/editing/selection/extend-by-word-001-expected.txt: Removed.
      * platform/qt-5.0/editing/selection/vertical-rl-ltr-extend-line-backward-wrap-expected.txt: Removed.
      * platform/qt-5.0/editing/selection/vertical-rl-ltr-extend-line-forward-wrap-expected.txt: Removed.
      * platform/qt-5.0/fast/dom/Orientation/create-event-orientationchange-expected.txt: Removed.
      * platform/qt-5.0/fast/dom/Window/window-properties-device-orientation-expected.txt: Removed.
      * platform/qt-5.0/fast/events/onload-re-entry-expected.txt: Removed.
      * platform/qt-5.0/fast/forms/input-disabled-color-expected.png: Removed.
      * platform/qt-5.0/fast/forms/input-disabled-color-expected.txt: Removed.
      * platform/qt-5.0/fast/forms/menulist-separator-painting-expected.png: Removed.
      * platform/qt-5.0/fast/forms/menulist-separator-painting-expected.txt: Removed.
      * platform/qt-5.0/fast/forms/select-background-none-expected.png: Removed.
      * platform/qt-5.0/fast/forms/select-background-none-expected.txt: Removed.
      * platform/qt-5.0/fast/images/embed-image-expected.txt: Removed.
      * platform/qt-5.0/fast/images/object-image-expected.txt: Removed.
      * platform/qt-5.0/fast/text/backslash-to-yen-sign-expected.txt: Removed.
      * platform/qt-5.0/fast/text/basic/003-expected.png: Removed.
      * platform/qt-5.0/fast/text/basic/003-expected.txt: Removed.
      * platform/qt-5.0/fast/text/fallback-traits-fixup-expected.txt: Removed.
      * platform/qt-5.0/fast/text/international/hindi-whitespace-expected.txt: Removed.
      * platform/qt-5.0/fast/text/international/text-spliced-font-expected.txt: Removed.
      * platform/qt-5.0/fast/text/letter-spacing-negative-opacity-expected.png: Removed.
      * platform/qt-5.0/fast/text/letter-spacing-negative-opacity-expected.txt: Removed.
      * platform/qt-5.0/fast/text/soft-hyphen-3-expected.txt: Removed.
      * platform/qt-5.0/http/tests/misc/location-replace-crossdomain-expected.png: Removed.
      * platform/qt-5.0/http/tests/misc/location-replace-crossdomain-expected.txt: Removed.
      * platform/qt-5.0/svg/W3C-SVG-1.1-SE/color-prop-05-t-expected.png: Removed.
      * platform/qt-5.0/svg/W3C-SVG-1.1-SE/filters-image-03-f-expected.png: Removed.
      * platform/qt-5.0/svg/W3C-SVG-1.1-SE/pservers-pattern-03-f-expected.png: Removed.
      * platform/qt-5.0/svg/W3C-SVG-1.1-SE/struct-use-14-f-expected.png: Removed.
      * platform/qt-5.0/svg/W3C-SVG-1.1-SE/svgdom-over-01-f-expected.png: Removed.
      * platform/qt-5.0/svg/as-image/img-preserveAspectRatio-support-1-expected.png: Removed.
      * platform/qt-5.0/svg/as-image/img-preserveAspectRatio-support-1-expected.txt: Removed.
      * platform/qt-5.0/svg/as-object/object-box-sizing-no-width-height-expected.png: Removed.
      * platform/qt-5.0/svg/as-object/object-box-sizing-no-width-height-expected.txt: Removed.
      * platform/qt-5.0/svg/batik/text/longTextOnPath-expected.png: Removed.
      * platform/qt-5.0/svg/batik/text/longTextOnPath-expected.txt: Removed.
      * platform/qt-5.0/svg/carto.net/tabgroup-expected.txt: Removed.
      * platform/qt-5.0/svg/foreignObject/text-tref-02-b-expected.png: Removed.
      * platform/qt-5.0/svg/transforms/text-with-pattern-with-svg-transform-expected.png: Removed.
      * platform/qt-5.0/svg/transforms/text-with-pattern-with-svg-transform-expected.txt: Removed.
      * platform/qt/TestExpectations:
      * platform/qt/editing/execCommand/findString-diacriticals-expected.txt: Renamed from LayoutTests/platform/qt-5.0/editing/execCommand/findString-diacriticals-expected.txt.
      * platform/qt/editing/selection/click-left-of-rtl-wrapping-text-expected.txt: Renamed from LayoutTests/platform/qt-5.0/editing/selection/click-left-of-rtl-wrapping-text-expected.txt.
      * platform/qt/fast/events/onload-re-entry-expected.png: Renamed from LayoutTests/platform/qt-5.0/fast/events/onload-re-entry-expected.png.
      * platform/qt/fast/events/onload-re-entry-expected.txt:
      * platform/qt/fast/events/touch/touch-slider-expected.txt: Renamed from LayoutTests/platform/qt-5.0/fast/events/touch/touch-slider-expected.txt.
      * platform/qt/fast/events/touch/touch-slider-no-js-touch-listener-expected.txt: Renamed from LayoutTests/platform/qt-5.0/fast/events/touch/touch-slider-no-js-touch-listener-expected.txt.
      * platform/qt/fast/forms/input-disabled-color-expected.png:
      * platform/qt/fast/forms/input-disabled-color-expected.txt:
      * platform/qt/fast/forms/menulist-separator-painting-expected.png:
      * platform/qt/fast/forms/menulist-separator-painting-expected.txt:
      * platform/qt/fast/forms/select-background-none-expected.png:
      * platform/qt/fast/forms/select-background-none-expected.txt:
      * platform/qt/fast/images/embed-image-expected.txt:
      * platform/qt/fast/images/object-image-expected.txt:
      * platform/qt/fast/text/basic/003-expected.png:
      * platform/qt/fast/text/international/text-spliced-font-expected.png: Renamed from LayoutTests/platform/qt-5.0/fast/text/international/text-spliced-font-expected.png.
      * platform/qt/fast/text/soft-hyphen-3-expected.txt:
      * platform/qt/http/tests/cookies/double-quoted-value-with-semi-colon-expected.txt: Renamed from LayoutTests/platform/qt-5.0/http/tests/cookies/double-quoted-value-with-semi-colon-expected.txt.
      * platform/qt/http/tests/misc/location-replace-crossdomain-expected.png:
      * platform/qt/http/tests/misc/location-replace-crossdomain-expected.txt:
      * platform/qt/http/tests/security/xss-DENIED-xsl-external-entity-redirect-expected.txt: Renamed from LayoutTests/platform/qt-5.0/http/tests/security/xss-DENIED-xsl-external-entity-redirect-expected.txt.
      * platform/qt/http/tests/xmlhttprequest/methods-expected.txt: Renamed from LayoutTests/platform/qt-5.0/http/tests/xmlhttprequest/methods-expected.txt.
      * platform/qt/http/tests/xmlhttprequest/workers/methods-async-expected.txt: Renamed from LayoutTests/platform/qt-5.0/http/tests/xmlhttprequest/workers/methods-async-expected.txt.
      * platform/qt/http/tests/xmlhttprequest/workers/methods-expected.txt: Renamed from LayoutTests/platform/qt-5.0/http/tests/xmlhttprequest/workers/methods-expected.txt.
      * platform/qt/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt: Renamed from LayoutTests/platform/qt-5.0/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt.
      * platform/qt/svg/W3C-SVG-1.1-SE/color-prop-05-t-expected.png:
      * platform/qt/svg/W3C-SVG-1.1-SE/filters-image-03-f-expected.png:
      * platform/qt/svg/W3C-SVG-1.1-SE/pservers-pattern-03-f-expected.png:
      * platform/qt/svg/W3C-SVG-1.1-SE/struct-use-14-f-expected.png:
      * platform/qt/svg/W3C-SVG-1.1-SE/svgdom-over-01-f-expected.png:
      * platform/qt/svg/as-image/img-preserveAspectRatio-support-1-expected.png:
      * platform/qt/svg/as-object/object-box-sizing-no-width-height-expected.png:
      * platform/qt/svg/as-object/object-box-sizing-no-width-height-expected.txt:
      * platform/qt/svg/batik/text/longTextOnPath-expected.png:
      * platform/qt/svg/batik/text/longTextOnPath-expected.txt:
      * platform/qt/svg/carto.net/tabgroup-expected.png: Renamed from LayoutTests/platform/qt-5.0/svg/carto.net/tabgroup-expected.png.
      * platform/qt/svg/carto.net/tabgroup-expected.txt:
      * platform/qt/svg/foreignObject/text-tref-02-b-expected.png:
      * platform/qt/svg/transforms/text-with-pattern-with-svg-transform-expected.png:
      * platform/qt/svg/transforms/text-with-pattern-with-svg-transform-expected.txt:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154101 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7180b8b7
    • simon.pena@samsung.com's avatar
      [GTK] Unreviewed gardening. Update test expectations. · 3f3bc838
      simon.pena@samsung.com authored
      * platform/gtk-wk1/TestExpectations: Unskip tests no longer failing.
      * platform/gtk-wk1/loader/go-back-cached-main-resource-expected.txt:
      Rebaseline after r153852.
      * platform/gtk/TestExpectations:
      * platform/gtk/fast/regions/region-dynamic-after-before-expected.txt:
      Rebaseline after r154072.
      * platform/gtk/fast/regions/region-generated-content-before-after-expected.txt:
      Rebaseline after r154072.
      * platform/gtk/security/block-test-no-port-expected.txt:
      Rebaseline after r153852.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154100 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3f3bc838
    • rwlbuis@webkit.org's avatar
      ASSERTION FAILED: !m_adoptionIsRequired in void WebCore::TreeShared<NodeType>::ref() · 7d0d8e85
      rwlbuis@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=116979
      
      Reviewed by Antti Koivisto.
      
      Source/WebCore:
      
      Make sure adoptRef is called before calling setPseudo, for all progress shadow elements.
      
      * html/shadow/ProgressShadowElement.cpp:
      (WebCore::ProgressInnerElement::ProgressInnerElement):
      (WebCore::ProgressBarElement::ProgressBarElement):
      (WebCore::ProgressValueElement::ProgressValueElement):
      * html/shadow/ProgressShadowElement.h:
      (WebCore::ProgressInnerElement::create):
      (WebCore::ProgressBarElement::create):
      (WebCore::ProgressValueElement::create):
      
      LayoutTests:
      
      Add testcase from bug with small adjustments.
      
      * svg/custom/tref-with-progress-tag-setpseudo-assert-expected.txt: Added.
      * svg/custom/tref-with-progress-tag-setpseudo-assert.html: Added.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154099 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7d0d8e85
    • simon.pena@samsung.com's avatar
      <https://webkit.org/b/119584> [Gtk] URL printing code in DumpRenderTree... · 89687684
      simon.pena@samsung.com authored
      <https://webkit.org/b/119584> [Gtk] URL printing code in DumpRenderTree doesn't match WTR or Mac DRT
      
      Reviewed by Gustavo Noronha Silva.
      
      Following a similar approach as in r153977, return a path string
      that is relative to main frame URL or just file name if the
      resource is not in the same directory subtree, and replace empty
      strings with "(null)".
      
      Source/WebKit/gtk:
      
      Update the AuthenticationCallback used in DumpRenderTree so that
      it receives a WebKitWebResource, and update
      dispatchDidReceiveAuthenticationChallenge so that it retrieves the
      WebKitWebResource and passes it to the callback.
      
      * WebCoreSupport/DumpRenderTreeSupportGtk.h: Update the
      AuthenticationCallback adding a WebKitWebResource parameter.
      * WebCoreSupport/FrameLoaderClientGtk.cpp:
      (WebKit::toString): Define this function earlier so we can use it
      to get the WebKitWebResource from the identifier in the
      AuthenticationChallenge.
      (WebKit::FrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
      Use toString to retrieve a WebKitWebResource from the identifier
      in the authentication challenge, and pass that WebKitWebResource
      to the AuthenticationCallback.
      
      Tools:
      
      Update pathFromSoupURI so it behaves more closely to the other
      ports, and remove the unused code after we no longer print
      <unknown> in certain cases. Also move
      soupURIToStringPreservingPassword to DumpRenderTreeGtk so it can
      be used both in TestRunnerGtk and in DumpRenderTree.
      
      * DumpRenderTree/gtk/DumpRenderTree.cpp:
      (soupURIToStringPreservingPassword): Moved from TestRunnerGtk so
      we can print Soup URIs with the password, since soup_uri_to_string
      doesn't preserve them.
      (pathFromSoupURI): Updated following EFL implementation in
      r153977, and return a WTFString instead of a CString.
      (convertSoupMessageToURLPath): Return "(null)" instead of empty
      strings, and handle the new return type of pathFromSoupURI.
      (convertWebResourceToURLPath): Use a GOwnPtr to hold the Soup URI
      reference, and handle the new return type of pathFromSoupURI.
      (descriptionSuitableForTestResult): Remove unused code.
      (didFinishLoading): Use convertResourceToURLPath.
      (didFailLoadingWithError): Use convertResourceToURLPath.
      (authenticationCallback): Display the URL of the authentication
      challenge.
      * DumpRenderTree/gtk/DumpRenderTreeGtk.h: Declare
      soupURIToStringPreservingPassword.
      * DumpRenderTree/gtk/TestRunnerGtk.cpp: Remove
      soupURIToStringPreservingPassword.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154098 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      89687684
    • simon.pena@samsung.com's avatar
      [GTK] Unreviewed gardening. Skip failing test. · 7530f00e
      simon.pena@samsung.com authored
      * platform/gtk-wk1/TestExpectations:
      http/tests/loading/unfinished-main-resource-back-to-cached-page-callbacks.html
      is failing.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154097 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7530f00e
    • allan.jensen@digia.com's avatar
      [Qt] fast/canvas/canvas-blending-transforms.html test fails on x32 after r153941. · cc2e6051
      allan.jensen@digia.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119792
      
      Unreviewed gardening.
      
      Speculative unskip after r154095.
      
      * platform/qt/TestExpectations:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154096 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      cc2e6051
    • allan.jensen@digia.com's avatar
      REGRESSION(r148790) Made 7 tests fail on x86 32bit · ee0f0dcc
      allan.jensen@digia.com authored
      https://bugs.webkit.org/show_bug.cgi?id=114913
      
      Reviewed by Filip Pizlo.
      
      Source/JavaScriptCore:
      
      The X87 register was not freed before some calls. Instead
      of inserting resetX87Registers to the last call sites,
      the two X87 registers are now freed in every call.
      
      * llint/LowLevelInterpreter32_64.asm:
      * llint/LowLevelInterpreter64.asm:
      * offlineasm/instructions.rb:
      * offlineasm/x86.rb:
      
      LayoutTests:
      
      Unskip the five tests now passsing again.
      
      * platform/qt/TestExpectations:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154095 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ee0f0dcc
    • simon.pena@samsung.com's avatar
      [GTK] Unreviewed gardening. Rebaseline after r154057. · f8d89c3e
      simon.pena@samsung.com authored
      * platform/gtk/fast/js/dom-static-property-for-in-iteration-expected.txt:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154094 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f8d89c3e
    • ryuan.choi@samsung.com's avatar
      [EFL] Unreviwed gardening. · 7cb987de
      ryuan.choi@samsung.com authored
      Skipped some failures.
      
      * platform/efl-wk2/TestExpectations:
      * platform/efl/TestExpectations:
      * platform/efl/fast/forms/datalist/input-list-expected.txt: Removed.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154093 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7cb987de
    • simon.pena@samsung.com's avatar
      [GTK] Unreviewed gardening. Rebaseline after r154072. · 959f0912
      simon.pena@samsung.com authored
      * platform/gtk/fast/regions/autoheight-regions-mark-expected.txt:
      * platform/gtk/fast/regions/overflow-in-uniform-regions-dynamic-expected.txt:
      * platform/gtk/fast/regions/overflow-in-variable-width-regions-expected.txt:
      * platform/gtk/fast/regions/overflow-moving-below-floats-in-variable-width-regions-expected.txt:
      * platform/gtk/fast/regions/overflow-not-moving-below-floats-in-variable-width-regions-expected.txt:
      * platform/gtk/fast/regions/overflow-rtl-in-variable-width-regions-expected.txt:
      * platform/gtk/fast/regions/overflow-size-change-in-variable-width-regions-expected.txt:
      * platform/gtk/fast/repaint/japanese-rl-selection-repaint-in-regions-expected.txt:
      * platform/gtk/fast/repaint/line-flow-with-floats-in-regions-expected.txt:
      * platform/gtk/fast/repaint/overflow-flipped-writing-mode-block-in-regions-expected.txt:
      * platform/gtk/fast/repaint/region-painting-via-layout-expected.txt:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154092 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      959f0912
    • kadam@inf.u-szeged.hu's avatar
      [Qt] Unreviwed gardening. Rebase fast tests after r154072. · 427833c7
      kadam@inf.u-szeged.hu authored
      Patch by Tamas Czene <tczene@inf.u-szeged.hu> on 2013-08-15
      
      * platform/qt-5.0-wk2/fast/repaint/region-painting-via-layout-expected.txt: Removed.
      * platform/qt/fast/regions/autoheight-regions-mark-expected.txt:
      * platform/qt/fast/regions/overflow-in-uniform-regions-dynamic-expected.png:
      * platform/qt/fast/regions/overflow-in-uniform-regions-dynamic-expected.txt:
      * platform/qt/fast/regions/overflow-in-variable-width-regions-expected.png:
      * platform/qt/fast/regions/overflow-in-variable-width-regions-expected.txt:
      * platform/qt/fast/regions/overflow-moving-below-floats-in-variable-width-regions-expected.png:
      * platform/qt/fast/regions/overflow-moving-below-floats-in-variable-width-regions-expected.txt:
      * platform/qt/fast/regions/overflow-not-moving-below-floats-in-variable-width-regions-expected.png:
      * platform/qt/fast/regions/overflow-not-moving-below-floats-in-variable-width-regions-expected.txt:
      * platform/qt/fast/regions/overflow-rtl-in-variable-width-regions-expected.png:
      * platform/qt/fast/regions/overflow-rtl-in-variable-width-regions-expected.txt:
      * platform/qt/fast/regions/overflow-size-change-in-variable-width-regions-expected.png:
      * platform/qt/fast/regions/overflow-size-change-in-variable-width-regions-expected.txt:
      * platform/qt/fast/repaint/line-flow-with-floats-in-regions-expected.png:
      * platform/qt/fast/repaint/line-flow-with-floats-in-regions-expected.txt:
      * platform/qt/fast/repaint/overflow-flipped-writing-mode-block-in-regions-expected.txt:
      * platform/qt/fast/repaint/region-painting-via-layout-expected.txt:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154091 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      427833c7
    • ap@apple.com's avatar
      Don't copy js-test-pre in cookies-test-pre · 756e5496
      ap@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119802
      
      Reviewed by Sam Weinig.
      
      * http/tests/cookies/resources/cookies-test-post.js:
      * http/tests/cookies/resources/cookies-test-pre.js:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154090 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      756e5496
  2. 14 Aug, 2013 5 commits
    • ryuan.choi@samsung.com's avatar
      <https://webkit.org/b/119786> [EFL] decoration of search type is different from other platforms · bed9dba6
      ryuan.choi@samsung.com authored
      Reviewed by Gyuyoung Kim.
      
      Source/WebCore:
      
      Other platforms except EFL port draw a magnifying icon for
      -webkit-search-results-button and -webkit-search-results-decoration in search field,
      but Efl port draws it for -webkit-search-decoration.
      
      This patch makes Efl port draw icon in first two cases like other ports.
      
      Tests: fast/css/input-search-padding.html
         fast/css/text-input-with-webkit-border-radius.html
         fast/css/text-overflow-input.html
         fast/forms/box-shadow-override.html
         fast/forms/control-restrict-line-height.html
         fast/forms/input-appearance-height.html
         fast/forms/placeholder-position.html
         fast/forms/placeholder-pseudo-style.html
         fast/forms/search-cancel-button-style-sharing.html
         fast/forms/search-display-none-cancel-button.html
         fast/forms/search-rtl.html
         fast/forms/search-vertical-alignment.html
         fast/forms/searchfield-heights.html
         fast/repaint/search-field-cancel.html
      
      * platform/efl/DefaultTheme/widget/search/cancel/search_cancel.edc:
      Moved results_button alias to search_decoration.edc
      * platform/efl/DefaultTheme/widget/search/decoration/search_decoration.edc:
      * platform/efl/RenderThemeEfl.cpp:
      Updated size of ResultsButtonStyle and ResultsDecorationStyle to show icon.
      In addition, removed adjustSearchFieldResultsButtonStyle and paintSearchFieldDecoration.
      (WebCore::toEdjeGroup): Removed decoration group.
      (WebCore::RenderThemeEfl::adjustSearchFieldResultsButtonStyle):
      (WebCore::RenderThemeEfl::adjustSearchFieldResultsDecorationStyle):
      * platform/efl/RenderThemeEfl.h:
      
      LayoutTests:
      
      Rebaseline related to input search field.
      
      * platform/efl/fast/css/input-search-padding-expected.png:
      * platform/efl/fast/css/input-search-padding-expected.txt:
      * platform/efl/fast/css/text-input-with-webkit-border-radius-expected.png:
      * platform/efl/fast/css/text-input-with-webkit-border-radius-expected.txt:
      * platform/efl/fast/css/text-overflow-input-expected.png:
      * platform/efl/fast/css/text-overflow-input-expected.txt:
      * platform/efl/fast/forms/box-shadow-override-expected.png:
      * platform/efl/fast/forms/box-shadow-override-expected.txt:
      * platform/efl/fast/forms/control-restrict-line-height-expected.png:
      * platform/efl/fast/forms/control-restrict-line-height-expected.txt:
      * platform/efl/fast/forms/input-appearance-height-expected.png:
      * platform/efl/fast/forms/input-appearance-height-expected.txt:
      * platform/efl/fast/forms/placeholder-position-expected.png:
      * platform/efl/fast/forms/placeholder-position-expected.txt:
      * platform/efl/fast/forms/placeholder-pseudo-style-expected.png:
      * platform/efl/fast/forms/placeholder-pseudo-style-expected.txt:
      * platform/efl/fast/forms/search-cancel-button-style-sharing-expected.png:
      * platform/efl/fast/forms/search-cancel-button-style-sharing-expected.txt:
      * platform/efl/fast/forms/search-display-none-cancel-button-expected.png:
      * platform/efl/fast/forms/search-display-none-cancel-button-expected.txt:
      * platform/efl/fast/forms/search-rtl-expected.png:
      * platform/efl/fast/forms/search-rtl-expected.txt:
      * platform/efl/fast/forms/search-vertical-alignment-expected.png:
      * platform/efl/fast/forms/search-vertical-alignment-expected.txt:
      * platform/efl/fast/forms/searchfield-heights-expected.png:
      * platform/efl/fast/forms/searchfield-heights-expected.txt:
      * platform/efl/fast/repaint/search-field-cancel-expected.png:
      * platform/efl/fast/repaint/search-field-cancel-expected.txt:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154089 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      bed9dba6
    • gyuyoung.kim@samsung.com's avatar
      [CSS] Introduce new structure to pass image orientation values. · 0d92f4d6
      gyuyoung.kim@samsung.com authored
      https://bugs.webkit.org/show_bug.cgi?id=119418
      
      Reviewed by Beth Dakin.
      
      Add a ImageOrientationDescription struct in order to reduce count of argument for
      image orientation.
      
      No new tests, no behavior change.
      
      * html/HTMLCanvasElement.cpp:
      (WebCore::HTMLCanvasElement::paint):
      * page/DragController.cpp:
      (WebCore::DragController::doImageDrag):
      * page/Frame.cpp:
      (WebCore::Frame::nodeImage):
      (WebCore::Frame::dragImageForSelection):
      * platform/DragImage.h:
      * platform/blackberry/DragImageBlackBerry.cpp:
      (WebCore::createDragImageFromImage):
      * platform/efl/DragImageEfl.cpp:
      (WebCore::createDragImageFromImage):
      * platform/graphics/BitmapImage.cpp:
      (WebCore::BitmapImage::updateSize):
      * platform/graphics/BitmapImage.h:
      * platform/graphics/GraphicsContext.cpp:
      (WebCore::GraphicsContext::drawImage):
      * platform/graphics/GraphicsContext.h:
      * platform/graphics/Image.cpp:
      (WebCore::Image::draw):
      * platform/graphics/Image.h:
      * platform/graphics/ImageOrientation.h:
      (WebCore::ImageOrientationDescription::ImageOrientationDescription):
      (WebCore::ImageOrientationDescription::respectImageOrientation):
      (WebCore::ImageOrientationDescription::imageOrientation):
      * platform/graphics/ImageSource.cpp:
      (WebCore::ImageSource::size):
      (WebCore::ImageSource::frameSizeAtIndex):
      * platform/graphics/ImageSource.h:
      * platform/graphics/blackberry/ImageBlackBerry.cpp:
      (WebCore::BitmapImage::draw):
      * platform/graphics/cairo/BitmapImageCairo.cpp:
      (WebCore::BitmapImage::draw):
      * platform/graphics/cairo/ImageBufferCairo.cpp:
      (WebCore::ImageBuffer::draw):
      * platform/graphics/cg/BitmapImageCG.cpp:
      (WebCore::BitmapImage::draw):
      * platform/graphics/cg/ImageSourceCG.cpp:
      (WebCore::ImageSource::frameSizeAtIndex):
      (WebCore::ImageSource::size):
      (WebCore::ImageSource::frameBytesAtIndex):
      * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
      (WebCore::MediaPlayerPrivateGStreamerBase::paint):
      * platform/graphics/qt/ImageBufferQt.cpp:
      (WebCore::ImageBuffer::draw):
      * platform/graphics/wince/ImageBufferWinCE.cpp:
      (WebCore::ImageBuffer::draw):
      * platform/gtk/ClipboardGtk.cpp:
      (WebCore::Clipboard::createDragImage):
      * platform/gtk/DragImageGtk.cpp:
      (WebCore::createDragImageFromImage):
      * platform/mac/DragImageMac.mm:
      (WebCore::createDragImageFromImage):
      * platform/qt/ClipboardQt.cpp:
      (WebCore::Clipboard::createDragImage):
      * platform/qt/DragImageQt.cpp:
      (WebCore::createDragImageFromImage):
      * platform/win/ClipboardWin.cpp:
      (WebCore::Clipboard::createDragImage):
      * platform/win/DragImageCGWin.cpp:
      (WebCore::createDragImageFromImage):
      * platform/win/DragImageCairoWin.cpp:
      (WebCore::createDragImageFromImage):
      * rendering/RenderEmbeddedObject.cpp:
      (WebCore::RenderEmbeddedObject::paintSnapshotImage):
      * rendering/RenderImage.cpp:
      (WebCore::RenderImage::paintReplaced):
      (WebCore::RenderImage::paintIntoRect):
      * rendering/RenderSnapshottedPlugIn.cpp:
      (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154088 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0d92f4d6
    • weinig@apple.com's avatar
      Update binding test results. Follow up fix for <https://webkit.org/b/119664> · f170493b
      weinig@apple.com authored
      * bindings/scripts/test/JS/JSTestCallback.cpp:
      (WebCore::JSTestCallback::JSTestCallback):
      * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
      (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154087 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f170493b
    • joepeck@webkit.org's avatar
      <https://webkit.org/b/119810> [Mac] No AutoreleasePool leaks when dragging image out of WebView · 6ca8bfa2
      joepeck@webkit.org authored
      Reviewed by Dan Bernstein.
      
      This code was just running a block of code asynchronously using a
      pthread. Convert this to use a dispatch block, which does provide
      an autorelease pool so there are no leaks and ends up much simpler.
      
      * platform/mac/FileSystemMac.mm:
      (WebCore::setMetadataURL):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154086 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6ca8bfa2
    • dino@apple.com's avatar
      <https://webkit.org/b/119827> Allow primary plug-in detection to run more than once if necessary · bfb24dbb
      dino@apple.com authored
      Reviewed by Tim Horton.
      
      We occasionally see cases where the primary plug-in detection runs before the plugins have been added
      to the page, especially if they do so in response to a load event. Tweak the algorithm so that it can
      run an arbitrary number of times if it fails.
      
      While here, also have the detection run if there has ever been a plugin in the page as opposed to any
      current views. We may have snapshotted a plugin by now and deleted its view.
      
      * WebProcess/WebPage/WebPage.cpp:
      (WebKit::WebPage::WebPage): initialise new members.
      (WebKit::WebPage::addPluginView): Mark that we've seen a plugin.
      (WebKit::WebPage::resetPrimarySnapshottedPlugIn): Reset new members.
      (WebKit::WebPage::determinePrimarySnapshottedPlugIn): Exit early if we've never
      seen a plugin, rather than if we don't have any active views. Also, if we didn't find anything set
      a timer to run again (maximum of two attempts at the moment).
      * WebProcess/WebPage/WebPage.h: New members - m_numberOfPrimarySnapshotDetectionAttempts
      and m_hasSeenPlugin.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154085 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      bfb24dbb