1. 09 Jan, 2014 2 commits
    • commit-queue@webkit.org's avatar
      Unreviewed, rolling out r161540. · 4a2c6f6e
      commit-queue@webkit.org authored
      http://trac.webkit.org/changeset/161540
      https://bugs.webkit.org/show_bug.cgi?id=126704
      
      Caused assertion failures on multiple tests (Requested by ap
      on #webkit).
      
      Source/JavaScriptCore:
      
      * bytecode/CodeBlock.cpp:
      (JSC::CodeBlock::visitAggregate):
      * bytecode/CodeBlock.h:
      (JSC::CodeBlockSet::mark):
      * dfg/DFGOperations.cpp:
      * heap/CodeBlockSet.cpp:
      (JSC::CodeBlockSet::add):
      (JSC::CodeBlockSet::traceMarked):
      * heap/CodeBlockSet.h:
      * heap/CopiedBlockInlines.h:
      (JSC::CopiedBlock::reportLiveBytes):
      * heap/CopiedSpace.cpp:
      * heap/CopiedSpace.h:
      * heap/Heap.cpp:
      (JSC::Heap::Heap):
      (JSC::Heap::didAbandon):
      (JSC::Heap::markRoots):
      (JSC::Heap::copyBackingStores):
      (JSC::Heap::collectAllGarbage):
      (JSC::Heap::collect):
      (JSC::Heap::didAllocate):
      * heap/Heap.h:
      (JSC::Heap::shouldCollect):
      (JSC::Heap::isCollecting):
      (JSC::Heap::isWriteBarrierEnabled):
      (JSC::Heap::writeBarrier):
      * heap/HeapOperation.h:
      * heap/MarkStack.cpp:
      (JSC::MarkStackArray::~MarkStackArray):
      * heap/MarkStack.h:
      * heap/MarkedAllocator.cpp:
      (JSC::MarkedAllocator::isPagedOut):
      (JSC::MarkedAllocator::tryAllocateHelper):
      (JSC::MarkedAllocator::addBlock):
      (JSC::MarkedAllocator::removeBlock):
      * heap/MarkedAllocator.h:
      (JSC::MarkedAllocator::MarkedAllocator):
      (JSC::MarkedAllocator::reset):
      * heap/MarkedBlock.cpp:
      * heap/MarkedBlock.h:
      (JSC::MarkedBlock::lastChanceToFinalize):
      (JSC::MarkedBlock::didConsumeEmptyFreeList):
      (JSC::MarkedBlock::clearMarks):
      * heap/MarkedSpace.cpp:
      (JSC::MarkedSpace::~MarkedSpace):
      (JSC::MarkedSpace::resetAllocators):
      (JSC::MarkedSpace::visitWeakSets):
      (JSC::MarkedSpace::reapWeakSets):
      * heap/MarkedSpace.h:
      (JSC::ClearMarks::operator()):
      (JSC::MarkedSpace::clearMarks):
      * heap/SlotVisitor.cpp:
      (JSC::SlotVisitor::~SlotVisitor):
      * heap/SlotVisitor.h:
      (JSC::SlotVisitor::sharedData):
      * heap/SlotVisitorInlines.h:
      (JSC::SlotVisitor::internalAppend):
      (JSC::SlotVisitor::copyLater):
      (JSC::SlotVisitor::reportExtraMemoryUsage):
      * jit/Repatch.cpp:
      * runtime/JSGenericTypedArrayViewInlines.h:
      (JSC::JSGenericTypedArrayView<Adaptor>::visitChildren):
      * runtime/JSPropertyNameIterator.h:
      (JSC::StructureRareData::setEnumerationCache):
      * runtime/JSString.cpp:
      (JSC::JSString::visitChildren):
      * runtime/StructureRareDataInlines.h:
      (JSC::StructureRareData::setPreviousID):
      (JSC::StructureRareData::setObjectToStringValue):
      * runtime/WeakMapData.cpp:
      (JSC::WeakMapData::visitChildren):
      
      Source/WTF:
      
      * wtf/Bitmap.h:
      (WTF::WordType>::count):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161557 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4a2c6f6e
    • akling@apple.com's avatar
      Shrink WatchpointSet. · 0a0bb16a
      akling@apple.com authored
      <https://webkit.org/b/126694>
      
      Reorder the members of WatchpointSet, shrinking it by 8 bytes.
      767 kB progression on Membuster3.
      
      Reviewed by Antti Koivisto.
      
      * bytecode/Watchpoint.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161554 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0a0bb16a
  2. 08 Jan, 2014 5 commits
    • mhahnenberg@apple.com's avatar
      Reverting accidental GC logging · 626c846a
      mhahnenberg@apple.com authored
      * heap/Heap.cpp:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161544 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      626c846a
    • mhahnenberg@apple.com's avatar
      Marking should be generational · 196dc9ae
      mhahnenberg@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126552
      
      Reviewed by Geoffrey Garen.
      
      Source/JavaScriptCore: 
      
      Re-marking the same objects over and over is a waste of effort. This patch implements 
      the sticky mark bit algorithm (along with our already-present write barriers) to reduce 
      overhead during garbage collection caused by rescanning objects.
      
      There are now two collection modes, EdenCollection and FullCollection. EdenCollections
      only visit new objects or objects that were added to the remembered set by a write barrier.
      FullCollections are normal collections that visit all objects regardless of their 
      generation.
      
      In this patch EdenCollections do not do anything in CopiedSpace. This will be fixed in 
      https://bugs.webkit.org/show_bug.cgi?id=126555.
      
      * bytecode/CodeBlock.cpp:
      (JSC::CodeBlock::visitAggregate):
      * bytecode/CodeBlock.h:
      (JSC::CodeBlockSet::mark):
      * dfg/DFGOperations.cpp:
      * heap/CodeBlockSet.cpp:
      (JSC::CodeBlockSet::add):
      (JSC::CodeBlockSet::traceMarked):
      (JSC::CodeBlockSet::rememberCurrentlyExecutingCodeBlocks):
      * heap/CodeBlockSet.h:
      * heap/CopiedBlockInlines.h:
      (JSC::CopiedBlock::reportLiveBytes):
      * heap/CopiedSpace.cpp:
      (JSC::CopiedSpace::didStartFullCollection):
      * heap/CopiedSpace.h:
      (JSC::CopiedSpace::heap):
      * heap/Heap.cpp:
      (JSC::Heap::Heap):
      (JSC::Heap::didAbandon):
      (JSC::Heap::markRoots):
      (JSC::Heap::copyBackingStores):
      (JSC::Heap::addToRememberedSet):
      (JSC::Heap::collectAllGarbage):
      (JSC::Heap::collect):
      (JSC::Heap::didAllocate):
      (JSC::Heap::writeBarrier):
      * heap/Heap.h:
      (JSC::Heap::isInRememberedSet):
      (JSC::Heap::operationInProgress):
      (JSC::Heap::shouldCollect):
      (JSC::Heap::isCollecting):
      (JSC::Heap::isWriteBarrierEnabled):
      (JSC::Heap::writeBarrier):
      * heap/HeapOperation.h:
      * heap/MarkStack.cpp:
      (JSC::MarkStackArray::~MarkStackArray):
      (JSC::MarkStackArray::clear):
      (JSC::MarkStackArray::fillVector):
      * heap/MarkStack.h:
      * heap/MarkedAllocator.cpp:
      (JSC::isListPagedOut):
      (JSC::MarkedAllocator::isPagedOut):
      (JSC::MarkedAllocator::tryAllocateHelper):
      (JSC::MarkedAllocator::addBlock):
      (JSC::MarkedAllocator::removeBlock):
      (JSC::MarkedAllocator::reset):
      * heap/MarkedAllocator.h:
      (JSC::MarkedAllocator::MarkedAllocator):
      * heap/MarkedBlock.cpp:
      (JSC::MarkedBlock::clearMarks):
      (JSC::MarkedBlock::clearRememberedSet):
      (JSC::MarkedBlock::clearMarksWithCollectionType):
      (JSC::MarkedBlock::lastChanceToFinalize):
      * heap/MarkedBlock.h: Changed atomSize to 16 bytes because we have no objects smaller
      than 16 bytes. This is also to pay for the additional Bitmap for the remembered set.
      (JSC::MarkedBlock::didConsumeEmptyFreeList):
      (JSC::MarkedBlock::setRemembered):
      (JSC::MarkedBlock::clearRemembered):
      (JSC::MarkedBlock::atomicClearRemembered):
      (JSC::MarkedBlock::isRemembered):
      * heap/MarkedSpace.cpp:
      (JSC::MarkedSpace::~MarkedSpace):
      (JSC::MarkedSpace::resetAllocators):
      (JSC::MarkedSpace::visitWeakSets):
      (JSC::MarkedSpace::reapWeakSets):
      (JSC::VerifyMarked::operator()):
      (JSC::MarkedSpace::clearMarks):
      * heap/MarkedSpace.h:
      (JSC::ClearMarks::operator()):
      (JSC::ClearRememberedSet::operator()):
      (JSC::MarkedSpace::didAllocateInBlock):
      (JSC::MarkedSpace::clearRememberedSet):
      * heap/SlotVisitor.cpp:
      (JSC::SlotVisitor::~SlotVisitor):
      (JSC::SlotVisitor::clearMarkStack):
      * heap/SlotVisitor.h:
      (JSC::SlotVisitor::markStack):
      (JSC::SlotVisitor::sharedData):
      * heap/SlotVisitorInlines.h:
      (JSC::SlotVisitor::internalAppend):
      (JSC::SlotVisitor::unconditionallyAppend):
      (JSC::SlotVisitor::copyLater):
      (JSC::SlotVisitor::reportExtraMemoryUsage):
      (JSC::SlotVisitor::heap):
      * jit/Repatch.cpp:
      * runtime/JSGenericTypedArrayViewInlines.h:
      (JSC::JSGenericTypedArrayView<Adaptor>::visitChildren):
      * runtime/JSPropertyNameIterator.h:
      (JSC::StructureRareData::setEnumerationCache):
      * runtime/JSString.cpp:
      (JSC::JSString::visitChildren):
      * runtime/StructureRareDataInlines.h:
      (JSC::StructureRareData::setPreviousID):
      (JSC::StructureRareData::setObjectToStringValue):
      * runtime/WeakMapData.cpp:
      (JSC::WeakMapData::visitChildren):
      
      Source/WTF: 
      
      * wtf/Bitmap.h:
      (WTF::WordType>::count): Added a cast that became necessary when Bitmap
      is used with smaller types than int32_t.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161540 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      196dc9ae
    • commit-queue@webkit.org's avatar
      [JS] Should be able to create a promise by calling the Promise constructor as a function · 6b63e87a
      commit-queue@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=126561
      
      Patch by Sam Weinig <sam@webkit.org> on 2014-01-08
      Reviewed by Geoffrey Garen.
      
      Source/JavaScriptCore:
      
      * runtime/JSPromiseConstructor.cpp:
      (JSC::JSPromiseConstructor::getCallData):
      Add support for calling the Promise constructor as a function (e.g. var p = Promise(...), note
      the missing "new").
      
      LayoutTests:
      
      * js/dom/Promise-types-expected.txt:
      * js/dom/Promise-types.html:
      Add test for using calling a Promise constructor as a function.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161538 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6b63e87a
    • commit-queue@webkit.org's avatar
      [EFL] Make FTL buildable · ad42c44c
      commit-queue@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=125777
      
      Patch by Dániel Bátyai <dbatyai.u-szeged@partner.samsung.com> on 2014-01-08
      Reviewed by Csaba Osztrogonác.
      
      .:
      
      * Source/cmake/OptionsEfl.cmake:
      * Source/cmakeconfig.h.cmake:
      
      Source/JavaScriptCore:
      
      * CMakeLists.txt:
      * ftl/FTLOSREntry.cpp:
      * ftl/FTLOSRExitCompiler.cpp:
      * llvm/library/config_llvm.h:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161498 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ad42c44c
    • zandobersek@gmail.com's avatar
      [Automake] Scripts for generated build targets do not necessarily produce their output · 36d77e02
      zandobersek@gmail.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126378
      
      Reviewed by Carlos Garcia Campos.
      
      Source/JavaScriptCore: 
      
      * GNUmakefile.am: Touch the build targets that are generated through helper scripts that don't
      assure the output is generated every time the script is invoked, most commonly due to unchanged
      input. This assures the build targets are up-to-date and can't be older that their dependencies,
      which would result in constant regeneration at every build.
      
      Source/WebCore: 
      
      * GNUmakefile.am: Touch the build targets that are generated through helper scripts that don't
      assure the output is generated every time the script is invoked, most commonly due to unchanged
      * bindings/gobject/GNUmakefile.am: Simply move the gdom-gen-symbols file into the output file
      instead of copying it if the contents differ and removing it. This again ensures that the output
      file is always newer than its dependencies, even if the input hasn't changed.
      
      Source/WebKit2: 
      
      * GNUmakefile.am: Don't pass the -n option to the ln command that links the build's include
      directories to actual source directories. This doesn't replace the original symbolic link,
      which can lead to the actual link being older than its dependencies and subsequent constant
      relinking at every build.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161497 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      36d77e02
  3. 07 Jan, 2014 8 commits
  4. 06 Jan, 2014 6 commits
    • fpizlo@apple.com's avatar
      Make the different flavors of integer arithmetic more explicit, and don't rely... · a0fb0905
      fpizlo@apple.com authored
      Make the different flavors of integer arithmetic more explicit, and don't rely on (possibly stale) results of the backwards propagator to decide integer arithmetic semantics
      https://bugs.webkit.org/show_bug.cgi?id=125519
      
      Reviewed by Geoffrey Garen.
              
      Adds the Arith::Mode enum to arithmetic nodes, which makes it explicit what sorts of
      checks and overflows the node should do. Previously this would be deduced from
      backwards analysis results.
              
      This also makes "unchecked" variants really mean that you want the int32 wrapped
      result, so ArithIMul is now done in terms of ArithMul(Unchecked). That means that the
      constant folder needs to compute exactly the result implied by ArithMode, instead of
      just folding the double result.
      
      * CMakeLists.txt:
      * GNUmakefile.list.am:
      * JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
      * JavaScriptCore.xcodeproj/project.pbxproj:
      * dfg/DFGAbstractInterpreterInlines.h:
      (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
      * dfg/DFGArithMode.cpp: Added.
      (WTF::printInternal):
      * dfg/DFGArithMode.h: Added.
      (JSC::DFG::doesOverflow):
      (JSC::DFG::shouldCheckOverflow):
      (JSC::DFG::shouldCheckNegativeZero):
      * dfg/DFGCSEPhase.cpp:
      (JSC::DFG::CSEPhase::pureCSE):
      (JSC::DFG::CSEPhase::performNodeCSE):
      * dfg/DFGConstantFoldingPhase.cpp:
      (JSC::DFG::ConstantFoldingPhase::foldConstants):
      * dfg/DFGFixupPhase.cpp:
      (JSC::DFG::FixupPhase::fixupNode):
      (JSC::DFG::FixupPhase::attemptToMakeIntegerAdd):
      * dfg/DFGGraph.cpp:
      (JSC::DFG::Graph::dump):
      * dfg/DFGNode.h:
      (JSC::DFG::Node::Node):
      (JSC::DFG::Node::hasArithMode):
      (JSC::DFG::Node::arithMode):
      (JSC::DFG::Node::setArithMode):
      * dfg/DFGSpeculativeJIT.cpp:
      (JSC::DFG::SpeculativeJIT::compileUInt32ToNumber):
      (JSC::DFG::SpeculativeJIT::compileDoubleAsInt32):
      (JSC::DFG::SpeculativeJIT::compileAdd):
      (JSC::DFG::SpeculativeJIT::compileArithSub):
      (JSC::DFG::SpeculativeJIT::compileArithNegate):
      (JSC::DFG::SpeculativeJIT::compileArithMul):
      (JSC::DFG::SpeculativeJIT::compileArithDiv):
      (JSC::DFG::SpeculativeJIT::compileArithMod):
      * dfg/DFGSpeculativeJIT.h:
      * dfg/DFGSpeculativeJIT32_64.cpp:
      (JSC::DFG::SpeculativeJIT::compile):
      * dfg/DFGSpeculativeJIT64.cpp:
      (JSC::DFG::SpeculativeJIT::compile):
      * ftl/FTLLowerDFGToLLVM.cpp:
      (JSC::FTL::LowerDFGToLLVM::compileAddSub):
      (JSC::FTL::LowerDFGToLLVM::compileArithMul):
      (JSC::FTL::LowerDFGToLLVM::compileArithDivMod):
      (JSC::FTL::LowerDFGToLLVM::compileArithNegate):
      (JSC::FTL::LowerDFGToLLVM::compileUInt32ToNumber):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161399 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a0fb0905
    • mhahnenberg@apple.com's avatar
      Add write barriers to the LLInt · 5dbd43c1
      mhahnenberg@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126527
      
      Reviewed by Filip Pizlo.
      
      This patch takes a similar approach to how write barriers work in the baseline JIT.
      We execute the write barrier at the beginning of the opcode so we don't have to
      worry about saving and restoring live registers across write barrier slow path calls
      to C code.
      
      * llint/LLIntOfflineAsmConfig.h:
      * llint/LLIntSlowPaths.cpp:
      (JSC::LLInt::llint_write_barrier_slow):
      * llint/LLIntSlowPaths.h:
      * llint/LowLevelInterpreter.asm:
      * llint/LowLevelInterpreter32_64.asm:
      * llint/LowLevelInterpreter64.asm:
      * offlineasm/arm64.rb:
      * offlineasm/instructions.rb:
      * offlineasm/x86.rb:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161377 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5dbd43c1
    • weinig@apple.com's avatar
      [JS] Implement Promise.all() · 7817ee1e
      weinig@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126510
      
      Reviewed by Gavin Barraclough.
      
      Source/JavaScriptCore: 
      
      Add Promise.all() implementation and factor out performing resolves and rejects
      on deferreds to share a bit of code. Also moves the abruptRejection helper to
      JSPromiseDeferred so it can be used in JSPromiseFunctions.
      
      * runtime/CommonIdentifiers.h:
      * runtime/JSPromiseConstructor.cpp:
      (JSC::JSPromiseConstructorFuncCast):
      (JSC::JSPromiseConstructorFuncResolve):
      (JSC::JSPromiseConstructorFuncReject):
      (JSC::JSPromiseConstructorFuncAll):
      * runtime/JSPromiseDeferred.cpp:
      (JSC::updateDeferredFromPotentialThenable):
      (JSC::performDeferredResolve):
      (JSC::performDeferredReject):
      (JSC::abruptRejection):
      * runtime/JSPromiseDeferred.h:
      * runtime/JSPromiseFunctions.cpp:
      (JSC::promiseAllCountdownFunction):
      (JSC::createPromiseAllCountdownFunction):
      * runtime/JSPromiseFunctions.h:
      * runtime/JSPromiseReaction.cpp:
      (JSC::ExecutePromiseReactionMicrotask::run):
      
      LayoutTests: 
      
      Enabled and fix the existing Promise.all() test case.
      - Promise.all() and Promise.all({}) should reject by my reading of the spec.
      Also removes the Promise.all() shim used by the crypto tests.
      
      * crypto/subtle/resources/common.js:
      * js/dom/Promise-static-all-expected.txt:
      * js/dom/Promise-static-all.html:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161365 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7817ee1e
    • fpizlo@apple.com's avatar
      Get rid of ENABLE(VALUE_PROFILER). It's on all the time now. · ba83364c
      fpizlo@apple.com authored
      Rubber stamped by Mark Hahnenberg.
      
      Source/JavaScriptCore: 
      
      * bytecode/CallLinkStatus.cpp:
      (JSC::CallLinkStatus::computeFor):
      * bytecode/CodeBlock.cpp:
      (JSC::CodeBlock::dumpValueProfiling):
      (JSC::CodeBlock::dumpArrayProfiling):
      (JSC::CodeBlock::dumpRareCaseProfile):
      (JSC::CodeBlock::dumpBytecode):
      (JSC::CodeBlock::CodeBlock):
      (JSC::CodeBlock::setNumParameters):
      (JSC::CodeBlock::shrinkToFit):
      (JSC::CodeBlock::shouldOptimizeNow):
      * bytecode/CodeBlock.h:
      (JSC::CodeBlock::valueProfileForBytecodeOffset):
      * bytecode/GetByIdStatus.cpp:
      (JSC::GetByIdStatus::computeForChain):
      (JSC::GetByIdStatus::computeFor):
      * bytecode/LazyOperandValueProfile.cpp:
      * bytecode/LazyOperandValueProfile.h:
      * bytecode/PutByIdStatus.cpp:
      (JSC::PutByIdStatus::computeFor):
      * bytecode/ValueProfile.h:
      * bytecompiler/BytecodeGenerator.cpp:
      (JSC::BytecodeGenerator::newArrayProfile):
      (JSC::BytecodeGenerator::newArrayAllocationProfile):
      (JSC::BytecodeGenerator::emitProfiledOpcode):
      * jit/GPRInfo.h:
      * jit/JIT.cpp:
      (JSC::JIT::JIT):
      (JSC::JIT::privateCompileSlowCases):
      (JSC::JIT::privateCompile):
      * jit/JIT.h:
      * jit/JITArithmetic.cpp:
      (JSC::JIT::compileBinaryArithOp):
      (JSC::JIT::emit_op_mul):
      (JSC::JIT::emit_op_div):
      * jit/JITArithmetic32_64.cpp:
      (JSC::JIT::emitBinaryDoubleOp):
      (JSC::JIT::emit_op_mul):
      (JSC::JIT::emitSlow_op_mul):
      (JSC::JIT::emit_op_div):
      * jit/JITCall.cpp:
      (JSC::JIT::emitPutCallResult):
      * jit/JITCall32_64.cpp:
      (JSC::JIT::emitPutCallResult):
      * jit/JITInlines.h:
      (JSC::JIT::appendCallWithExceptionCheckSetJSValueResultWithProfile):
      (JSC::JIT::emitValueProfilingSite):
      (JSC::JIT::emitArrayProfilingSiteForBytecodeIndex):
      (JSC::JIT::emitArrayProfileStoreToHoleSpecialCase):
      (JSC::JIT::emitArrayProfileOutOfBoundsSpecialCase):
      (JSC::arrayProfileSaw):
      (JSC::JIT::chooseArrayMode):
      * jit/JITOpcodes.cpp:
      (JSC::JIT::emit_op_get_argument_by_val):
      * jit/JITOpcodes32_64.cpp:
      (JSC::JIT::emit_op_get_argument_by_val):
      * jit/JITPropertyAccess.cpp:
      (JSC::JIT::emit_op_get_by_val):
      (JSC::JIT::emitSlow_op_get_by_val):
      (JSC::JIT::emit_op_get_by_id):
      (JSC::JIT::emit_op_get_from_scope):
      * jit/JITPropertyAccess32_64.cpp:
      (JSC::JIT::emit_op_get_by_val):
      (JSC::JIT::emitSlow_op_get_by_val):
      (JSC::JIT::emit_op_get_by_id):
      (JSC::JIT::emit_op_get_from_scope):
      * llint/LLIntOfflineAsmConfig.h:
      * llint/LLIntSlowPaths.cpp:
      (JSC::LLInt::LLINT_SLOW_PATH_DECL):
      * llint/LowLevelInterpreter.asm:
      * llint/LowLevelInterpreter32_64.asm:
      * llint/LowLevelInterpreter64.asm:
      * profiler/ProfilerBytecodeSequence.cpp:
      (JSC::Profiler::BytecodeSequence::BytecodeSequence):
      * runtime/CommonSlowPaths.cpp:
      
      Source/WTF: 
      
      * wtf/Platform.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161364 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ba83364c
    • fpizlo@apple.com's avatar
      LLInt shouldn't check for ENABLE(JIT). · 752acb36
      fpizlo@apple.com authored
      Rubber stamped by Mark Hahnenberg.
      
      * llint/LLIntCommon.h:
      * llint/LLIntOfflineAsmConfig.h:
      * llint/LLIntSlowPaths.cpp:
      (JSC::LLInt::entryOSR):
      (JSC::LLInt::LLINT_SLOW_PATH_DECL):
      * llint/LowLevelInterpreter.asm:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161356 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      752acb36
    • fpizlo@apple.com's avatar
      LLInt shouldnt check for ENABLE(JAVASCRIPT_DEBUGGER). · 3ebfeda8
      fpizlo@apple.com authored
      Rubber stamped by Mark Hahnenberg.
      
      * debugger/Debugger.h:
      (JSC::Debugger::Debugger):
      * llint/LLIntOfflineAsmConfig.h:
      * llint/LowLevelInterpreter.asm:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161353 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3ebfeda8
  5. 05 Jan, 2014 2 commits
    • weinig@apple.com's avatar
      [JS] Implement Promise.race() · c7329eb8
      weinig@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126506
      
      Reviewed by Oliver Hunt.
      
      Source/JavaScriptCore: 
      
      * runtime/CommonIdentifiers.h:
      Add identifier for "cast".
          
      * runtime/JSPromiseConstructor.cpp:
      (JSC::abruptRejection):
      Helper for the RejectIfAbrupt abstract operation.
        
      (JSC::JSPromiseConstructorFuncRace):
      Add implementation of Promise.race()
      
      LayoutTests: 
      
      Enabled and fix the existing Promise.race() test case.
      - Promise.race() and Promise.race({}) should reject by my reading of the spec.
      
      * js/dom/Promise-static-race-expected.txt:
      * js/dom/Promise-static-race.html:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161330 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c7329eb8
    • mrobinson@webkit.org's avatar
      [GTK] [CMake] Ensure that the autotools build and the CMake install the same files · 742e8e47
      mrobinson@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=116379
      
      Reviewed by Gustavo Noronha Silva.
      
      .:
      
      * Source/PlatformGTK.cmake: Install the documentation.
      * Source/cmake/OptionsCommon.cmake: Add a LIBEXEC variable for WebKit2 executables, and
      don't use the default locations on GTK+. We will get them from the CMake-provided GNU installation
      variables.
      * Source/cmake/OptionsGTK.cmake: Setup the installation variables using the ones provided
      by CMake's GNU installation directory support. Fix the definition of DATADIR. Always install
      the jsc binary.
      
      Source/JavaScriptCore:
      
      * PlatformGTK.cmake: Install API headers, gir files, and the pkg-config file.
      
      Source/WebCore:
      
      * PlatformGTK.cmake: Reformat some install directives to be consistent with the rest of them.
      Install the GObject DOM bindings headers.
      
      Source/WebKit:
      
      * PlatformGTK.cmake: Install API headers, gir files, and the pkg-config file. Move
      a couple installed and generated headers to the installed headers list.
      
      Source/WebKit2:
      
      * CMakeLists.txt: Install the plugin process to the new LIBEXEC directory, which
      for non-GTK+ platforms is the same as EXEC.
      * PlatformGTK.cmake: Install API headers, gir files, and the pkg-config file. Move
      a couple installed and generated headers to the installed headers list. Rename the
      headers list to be consistent with the WebKit1 build. No longer use a variable for
      the name of the plugin process, as it's unnecessary.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161325 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      742e8e47
  6. 04 Jan, 2014 3 commits
    • commit-queue@webkit.org's avatar
      Use Compiler macros instead of raw "final" and "override" · 2ab633bd
      commit-queue@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=126490
      
      Patch by Yusuke Suzuki <utatane.tea@gmail.com> on 2014-01-04
      Reviewed by Sam Weinig.
      
      * runtime/JSPromiseReaction.cpp:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161317 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2ab633bd
    • mrobinson@webkit.org's avatar
      [GTK] [CMake] Improve the way we locate gobject-introspection · ec412602
      mrobinson@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=126452
      
      Reviewed by Philippe Normand.
      
      .:
      
      * Source/cmake/FindGObjectIntrospection.cmake: Added.
      * Source/cmake/OptionsGTK.cmake: Load the new  FindGObjectIntrospection file.
      
      Source/JavaScriptCore:
      
      * PlatformGTK.cmake: Use the new introspection variables.
      
      Source/WebKit:
      
      * PlatformGTK.cmake: Use the new introspection variables.
      
      Source/WebKit2:
      
      * PlatformGTK.cmake: Use the new introspection variables.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161311 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ec412602
    • zandobersek@gmail.com's avatar
      Explicitly use the std:: nested name specifier when using std::pair, std::make_pair · 83a3119e
      zandobersek@gmail.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126439
      
      Reviewed by Andreas Kling.
      
      Source/JavaScriptCore: 
      
      Instead of relying on std::pair and std::make_pair symbols being present in the current scope
      through the pair and make_pair symbols, the std:: specifier should be used explicitly.
      
      * bytecode/Opcode.cpp:
      (JSC::compareOpcodePairIndices):
      (JSC::OpcodeStats::~OpcodeStats):
      * bytecompiler/BytecodeGenerator.cpp:
      (JSC::BytecodeGenerator::BytecodeGenerator):
      * parser/ASTBuilder.h:
      (JSC::ASTBuilder::makeBinaryNode):
      * parser/Parser.cpp:
      (JSC::Parser<LexerType>::parseIfStatement):
      * runtime/Structure.cpp:
      (JSC::StructureTransitionTable::contains):
      (JSC::StructureTransitionTable::get):
      (JSC::StructureTransitionTable::add):
      
      Source/WebCore: 
      
      Instead of relying on std::pair and std::make_pair symbols being present in the current scope
      through the pair and make_pair symbols, the std:: specifier should be used explicitly.
      
      * Modules/webdatabase/DatabaseTracker.cpp:
      (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
      * accessibility/AXObjectCache.h:
      * accessibility/AccessibilityARIAGridCell.cpp:
      (WebCore::AccessibilityARIAGridCell::rowIndexRange):
      (WebCore::AccessibilityARIAGridCell::columnIndexRange):
      * accessibility/AccessibilityARIAGridCell.h:
      * accessibility/AccessibilityObject.h:
      * accessibility/AccessibilityRenderObject.cpp:
      (WebCore::AccessibilityRenderObject::mathPrescripts):
      (WebCore::AccessibilityRenderObject::mathPostscripts):
      * accessibility/AccessibilityTable.cpp:
      (WebCore::AccessibilityTable::cellForColumnAndRow):
      * accessibility/AccessibilityTableCell.cpp:
      (WebCore::AccessibilityTableCell::rowIndexRange):
      (WebCore::AccessibilityTableCell::columnIndexRange):
      * accessibility/AccessibilityTableCell.h:
      * accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
      (webkitAccessibleTableGetColumnAtIndex):
      (webkitAccessibleTableGetRowAtIndex):
      (webkitAccessibleTableGetColumnExtentAt):
      (webkitAccessibleTableGetRowExtentAt):
      (webkitAccessibleTableGetColumnHeader):
      (webkitAccessibleTableGetRowHeader):
      * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
      (-[WebAccessibilityObjectWrapper accessibilityHeaderElements]):
      (-[WebAccessibilityObjectWrapper accessibilityRowRange]):
      (-[WebAccessibilityObjectWrapper accessibilityColumnRange]):
      * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
      (convertMathPairsToNSArray):
      * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
      (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
      * bindings/js/SerializedScriptValue.cpp:
      * dom/ContainerNode.cpp:
      * dom/StyledElement.cpp:
      (WebCore::attributeNameSort):
      * html/MediaFragmentURIParser.cpp:
      (WebCore::MediaFragmentURIParser::parseTimeFragment):
      * html/parser/HTMLMetaCharsetParser.h:
      * inspector/ContentSearchUtils.cpp:
      (WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
      (WebCore::ContentSearchUtils::searchInTextByLines):
      * inspector/DOMPatchSupport.cpp:
      (WebCore::DOMPatchSupport::diff):
      (WebCore::DOMPatchSupport::innerPatchChildren):
      * inspector/DOMPatchSupport.h:
      * inspector/InspectorAgent.cpp:
      (WebCore::InspectorAgent::enable):
      (WebCore::InspectorAgent::evaluateForTestInFrontend):
      * inspector/InspectorAgent.h:
      * loader/FormSubmission.cpp:
      (WebCore::FormSubmission::create):
      * loader/cache/CachedImage.cpp:
      (WebCore::CachedImage::brokenImage):
      * loader/cache/CachedImage.h:
      * platform/URL.cpp:
      (WebCore::findHostnamesInMailToURL):
      (WebCore::encodeHostnames):
      * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
      * platform/graphics/FontCache.cpp:
      (WebCore::FontCache::getCachedFontData):
      * platform/graphics/WidthIterator.cpp:
      * platform/network/HTTPHeaderMap.cpp:
      (WebCore::HTTPHeaderMap::adopt):
      * platform/network/ResourceResponseBase.cpp:
      (WebCore::ResourceResponseBase::parseCacheControlDirectives):
      (WebCore::parseCacheHeader):
      * platform/text/AtomicStringKeyedMRUCache.h:
      * platform/text/LineBreakIteratorPoolICU.h:
      * rendering/InlineFlowBox.h:
      * rendering/RenderImage.cpp:
      (WebCore::RenderImage::imageSizeForError):
      (WebCore::RenderImage::paintReplaced):
      * rendering/RenderTableSection.cpp:
      (WebCore::RenderTableSection::cachedCollapsedBorder):
      * rendering/RenderTableSection.h:
      * rendering/svg/SVGTextRunRenderingContext.cpp:
      (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
      * svg/SVGAnimatedAngle.cpp:
      (WebCore::SVGAnimatedAngleAnimator::constructFromString):
      (WebCore::SVGAnimatedAngleAnimator::addAnimatedTypes):
      (WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue):
      * svg/SVGAnimatedIntegerOptionalInteger.cpp:
      (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::constructFromString):
      (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::addAnimatedTypes):
      (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::calculateAnimatedValue):
      * svg/SVGAnimatedNumberOptionalNumber.cpp:
      (WebCore::SVGAnimatedNumberOptionalNumberAnimator::constructFromString):
      (WebCore::SVGAnimatedNumberOptionalNumberAnimator::addAnimatedTypes):
      (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateAnimatedValue):
      * svg/SVGAnimatedType.cpp:
      (WebCore::SVGAnimatedType::createIntegerOptionalInteger):
      (WebCore::SVGAnimatedType::createNumberOptionalNumber):
      * svg/SVGAnimatedType.h:
      (WebCore::SVGAnimatedType::integerOptionalInteger):
      (WebCore::SVGAnimatedType::numberOptionalNumber):
      * svg/SVGAnimatedTypeAnimator.h:
      (WebCore::SVGAnimatedTypeAnimator::constructFromBaseValues):
      (WebCore::SVGAnimatedTypeAnimator::resetFromBaseValues):
      * svg/SVGParserUtilities.h:
      * svg/animation/SMILTimeContainer.h:
      
      Source/WebKit/mac: 
      
      Instead of relying on std::pair and std::make_pair symbols being present in the current scope
      through the pair and make_pair symbols, the std:: specifier should be used explicitly.
      
      * Plugins/Hosted/NetscapePluginInstanceProxy.h:
      * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
      (WebKit::NetscapePluginInstanceProxy::LocalObjectMap::idForObject):
      (WebKit::NetscapePluginInstanceProxy::LocalObjectMap::retain):
      (WebKit::NetscapePluginInstanceProxy::LocalObjectMap::release):
      (WebKit::NetscapePluginInstanceProxy::LocalObjectMap::forget):
      
      Source/WebKit2: 
      
      Instead of relying on std::pair and std::make_pair symbols being present in the current scope
      through the pair and make_pair symbols, the std:: specifier should be used explicitly.
      
      * Shared/mac/ArgumentCodersMac.mm:
      (IPC::encode):
      * UIProcess/Notifications/WebNotificationManagerProxy.cpp:
      (WebKit::WebNotificationManagerProxy::show):
      (WebKit::WebNotificationManagerProxy::cancel):
      (WebKit::WebNotificationManagerProxy::didDestroyNotification):
      * UIProcess/Notifications/WebNotificationManagerProxy.h:
      * UIProcess/WebContext.cpp:
      (WebKit::WebContext::createNewWebProcess):
      * UIProcess/WebContext.h:
      
      Source/WTF: 
      
      * wtf/VectorTraits.h: Stop bringing std::pair into the current scope.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161309 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      83a3119e
  7. 03 Jan, 2014 2 commits
  8. 02 Jan, 2014 6 commits
    • weinig@apple.com's avatar
      Update Promises to the https://github.com/domenic/promises-unwrapping spec · 349af4e4
      weinig@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=120954
      
      Reviewed by Filip Pizlo.
      
      Source/JavaScriptCore: 
      
      Update Promises to the revised spec. Notable changes:
      - JSPromiseResolver is gone.
      - TaskContext has been renamed Microtask and now has a virtual run() function.
      - Instead of using custom InternalFunction subclasses, JSFunctions are used
        with PrivateName properties for internal slots.
      
      * CMakeLists.txt:
      * DerivedSources.make:
      * GNUmakefile.list.am:
      * JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
      * JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters:
      * JavaScriptCore.xcodeproj/project.pbxproj:
      * interpreter/CallFrame.h:
      (JSC::ExecState::promiseConstructorTable):
      * runtime/CommonIdentifiers.cpp:
      (JSC::CommonIdentifiers::CommonIdentifiers):
      * runtime/CommonIdentifiers.h:
      * runtime/JSGlobalObject.cpp:
      (JSC::JSGlobalObject::reset):
      (JSC::JSGlobalObject::visitChildren):
      (JSC::JSGlobalObject::queueMicrotask):
      * runtime/JSGlobalObject.h:
      (JSC::JSGlobalObject::promiseConstructor):
      (JSC::JSGlobalObject::promisePrototype):
      (JSC::JSGlobalObject::promiseStructure):
      * runtime/JSPromise.cpp:
      (JSC::JSPromise::create):
      (JSC::JSPromise::JSPromise):
      (JSC::JSPromise::finishCreation):
      (JSC::JSPromise::visitChildren):
      (JSC::JSPromise::reject):
      (JSC::JSPromise::resolve):
      (JSC::JSPromise::appendResolveReaction):
      (JSC::JSPromise::appendRejectReaction):
      (JSC::triggerPromiseReactions):
      * runtime/JSPromise.h:
      (JSC::JSPromise::status):
      (JSC::JSPromise::result):
      (JSC::JSPromise::constructor):
      * runtime/JSPromiseCallback.cpp: Removed.
      * runtime/JSPromiseCallback.h: Removed.
      * runtime/JSPromiseConstructor.cpp:
      (JSC::constructPromise):
      (JSC::JSPromiseConstructor::getCallData):
      (JSC::JSPromiseConstructorFuncCast):
      (JSC::JSPromiseConstructorFuncResolve):
      (JSC::JSPromiseConstructorFuncReject):
      * runtime/JSPromiseConstructor.h:
      * runtime/JSPromiseDeferred.cpp: Added.
      (JSC::JSPromiseDeferred::create):
      (JSC::JSPromiseDeferred::JSPromiseDeferred):
      (JSC::JSPromiseDeferred::finishCreation):
      (JSC::JSPromiseDeferred::visitChildren):
      (JSC::createJSPromiseDeferredFromConstructor):
      (JSC::updateDeferredFromPotentialThenable):
      * runtime/JSPromiseDeferred.h: Added.
      (JSC::JSPromiseDeferred::createStructure):
      (JSC::JSPromiseDeferred::promise):
      (JSC::JSPromiseDeferred::resolve):
      (JSC::JSPromiseDeferred::reject):
      * runtime/JSPromiseFunctions.cpp: Added.
      (JSC::deferredConstructionFunction):
      (JSC::createDeferredConstructionFunction):
      (JSC::identifyFunction):
      (JSC::createIdentifyFunction):
      (JSC::promiseAllCountdownFunction):
      (JSC::createPromiseAllCountdownFunction):
      (JSC::promiseResolutionHandlerFunction):
      (JSC::createPromiseResolutionHandlerFunction):
      (JSC::rejectPromiseFunction):
      (JSC::createRejectPromiseFunction):
      (JSC::resolvePromiseFunction):
      (JSC::createResolvePromiseFunction):
      (JSC::throwerFunction):
      (JSC::createThrowerFunction):
      * runtime/JSPromiseFunctions.h: Added.
      * runtime/JSPromisePrototype.cpp:
      (JSC::JSPromisePrototypeFuncThen):
      (JSC::JSPromisePrototypeFuncCatch):
      * runtime/JSPromiseReaction.cpp: Added.
      (JSC::createExecutePromiseReactionMicroTask):
      (JSC::ExecutePromiseReactionMicroTask::run):
      (JSC::JSPromiseReaction::create):
      (JSC::JSPromiseReaction::JSPromiseReaction):
      (JSC::JSPromiseReaction::finishCreation):
      (JSC::JSPromiseReaction::visitChildren):
      * runtime/JSPromiseReaction.h: Added.
      (JSC::JSPromiseReaction::createStructure):
      (JSC::JSPromiseReaction::deferred):
      (JSC::JSPromiseReaction::handler):
      * runtime/JSPromiseResolver.cpp: Removed.
      * runtime/JSPromiseResolver.h: Removed.
      * runtime/JSPromiseResolverConstructor.cpp: Removed.
      * runtime/JSPromiseResolverConstructor.h: Removed.
      * runtime/JSPromiseResolverPrototype.cpp: Removed.
      * runtime/JSPromiseResolverPrototype.h: Removed.
      * runtime/Microtask.h: Added.
      * runtime/VM.cpp:
      (JSC::VM::VM):
      (JSC::VM::~VM):
      * runtime/VM.h:
      
      Source/WebCore: 
      
      * ForwardingHeaders/runtime/JSPromiseDeferred.h: Added.
      * ForwardingHeaders/runtime/JSPromiseResolver.h: Removed.
      * bindings/js/JSDOMGlobalObjectTask.cpp:
      (WebCore::JSGlobalObjectTask::JSGlobalObjectTask):
      * bindings/js/JSDOMGlobalObjectTask.h:
      * bindings/js/JSDOMPromise.cpp:
      (WebCore::DeferredWrapper::DeferredWrapper):
      (WebCore::DeferredWrapper::promise):
      (WebCore::DeferredWrapper::resolve):
      (WebCore::DeferredWrapper::reject):
      * bindings/js/JSDOMPromise.h:
      (WebCore::DeferredWrapper::resolve):
      (WebCore::DeferredWrapper::reject):
      (WebCore::DeferredWrapper::resolve<String>):
      (WebCore::DeferredWrapper::resolve<bool>):
      (WebCore::char>>):
      (WebCore::DeferredWrapper::reject<String>):
      * bindings/js/JSDOMWindowBase.cpp:
      (WebCore::JSDOMWindowBase::queueTaskToEventLoop):
      * bindings/js/JSDOMWindowBase.h:
      * bindings/js/JSSubtleCryptoCustom.cpp:
      (WebCore::JSSubtleCrypto::encrypt):
      (WebCore::JSSubtleCrypto::decrypt):
      (WebCore::JSSubtleCrypto::sign):
      (WebCore::JSSubtleCrypto::verify):
      (WebCore::JSSubtleCrypto::digest):
      (WebCore::JSSubtleCrypto::generateKey):
      (WebCore::JSSubtleCrypto::importKey):
      (WebCore::JSSubtleCrypto::exportKey):
      (WebCore::JSSubtleCrypto::wrapKey):
      (WebCore::JSSubtleCrypto::unwrapKey):
      * bindings/js/JSWorkerGlobalScopeBase.cpp:
      (WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):
      * bindings/js/JSWorkerGlobalScopeBase.h:
      
      LayoutTests: 
      
      * crypto/subtle/argument-conversion.html:
      * crypto/subtle/resources/common.js:
      * crypto/subtle/sha-1.html:
      * crypto/subtle/sha-224.html:
      * crypto/subtle/sha-256.html:
      * crypto/subtle/sha-384.html:
      * crypto/subtle/sha-512.html:
      * js/dom/Promise-already-fulfilled-expected.txt: Removed.
      * js/dom/Promise-already-fulfilled.html: Removed.
      * js/dom/Promise-already-rejected.html:
      * js/dom/Promise-already-resolved.html:
      * js/dom/Promise-catch-expected.txt:
      * js/dom/Promise-catch-in-workers-expected.txt:
      * js/dom/Promise-catch.html:
      * js/dom/Promise-chain.html:
      * js/dom/Promise-exception-expected.txt:
      * js/dom/Promise-exception.html:
      * js/dom/Promise-expected.txt:
      * js/dom/Promise-fulfill-expected.txt: Removed.
      * js/dom/Promise-fulfill-in-workers-expected.txt: Removed.
      * js/dom/Promise-fulfill-in-workers.html: Removed.
      * js/dom/Promise-fulfill.html: Removed.
      * js/dom/Promise-init-callback-receiver-expected.txt: Added.
      * js/dom/Promise-init-callback-receiver.html: Added.
      * js/dom/Promise-init-expected.txt:
      * js/dom/Promise-init-in-workers-expected.txt:
      * js/dom/Promise-init.html:
      * js/dom/Promise-onFulfilled-deep-expected.txt: Added.
      * js/dom/Promise-onFulfilled-deep.html: Added.
      * js/dom/Promise-onRejected-deep-expected.txt: Added.
      * js/dom/Promise-onRejected-deep.html: Added.
      * js/dom/Promise-reject.html:
      * js/dom/Promise-resolve-chain.html:
      * js/dom/Promise-resolve-expected.txt:
      * js/dom/Promise-resolve-in-workers-expected.txt:
      * js/dom/Promise-resolve-state-expected.txt: Added.
      * js/dom/Promise-resolve-state-in-workers-expected.txt: Added.
      * js/dom/Promise-resolve-state-in-workers.html: Added.
      * js/dom/Promise-resolve-state.html: Added.
      * js/dom/Promise-resolve-with-itself-expected.txt: Added.
      * js/dom/Promise-resolve-with-itself.html: Added.
      * js/dom/Promise-resolve-with-then-exception.html:
      * js/dom/Promise-resolve-with-then-fulfill-expected.txt:
      * js/dom/Promise-resolve-with-then-fulfill.html:
      * js/dom/Promise-resolve-with-then-reject-expected.txt:
      * js/dom/Promise-resolve-with-then-reject.html:
      * js/dom/Promise-resolve.html:
      * js/dom/Promise-simple-expected.txt:
      * js/dom/Promise-simple-fulfill-expected.txt: Removed.
      * js/dom/Promise-simple-fulfill-inside-callback-expected.txt: Removed.
      * js/dom/Promise-simple-fulfill-inside-callback.html: Removed.
      * js/dom/Promise-simple-fulfill.html: Removed.
      * js/dom/Promise-simple-in-workers-expected.txt:
      * js/dom/Promise-simple-resolve-expected.txt: Added.
      * js/dom/Promise-simple-resolve.html: Added.
      * js/dom/Promise-simple.html:
      * js/dom/Promise-static-all-expected.txt: Added.
      * js/dom/Promise-static-all.html: Added.
      * js/dom/Promise-static-cast-expected.txt: Added.
      * js/dom/Promise-static-cast.html: Added.
      * js/dom/Promise-static-fulfill-expected.txt: Removed.
      * js/dom/Promise-static-fulfill.html: Removed.
      * js/dom/Promise-static-race-expected.txt: Added.
      * js/dom/Promise-static-race.html: Added.
      * js/dom/Promise-static-resolve.html:
      * js/dom/Promise-then-callback-receiver-expected.txt: Added.
      * js/dom/Promise-then-callback-receiver.html: Added.
      * js/dom/Promise-then-expected.txt:
      * js/dom/Promise-then-in-workers-expected.txt:
      * js/dom/Promise-then-without-callbacks.html:
      * js/dom/Promise-then.html:
      * js/dom/Promise-types-expected.txt:
      * js/dom/Promise-types.html:
      * js/dom/Promise.html:
      * js/resources/Promise-catch-in-workers.js:
      * js/resources/Promise-fulfill-in-workers.js: Removed.
      * js/resources/Promise-init-in-workers.js:
      * js/resources/Promise-reject-in-workers.js:
      * js/resources/Promise-resolve-in-workers.js:
      * js/resources/Promise-resolve-state-in-workers.js: Added.
      * js/resources/Promise-simple-in-workers.js:
      * js/resources/Promise-then-in-workers.js:
      * js/resources/Promise-then-without-callbacks-in-workers.js:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161241 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      349af4e4
    • mhahnenberg@apple.com's avatar
      Add support for StoreBarrier and friends to the FTL · 72454da3
      mhahnenberg@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126040
      
      Reviewed by Filip Pizlo.
      
      * ftl/FTLAbstractHeapRepository.h:
      * ftl/FTLCapabilities.cpp:
      (JSC::FTL::canCompile):
      * ftl/FTLIntrinsicRepository.h:
      * ftl/FTLLowerDFGToLLVM.cpp:
      (JSC::FTL::LowerDFGToLLVM::compileNode):
      (JSC::FTL::LowerDFGToLLVM::compileStoreBarrier):
      (JSC::FTL::LowerDFGToLLVM::compileConditionalStoreBarrier):
      (JSC::FTL::LowerDFGToLLVM::compileStoreBarrierWithNullCheck):
      (JSC::FTL::LowerDFGToLLVM::loadMarkByte):
      (JSC::FTL::LowerDFGToLLVM::emitStoreBarrier):
      * heap/Heap.cpp:
      (JSC::Heap::Heap):
      * heap/Heap.h:
      (JSC::Heap::writeBarrierBuffer):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161240 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      72454da3
    • mhahnenberg@apple.com's avatar
      Storing new CopiedSpace memory into a JSObject should fire a write barrier · ebf01914
      mhahnenberg@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126025
      
      Reviewed by Filip Pizlo.
      
      Technically this is creating a pointer between a (potentially) old generation object and a young
      generation chunk of memory, thus there needs to be a barrier.
      
      * JavaScriptCore.xcodeproj/project.pbxproj:
      * dfg/DFGOperations.cpp:
      * heap/CopyWriteBarrier.h: Added. This class functions similarly to the WriteBarrier class. It
      acts as a proxy for pointers to CopiedSpace. Assignments to the field cause a write barrier to
      fire for the object that is the owner of the CopiedSpace memory. This is to ensure during nursery
      collections that objects with new backing stores are visited, even if they are old generation objects.
      (JSC::CopyWriteBarrier::CopyWriteBarrier):
      (JSC::CopyWriteBarrier::operator!):
      (JSC::CopyWriteBarrier::operator UnspecifiedBoolType*):
      (JSC::CopyWriteBarrier::get):
      (JSC::CopyWriteBarrier::operator*):
      (JSC::CopyWriteBarrier::operator->):
      (JSC::CopyWriteBarrier::set):
      (JSC::CopyWriteBarrier::setWithoutWriteBarrier):
      (JSC::CopyWriteBarrier::clear):
      * heap/Heap.h:
      * runtime/JSArray.cpp:
      (JSC::JSArray::unshiftCountSlowCase):
      (JSC::JSArray::shiftCountWithArrayStorage):
      (JSC::JSArray::unshiftCountWithArrayStorage):
      * runtime/JSCell.h:
      (JSC::JSCell::unvalidatedStructure):
      * runtime/JSGenericTypedArrayViewInlines.h:
      (JSC::JSGenericTypedArrayView<Adaptor>::slowDownAndWasteMemory):
      * runtime/JSObject.cpp:
      (JSC::JSObject::copyButterfly):
      (JSC::JSObject::getOwnPropertySlotByIndex):
      (JSC::JSObject::putByIndex):
      (JSC::JSObject::enterDictionaryIndexingModeWhenArrayStorageAlreadyExists):
      (JSC::JSObject::createInitialIndexedStorage):
      (JSC::JSObject::createArrayStorage):
      (JSC::JSObject::deletePropertyByIndex):
      (JSC::JSObject::getOwnPropertyNames):
      (JSC::JSObject::putByIndexBeyondVectorLengthWithoutAttributes):
      (JSC::JSObject::countElements):
      (JSC::JSObject::increaseVectorLength):
      (JSC::JSObject::ensureLengthSlow):
      * runtime/JSObject.h:
      (JSC::JSObject::butterfly):
      (JSC::JSObject::setStructureAndButterfly):
      (JSC::JSObject::setButterflyWithoutChangingStructure):
      (JSC::JSObject::JSObject):
      (JSC::JSObject::putDirectInternal):
      (JSC::JSObject::putDirectWithoutTransition):
      * runtime/MapData.cpp:
      (JSC::MapData::ensureSpaceForAppend):
      * runtime/Structure.cpp:
      (JSC::Structure::materializePropertyMap):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161230 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ebf01914
    • oliver@apple.com's avatar
      Refactor PutPropertySlot to be aware of custom properties · 6884841a
      oliver@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=126187
      
      Reviewed by Antti Koivisto.
      
      Source/JavaScriptCore:
      
      Refactor PutPropertySlot, making the constructor take the thisValue
      used as a target.  This results in a wide range of boilerplate changes
      to pass the new parameter.
      
      * API/JSObjectRef.cpp:
      (JSObjectSetProperty):
      * dfg/DFGOperations.cpp:
      (JSC::DFG::operationPutByValInternal):
      * interpreter/Interpreter.cpp:
      (JSC::Interpreter::execute):
      * jit/JITOperations.cpp:
      * llint/LLIntSlowPaths.cpp:
      (JSC::LLInt::LLINT_SLOW_PATH_DECL):
      * runtime/Arguments.cpp:
      (JSC::Arguments::putByIndex):
      * runtime/ArrayPrototype.cpp:
      (JSC::putProperty):
      (JSC::arrayProtoFuncPush):
      * runtime/JSCJSValue.cpp:
      (JSC::JSValue::putToPrimitiveByIndex):
      * runtime/JSCell.cpp:
      (JSC::JSCell::putByIndex):
      * runtime/JSFunction.cpp:
      (JSC::JSFunction::put):
      * runtime/JSGenericTypedArrayViewInlines.h:
      (JSC::JSGenericTypedArrayView<Adaptor>::putByIndex):
      * runtime/JSONObject.cpp:
      (JSC::Walker::walk):
      * runtime/JSObject.cpp:
      (JSC::JSObject::putByIndex):
      (JSC::JSObject::putDirectNonIndexAccessor):
      (JSC::JSObject::deleteProperty):
      * runtime/JSObject.h:
      (JSC::JSObject::putDirect):
      * runtime/Lookup.h:
      (JSC::putEntry):
      (JSC::lookupPut):
      * runtime/PutPropertySlot.h:
      (JSC::PutPropertySlot::PutPropertySlot):
      (JSC::PutPropertySlot::setCustomProperty):
      (JSC::PutPropertySlot::thisValue):
      (JSC::PutPropertySlot::isCacheable):
      
      Source/WebCore:
      
      Update the bindings code generation and custom objects
      to the new function signatures
      
      * bindings/js/JSDOMWindowCustom.cpp:
      (WebCore::JSDOMWindow::put):
      * bindings/objc/WebScriptObject.mm:
      (-[WebScriptObject setValue:forKey:]):
      * bindings/scripts/CodeGeneratorJS.pm:
      (GenerateImplementation):
      * bindings/scripts/test/JS/JSTestInterface.cpp:
      (WebCore::JSTestInterface::putByIndex):
      * bridge/NP_jsobject.cpp:
      (_NPN_SetProperty):
      
      Source/WebKit/mac:
      
      Update for new method signatures.
      
      * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
      (WebKit::NetscapePluginInstanceProxy::setProperty):
      
      Source/WebKit2:
      
      Update for new method signatures.
      
      * WebProcess/Plugins/Netscape/NPJSObject.cpp:
      (WebKit::NPJSObject::setProperty):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161220 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6884841a
    • fpizlo@apple.com's avatar
      Rationalize DFG DCE · 9775655d
      fpizlo@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=125523
      
      Reviewed by Mark Hahnenberg.
              
      Adds the ability to DCE more things. It's now the case that if a node is completely
      pure, we clear NodeMustGenerate and the node becomes a DCE candidate.
      
      * dfg/DFGAbstractInterpreterInlines.h:
      (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
      * dfg/DFGCSEPhase.cpp:
      (JSC::DFG::CSEPhase::performNodeCSE):
      * dfg/DFGClobberize.h:
      (JSC::DFG::clobberize):
      * dfg/DFGDCEPhase.cpp:
      (JSC::DFG::DCEPhase::cleanVariables):
      * dfg/DFGFixupPhase.cpp:
      (JSC::DFG::FixupPhase::fixupNode):
      * dfg/DFGGraph.h:
      (JSC::DFG::Graph::clobbersWorld):
      * dfg/DFGNodeType.h:
      * dfg/DFGSpeculativeJIT.cpp:
      (JSC::DFG::SpeculativeJIT::compileAdd):
      * dfg/DFGSpeculativeJIT.h:
      * dfg/DFGSpeculativeJIT32_64.cpp:
      (JSC::DFG::SpeculativeJIT::compile):
      * dfg/DFGSpeculativeJIT64.cpp:
      (JSC::DFG::SpeculativeJIT::compile):
      * ftl/FTLLowerDFGToLLVM.cpp:
      (JSC::FTL::LowerDFGToLLVM::compileNode):
      (JSC::FTL::LowerDFGToLLVM::compileValueAdd):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161218 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9775655d
    • benjamin@webkit.org's avatar
      Attempt to fix the build of WebCore's code generator on CMake based system · c2a7dfd9
      benjamin@webkit.org authored
      https://bugs.webkit.org/show_bug.cgi?id=126271
      
      Reviewed by Sam Weinig.
      
      * CMakeLists.txt:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161206 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c2a7dfd9
  9. 30 Dec, 2013 6 commits