FTL: Refactor compileArithDiv and compileArithMod into one function.
https://bugs.webkit.org/show_bug.cgi?id=122205

Patch by Nadav Rotem <nrotem@apple.com> on 2013-10-02
Reviewed by Filip Pizlo.

* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileNode):
(JSC::FTL::LowerDFGToLLVM::compileAddSub):
(JSC::FTL::LowerDFGToLLVM::compileArithDivMod):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156784 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Implement prefixed-destructuring assignment
https://bugs.webkit.org/show_bug.cgi?id=121930

Reviewed by Mark Hahnenberg.

Source/JavaScriptCore:

Relanding with fix after rollout - it helps to not completely destroy
optimisations for no reason.

LayoutTests:

Relanding with fix after rollout - it helps to not completely destroy
optimisations for no reason.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156785 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Move AHEM____.TTF from qt/fonts/ to fonts/.

Rubber-stamped by Andreas Kling.

* DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
* DumpRenderTree/fonts/AHEM____.TTF: Renamed from Tools/DumpRenderTree/qt/fonts/AHEM____.TTF.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156786 268f45cc-cd09-0410-ab3c-d52691b4dbfc
get_callee and to_this aren't properly cleared during finalizeUnconditionally
https://bugs.webkit.org/show_bug.cgi?id=122224

Reviewed by Geoffrey Garen.

Even though there is code to clear unmarked inline cache objects in finalizeUnconditionally,
it will never run because get_callee and to_this weren't added to the proper Vector in the
UnlinkedCodeBlock that is iterated during finalizeUnconditionally.

* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
(JSC::BytecodeGenerator::emitCreateThis):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156787 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Clean up more <style scoped> from style resolution
https://bugs.webkit.org/show_bug.cgi?id=122188

Reviewed by Darin Adler.

* css/ElementRuleCollector.cpp:
(WebCore::MatchRequest::MatchRequest):
(WebCore::ElementRuleCollector::collectMatchingRules):
(WebCore::ElementRuleCollector::collectMatchingRulesForRegion):
(WebCore::ElementRuleCollector::matchAuthorRules):
(WebCore::ElementRuleCollector::ruleMatches):
(WebCore::ElementRuleCollector::doCollectMatchingRulesForList):
* css/ElementRuleCollector.h:
* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::matchRecursively):
* css/SelectorChecker.h:
(WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
* dom/SelectorQuery.cpp:
(WebCore::SelectorDataList::selectorMatches):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156788 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Windows] Unreviewed build fix.

* WebScriptWorld.cpp:
(WebScriptWorld::findOrCreateWorld):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156789 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Implement Array key, value and entries iterators
https://bugs.webkit.org/show_bug.cgi?id=122195

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

Add implementation of ES6 Array iterators for keys(), values() and entries()

Fairly self explanatory as we just need a simple implementation so that we can
implement and test other features.

* JavaScriptCore.xcodeproj/project.pbxproj:
* runtime/ArrayIteratorConstructor.cpp: Added.
(JSC::ArrayIteratorConstructor::finishCreation):
* runtime/ArrayIteratorConstructor.h: Added.
(JSC::ArrayIteratorConstructor::create):
(JSC::ArrayIteratorConstructor::createStructure):
(JSC::ArrayIteratorConstructor::ArrayIteratorConstructor):
* runtime/ArrayIteratorPrototype.cpp: Added.
(JSC::ArrayIteratorPrototype::finishCreation):
(JSC::createIteratorResult):
(JSC::arrayIteratorPrototypeNext):
* runtime/ArrayIteratorPrototype.h: Added.
(JSC::ArrayIteratorPrototype::create):
(JSC::ArrayIteratorPrototype::createStructure):
(JSC::ArrayIteratorPrototype::ArrayIteratorPrototype):
* runtime/ArrayPrototype.cpp:
(JSC::arrayProtoFuncValues):
(JSC::arrayProtoFuncEntries):
(JSC::arrayProtoFuncKeys):
* runtime/CommonIdentifiers.h:
* runtime/Identifier.h:
(JSC::Identifier::createEmptyUnique):
* runtime/JSArrayIterator.cpp: Added.
(JSC::JSArrayIterator::finishCreation):
* runtime/JSArrayIterator.h: Added.
(JSC::JSArrayIterator::createStructure):
(JSC::JSArrayIterator::create):
(JSC::JSArrayIterator::iterationKind):
(JSC::JSArrayIterator::iteratedObject):
(JSC::JSArrayIterator::nextIndex):
(JSC::JSArrayIterator::setNextIndex):
(JSC::JSArrayIterator::finish):
(JSC::JSArrayIterator::JSArrayIterator):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::reset):
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::iteratorResultStructure):

LayoutTests:

Add tests

* js/Object-getOwnPropertyNames-expected.txt:
* js/array-iterators-expected.txt: Added.
* js/array-iterators.html: Added.
* js/script-tests/Object-getOwnPropertyNames.js:
* js/script-tests/array-iterators.js: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156791 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Eliminate a branch in FastBitVector setAndCheck, make it vectorizable.
https://bugs.webkit.org/show_bug.cgi?id=122229

Patch by Nadav Rotem <nrotem@apple.com> on 2013-10-02
Reviewed by Geoffrey Garen.

The CPU is unlikely to predict the branch in setAndCheck. I changed the code to use conditional instructions.

* wtf/FastBitVector.h:
(WTF::FastBitVector::setAndCheck):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156792 268f45cc-cd09-0410-ab3c-d52691b4dbfc