WebKit-https.git
8 years agoImproved WinLauncher's URL handling.
commit-queue@webkit.org [Wed, 18 Sep 2013 17:21:56 +0000 (17:21 +0000)]
Improved WinLauncher's URL handling.
https://bugs.webkit.org/show_bug.cgi?id=121535

Patch by Alex Christensen <achristensen@webkit.org> on 2013-09-18
Reviewed by Brent Fulgham.

* WinLauncher/WinLauncher.cpp:
(EditProc):
Use INTERNET_MAX_URL_LENGTH instead of our MAX_URL_LENGTH.
(loadURL):
Prepend "http://" to URLs with no scheme.

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

8 years agoDFG should support Int52 for local variables
fpizlo@apple.com [Wed, 18 Sep 2013 17:14:02 +0000 (17:14 +0000)]
DFG should support Int52 for local variables
https://bugs.webkit.org/show_bug.cgi?id=121064

Source/JavaScriptCore:

Reviewed by Oliver Hunt.

This adds Int52 support for local variables to the DFG and FTL. It's a speed-up on
programs that have local int32 overflows but where a larger int representation can
prevent us from having to convert all the way up to double.

It's a small speed-up for now. But we're just supporting Int52 for a handful of
operations (add, sub, mul, neg, compare, bitops, typed array access) and this lays
the groundwork for adding Int52 to JSValue, which will probably be a bigger
speed-up.

The basic approach is:

- We have a notion of Int52 in our typesystem. Int52 doesn't belong to BytecodeTop
  or HeapTop - i.e. it doesn't arise from JSValues.

- DFG treats Int52 as being part of its FullTop and will treat it as being a
  subtype of double unless instructed otherwise.

- Prediction propagator creates Int52s whenever we have a node going doubly but due
  to large values rather than fractional values, and that node is known to be able
  to produce Int52 natively in the DFG backend.

- Fixup phase converts edges to MachineIntUses in nodes that are known to be able
  to deal with Int52, and where we have a subtype of Int32|Int52 as the predicted
  input.

- The DFG backend and FTL LLVM IR lowering have two notions of Int52s - ones that
  are left-shifted by 16 (great for overflow checks) and ones that are
  sign-extended. Both backends know how to convert between Int52s and the other
  representations.

* assembler/MacroAssemblerX86_64.h:
(JSC::MacroAssemblerX86_64::rshift64):
(JSC::MacroAssemblerX86_64::mul64):
(JSC::MacroAssemblerX86_64::branchMul64):
(JSC::MacroAssemblerX86_64::branchNeg64):
(JSC::MacroAssemblerX86_64::convertInt64ToDouble):
* assembler/X86Assembler.h:
(JSC::X86Assembler::imulq_rr):
(JSC::X86Assembler::cvtsi2sdq_rr):
* bytecode/DataFormat.h:
(JSC::dataFormatToString):
* bytecode/ExitKind.cpp:
(JSC::exitKindToString):
* bytecode/ExitKind.h:
* bytecode/OperandsInlines.h:
(JSC::::dumpInContext):
* bytecode/SpeculatedType.cpp:
(JSC::dumpSpeculation):
(JSC::speculationToAbbreviatedString):
(JSC::speculationFromValue):
* bytecode/SpeculatedType.h:
(JSC::isInt32SpeculationForArithmetic):
(JSC::isInt52Speculation):
(JSC::isMachineIntSpeculationForArithmetic):
(JSC::isInt52AsDoubleSpeculation):
(JSC::isBytecodeRealNumberSpeculation):
(JSC::isFullRealNumberSpeculation):
(JSC::isBytecodeNumberSpeculation):
(JSC::isFullNumberSpeculation):
(JSC::isBytecodeNumberSpeculationExpectingDefined):
(JSC::isFullNumberSpeculationExpectingDefined):
* bytecode/ValueRecovery.h:
(JSC::ValueRecovery::alreadyInJSStackAsUnboxedInt52):
(JSC::ValueRecovery::inGPR):
(JSC::ValueRecovery::displacedInJSStack):
(JSC::ValueRecovery::isAlreadyInJSStack):
(JSC::ValueRecovery::gpr):
(JSC::ValueRecovery::virtualRegister):
(JSC::ValueRecovery::dumpInContext):
* dfg/DFGAbstractInterpreter.h:
(JSC::DFG::AbstractInterpreter::needsTypeCheck):
(JSC::DFG::AbstractInterpreter::filterByType):
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):
* dfg/DFGAbstractValue.cpp:
(JSC::DFG::AbstractValue::set):
(JSC::DFG::AbstractValue::checkConsistency):
* dfg/DFGAbstractValue.h:
(JSC::DFG::AbstractValue::couldBeType):
(JSC::DFG::AbstractValue::isType):
(JSC::DFG::AbstractValue::checkConsistency):
(JSC::DFG::AbstractValue::validateType):
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::refine):
* dfg/DFGAssemblyHelpers.h:
(JSC::DFG::AssemblyHelpers::boxInt52):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::makeSafe):
* dfg/DFGCSEPhase.cpp:
(JSC::DFG::CSEPhase::pureCSE):
(JSC::DFG::CSEPhase::getByValLoadElimination):
(JSC::DFG::CSEPhase::performNodeCSE):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGCommon.h:
(JSC::DFG::enableInt52):
* dfg/DFGDCEPhase.cpp:
(JSC::DFG::DCEPhase::fixupBlock):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::run):
(JSC::DFG::FixupPhase::fixupNode):
(JSC::DFG::FixupPhase::fixupSetLocalsInBlock):
(JSC::DFG::FixupPhase::fixupUntypedSetLocalsInBlock):
(JSC::DFG::FixupPhase::observeUseKindOnNode):
(JSC::DFG::FixupPhase::fixEdge):
(JSC::DFG::FixupPhase::injectInt32ToDoubleNode):
(JSC::DFG::FixupPhase::attemptToMakeIntegerAdd):
* dfg/DFGFlushFormat.cpp:
(WTF::printInternal):
* dfg/DFGFlushFormat.h:
(JSC::DFG::resultFor):
(JSC::DFG::useKindFor):
* dfg/DFGGenerationInfo.h:
(JSC::DFG::GenerationInfo::initInt52):
(JSC::DFG::GenerationInfo::initStrictInt52):
(JSC::DFG::GenerationInfo::isFormat):
(JSC::DFG::GenerationInfo::isInt52):
(JSC::DFG::GenerationInfo::isStrictInt52):
(JSC::DFG::GenerationInfo::fillInt52):
(JSC::DFG::GenerationInfo::fillStrictInt52):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::addShouldSpeculateMachineInt):
(JSC::DFG::Graph::mulShouldSpeculateMachineInt):
(JSC::DFG::Graph::negateShouldSpeculateMachineInt):
* dfg/DFGInPlaceAbstractState.cpp:
(JSC::DFG::InPlaceAbstractState::mergeStateAtTail):
* dfg/DFGJITCode.cpp:
(JSC::DFG::JITCode::reconstruct):
* dfg/DFGJITCompiler.h:
(JSC::DFG::JITCompiler::noticeOSREntry):
* dfg/DFGMinifiedNode.h:
(JSC::DFG::belongsInMinifiedGraph):
(JSC::DFG::MinifiedNode::hasChild):
* dfg/DFGNode.h:
(JSC::DFG::Node::shouldSpeculateNumber):
(JSC::DFG::Node::shouldSpeculateNumberExpectingDefined):
(JSC::DFG::Node::canSpeculateInt52):
* dfg/DFGNodeFlags.h:
(JSC::DFG::nodeCanSpeculateInt52):
* dfg/DFGNodeType.h:
(JSC::DFG::permitsOSRBackwardRewiring):
(JSC::DFG::forwardRewiringSelectionScore):
* dfg/DFGOSREntry.cpp:
(JSC::DFG::prepareOSREntry):
* dfg/DFGOSREntry.h:
* dfg/DFGOSRExitCompiler.cpp:
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::speculatedDoubleTypeForPrediction):
(JSC::DFG::PredictionPropagationPhase::propagate):
(JSC::DFG::PredictionPropagationPhase::doDoubleVoting):
* dfg/DFGSafeToExecute.h:
(JSC::DFG::SafeToExecuteEdge::operator()):
(JSC::DFG::safeToExecute):
* dfg/DFGSilentRegisterSavePlan.h:
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::silentSavePlanForGPR):
(JSC::DFG::SpeculativeJIT::silentFill):
(JSC::DFG::SpeculativeJIT::compilePeepHoleBranch):
(JSC::DFG::SpeculativeJIT::compileInlineStart):
(JSC::DFG::SpeculativeJIT::compileDoublePutByVal):
(JSC::DFG::SpeculativeJIT::compileValueToInt32):
(JSC::DFG::SpeculativeJIT::compileInt32ToDouble):
(JSC::DFG::SpeculativeJIT::compileGetByValOnIntTypedArray):
(JSC::DFG::SpeculativeJIT::compilePutByValForIntTypedArray):
(JSC::DFG::SpeculativeJIT::compileAdd):
(JSC::DFG::SpeculativeJIT::compileArithSub):
(JSC::DFG::SpeculativeJIT::compileArithNegate):
(JSC::DFG::SpeculativeJIT::compileArithMul):
(JSC::DFG::SpeculativeJIT::compare):
(JSC::DFG::SpeculativeJIT::compileStrictEq):
(JSC::DFG::SpeculativeJIT::speculateMachineInt):
(JSC::DFG::SpeculativeJIT::speculateNumber):
(JSC::DFG::SpeculativeJIT::speculateRealNumber):
(JSC::DFG::SpeculativeJIT::speculate):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::canReuse):
(JSC::DFG::SpeculativeJIT::isFilled):
(JSC::DFG::SpeculativeJIT::isFilledDouble):
(JSC::DFG::SpeculativeJIT::use):
(JSC::DFG::SpeculativeJIT::isKnownInteger):
(JSC::DFG::SpeculativeJIT::isKnownCell):
(JSC::DFG::SpeculativeJIT::isKnownNotNumber):
(JSC::DFG::SpeculativeJIT::int52Result):
(JSC::DFG::SpeculativeJIT::strictInt52Result):
(JSC::DFG::SpeculativeJIT::initConstantInfo):
(JSC::DFG::SpeculativeJIT::isInteger):
(JSC::DFG::SpeculativeJIT::betterUseStrictInt52):
(JSC::DFG::SpeculativeJIT::generationInfo):
(JSC::DFG::SpeculateInt52Operand::SpeculateInt52Operand):
(JSC::DFG::SpeculateInt52Operand::~SpeculateInt52Operand):
(JSC::DFG::SpeculateInt52Operand::edge):
(JSC::DFG::SpeculateInt52Operand::node):
(JSC::DFG::SpeculateInt52Operand::gpr):
(JSC::DFG::SpeculateInt52Operand::use):
(JSC::DFG::SpeculateStrictInt52Operand::SpeculateStrictInt52Operand):
(JSC::DFG::SpeculateStrictInt52Operand::~SpeculateStrictInt52Operand):
(JSC::DFG::SpeculateStrictInt52Operand::edge):
(JSC::DFG::SpeculateStrictInt52Operand::node):
(JSC::DFG::SpeculateStrictInt52Operand::gpr):
(JSC::DFG::SpeculateStrictInt52Operand::use):
(JSC::DFG::SpeculateWhicheverInt52Operand::SpeculateWhicheverInt52Operand):
(JSC::DFG::SpeculateWhicheverInt52Operand::~SpeculateWhicheverInt52Operand):
(JSC::DFG::SpeculateWhicheverInt52Operand::edge):
(JSC::DFG::SpeculateWhicheverInt52Operand::node):
(JSC::DFG::SpeculateWhicheverInt52Operand::gpr):
(JSC::DFG::SpeculateWhicheverInt52Operand::use):
(JSC::DFG::SpeculateWhicheverInt52Operand::format):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::boxInt52):
(JSC::DFG::SpeculativeJIT::fillJSValue):
(JSC::DFG::SpeculativeJIT::fillSpeculateInt32Internal):
(JSC::DFG::SpeculativeJIT::fillSpeculateInt52):
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):
(JSC::DFG::SpeculativeJIT::fillSpeculateCell):
(JSC::DFG::SpeculativeJIT::fillSpeculateBoolean):
(JSC::DFG::SpeculativeJIT::compileInt52Compare):
(JSC::DFG::SpeculativeJIT::compilePeepHoleInt52Branch):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGUseKind.cpp:
(WTF::printInternal):
* dfg/DFGUseKind.h:
(JSC::DFG::typeFilterFor):
(JSC::DFG::isNumerical):
* dfg/DFGValueSource.cpp:
(JSC::DFG::ValueSource::dump):
* dfg/DFGValueSource.h:
(JSC::DFG::dataFormatToValueSourceKind):
(JSC::DFG::valueSourceKindToDataFormat):
(JSC::DFG::ValueSource::forFlushFormat):
(JSC::DFG::ValueSource::valueRecovery):
* dfg/DFGVariableAccessData.h:
(JSC::DFG::VariableAccessData::shouldUseDoubleFormatAccordingToVote):
(JSC::DFG::VariableAccessData::flushFormat):
* ftl/FTLCArgumentGetter.cpp:
(JSC::FTL::CArgumentGetter::loadNextAndBox):
* ftl/FTLCArgumentGetter.h:
* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLExitValue.cpp:
(JSC::FTL::ExitValue::dumpInContext):
* ftl/FTLExitValue.h:
(JSC::FTL::ExitValue::inJSStackAsInt52):
* ftl/FTLIntrinsicRepository.h:
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::createPhiVariables):
(JSC::FTL::LowerDFGToLLVM::compileNode):
(JSC::FTL::LowerDFGToLLVM::compileUpsilon):
(JSC::FTL::LowerDFGToLLVM::compilePhi):
(JSC::FTL::LowerDFGToLLVM::compileSetLocal):
(JSC::FTL::LowerDFGToLLVM::compileAdd):
(JSC::FTL::LowerDFGToLLVM::compileArithSub):
(JSC::FTL::LowerDFGToLLVM::compileArithMul):
(JSC::FTL::LowerDFGToLLVM::compileArithNegate):
(JSC::FTL::LowerDFGToLLVM::compilePutByVal):
(JSC::FTL::LowerDFGToLLVM::compileCompareEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareStrictEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareLess):
(JSC::FTL::LowerDFGToLLVM::compileCompareLessEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareGreater):
(JSC::FTL::LowerDFGToLLVM::compileCompareGreaterEq):
(JSC::FTL::LowerDFGToLLVM::lowInt32):
(JSC::FTL::LowerDFGToLLVM::lowInt52):
(JSC::FTL::LowerDFGToLLVM::lowStrictInt52):
(JSC::FTL::LowerDFGToLLVM::betterUseStrictInt52):
(JSC::FTL::LowerDFGToLLVM::bestInt52Kind):
(JSC::FTL::LowerDFGToLLVM::opposite):
(JSC::FTL::LowerDFGToLLVM::lowWhicheverInt52):
(JSC::FTL::LowerDFGToLLVM::lowCell):
(JSC::FTL::LowerDFGToLLVM::lowBoolean):
(JSC::FTL::LowerDFGToLLVM::lowDouble):
(JSC::FTL::LowerDFGToLLVM::lowJSValue):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToInt32):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToDouble):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToJSValue):
(JSC::FTL::LowerDFGToLLVM::setInt52WithStrictValue):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToInt52):
(JSC::FTL::LowerDFGToLLVM::int52ToStrictInt52):
(JSC::FTL::LowerDFGToLLVM::speculateRealNumber):
(JSC::FTL::LowerDFGToLLVM::initializeOSRExitStateForBlock):
(JSC::FTL::LowerDFGToLLVM::emitOSRExitCall):
(JSC::FTL::LowerDFGToLLVM::addExitArgumentForNode):
(JSC::FTL::LowerDFGToLLVM::setInt52):
(JSC::FTL::LowerDFGToLLVM::setStrictInt52):
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileStub):
* ftl/FTLOutput.h:
(JSC::FTL::Output::addWithOverflow64):
(JSC::FTL::Output::subWithOverflow64):
(JSC::FTL::Output::mulWithOverflow64):
* ftl/FTLValueFormat.cpp:
(WTF::printInternal):
* ftl/FTLValueFormat.h:
* ftl/FTLValueSource.cpp:
(JSC::FTL::ValueSource::dump):
* ftl/FTLValueSource.h:
* interpreter/Register.h:
(JSC::Register::unboxedInt52):
* runtime/Arguments.cpp:
(JSC::Arguments::tearOffForInlineCallFrame):
* runtime/IndexingType.cpp:
(JSC::leastUpperBoundOfIndexingTypeAndType):
* runtime/JSCJSValue.h:
* runtime/JSCJSValueInlines.h:
(JSC::JSValue::isMachineInt):
(JSC::JSValue::asMachineInt):

Source/WTF:

Reviewed by Oliver Hunt.

* wtf/PrintStream.h:
(WTF::ValueIgnoringContext::ValueIgnoringContext):
(WTF::ValueIgnoringContext::dump):
(WTF::ignoringContext):

Tools:

Reviewed by Oliver Hunt.

* Scripts/run-jsc-stress-tests:

LayoutTests:

Reviewed by Oliver Hunt.

* js/dfg-int-overflow-large-constants-in-a-line-expected.txt:
* js/regress/large-int-captured-expected.txt: Added.
* js/regress/large-int-captured.html: Added.
* js/regress/large-int-expected.txt: Added.
* js/regress/large-int-neg-expected.txt: Added.
* js/regress/large-int-neg.html: Added.
* js/regress/large-int.html: Added.
* js/regress/marsaglia-larger-ints-expected.txt: Added.
* js/regress/marsaglia-larger-ints.html: Added.
* js/regress/script-tests/large-int-captured.js: Added.
(.bar):
(foo):
* js/regress/script-tests/large-int-neg.js: Added.
(foo):
* js/regress/script-tests/large-int.js: Added.
(foo):
* js/regress/script-tests/marsaglia-larger-ints.js: Added.
(uint):
(marsaglia):
* js/script-tests/dfg-int-overflow-large-constants-in-a-line.js:

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

8 years agoREGRESSION(r155771): js/stack-overflow-arrity-catch.html is crashing on non-Mac platforms
msaboff@apple.com [Wed, 18 Sep 2013 16:51:07 +0000 (16:51 +0000)]
REGRESSION(r155771): js/stack-overflow-arrity-catch.html is crashing on non-Mac platforms
https://bugs.webkit.org/show_bug.cgi?id=121376

Reviewed by Oliver Hunt.

Fix stack grow() call for stack growing down.  This should catch running out of stack space before
we try to move the frame down due to arity mismatch.

* runtime/CommonSlowPaths.h:
(JSC::CommonSlowPaths::arityCheckFor):

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

8 years ago[Win] TestWebKitAPI does not compile.
commit-queue@webkit.org [Wed, 18 Sep 2013 16:33:18 +0000 (16:33 +0000)]
[Win] TestWebKitAPI does not compile.
https://bugs.webkit.org/show_bug.cgi?id=121485

Patch by peavo@outlook.com <peavo@outlook.com> on 2013-09-18
Reviewed by Brent Fulgham.

Source/WebKit:

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Export needed symbols.

Tools:

It is no longer possible to inherit from WebCore::BitmapImage, which the test relies on.
Instead, load a bitmap, then destroy the decoded data, which will cause WebCore::frameAtIndex()
to return null, which is the case we want to test.

* TestWebKitAPI/Tests/WebCore/win/BitmapImage.cpp:
(TestWebKitAPI::TEST):

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

8 years agoMissed one rebaseline for the RenderMenuList change.
akling@apple.com [Wed, 18 Sep 2013 16:27:02 +0000 (16:27 +0000)]
Missed one rebaseline for the RenderMenuList change.

* platform/mac/fast/forms/select-empty-option-height-expected.txt:

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

8 years agoYARR: Put UCS2 canonicalization tables in read-only memory.
akling@apple.com [Wed, 18 Sep 2013 15:55:55 +0000 (15:55 +0000)]
YARR: Put UCS2 canonicalization tables in read-only memory.
<https://webkit.org/b/121547>

Reviewed by Sam Weinig.

These tables never mutate so mark them const.

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

8 years agoPut constant CachedPower table in read-only memory.
akling@apple.com [Wed, 18 Sep 2013 15:54:54 +0000 (15:54 +0000)]
Put constant CachedPower table in read-only memory.
<https://webkit.org/b/121546>

Reviewed by Anders Carlsson.

* wtf/dtoa/cached-powers.cc:

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

8 years agoCTTE: RenderBR always has an HTMLElement.
akling@apple.com [Wed, 18 Sep 2013 15:48:34 +0000 (15:48 +0000)]
CTTE: RenderBR always has an HTMLElement.
<https://webkit.org/b/121557>

Reviewed by Antti Koivisto.

This renderer is never anonymous and always has a corresponding HTMLElement.
Tighten this up by making the constructor take a HTMLElement& and remove
RenderBR::createAnonymous().

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

8 years agoAvoid using RenderBR internally in RenderMenuList.
akling@apple.com [Wed, 18 Sep 2013 15:35:01 +0000 (15:35 +0000)]
Avoid using RenderBR internally in RenderMenuList.
<https://webkit.org/b/121550>

Reviewed by Antti Koivisto.

Source/WebCore:

RenderMenuLists with an empty caption text were previously using a
RenderBR as placeholder.

Switch to using a \n RenderText instead so we can tighten RenderBR.

This will change DRT dumps but actual metrics should not change.

LayoutTests:

Update expected results for RenderMenuLists with empty text.
They now have a RenderText inside them instead of a RenderBR.

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

8 years agoChange one accidental "object->isText() || object->isLineBreak()" from previous patch...
antti@apple.com [Wed, 18 Sep 2013 14:41:45 +0000 (14:41 +0000)]
Change one accidental "object->isText() || object->isLineBreak()" from previous patch back to "object->isTextOrLineBreak()"

Not reviewed.

* rendering/InlineIterator.h:
(WebCore::isIteratorTarget):

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

8 years agoRemove RenderWordBreak
antti@apple.com [Wed, 18 Sep 2013 14:33:55 +0000 (14:33 +0000)]
Remove RenderWordBreak
https://bugs.webkit.org/show_bug.cgi?id=121549

Reviewed by Andreas Kling.

Remove RenderWordBreak and make it a bit in RenderBR instead.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.xcodeproj/project.pbxproj:
* dom/Document.cpp:
(WebCore::Document::updateHoverActiveState):
* dom/Position.cpp:
(WebCore::hasInlineBoxWrapper):
(WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
* editing/Editor.cpp:
(WebCore::findFirstMarkable):
* editing/TextIterator.cpp:
(WebCore::ignoresContainerClip):
* html/HTMLElement.cpp:
(WebCore::HTMLElement::createRenderer):
* rendering/InlineBox.cpp:
(WebCore::InlineBox::logicalHeight):
(WebCore::InlineBox::baselinePosition):
(WebCore::InlineBox::lineHeight):
(WebCore::InlineBox::deleteLine):
(WebCore::InlineBox::extractLine):
(WebCore::InlineBox::attachLine):
(WebCore::InlineBox::nodeAtPoint):
* rendering/InlineBox.h:
(WebCore::InlineBox::isLineBreak):
* rendering/InlineFlowBox.cpp:
(WebCore::InlineFlowBox::addToLine):
(WebCore::InlineFlowBox::computeOverflow):
* rendering/InlineIterator.h:
(WebCore::InlineIterator::atTextParagraphSeparator):
(WebCore::isIteratorTarget):
* rendering/RenderBR.cpp:
(WebCore::RenderBR::RenderBR):
* rendering/RenderBR.h:
(WebCore::toRenderBR):

    RenderBR now represents both hard and soft line breaks. It will be renamed to RenderLineBreak later.

* rendering/RenderBlock.cpp:
(WebCore::InlineMinMaxIterator::next):
(WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::createInlineBoxForRenderer):
(WebCore::dirtyLineBoxesForRenderer):
(WebCore::RenderBlock::computeBlockDirectionPositionsForLine):
(WebCore::RenderBlockFlow::layoutInlineChildren):
(WebCore::textBeginsWithBreakablePosition):
(WebCore::canBreakAtThisPosition):
(WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
* rendering/RenderInline.cpp:
(WebCore::RenderInline::generateCulledLineBoxRects):
(WebCore::RenderInline::culledInlineFirstLineBox):
(WebCore::RenderInline::culledInlineLastLineBox):
(WebCore::RenderInline::dirtyLineBoxes):
* rendering/RenderLineBoxList.cpp:
(WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
* rendering/RenderObject.h:
(WebCore::RenderObject::isLineBreak):

    This bit covers both BR and WBR.

(WebCore::RenderObject::isBR):
(WebCore::RenderObject::isLineBreakOpportunity):

    Rename isWordBreak to isLineBreakOpportunity. This matches HTML5 spec terminology.

(WebCore::RenderObject::isTextOrLineBreak):

    Since WBR used to be Text we want this check to still cover it too. Renamed from isTextOrBR.

(WebCore::RenderObject::setIsLineBreak):
(WebCore::RenderObject::isWBR):
(WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
* rendering/RenderObjectChildList.cpp:
(WebCore::RenderObjectChildList::removeChildNode):
* rendering/RenderText.cpp:
* rendering/RenderText.h:
* rendering/RenderTreeAsText.cpp:
(WebCore::RenderTreeAsText::writeRenderObject):
* rendering/RenderWordBreak.cpp: Removed.
* rendering/RenderWordBreak.h: Removed.
* rendering/RenderingAllInOne.cpp:
* rendering/RootInlineBox.cpp:
(WebCore::RootInlineBox::ascentAndDescentForBox):
(WebCore::RootInlineBox::verticalPositionForBox):
(WebCore::RootInlineBox::includeLeadingForBox):
(WebCore::RootInlineBox::includeFontForBox):
(WebCore::RootInlineBox::includeGlyphsForBox):
(WebCore::RootInlineBox::includeMarginForBox):

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

8 years agoASSERT_NOT_REACHED is touched in WebCore::CSSPrimitiveValue::computeLengthDouble
ossy@webkit.org [Wed, 18 Sep 2013 13:48:19 +0000 (13:48 +0000)]
ASSERT_NOT_REACHED is touched in WebCore::CSSPrimitiveValue::computeLengthDouble
https://bugs.webkit.org/show_bug.cgi?id=120469

Source/WebCore:

Tests: fast/css/outline-offset-parsing-assert.html
       fast/css/outline-offset-parsing.html

Reviewed by Dirk Schulze.

* css/CSSParser.cpp:
(WebCore::CSSParser::parseValue): Fixed a typo after r66615, outline-offset can't be percentage.

LayoutTests:

Reviewed by Dirk Schulze.

* fast/css/outline-offset-parsing-assert-expected.txt: Added.
* fast/css/outline-offset-parsing-assert.html: Added.
* fast/css/outline-offset-parsing-expected.txt: Added.
* fast/css/outline-offset-parsing.html: Added.
* fast/css/script-tests/outline-offset-parsing.js: Added.
(test):

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

8 years ago[MathML] Implement the subscriptshift and superscriptshift attributes
commit-queue@webkit.org [Wed, 18 Sep 2013 12:39:23 +0000 (12:39 +0000)]
[MathML] Implement the subscriptshift and superscriptshift attributes
https://bugs.webkit.org/show_bug.cgi?id=120069

Patch by Gurpreet Kaur <k.gurpreet@samsung.com> on 2013-09-18
Reviewed by Darin Adler.

Source/WebCore:

Added support for subscriptshift and superscriptshift attributes. The
subscriptshift attribute is for msup element and superscriptshift for
msup. msubsup can have both subscriptshift and superscriptshift. The
subscriptshift attribute specifies the minimum amount to shift the
baseline of subscript down. The superscriptshift attribute specifies
the minimum amount to shift the baseline of superscript up.

Tests: mathml/presentation/msub-subscriptshift.html
       mathml/presentation/msubsup-subscriptshift.html
       mathml/presentation/msubsup-superscriptshift.html
       mathml/presentation/msup-superscriptshift.html
       mathml/presentation/multiscript-subscriptshift.html
       mathml/presentation/multiscript-superscriptshift.html

* mathml/mathattrs.in:
* rendering/mathml/RenderMathMLScripts.cpp:
(WebCore::RenderMathMLScripts::layout):
For aligning the subscript and superscript padding is added to the base.
So subscriptshift and superscriptshift attributes is set as padding bottom
and padding top of base respectively.

LayoutTests:

* mathml/presentation/msub-subscriptshift-expected.txt: Added.
* mathml/presentation/msub-subscriptshift.html: Added.
* mathml/presentation/msubsup-subscriptshift-expected.txt: Added.
* mathml/presentation/msubsup-subscriptshift.html: Added.
* mathml/presentation/msubsup-superscriptshift-expected.txt: Added.
* mathml/presentation/msubsup-superscriptshift.html: Added.
* mathml/presentation/msup-superscriptshift-expected.txt: Added.
* mathml/presentation/msup-superscriptshift.html: Added.
* mathml/presentation/multiscript-subscriptshift-expected.txt: Added.
* mathml/presentation/multiscript-subscriptshift.html: Added.
* mathml/presentation/multiscript-superscriptshift-expected.txt: Added.
* mathml/presentation/multiscript-superscriptshift.html: Added.
Added new tests for verifying that subscriptshift and superscriptshift are
being applied properly to the script base.

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

8 years ago[ATK] Expose aria-haspopup and aria-sort without the 'aria-' prefix
mario@webkit.org [Wed, 18 Sep 2013 08:28:59 +0000 (08:28 +0000)]
[ATK] Expose aria-haspopup and aria-sort without the 'aria-' prefix
https://bugs.webkit.org/show_bug.cgi?id=121495

Reviewed by Chris Fleizach.

Source/WebCore:

Removed the 'aria-' prefix from the exposed ATK object attributes
for WAI-ARIA attributes 'aria-haspopup' and 'aria-sort'.

* accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
(webkitAccessibleGetAttributes): Removed the prefix.

Tools:

Adapted DRT and WKTR to deal with the new names for the ATK object
attributes being exposed for 'aria-haspopup' and 'aria-sort'.

* DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
(coreAttributeToAtkAttribute): Updated translation between ATK and DRT.
(AccessibilityUIElement::stringAttributeValue): Ditto.
(AccessibilityUIElement::hasPopup): Ditto.
* WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::coreAttributeToAtkAttribute): Updated translation between ATK and WKTR.
(WTR::AccessibilityUIElement::stringAttributeValue): Ditto.
(WTR::AccessibilityUIElement::hasPopup): Ditto.

LayoutTests:

Rebaseline test expectations that were displaying the 'aria-sort'
attributes incorrectly, when they shouldn't due to that ARIA
attribute not being explicitly used in the HTML.

* platform/efl-wk1/accessibility/lists-expected.txt: Removed output for 'aria-sort'.
* platform/efl-wk1/accessibility/plugin-expected.txt: Ditto.
* platform/efl-wk1/accessibility/table-with-aria-role-expected.txt: Ditto.
* platform/efl-wk1/accessibility/transformed-element-expected.txt: Ditto.
* platform/efl-wk2/accessibility/image-link-expected.txt: Ditto.
* platform/efl-wk2/accessibility/image-map2-expected.txt: Ditto.
* platform/efl-wk2/accessibility/lists-expected.txt: Ditto.
* platform/efl-wk2/accessibility/plugin-expected.txt: Ditto.
* platform/efl-wk2/accessibility/table-cell-spans-expected.txt: Ditto.
* platform/efl-wk2/accessibility/table-cells-expected.txt: Ditto.
* platform/efl-wk2/accessibility/table-with-aria-role-expected.txt: Ditto.
* platform/efl-wk2/accessibility/transformed-element-expected.txt: Ditto.
* platform/gtk/accessibility/image-link-expected.txt: Ditto.
* platform/gtk/accessibility/image-map2-expected.txt: Ditto.
* platform/gtk/accessibility/lists-expected.txt: Ditto.
* platform/gtk/accessibility/plugin-expected.txt: Ditto.
* platform/gtk/accessibility/table-cell-spans-expected.txt: Ditto.
* platform/gtk/accessibility/table-cells-expected.txt: Ditto.
* platform/gtk/accessibility/table-detection-expected.txt: Ditto.
* platform/gtk/accessibility/table-one-cell-expected.txt: Ditto.
* platform/gtk/accessibility/table-with-aria-role-expected.txt: Ditto.
* platform/gtk/accessibility/table-with-rules-expected.txt: Ditto.
* platform/gtk/accessibility/transformed-element-expected.txt: Ditto.

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

8 years agoUnreviewed, rolling out r156019 and r156020.
commit-queue@webkit.org [Wed, 18 Sep 2013 07:25:52 +0000 (07:25 +0000)]
Unreviewed, rolling out r156019 and r156020.
http://trac.webkit.org/changeset/156019
http://trac.webkit.org/changeset/156020
https://bugs.webkit.org/show_bug.cgi?id=121540

Broke tests (Requested by ap on #webkit).

Source/JavaScriptCore:

* assembler/MacroAssemblerX86_64.h:
* assembler/X86Assembler.h:
* bytecode/DataFormat.h:
(JSC::dataFormatToString):
* bytecode/ExitKind.cpp:
(JSC::exitKindToString):
* bytecode/ExitKind.h:
* bytecode/OperandsInlines.h:
(JSC::::dumpInContext):
* bytecode/SpeculatedType.cpp:
(JSC::dumpSpeculation):
(JSC::speculationToAbbreviatedString):
(JSC::speculationFromValue):
* bytecode/SpeculatedType.h:
(JSC::isInt32SpeculationForArithmetic):
(JSC::isInt48Speculation):
(JSC::isMachineIntSpeculationForArithmetic):
(JSC::isInt48AsDoubleSpeculation):
(JSC::isRealNumberSpeculation):
(JSC::isNumberSpeculation):
(JSC::isNumberSpeculationExpectingDefined):
* bytecode/ValueRecovery.h:
(JSC::ValueRecovery::inGPR):
(JSC::ValueRecovery::displacedInJSStack):
(JSC::ValueRecovery::isAlreadyInJSStack):
(JSC::ValueRecovery::gpr):
(JSC::ValueRecovery::virtualRegister):
(JSC::ValueRecovery::dumpInContext):
* dfg/DFGAbstractInterpreter.h:
(JSC::DFG::AbstractInterpreter::needsTypeCheck):
(JSC::DFG::AbstractInterpreter::filterByType):
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):
* dfg/DFGAbstractValue.cpp:
(JSC::DFG::AbstractValue::set):
(JSC::DFG::AbstractValue::checkConsistency):
* dfg/DFGAbstractValue.h:
(JSC::DFG::AbstractValue::validateType):
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::refine):
* dfg/DFGAssemblyHelpers.h:
(JSC::DFG::AssemblyHelpers::unboxDouble):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::makeSafe):
* dfg/DFGCSEPhase.cpp:
(JSC::DFG::CSEPhase::canonicalize):
(JSC::DFG::CSEPhase::pureCSE):
(JSC::DFG::CSEPhase::getByValLoadElimination):
(JSC::DFG::CSEPhase::performNodeCSE):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGCommon.h:
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::run):
(JSC::DFG::FixupPhase::fixupNode):
(JSC::DFG::FixupPhase::fixupSetLocalsInBlock):
(JSC::DFG::FixupPhase::observeUseKindOnNode):
(JSC::DFG::FixupPhase::fixEdge):
(JSC::DFG::FixupPhase::injectInt32ToDoubleNode):
(JSC::DFG::FixupPhase::attemptToMakeIntegerAdd):
* dfg/DFGFlushFormat.cpp:
(WTF::printInternal):
* dfg/DFGFlushFormat.h:
(JSC::DFG::resultFor):
(JSC::DFG::useKindFor):
* dfg/DFGGenerationInfo.h:
(JSC::DFG::GenerationInfo::initInt32):
(JSC::DFG::GenerationInfo::fillInt32):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::addShouldSpeculateMachineInt):
(JSC::DFG::Graph::mulShouldSpeculateMachineInt):
(JSC::DFG::Graph::negateShouldSpeculateMachineInt):
* dfg/DFGInPlaceAbstractState.cpp:
(JSC::DFG::InPlaceAbstractState::mergeStateAtTail):
* dfg/DFGJITCode.cpp:
(JSC::DFG::JITCode::reconstruct):
* dfg/DFGMinifiedNode.h:
(JSC::DFG::belongsInMinifiedGraph):
(JSC::DFG::MinifiedNode::hasChild):
* dfg/DFGNode.h:
(JSC::DFG::Node::shouldSpeculateNumber):
(JSC::DFG::Node::shouldSpeculateNumberExpectingDefined):
(JSC::DFG::Node::canSpeculateInt48):
* dfg/DFGNodeFlags.h:
(JSC::DFG::nodeCanSpeculateInt48):
* dfg/DFGNodeType.h:
(JSC::DFG::forwardRewiringSelectionScore):
* dfg/DFGOSRExitCompiler.cpp:
(JSC::DFG::shortOperandsDump):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::speculatedDoubleTypeForPrediction):
(JSC::DFG::PredictionPropagationPhase::propagate):
(JSC::DFG::PredictionPropagationPhase::doDoubleVoting):
* dfg/DFGSafeToExecute.h:
(JSC::DFG::SafeToExecuteEdge::operator()):
(JSC::DFG::safeToExecute):
* dfg/DFGSilentRegisterSavePlan.h:
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::silentSavePlanForGPR):
(JSC::DFG::SpeculativeJIT::silentFill):
(JSC::DFG::SpeculativeJIT::compilePeepHoleBranch):
(JSC::DFG::SpeculativeJIT::compileInlineStart):
(JSC::DFG::SpeculativeJIT::compileDoublePutByVal):
(JSC::DFG::SpeculativeJIT::compileValueToInt32):
(JSC::DFG::SpeculativeJIT::compileInt32ToDouble):
(JSC::DFG::SpeculativeJIT::compileGetByValOnIntTypedArray):
(JSC::DFG::SpeculativeJIT::compilePutByValForIntTypedArray):
(JSC::DFG::SpeculativeJIT::compileAdd):
(JSC::DFG::SpeculativeJIT::compileArithSub):
(JSC::DFG::SpeculativeJIT::compileArithNegate):
(JSC::DFG::SpeculativeJIT::compileArithMul):
(JSC::DFG::SpeculativeJIT::compare):
(JSC::DFG::SpeculativeJIT::compileStrictEq):
(JSC::DFG::SpeculativeJIT::speculateNumber):
(JSC::DFG::SpeculativeJIT::speculateRealNumber):
(JSC::DFG::SpeculativeJIT::speculate):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::canReuse):
(JSC::DFG::SpeculativeJIT::isFilled):
(JSC::DFG::SpeculativeJIT::isFilledDouble):
(JSC::DFG::SpeculativeJIT::use):
(JSC::DFG::SpeculativeJIT::boxDouble):
(JSC::DFG::SpeculativeJIT::isKnownInteger):
(JSC::DFG::SpeculativeJIT::isKnownCell):
(JSC::DFG::SpeculativeJIT::isKnownNotNumber):
(JSC::DFG::SpeculativeJIT::int32Result):
(JSC::DFG::SpeculativeJIT::initConstantInfo):
(JSC::DFG::SpeculativeJIT::isInteger):
(JSC::DFG::SpeculativeJIT::generationInfoFromVirtualRegister):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::fillJSValue):
(JSC::DFG::SpeculativeJIT::fillSpeculateInt32Internal):
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):
(JSC::DFG::SpeculativeJIT::fillSpeculateCell):
(JSC::DFG::SpeculativeJIT::fillSpeculateBoolean):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGUseKind.cpp:
(WTF::printInternal):
* dfg/DFGUseKind.h:
(JSC::DFG::typeFilterFor):
(JSC::DFG::isNumerical):
* dfg/DFGValueSource.cpp:
(JSC::DFG::ValueSource::dump):
* dfg/DFGValueSource.h:
(JSC::DFG::dataFormatToValueSourceKind):
(JSC::DFG::valueSourceKindToDataFormat):
(JSC::DFG::ValueSource::forFlushFormat):
(JSC::DFG::ValueSource::valueRecovery):
* dfg/DFGVariableAccessData.h:
(JSC::DFG::VariableAccessData::shouldUseDoubleFormatAccordingToVote):
(JSC::DFG::VariableAccessData::flushFormat):
* ftl/FTLCArgumentGetter.cpp:
(JSC::FTL::CArgumentGetter::loadNextAndBox):
* ftl/FTLCArgumentGetter.h:
* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLExitValue.cpp:
(JSC::FTL::ExitValue::dumpInContext):
* ftl/FTLExitValue.h:
* ftl/FTLIntrinsicRepository.h:
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::createPhiVariables):
(JSC::FTL::LowerDFGToLLVM::compileNode):
(JSC::FTL::LowerDFGToLLVM::compileUpsilon):
(JSC::FTL::LowerDFGToLLVM::compilePhi):
(JSC::FTL::LowerDFGToLLVM::compileSetLocal):
(JSC::FTL::LowerDFGToLLVM::compileAdd):
(JSC::FTL::LowerDFGToLLVM::compileArithSub):
(JSC::FTL::LowerDFGToLLVM::compileArithMul):
(JSC::FTL::LowerDFGToLLVM::compileArithNegate):
(JSC::FTL::LowerDFGToLLVM::compilePutByVal):
(JSC::FTL::LowerDFGToLLVM::compileCompareEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareStrictEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareLess):
(JSC::FTL::LowerDFGToLLVM::compileCompareLessEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareGreater):
(JSC::FTL::LowerDFGToLLVM::compileCompareGreaterEq):
(JSC::FTL::LowerDFGToLLVM::lowInt32):
(JSC::FTL::LowerDFGToLLVM::lowCell):
(JSC::FTL::LowerDFGToLLVM::lowBoolean):
(JSC::FTL::LowerDFGToLLVM::lowDouble):
(JSC::FTL::LowerDFGToLLVM::lowJSValue):
(JSC::FTL::LowerDFGToLLVM::speculateRealNumber):
(JSC::FTL::LowerDFGToLLVM::initializeOSRExitStateForBlock):
(JSC::FTL::LowerDFGToLLVM::emitOSRExitCall):
(JSC::FTL::LowerDFGToLLVM::addExitArgumentForNode):
(JSC::FTL::LowerDFGToLLVM::setInt32):
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileStub):
* ftl/FTLOutput.h:
(JSC::FTL::Output::mulWithOverflow32):
* ftl/FTLValueFormat.cpp:
(WTF::printInternal):
* ftl/FTLValueFormat.h:
* ftl/FTLValueSource.cpp:
(JSC::FTL::ValueSource::dump):
* ftl/FTLValueSource.h:
* interpreter/Register.h:
* runtime/Arguments.cpp:
(JSC::Arguments::tearOffForInlineCallFrame):
* runtime/IndexingType.cpp:
(JSC::leastUpperBoundOfIndexingTypeAndType):
* runtime/JSCJSValue.h:
* runtime/JSCJSValueInlines.h:

Source/WTF:

* wtf/PrintStream.h:

Tools:

* Scripts/run-jsc-stress-tests:

LayoutTests:

* js/regress/large-int-captured-expected.txt: Removed.
* js/regress/large-int-captured.html: Removed.
* js/regress/large-int-expected.txt: Removed.
* js/regress/large-int-neg-expected.txt: Removed.
* js/regress/large-int-neg.html: Removed.
* js/regress/large-int.html: Removed.
* js/regress/marsaglia-larger-ints-expected.txt: Removed.
* js/regress/marsaglia-larger-ints.html: Removed.
* js/regress/script-tests/large-int-captured.js: Removed.
* js/regress/script-tests/large-int-neg.js: Removed.
* js/regress/script-tests/large-int.js: Removed.
* js/regress/script-tests/marsaglia-larger-ints.js: Removed.

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

8 years ago[GTK] WebKitScriptWorld not in API documentation
carlosgc@webkit.org [Wed, 18 Sep 2013 07:07:07 +0000 (07:07 +0000)]
[GTK] WebKitScriptWorld not in API documentation
https://bugs.webkit.org/show_bug.cgi?id=121539

Reviewed by Philippe Normand.

* UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add WebKitScriptWorld.

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

8 years ago[GTK] Cannot find WebInspectorUI/UserInterface/Main.html referenced in GResourceBundl...
commit-queue@webkit.org [Wed, 18 Sep 2013 06:51:58 +0000 (06:51 +0000)]
[GTK] Cannot find WebInspectorUI/UserInterface/Main.html referenced in GResourceBundle.xml
https://bugs.webkit.org/show_bug.cgi?id=121405

Patch by Gustavo Noronha Silva <gns@gnome.org> on 2013-09-17
Reviewed by Carlos Garcia Campos.

* GNUmakefile.am: if srcdir == builddir the WebInspectorUI variable that is used both to list
the dependencies of the GResourceBundle and to normalize the paths added to the XML through sed
replacement will end up starting with ./, which would be fine if automake did not remove that
from the paths in the target's dependency. We deal with that by normalizing the path we use to
take that quirk into account.

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

8 years agoUnreviewed. Add myself as a committer.
ryumiel@company100.net [Wed, 18 Sep 2013 06:39:54 +0000 (06:39 +0000)]
Unreviewed. Add myself as a committer.

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

8 years agoRename InlineBox::isText()
antti@apple.com [Wed, 18 Sep 2013 06:30:30 +0000 (06:30 +0000)]
Rename InlineBox::isText()
<https://webkit.org/b/121525>

Reviewed by Andreas Kling.

The flag sounds like RenderObject::isText() yet it can be set for some inline boxes generated
for non-text renderers too (br, list markers). This is pretty confusing.

Rename to InlineBox::behavesLikeText().

* rendering/InlineBox.cpp:
(WebCore::InlineBox::logicalHeight):
(WebCore::InlineBox::baselinePosition):
(WebCore::InlineBox::lineHeight):
* rendering/InlineBox.h:
(WebCore::InlineBox::behavesLikeText):
(WebCore::InlineBox::setBehavesLikeText):
(WebCore::InlineBox::InlineBoxBitfields::InlineBoxBitfields):
* rendering/InlineFlowBox.cpp:
(WebCore::InlineFlowBox::addToLine):
(WebCore::InlineFlowBox::placeBoxesInBlockDirection):
* rendering/InlineTextBox.cpp:
(WebCore::InlineTextBox::baselinePosition):
(WebCore::InlineTextBox::lineHeight):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::createInlineBoxForRenderer):
(WebCore::setLogicalWidthForTextRun):
* rendering/RenderListMarker.cpp:
(WebCore::RenderListMarker::createInlineBox):
* rendering/RenderText.cpp:
(WebCore::RenderText::createInlineTextBox):
* rendering/RootInlineBox.cpp:
(WebCore::RootInlineBox::includeLeadingForBox):
(WebCore::RootInlineBox::includeFontForBox):
(WebCore::RootInlineBox::includeGlyphsForBox):
(WebCore::RootInlineBox::includeMarginForBox):

    Switch tests from isText() to isTextOrBR(). This matches the behavior before r155957.
    I don't know if there is a case where this actually makes any difference in behavior.

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

8 years agoShrink SVGPathStringBuilder
weinig@apple.com [Wed, 18 Sep 2013 06:05:09 +0000 (06:05 +0000)]
Shrink SVGPathStringBuilder
https://bugs.webkit.org/show_bug.cgi?id=121536

Reviewed by Anders Carlsson.

- Use StringBuilder everywhere to avoid unnecessary temporary
  String objects and code size bloat.
- Also did a drive by FINAL / OVERRIDE pass.

As an example of the win, the function SVGPathStringBuilder::arcTo
went from being 6120 bytes down to just 378 bytes.

* svg/SVGPathStringBuilder.cpp:
(WebCore::SVGPathStringBuilder::SVGPathStringBuilder):
(WebCore::SVGPathStringBuilder::~SVGPathStringBuilder):
(WebCore::SVGPathStringBuilder::cleanup):
(WebCore::SVGPathStringBuilder::incrementPathSegmentCount):
(WebCore::SVGPathStringBuilder::continueConsuming):
It wasn't helpful for these to be inlined, so move them to
the implementation file.

(WebCore::appendFlag):
(WebCore::appendNumber):
(WebCore::appendPoint):
Added helpers.

(WebCore::SVGPathStringBuilder::moveTo):
(WebCore::SVGPathStringBuilder::lineTo):
(WebCore::SVGPathStringBuilder::lineToHorizontal):
(WebCore::SVGPathStringBuilder::lineToVertical):
(WebCore::SVGPathStringBuilder::curveToCubic):
(WebCore::SVGPathStringBuilder::curveToCubicSmooth):
(WebCore::SVGPathStringBuilder::curveToQuadratic):
(WebCore::SVGPathStringBuilder::curveToQuadraticSmooth):
(WebCore::SVGPathStringBuilder::arcTo):
(WebCore::SVGPathStringBuilder::closePath):
* svg/SVGPathStringBuilder.h:
Stopped using operator+ and removed duplicate string building logic in each build
type (e.g. both sides of the PathCoordinateMode condition were doing almost identical
work).

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

8 years agoCTTE: Convert some straggling Element subclasses constructors to take a Document&
weinig@apple.com [Wed, 18 Sep 2013 05:00:18 +0000 (05:00 +0000)]
CTTE: Convert some straggling Element subclasses constructors to take a Document&
https://bugs.webkit.org/show_bug.cgi?id=121533

Reviewed by Anders Carlsson.

* html/HTMLMeterElement.cpp:
(WebCore::HTMLMeterElement::didAddUserAgentShadowRoot):
* html/HTMLProgressElement.cpp:
(WebCore::HTMLProgressElement::didAddUserAgentShadowRoot):
* html/HTMLTextAreaElement.cpp:
(WebCore::HTMLTextAreaElement::didAddUserAgentShadowRoot):
* html/SearchInputType.cpp:
(WebCore::SearchInputType::createShadowSubtree):
* html/TextFieldInputType.cpp:
(WebCore::TextFieldInputType::createShadowSubtree):
* html/shadow/MeterShadowElement.cpp:
(WebCore::MeterShadowElement::MeterShadowElement):
(WebCore::MeterInnerElement::MeterInnerElement):
* html/shadow/MeterShadowElement.h:
(WebCore::MeterInnerElement::create):
(WebCore::MeterBarElement::create):
(WebCore::MeterValueElement::create):
* html/shadow/ProgressShadowElement.cpp:
(WebCore::ProgressShadowElement::ProgressShadowElement):
(WebCore::ProgressInnerElement::ProgressInnerElement):
(WebCore::ProgressBarElement::ProgressBarElement):
(WebCore::ProgressValueElement::ProgressValueElement):
* html/shadow/ProgressShadowElement.h:
(WebCore::ProgressInnerElement::create):
(WebCore::ProgressBarElement::create):
(WebCore::ProgressValueElement::create):
* html/shadow/SpinButtonElement.cpp:
(WebCore::SpinButtonElement::SpinButtonElement):
(WebCore::SpinButtonElement::create):
* html/shadow/SpinButtonElement.h:
* html/shadow/TextControlInnerElements.cpp:
(WebCore::TextControlInnerContainer::TextControlInnerContainer):
(WebCore::TextControlInnerContainer::create):
(WebCore::TextControlInnerElement::TextControlInnerElement):
(WebCore::TextControlInnerElement::create):
(WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
(WebCore::TextControlInnerTextElement::create):
(WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
(WebCore::SearchFieldResultsButtonElement::create):
(WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
(WebCore::SearchFieldCancelButtonElement::create):
(WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
(WebCore::InputFieldSpeechButtonElement::create):
* html/shadow/TextControlInnerElements.h:

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

8 years ago[CSS Shapes] Use the float height to determine position in shape-inside
zoltan@webkit.org [Wed, 18 Sep 2013 03:27:35 +0000 (03:27 +0000)]
[CSS Shapes] Use the float height to determine position in shape-inside
https://bugs.webkit.org/show_bug.cgi?id=102846

Reviewed by Darin Adler.

Float positioning inside shape-inside has been working only for simple cases when the float boundaries didn't overlap with the shape.
This patch fixes the behavior for left floats and shapes with inline content. I want to add this work step by step, therefore the next
step would be to add support for block content with inline content (e.g. paragraphs) then cover cases with right floats.

Source/WebCore:

Tests: fast/shapes/shape-inside/shape-inside-left-float-in-lower-left-triangle-inline-content.html
       fast/shapes/shape-inside/shape-inside-left-float-in-lower-right-triangle-inline-content.html
       fast/shapes/shape-inside/shape-inside-left-float-in-upper-left-triangle-inline-content.html
       fast/shapes/shape-inside/shape-inside-left-float-in-upper-right-triangle-inline-content.html

* rendering/LineWidth.cpp:
(WebCore::LineWidth::LineWidth): Use the new updateCurrentShapeSegment member function.
(WebCore::LineWidth::updateCurrentShapeSegment): We need a function to update the current line segment's reference, since we use it multiple places.
* rendering/LineWidth.h: Add new member function.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::computeLogicalLocationForFloat): Fix positioning of a floating element.
* rendering/RenderBlockLineLayout.cpp:
(WebCore::RenderBlock::updateShapeAndSegmentsForCurrentLine): Use updateSegmentsForLine instead of computeSegmentsForLine.
(WebCore::RenderBlock::updateShapeAndSegmentsForCurrentLineInFlowThread): Use updateSegmentsForLine instead of computeSegmentsForLine.
(WebCore::RenderBlock::adjustLogicalLineTopAndLogicalHeightIfNeeded):
(WebCore::updateSegmentsForShapes): After our float is positioned, we need to adjust the current lineTop and update the logical height to be able to wrap around the float.
(WebCore::RenderBlock::LineBreaker::nextSegmentBreak): If we have a float in our line we might need to adjust our lineTop and logicalHeight.
* rendering/shapes/ShapeInfo.cpp:
(WebCore::::computeSegmentsForLine): Add new const function to compute the segments. I'd like make this function static later if possible.
(WebCore::::updateSegmentsForLine): Old computeSegmentsForLine, change name to indicate that it is actually changing things.
* rendering/shapes/ShapeInfo.h: Update function names, add declaration.
(WebCore::ShapeInfo::clearSegments):
(WebCore::ShapeInfo::logicalLineBottom):
(WebCore::ShapeInfo::lineOverlapsShapeBounds):
* rendering/shapes/ShapeInsideInfo.cpp:
(WebCore::ShapeInsideInfo::computeFirstFitPositionForFloat): Compute the first fit position below the current line position inside shapes. I called this function
this way, because currently we use it only for shapes.
* rendering/shapes/ShapeInsideInfo.h: Update function names.
* rendering/shapes/ShapeOutsideInfo.cpp: Update function names.
(WebCore::ShapeOutsideInfo::computeSegmentsForContainingBlockLine):
(WebCore::ShapeOutsideInfo::updateSegmentsForLine):
* rendering/shapes/ShapeOutsideInfo.h: Update function names.

LayoutTests:

* fast/shapes/shape-inside/shape-inside-left-float-in-lower-left-triangle-inline-content-expected.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-lower-left-triangle-inline-content.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-lower-right-triangle-inline-content-expected.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-lower-right-triangle-inline-content.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-upper-left-triangle-inline-content-expected.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-upper-left-triangle-inline-content.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-upper-right-triangle-inline-content-expected.html: Added.
* fast/shapes/shape-inside/shape-inside-left-float-in-upper-right-triangle-inline-content.html: Added.

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

8 years agoUnreviewed. Add myself as a committer.
jae.park@company100.net [Wed, 18 Sep 2013 01:59:14 +0000 (01:59 +0000)]
Unreviewed. Add myself as a committer.

* Scripts/webkitpy/common/config/contributors.json:

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

8 years agoUnreviewed, fix 32-bit build.
fpizlo@apple.com [Wed, 18 Sep 2013 01:48:54 +0000 (01:48 +0000)]
Unreviewed, fix 32-bit build.

* runtime/JSCJSValue.h:

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

8 years agoDFG should support Int52 for local variables
fpizlo@apple.com [Wed, 18 Sep 2013 01:31:04 +0000 (01:31 +0000)]
DFG should support Int52 for local variables
https://bugs.webkit.org/show_bug.cgi?id=121064

Source/JavaScriptCore:

Reviewed by Oliver Hunt.

This adds Int52 support for local variables to the DFG and FTL. It's a speed-up on
programs that have local int32 overflows but where a larger int representation can
prevent us from having to convert all the way up to double.

It's a small speed-up for now. But we're just supporting Int52 for a handful of
operations (add, sub, mul, neg, compare, bitops, typed array access) and this lays
the groundwork for adding Int52 to JSValue, which will probably be a bigger
speed-up.

The basic approach is:

- We have a notion of Int52 in our typesystem. Int52 doesn't belong to BytecodeTop
  or HeapTop - i.e. it doesn't arise from JSValues.

- DFG treats Int52 as being part of its FullTop and will treat it as being a
  subtype of double unless instructed otherwise.

- Prediction propagator creates Int52s whenever we have a node going doubly but due
  to large values rather than fractional values, and that node is known to be able
  to produce Int52 natively in the DFG backend.

- Fixup phase converts edges to MachineIntUses in nodes that are known to be able
  to deal with Int52, and where we have a subtype of Int32|Int52 as the predicted
  input.

- The DFG backend and FTL LLVM IR lowering have two notions of Int52s - ones that
  are left-shifted by 16 (great for overflow checks) and ones that are
  sign-extended. Both backends know how to convert between Int52s and the other
  representations.

* assembler/MacroAssemblerX86_64.h:
(JSC::MacroAssemblerX86_64::rshift64):
(JSC::MacroAssemblerX86_64::mul64):
(JSC::MacroAssemblerX86_64::branchMul64):
(JSC::MacroAssemblerX86_64::branchNeg64):
(JSC::MacroAssemblerX86_64::convertInt64ToDouble):
* assembler/X86Assembler.h:
(JSC::X86Assembler::imulq_rr):
(JSC::X86Assembler::cvtsi2sdq_rr):
* bytecode/DataFormat.h:
(JSC::dataFormatToString):
* bytecode/OperandsInlines.h:
(JSC::::dumpInContext):
* bytecode/SpeculatedType.cpp:
(JSC::dumpSpeculation):
(JSC::speculationToAbbreviatedString):
(JSC::speculationFromValue):
* bytecode/SpeculatedType.h:
(JSC::isInt32SpeculationForArithmetic):
(JSC::isMachineIntSpeculationForArithmetic):
(JSC::isBytecodeRealNumberSpeculation):
(JSC::isFullRealNumberSpeculation):
(JSC::isBytecodeNumberSpeculation):
(JSC::isFullNumberSpeculation):
(JSC::isBytecodeNumberSpeculationExpectingDefined):
(JSC::isFullNumberSpeculationExpectingDefined):
* bytecode/ValueRecovery.h:
(JSC::ValueRecovery::alreadyInJSStackAsUnboxedInt52):
(JSC::ValueRecovery::inGPR):
(JSC::ValueRecovery::displacedInJSStack):
(JSC::ValueRecovery::isAlreadyInJSStack):
(JSC::ValueRecovery::gpr):
(JSC::ValueRecovery::virtualRegister):
(JSC::ValueRecovery::dumpInContext):
* dfg/DFGAbstractInterpreter.h:
(JSC::DFG::AbstractInterpreter::needsTypeCheck):
(JSC::DFG::AbstractInterpreter::filterByType):
* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):
* dfg/DFGAbstractValue.cpp:
(JSC::DFG::AbstractValue::set):
(JSC::DFG::AbstractValue::checkConsistency):
* dfg/DFGAbstractValue.h:
(JSC::DFG::AbstractValue::couldBeType):
(JSC::DFG::AbstractValue::isType):
(JSC::DFG::AbstractValue::checkConsistency):
(JSC::DFG::AbstractValue::validateType):
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::refine):
* dfg/DFGAssemblyHelpers.h:
(JSC::DFG::AssemblyHelpers::boxInt52):
* dfg/DFGCSEPhase.cpp:
(JSC::DFG::CSEPhase::pureCSE):
(JSC::DFG::CSEPhase::getByValLoadElimination):
(JSC::DFG::CSEPhase::performNodeCSE):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGCommon.h:
(JSC::DFG::enableInt52):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::run):
(JSC::DFG::FixupPhase::fixupNode):
(JSC::DFG::FixupPhase::fixupSetLocalsInBlock):
(JSC::DFG::FixupPhase::fixupUntypedSetLocalsInBlock):
(JSC::DFG::FixupPhase::observeUseKindOnNode):
(JSC::DFG::FixupPhase::fixEdge):
(JSC::DFG::FixupPhase::injectInt32ToDoubleNode):
(JSC::DFG::FixupPhase::attemptToMakeIntegerAdd):
* dfg/DFGFlushFormat.cpp:
(WTF::printInternal):
* dfg/DFGFlushFormat.h:
(JSC::DFG::resultFor):
(JSC::DFG::useKindFor):
* dfg/DFGGenerationInfo.h:
(JSC::DFG::GenerationInfo::initInt52):
(JSC::DFG::GenerationInfo::initStrictInt52):
(JSC::DFG::GenerationInfo::isFormat):
(JSC::DFG::GenerationInfo::isInt52):
(JSC::DFG::GenerationInfo::isStrictInt52):
(JSC::DFG::GenerationInfo::fillInt52):
(JSC::DFG::GenerationInfo::fillStrictInt52):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::addShouldSpeculateMachineInt):
(JSC::DFG::Graph::mulShouldSpeculateMachineInt):
(JSC::DFG::Graph::negateShouldSpeculateMachineInt):
* dfg/DFGInPlaceAbstractState.cpp:
(JSC::DFG::InPlaceAbstractState::mergeStateAtTail):
* dfg/DFGJITCode.cpp:
(JSC::DFG::JITCode::reconstruct):
* dfg/DFGMinifiedNode.h:
(JSC::DFG::belongsInMinifiedGraph):
(JSC::DFG::MinifiedNode::hasChild):
* dfg/DFGNode.h:
(JSC::DFG::Node::shouldSpeculateNumber):
(JSC::DFG::Node::shouldSpeculateNumberExpectingDefined):
* dfg/DFGNodeFlags.h:
* dfg/DFGNodeType.h:
(JSC::DFG::forwardRewiringSelectionScore):
* dfg/DFGOSRExitCompiler.cpp:
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::speculatedDoubleTypeForPrediction):
(JSC::DFG::PredictionPropagationPhase::propagate):
(JSC::DFG::PredictionPropagationPhase::doDoubleVoting):
* dfg/DFGSafeToExecute.h:
(JSC::DFG::SafeToExecuteEdge::operator()):
(JSC::DFG::safeToExecute):
* dfg/DFGSilentRegisterSavePlan.h:
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::silentSavePlanForGPR):
(JSC::DFG::SpeculativeJIT::silentFill):
(JSC::DFG::SpeculativeJIT::compilePeepHoleBranch):
(JSC::DFG::SpeculativeJIT::compileInlineStart):
(JSC::DFG::SpeculativeJIT::compileDoublePutByVal):
(JSC::DFG::SpeculativeJIT::compileValueToInt32):
(JSC::DFG::SpeculativeJIT::compileInt32ToDouble):
(JSC::DFG::SpeculativeJIT::compileGetByValOnIntTypedArray):
(JSC::DFG::SpeculativeJIT::compilePutByValForIntTypedArray):
(JSC::DFG::SpeculativeJIT::compileAdd):
(JSC::DFG::SpeculativeJIT::compileArithSub):
(JSC::DFG::SpeculativeJIT::compileArithNegate):
(JSC::DFG::SpeculativeJIT::compileArithMul):
(JSC::DFG::SpeculativeJIT::compare):
(JSC::DFG::SpeculativeJIT::compileStrictEq):
(JSC::DFG::SpeculativeJIT::speculateMachineInt):
(JSC::DFG::SpeculativeJIT::speculateNumber):
(JSC::DFG::SpeculativeJIT::speculateRealNumber):
(JSC::DFG::SpeculativeJIT::speculate):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::canReuse):
(JSC::DFG::SpeculativeJIT::isFilled):
(JSC::DFG::SpeculativeJIT::isFilledDouble):
(JSC::DFG::SpeculativeJIT::use):
(JSC::DFG::SpeculativeJIT::isKnownInteger):
(JSC::DFG::SpeculativeJIT::isKnownCell):
(JSC::DFG::SpeculativeJIT::isKnownNotNumber):
(JSC::DFG::SpeculativeJIT::int52Result):
(JSC::DFG::SpeculativeJIT::strictInt52Result):
(JSC::DFG::SpeculativeJIT::initConstantInfo):
(JSC::DFG::SpeculativeJIT::isInteger):
(JSC::DFG::SpeculativeJIT::betterUseStrictInt52):
(JSC::DFG::SpeculativeJIT::generationInfo):
(JSC::DFG::SpeculateInt52Operand::SpeculateInt52Operand):
(JSC::DFG::SpeculateInt52Operand::~SpeculateInt52Operand):
(JSC::DFG::SpeculateInt52Operand::edge):
(JSC::DFG::SpeculateInt52Operand::node):
(JSC::DFG::SpeculateInt52Operand::gpr):
(JSC::DFG::SpeculateInt52Operand::use):
(JSC::DFG::SpeculateStrictInt52Operand::SpeculateStrictInt52Operand):
(JSC::DFG::SpeculateStrictInt52Operand::~SpeculateStrictInt52Operand):
(JSC::DFG::SpeculateStrictInt52Operand::edge):
(JSC::DFG::SpeculateStrictInt52Operand::node):
(JSC::DFG::SpeculateStrictInt52Operand::gpr):
(JSC::DFG::SpeculateStrictInt52Operand::use):
(JSC::DFG::SpeculateWhicheverInt52Operand::SpeculateWhicheverInt52Operand):
(JSC::DFG::SpeculateWhicheverInt52Operand::~SpeculateWhicheverInt52Operand):
(JSC::DFG::SpeculateWhicheverInt52Operand::edge):
(JSC::DFG::SpeculateWhicheverInt52Operand::node):
(JSC::DFG::SpeculateWhicheverInt52Operand::gpr):
(JSC::DFG::SpeculateWhicheverInt52Operand::use):
(JSC::DFG::SpeculateWhicheverInt52Operand::format):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::boxInt52):
(JSC::DFG::SpeculativeJIT::fillJSValue):
(JSC::DFG::SpeculativeJIT::fillSpeculateInt32Internal):
(JSC::DFG::SpeculativeJIT::fillSpeculateInt52):
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):
(JSC::DFG::SpeculativeJIT::fillSpeculateCell):
(JSC::DFG::SpeculativeJIT::fillSpeculateBoolean):
(JSC::DFG::SpeculativeJIT::compileInt52Compare):
(JSC::DFG::SpeculativeJIT::compilePeepHoleInt52Branch):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGUseKind.cpp:
(WTF::printInternal):
* dfg/DFGUseKind.h:
(JSC::DFG::typeFilterFor):
(JSC::DFG::isNumerical):
* dfg/DFGValueSource.cpp:
(JSC::DFG::ValueSource::dump):
* dfg/DFGValueSource.h:
(JSC::DFG::dataFormatToValueSourceKind):
(JSC::DFG::valueSourceKindToDataFormat):
(JSC::DFG::ValueSource::forFlushFormat):
(JSC::DFG::ValueSource::valueRecovery):
* dfg/DFGVariableAccessData.h:
(JSC::DFG::VariableAccessData::shouldUseDoubleFormatAccordingToVote):
(JSC::DFG::VariableAccessData::flushFormat):
* ftl/FTLCArgumentGetter.cpp:
(JSC::FTL::CArgumentGetter::loadNextAndBox):
* ftl/FTLCArgumentGetter.h:
* ftl/FTLCapabilities.cpp:
(JSC::FTL::canCompile):
* ftl/FTLExitValue.cpp:
(JSC::FTL::ExitValue::dumpInContext):
* ftl/FTLExitValue.h:
(JSC::FTL::ExitValue::inJSStackAsInt52):
* ftl/FTLIntrinsicRepository.h:
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::createPhiVariables):
(JSC::FTL::LowerDFGToLLVM::compileNode):
(JSC::FTL::LowerDFGToLLVM::compileUpsilon):
(JSC::FTL::LowerDFGToLLVM::compilePhi):
(JSC::FTL::LowerDFGToLLVM::compileSetLocal):
(JSC::FTL::LowerDFGToLLVM::compileAdd):
(JSC::FTL::LowerDFGToLLVM::compileArithSub):
(JSC::FTL::LowerDFGToLLVM::compileArithMul):
(JSC::FTL::LowerDFGToLLVM::compileArithNegate):
(JSC::FTL::LowerDFGToLLVM::compilePutByVal):
(JSC::FTL::LowerDFGToLLVM::compileCompareEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareStrictEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareLess):
(JSC::FTL::LowerDFGToLLVM::compileCompareLessEq):
(JSC::FTL::LowerDFGToLLVM::compileCompareGreater):
(JSC::FTL::LowerDFGToLLVM::compileCompareGreaterEq):
(JSC::FTL::LowerDFGToLLVM::lowInt32):
(JSC::FTL::LowerDFGToLLVM::lowInt52):
(JSC::FTL::LowerDFGToLLVM::lowStrictInt52):
(JSC::FTL::LowerDFGToLLVM::betterUseStrictInt52):
(JSC::FTL::LowerDFGToLLVM::bestInt52Kind):
(JSC::FTL::LowerDFGToLLVM::opposite):
(JSC::FTL::LowerDFGToLLVM::Int52s::operator[]):
(JSC::FTL::LowerDFGToLLVM::lowWhicheverInt52):
(JSC::FTL::LowerDFGToLLVM::lowWhicheverInt52s):
(JSC::FTL::LowerDFGToLLVM::lowOpposingInt52s):
(JSC::FTL::LowerDFGToLLVM::lowCell):
(JSC::FTL::LowerDFGToLLVM::lowBoolean):
(JSC::FTL::LowerDFGToLLVM::lowDouble):
(JSC::FTL::LowerDFGToLLVM::lowJSValue):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToInt32):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToDouble):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToJSValue):
(JSC::FTL::LowerDFGToLLVM::setInt52WithStrictValue):
(JSC::FTL::LowerDFGToLLVM::strictInt52ToInt52):
(JSC::FTL::LowerDFGToLLVM::int52ToStrictInt52):
(JSC::FTL::LowerDFGToLLVM::speculateRealNumber):
(JSC::FTL::LowerDFGToLLVM::initializeOSRExitStateForBlock):
(JSC::FTL::LowerDFGToLLVM::emitOSRExitCall):
(JSC::FTL::LowerDFGToLLVM::addExitArgumentForNode):
(JSC::FTL::LowerDFGToLLVM::setInt52):
(JSC::FTL::LowerDFGToLLVM::setStrictInt52):
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileStub):
* ftl/FTLOutput.h:
(JSC::FTL::Output::addWithOverflow64):
(JSC::FTL::Output::subWithOverflow64):
(JSC::FTL::Output::mulWithOverflow64):
* ftl/FTLValueFormat.cpp:
(WTF::printInternal):
* ftl/FTLValueFormat.h:
* ftl/FTLValueSource.cpp:
(JSC::FTL::ValueSource::dump):
* ftl/FTLValueSource.h:
* interpreter/Register.h:
(JSC::Register::unboxedInt52):
* runtime/Arguments.cpp:
(JSC::Arguments::tearOffForInlineCallFrame):
* runtime/IndexingType.cpp:
(JSC::leastUpperBoundOfIndexingTypeAndType):
* runtime/JSCJSValue.h:
* runtime/JSCJSValueInlines.h:
(JSC::JSValue::isMachineInt):
(JSC::JSValue::asMachineInt):

Source/WTF:

Reviewed by Oliver Hunt.

* wtf/PrintStream.h:
(WTF::ValueIgnoringContext::ValueIgnoringContext):
(WTF::ValueIgnoringContext::dump):
(WTF::ignoringContext):

Tools:

Reviewed by Oliver Hunt.

* Scripts/run-jsc-stress-tests:

LayoutTests:

Reviewed by Oliver Hunt.

* js/regress/large-int-captured-expected.txt: Added.
* js/regress/large-int-captured.html: Added.
* js/regress/large-int-expected.txt: Added.
* js/regress/large-int-neg-expected.txt: Added.
* js/regress/large-int-neg.html: Added.
* js/regress/large-int.html: Added.
* js/regress/marsaglia-larger-ints-expected.txt: Added.
* js/regress/marsaglia-larger-ints.html: Added.
* js/regress/script-tests/large-int-captured.js: Added.
(.bar):
(foo):
* js/regress/script-tests/large-int-neg.js: Added.
(foo):
* js/regress/script-tests/large-int.js: Added.
(foo):
* js/regress/script-tests/marsaglia-larger-ints.js: Added.
(uint):
(marsaglia):

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

8 years agoAdded back and forward buttons to WinLauncher.
alex.christensen@flexsim.com [Wed, 18 Sep 2013 01:10:07 +0000 (01:10 +0000)]
Added back and forward buttons to WinLauncher.
https://bugs.webkit.org/show_bug.cgi?id=121212

Reviewed by Brent Fulgham.

* WinLauncher/WinLauncher.cpp:
(resizeSubViews):
Move new back and forward buttons to correct positions before URL bar.
(dllLauncherEntryPoint):
Store the default button window procedure and replace with my button procedures.
(EditProc): Updated style and renamed from MyEditProc.
(BackButtonProc): Added.
(ForwardButtonProc): Added.

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

8 years agoUse CheckStructure for checking the types of typed arrays whenever possible
fpizlo@apple.com [Wed, 18 Sep 2013 01:06:49 +0000 (01:06 +0000)]
Use CheckStructure for checking the types of typed arrays whenever possible
https://bugs.webkit.org/show_bug.cgi?id=121514

Reviewed by Oliver Hunt.

* bytecode/ArrayProfile.cpp:
(JSC::ArrayProfile::computeUpdatedPrediction):
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::fromObserved):
(JSC::DFG::ArrayMode::refine):
(JSC::DFG::ArrayMode::originalArrayStructure):
(JSC::DFG::arrayClassToString):
* dfg/DFGArrayMode.h:
(JSC::DFG::ArrayMode::ArrayMode):
(JSC::DFG::ArrayMode::arrayModesWithIndexingShape):
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::isOriginalTypedArrayStructure):

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

8 years agoDFG should use the (x & 0x7fffffff) trick for doing overflow and neg-zero checks...
fpizlo@apple.com [Wed, 18 Sep 2013 01:04:31 +0000 (01:04 +0000)]
DFG should use the (x & 0x7fffffff) trick for doing overflow and neg-zero checks on negation in one go
https://bugs.webkit.org/show_bug.cgi?id=121520

Reviewed by Oliver Hunt.

* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileArithNegate):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileArithNegate):

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

8 years agoReplace use of OwnArrayPtr<Foo> with std::unique_ptr<Foo[]> in WebCore
weinig@apple.com [Wed, 18 Sep 2013 00:15:13 +0000 (00:15 +0000)]
Replace use of OwnArrayPtr<Foo> with std::unique_ptr<Foo[]> in WebCore
https://bugs.webkit.org/show_bug.cgi?id=121527

Reviewed by Anders Carlsson.

* Modules/webaudio/AudioBufferSourceNode.cpp:
(WebCore::AudioBufferSourceNode::setBuffer):
* Modules/webaudio/AudioBufferSourceNode.h:
* Modules/webaudio/OscillatorNode.h:
* css/CSSParser.cpp:
(WebCore::CSSParser::setupParser):
(WebCore::CSSParser::currentCharacter16):
* css/CSSParser.h:
* html/HTMLAreaElement.h:
* html/HTMLFrameSetElement.h:
* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::copyTexSubImage2D):
(WebCore::WebGLRenderingContext::simulateVertexAttrib0):
(WebCore::WebGLRenderingContext::LRUImageBufferCache::LRUImageBufferCache):
* html/canvas/WebGLRenderingContext.h:
* platform/ScrollAnimatorNone.cpp:
* platform/audio/DynamicsCompressor.cpp:
(WebCore::DynamicsCompressor::setNumberOfChannels):
* platform/audio/DynamicsCompressor.h:
* platform/audio/FFTFrame.h:
* platform/audio/gstreamer/FFTFrameGStreamer.cpp:
(WebCore::FFTFrame::FFTFrame):
* platform/efl/ScrollbarEfl.cpp:
(ScrollbarEfl::updateThumbPositionAndProportion):
* platform/graphics/ANGLEWebKitBridge.cpp:
(WebCore::ANGLEWebKitBridge::compileShaderSource):
* platform/graphics/GraphicsContext3D.cpp:
(WebCore::GraphicsContext3D::texImage2DResourceSafe):
* platform/graphics/GraphicsContext3D.h:
* platform/graphics/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
* platform/graphics/blackberry/LayerTexture.cpp:
* platform/graphics/ca/win/CACFLayerTreeHost.cpp:
(WebCore::getDirtyRects):
* platform/graphics/cg/GraphicsContext3DCG.cpp:
(WebCore::GraphicsContext3D::ImageExtractor::extractImage):
* platform/graphics/cg/GraphicsContextCG.cpp:
* platform/graphics/cg/ImageBufferCG.cpp:
* platform/graphics/gpu/Texture.cpp:
(WebCore::Texture::updateSubRect):
* platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
(WebCore::HarfBuzzShaper::HarfBuzzShaper):
(WebCore::HarfBuzzShaper::setNormalizedBuffer):
* platform/graphics/harfbuzz/HarfBuzzShaper.h:
* platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
(WebCore::GraphicsContext3D::paintRenderingResultsToCanvas):
(WebCore::GraphicsContext3D::compileShader):
(WebCore::GraphicsContext3D::getActiveAttrib):
(WebCore::GraphicsContext3D::getActiveUniform):
(WebCore::GraphicsContext3D::getProgramInfoLog):
(WebCore::GraphicsContext3D::getShaderInfoLog):
* platform/graphics/opentype/OpenTypeSanitizer.cpp:
* platform/graphics/texmap/TextureMapperGL.cpp:
* platform/graphics/wince/SharedBitmap.cpp:
(WebCore::SharedBitmap::SharedBitmap):
(WebCore::SharedBitmap::to16bit):
* platform/graphics/wince/SharedBitmap.h:
* platform/image-decoders/blackberry/JPEGImageDecoder.cpp:
(WebCore::ImageReader::decode):
* platform/image-decoders/png/PNGImageDecoder.cpp:
(WebCore::PNGImageReader::createRowBuffer):
* platform/win/ContextMenuWin.cpp:
(WebCore::ContextMenu::getContextMenuItems):
* platform/win/LoggingWin.cpp:
(WebCore::logLevelString):
* plugins/PluginPackage.cpp:
* plugins/blackberry/PluginViewBlackBerry.cpp:
(WebCore::PluginView::handleTouchEvent):
* plugins/win/PluginPackageWin.cpp:
(WebCore::PluginPackage::fetchInfo):

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

8 years agoUnreviewed, rolling out r156001.
commit-queue@webkit.org [Wed, 18 Sep 2013 00:10:20 +0000 (00:10 +0000)]
Unreviewed, rolling out r156001.
http://trac.webkit.org/changeset/156001
https://bugs.webkit.org/show_bug.cgi?id=121529

Broke API tests (Requested by ap on #webkit).

* platform/mac/HTMLConverter.h:
* platform/mac/HTMLConverter.mm:
(WebDefaultFont):
(_fontForNameAndSize):
(+[WebHTMLConverter defaultParagraphStyle]):
(-[WebHTMLConverter _computedStyleForElement:]):
(-[WebHTMLConverter _specifiedStyleForElement:]):
(-[WebHTMLConverter _computedStringForNode:property:]):
(-[WebHTMLConverter _stringForNode:property:]):
(-[WebHTMLConverter _getComputedFloat:forNode:property:]):
(-[WebHTMLConverter _getFloat:forNode:property:]):
(_colorForRGBColor):
(_shadowForShadowStyle):
(-[WebHTMLConverter _elementIsBlockLevel:]):
(-[WebHTMLConverter _elementHasOwnBackgroundColor:]):
(-[WebHTMLConverter _computedColorForNode:property:]):
(-[WebHTMLConverter _colorForNode:property:]):
(-[WebHTMLConverter _computedAttributesForElement:]):
(-[WebHTMLConverter _attributesForElement:]):
(-[WebHTMLConverter _newParagraphForElement:tag:allowEmpty:suppressTrailingSpace:]):
(-[WebHTMLConverter _newLineForElement:]):
(-[WebHTMLConverter _newTabForElement:]):
(-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
(-[WebHTMLConverter _addQuoteForElement:opening:level:]):
(-[WebHTMLConverter _addValue:forElement:]):
(-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
(_dateForString):
(_colCompare):
(-[WebHTMLConverter _enterElement:tag:display:]):
(-[WebHTMLConverter _addTableForElement:]):
(-[WebHTMLConverter _addTableCellForElement:]):
(-[WebHTMLConverter _processElement:tag:display:depth:]):
(-[WebHTMLConverter _addMarkersToList:range:]):
(-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
(-[WebHTMLConverter _processText:]):
(-[WebHTMLConverter _traverseNode:depth:embedded:]):
(-[WebHTMLConverter _traverseFooterNode:depth:]):
(-[WebHTMLConverter _loadFromDOMRange]):
(-[WebHTMLConverter dealloc]):
(-[WebHTMLConverter init]):
(-[WebHTMLConverter initWithDOMRange:]):
(-[WebHTMLConverter attributedString]):
(+[WebHTMLConverter editingAttributedStringFromRange:]):
(fileWrapperForElement):

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

8 years agoRemoved some Lion specific results - these tests are failing on Lion bots despite...
ap@apple.com [Tue, 17 Sep 2013 23:24:36 +0000 (23:24 +0000)]
Removed some Lion specific results - these tests are failing on Lion bots despite these,
and it looks like Lion now matches cross-platform results.

* platform/mac-lion/editing/selection/vertical-rl-ltr-extend-line-backward-wrap-expected.png: Removed.
* platform/mac-lion/editing/selection/vertical-rl-ltr-extend-line-backward-wrap-expected.txt: Removed.
* platform/mac-lion/editing/selection/vertical-rl-ltr-extend-line-forward-wrap-expected.png: Removed.
* platform/mac-lion/editing/selection/vertical-rl-ltr-extend-line-forward-wrap-expected.txt: Removed.

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

8 years agocompositing/images/positioned-image-content-rect.html is failing on some bots
ap@apple.com [Tue, 17 Sep 2013 23:12:35 +0000 (23:12 +0000)]
compositing/images/positioned-image-content-rect.html is failing on some bots
https://bugs.webkit.org/show_bug.cgi?id=121526

* platform/mac/TestExpectations: Marked as failing or passing for now, should
be fixed with upcoming color management improvements.

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

8 years agoAX: Mac AXARIABusy should be AXElementBusy (not ARIA specific)
commit-queue@webkit.org [Tue, 17 Sep 2013 23:08:05 +0000 (23:08 +0000)]
AX: Mac AXARIABusy should be AXElementBusy (not ARIA specific)
https://bugs.webkit.org/show_bug.cgi?id=121442

Patch by Samuel White <samuel_white@apple.com> on 2013-09-17
Reviewed by Chris Fleizach.

Source/WebCore:

No new tests, changed AXARIABusy attribute to AXElementBusy to uncouple the concept of busy with
the aria-busy attribute. This will allow us to expand on the definition of busy moving forward.

* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):

LayoutTests:

Mac platform attribute name change only (AXARIABusy => AXElementBusy). Updated existing tests using this attribute.

* accessibility/transformed-element-expected.txt:
* platform/mac/accessibility/aria-columnrowheaders-expected.txt:
* platform/mac/accessibility/aria-liveregions-attributes-expected.txt:
* platform/mac/accessibility/aria-liveregions-attributes.html:
* platform/mac/accessibility/bounds-for-range-expected.txt:
* platform/mac/accessibility/document-attributes-expected.txt:
* platform/mac/accessibility/document-links-expected.txt:
* platform/mac/accessibility/image-link-expected.txt:
* platform/mac/accessibility/image-map2-expected.txt:
* platform/mac/accessibility/internal-link-anchors-expected.txt:
* platform/mac/accessibility/internal-link-anchors2-expected.txt:
* platform/mac/accessibility/lists-expected.txt:
* platform/mac/accessibility/plugin-expected.txt:
* platform/mac/accessibility/table-attributes-expected.txt:
* platform/mac/accessibility/table-cell-spans-expected.txt:
* platform/mac/accessibility/table-cells-expected.txt:
* platform/mac/accessibility/table-detection-expected.txt:
* platform/mac/accessibility/table-one-cell-expected.txt:
* platform/mac/accessibility/table-sections-expected.txt:
* platform/mac/accessibility/table-with-aria-role-expected.txt:
* platform/mac/accessibility/table-with-rules-expected.txt:

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

8 years agoUnreviewed typo fix after r155999
msaboff@apple.com [Tue, 17 Sep 2013 22:48:57 +0000 (22:48 +0000)]
Unreviewed typo fix after r155999

Changed en_US.UTB-8 to en_US.UTF-8

* Scripts/run-javascriptcore-tests:

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

8 years agoPack create_hash_table tables better.
akling@apple.com [Tue, 17 Sep 2013 22:32:31 +0000 (22:32 +0000)]
Pack create_hash_table tables better.
<https://webkit.org/b/121517>

Reviewed by Sam Weinig.

Source/JavaScriptCore:

Reduces JavaScriptCore binary size by 4648 bytes.

* create_hash_table:
* runtime/Lookup.h:

    Reorder HashTableValue members to avoid unnecessary padding.

Source/WebCore:

Reduces WebCore binary size by 72744 bytes.

* bindings/scripts/CodeGeneratorJS.pm:
(GenerateHashTable):

    Updated for new HashTableValue member order.

* bindings/scripts/test/JS/*:

    Rebaselined bindings tests.

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

8 years agoRebaseline a test.
simon.fraser@apple.com [Tue, 17 Sep 2013 22:27:40 +0000 (22:27 +0000)]
Rebaseline a test.

* platform/mac-wk2/compositing/visible-rect/iframe-no-layers-expected.txt: Copied from LayoutTests/platform/mac/compositing/visible-rect/iframe-no-layers-expected.txt.
* platform/mac/compositing/visible-rect/iframe-no-layers-expected.txt:

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

8 years ago[Windows] Adjust test list further to make the bots green.
bfulgham@apple.com [Tue, 17 Sep 2013 22:27:07 +0000 (22:27 +0000)]
[Windows] Adjust test list further to make the bots green.

* platform/win/TestExpectations:

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

8 years ago[Qt] Add FlowThreadController.h to Target.pri
zoltan@webkit.org [Tue, 17 Sep 2013 22:07:32 +0000 (22:07 +0000)]
[Qt] Add FlowThreadController.h to Target.pri
https://bugs.webkit.org/show_bug.cgi?id=121516

Reviewed by Dirk Schulze.

No new tests, no behavior change.

* Target.pri:

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

8 years agoScriptProcessorNode is garbage collected while still active if unreachable (breaks
ap@apple.com [Tue, 17 Sep 2013 22:03:44 +0000 (22:03 +0000)]
ScriptProcessorNode is garbage collected while still active if unreachable (breaks
webaudio/javascriptaudionode.html test)
https://bugs.webkit.org/show_bug.cgi?id=112521

* TestExpectations: Marking test as failing/asserting.

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

8 years agoStop explicitly using PassOwnPtr in WebCore/html
andersca@apple.com [Tue, 17 Sep 2013 21:58:57 +0000 (21:58 +0000)]
Stop explicitly using PassOwnPtr in WebCore/html
https://bugs.webkit.org/show_bug.cgi?id=121511

Reviewed by Andreas Kling.

Source/WebCore:

* dom/ElementRareData.h:
(WebCore::ElementRareData::setClassList):
* html/ButtonInputType.cpp:
(WebCore::ButtonInputType::create):
* html/ButtonInputType.h:
* html/CheckboxInputType.cpp:
(WebCore::CheckboxInputType::create):
(WebCore::CheckboxInputType::willDispatchClick):
* html/CheckboxInputType.h:
* html/ClassList.cpp:
(WebCore::ClassList::create):
* html/ClassList.h:
* html/ColorInputType.cpp:
(WebCore::ColorInputType::create):
* html/ColorInputType.h:
* html/DateInputType.cpp:
(WebCore::DateInputType::create):
* html/DateInputType.h:
* html/DateTimeInputType.cpp:
(WebCore::DateTimeInputType::create):
* html/DateTimeInputType.h:
* html/DateTimeLocalInputType.cpp:
(WebCore::DateTimeLocalInputType::create):
* html/DateTimeLocalInputType.h:
* html/EmailInputType.cpp:
(WebCore::EmailInputType::create):
* html/EmailInputType.h:
* html/FileInputType.cpp:
(WebCore::FileInputType::create):
* html/FileInputType.h:
* html/FormAssociatedElement.cpp:
(WebCore::FormAttributeTargetObserver::create):
* html/FormController.cpp:
(WebCore::SavedFormState::create):
(WebCore::SavedFormState::deserialize):
(WebCore::FormKeyGenerator::create):
(WebCore::FormController::createSavedFormStateMap):
* html/FormController.h:
(WebCore::FormController::create):
* html/HTMLInputElement.cpp:
(WebCore::ListAttributeTargetObserver::create):
* html/HiddenInputType.cpp:
(WebCore::HiddenInputType::create):
* html/HiddenInputType.h:
* html/ImageInputType.cpp:
(WebCore::ImageInputType::create):
* html/ImageInputType.h:
* html/InputType.cpp:
(WebCore::InputType::create):
(WebCore::InputType::createText):
(WebCore::InputType::willDispatchClick):
* html/InputType.h:
* html/MonthInputType.cpp:
(WebCore::MonthInputType::create):
* html/MonthInputType.h:
* html/NumberInputType.cpp:
(WebCore::NumberInputType::create):
* html/NumberInputType.h:
* html/PasswordInputType.cpp:
(WebCore::PasswordInputType::create):
* html/PasswordInputType.h:
* html/PublicURLManager.h:
(WebCore::PublicURLManager::create):
* html/RadioInputType.cpp:
(WebCore::RadioInputType::create):
(WebCore::RadioInputType::willDispatchClick):
* html/RadioInputType.h:
* html/RangeInputType.cpp:
(WebCore::RangeInputType::create):
* html/RangeInputType.h:
* html/ResetInputType.cpp:
(WebCore::ResetInputType::create):
* html/ResetInputType.h:
* html/SearchInputType.cpp:
(WebCore::SearchInputType::create):
* html/SearchInputType.h:
* html/SubmitInputType.cpp:
(WebCore::SubmitInputType::create):
* html/SubmitInputType.h:
* html/TelephoneInputType.cpp:
(WebCore::TelephoneInputType::create):
* html/TelephoneInputType.h:
* html/TextInputType.cpp:
(WebCore::TextInputType::create):
* html/TextInputType.h:
* html/TimeInputType.cpp:
(WebCore::TimeInputType::create):
* html/TimeInputType.h:
* html/URLInputType.cpp:
(WebCore::URLInputType::create):
* html/URLInputType.h:
* html/ValidationMessage.cpp:
(WebCore::ValidationMessage::create):
* html/ValidationMessage.h:
* html/ValidityState.h:
(WebCore::ValidityState::create):
* html/WeekInputType.cpp:
(WebCore::WeekInputType::create):
* html/WeekInputType.h:
* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::createCompositingBuffer):
* html/canvas/CanvasRenderingContext2D.h:
(WebCore::CanvasRenderingContext2D::create):
* html/canvas/EXTDrawBuffers.cpp:
(WebCore::EXTDrawBuffers::create):
* html/canvas/EXTDrawBuffers.h:
* html/canvas/EXTTextureFilterAnisotropic.cpp:
(WebCore::EXTTextureFilterAnisotropic::create):
* html/canvas/EXTTextureFilterAnisotropic.h:
* html/canvas/OESElementIndexUint.cpp:
(WebCore::OESElementIndexUint::create):
* html/canvas/OESElementIndexUint.h:
* html/canvas/OESStandardDerivatives.cpp:
(WebCore::OESStandardDerivatives::create):
* html/canvas/OESStandardDerivatives.h:
* html/canvas/OESTextureFloat.cpp:
(WebCore::OESTextureFloat::create):
* html/canvas/OESTextureFloat.h:
* html/canvas/OESTextureHalfFloat.cpp:
(WebCore::OESTextureHalfFloat::create):
* html/canvas/OESTextureHalfFloat.h:
* html/canvas/OESVertexArrayObject.cpp:
(WebCore::OESVertexArrayObject::create):
* html/canvas/OESVertexArrayObject.h:
* html/canvas/WebGLCompressedTextureATC.cpp:
(WebCore::WebGLCompressedTextureATC::create):
* html/canvas/WebGLCompressedTextureATC.h:
* html/canvas/WebGLCompressedTexturePVRTC.cpp:
(WebCore::WebGLCompressedTexturePVRTC::create):
* html/canvas/WebGLCompressedTexturePVRTC.h:
* html/canvas/WebGLCompressedTextureS3TC.cpp:
(WebCore::WebGLCompressedTextureS3TC::create):
* html/canvas/WebGLCompressedTextureS3TC.h:
* html/canvas/WebGLDebugRendererInfo.cpp:
(WebCore::WebGLDebugRendererInfo::create):
* html/canvas/WebGLDebugRendererInfo.h:
* html/canvas/WebGLDebugShaders.cpp:
(WebCore::WebGLDebugShaders::create):
* html/canvas/WebGLDebugShaders.h:
* html/canvas/WebGLDepthTexture.cpp:
(WebCore::WebGLDepthTexture::create):
* html/canvas/WebGLDepthTexture.h:
* html/canvas/WebGLLoseContext.cpp:
(WebCore::WebGLLoseContext::create):
* html/canvas/WebGLLoseContext.h:
* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::create):
* html/canvas/WebGLRenderingContext.h:
* html/parser/BackgroundHTMLParser.cpp:
(WebCore::BackgroundHTMLParser::BackgroundHTMLParser):
(WebCore::BackgroundHTMLParser::resumeFrom):
* html/parser/BackgroundHTMLParser.h:
(WebCore::BackgroundHTMLParser::create):
* html/parser/HTMLDocumentParser.cpp:
(WebCore::HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser):
(WebCore::HTMLDocumentParser::validateSpeculations):
(WebCore::HTMLDocumentParser::discardSpeculationsAndResumeFrom):
(WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
* html/parser/HTMLDocumentParser.h:
* html/parser/HTMLElementStack.cpp:
(WebCore::HTMLElementStack::ElementRecord::ElementRecord):
* html/parser/HTMLElementStack.h:
(WebCore::HTMLElementStack::ElementRecord::releaseNext):
(WebCore::HTMLElementStack::ElementRecord::setNext):
* html/parser/HTMLMetaCharsetParser.h:
(WebCore::HTMLMetaCharsetParser::create):
* html/parser/HTMLParserScheduler.h:
(WebCore::HTMLParserScheduler::create):
* html/parser/HTMLParserThread.h:
(WebCore::HTMLParserThread::create):
* html/parser/HTMLPreloadScanner.cpp:
(WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
* html/parser/HTMLResourcePreloader.cpp:
(WebCore::HTMLResourcePreloader::preload):
* html/parser/HTMLResourcePreloader.h:
(WebCore::PreloadRequest::create):
* html/parser/HTMLScriptRunner.h:
(WebCore::HTMLScriptRunner::create):
* html/parser/HTMLToken.h:
(WebCore::HTMLToken::releaseDoctypeData):
* html/parser/HTMLTokenizer.h:
(WebCore::HTMLTokenizer::create):
* html/parser/HTMLTreeBuilder.h:
(WebCore::HTMLTreeBuilder::create):
* html/parser/XSSAuditor.cpp:
(WebCore::XSSAuditor::filterToken):
* html/parser/XSSAuditor.h:
* html/parser/XSSAuditorDelegate.h:
(WebCore::XSSInfo::create):
* html/track/WebVTTParser.h:
(WebCore::WebVTTParser::create):
* html/track/WebVTTTokenizer.h:
(WebCore::WebVTTTokenizer::create):

Source/WTF:

Make operator= work work for different types of OwnPtrs.

* wtf/OwnPtr.h:

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

8 years agoDFG doesn't properly keep scope alive for op_put_to_scope
mhahnenberg@apple.com [Tue, 17 Sep 2013 21:57:25 +0000 (21:57 +0000)]
DFG doesn't properly keep scope alive for op_put_to_scope
https://bugs.webkit.org/show_bug.cgi?id=121519

Reviewed by Michael Saboff.

This was a latent bug that can't actually occur in ToT. It was uncovered by causing slow
path calls in the baseline JIT for op_put_to_scope in places where we couldn't before (but
which were necessary for gen GC).

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::parseBlock):

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

8 years agoWeb Inspector: inspector/storage-panel-dom-storage-update.html is flakey on the bots
ap@apple.com [Tue, 17 Sep 2013 21:48:58 +0000 (21:48 +0000)]
Web Inspector: inspector/storage-panel-dom-storage-update.html is flakey on the bots
https://bugs.webkit.org/show_bug.cgi?id=120544

* platform/mac-wk2/TestExpectations:
* platform/mac/TestExpectations:
Marking as such again.

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

8 years agoUpstream changes to WebHTMLConverter to support HTML
enrica@apple.com [Tue, 17 Sep 2013 21:48:13 +0000 (21:48 +0000)]
Upstream changes to WebHTMLConverter to support HTML
to NSAttributedString conversion on both iOS and OS X.

Reviewed by Benjamin Poulain.

* platform/mac/HTMLConverter.h:
* platform/mac/HTMLConverter.mm:
(WebDefaultFont):
(_fontForNameAndSize):
(+[WebHTMLConverter defaultParagraphStyle]):
(-[WebHTMLConverter _computedStyleForElement:]):
(-[WebHTMLConverter _specifiedStyleForElement:]):
(-[WebHTMLConverter _computedStringForNode:property:]):
(-[WebHTMLConverter _stringForNode:property:]):
(-[WebHTMLConverter _getComputedFloat:forNode:property:]):
(-[WebHTMLConverter _getFloat:forNode:property:]):
(_NSFirstPathForDirectoriesInDomains):
(_NSSystemLibraryPath):
(-[WebHTMLConverter _webKitBundle]):
(_colorForRGBColor):
(_shadowForShadowStyle):
(-[WebHTMLConverter _elementIsBlockLevel:]):
(-[WebHTMLConverter _elementHasOwnBackgroundColor:]):
(-[WebHTMLConverter _computedColorForNode:property:]):
(-[WebHTMLConverter _colorForNode:property:]):
(-[WebHTMLConverter _computedAttributesForElement:]):
(-[WebHTMLConverter _attributesForElement:]):
(-[WebHTMLConverter _newParagraphForElement:tag:allowEmpty:suppressTrailingSpace:]):
(-[WebHTMLConverter _newLineForElement:]):
(-[WebHTMLConverter _newTabForElement:]):
(-[WebHTMLConverter _WebMessageDocumentClass]):
(-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
(-[WebHTMLConverter _addQuoteForElement:opening:level:]):
(-[WebHTMLConverter _addValue:forElement:]):
(-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
(_dateForString):
(_colCompare):
(-[WebHTMLConverter _processMetaElementWithName:content:]):
(-[WebHTMLConverter _processHeadElement:]):
(-[WebHTMLConverter _enterElement:tag:display:embedded:]):
(-[WebHTMLConverter _addTableForElement:]):
(-[WebHTMLConverter _addTableCellForElement:]):
(-[WebHTMLConverter _processElement:tag:display:depth:]):
(-[WebHTMLConverter _addMarkersToList:range:]):
(-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
(-[WebHTMLConverter _processText:]):
(-[WebHTMLConverter _traverseNode:depth:embedded:]):
(-[WebHTMLConverter _traverseFooterNode:depth:]):
(-[WebHTMLConverter _loadFromDOMRange]):
(-[WebHTMLConverter dealloc]):
(-[WebHTMLConverter init]):
(-[WebHTMLConverter initWithDOMRange:]):
(-[WebHTMLConverter attributedString]):
(+[WebHTMLConverter editingAttributedStringFromRange:]):

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

8 years agoAdd make_unique and start using it
weinig@apple.com [Tue, 17 Sep 2013 21:46:10 +0000 (21:46 +0000)]
Add make_unique and start using it
https://bugs.webkit.org/show_bug.cgi?id=121523

Reviewed by Anders Carlsson.

../WebCore:

* html/HTMLAreaElement.h:
* html/HTMLFrameSetElement.h:
* platform/Length.cpp:
(WebCore::newCoordsArray):
(WebCore::newLengthArray):
* platform/Length.h:
Switch off OwnArrayPtr to std::unique_ptr<T[]> and make use of make_unique.

../WTF:

* wtf/StdLibExtras.h:
(std::make_unique):
Add temporary implementation of std::make_unique that we can use until our standard
libraries have support for it.

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

8 years agorun-jsc-stress-tests fails with ruby version 2
msaboff@apple.com [Tue, 17 Sep 2013 21:44:09 +0000 (21:44 +0000)]
run-jsc-stress-tests fails with ruby version 2
https://bugs.webkit.org/show_bug.cgi?id=121521

Reviewed by Jessie Berlin.

Explicitly set LANG to en_US.UTB-8 before starting run-jsc-stress-tests.

* Scripts/run-javascriptcore-tests:

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

8 years agoHardware accelerated CSS transitions appear pixelated when scaled up using transform
simon.fraser@apple.com [Tue, 17 Sep 2013 21:33:48 +0000 (21:33 +0000)]
Hardware accelerated CSS transitions appear pixelated when scaled up using transform
https://bugs.webkit.org/show_bug.cgi?id=27684
<rdar://problem/6134606>

Source/WebCore:

Reviewed by Dean Jackson.

Take transforms and animations into account when computing the contentsScale
for a layer, so that scaled-up layers remain sharp most of the time.

In its recursiveCommitChanges() tree walk, GraphicsLayerCA now tracks
a root-relative transform, and extracts from that transform the X and Y
scales which it uses to scale the backing store.

If the layer has transform animations on it, we keep around
a transformation matrix for the animation endpoints (or keyframes),
pick up the state that has the larger impact on the root-relative scale,
and use that as the layer's transform, and the transform when recursing
over descendants.

Tests: compositing/contents-scale/animating.html
       compositing/contents-scale/scaled-ancestor.html
       compositing/contents-scale/simple-scale.html
       compositing/contents-scale/z-translate.html

* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::maxScaleFromTransform): Decompose the transform if necesssary
to extract the X and Y scale components.
(WebCore::GraphicsLayerCA::GraphicsLayerCA): Initialize m_rootRelativeScaleFactor.
(WebCore::GraphicsLayerCA::flushCompositingState): Supply a TransformationMatrix
for the root of the recursion.
(WebCore::GraphicsLayerCA::layerTransform): This code was factored out of
computeVisibleRect(), and optionally takes a custom transform.
(WebCore::GraphicsLayerCA::computeVisibleRect): Use the layerTransform() function.
(WebCore::GraphicsLayerCA::updateRootRelativeScale): Given a transform from the root,
find the max scale factor by multiplying the various animation endpoint matrices and picking
the one with the biggest impact on scale. Use this to set m_rootRelativeScaleFactor, and
set the flag to say that we need to update contentsScale.
(WebCore::GraphicsLayerCA::recursiveCommitChanges):
(WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): After updating
animations, call updateRootRelativeScale() to update m_rootRelativeScaleFactor.
(WebCore::GraphicsLayerCA::updateAnimations): We have a side table of animation name to
TransformationMatrix, so figure out which entries can be removed from that side table,
and remove them.
(WebCore::GraphicsLayerCA::setAnimationOnLayer):
(WebCore::GraphicsLayerCA::appendToUncommittedAnimations): Store the matrices for
animation endpoints/keyframes in the m_animationTransforms side table. We don't store
them directly in LayerPropertyAnimation because we just want the final matrix for
a transform list, and using a side table makes ownership easier to manage.
(WebCore::GraphicsLayerCA::getTransformFromAnimationsWithMaxScaleImpact):
goes through the matrices for the running animation endpoints/keyframes, and
multiplies each with the transform up to this layer to find the matrix with the
larger impact on scale.
(WebCore::GraphicsLayerCA::setTransformAnimationEndpoints): Returns a vector
of TransformationMatrix for the from and to states.
(WebCore::GraphicsLayerCA::setTransformAnimationKeyframes): Returns a vector
of TransformationMatrix for the keyframes.
(WebCore::GraphicsLayerCA::updateContentsScale): Include m_rootRelativeScaleFactor in the
scale factor computation.
(WebCore::GraphicsLayerCA::dumpAdditionalProperties): If we're dumping visible rects,
also dump the contentsScale. Convenient at these are useful to look at together, and I didn't
want to pollute Internals with yet more flags.
* platform/graphics/ca/GraphicsLayerCA.h:
(WebCore::GraphicsLayerCA::LayerPropertyAnimation::LayerPropertyAnimation): Formatting.

LayoutTests:

Reviewed by Dean Jackson.

New tests that dump contentsScale under various scaling scenarios:

* compositing/contents-scale/animating-expected.txt: Added.
* compositing/contents-scale/animating.html: Added.
* compositing/contents-scale/scaled-ancestor-expected.txt: Added.
* compositing/contents-scale/scaled-ancestor.html: Added.
* compositing/contents-scale/simple-scale-expected.txt: Added.
* compositing/contents-scale/simple-scale.html: Added.
* compositing/contents-scale/z-translate-expected.txt: Added.
* compositing/contents-scale/z-translate.html: Added.

These tests had Mac-specific results (which include visible rects and now
contents scale) in the cross-platform directory, so cleaned up the cross-platform
results and moved the Mac results to platform-mac.

* compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants-expected.txt:
* compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants2-expected.txt:
* compositing/visible-rect/2d-transformed-expected.txt:
* compositing/visible-rect/3d-transform-style-expected.txt:
* compositing/visible-rect/3d-transformed-expected.txt:
* compositing/visible-rect/animated-expected.txt:
* compositing/visible-rect/animated-from-none-expected.txt:
* compositing/visible-rect/clipped-by-viewport-expected.txt:
* compositing/visible-rect/clipped-visible-rect-expected.txt:
* compositing/visible-rect/flipped-preserve-3d-expected.txt:
* compositing/visible-rect/iframe-and-layers-expected.txt:
* compositing/visible-rect/nested-transform-expected.txt:
* compositing/visible-rect/scrolled-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-clamped-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
* platform/mac/compositing/tiling/tile-cache-zoomed-expected.txt:
* platform/mac/compositing/visible-rect/2d-transformed-expected.txt: Copied from LayoutTests/compositing/visible-rect/2d-transformed-expected.txt.
* platform/mac/compositing/visible-rect/3d-transform-style-expected.txt: Copied from LayoutTests/compositing/visible-rect/3d-transform-style-expected.txt.
* platform/mac/compositing/visible-rect/3d-transformed-expected.txt: Copied from LayoutTests/compositing/visible-rect/3d-transformed-expected.txt.
* platform/mac/compositing/visible-rect/animated-expected.txt: Copied from LayoutTests/compositing/visible-rect/animated-expected.txt.
* platform/mac/compositing/visible-rect/animated-from-none-expected.txt: Copied from LayoutTests/compositing/visible-rect/animated-from-none-expected.txt.
* platform/mac/compositing/visible-rect/clipped-by-viewport-expected.txt: Copied from LayoutTests/compositing/visible-rect/clipped-by-viewport-expected.txt.
* platform/mac/compositing/visible-rect/clipped-visible-rect-expected.txt: Copied from LayoutTests/compositing/visible-rect/clipped-visible-rect-expected.txt.
* platform/mac/compositing/visible-rect/flipped-preserve-3d-expected.txt: Copied from LayoutTests/compositing/visible-rect/flipped-preserve-3d-expected.txt.
* platform/mac/compositing/visible-rect/iframe-and-layers-expected.txt: Copied from LayoutTests/compositing/visible-rect/iframe-and-layers-expected.txt.
* platform/mac/compositing/visible-rect/iframe-no-layers-expected.txt:
* platform/mac/compositing/visible-rect/nested-transform-expected.txt: Copied from LayoutTests/compositing/visible-rect/nested-transform-expected.txt.
* platform/mac/compositing/visible-rect/scrolled-expected.txt: Copied from LayoutTests/compositing/visible-rect/scrolled-expected.txt.

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

8 years agoDon't GC while OSR compiling
fpizlo@apple.com [Tue, 17 Sep 2013 20:56:57 +0000 (20:56 +0000)]
Don't GC while OSR compiling
https://bugs.webkit.org/show_bug.cgi?id=121513

Reviewed by Mark Hahnenberg.

Fixes some rare crashes that I see in ConservativeRoots, while in a GC from OSR exit
compilation.

* dfg/DFGOSRExitCompiler.cpp:
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileFTLOSRExit):

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

8 years agoUnreviewed, rolling out r155977.
commit-queue@webkit.org [Tue, 17 Sep 2013 20:54:00 +0000 (20:54 +0000)]
Unreviewed, rolling out r155977.
http://trac.webkit.org/changeset/155977
https://bugs.webkit.org/show_bug.cgi?id=121515

Broke over a dozen tests on Mac WK2 (Requested by ap on
#webkit).

Source/WebCore:

* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::GraphicsLayerCA):
(WebCore::GraphicsLayerCA::flushCompositingState):
(WebCore::GraphicsLayerCA::computeVisibleRect):
(WebCore::GraphicsLayerCA::recursiveCommitChanges):
(WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
(WebCore::GraphicsLayerCA::updateAnimations):
(WebCore::GraphicsLayerCA::setAnimationOnLayer):
(WebCore::GraphicsLayerCA::appendToUncommittedAnimations):
(WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
(WebCore::GraphicsLayerCA::setTransformAnimationKeyframes):
(WebCore::GraphicsLayerCA::updateContentsScale):
(WebCore::GraphicsLayerCA::dumpAdditionalProperties):
* platform/graphics/ca/GraphicsLayerCA.h:
(WebCore::GraphicsLayerCA::LayerPropertyAnimation::LayerPropertyAnimation):

LayoutTests:

* compositing/contents-scale/animating-expected.txt: Removed.
* compositing/contents-scale/animating.html: Removed.
* compositing/contents-scale/scaled-ancestor-expected.txt: Removed.
* compositing/contents-scale/scaled-ancestor.html: Removed.
* compositing/contents-scale/simple-scale-expected.txt: Removed.
* compositing/contents-scale/simple-scale.html: Removed.
* compositing/contents-scale/z-translate-expected.txt: Removed.
* compositing/contents-scale/z-translate.html: Removed.
* compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants-expected.txt:
* compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants2-expected.txt:
* compositing/visible-rect/2d-transformed-expected.txt:
* compositing/visible-rect/3d-transform-style-expected.txt:
* compositing/visible-rect/3d-transformed-expected.txt:
* compositing/visible-rect/animated-expected.txt:
* compositing/visible-rect/animated-from-none-expected.txt:
* compositing/visible-rect/clipped-by-viewport-expected.txt:
* compositing/visible-rect/clipped-visible-rect-expected.txt:
* compositing/visible-rect/flipped-preserve-3d-expected.txt:
* compositing/visible-rect/iframe-and-layers-expected.txt:
* compositing/visible-rect/nested-transform-expected.txt:
* compositing/visible-rect/scrolled-expected.txt:
* platform/mac/compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants-expected.txt: Removed.
* platform/mac/compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants2-expected.txt: Removed.
* platform/mac/compositing/tiling/rotated-tiled-clamped-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
* platform/mac/compositing/tiling/tile-cache-zoomed-expected.txt:
* platform/mac/compositing/visible-rect/2d-transformed-expected.txt: Removed.
* platform/mac/compositing/visible-rect/3d-transform-style-expected.txt: Removed.
* platform/mac/compositing/visible-rect/3d-transformed-expected.txt: Removed.
* platform/mac/compositing/visible-rect/animated-expected.txt: Removed.
* platform/mac/compositing/visible-rect/animated-from-none-expected.txt: Removed.
* platform/mac/compositing/visible-rect/clipped-by-viewport-expected.txt: Removed.
* platform/mac/compositing/visible-rect/clipped-visible-rect-expected.txt: Removed.
* platform/mac/compositing/visible-rect/flipped-preserve-3d-expected.txt: Removed.
* platform/mac/compositing/visible-rect/iframe-and-layers-expected.txt: Removed.
* platform/mac/compositing/visible-rect/iframe-no-layers-expected.txt:
* platform/mac/compositing/visible-rect/nested-transform-expected.txt: Removed.
* platform/mac/compositing/visible-rect/scrolled-expected.txt: Removed.

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

8 years agoMediaStream API: Changing the device enumeration to be async
eric.carlson@apple.com [Tue, 17 Sep 2013 20:36:26 +0000 (20:36 +0000)]
MediaStream API: Changing the device enumeration to be async
https://bugs.webkit.org/show_bug.cgi?id=120883

Reviewed by Darin Adler.

Source/WebCore:

Parts merged from https://chromium.googlesource.com/chromium/blink/+/40a96080a1531e50de4eb84571c7dc9fb321ece5
and https://chromium.googlesource.com/chromium/blink/+/ff783a23bb1add588971a8187048a305cf485121
by Tommy Widenflycht.

Test: fast/mediastream/MediaStreamTrack-getSources.html

* CMakeLists.txt: Added new files.
* DerivedSources.make: Ditto.
* GNUmakefile.list.am: Ditto.

* Modules/mediastream/MediaStreamTrack.cpp:
(WebCore::MediaStreamTrack::kind): ASCIILiteral -> NeverDestroyed<AtomicString>.
(WebCore::MediaStreamTrack::readyState): Ditto.
(WebCore::MediaStreamTrack::getSources): New.
* Modules/mediastream/MediaStreamTrack.h:
* Modules/mediastream/MediaStreamTrack.idl:

* Modules/mediastream/MediaStreamTrackSourcesCallback.h: Added.
* Modules/mediastream/MediaStreamTrackSourcesCallback.idl: Added.
* Modules/mediastream/MediaStreamTrackSourcesRequest.cpp: Added.
* Modules/mediastream/MediaStreamTrackSourcesRequest.h: Added.

* Modules/mediastream/SourceInfo.cpp: Added.
* Modules/mediastream/SourceInfo.h: Added.
* Modules/mediastream/SourceInfo.idl: Added.

* WebCore.xcodeproj/project.pbxproj: Add new files.

* bindings/js/JSDOMBinding.h: Add toJS templates for Vector<T> and Vector<RefPtr<T>>.

* platform/mediastream/MediaStreamCenter.h: Add prototype for getMediaStreamTrackSources.

* platform/mediastream/MediaStreamTrackSourcesRequestClient.h: Added.

* platform/mediastream/blackberry/MediaStreamCenterBlackBerry.cpp:
(WebCore::MediaStreamCenterMac::getMediaStreamTrackSources): Added.
* platform/mediastream/blackberry/MediaStreamCenterBlackBerry.h:

* platform/mediastream/gstreamer/MediaStreamCenterGStreamer.cpp:
(WebCore::MediaStreamCenterMac::getMediaStreamTrackSources): Added
* platform/mediastream/gstreamer/MediaStreamCenterGStreamer.h:

* platform/mediastream/mac/MediaStreamCenterMac.cpp:
(WebCore::MediaStreamCenterMac::getMediaStreamTrackSources): Added.
* platform/mediastream/mac/MediaStreamCenterMac.h:

LayoutTests:

* fast/mediastream/MediaStreamTrack-getSources-expected.txt: Added.
* fast/mediastream/MediaStreamTrack-getSources.html: Added.

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

8 years agolUnreviewed, rolling out r155976.
bfulgham@apple.com [Tue, 17 Sep 2013 20:30:12 +0000 (20:30 +0000)]
lUnreviewed, rolling out r155976.
http://trac.webkit.org/changeset/155976
https://bugs.webkit.org/show_bug.cgi?id=121512

Broke a test, needs cleanup (Requested by ap_ on #webkit).

Patch by Commit Queue <commit-queue@webkit.org> on 2013-09-17

* platform/mac/accessibility/element-busy-changed-expected.txt: Removed.
* platform/mac/accessibility/element-busy-changed.html: Removed.

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

8 years agoUnreviewed, rolling out r155976.
commit-queue@webkit.org [Tue, 17 Sep 2013 20:10:34 +0000 (20:10 +0000)]
Unreviewed, rolling out r155976.
http://trac.webkit.org/changeset/155976
https://bugs.webkit.org/show_bug.cgi?id=121512

Broke a test, needs cleanup (Requested by ap_ on #webkit).

Source/WebCore:

* accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::handleAttributeChanged):
* accessibility/AXObjectCache.h:
* accessibility/mac/AXObjectCacheMac.mm:
(WebCore::AXObjectCache::postPlatformNotification):

LayoutTests:

* platform/mac/accessibility/element-busy-changed-expected.txt: Removed.
* platform/mac/accessibility/element-busy-changed.html: Removed.

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

8 years agoImprove srcset parser
commit-queue@webkit.org [Tue, 17 Sep 2013 20:06:49 +0000 (20:06 +0000)]
Improve srcset parser
https://bugs.webkit.org/show_bug.cgi?id=119423

Patch by Romain Perier <romain.perier@gmail.com> on 2013-09-17
Reviewed by Benjamin Poulain.

Source/WebCore:

Added new tests and covered by existing ones.

* html/parser/HTMLParserIdioms.cpp:
(WebCore::isHTMLSpaceOrComma): Add a new predicate function used by String::find()
to get the first space or comma character from the input string.
(WebCore::parseImagesWithScaleFromSrcSetAttribute): Add a new static function to parse
and extract images with scale from the srcset attribute. All valid candidates are
returned to the caller through a list. This parsing function also adds support
for data URI schemes as described by the specification.
(WebCore::bestFitSourceForImageAttributes): Remove intermediate arrays of string
when parsing. That is more efficient and avoids trashing the data cache
(varying between 20 and 65% faster depending of the amount of data)
The parser now walks along the attribute value and extracts the candidates directly.

LayoutTests:

* fast/hidpi/image-srcset-data-srcset-invalid-inputs.html: Ensures that a various invalid
  form of data uri schemes are supported by the srcset attribute.
* fast/hidpi/image-srcset-data-srcset-valid-inputs.html: Ensures that a various valid
  form of data uri schemes are supported by the srcset attribute.
* fast/hidpi/image-srcset-data-srcset.html: Use comma instead of %.
* fast/hidpi/image-srcset-fraction-1.5x.html: Added.
* fast/hidpi/image-srcset-invalid-inputs-except-one.html: Missing srcset-helper.js. Adding more invalid cases.
* fast/hidpi/image-srcset-invalid-inputs.html: Adding more invalid cases.
* fast/hidpi/image-srcset-nomodifier.html: Updated output as behaviour changed for this case.
* fast/hidpi/image-srcset-space-suffix-nomodifier.html: Ensures that a single candidate with no scale modifier
  is supported by the srcset attribute, even if a space is left at the end.
* fast/hidpi/image-srcset-space-prefix-nomodifier.html: Ensures that a single candidate with no scale modifier
  is supported by the srcset attribute, even if a space is left at the beginning.
* fast/hidpi/image-srcset-space-surrounded-nomodifier.html: Ensures that a single candidate with no scale modifier
  is supported by the srcset attribute, even if it is surrounded by spaces.
* fast/hidpi/image-srcset-data-escaped-srcset.html: Ensures that data uri schemes with escaped characters
  are supported by the srcset attribute.

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

8 years agoBuildfix for !ENABLE(CUSTOM_PROTOCOLS) platforms
ossy@webkit.org [Tue, 17 Sep 2013 20:00:05 +0000 (20:00 +0000)]
Buildfix for !ENABLE(CUSTOM_PROTOCOLS) platforms
https://bugs.webkit.org/show_bug.cgi?id=121417

Reviewed by Alexey Proskuryakov.

Original patch by Balazs Kelemen <kbalazs@webkit.org>.

* CMakeLists.txt: Add CustomProtocolManagerProxy.messages.in.
* DerivedSources.pri: Add CustomProtocolManagerProxy.messages.in.
* GNUmakefile.am: Add CustomProtocolManagerProxy.messages.in.
* GNUmakefile.list.am: Add CustomProtocolManagerProxyMessages.h and CustomProtocolManagerProxyMessageReceiver.cpp.
* NetworkProcess/NetworkProcess.cpp: Add the missing ENABLE(CUSTOM_PROTOCOLS) guard.
(WebKit::NetworkProcess::NetworkProcess):
* UIProcess/WebProcessProxy.cpp: Remove the unnecessary conditional include.

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

8 years ago[GTK] Test /webkit2/WebKitWebInspectorServer/test-open-debugging-session times out...
kov@webkit.org [Tue, 17 Sep 2013 19:27:30 +0000 (19:27 +0000)]
[GTK] Test /webkit2/WebKitWebInspectorServer/test-open-debugging-session times out after r155714
https://bugs.webkit.org/show_bug.cgi?id=121383

Reviewed by Carlos Garcia Campos.

* UIProcess/API/gtk/tests/TestInspectorServer.cpp:
(openRemoteDebuggingSession): use the page contents' to check the remote debugging of the page
has been successfuly opened, as the title is no longer the same after the switch to the new
frontend.

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

8 years agoUnreviewed build fix after 155963.
kov@webkit.org [Tue, 17 Sep 2013 19:16:01 +0000 (19:16 +0000)]
Unreviewed build fix after 155963.

* platform/gtk/RenderThemeGtk3.cpp:
(WebCore::getStyleContext): use nullptr instead of 0.

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

8 years ago[Windows] Disable a number of crashing tests to help the EWS system run more rapidly.
bfulgham@apple.com [Tue, 17 Sep 2013 19:06:26 +0000 (19:06 +0000)]
[Windows] Disable a number of crashing tests to help the EWS system run more rapidly.
https://bugs.webkit.org/show_bug.cgi?id=121509

* platform/win/TestExpectations:

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

8 years agoMake SVGTransform::valueAsString use StringBuilder
ap@apple.com [Tue, 17 Sep 2013 19:05:23 +0000 (19:05 +0000)]
Make SVGTransform::valueAsString use StringBuilder
https://bugs.webkit.org/show_bug.cgi?id=121498

Unreviewed typo fix, should address a regression on svg/dom/SVGViewSpec.html.

* svg/SVGTransform.cpp: (WebCore::SVGTransform::valueAsString): "e" is totally
not the same as "f".

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

8 years ago[Windows] Disable a number of failing tests to help the EWS system run more rapidly.
bfulgham@apple.com [Tue, 17 Sep 2013 18:57:15 +0000 (18:57 +0000)]
[Windows] Disable a number of failing tests to help the EWS system run more rapidly.

* platform/win/TestExpectations:

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

8 years ago[Windows] Unreviewed build fix after r155963.
bfulgham@apple.com [Tue, 17 Sep 2013 18:22:02 +0000 (18:22 +0000)]
[Windows] Unreviewed build fix after r155963.

* DumpRenderTree/win/TestRunnerWin.cpp:
(TestRunner::evaluateScriptInIsolatedWorld): Pass nullptr rather than 0.

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

8 years ago[Windows] Speculative build fix after r155963
bfulgham@apple.com [Tue, 17 Sep 2013 18:15:15 +0000 (18:15 +0000)]
[Windows] Speculative build fix after r155963

* WebKitCOMAPI.cpp:
(classFactory): Use nullptr rather than 0 for HashMap.

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

8 years agoHardware accelerated CSS transitions appear pixelated when scaled up using transform
simon.fraser@apple.com [Tue, 17 Sep 2013 18:12:52 +0000 (18:12 +0000)]
Hardware accelerated CSS transitions appear pixelated when scaled up using transform
https://bugs.webkit.org/show_bug.cgi?id=27684
<rdar://problem/6134606>

Source/WebCore:

Reviewed by Dean Jackson.

Take transforms and animations into account when computing the contentsScale
for a layer, so that scaled-up layers remain sharp most of the time.

In its recursiveCommitChanges() tree walk, GraphicsLayerCA now tracks
a root-relative transform, and extracts from that transform the X and Y
scales which it uses to scale the backing store.

If the layer has transform animations on it, we keep around
a transformation matrix for the animation endpoints (or keyframes),
pick up the state that has the larger impact on the root-relative scale,
and use that as the layer's transform, and the transform when recursing
over descendants.

Tests: compositing/contents-scale/animating.html
       compositing/contents-scale/scaled-ancestor.html
       compositing/contents-scale/simple-scale.html
       compositing/contents-scale/z-translate.html

* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::maxScaleFromTransform): Decompose the transform if necesssary
to extract the X and Y scale components.
(WebCore::GraphicsLayerCA::GraphicsLayerCA): Initialize m_rootRelativeScaleFactor.
(WebCore::GraphicsLayerCA::flushCompositingState): Supply a TransformationMatrix
for the root of the recursion.
(WebCore::GraphicsLayerCA::layerTransform): This code was factored out of
computeVisibleRect(), and optionally takes a custom transform.
(WebCore::GraphicsLayerCA::computeVisibleRect): Use the layerTransform() function.
(WebCore::GraphicsLayerCA::updateRootRelativeScale): Given a transform from the root,
find the max scale factor by multiplying the various animation endpoint matrices and picking
the one with the biggest impact on scale. Use this to set m_rootRelativeScaleFactor, and
set the flag to say that we need to update contentsScale.
(WebCore::GraphicsLayerCA::recursiveCommitChanges):
(WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): After updating
animations, call updateRootRelativeScale() to update m_rootRelativeScaleFactor.
(WebCore::GraphicsLayerCA::updateAnimations): We have a side table of animation name to
TransformationMatrix, so figure out which entries can be removed from that side table,
and remove them.
(WebCore::GraphicsLayerCA::setAnimationOnLayer):
(WebCore::GraphicsLayerCA::appendToUncommittedAnimations): Store the matrices for
animation endpoints/keyframes in the m_animationTransforms side table. We don't store
them directly in LayerPropertyAnimation because we just want the final matrix for
a transform list, and using a side table makes ownership easier to manage.
(WebCore::GraphicsLayerCA::getTransformFromAnimationsWithMaxScaleImpact):
goes through the matrices for the running animation endpoints/keyframes, and
multiplies each with the transform up to this layer to find the matrix with the
larger impact on scale.
(WebCore::GraphicsLayerCA::setTransformAnimationEndpoints): Returns a vector
of TransformationMatrix for the from and to states.
(WebCore::GraphicsLayerCA::setTransformAnimationKeyframes): Returns a vector
of TransformationMatrix for the keyframes.
(WebCore::GraphicsLayerCA::updateContentsScale): Include m_rootRelativeScaleFactor in the
scale factor computation.
(WebCore::GraphicsLayerCA::dumpAdditionalProperties): If we're dumping visible rects,
also dump the contentsScale. Convenient at these are useful to look at together, and I didn't
want to pollute Internals with yet more flags.
* platform/graphics/ca/GraphicsLayerCA.h:
(WebCore::GraphicsLayerCA::LayerPropertyAnimation::LayerPropertyAnimation): Formatting.

LayoutTests:

Reviewed by Dean Jackson.

New tests that dump contentsScale under various scaling scenarios:

* compositing/contents-scale/animating-expected.txt: Added.
* compositing/contents-scale/animating.html: Added.
* compositing/contents-scale/scaled-ancestor-expected.txt: Added.
* compositing/contents-scale/scaled-ancestor.html: Added.
* compositing/contents-scale/simple-scale-expected.txt: Added.
* compositing/contents-scale/simple-scale.html: Added.
* compositing/contents-scale/z-translate-expected.txt: Added.
* compositing/contents-scale/z-translate.html: Added.

These tests had Mac-specific results (which include visible rects and now
contents scale) in the cross-platform directory, so cleaned up the cross-platform
results and moved the Mac results to platform-mac.

* compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants-expected.txt:
* compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants2-expected.txt:
* compositing/visible-rect/2d-transformed-expected.txt:
* compositing/visible-rect/3d-transform-style-expected.txt:
* compositing/visible-rect/3d-transformed-expected.txt:
* compositing/visible-rect/animated-expected.txt:
* compositing/visible-rect/animated-from-none-expected.txt:
* compositing/visible-rect/clipped-by-viewport-expected.txt:
* compositing/visible-rect/clipped-visible-rect-expected.txt:
* compositing/visible-rect/flipped-preserve-3d-expected.txt:
* compositing/visible-rect/iframe-and-layers-expected.txt:
* compositing/visible-rect/nested-transform-expected.txt:
* compositing/visible-rect/scrolled-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-clamped-expected.txt:
* platform/mac/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
* platform/mac/compositing/tiling/tile-cache-zoomed-expected.txt:
* platform/mac/compositing/visible-rect/2d-transformed-expected.txt: Copied from LayoutTests/compositing/visible-rect/2d-transformed-expected.txt.
* platform/mac/compositing/visible-rect/3d-transform-style-expected.txt: Copied from LayoutTests/compositing/visible-rect/3d-transform-style-expected.txt.
* platform/mac/compositing/visible-rect/3d-transformed-expected.txt: Copied from LayoutTests/compositing/visible-rect/3d-transformed-expected.txt.
* platform/mac/compositing/visible-rect/animated-expected.txt: Copied from LayoutTests/compositing/visible-rect/animated-expected.txt.
* platform/mac/compositing/visible-rect/animated-from-none-expected.txt: Copied from LayoutTests/compositing/visible-rect/animated-from-none-expected.txt.
* platform/mac/compositing/visible-rect/clipped-by-viewport-expected.txt: Copied from LayoutTests/compositing/visible-rect/clipped-by-viewport-expected.txt.
* platform/mac/compositing/visible-rect/clipped-visible-rect-expected.txt: Copied from LayoutTests/compositing/visible-rect/clipped-visible-rect-expected.txt.
* platform/mac/compositing/visible-rect/flipped-preserve-3d-expected.txt: Copied from LayoutTests/compositing/visible-rect/flipped-preserve-3d-expected.txt.
* platform/mac/compositing/visible-rect/iframe-and-layers-expected.txt: Copied from LayoutTests/compositing/visible-rect/iframe-and-layers-expected.txt.
* platform/mac/compositing/visible-rect/iframe-no-layers-expected.txt:
* platform/mac/compositing/visible-rect/nested-transform-expected.txt: Copied from LayoutTests/compositing/visible-rect/nested-transform-expected.txt.
* platform/mac/compositing/visible-rect/scrolled-expected.txt: Copied from LayoutTests/compositing/visible-rect/scrolled-expected.txt.

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

8 years agoAX: Expose ARIA Busy Notifications
commit-queue@webkit.org [Tue, 17 Sep 2013 18:10:47 +0000 (18:10 +0000)]
AX: Expose ARIA Busy Notifications
https://bugs.webkit.org/show_bug.cgi?id=121451

Patch by Samuel White <samuel_white@apple.com> on 2013-09-17
Reviewed by Darin Adler.

Source/WebCore:

Added AXElementBusyChanged notification that posts when aria-busy is toggled. This
enables screen readers to detect busy states without polling the focused element.

Test: platform/mac/accessibility/element-busy-changed.html

* accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::handleAttributeChanged):
* accessibility/AXObjectCache.h:
* accessibility/mac/AXObjectCacheMac.mm:
(WebCore::AXObjectCache::postPlatformNotification):

LayoutTests:

Added test to verify that elements post AXElementBusyChanged notifications when aria-busy is toggled.

* platform/mac/accessibility/element-busy-changed-expected.txt: Added.
* platform/mac/accessibility/element-busy-changed.html: Added.

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

8 years agoAdd isTextOrBR() and use it
antti@apple.com [Tue, 17 Sep 2013 18:10:02 +0000 (18:10 +0000)]
Add isTextOrBR() and use it
https://bugs.webkit.org/show_bug.cgi?id=121506

Reviewed by Darin Adler.

It is a popular test.

* dom/Document.cpp:
(WebCore::Document::updateHoverActiveState):
* editing/Editor.cpp:
(WebCore::findFirstMarkable):
* editing/TextIterator.cpp:
(WebCore::ignoresContainerClip):
* rendering/InlineBox.cpp:
(WebCore::InlineBox::logicalHeight):
* rendering/InlineIterator.h:
(WebCore::isIteratorTarget):
* rendering/RenderBlock.cpp:
(WebCore::InlineMinMaxIterator::next):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::RenderBlockFlow::layoutInlineChildren):
* rendering/RenderCounter.cpp:
(WebCore::planCounter):
* rendering/RenderObject.h:
(WebCore::RenderObject::isTextOrBR):
* rendering/RenderTreeAsText.cpp:
(WebCore::write):
* rendering/RootInlineBox.cpp:
(WebCore::RootInlineBox::ascentAndDescentForBox):
(WebCore::RootInlineBox::verticalPositionForBox):

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

8 years ago[CSS Regions] Layout Test for selection direction
rego@igalia.com [Tue, 17 Sep 2013 18:04:40 +0000 (18:04 +0000)]
[CSS Regions] Layout Test for selection direction
https://bugs.webkit.org/show_bug.cgi?id=121501

Reviewed by Darin Adler.

Selection follows DOM tree, so the highlighted text in this test case is
the opposite to what the user is actually selecting. This was not
working properly from r139197 to r155058, so adding a Layout Test to
prevent future breaks. It is a reftest comparing regions and absolute
positions behavior.

* fast/regions/selection-direction-expected.html: Added.
* fast/regions/selection-direction.html: Added.

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

8 years agoFix a typo.
andersca@apple.com [Tue, 17 Sep 2013 17:56:32 +0000 (17:56 +0000)]
Fix a typo.

* TestWebKitAPI/Tests/WTF/HashMap.cpp:
(TestWebKitAPI::TEST):

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

8 years agoRenderBR should not be RenderText
antti@apple.com [Tue, 17 Sep 2013 17:40:45 +0000 (17:40 +0000)]
RenderBR should not be RenderText
https://bugs.webkit.org/show_bug.cgi?id=121221

Rubber-stamped by Andreas Kling.

Fix assertion in these tests:

fast/repaint/selection-rl.html
fast/writing-mode/horizontal-bt-replaced-selection.html
fast/writing-mode/vertical-rl-replaced-selection.html

* rendering/InlineBox.cpp:
(WebCore::InlineBox::nodeAtPoint):

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

8 years agoRemove unused function didSetSelectionTypesForPasteboard from EditorClient.
enrica@apple.com [Tue, 17 Sep 2013 17:20:03 +0000 (17:20 +0000)]
Remove unused function didSetSelectionTypesForPasteboard from EditorClient.
https://bugs.webkit.org/show_bug.cgi?id=121464

Reviewed by Darin Adler.

Source/WebCore:

This method was only implemented in WebEditorClient.mm for Mac where it was
calling a private delegate that is no longer in use.
This patch removes it for all the platforms.
I've also removed setTypes and writeAfterSettingTypes from the implementation
of the Pasteboard class for Mac.

* editing/mac/EditorMac.mm:
(WebCore::Editor::writeSelectionToPasteboard): Now calls write instead of
setTypes and writeAfterSettingTypes.
* loader/EmptyClients.h: Removed didSetSelectionTypesForPasteboard.
* page/EditorClient.h: Ditto.
* platform/Pasteboard.h: Removed setTypes and writeAfterSettingTypes.
* platform/ios/PasteboardIOS.mm:
(WebCore::Pasteboard::writeSelection): Removed call to didSetSelectionTypesForPasteboard.
* platform/mac/PasteboardMac.mm:
(WebCore::Pasteboard::write): Added to replace setTypes and writeAfterSettingTypes.

Source/WebKit/efl:

* WebCoreSupport/EditorClientEfl.cpp:
* WebCoreSupport/EditorClientEfl.h:

Source/WebKit/gtk:

* WebCoreSupport/EditorClientGtk.cpp:
* WebCoreSupport/EditorClientGtk.h:

Source/WebKit/mac:

This method was only implemented in WebEditorClient.mm for Mac where it was
calling a private delegate that is no longer in use.

* DefaultDelegates/WebDefaultEditingDelegate.m:
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
* WebView/WebEditingDelegatePrivate.h:

Source/WebKit/qt:

* WebCoreSupport/EditorClientQt.cpp:
* WebCoreSupport/EditorClientQt.h:

Source/WebKit/win:

* WebCoreSupport/WebEditorClient.cpp:
* WebCoreSupport/WebEditorClient.h:

Source/WebKit/wince:

* WebCoreSupport/EditorClientWinCE.cpp:
* WebCoreSupport/EditorClientWinCE.h:

Source/WebKit2:

* WebProcess/WebCoreSupport/WebEditorClient.cpp:
* WebProcess/WebCoreSupport/WebEditorClient.h:

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

8 years agoFurther shrink table-populating code by making the tables read-only data and preventi...
darin@apple.com [Tue, 17 Sep 2013 17:17:50 +0000 (17:17 +0000)]
Further shrink table-populating code by making the tables read-only data and preventing inlining
https://bugs.webkit.org/show_bug.cgi?id=121468

Reviewed by Sam Weinig.

* bindings/scripts/StaticString.pm:
(GenerateStrings): Eliminated the xxxImpl globals. We definitely did not need
globals for these, much less read-write data. Instead, write the expression at
each site where we need them.
(GenerateStringAsserts): This is one such site (see above).
* css/CSSSelector.cpp:
(WebCore::populatePseudoTypeByNameMap): Mark this function NEVER_INLINE and
add static to make sure the table ends up in read-only data.
* dom/make_names.pl:
(printDefinitions): Write the xxxImpl expression (see above).
(printFactoryCppFile): Ditto. Also mark the populate function NEVER_INLINE and
add static to make sure the table ends up in read-only data.
(printWrapperFactoryCppFile): Ditto.
* html/HTMLElement.cpp:
(WebCore::populateEventNameForAttributeLocalNameMap): Mark this function
NEVER_INLINE and add static to makes sure the table ends up in read-only data.

* platform/text/UnicodeRange.cpp: Added a const to make this read-only data.

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

8 years agoShrink SVGElement::cssPropertyIdForSVGAttributeName and cssPropertyToTypeMap
darin@apple.com [Tue, 17 Sep 2013 17:13:53 +0000 (17:13 +0000)]
Shrink SVGElement::cssPropertyIdForSVGAttributeName and cssPropertyToTypeMap
https://bugs.webkit.org/show_bug.cgi?id=121499

Reviewed by Andreas Kling.

* svg/SVGElement.cpp:
(WebCore::populateAttributeNameToCSSPropertyIDMap): Added. Code that used to
be in SVGElement::cssPropertyIdForSVGAttributeName to build a map that maps
attribute names to CSS property IDs, but without the multiple unrolled calls
to HashMap functions.
(WebCore::populateAttributeNameToAnimatedPropertyTypeMap): Added. Code that
used to be in cssPropertyToTypeMap, but without the multiple unrolled calls
to HashMap functions.
(WebCore::attributeNameToAnimatedPropertyTypeMap): Renamed from
cssPropertyToTypeMap, a confusingly inaccurate and imprecise name, and
reimplemented using the populate function.
(WebCore::SVGElement::animatedPropertyTypeForAttribute): Updated to call
attributeNameToAnimatedPropertyTypeMap, and also removed the double hashing
that was done by calling contains followed by get.
(WebCore::SVGElement::cssPropertyIdForSVGAttributeName): Rewrote to use
populateAttributeNameToCSSPropertyIDMap.
(WebCore::SVGElement::isAnimatableCSSProperty): Updated to call the new
attributeNameToAnimatedPropertyTypeMap.

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

8 years agoMake SVGTransform::valueAsString use StringBuilder
darin@apple.com [Tue, 17 Sep 2013 17:09:11 +0000 (17:09 +0000)]
Make SVGTransform::valueAsString use StringBuilder
https://bugs.webkit.org/show_bug.cgi?id=121498

Reviewed by Andreas Kling.

Source/WebCore:

* svg/SVGTransform.cpp:
(WebCore::SVGTransform::valueAsString): Use StringBuilder constently to
avoid creating temporary String objects that cause additional, slow
memory allocation.

Source/WTF:

* wtf/text/StringBuilder.cpp: Added appendNumber functions corresponding to all remaining
String::number functions. If we find we don't need all of these we can delete them later,
but I don't want to give clients a reason to prefer less-efficient API to StringBuilder.
* wtf/text/StringBuilder.h: Ditto.

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

8 years agoGet rid of a couple unneeded NeverDestroyed::get() calls
darin@apple.com [Tue, 17 Sep 2013 17:07:16 +0000 (17:07 +0000)]
Get rid of a couple unneeded NeverDestroyed::get() calls
https://bugs.webkit.org/show_bug.cgi?id=121500

Reviewed by Andreas Kling.

* css/CSSSelector.cpp:
(WebCore::CSSSelector::parsePseudoType): No need to call get() here.
* dom/make_names.pl:
(printFactoryCppFile): Ditto.
(printWrapperFactoryCppFile): Ditto.

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

8 years agoClean up the Inspector's WebSocket code and prevent it from dropping messages.
timothy@apple.com [Tue, 17 Sep 2013 17:04:36 +0000 (17:04 +0000)]
Clean up the Inspector's WebSocket code and prevent it from dropping messages.

https://bugs.webkit.org/show_bug.cgi?id=121391

Reviewed by Joseph Pecoraro.

* UserInterface/InspectorFrontendHostStub.js:
(.WebInspector.InspectorFrontendHostStub.prototype.initializeWebSocket): Added. Create the socket
and call _sendPendingMessagesToBackendIfNeeded.
(.WebInspector.InspectorFrontendHostStub.prototype.sendMessageToBackend): Store messages as pending
if the socket isn't ready yet. Call _sendPendingMessagesToBackendIfNeeded.
(.WebInspector.InspectorFrontendHostStub.prototype._sendPendingMessagesToBackendIfNeeded): Added.
* UserInterface/Main.js:
(WebInspector._initializeWebSocketIfNeeded): Move socket creation to initializeWebSocket.

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

8 years agoBad ASSERT() in RasterShapeIntervals::firstIncludedIntervalY()
hmuller@adobe.com [Tue, 17 Sep 2013 16:46:27 +0000 (16:46 +0000)]
Bad ASSERT() in RasterShapeIntervals::firstIncludedIntervalY()
https://bugs.webkit.org/show_bug.cgi?id=121455

Reviewed by Darin Adler.

Source/WebCore:

Corrected a bad ASSERT() introduced in https://bugs.webkit.org/show_bug.cgi?id=120211.

Test: fast/shapes/shape-inside/shape-inside-first-fit-crash.html

* rendering/shapes/RasterShape.cpp:
(WebCore::RasterShapeIntervals::firstIncludedIntervalY):

LayoutTests:

Simple regression test, it crashes in the bad ASSERT().

* fast/shapes/shape-inside/shape-inside-first-fit-crash-expected.txt: Added.
* fast/shapes/shape-inside/shape-inside-first-fit-crash.html: Added.

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

8 years agoMove the line widow functions out of RenderBlock and into RenderBlockFlow.
hyatt@apple.com [Tue, 17 Sep 2013 16:41:42 +0000 (16:41 +0000)]
Move the line widow functions out of RenderBlock and into RenderBlockFlow.
https://bugs.webkit.org/show_bug.cgi?id=121456

Reviewed by Dean Jackson.

* rendering/RenderBlock.cpp:
* rendering/RenderBlock.h:
(WebCore::RenderBlock::RenderBlockRareData::RenderBlockRareData):
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::layoutBlockChild):
(WebCore::calculateMinimumPageHeight):
(WebCore::RenderBlockFlow::adjustLinePositionForPagination):
(WebCore::RenderBlockFlow::setBreakAtLineToAvoidWidow):
(WebCore::RenderBlockFlow::clearShouldBreakAtLineToAvoidWidow):
(WebCore::RenderBlockFlow::relayoutToAvoidWidows):
* rendering/RenderBlockFlow.h:
(WebCore::RenderBlockFlow::RenderBlockFlowRareData::RenderBlockFlowRareData):
(WebCore::RenderBlockFlow::shouldBreakAtLineToAvoidWidow):
(WebCore::RenderBlockFlow::lineBreakToAvoidWidow):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::RenderBlock::layoutRunsAndFloatsInRange):
(WebCore::RenderBlock::linkToEndLineIfNeeded):
(WebCore::RenderBlock::determineStartPosition):
(WebCore::RenderBlock::checkPaginationAndFloatsAtEndLine):
* rendering/RenderObject.h:

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

8 years agoHashMap should work with move-only keys
andersca@apple.com [Tue, 17 Sep 2013 16:26:58 +0000 (16:26 +0000)]
HashMap should work with move-only keys
https://bugs.webkit.org/show_bug.cgi?id=121310

Reviewed by Darin Adler.

Source/WebCore:

Update the call sites now that HashMap::take doesn't return a PassOwnPtr.

* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::takeRenderBoxRegionInfo):
* rendering/RenderRegion.h:
* rendering/svg/RenderSVGResourceContainer.cpp:
(WebCore::RenderSVGResourceContainer::registerResource):
* svg/SVGDocumentExtensions.cpp:
(WebCore::SVGDocumentExtensions::removePendingResource):
(WebCore::SVGDocumentExtensions::removePendingResourceForRemoval):
* svg/SVGDocumentExtensions.h:

Source/WTF:

Add extra overloads for add and set where the key is an rvalue reference, but not a
template parameter rvalue reference. This way we'll coerce the key parameter to have the expected
type instead of the passed in type, causing map.add(StringImpl::create("Hello"), 123) work when the
type of map is HashMap<String, unsigned>.

Also, sprinkle && and std::forward where appropriate.

* wtf/HashMap.h:
* wtf/HashTable.h:

Tools:

* TestWebKitAPI/Tests/WTF/HashMap.cpp:
(TestWebKitAPI::TEST):
Add test.

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

8 years agoAdd RenderObject bit for isBR().
antti@apple.com [Tue, 17 Sep 2013 16:00:04 +0000 (16:00 +0000)]
Add RenderObject bit for isBR().
https://bugs.webkit.org/show_bug.cgi?id=121494

Reviewed by Andreas Kling.

It is no longer piggybacking on isText() flag and is now hot in inline layout.

* rendering/RenderBR.cpp:
(WebCore::RenderBR::RenderBR):
* rendering/RenderBR.h:
* rendering/RenderObject.h:
(WebCore::RenderObject::isBR):
(WebCore::RenderObject::setIsBR):
(WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):

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

8 years agoExport some missing symbols for Internals after RenderArena& change.
akling@apple.com [Tue, 17 Sep 2013 15:54:07 +0000 (15:54 +0000)]
Export some missing symbols for Internals after RenderArena& change.

* WebCore.exp.in:

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

8 years ago[Qt] Unreviewed gardening. Skip and rebase tests.
kadam@inf.u-szeged.hu [Tue, 17 Sep 2013 15:38:53 +0000 (15:38 +0000)]
[Qt] Unreviewed gardening. Skip and rebase tests.

Patch by Gabor Abraham <abrhm@inf.u-szeged.hu> on 2013-09-17

* platform/qt-wk2/TestExpectations:
* platform/qt-wk2/compositing/geometry/negative-text-indent-with-overflow-hidden-layer-expected.txt: Added r155546.
* platform/qt-wk2/compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants-expected.txt: Added r155607.
* platform/qt-wk2/compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants2-expected.txt: Added r155607.
* platform/qt-wk2/fast/repaint/negative-text-indent-with-overflow-hidden-expected.txt: Added r155546.
* platform/qt-wk2/fast/replaced/border-radius-clip-expected.txt: Removed.
* platform/qt/TestExpectations:

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

8 years agoSet MessageEvent.source to the newly created port for shared workers' connect events
ch.dumez@sisa.samsung.com [Tue, 17 Sep 2013 15:25:34 +0000 (15:25 +0000)]
Set MessageEvent.source to the newly created port for shared workers' connect events
https://bugs.webkit.org/show_bug.cgi?id=121390

Reviewed by Darin Adler.

Source/WebCore:

Set MessageEvent.source to the newly created port for shared workers' connect events
instead of previously null, as per the latest specification:
http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#dom-messageevent-source
http://www.whatwg.org/specs/web-apps/current-work/multipage/workers.html#dom-sharedworker

This behavior is consisent with Blink.

Test: fast/workers/shared-worker-messageevent-source.html

* dom/EventTarget.cpp:
(WebCore::EventTarget::isMessagePort):
* dom/EventTarget.h:
* dom/MessageEvent.cpp:
(WebCore::isValidSource):
(WebCore::MessageEvent::MessageEvent):
* dom/MessageEvent.h:
Use null String instead of an empty String as default value for origin and lastEventId.
This is more efficient and has no impact on the behavior on the JavaScript since a
null String is exposed as an empty one on JS side.
This change is covered by fast/events/constructors/message-event-constructor.html
* dom/MessageEvent.idl:
* dom/MessagePort.h:
* page/DOMWindow.cpp:
(WebCore::PostMessageTimer::event):
* workers/SharedWorkerGlobalScope.cpp:
(WebCore::createConnectEvent):

LayoutTests:

Add layout test to check that MessageEvent.source is set to the newly created port
for shared workers' connect events.

* fast/events/constructors/message-event-constructor-expected.txt:
* fast/events/constructors/message-event-constructor.html:
* fast/workers/resources/messageevent-source.js: Added.
(onconnect):
* fast/workers/shared-worker-messageevent-source-expected.txt: Added.
* fast/workers/shared-worker-messageevent-source.html: Added.

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

8 years agoFix Windows CE build on ARM.
commit-queue@webkit.org [Tue, 17 Sep 2013 15:18:01 +0000 (15:18 +0000)]
Fix Windows CE build on ARM.
https://bugs.webkit.org/show_bug.cgi?id=121490

Patch by Sergio Martins <sergio.martins@kdab.com> on 2013-09-17
Reviewed by Darin Adler.

* wtf/dtoa/utils.h:

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

8 years agoRenderBR should not be RenderText
antti@apple.com [Tue, 17 Sep 2013 15:13:37 +0000 (15:13 +0000)]
RenderBR should not be RenderText
https://bugs.webkit.org/show_bug.cgi?id=121221

Reviewed by Darin Adler.

Source/WebCore:

Stop inheriting RenderBR from RenderText and make it be a RenderBoxModelObject instead. RenderBR was one
of the few cases where Element renderer was a RenderText. This will enable future cleanups.

RenderBR used little of RenderText mechanisms and was already heavily specialized everywhere. Layout code
didn't care about its text content at all. The new RenderText is also significatly more lightweight
than the old. As a line box it uses plain InlineBox instead of InlineTextBox.

The patch tries to avoid changing test results though there are a few changed render tree dumps without
visual effect. There are also two rendering progressions.

* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::textUnderElement):
(WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
* dom/ContainerNode.cpp:
(WebCore::ContainerNode::getUpperLeftCorner):
* dom/Document.cpp:
(WebCore::Document::updateHoverActiveState):
* dom/Position.cpp:
(WebCore::hasInlineBoxWrapper):
(WebCore::nextRenderedEditable):
(WebCore::previousRenderedEditable):
(WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
(WebCore::Position::getInlineBoxAndOffset):
* dom/Range.cpp:
(WebCore::Range::textRects):
(WebCore::Range::textQuads):
* editing/ApplyStyleCommand.cpp:
(WebCore::ApplyStyleCommand::applyInlineStyleToPushDown):
* editing/Editor.cpp:
(WebCore::findFirstMarkable):
* editing/TextIterator.cpp:
(WebCore::ignoresContainerClip):
* editing/VisibleUnits.cpp:
(WebCore::CachedLogicallyOrderedLeafBoxes::previousTextOrLineBreakBox):
(WebCore::CachedLogicallyOrderedLeafBoxes::nextTextOrLineBreakBox):
(WebCore::logicallyPreviousBox):
(WebCore::logicallyNextBox):
(WebCore::wordBreakIteratorForMinOffsetBoundary):
(WebCore::wordBreakIteratorForMaxOffsetBoundary):
* rendering/InlineBox.cpp:
(WebCore::InlineBox::logicalHeight):
(WebCore::InlineBox::baselinePosition):
(WebCore::InlineBox::lineHeight):
(WebCore::InlineBox::deleteLine):
(WebCore::InlineBox::extractLine):
(WebCore::InlineBox::attachLine):
(WebCore::InlineBox::paint):
* rendering/InlineBox.h:
(WebCore::InlineBox::isLineBreak):
* rendering/InlineFlowBox.cpp:
(WebCore::InlineFlowBox::computeOverflow):
* rendering/InlineIterator.h:
(WebCore::isIteratorTarget):
* rendering/InlineTextBox.cpp:
(WebCore::InlineTextBox::lineHeight):
(WebCore::InlineTextBox::isLineBreak):
* rendering/RenderBR.cpp:
(WebCore::RenderBR::RenderBR):
(WebCore::RenderBR::~RenderBR):
(WebCore::RenderBR::createAnonymous):
(WebCore::RenderBR::lineHeight):
(WebCore::RenderBR::baselinePosition):
(WebCore::RenderBR::createInlineBox):
(WebCore::RenderBR::setInlineBoxWrapper):
(WebCore::RenderBR::replaceInlineBoxWrapper):
(WebCore::RenderBR::deleteInlineBoxWrapper):
(WebCore::RenderBR::dirtyLineBoxes):
(WebCore::RenderBR::caretMinOffset):
(WebCore::RenderBR::caretMaxOffset):
(WebCore::RenderBR::canBeSelectionLeaf):
(WebCore::RenderBR::setSelectionState):
(WebCore::RenderBR::localCaretRect):
(WebCore::RenderBR::linesBoundingBox):
(WebCore::RenderBR::absoluteRects):
(WebCore::RenderBR::absoluteQuads):
(WebCore::RenderBR::updateFromStyle):
(WebCore::RenderBR::borderBoundingBox):
* rendering/RenderBR.h:
(WebCore::toRenderBR):
* rendering/RenderBlock.cpp:
(WebCore::InlineMinMaxIterator::next):
(WebCore::RenderBlock::updateFirstLetter):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::createInlineBoxForRenderer):
(WebCore::dirtyLineBoxesForRenderer):
(WebCore::reachedEndOfTextRenderer):
(WebCore::RenderBlock::computeBlockDirectionPositionsForLine):
(WebCore::RenderBlockFlow::layoutInlineChildren):
(WebCore::requiresLineBox):
(WebCore::shouldSkipWhitespaceAfterStartObject):
(WebCore::canBreakAtThisPosition):
* rendering/RenderInline.cpp:
(WebCore::RenderInline::generateCulledLineBoxRects):
(WebCore::RenderInline::culledInlineFirstLineBox):
(WebCore::RenderInline::culledInlineLastLineBox):
(WebCore::RenderInline::dirtyLineBoxes):
* rendering/RenderLineBoxList.cpp:
(WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
* rendering/RenderMenuList.cpp:
(WebCore::RenderMenuList::RenderMenuList):
(WebCore::RenderMenuList::styleDidChange):
(WebCore::RenderMenuList::setText):
(WebCore::RenderMenuList::text):
* rendering/RenderMenuList.h:
* rendering/RenderObject.h:
(WebCore::RenderObject::isBeforeContent):
(WebCore::RenderObject::isAfterContent):
* rendering/RenderObjectChildList.cpp:
(WebCore::RenderObjectChildList::removeChildNode):
* rendering/RenderText.cpp:
(WebCore::RenderText::removeAndDestroyTextBoxes):
(WebCore::RenderText::computePreferredLogicalWidths):
(WebCore::RenderText::setTextInternal):
* rendering/RenderTreeAsText.cpp:
(WebCore::RenderTreeAsText::writeRenderObject):
* rendering/RootInlineBox.cpp:
(WebCore::RootInlineBox::ascentAndDescentForBox):
(WebCore::RootInlineBox::verticalPositionForBox):

LayoutTests:

* editing/selection/move-by-word-visually-mac-expected.txt:

    This is a progression. A previously failing subtest passes.

* platform/mac/css3/selectors3/html/css3-modsel-179a-expected.txt:
* platform/mac/css3/selectors3/xhtml/css3-modsel-179a-expected.txt:
* platform/mac/css3/selectors3/xml/css3-modsel-179a-expected.txt:

    Changes in render tree dump that don't affect rendering.

* platform/mac/fast/css/pseudo-first-line-border-width-expected.txt:

    This is a progression. The new rendering matches Firefox.

* platform/mac/fast/css/word-space-extra-expected.txt:
* platform/mac/fast/text/whitespace/pre-wrap-spaces-after-newline-expected.txt:

    Changes in render tree dump that don't affect rendering.

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

8 years agoBuildfix for !(ENABLE(WEB_ARCHIVE) || ENABLE(MHTML)) platforms
ossy@webkit.org [Tue, 17 Sep 2013 15:10:01 +0000 (15:10 +0000)]
Buildfix for !(ENABLE(WEB_ARCHIVE) || ENABLE(MHTML)) platforms
https://bugs.webkit.org/show_bug.cgi?id=121491

Reviewed by Darin Adler.

* WebProcess/Network/WebResourceLoadScheduler.cpp:
(WebKit::WebResourceLoadScheduler::scheduleLoad):

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

8 years agoDodge more work during render tree teardown.
akling@apple.com [Tue, 17 Sep 2013 14:57:55 +0000 (14:57 +0000)]
Dodge more work during render tree teardown.
<https://webkit.org/b/121487>

Reviewed by Antti Koivisto.

Add a Document::hasLivingRenderTree() method that returns true if
there's a render tree attached to the document and it's not in the
process of being torn down.

Deploy this check in a number of places that were only checking
for the presence of a RenderView.

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

8 years agoMediaStream API: Adding an async RTCPeerConnection::addIceCandidate
eric.carlson@apple.com [Tue, 17 Sep 2013 14:52:37 +0000 (14:52 +0000)]
MediaStream API: Adding an async RTCPeerConnection::addIceCandidate
https://bugs.webkit.org/show_bug.cgi?id=121403

Source/WebCore:

Merged from https://chromium.googlesource.com/chromium/blink/+/5bd81fda88d48dd2780832246e7d1ab973ee7a1d

Reviewed by Darin Adler.

No new tests, updated RTCPeerConnection-ice.html.

* Modules/mediastream/RTCPeerConnection.cpp:
(WebCore::RTCPeerConnection::addIceCandidate): Add success and error callbacks.
* Modules/mediastream/RTCPeerConnection.h:
* Modules/mediastream/RTCPeerConnection.idl:

* platform/mediastream/RTCPeerConnectionHandler.h: Changed addIceCandidate signature.

* platform/mediastream/RTCVoidRequest.h: Removed ExtraData, it is unnecessary.

LayoutTests:

Reviewed by Darin Adler.

* fast/mediastream/RTCPeerConnection-ice-expected.txt:
* fast/mediastream/RTCPeerConnection-ice.html:

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

8 years ago[GTK] Unreviewed make distcheck fix.
berto@igalia.com [Tue, 17 Sep 2013 13:44:54 +0000 (13:44 +0000)]
[GTK] Unreviewed make distcheck fix.

* GNUmakefile.am: include WebProcess/Network/*.in in the tarball,
it's needed for generating WebResourceLoaderMessage*.{cpp,h}.

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

8 years ago[GTK] Do not include Returns tag in api doc for methods returning void
carlosgc@webkit.org [Tue, 17 Sep 2013 13:38:10 +0000 (13:38 +0000)]
[GTK] Do not include Returns tag in api doc for methods returning void
https://bugs.webkit.org/show_bug.cgi?id=121488

Reviewed by Philippe Normand.

* bindings/gobject/WebKitDOMCustom.h:
* bindings/scripts/CodeGeneratorGObject.pm:
(GenerateFunction): Only add Returns tag for methods not returning
void.
* bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
* bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
* bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
* bindings/scripts/test/GObject/WebKitDOMTestObj.h:
* bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:

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

8 years agoCorrect range used for Emoji checks.
michael.bruning@digia.com [Tue, 17 Sep 2013 13:24:28 +0000 (13:24 +0000)]
Correct range used for Emoji checks.
https://bugs.webkit.org/show_bug.cgi?id=121486

Reviewed by Allan Sandfeld Jensen.

Found and reported by David Binderman via Qt bug tracker.

The check if a character was in the Emoji range always evaluated to
false due to the upper range limit being lower than the lower limit.

Changed the upper limit to the highest assigned character from the
"Transport and Map Symbols" (0x1F6C5) as that seems to have been the
intended upper range limit of this check.

* platform/graphics/Font.cpp:
(WebCore::Font::isCJKIdeographOrSymbol):

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

8 years agoREGRESSION(r155910): WebKit nightly builds don't load any page
mihnea@adobe.com [Tue, 17 Sep 2013 12:40:37 +0000 (12:40 +0000)]
REGRESSION(r155910): WebKit nightly builds don't load any page
https://bugs.webkit.org/show_bug.cgi?id=121482

Reviewed by Andreas Kling.

Replaced C++ style comments with C style comments.

* wtf/Platform.h:

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

8 years agoMove text caret rect computation to root inline box
antti@apple.com [Tue, 17 Sep 2013 12:33:29 +0000 (12:33 +0000)]
Move text caret rect computation to root inline box
https://bugs.webkit.org/show_bug.cgi?id=121479

Reviewed by Andreas Kling.

For future code sharing.

* rendering/RenderText.cpp:
(WebCore::RenderText::localCaretRect):
* rendering/RootInlineBox.cpp:
(WebCore::RootInlineBox::computeCaretRect):
* rendering/RootInlineBox.h:

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

8 years ago[GTK] Don't make the GObject DOM bindings API break test fatal
berto@igalia.com [Tue, 17 Sep 2013 12:17:01 +0000 (12:17 +0000)]
[GTK] Don't make the GObject DOM bindings API break test fatal
https://bugs.webkit.org/show_bug.cgi?id=121484

Reviewed by Carlos Garcia Campos.

The API varies depending on the compilation options, so this can
easily produce false positives.

Until we figure out a way to handle this situation we shouldn't
make this test fatal.

* bindings/scripts/gobject-run-api-break-test:
(check_api):

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

8 years ago[CSSRegions] Flowed fixed element without its transformed parent positioned relative...
mihnea@adobe.com [Tue, 17 Sep 2013 12:05:51 +0000 (12:05 +0000)]
[CSSRegions] Flowed fixed element without its transformed parent positioned relative to viewport
https://bugs.webkit.org/show_bug.cgi?id=121478

Reviewed by Antti Koivisto.

A fixed positioned element collected into a named flow without its transformed parent should be positioned relative to the viewport instead of the transformed parent. Add a test for this behavior.

* fast/regions/flow-fixed-element-transformed-parent-expected.txt: Added.
* fast/regions/flow-fixed-element-transformed-parent.html: Added.

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

8 years ago[CSSRegions] Replace generatingNode() with generatingElement() for RenderRegion
mihnea@adobe.com [Tue, 17 Sep 2013 12:02:09 +0000 (12:02 +0000)]
[CSSRegions] Replace generatingNode() with generatingElement() for RenderRegion
https://bugs.webkit.org/show_bug.cgi?id=121469

Reviewed by Antti Koivisto.

The fix for https://bugs.webkit.org/show_bug.cgi?id=120397 replaced node() with generatingElement() for regions, but i forgot about replacing generatingNode() with generatingElement() in RenderNamedFlowThread::compareRenderRegions. This is needed in preparation for regions as anonymous blocks refactoring in https://bugs.webkit.org/show_bug.cgi?id=119135.

No new functionality introduced, therefore no new tests.

* rendering/RenderNamedFlowThread.cpp:
(WebCore::compareRenderRegions):

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

8 years agoBrowserMarshal.h build fail
berto@igalia.com [Tue, 17 Sep 2013 11:58:02 +0000 (11:58 +0000)]
BrowserMarshal.h build fail
https://bugs.webkit.org/show_bug.cgi?id=102938

Patch by YuTeh Shen <shenyute@hotmail.com> on 2013-09-17
Reviewed by Carlos Garcia Campos.

Fix variable name.

* MiniBrowser/gtk/GNUmakefile.am:

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

8 years agoCTTE: Pass RenderArena around by reference.
akling@apple.com [Tue, 17 Sep 2013 11:05:01 +0000 (11:05 +0000)]
CTTE: Pass RenderArena around by reference.
<https://webkit.org/b/121470>

Reviewed by Antti Koivisto.

Pass the RenderArena around by reference in all render tree code.
This code will never be running without an arena.

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

8 years ago[GTK] GObject DOM symbols file is not generated for video related classes
carlosgc@webkit.org [Tue, 17 Sep 2013 10:24:35 +0000 (10:24 +0000)]
[GTK] GObject DOM symbols file is not generated for video related classes
https://bugs.webkit.org/show_bug.cgi?id=121476

Reviewed by Philippe Normand.

The problem is that we are using a different path for video
related header files in the Makefile, it's the same path in
practice, because we are just prepending ./ to the path, but the
rules that parse those paths don't expect the ./ at the beginning.

* bindings/gobject/GNUmakefile.am: Use the same path for video
related header files as the other paths in
webkitgtk_gdom_built_h_api.
* bindings/gobject/webkitdom.symbols: Updated to include the
symbols of the video related clases.

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

8 years ago[GTK][EFL] Add ResourceError::internalError() after r138387
ossy@webkit.org [Tue, 17 Sep 2013 09:47:41 +0000 (09:47 +0000)]
[GTK][EFL] Add ResourceError::internalError() after r138387
https://bugs.webkit.org/show_bug.cgi?id=121433

Reviewed by Christophe Dumez.

Original patch by Balazs Kelemen <kbalazs@webkit.org>
and Kwang Yul Seo <skyul@company100.net>

* WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
(WebKit::internalError):
* WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
(WebKit::internalError):

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

8 years agoUnreviewed make distcheck fix.
berto@igalia.com [Tue, 17 Sep 2013 09:44:12 +0000 (09:44 +0000)]
Unreviewed make distcheck fix.

* GNUmakefile.list.am:

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

8 years ago[Qt] Unreviewed gardening. Skip failing tests.
kadam@inf.u-szeged.hu [Tue, 17 Sep 2013 09:38:06 +0000 (09:38 +0000)]
[Qt] Unreviewed gardening. Skip failing tests.

* platform/qt-wk1/TestExpectations:

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

8 years agoSome build juice for Windows.
akling@apple.com [Tue, 17 Sep 2013 09:32:47 +0000 (09:32 +0000)]
Some build juice for Windows.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:

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

8 years agoRemove ContextFeatures.
akling@apple.com [Tue, 17 Sep 2013 09:27:21 +0000 (09:27 +0000)]
Remove ContextFeatures.
<https://webkit.org/b/121473>

Reviewed by Antti Koivisto.

This was only used by the chromium port, nobody implements ContextFeaturesClient.

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