2011-01-29 Geoffrey Garen <ggaren@apple.com>
[WebKit.git] / Source / JavaScriptCore / ChangeLog
1 2011-01-29  Geoffrey Garen  <ggaren@apple.com>
2
3         Reviewed by Maciej Stachowiak.
4
5         Switched heap to use the Bitmap class and removed CollectorBitmap
6         https://bugs.webkit.org/show_bug.cgi?id=53391
7         
8         SunSpider says 1.005x as fast. Seems like a fluke.
9
10         * runtime/MarkedSpace.cpp:
11         (JSC::MarkedSpace::allocate): Updated for rename and returning a value
12         rather than taking a value by reference.
13
14         * runtime/MarkedSpace.h: Code reuse is good.
15
16         * wtf/Bitmap.h:
17         (WTF::::testAndSet): Added, since this is the one thing Bitmap was missing
18         which CollectorBitmap had. (Renamed from the less conventional "getset".)
19
20         (WTF::::nextPossiblyUnset): Renamed and changed to return a value for
21         clarity. It's all the same with inlining.
22
23 2011-01-28  Geoffrey Garen  <ggaren@apple.com>
24
25         Reviewed by Maciej Stachowiak.
26
27         Some more Heap cleanup.
28         https://bugs.webkit.org/show_bug.cgi?id=53357
29         
30         * JavaScriptCore.exp:
31         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def: Updated exported symbols.
32
33         * runtime/Heap.cpp:
34         (JSC::Heap::reportExtraMemoryCostSlowCase): Renamed recordExtraCost to 
35         reportExtraMemoryCostSlowCase to match our naming conventions.
36
37         (JSC::Heap::capacity): Renamed size to capacity because this function
38         returns the capacity of the heap, including unused portions.
39
40         * runtime/Heap.h:
41         (JSC::Heap::globalData):
42         (JSC::Heap::markedSpace):
43         (JSC::Heap::machineStackMarker):
44         (JSC::Heap::reportExtraMemoryCost): Moved statics to the top of the file.
45         Moved ctor and dtor to the beginning of the class definition. Grouped
46         functions by purpose.
47
48         * runtime/MarkedSpace.cpp:
49         (JSC::MarkedSpace::capacity): Renamed size to capacity because this
50         function returns the capacity of the heap, including unused portions.
51
52         * runtime/MarkedSpace.h: Removed statistics and the Statistics class because
53         the same information can be gotten just by calling size() and capacity().
54
55         * runtime/MemoryStatistics.cpp:
56         * runtime/MemoryStatistics.h: Ditto.
57
58 2011-01-29  Daniel Bates  <dbates@rim.com>
59
60         Reviewed by Eric Seidel.
61
62         Move wince/mt19937ar.c to ThirdParty and make it a policy choice
63         https://bugs.webkit.org/show_bug.cgi?id=53253
64
65         Make inclusion of MT19937 a policy decision.
66
67         Currently, we hardcoded to  use MT19937 when building for
68         Windows CE. Instead, we should make this a policy decision
69         with the Windows CE port using this by default.
70
71         * JavaScriptCore.pri: Append Source/ThirdParty to the end
72         of the list include directories.
73         * wtf/CMakeLists.txt: Ditto.
74         * wtf/Platform.h: Defined WTF_USE_MERSENNE_TWISTER_19937 when
75         building for Windows CE.
76         * wtf/RandomNumber.cpp:
77         (WTF::randomNumber): Substituted USE(MERSENNE_TWISTER_19937) for OS(WINCE).
78
79 2011-01-29  Cameron Zwarich  <zwarich@apple.com>
80
81         Reviewed by David Kilzer.
82
83         Bug 53374 - Remove uses of unsafe string functions in debugging code
84         https://bugs.webkit.org/show_bug.cgi?id=53374
85
86         * runtime/RegExp.cpp:
87         (JSC::RegExp::printTraceData):
88
89 2011-01-29  Cameron Zwarich  <zwarich@apple.com>
90
91         Reviewed by Oliver Hunt.
92
93         JavaScriptCoreUseJIT environment variable broken
94         https://bugs.webkit.org/show_bug.cgi?id=53372
95
96         * runtime/JSGlobalData.cpp:
97         (JSC::JSGlobalData::JSGlobalData): Check the actual value in the string returned
98         by getenv() rather than just doing a NULL check on the return value.
99
100 2011-01-29  Patrick Gansterer  <paroga@webkit.org>
101
102         Reviewed by David Kilzer.
103
104         Move CharacterNames.h into WTF directory
105         https://bugs.webkit.org/show_bug.cgi?id=49618
106
107         * GNUmakefile.am:
108         * JavaScriptCore.gypi:
109         * JavaScriptCore.vcproj/WTF/WTF.vcproj:
110         * JavaScriptCore.xcodeproj/project.pbxproj:
111         * wtf/CMakeLists.txt:
112         * wtf/unicode/CharacterNames.h: Renamed from WebCore/platform/text/CharacterNames.h.
113         * wtf/unicode/UTF8.cpp:
114
115 2011-01-28  Simon Fraser  <simon.fraser@apple.com>
116
117         Reviewed by Gavin Barraclough.
118
119         Add various clampToInt() methods to MathExtras.h
120         https://bugs.webkit.org/show_bug.cgi?id=52910
121         
122         Add functions for clamping doubles and floats to valid int
123         ranges, for signed and positive integers.
124
125         * wtf/MathExtras.h:
126         (clampToInteger):
127         (clampToPositiveInteger):
128
129 2011-01-28  Sheriff Bot  <webkit.review.bot@gmail.com>
130
131         Unreviewed, rolling out r77006 and r77020.
132         http://trac.webkit.org/changeset/77006
133         http://trac.webkit.org/changeset/77020
134         https://bugs.webkit.org/show_bug.cgi?id=53360
135
136         "Broke Windows tests" (Requested by rniwa on #webkit).
137
138         * API/JSCallbackObject.h:
139         (JSC::JSCallbackObjectData::setPrivateProperty):
140         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::getPrivateProperty):
141         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::setPrivateProperty):
142         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::markChildren):
143         (JSC::JSCallbackObject::setPrivateProperty):
144         * API/JSCallbackObjectFunctions.h:
145         (JSC::::put):
146         (JSC::::staticFunctionGetter):
147         * API/JSObjectRef.cpp:
148         (JSObjectMakeConstructor):
149         (JSObjectSetPrivateProperty):
150         * API/JSWeakObjectMapRefInternal.h:
151         * JavaScriptCore.exp:
152         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
153         * JavaScriptCore.xcodeproj/project.pbxproj:
154         * bytecode/CodeBlock.cpp:
155         (JSC::CodeBlock::markAggregate):
156         * bytecode/CodeBlock.h:
157         (JSC::CodeBlock::globalObject):
158         * bytecompiler/BytecodeGenerator.cpp:
159         (JSC::BytecodeGenerator::BytecodeGenerator):
160         (JSC::BytecodeGenerator::emitJumpIfNotFunctionCall):
161         (JSC::BytecodeGenerator::emitJumpIfNotFunctionApply):
162         (JSC::BytecodeGenerator::findScopedProperty):
163         * debugger/Debugger.cpp:
164         (JSC::evaluateInGlobalCallFrame):
165         * debugger/DebuggerActivation.cpp:
166         (JSC::DebuggerActivation::DebuggerActivation):
167         (JSC::DebuggerActivation::markChildren):
168         * debugger/DebuggerActivation.h:
169         * debugger/DebuggerCallFrame.cpp:
170         (JSC::DebuggerCallFrame::evaluate):
171         * interpreter/CallFrame.h:
172         (JSC::ExecState::exception):
173         * interpreter/Interpreter.cpp:
174         (JSC::Interpreter::resolve):
175         (JSC::Interpreter::resolveSkip):
176         (JSC::Interpreter::resolveGlobal):
177         (JSC::Interpreter::resolveGlobalDynamic):
178         (JSC::Interpreter::resolveBaseAndProperty):
179         (JSC::Interpreter::unwindCallFrame):
180         (JSC::appendSourceToError):
181         (JSC::Interpreter::execute):
182         (JSC::Interpreter::tryCacheGetByID):
183         (JSC::Interpreter::privateExecute):
184         * jit/JITStubs.cpp:
185         (JSC::JITThunks::tryCacheGetByID):
186         (JSC::DEFINE_STUB_FUNCTION):
187         * jsc.cpp:
188         (GlobalObject::GlobalObject):
189         * runtime/ArgList.cpp:
190         (JSC::MarkedArgumentBuffer::markLists):
191         * runtime/Arguments.cpp:
192         (JSC::Arguments::markChildren):
193         (JSC::Arguments::getOwnPropertySlot):
194         (JSC::Arguments::getOwnPropertyDescriptor):
195         (JSC::Arguments::put):
196         * runtime/Arguments.h:
197         (JSC::Arguments::setActivation):
198         (JSC::Arguments::Arguments):
199         * runtime/ArrayConstructor.cpp:
200         (JSC::ArrayConstructor::ArrayConstructor):
201         (JSC::constructArrayWithSizeQuirk):
202         * runtime/ArrayPrototype.cpp:
203         (JSC::arrayProtoFuncSplice):
204         * runtime/BatchedTransitionOptimizer.h:
205         (JSC::BatchedTransitionOptimizer::BatchedTransitionOptimizer):
206         (JSC::BatchedTransitionOptimizer::~BatchedTransitionOptimizer):
207         * runtime/BooleanConstructor.cpp:
208         (JSC::BooleanConstructor::BooleanConstructor):
209         (JSC::constructBoolean):
210         (JSC::constructBooleanFromImmediateBoolean):
211         * runtime/BooleanPrototype.cpp:
212         (JSC::BooleanPrototype::BooleanPrototype):
213         * runtime/ConservativeSet.cpp:
214         (JSC::ConservativeSet::grow):
215         * runtime/ConservativeSet.h:
216         (JSC::ConservativeSet::~ConservativeSet):
217         (JSC::ConservativeSet::mark):
218         * runtime/DateConstructor.cpp:
219         (JSC::DateConstructor::DateConstructor):
220         * runtime/DateInstance.cpp:
221         (JSC::DateInstance::DateInstance):
222         * runtime/DatePrototype.cpp:
223         (JSC::dateProtoFuncSetTime):
224         (JSC::setNewValueFromTimeArgs):
225         (JSC::setNewValueFromDateArgs):
226         (JSC::dateProtoFuncSetYear):
227         * runtime/ErrorConstructor.cpp:
228         (JSC::ErrorConstructor::ErrorConstructor):
229         * runtime/ErrorInstance.cpp:
230         (JSC::ErrorInstance::ErrorInstance):
231         * runtime/ErrorPrototype.cpp:
232         (JSC::ErrorPrototype::ErrorPrototype):
233         * runtime/FunctionConstructor.cpp:
234         (JSC::FunctionConstructor::FunctionConstructor):
235         * runtime/FunctionPrototype.cpp:
236         (JSC::FunctionPrototype::FunctionPrototype):
237         * runtime/GetterSetter.cpp:
238         (JSC::GetterSetter::markChildren):
239         * runtime/GetterSetter.h:
240         (JSC::GetterSetter::GetterSetter):
241         (JSC::GetterSetter::getter):
242         (JSC::GetterSetter::setGetter):
243         (JSC::GetterSetter::setter):
244         (JSC::GetterSetter::setSetter):
245         * runtime/GlobalEvalFunction.cpp:
246         (JSC::GlobalEvalFunction::GlobalEvalFunction):
247         (JSC::GlobalEvalFunction::markChildren):
248         * runtime/GlobalEvalFunction.h:
249         (JSC::GlobalEvalFunction::cachedGlobalObject):
250         * runtime/Heap.cpp:
251         (JSC::Heap::markProtectedObjects):
252         (JSC::Heap::markTempSortVectors):
253         (JSC::Heap::markRoots):
254         * runtime/InternalFunction.cpp:
255         (JSC::InternalFunction::InternalFunction):
256         * runtime/JSAPIValueWrapper.h:
257         (JSC::JSAPIValueWrapper::value):
258         (JSC::JSAPIValueWrapper::JSAPIValueWrapper):
259         * runtime/JSActivation.cpp:
260         (JSC::JSActivation::markChildren):
261         (JSC::JSActivation::put):
262         * runtime/JSArray.cpp:
263         (JSC::JSArray::JSArray):
264         (JSC::JSArray::getOwnPropertySlot):
265         (JSC::JSArray::getOwnPropertyDescriptor):
266         (JSC::JSArray::put):
267         (JSC::JSArray::putSlowCase):
268         (JSC::JSArray::deleteProperty):
269         (JSC::JSArray::increaseVectorLength):
270         (JSC::JSArray::setLength):
271         (JSC::JSArray::pop):
272         (JSC::JSArray::push):
273         (JSC::JSArray::unshiftCount):
274         (JSC::JSArray::sort):
275         (JSC::JSArray::fillArgList):
276         (JSC::JSArray::copyToRegisters):
277         (JSC::JSArray::compactForSorting):
278         * runtime/JSArray.h:
279         (JSC::JSArray::getIndex):
280         (JSC::JSArray::setIndex):
281         (JSC::JSArray::uncheckedSetIndex):
282         (JSC::JSArray::markChildrenDirect):
283         * runtime/JSByteArray.cpp:
284         (JSC::JSByteArray::JSByteArray):
285         * runtime/JSCell.h:
286         (JSC::JSCell::JSValue::toThisObject):
287         (JSC::JSCell::MarkStack::append):
288         * runtime/JSFunction.cpp:
289         (JSC::JSFunction::JSFunction):
290         (JSC::JSFunction::getOwnPropertySlot):
291         * runtime/JSGlobalData.h:
292         * runtime/JSGlobalObject.cpp:
293         (JSC::markIfNeeded):
294         (JSC::JSGlobalObject::reset):
295         (JSC::JSGlobalObject::resetPrototype):
296         (JSC::JSGlobalObject::markChildren):
297         * runtime/JSGlobalObject.h:
298         (JSC::JSGlobalObject::JSGlobalObjectData::JSGlobalObjectData):
299         (JSC::JSGlobalObject::regExpConstructor):
300         (JSC::JSGlobalObject::errorConstructor):
301         (JSC::JSGlobalObject::evalErrorConstructor):
302         (JSC::JSGlobalObject::rangeErrorConstructor):
303         (JSC::JSGlobalObject::referenceErrorConstructor):
304         (JSC::JSGlobalObject::syntaxErrorConstructor):
305         (JSC::JSGlobalObject::typeErrorConstructor):
306         (JSC::JSGlobalObject::URIErrorConstructor):
307         (JSC::JSGlobalObject::evalFunction):
308         (JSC::JSGlobalObject::objectPrototype):
309         (JSC::JSGlobalObject::functionPrototype):
310         (JSC::JSGlobalObject::arrayPrototype):
311         (JSC::JSGlobalObject::booleanPrototype):
312         (JSC::JSGlobalObject::stringPrototype):
313         (JSC::JSGlobalObject::numberPrototype):
314         (JSC::JSGlobalObject::datePrototype):
315         (JSC::JSGlobalObject::regExpPrototype):
316         (JSC::JSGlobalObject::methodCallDummy):
317         (JSC::Structure::prototypeForLookup):
318         (JSC::constructArray):
319         * runtime/JSONObject.cpp:
320         (JSC::Stringifier::Holder::object):
321         (JSC::Stringifier::markAggregate):
322         (JSC::Stringifier::stringify):
323         (JSC::Stringifier::Holder::appendNextProperty):
324         (JSC::Walker::callReviver):
325         (JSC::Walker::walk):
326         * runtime/JSObject.cpp:
327         (JSC::JSObject::defineGetter):
328         (JSC::JSObject::defineSetter):
329         (JSC::JSObject::removeDirect):
330         (JSC::JSObject::putDirectFunction):
331         (JSC::JSObject::putDirectFunctionWithoutTransition):
332         (JSC::putDescriptor):
333         (JSC::JSObject::defineOwnProperty):
334         * runtime/JSObject.h:
335         (JSC::JSObject::getDirectOffset):
336         (JSC::JSObject::putDirectOffset):
337         (JSC::JSObject::flattenDictionaryObject):
338         (JSC::JSObject::putDirectInternal):
339         (JSC::JSObject::putDirect):
340         (JSC::JSObject::putDirectFunction):
341         (JSC::JSObject::putDirectWithoutTransition):
342         (JSC::JSObject::putDirectFunctionWithoutTransition):
343         (JSC::JSValue::putDirect):
344         (JSC::JSObject::allocatePropertyStorageInline):
345         (JSC::JSObject::markChildrenDirect):
346         * runtime/JSPropertyNameIterator.cpp:
347         (JSC::JSPropertyNameIterator::JSPropertyNameIterator):
348         (JSC::JSPropertyNameIterator::get):
349         * runtime/JSPropertyNameIterator.h:
350         * runtime/JSStaticScopeObject.cpp:
351         (JSC::JSStaticScopeObject::markChildren):
352         * runtime/JSString.cpp:
353         (JSC::StringObject::create):
354         * runtime/JSValue.h:
355         * runtime/JSWrapperObject.cpp:
356         (JSC::JSWrapperObject::markChildren):
357         * runtime/JSWrapperObject.h:
358         (JSC::JSWrapperObject::internalValue):
359         (JSC::JSWrapperObject::setInternalValue):
360         * runtime/LiteralParser.cpp:
361         (JSC::LiteralParser::parse):
362         * runtime/Lookup.cpp:
363         (JSC::setUpStaticFunctionSlot):
364         * runtime/Lookup.h:
365         (JSC::lookupPut):
366         * runtime/MarkStack.h:
367         (JSC::MarkStack::appendValues):
368         * runtime/MathObject.cpp:
369         (JSC::MathObject::MathObject):
370         * runtime/NativeErrorConstructor.cpp:
371         (JSC::NativeErrorConstructor::NativeErrorConstructor):
372         * runtime/NativeErrorPrototype.cpp:
373         (JSC::NativeErrorPrototype::NativeErrorPrototype):
374         * runtime/NumberConstructor.cpp:
375         (JSC::NumberConstructor::NumberConstructor):
376         (JSC::constructWithNumberConstructor):
377         * runtime/NumberObject.cpp:
378         (JSC::constructNumber):
379         * runtime/NumberPrototype.cpp:
380         (JSC::NumberPrototype::NumberPrototype):
381         * runtime/ObjectConstructor.cpp:
382         (JSC::ObjectConstructor::ObjectConstructor):
383         (JSC::objectConstructorGetOwnPropertyDescriptor):
384         * runtime/Operations.h:
385         (JSC::normalizePrototypeChain):
386         (JSC::resolveBase):
387         * runtime/PrototypeFunction.cpp:
388         (JSC::PrototypeFunction::PrototypeFunction):
389         * runtime/PutPropertySlot.h:
390         (JSC::PutPropertySlot::setExistingProperty):
391         (JSC::PutPropertySlot::setNewProperty):
392         (JSC::PutPropertySlot::base):
393         * runtime/RegExpConstructor.cpp:
394         (JSC::RegExpConstructor::RegExpConstructor):
395         * runtime/ScopeChain.cpp:
396         (JSC::ScopeChainNode::print):
397         * runtime/ScopeChain.h:
398         (JSC::ScopeChainNode::~ScopeChainNode):
399         (JSC::ScopeChainIterator::operator*):
400         (JSC::ScopeChainIterator::operator->):
401         (JSC::ScopeChain::top):
402         * runtime/ScopeChainMark.h:
403         (JSC::ScopeChain::markAggregate):
404         * runtime/SmallStrings.cpp:
405         (JSC::isMarked):
406         (JSC::SmallStrings::markChildren):
407         * runtime/SmallStrings.h:
408         (JSC::SmallStrings::emptyString):
409         (JSC::SmallStrings::singleCharacterString):
410         (JSC::SmallStrings::singleCharacterStrings):
411         * runtime/StringConstructor.cpp:
412         (JSC::StringConstructor::StringConstructor):
413         * runtime/StringObject.cpp:
414         (JSC::StringObject::StringObject):
415         * runtime/StringObject.h:
416         * runtime/StringPrototype.cpp:
417         (JSC::StringPrototype::StringPrototype):
418         * runtime/Structure.cpp:
419         (JSC::Structure::Structure):
420         (JSC::Structure::addPropertyTransition):
421         (JSC::Structure::toDictionaryTransition):
422         (JSC::Structure::flattenDictionaryStructure):
423         * runtime/Structure.h:
424         (JSC::Structure::storedPrototype):
425         * runtime/WeakGCMap.h:
426         (JSC::WeakGCMap::uncheckedGet):
427         (JSC::WeakGCMap::isValid):
428         (JSC::::get):
429         (JSC::::take):
430         (JSC::::set):
431         (JSC::::uncheckedRemove):
432         * runtime/WriteBarrier.h: Removed.
433
434 2011-01-28  Gavin Barraclough  <barraclough@apple.com>
435
436         Reviewed by Geoff Garen.
437
438         https://bugs.webkit.org/show_bug.cgi?id=53352
439         Heavy external fragmentation in FixedVMPoolAllocator can lead to a CRASH().
440
441         The FixedVMPoolAllocator currently uses a best fix policy -
442         switch to first fit, this is less prone to external fragmentation.
443
444         * jit/ExecutableAllocatorFixedVMPool.cpp:
445         (JSC::AllocationTableSizeClass::AllocationTableSizeClass):
446         (JSC::AllocationTableSizeClass::blockSize):
447         (JSC::AllocationTableSizeClass::blockCount):
448         (JSC::AllocationTableSizeClass::blockAlignment):
449         (JSC::AllocationTableSizeClass::size):
450         (JSC::AllocationTableLeaf::AllocationTableLeaf):
451         (JSC::AllocationTableLeaf::~AllocationTableLeaf):
452         (JSC::AllocationTableLeaf::allocate):
453         (JSC::AllocationTableLeaf::free):
454         (JSC::AllocationTableLeaf::isEmpty):
455         (JSC::AllocationTableLeaf::isFull):
456         (JSC::AllocationTableLeaf::size):
457         (JSC::AllocationTableLeaf::classForSize):
458         (JSC::AllocationTableLeaf::dump):
459         (JSC::LazyAllocationTable::LazyAllocationTable):
460         (JSC::LazyAllocationTable::~LazyAllocationTable):
461         (JSC::LazyAllocationTable::allocate):
462         (JSC::LazyAllocationTable::free):
463         (JSC::LazyAllocationTable::isEmpty):
464         (JSC::LazyAllocationTable::isFull):
465         (JSC::LazyAllocationTable::size):
466         (JSC::LazyAllocationTable::dump):
467         (JSC::LazyAllocationTable::classForSize):
468         (JSC::AllocationTableDirectory::AllocationTableDirectory):
469         (JSC::AllocationTableDirectory::~AllocationTableDirectory):
470         (JSC::AllocationTableDirectory::allocate):
471         (JSC::AllocationTableDirectory::free):
472         (JSC::AllocationTableDirectory::isEmpty):
473         (JSC::AllocationTableDirectory::isFull):
474         (JSC::AllocationTableDirectory::size):
475         (JSC::AllocationTableDirectory::classForSize):
476         (JSC::AllocationTableDirectory::dump):
477         (JSC::FixedVMPoolAllocator::FixedVMPoolAllocator):
478         (JSC::FixedVMPoolAllocator::alloc):
479         (JSC::FixedVMPoolAllocator::free):
480         (JSC::FixedVMPoolAllocator::allocated):
481         (JSC::FixedVMPoolAllocator::isValid):
482         (JSC::FixedVMPoolAllocator::classForSize):
483         (JSC::FixedVMPoolAllocator::offsetToPointer):
484         (JSC::FixedVMPoolAllocator::pointerToOffset):
485         (JSC::ExecutableAllocator::committedByteCount):
486         (JSC::ExecutableAllocator::isValid):
487         (JSC::ExecutableAllocator::underMemoryPressure):
488         (JSC::ExecutablePool::systemAlloc):
489         (JSC::ExecutablePool::systemRelease):
490         * wtf/PageReservation.h:
491         (WTF::PageReservation::PageReservation):
492         (WTF::PageReservation::commit):
493         (WTF::PageReservation::decommit):
494         (WTF::PageReservation::committed):
495
496 2011-01-27  Oliver Hunt  <oliver@apple.com>
497
498         Reviewed by Geoffrey Garen.
499
500         Convert markstack to a slot visitor API
501         https://bugs.webkit.org/show_bug.cgi?id=53219
502
503         Move the MarkStack over to a slot based marking API.
504
505         In order to avoiding aliasing concerns there are two new types
506         that need to be used when holding on to JSValues and JSCell that
507         need to be marked: WriteBarrier and DeprecatedPtr.  WriteBarrier
508         is expected to be used for any JSValue or Cell that's lifetime and
509         marking is controlled by another GC object.  DeprecatedPtr is used
510         for any value that we need to rework ownership for.
511
512         The change over to this model has produced a large amount of
513         code changes, but they are mostly mechanical (forwarding JSGlobalData,
514         etc).
515
516         * API/JSCallbackObject.h:
517         (JSC::JSCallbackObjectData::setPrivateProperty):
518         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::getPrivateProperty):
519         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::setPrivateProperty):
520         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::markChildren):
521         (JSC::JSCallbackObject::setPrivateProperty):
522         * API/JSCallbackObjectFunctions.h:
523         (JSC::::put):
524         (JSC::::staticFunctionGetter):
525         * API/JSObjectRef.cpp:
526         (JSObjectMakeConstructor):
527         (JSObjectSetPrivateProperty):
528         * API/JSWeakObjectMapRefInternal.h:
529         * JavaScriptCore.exp:
530         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
531         * JavaScriptCore.xcodeproj/project.pbxproj:
532         * bytecode/CodeBlock.cpp:
533         (JSC::CodeBlock::markAggregate):
534         * bytecode/CodeBlock.h:
535         (JSC::CodeBlock::globalObject):
536         * bytecompiler/BytecodeGenerator.cpp:
537         (JSC::BytecodeGenerator::BytecodeGenerator):
538         (JSC::BytecodeGenerator::emitJumpIfNotFunctionCall):
539         (JSC::BytecodeGenerator::emitJumpIfNotFunctionApply):
540         (JSC::BytecodeGenerator::findScopedProperty):
541         * debugger/DebuggerActivation.cpp:
542         (JSC::DebuggerActivation::DebuggerActivation):
543         (JSC::DebuggerActivation::markChildren):
544         * debugger/DebuggerActivation.h:
545         * interpreter/Interpreter.cpp:
546         (JSC::Interpreter::resolve):
547         (JSC::Interpreter::resolveSkip):
548         (JSC::Interpreter::resolveGlobalDynamic):
549         (JSC::Interpreter::resolveBaseAndProperty):
550         (JSC::Interpreter::unwindCallFrame):
551         (JSC::appendSourceToError):
552         (JSC::Interpreter::execute):
553         (JSC::Interpreter::privateExecute):
554         * interpreter/Register.h:
555         (JSC::Register::jsValueSlot):
556         * jit/JITStubs.cpp:
557         (JSC::JITThunks::tryCacheGetByID):
558         (JSC::DEFINE_STUB_FUNCTION):
559         * jsc.cpp:
560         (GlobalObject::GlobalObject):
561         * runtime/Arguments.cpp:
562         (JSC::Arguments::markChildren):
563         (JSC::Arguments::getOwnPropertySlot):
564         (JSC::Arguments::getOwnPropertyDescriptor):
565         (JSC::Arguments::put):
566         * runtime/Arguments.h:
567         (JSC::Arguments::setActivation):
568         (JSC::Arguments::Arguments):
569         * runtime/ArrayConstructor.cpp:
570         (JSC::ArrayConstructor::ArrayConstructor):
571         (JSC::constructArrayWithSizeQuirk):
572         * runtime/ArrayPrototype.cpp:
573         (JSC::arrayProtoFuncSplice):
574         * runtime/BatchedTransitionOptimizer.h:
575         (JSC::BatchedTransitionOptimizer::BatchedTransitionOptimizer):
576         (JSC::BatchedTransitionOptimizer::~BatchedTransitionOptimizer):
577         * runtime/BooleanConstructor.cpp:
578         (JSC::BooleanConstructor::BooleanConstructor):
579         (JSC::constructBoolean):
580         (JSC::constructBooleanFromImmediateBoolean):
581         * runtime/BooleanPrototype.cpp:
582         (JSC::BooleanPrototype::BooleanPrototype):
583         * runtime/ConservativeSet.h:
584         (JSC::ConservativeSet::mark):
585         * runtime/DateConstructor.cpp:
586         (JSC::DateConstructor::DateConstructor):
587         * runtime/DateInstance.cpp:
588         (JSC::DateInstance::DateInstance):
589         * runtime/DatePrototype.cpp:
590         (JSC::dateProtoFuncSetTime):
591         (JSC::setNewValueFromTimeArgs):
592         (JSC::setNewValueFromDateArgs):
593         (JSC::dateProtoFuncSetYear):
594         * runtime/ErrorConstructor.cpp:
595         (JSC::ErrorConstructor::ErrorConstructor):
596         * runtime/ErrorInstance.cpp:
597         (JSC::ErrorInstance::ErrorInstance):
598         * runtime/ErrorPrototype.cpp:
599         (JSC::ErrorPrototype::ErrorPrototype):
600         * runtime/FunctionConstructor.cpp:
601         (JSC::FunctionConstructor::FunctionConstructor):
602         * runtime/FunctionPrototype.cpp:
603         (JSC::FunctionPrototype::FunctionPrototype):
604         * runtime/GetterSetter.cpp:
605         (JSC::GetterSetter::markChildren):
606         * runtime/GetterSetter.h:
607         (JSC::GetterSetter::GetterSetter):
608         (JSC::GetterSetter::getter):
609         (JSC::GetterSetter::setGetter):
610         (JSC::GetterSetter::setter):
611         (JSC::GetterSetter::setSetter):
612         * runtime/GlobalEvalFunction.cpp:
613         (JSC::GlobalEvalFunction::GlobalEvalFunction):
614         (JSC::GlobalEvalFunction::markChildren):
615         * runtime/GlobalEvalFunction.h:
616         (JSC::GlobalEvalFunction::cachedGlobalObject):
617         * runtime/Heap.cpp:
618         (JSC::Heap::markProtectedObjects):
619         (JSC::Heap::markTempSortVectors):
620         (JSC::Heap::markRoots):
621         * runtime/InternalFunction.cpp:
622         (JSC::InternalFunction::InternalFunction):
623         * runtime/JSAPIValueWrapper.h:
624         (JSC::JSAPIValueWrapper::value):
625         (JSC::JSAPIValueWrapper::JSAPIValueWrapper):
626         * runtime/JSActivation.cpp:
627         (JSC::JSActivation::put):
628         * runtime/JSArray.cpp:
629         (JSC::JSArray::JSArray):
630         (JSC::JSArray::getOwnPropertySlot):
631         (JSC::JSArray::getOwnPropertyDescriptor):
632         (JSC::JSArray::put):
633         (JSC::JSArray::putSlowCase):
634         (JSC::JSArray::deleteProperty):
635         (JSC::JSArray::increaseVectorLength):
636         (JSC::JSArray::setLength):
637         (JSC::JSArray::pop):
638         (JSC::JSArray::push):
639         (JSC::JSArray::unshiftCount):
640         (JSC::JSArray::sort):
641         (JSC::JSArray::fillArgList):
642         (JSC::JSArray::copyToRegisters):
643         (JSC::JSArray::compactForSorting):
644         * runtime/JSArray.h:
645         (JSC::JSArray::getIndex):
646         (JSC::JSArray::setIndex):
647         (JSC::JSArray::uncheckedSetIndex):
648         (JSC::JSArray::markChildrenDirect):
649         * runtime/JSByteArray.cpp:
650         (JSC::JSByteArray::JSByteArray):
651         * runtime/JSCell.h:
652         (JSC::JSCell::MarkStack::append):
653         (JSC::JSCell::MarkStack::appendCell):
654         * runtime/JSFunction.cpp:
655         (JSC::JSFunction::JSFunction):
656         (JSC::JSFunction::getOwnPropertySlot):
657         * runtime/JSGlobalObject.cpp:
658         (JSC::markIfNeeded):
659         (JSC::JSGlobalObject::reset):
660         (JSC::JSGlobalObject::resetPrototype):
661         (JSC::JSGlobalObject::markChildren):
662         * runtime/JSGlobalObject.h:
663         (JSC::JSGlobalObject::JSGlobalObjectData::JSGlobalObjectData):
664         (JSC::JSGlobalObject::regExpConstructor):
665         (JSC::JSGlobalObject::errorConstructor):
666         (JSC::JSGlobalObject::evalErrorConstructor):
667         (JSC::JSGlobalObject::rangeErrorConstructor):
668         (JSC::JSGlobalObject::referenceErrorConstructor):
669         (JSC::JSGlobalObject::syntaxErrorConstructor):
670         (JSC::JSGlobalObject::typeErrorConstructor):
671         (JSC::JSGlobalObject::URIErrorConstructor):
672         (JSC::JSGlobalObject::evalFunction):
673         (JSC::JSGlobalObject::objectPrototype):
674         (JSC::JSGlobalObject::functionPrototype):
675         (JSC::JSGlobalObject::arrayPrototype):
676         (JSC::JSGlobalObject::booleanPrototype):
677         (JSC::JSGlobalObject::stringPrototype):
678         (JSC::JSGlobalObject::numberPrototype):
679         (JSC::JSGlobalObject::datePrototype):
680         (JSC::JSGlobalObject::regExpPrototype):
681         (JSC::JSGlobalObject::methodCallDummy):
682         (JSC::constructArray):
683         * runtime/JSONObject.cpp:
684         (JSC::Stringifier::Holder::object):
685         (JSC::Stringifier::Holder::objectSlot):
686         (JSC::Stringifier::markAggregate):
687         (JSC::Stringifier::stringify):
688         (JSC::Stringifier::Holder::appendNextProperty):
689         (JSC::Walker::callReviver):
690         (JSC::Walker::walk):
691         * runtime/JSObject.cpp:
692         (JSC::JSObject::defineGetter):
693         (JSC::JSObject::defineSetter):
694         (JSC::JSObject::removeDirect):
695         (JSC::JSObject::putDirectFunction):
696         (JSC::JSObject::putDirectFunctionWithoutTransition):
697         (JSC::putDescriptor):
698         (JSC::JSObject::defineOwnProperty):
699         * runtime/JSObject.h:
700         (JSC::JSObject::putDirectOffset):
701         (JSC::JSObject::putUndefinedAtDirectOffset):
702         (JSC::JSObject::flattenDictionaryObject):
703         (JSC::JSObject::putDirectInternal):
704         (JSC::JSObject::putDirect):
705         (JSC::JSObject::putDirectFunction):
706         (JSC::JSObject::putDirectWithoutTransition):
707         (JSC::JSObject::putDirectFunctionWithoutTransition):
708         (JSC::JSValue::putDirect):
709         (JSC::JSObject::allocatePropertyStorageInline):
710         (JSC::JSObject::markChildrenDirect):
711         * runtime/JSStaticScopeObject.cpp:
712         (JSC::JSStaticScopeObject::markChildren):
713         * runtime/JSString.cpp:
714         (JSC::StringObject::create):
715         * runtime/JSValue.h:
716         * runtime/JSWrapperObject.cpp:
717         (JSC::JSWrapperObject::markChildren):
718         * runtime/JSWrapperObject.h:
719         (JSC::JSWrapperObject::internalValue):
720         (JSC::JSWrapperObject::setInternalValue):
721         * runtime/LiteralParser.cpp:
722         (JSC::LiteralParser::parse):
723         * runtime/Lookup.cpp:
724         (JSC::setUpStaticFunctionSlot):
725         * runtime/Lookup.h:
726         (JSC::lookupPut):
727         * runtime/MarkStack.h:
728         * runtime/MathObject.cpp:
729         (JSC::MathObject::MathObject):
730         * runtime/NativeErrorConstructor.cpp:
731         (JSC::NativeErrorConstructor::NativeErrorConstructor):
732         * runtime/NativeErrorPrototype.cpp:
733         (JSC::NativeErrorPrototype::NativeErrorPrototype):
734         * runtime/NumberConstructor.cpp:
735         (JSC::NumberConstructor::NumberConstructor):
736         (JSC::constructWithNumberConstructor):
737         * runtime/NumberObject.cpp:
738         (JSC::constructNumber):
739         * runtime/NumberPrototype.cpp:
740         (JSC::NumberPrototype::NumberPrototype):
741         * runtime/ObjectConstructor.cpp:
742         (JSC::ObjectConstructor::ObjectConstructor):
743         (JSC::objectConstructorGetOwnPropertyDescriptor):
744         * runtime/Operations.h:
745         (JSC::normalizePrototypeChain):
746         (JSC::resolveBase):
747         * runtime/PrototypeFunction.cpp:
748         (JSC::PrototypeFunction::PrototypeFunction):
749         * runtime/PutPropertySlot.h:
750         (JSC::PutPropertySlot::setExistingProperty):
751         (JSC::PutPropertySlot::setNewProperty):
752         (JSC::PutPropertySlot::base):
753         * runtime/RegExpConstructor.cpp:
754         (JSC::RegExpConstructor::RegExpConstructor):
755         * runtime/ScopeChain.cpp:
756         (JSC::ScopeChainNode::print):
757         * runtime/ScopeChain.h:
758         (JSC::ScopeChainNode::~ScopeChainNode):
759         (JSC::ScopeChainIterator::operator*):
760         (JSC::ScopeChainIterator::operator->):
761         (JSC::ScopeChain::top):
762         * runtime/ScopeChainMark.h:
763         (JSC::ScopeChain::markAggregate):
764         * runtime/SmallStrings.cpp:
765         (JSC::isMarked):
766         (JSC::SmallStrings::markChildren):
767         * runtime/SmallStrings.h:
768         (JSC::SmallStrings::emptyString):
769         (JSC::SmallStrings::singleCharacterString):
770         (JSC::SmallStrings::singleCharacterStrings):
771         * runtime/StringConstructor.cpp:
772         (JSC::StringConstructor::StringConstructor):
773         * runtime/StringObject.cpp:
774         (JSC::StringObject::StringObject):
775         * runtime/StringObject.h:
776         * runtime/StringPrototype.cpp:
777         (JSC::StringPrototype::StringPrototype):
778         * runtime/Structure.cpp:
779         (JSC::Structure::flattenDictionaryStructure):
780         * runtime/Structure.h:
781         (JSC::Structure::storedPrototypeSlot):
782         * runtime/WeakGCMap.h:
783         (JSC::WeakGCMap::uncheckedGet):
784         (JSC::WeakGCMap::uncheckedGetSlot):
785         (JSC::::get):
786         (JSC::::take):
787         (JSC::::set):
788         (JSC::::uncheckedRemove):
789         * runtime/WriteBarrier.h: Added.
790         (JSC::DeprecatedPtr::DeprecatedPtr):
791         (JSC::DeprecatedPtr::get):
792         (JSC::DeprecatedPtr::operator*):
793         (JSC::DeprecatedPtr::operator->):
794         (JSC::DeprecatedPtr::slot):
795         (JSC::DeprecatedPtr::operator UnspecifiedBoolType*):
796         (JSC::DeprecatedPtr::operator!):
797         (JSC::WriteBarrierBase::set):
798         (JSC::WriteBarrierBase::get):
799         (JSC::WriteBarrierBase::operator*):
800         (JSC::WriteBarrierBase::operator->):
801         (JSC::WriteBarrierBase::slot):
802         (JSC::WriteBarrierBase::operator UnspecifiedBoolType*):
803         (JSC::WriteBarrierBase::operator!):
804         (JSC::WriteBarrier::WriteBarrier):
805         (JSC::operator==):
806
807 2011-01-28  Adam Roben  <aroben@apple.com>
808
809         Chromium build fix after r76967
810
811         * wtf/ThreadingPrimitives.h: Use OS(WINDOWS) instead of PLATFORM(WIN), to match other
812         similar macros in this file.
813
814 2011-01-28  Michael Saboff  <msaboff@apple.com>
815
816         Potentially Unsafe HashSet of RuntimeObject* in RootObject definition
817         https://bugs.webkit.org/show_bug.cgi?id=53271
818
819         Reapplying this this change.  No change from prior patch in
820         JavaScriptCore.
821
822         Added new isValid() methods to check if a contained object in
823         a WeakGCMap is valid when using an unchecked iterator.
824
825         * runtime/WeakGCMap.h:
826         (JSC::WeakGCMap::isValid):
827
828 2011-01-27  Adam Roben  <aroben@apple.com>
829
830         Extract code to convert a WTF absolute time to a Win32 wait interval into a separate
831         function
832
833         Fixes <http://webkit.org/b/53208> <rdar://problem/8922490> BinarySemaphore should wrap a
834         Win32 event
835
836         Reviewed by Dave Hyatt.
837
838         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def: Export the new function.
839
840         * wtf/ThreadingPrimitives.h: Declare the new function.
841
842         * wtf/ThreadingWin.cpp:
843         (WTF::ThreadCondition::timedWait): Moved code to convert the absolute time to a wait
844         interval from here...
845         (WTF::absoluteTimeToWaitTimeoutInterval): ...to here.
846
847 2011-01-28  Sam Weinig  <sam@webkit.org>
848
849         Reviewed by Maciej Stachowiak.
850
851         Add basic rubber banding support
852         <rdar://problem/8219429>
853         https://bugs.webkit.org/show_bug.cgi?id=53277
854
855         * wtf/Platform.h: Add ENABLE for rubber banding.
856
857 2011-01-28  Sheriff Bot  <webkit.review.bot@gmail.com>
858
859         Unreviewed, rolling out r76893.
860         http://trac.webkit.org/changeset/76893
861         https://bugs.webkit.org/show_bug.cgi?id=53287
862
863         It made some tests crash on GTK and Qt debug bots (Requested
864         by Ossy on #webkit).
865
866         * runtime/WeakGCMap.h:
867
868 2011-01-27  Adam Barth  <abarth@webkit.org>
869
870         Reviewed by Eric Seidel.
871
872         Add WTFString method to compare equality with Vector<UChar>
873         https://bugs.webkit.org/show_bug.cgi?id=53266
874
875         I'm planning to use this method in the new XSS filter implementation,
876         but it seems generally useful.
877
878         * wtf/text/StringImpl.h:
879         (WTF::equalIgnoringNullity):
880         * wtf/text/WTFString.h:
881         (WTF::equalIgnoringNullity):
882
883 2011-01-27  Michael Saboff  <msaboff@apple.com>
884
885         Potentially Unsafe HashSet of RuntimeObject* in RootObject definition
886         https://bugs.webkit.org/show_bug.cgi?id=53271
887
888         Added new isValid() methods to check if a contained object in
889         a WeakGCMap is valid when using an unchecked iterator.
890
891         * runtime/WeakGCMap.h:
892         (JSC::WeakGCMap::isValid):
893
894 2011-01-26  Sam Weinig  <sam@webkit.org>
895
896         Reviewed by Maciej Stachowiak.
897
898         Add events to represent the start/end of a gesture scroll
899         https://bugs.webkit.org/show_bug.cgi?id=53215
900
901         * wtf/Platform.h: Add ENABLE for gesture events. 
902
903 2011-01-26  Yael Aharon  <yael.aharon@nokia.com>
904
905         Reviewed by Laszlo Gombos.
906
907         [Qt][Symbian] Fix --minimal build
908         https://bugs.webkit.org/show_bug.cgi?id=52839
909
910         Move definition of USE_SYSTEM_MALLOC out of pri file.
911         Put it in platform.h instead.
912
913         * wtf/Platform.h:
914         * wtf/TCSystemAlloc.cpp:
915         * wtf/wtf.pri:
916
917 2011-01-26  Patrick Gansterer  <paroga@webkit.org>
918
919         Reviewed by Andreas Kling.
920
921         [WINCE] Add JIT support to build system
922         https://bugs.webkit.org/show_bug.cgi?id=53079
923
924         * CMakeListsWinCE.txt:
925
926 2011-01-25  Adam Roben  <aroben@apple.com>
927
928         Windows Production build fix
929
930         Reviewed by Steve Falkenburg.
931
932         * JavaScriptCore.vcproj/JavaScriptCore.make: Set BUILDSTYLE to Release_PGO at the very start
933         of the file so that ConfigurationBuildDir takes that into account. Also set it the right way
934         (by redefining the macro) rather than the wrong way (by modifying the environment variable).
935
936 2011-01-25  Steve Falkenburg  <sfalken@apple.com>
937
938         Rubber-stamped by Adam Roben.
939
940         Windows production build fix.
941         Use correct environment variable escaping
942
943         * JavaScriptCore.vcproj/JavaScriptCore.make:
944         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreGenerated.make:
945
946 2011-01-25  Oliver Hunt  <oliver@apple.com>
947
948         Reviewed by Gavin Barraclough.
949
950         JSON.stringify processing time exponentially grows with size of object
951         https://bugs.webkit.org/show_bug.cgi?id=51922
952
953         Remove last use of reserveCapacity from JSON stringification, as it results
954         in appalling append behaviour when there are a large number of property names
955         and nothing else.
956
957         * runtime/JSONObject.cpp:
958         (JSC::Stringifier::appendQuotedString):
959
960 2011-01-25  Antti Koivisto  <antti@apple.com>
961
962         Not reviewed.
963         
964         Try to fix windows build.
965
966         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
967
968 2011-01-25  Antti Koivisto  <antti@apple.com>
969
970         Reviewed by Oliver Hunt.
971
972         REGRESSION: Leak in JSParser::Scope::copyCapturedVariablesToVector()
973         https://bugs.webkit.org/show_bug.cgi?id=53061
974          
975         Cache did not know about the subclass so failed to fully delete the items. 
976         Got rid of the subclass and moved the classes to separate files.
977
978         * CMakeLists.txt:
979         * GNUmakefile.am:
980         * JavaScriptCore.exp:
981         * JavaScriptCore.gypi:
982         * JavaScriptCore.pro:
983         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
984         * JavaScriptCore.xcodeproj/project.pbxproj:
985         * parser/JSParser.cpp:
986         (JSC::JSParser::Scope::saveFunctionInfo):
987         (JSC::JSParser::Scope::restoreFunctionInfo):
988         (JSC::JSParser::findCachedFunctionInfo):
989         (JSC::JSParser::parseFunctionInfo):
990         * parser/SourceProvider.h:
991         * parser/SourceProviderCache.cpp: Added.
992         (JSC::SourceProviderCache::~SourceProviderCache):
993         (JSC::SourceProviderCache::byteSize):
994         * parser/SourceProviderCache.h: Added.
995         (JSC::SourceProviderCache::SourceProviderCache):
996         (JSC::SourceProviderCache::add):
997         (JSC::SourceProviderCache::get):
998         * parser/SourceProviderCacheItem.h: Added.
999         (JSC::SourceProviderCacheItem::SourceProviderCacheItem):
1000         (JSC::SourceProviderCacheItem::approximateByteSize):
1001         (JSC::SourceProviderCacheItem::closeBraceToken):
1002
1003 2011-01-25  Marcilio Mendonca  <mamendonca@rim.com>
1004
1005         Reviewed by Darin Adler.
1006
1007         Bug 53087: Refactoring: replaced a hanging "else" with a "return"
1008         statement
1009         https://bugs.webkit.org/show_bug.cgi?id=53087.
1010
1011         Refactoring work: Replaced a hanging "else" within an #if PLATFORM(M
1012         with a "return" so that the code is more readable and less error pro
1013         (e.g., "else" doesn't use braces so adding extra lines to the else
1014         block won't have any effect; even worse, code still compiles
1015         successfully.
1016
1017         * wtf/Assertions.cpp:
1018
1019 2011-01-24  Chris Marrin  <cmarrin@apple.com>
1020
1021         Reviewed by Eric Seidel.
1022
1023         Change ENABLE_3D_CANVAS to ENABLE_WEBGL
1024         https://bugs.webkit.org/show_bug.cgi?id=53041
1025
1026         * Configurations/FeatureDefines.xcconfig:
1027
1028 2011-01-25  Adam Roben  <aroben@apple.com>
1029
1030         Windows Production build fix
1031
1032         * JavaScriptCore.vcproj/JavaScriptCore.make: Added a missing "set".
1033
1034 2011-01-25  Patrick Gansterer  <paroga@webkit.org>
1035
1036         Reviewed by Eric Seidel.
1037
1038         Add missing defines for COMPILER(RVCT) && CPU(ARM_THUMB2)
1039         https://bugs.webkit.org/show_bug.cgi?id=52949
1040
1041         * jit/JITStubs.cpp:
1042
1043 2011-01-24  Adam Roben  <aroben@apple.com>
1044
1045         Windows Production build fix
1046
1047         * JavaScriptCore.vcproj/JavaScriptCore.make: Update for move of JavaScriptCore into Source.
1048
1049 2011-01-24  Peter Varga  <pvarga@webkit.org>
1050
1051         Reviewed by Oliver Hunt.
1052
1053         Optimize regex patterns which contain empty alternatives
1054         https://bugs.webkit.org/show_bug.cgi?id=51395
1055
1056         Eliminate the empty alternatives from the regex pattern and convert it to do
1057         the matching in an easier way.
1058
1059         * yarr/YarrPattern.cpp:
1060         (JSC::Yarr::YarrPatternConstructor::atomParenthesesEnd):
1061
1062 2011-01-24  Andras Becsi  <abecsi@webkit.org>
1063
1064         Reviewed by Csaba Osztrogonác.
1065
1066         [Qt] Move project files into Source
1067         https://bugs.webkit.org/show_bug.cgi?id=52891
1068
1069         * JavaScriptCore.pri:
1070         * JavaScriptCore.pro:
1071         * jsc.pro:
1072
1073 2011-01-23  Mark Rowe  <mrowe@apple.com>
1074
1075         Follow-up to r76477.
1076
1077         Fix the scripts that detect problematic code such as static initializers
1078         and destructors, weak vtables, inappropriate files in the framework wrappers,
1079         and public headers including private headers. These had all been broken
1080         since the projects were moved in to the Source directory as the paths to the
1081         scripts were not updated at that time.
1082
1083         * JavaScriptCore.xcodeproj/project.pbxproj:
1084
1085 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
1086
1087         Reviewed by Darin Adler.
1088
1089         Use WTF::StringHasher in WebCore
1090         https://bugs.webkit.org/show_bug.cgi?id=52934
1091
1092         Add an additional function to calculate the hash
1093         of data with a runtimedependent size.
1094
1095         * wtf/StringHasher.h:
1096         (WTF::StringHasher::createBlobHash):
1097
1098 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
1099
1100         Reviewed by David Kilzer.
1101
1102         Fix comment in String::ascii()
1103         https://bugs.webkit.org/show_bug.cgi?id=52980
1104
1105         * wtf/text/WTFString.cpp:
1106         (WTF::String::ascii):
1107
1108 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
1109
1110         Reviewed by David Kilzer.
1111
1112         Add String::containsOnlyLatin1()
1113         https://bugs.webkit.org/show_bug.cgi?id=52979
1114
1115         * wtf/text/WTFString.h:
1116         (WTF::String::containsOnlyLatin1):
1117         (WTF::charactersAreAllLatin1):
1118
1119 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
1120
1121         Reviewed by Oliver Hunt.
1122
1123         Remove obsolete JSVALUE32 code
1124         https://bugs.webkit.org/show_bug.cgi?id=52948
1125
1126         r70111 removed support for JSVALUE32.
1127         ARM, MIPS and X86 support JSVALUE32_64 only.
1128
1129         * jit/JITStubs.cpp:
1130
1131 2011-01-22  Geoffrey Garen  <ggaren@apple.com>
1132
1133         Reviewed by Dan Bernstein.
1134
1135         ASSERT running run-webkit-tests --threaded.
1136         https://bugs.webkit.org/show_bug.cgi?id=52971
1137         
1138         SunSpider and v8 report no change.
1139
1140         * runtime/ConservativeSet.cpp:
1141         (JSC::ConservativeSet::grow):
1142         (JSC::ConservativeSet::add):
1143         * runtime/ConservativeSet.h: Tweaked the inline capacity to 128, and
1144         the growth policy to 2X, to make SunSpider and v8 happy.
1145         (JSC::ConservativeSet::ConservativeSet):
1146         (JSC::ConservativeSet::~ConservativeSet):
1147         (JSC::ConservativeSet::mark): Use OSAllocator directly, instead of malloc.
1148         Malloc is forbidden during a multi-threaded mark phase because it can
1149         cause deadlock.
1150
1151 2011-01-22  Geoffrey Garen  <ggaren@apple.com>
1152
1153         Reviewed by Geoffrey Garen.
1154
1155         Rubber-stamped by Maciej Stachowiak.
1156
1157         A few of Maciej's review suggestions for my last patch.
1158         https://bugs.webkit.org/show_bug.cgi?id=52946        
1159
1160         SunSpider reports no change.
1161
1162         * Android.mk:
1163         * CMakeLists.txt:
1164         * GNUmakefile.am:
1165         * JavaScriptCore.gypi:
1166         * JavaScriptCore.pro:
1167         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
1168         * JavaScriptCore.xcodeproj/project.pbxproj: Updated build systems.
1169
1170         * runtime/ConservativeSet.cpp: Added.
1171         (JSC::isPointerAligned):
1172         (JSC::ConservativeSet::add):
1173         * runtime/ConservativeSet.h: Added.
1174         (JSC::ConservativeSet::ConservativeSet):
1175         (JSC::ConservativeSet::mark): Split ConservativeSet out into its own
1176         file, and moved the conservative check into ConservativeSet::add, making
1177         ConservativeSet's responsibility clearer.
1178
1179         * runtime/Heap.cpp:
1180         (JSC::Heap::markRoots):
1181         * runtime/MachineStackMarker.cpp:
1182         (JSC::MachineStackMarker::markCurrentThreadConservativelyInternal):
1183         (JSC::MachineStackMarker::markOtherThreadConservatively):
1184         * runtime/MachineStackMarker.h:
1185         * runtime/MarkStack.h: Updated for changes above.
1186
1187 2011-01-22  Patrick Gansterer  <paroga@webkit.org>
1188
1189         Unreviewed WinCE build fix for r76430.
1190
1191         * runtime/MachineStackMarker.cpp:
1192         (JSC::swapIfBackwards):
1193
1194 2011-01-21  Geoffrey Garen  <ggaren@apple.com>
1195
1196         Reviewed by Beth Dakin.
1197
1198         Reorganized MarkedSpace, making many of its functions private.
1199
1200         * runtime/JSCell.h:
1201         (JSC::JSCell::Heap::heap):
1202         * runtime/MarkedSpace.h:
1203         (JSC::MarkedSpace::globalData):
1204         (JSC::MarkedSpace::heap):
1205
1206 2011-01-21  Geoffrey Garen  <ggaren@apple.com>
1207
1208         Try to fix build: moved helper function out of #ifdef.
1209
1210         * runtime/MachineStackMarker.cpp:
1211         (JSC::swapIfBackwards):
1212
1213 2011-01-21  Geoffrey Garen  <ggaren@apple.com>
1214
1215         Rubber-stamped by Maciej Stachowiak.
1216
1217         A few of Maciej's review suggestions for my last patch.
1218         https://bugs.webkit.org/show_bug.cgi?id=52946        
1219
1220         SunSpider reports no change.
1221
1222         * runtime/MachineStackMarker.cpp:
1223         (JSC::swapIfBackwards): Added a helper function for handling platforms
1224         where the stack can grow in any direction.
1225
1226         (JSC::MachineStackMarker::markCurrentThreadConservativelyInternal):
1227         (JSC::MachineStackMarker::markOtherThreadConservatively): Use the helper
1228         function.
1229
1230         (JSC::isPointerAligned): Use "!" instead of "==0" because a robot told me to.
1231
1232         (JSC::MachineStackMarker::markConservatively): Changed to use a more
1233         standard looping idiom, and to use the helper function above.
1234
1235         * runtime/MarkedSpace.h:
1236         (JSC::MarkedSpace::isCellAligned): Use "!" instead of "==0" because a robot told me to.
1237
1238 2011-01-21  Geoffrey Garen  <ggaren@apple.com>
1239
1240         Reviewed by Maciej Stachowiak.
1241
1242         Cleaned up some conservative marking code.
1243         https://bugs.webkit.org/show_bug.cgi?id=52946
1244         
1245         SunSpider reports no change.
1246
1247         * interpreter/RegisterFile.h: No need for a special marking function,
1248         since we already expose a start() and end().
1249
1250         * runtime/Heap.cpp:
1251         (JSC::Heap::registerFile):
1252         (JSC::Heap::markRoots):
1253         * runtime/Heap.h:
1254         (JSC::Heap::contains): Migrated markConservatively() to the machine stack
1255         marker class. Now, Heap just provides a contains() function, which the
1256         machine stack marker uses for checking whether a pointer points into the heap.
1257
1258         * runtime/MachineStackMarker.cpp:
1259         (JSC::MachineStackMarker::markCurrentThreadConservativelyInternal):
1260         (JSC::MachineStackMarker::markOtherThreadConservatively):
1261         (JSC::isPointerAligned):
1262         (JSC::MachineStackMarker::markConservatively):
1263         * runtime/MachineStackMarker.h: Move the conservative marking code here.
1264
1265         * runtime/MarkStack.h:
1266         (JSC::ConservativeSet::add):
1267         (JSC::ConservativeSet::mark): Changed to using a vector instead of hash
1268         set. Vector seems to be a bit faster, and it generates smaller code.
1269
1270         * runtime/MarkedSpace.cpp:
1271         (JSC::MarkedSpace::containsSlowCase):
1272         * runtime/MarkedSpace.h:
1273         (JSC::MarkedSpace::isCellAligned):
1274         (JSC::MarkedSpace::isPossibleCell):
1275         (JSC::MarkedSpace::contains): Kept the code for determining whether a
1276         pointer pointed into marked space, and moved the code for marking
1277         a set of conservative pointers into the machine stack marker.
1278
1279         * wtf/HashSet.h:
1280         (WTF::::add): Added two missing inlines that I noticed while testing
1281         vector vs hash set.
1282
1283 2011-01-21  Mark Rowe  <mrowe@apple.com>
1284
1285         Reviewed by Sam Weinig.
1286
1287         Work around a Clang bug <rdar://problem/8876150> that leads to it incorrectly emitting an access
1288         control warning when a client tries to use operator bool exposed above via "using PageBlock::operator bool".
1289
1290         * wtf/PageAllocation.h:
1291         (WTF::PageAllocation::operator bool):
1292         * wtf/PageReservation.h:
1293         (WTF::PageReservation::operator bool):
1294
1295 2011-01-21  Michael Saboff  <msaboff@apple.com>
1296
1297         Reviewed by Oliver Hunt.
1298
1299         [RegexFuzz] Hang with forward assertion
1300         https://bugs.webkit.org/show_bug.cgi?id=52825
1301         <rdar://problem/8894332>
1302
1303         The backtrackTo label from the first term in a list of terms is
1304         being overwritten by processing of subsequent terms.  Changed
1305         copyBacktrackToLabel() to check for an existing bcaktrackTo label
1306         before copying and renamed it to propagateBacktrackToLabel() since
1307         it no longer copies.
1308
1309         * yarr/YarrJIT.cpp:
1310         (JSC::Yarr::YarrGenerator::BacktrackDestination::propagateBacktrackToLabel):
1311         (JSC::Yarr::YarrGenerator::generateParenthesesSingle):
1312
1313 2011-01-21  Geoffrey Garen  <ggaren@apple.com>
1314
1315         Reviewed by Sam Weinig.
1316
1317         Moved the mark stack from global data to the heap, since it pertains
1318         to the heap, and not the virtual machine as a whole.
1319         https://bugs.webkit.org/show_bug.cgi?id=52930
1320         
1321         SunSpider reports no change.
1322
1323         * runtime/Heap.cpp:
1324         (JSC::Heap::Heap):
1325         (JSC::Heap::markRoots):
1326         * runtime/Heap.h:
1327         * runtime/JSGlobalData.cpp:
1328         (JSC::JSGlobalData::JSGlobalData):
1329         * runtime/JSGlobalData.h:
1330
1331 2011-01-21  Peter Gal  <galpeter@inf.u-szeged.hu>
1332
1333         Reviewed by Darin Adler.
1334
1335         REGRESSION(r76177): All JavaScriptCore tests fail on ARM
1336         https://bugs.webkit.org/show_bug.cgi?id=52814
1337
1338         Get the approximateByteSize value before releasing the OwnPtr.
1339
1340         * parser/JSParser.cpp:
1341         (JSC::JSParser::parseFunctionInfo):
1342
1343 2011-01-21  Xan Lopez  <xlopez@igalia.com>
1344
1345         Reviewed by Martin Robinson.
1346
1347         Remove unnecessary <stdio.h> include
1348         https://bugs.webkit.org/show_bug.cgi?id=52884
1349
1350         * jit/JIT.cpp: remove unnecessary include.
1351
1352 2011-01-20  Ryosuke Niwa  <rniwa@webkit.org>
1353
1354         Reviewed by Maciej Stachowiak.
1355
1356         Added OwnPtrCommon.h because OwnArrayPtr::set calls deleteOwnedPtr.
1357
1358         * wtf/OwnArrayPtr.h:
1359
1360 2011-01-20  Patrick Gansterer  <paroga@webkit.org>
1361
1362         Reviewed by Oliver Hunt.
1363
1364         [WINCE] Remove obsolete JSVALUE32 code
1365         https://bugs.webkit.org/show_bug.cgi?id=52450
1366
1367         Remove the "offset hack" in create_jit_stubs, since we
1368         only support JSVALUE32_64 in the meantime.
1369
1370         * create_jit_stubs: Removed offset argument
1371         * jit/JITStubs.cpp:
1372
1373 2011-01-20  Geoffrey Garen  <ggaren@apple.com>
1374
1375         Reviewed by Oliver Hunt.
1376
1377         When marking conservatively, guard against reviving dead objects.
1378         https://bugs.webkit.org/show_bug.cgi?id=52840
1379         
1380         SunSpider and v8 say no change.
1381
1382         * interpreter/RegisterFile.h:
1383         (JSC::RegisterFile::markCallFrames): Updated to use the ConservativeSet API.
1384
1385         * runtime/Heap.cpp:
1386         (JSC::Heap::recordExtraCost): No need to guard against conservative
1387         marking reviving dead objects anymore, since the conservative marking
1388         mechanism guards against this now.
1389
1390         (JSC::Heap::markConservatively):
1391         (JSC::Heap::markProtectedObjects):
1392         (JSC::Heap::markTempSortVectors): Don't drain the mark stack inside a
1393         marking function. We want to establish a separation of concerns between
1394         visiting roots and draining the mark stack.
1395
1396         (JSC::Heap::markRoots): Gather the set of conservative references before
1397         clearning mark bits, because conservative marking now uses the mark bits
1398         to determine if a reference is valid, and avoid reviving dead objects.
1399
1400         (JSC::Heap::collectAllGarbage): No need to guard against conservative
1401         marking reviving dead objects anymore, since the conservative marking
1402         mechanism guards against this now.
1403
1404         * runtime/Heap.h: Updated to use the ConservativeSet API.
1405
1406         * runtime/MachineStackMarker.cpp:
1407         (JSC::MachineStackMarker::markCurrentThreadConservativelyInternal):
1408         (JSC::MachineStackMarker::markCurrentThreadConservatively):
1409         (JSC::MachineStackMarker::markOtherThreadConservatively):
1410         (JSC::MachineStackMarker::markMachineStackConservatively):
1411         * runtime/MachineStackMarker.h: Ditto.
1412
1413         * runtime/MarkStack.h:
1414         (JSC::ConservativeSet::add):
1415         (JSC::ConservativeSet::mark): Added ConservativeSet, for gathering the
1416         set of conservative references. This is different from MarkStack, since
1417         we don't mark the set until it is completely gathered.
1418
1419         * runtime/MarkedSpace.cpp:
1420         (JSC::MarkedSpace::freeBlock):
1421         (JSC::MarkedSpace::resizeBlocks):
1422         (JSC::MarkedSpace::markConservatively):
1423         * runtime/MarkedSpace.h: When marking conservatively, guard against
1424         reviving dead objects.
1425
1426 2011-01-20  Siddharth Mathur  <siddharth.mathur@nokia.com>
1427
1428         Reviewed by Geoffrey Garen.
1429
1430         [Symbian] Fix StackBounds::initialize()
1431         https://bugs.webkit.org/show_bug.cgi?id=52842
1432
1433         * wtf/StackBounds.cpp:
1434         (WTF::StackBounds::initialize): Use TThreadStackInfo.iLimit for stack limit
1435
1436 2011-01-20  Michael Saboff  <msaboff@apple.com>
1437
1438         Reviewed by Oliver Hunt.
1439
1440         <rdar://problem/8890203> [RegexFuzz] Crash in generated code (52773)
1441         https://bugs.webkit.org/show_bug.cgi?id=52773
1442
1443         Fixed case where an existing DataLabelPtr is overwritten.  The
1444         replacing DataLabelPtr is now resolved immediately in
1445         linkDataLabelToBacktrackIfExists().  Cleanup - eliminated bool
1446         return value for the routine as it was never used.
1447
1448         * yarr/YarrJIT.cpp:
1449         (JSC::Yarr::YarrGenerator::TermGenerationState::linkDataLabelToBacktrackIfExists):
1450
1451 2011-01-20  Andras Becsi  <abecsi@webkit.org>
1452
1453         Reviewed by Csaba Osztrogonác.
1454
1455         [Qt][WK2] WebKit2 enabled build fails to link
1456
1457         Work around undefined reference linking issues until the buildsystem gets redesigned.
1458         These issues first occured in minimal builds (see BUG 50519).
1459
1460         * JavaScriptCore.pri: link as whole-archive for WebKit2 builds
1461
1462 2011-01-20  Zoltan Horvath  <zoltan@webkit.org>
1463
1464         Reviewed by Csaba Osztrogonác.
1465
1466         Refactoring of the custom allocation framework
1467         https://bugs.webkit.org/show_bug.cgi?id=49897
1468
1469         Inheriting from FastAllocBase can result in objects getting larger (bug #33896, #46589).
1470         The modification replaces Noncopyable and FastAllocBase classes and these inherits with their
1471         equivalent macro implementation at the necessary places.
1472
1473         * wtf/FastAllocBase.h: Turn FastAllocBase's implementation into a macro.
1474
1475 2011-01-20  Mark Rowe  <mrowe@apple.com>
1476
1477         Reviewed by Maciej Stachowiak.
1478
1479         Follow-up to r75766 / <rdar://problem/5469576>.
1480
1481         We were failing to initialize the key, causing all sorts of unexpected behavior.
1482
1483         * wtf/FastMalloc.cpp:
1484         (WTF::setThreadHeap):
1485         (WTF::TCMalloc_ThreadCache::GetThreadHeap):
1486         (WTF::TCMalloc_ThreadCache::InitTSD): Ensure that the key is initialized.
1487
1488 2011-01-18  Geoffrey Garen  <ggaren@apple.com>
1489
1490         Reviewed by Darin Adler.
1491
1492         Rolled back in r76078, with crash fixed.
1493         https://bugs.webkit.org/show_bug.cgi?id=52668
1494         
1495         * runtime/JSGlobalObject.cpp:
1496         (JSC::JSGlobalObject::markChildren): Account for the fact that the global
1497         object moves its variables into and out of the register file. While out
1498         of the register file, the symbol table's size is not an accurate count
1499         for the size of the register array, since the BytecodeGenerator might
1500         be compiling, adding items to the symbol table.
1501         
1502 2011-01-18  Darin Adler  <darin@apple.com>
1503
1504         Reviewed by Geoffrey Garen.
1505
1506         Stack overflow when converting an Error object to string
1507         https://bugs.webkit.org/show_bug.cgi?id=46410
1508
1509         * Android.mk: Added StringRecursionChecker.cpp and
1510         StringRecursionChecker.h.
1511         * CMakeLists.txt: Ditto.
1512         * GNUmakefile.am: Ditto.
1513         * JavaScriptCore.gypi: Ditto.
1514         * JavaScriptCore.pro: Ditto.
1515         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj: Ditto.
1516         * JavaScriptCore.xcodeproj/project.pbxproj: Ditto.
1517
1518         * runtime/ArrayPrototype.cpp:
1519         (JSC::arrayProtoFuncToString): Use StringRecursionChecker instead
1520         of the older hand-written code to do the same thing.
1521         (JSC::arrayProtoFuncToLocaleString): Ditto.
1522         (JSC::arrayProtoFuncJoin): Ditto.
1523
1524         * runtime/ErrorPrototype.cpp:
1525         (JSC::errorProtoFuncToString): Use StringRecursionChecker.
1526
1527         * runtime/JSGlobalData.h: Renamed arrayVisitedElements to
1528         stringRecursionCheckVisitedObjects.
1529
1530         * runtime/RegExpPrototype.cpp:
1531         (JSC::regExpProtoFuncToString): Use StringRecursionChecker.
1532
1533         * runtime/StringRecursionChecker.cpp: Added.
1534         * runtime/StringRecursionChecker.h: Added.
1535
1536 2011-01-19  Oliver Hunt  <oliver@apple.com>
1537
1538         Reviewed by Gavin Barraclough.
1539
1540         Remove non-spec support for callable RegExp
1541         https://bugs.webkit.org/show_bug.cgi?id=28285
1542
1543         Remove support for callable regexps.  If it breaks sites we can
1544         just roll this out.
1545
1546         * runtime/RegExpObject.cpp:
1547         * runtime/RegExpObject.h:
1548         * tests/mozilla/expected.html: update results.
1549
1550 2011-01-19  Antti Koivisto  <antti@apple.com>
1551
1552         Reviewed by Oliver Hunt.
1553
1554         Cache function offsets to speed up javascript parsing
1555         https://bugs.webkit.org/show_bug.cgi?id=52622
1556         
1557         Use cache to save function offsets and some other info.
1558         This avoids quite a bit of work when reparsing the source.
1559
1560         * parser/ASTBuilder.h:
1561         * parser/JSParser.cpp:
1562         (JSC::JSParser::CachedFunctionInfo::CachedFunctionInfo):
1563         (JSC::JSParser::CachedFunctionInfo::approximateByteSize):
1564         (JSC::JSParser::CachedFunctionInfo::closeBraceToken):
1565         (JSC::JSParser::Scope::copyCapturedVariablesToVector):
1566         (JSC::JSParser::Scope::saveFunctionInfo):
1567         (JSC::JSParser::Scope::restoreFunctionInfo):
1568         (JSC::JSParser::findCachedFunctionInfo):
1569         (JSC::JSParser::JSParser):
1570         (JSC::JSParser::parseProgram):
1571         (JSC::JSParser::parseFunctionInfo):
1572         * parser/Lexer.h:
1573         (JSC::Lexer::setOffset):
1574         (JSC::Lexer::setLineNumber):
1575         (JSC::Lexer::sourceProvider):
1576         * parser/SourceProvider.h:
1577         (JSC::SourceProviderCache::SourceProviderCache):
1578         (JSC::SourceProviderCache::~SourceProviderCache):
1579         (JSC::SourceProviderCache::byteSize):
1580         (JSC::SourceProviderCache::add):
1581         (JSC::SourceProviderCache::get):
1582         (JSC::SourceProvider::SourceProvider):
1583         (JSC::SourceProvider::~SourceProvider):
1584         (JSC::SourceProvider::cache):
1585         (JSC::SourceProvider::notifyCacheSizeChanged):
1586         (JSC::SourceProvider::cacheSizeChanged):
1587         * parser/SyntaxChecker.h:
1588
1589 2011-01-19  Mark Rowe  <mrowe@apple.com>
1590
1591         Reviewed by Darin Adler.
1592
1593         Follow-up to r75766 / <rdar://problem/5469576>.
1594
1595         * DerivedSources.make: Evaluate the SDKROOT variable correctly.
1596
1597 2011-01-19  Oliver Hunt  <oliver@apple.com>
1598
1599         Reviewed by Gavin Barraclough.
1600
1601         [jsfunfuzz] Defining a function called __proto__ inside an eval triggers an assertion
1602         https://bugs.webkit.org/show_bug.cgi?id=52672
1603
1604         Rather than coming up with a somewhat convoluted mechanism to ensure that
1605         developers can override the global objects prototype with a function named
1606         __proto__ and expect it to work, we just disallow it at the syntax level.
1607
1608         * parser/JSParser.cpp:
1609         (JSC::JSParser::parseFunctionInfo):
1610
1611 2011-01-19  Michael Saboff  <msaboff@apple.com>
1612
1613         Reviewed by Darin Adler.
1614
1615         <rdar://problem/8882994> Regression: Simple nested backtrack hangs
1616         https://bugs.webkit.org/show_bug.cgi?id=52675
1617
1618         The changeset (r76076) for https://bugs.webkit.org/show_bug.cgi?id=52540
1619         broke simple backtracking in some cases.  Reworked that change to 
1620         link both jumps and labels.
1621
1622         * yarr/YarrJIT.cpp:
1623         (JSC::Yarr::YarrGenerator::BacktrackDestination::hasBacktrackToLabel):
1624         (JSC::Yarr::YarrGenerator::TermGenerationState::propagateBacktrackingFrom):
1625         (JSC::Yarr::YarrGenerator::generateParenthesesSingle):
1626
1627 2011-01-19  Pavel Podivilov  <podivilov@chromium.org>
1628
1629         Reviewed by Yury Semikhatsky.
1630
1631         Web Inspector: [JSC] scripts have incorrect starting line (always 1).
1632         https://bugs.webkit.org/show_bug.cgi?id=52721
1633
1634         * debugger/Debugger.cpp:
1635         (JSC::Debugger::recompileAllJSFunctions):
1636         * debugger/Debugger.h:
1637         * parser/Parser.h:
1638         (JSC::Parser::parse):
1639         * parser/SourceCode.h:
1640         (JSC::SourceCode::SourceCode):
1641         * parser/SourceProvider.h:
1642         (JSC::SourceProvider::startPosition):
1643
1644 2011-01-19  Csaba Osztrogonác  <ossy@webkit.org>
1645
1646         Reviewed by Laszlo Gombos and Tor Arne Vestbø.
1647
1648         [Qt] Remove unnecessary "../Source" from paths
1649         after moving source files into Source is finished.
1650
1651         * JavaScriptCore.pri:
1652
1653 2011-01-19  Benjamin Kalman  <kalman@chromium.org>
1654
1655         Reviewed by Darin Adler.
1656
1657         Don't return void from void function String::split
1658         https://bugs.webkit.org/show_bug.cgi?id=52684
1659
1660         * wtf/text/WTFString.cpp:
1661         (WTF::String::split):
1662
1663 2011-01-18  Kenneth Russell  <kbr@google.com>
1664
1665         Unreviewed, rolling out r76078.
1666         http://trac.webkit.org/changeset/76078
1667         https://bugs.webkit.org/show_bug.cgi?id=52668
1668
1669         Caused crashes of fast/canvas/webgl/constants.html,
1670         fast/canvas/webgl/gl-enum-tests.html, and possibly other layout
1671         test crashes in Release mode. WebGL crashes were observed with
1672         "run-webkit-tests fast/canvas/webgl". It was necessary to run
1673         multiple tests to provoke the crash.
1674
1675         * interpreter/RegisterFile.h:
1676         (JSC::RegisterFile::markGlobals):
1677         * runtime/JSActivation.cpp:
1678         (JSC::JSActivation::markChildren):
1679         * runtime/JSGlobalObject.cpp:
1680         (JSC::JSGlobalObject::markChildren):
1681
1682 2011-01-18  Oliver Hunt  <oliver@apple.com>
1683
1684         Reviewed by Gavin Barraclough.
1685
1686         [jsfunfuzz] Assertion asking activation for arguments when arguments is overridden
1687         https://bugs.webkit.org/show_bug.cgi?id=52690
1688
1689         Clean up code to retrieve arguments from activation and function objects.
1690         Remove the incorrect assertion from JSActivation's argumentsGetter.
1691
1692         * interpreter/Interpreter.cpp:
1693         (JSC::Interpreter::retrieveArguments):
1694         * runtime/JSActivation.cpp:
1695         (JSC::JSActivation::argumentsGetter):
1696
1697 2011-01-18  Geoffrey Garen  <ggaren@apple.com>
1698
1699         Reviewed by Darin Adler.
1700
1701         Removed RegisterFile::markGlobals because it was obtuse, and it
1702         unnecessarily relied on conservative marking.
1703         https://bugs.webkit.org/show_bug.cgi?id=52668
1704
1705         * interpreter/RegisterFile.h: Removed markGlobals.
1706
1707         * runtime/JSActivation.cpp:
1708         (JSC::JSActivation::markChildren): Added a comment explaning why some
1709         JSActivations don't always mark their registers arrays.
1710
1711         * runtime/JSGlobalObject.cpp:
1712         (JSC::JSGlobalObject::markChildren): Instead of calling markGlobals, mark
1713         the registers array directly.
1714
1715 2011-01-18  Michael Saboff  <msaboff@apple.com>
1716
1717         Reviewed by Oliver Hunt.
1718
1719         <rdar://problem/8875432> Regression: Some text-only e-mails cause hang beneath RegExp::match (52540)
1720         https://bugs.webkit.org/show_bug.cgi?id=52540
1721         https://bugs.webkit.org/show_bug.cgi?id=52662
1722
1723         Directly use backtrack label with parentheses nested under a
1724         non-capturing parentheses.  Also linked current parentheses
1725         tail code object for possible parens nested within a non-capturing
1726         parentheses.
1727
1728         * yarr/YarrJIT.cpp:
1729         (JSC::Yarr::YarrGenerator::BacktrackDestination::linkBacktrackToLabel):
1730         (JSC::Yarr::YarrGenerator::generateParenthesesSingle):
1731
1732 2011-01-18  Daniel Bates  <dbates@rim.com>
1733
1734         Reviewed by Gavin Barraclough.
1735
1736         Only use moving memory model assumption in ExecutableAllocator::intializePageSize() for Symbian OS
1737         https://bugs.webkit.org/show_bug.cgi?id=52517
1738
1739         Patch by David Tapuska
1740
1741         Currently, we compile code with respect to the Symbian-specific moving memory model
1742         assumption for all ARMv5 or lower architectures. Instead, we should only compile
1743         such code when building for Symbian OS on those architectures because this model
1744         is Symbian-specific.
1745
1746         * jit/ExecutableAllocator.cpp:
1747         (JSC::ExecutableAllocator::intializePageSize):
1748
1749 2011-01-18  Dimitry Andric  <dim@freebsd.org>
1750
1751         Reviewed by Andreas Kling.
1752
1753         Fix linking JavaScriptCore on FreeBSD/amd64
1754         https://bugs.webkit.org/show_bug.cgi?id=52591
1755
1756         Linking of JavaScriptCore on FreeBSD/amd64 fails, for the same reason as
1757         in bug 28422: cti_vm_throw needs a "@plt" suffix, otherwise the linker
1758         complains about the relocation type.
1759
1760         * jit/JITStubs.cpp: use @plt suffix on x86_64 platforms, for both Linux
1761         and FreeBSD.
1762
1763 2011-01-18  Oliver Hunt  <oliver@apple.com>
1764
1765         Reviewed by Antti Koivisto.
1766
1767         [jsfunfuzz] Assertion in codegen for array of NaN constants
1768         https://bugs.webkit.org/show_bug.cgi?id=52643
1769
1770         Don't cache NaN literals in the code generator, as NaN doesn't compare
1771         as equal to itself it causes problems when rehashing the number cache.
1772
1773         * bytecompiler/BytecodeGenerator.cpp:
1774         (JSC::BytecodeGenerator::emitLoad):
1775
1776 2011-01-17  Jarred Nicholls  <jarred@sencha.com>
1777
1778         Reviewed by Csaba Osztrogonác.
1779
1780         REGRESSION(r75709): Return value of fscanf() shouldn't be ignored.
1781         https://bugs.webkit.org/show_bug.cgi?id=52585
1782         
1783         gcc 4.4.4+ has warn_unused_value attribute on fscanf, so we should check
1784         the return value to get around the gcc warning
1785
1786         * jit/ExecutableAllocatorFixedVMPool.cpp:
1787         (JSC::maybeModifyVMPoolSize):
1788
1789 2011-01-17  Michael Saboff  <msaboff@apple.com>
1790
1791         Reviewed by Oliver Hunt.
1792
1793         [regexfuzz] Crash running regex with lookahead
1794         https://bugs.webkit.org/show_bug.cgi?id=52548
1795
1796         Eliminated agressive chaining of backtracks.  This code was overwriting
1797         already valid backtrack information.
1798
1799         * yarr/YarrJIT.cpp:
1800         (JSC::Yarr::YarrGenerator::ParenthesesTail::processBacktracks):
1801
1802 2011-01-17  Tony Gentilcore  <tonyg@chromium.org>
1803
1804         Reviewed by Alexey Proskuryakov.
1805
1806         Fix some headers with missing or misspelled #ifndef guards
1807         https://bugs.webkit.org/show_bug.cgi?id=52545
1808
1809         * wtf/RefPtrHashMap.h:
1810
1811 2011-01-17  Dan Bernstein  <mitz@apple.com>
1812
1813         Rubber-stamped by Mark Rowe.
1814
1815         Update xcodeproj svn:ignore to include xcuserdata.
1816
1817         * JavaScriptCore.xcodeproj: Modified property svn:ignore.
1818
1819 2011-01-16  Adam Barth  <abarth@webkit.org>
1820
1821         Rubber-stamped by Eric Seidel.
1822
1823         Move WebKit into Source
1824         https://bugs.webkit.org/show_bug.cgi?id=52530
1825
1826         * JavaScriptCore.gyp/JavaScriptCore.gyp:
1827
1828 2011-01-16  Oliver Hunt  <oliver@apple.com>
1829
1830         Reviewed by Sam Weinig.
1831
1832         [jsfunfuzz] Parser doesn't correctly validate for-loop syntax
1833         https://bugs.webkit.org/show_bug.cgi?id=52516
1834
1835         Ensure that we always check for a semicolon after encountering
1836         multiple declarations in the initialiser portion of a for-loop.
1837
1838         * parser/JSParser.cpp:
1839         (JSC::JSParser::parseForStatement):
1840
1841 2011-01-16  Oliver Hunt  <oliver@apple.com>
1842
1843         Reviewed by Geoffrey Garen.
1844
1845         Strict mode restrictions on arguments and eval usage aren't complete
1846         https://bugs.webkit.org/show_bug.cgi?id=52528
1847
1848         Fix a few bugs in strict mode where we incorrect allow mutation of
1849         arguments and eval in the parser.
1850
1851         Alas the "optimisation" used by the syntax checker for validating
1852         binary and unary expressions was too aggressive: we do actually need
1853         a stack for operations and operands although it needn't be as complete
1854         as that used for the full AST builder.
1855
1856         Also disallow assignment to arguments in all cases as allowing arguments
1857         to be assignable is always an error in strict mode, regardless of context.
1858
1859         * parser/ASTBuilder.h:
1860         (JSC::ASTBuilder::BinaryExprContext::BinaryExprContext):
1861         (JSC::ASTBuilder::UnaryExprContext::UnaryExprContext):
1862         * parser/JSParser.cpp:
1863         (JSC::JSParser::parseAssignmentExpression):
1864         (JSC::JSParser::parseBinaryExpression):
1865         (JSC::JSParser::parseUnaryExpression):
1866         * parser/SyntaxChecker.h:
1867         (JSC::SyntaxChecker::BinaryExprContext::BinaryExprContext):
1868         (JSC::SyntaxChecker::BinaryExprContext::~BinaryExprContext):
1869         (JSC::SyntaxChecker::UnaryExprContext::UnaryExprContext):
1870         (JSC::SyntaxChecker::UnaryExprContext::~UnaryExprContext):
1871         (JSC::SyntaxChecker::appendBinaryExpressionInfo):
1872         (JSC::SyntaxChecker::operatorStackPop):
1873
1874 2011-01-15  Geoffrey Garen  <ggaren@apple.com>
1875
1876         Reviewed by Oliver Hunt.
1877
1878         Rolled back in r75886.
1879         https://bugs.webkit.org/show_bug.cgi?id=52527
1880         
1881         r75886 broke the GTK Linux bot because Linux was -- quite surprisingly --
1882         set up to use the constants for embedded devices.
1883
1884         * jit/ExecutableAllocatorFixedVMPool.cpp:
1885         (JSC::maybeModifyVMPoolSize): Separated Linux constants from embedded
1886         constants.
1887
1888 2011-01-15  Sheriff Bot  <webkit.review.bot@gmail.com>
1889
1890         Unreviewed, rolling out r75886.
1891         http://trac.webkit.org/changeset/75886
1892         https://bugs.webkit.org/show_bug.cgi?id=52526
1893
1894         "Broke GTK+ 64bit" (Requested by xan_ on #webkit).
1895
1896         * jit/ExecutableAllocatorFixedVMPool.cpp:
1897
1898 2011-01-15  Geoffrey Garen  <ggaren@apple.com>
1899
1900         Reviewed by Sam Weinig.
1901
1902         <rdar://problem/8870429> Shrink the executable pool on embedded devices
1903
1904         * jit/ExecutableAllocatorFixedVMPool.cpp: Dropped the pool size from 32MB
1905         to 16MB.
1906
1907 2011-01-15  Oliver Hunt  <oliver@apple.com>
1908
1909         Reviewed by Maciej Stachowiak.
1910
1911         Incorrect behavior changing attributes of an accessor
1912         https://bugs.webkit.org/show_bug.cgi?id=52515
1913
1914         defineProperty doesn't correctly handle changing attributes of an accessor
1915         property.  This is because we don't pass the full descriptor to the 
1916         putDescriptor helper function, which means we have insufficient information
1917         to do the right thing. Once that's passed the correct behavior is relatively
1918         simple to implement.
1919
1920         * runtime/JSObject.cpp:
1921         (JSC::putDescriptor):
1922         (JSC::JSObject::defineOwnProperty):
1923
1924 2011-01-14  Oliver Hunt  <oliver@apple.com>
1925
1926         Reviewed by Maciej Stachowiak.
1927
1928         [jsfunfuzz] Incorrect handling of consecutive duplicate labels
1929         https://bugs.webkit.org/show_bug.cgi?id=52505
1930
1931         Compare StringImpl*'s instead of Identifier*'s when looking for duplicate
1932         labels.
1933
1934         * parser/JSParser.cpp:
1935         (JSC::JSParser::parseExpressionOrLabelStatement):
1936
1937 2011-01-14  Simon Fraser  <simon.fraser@apple.com>
1938
1939         No review.
1940         
1941         Initialize m_operationInProgress after r75855.
1942
1943         * runtime/Heap.cpp:
1944         (JSC::Heap::Heap):
1945
1946 2011-01-14  Geoffrey Garen  <ggaren@apple.com>
1947
1948         Reverted accidentally committed code from my last checkin.
1949
1950         * runtime/Heap.cpp:
1951         (JSC::Heap::markRoots):
1952
1953 2011-01-14  Geoffrey Garen  <ggaren@apple.com>
1954
1955         Reviewed by Sam Weinig.
1956         
1957         Try to fix the GTK bot.
1958
1959         * runtime/Heap.cpp:
1960         (JSC::Heap::Heap):
1961         (JSC::Heap::markRoots): Kids, remember to initialize your data members.
1962         Knowing is half the battle.
1963
1964 2011-01-14  Oliver Hunt  <oliver@apple.com>
1965
1966         Reviewed by Stephanie Lewis.
1967
1968         [jsfunfuzz] We should be clearing the lexers temporary character buffers when switching to strict mode
1969         https://bugs.webkit.org/show_bug.cgi?id=52501
1970
1971         Clear the temporary character buffers used for reading escaped characters and
1972         numbers.
1973
1974         * parser/Lexer.h:
1975         (JSC::Lexer::setOffset):
1976
1977 2011-01-14  Geoffrey Garen  <ggaren@apple.com>
1978
1979         Try to fix non-Dtrace builds: #include Tracing.h instead of TracingDtrace.h.
1980
1981         * runtime/Heap.cpp:
1982
1983 2011-01-13  Geoffrey Garen  <ggaren@apple.com>
1984
1985         Reviewed by Oliver Hunt.
1986
1987         Split out a MarkedSpace strategy object from Heap.
1988         https://bugs.webkit.org/show_bug.cgi?id=52421
1989         
1990         SunSpider reports no change.
1991
1992         * Android.mk:
1993         * CMakeLists.txt:
1994         * GNUmakefile.am:
1995         * JavaScriptCore.gypi:
1996         * JavaScriptCore.pro:
1997         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
1998         * JavaScriptCore.xcodeproj/project.pbxproj: Updated our 7 build systems. Which is cool.
1999
2000         * runtime/Heap.cpp:
2001         (JSC::Heap::Heap):
2002         (JSC::Heap::destroy):
2003         (JSC::Heap::recordExtraCost):
2004         (JSC::Heap::allocate):
2005         (JSC::Heap::markConservatively):
2006         (JSC::Heap::markRoots):
2007         (JSC::Heap::objectCount):
2008         (JSC::Heap::statistics):
2009         (JSC::Heap::size):
2010         (JSC::Heap::isBusy):
2011         (JSC::Heap::collectAllGarbage):
2012         (JSC::Heap::primaryHeapBegin):
2013         (JSC::Heap::primaryHeapEnd):
2014         * runtime/Heap.h:
2015         (JSC::Heap::globalData):
2016         (JSC::Heap::markedSpace):
2017         (JSC::Heap::isCellMarked):
2018         (JSC::Heap::checkMarkCell):
2019         (JSC::Heap::markCell): Moved all code pertaining to managing chunks of
2020         collector memory out of this class. Heap now just delegates to MarkedSpace.
2021
2022         * runtime/JSCell.h:
2023         (JSC::JSCell::Heap::heap): Updated for MarkedSpace delegation.
2024
2025         * runtime/JSValue.h: Moved the ValueStringPair typedef to help with #includes.
2026
2027         * runtime/MarkedSpace.cpp: Copied from runtime/Heap.cpp.
2028         (JSC::MarkedSpace::MarkedSpace):
2029         (JSC::MarkedSpace::destroy):
2030         (JSC::MarkedSpace::allocateBlock):
2031         (JSC::MarkedSpace::freeBlock):
2032         (JSC::MarkedSpace::allocate):
2033         (JSC::MarkedSpace::resizeBlocks):
2034         (JSC::MarkedSpace::growBlocks):
2035         (JSC::MarkedSpace::shrinkBlocks):
2036         (JSC::MarkedSpace::markConservatively):
2037         (JSC::MarkedSpace::clearMarkBits):
2038         (JSC::MarkedSpace::markedCells):
2039         (JSC::MarkedSpace::sweep):
2040         (JSC::MarkedSpace::objectCount):
2041         (JSC::MarkedSpace::addToStatistics):
2042         (JSC::MarkedSpace::statistics):
2043         (JSC::MarkedSpace::size):
2044         (JSC::MarkedSpace::reset):
2045         (JSC::MarkedSpace::primaryHeapBegin):
2046         (JSC::MarkedSpace::primaryHeapEnd):
2047         * runtime/MarkedSpace.h: Copied from runtime/Heap.h.
2048         (JSC::MarkedSpace::globalData):
2049         (JSC::MarkedSpace::didShrink):
2050         (JSC::MarkedSpace::cellBlock):
2051         (JSC::MarkedSpace::cellOffset):
2052         (JSC::MarkedSpace::isCellMarked):
2053         (JSC::MarkedSpace::checkMarkCell):
2054         (JSC::MarkedSpace::markCell): Moved all code pertaining to managing chunks of
2055         collector memory into this class.
2056
2057         * runtime/MemoryStatistics.cpp:
2058         (JSC::heapStatistics):
2059         * runtime/MemoryStatistics.h: Updated for MarkedSpace delegation.
2060
2061 2011-01-14  Oliver Hunt  <oliver@apple.com>
2062
2063         Reviewed by Gavin Barraclough.
2064
2065         [jsfunfuzz] parser doesn't enforce continue restrictions correctly.
2066         https://bugs.webkit.org/show_bug.cgi?id=52493
2067
2068         This patch reworks handling of break, continue and label statements
2069         to correctly handle all the valid and invalid cases.  Previously certain
2070         errors would be missed by the parser in strict mode, but the bytecode 
2071         generator needed to handle those cases for non-strict code so nothing
2072         failed, it simply became non-standard behaviour.
2073
2074         Now that we treat break and continue errors as early faults in non-strict
2075         mode as well that safety net has been removed so the parser bugs result in
2076         crashes at codegen time.
2077
2078         * parser/JSParser.cpp:
2079         (JSC::JSParser::ScopeLabelInfo::ScopeLabelInfo):
2080         (JSC::JSParser::next):
2081         (JSC::JSParser::nextTokenIsColon):
2082         (JSC::JSParser::continueIsValid):
2083             Continue is only valid in loops so we can't use breakIsValid()
2084         (JSC::JSParser::pushLabel):
2085             We now track whether the label is for a loop (and is therefore a
2086             valid target for continue.
2087         (JSC::JSParser::popLabel):
2088         (JSC::JSParser::getLabel):
2089             Replace hasLabel with getLabel so that we can validate the target
2090             when parsing continue statements.
2091         (JSC::JSParser::Scope::continueIsValid):
2092         (JSC::JSParser::Scope::pushLabel):
2093         (JSC::JSParser::Scope::getLabel):
2094         (JSC::JSParser::JSParser):
2095         (JSC::JSParser::parseBreakStatement):
2096         (JSC::JSParser::parseContinueStatement):
2097         (JSC::LabelInfo::LabelInfo):
2098         (JSC::JSParser::parseExpressionOrLabelStatement):
2099             Consecutive labels now get handled iteratively so that we can determine
2100             whether they're valid targets for continue.
2101         * parser/Lexer.cpp:
2102         (JSC::Lexer::nextTokenIsColon):
2103         * parser/Lexer.h:
2104         (JSC::Lexer::setOffset):
2105
2106 2011-01-14  Patrick Gansterer  <paroga@webkit.org>
2107
2108         Reviewed by Adam Roben.
2109
2110         Use the Windows thread pool instead of an extra thread for FastMalloc scavenging
2111         https://bugs.webkit.org/show_bug.cgi?id=45186
2112
2113         * wtf/FastMalloc.cpp:
2114         (WTF::TCMalloc_PageHeap::scheduleScavenger): Added missing this pointer to CreateTimerQueueTimer().
2115
2116 2011-01-14  Patrick Gansterer  <paroga@webkit.org>
2117
2118         Reviewed by Adam Roben.
2119
2120         Use the Windows thread pool instead of an extra thread for FastMalloc scavenging
2121         https://bugs.webkit.org/show_bug.cgi?id=45186
2122
2123         r75819 accidentally changed the initial state of the scavenge timer.
2124
2125         * wtf/FastMalloc.cpp:
2126         (WTF::TCMalloc_PageHeap::initializeScavenger): Changed initial state of m_scavengingSuspended to true.
2127
2128 2011-01-14  Patrick Gansterer  <paroga@webkit.org>
2129
2130         Unreviewed Windows Release build fix.
2131
2132         * wtf/FastMalloc.cpp:
2133         (WTF::TCMalloc_PageHeap::scavengerTimerFired):
2134
2135 2011-01-14  Patrick Gansterer  <paroga@webkit.org>
2136
2137         Unreviewed Windows Release build fix.
2138
2139         * wtf/FastMalloc.cpp:
2140         (WTF::TCMalloc_PageHeap::scavengerTimerFired):
2141
2142 2011-01-14  Patrick Gansterer  <paroga@webkit.org>
2143
2144         Reviewed by Adam Roben.
2145
2146         Use the Windows thread pool instead of an extra thread for FastMalloc scavenging
2147         https://bugs.webkit.org/show_bug.cgi?id=45186
2148
2149         Use CreateTimerQueueTimer() to start periodicScavenge() and stop it with DeleteTimerQueueTimer().
2150
2151         * wtf/FastMalloc.cpp:
2152         (WTF::TCMalloc_PageHeap::initializeScavenger):
2153         (WTF::TCMalloc_PageHeap::isScavengerSuspended):
2154         (WTF::TCMalloc_PageHeap::scheduleScavenger):
2155         (WTF::TCMalloc_PageHeap::rescheduleScavenger):
2156         (WTF::TCMalloc_PageHeap::suspendScavenger):
2157         (WTF::scavengerTimerFired):
2158         (WTF::TCMalloc_PageHeap::periodicScavenge):
2159         (WTF::TCMalloc_PageHeap::signalScavenger):
2160
2161 2011-01-14  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2162
2163         Reviewed by Kenneth Rohde Christiansen.
2164
2165         Align import/export directives
2166         https://bugs.webkit.org/show_bug.cgi?id=52208
2167
2168         * API/JSBase.h: Align import/export directives with
2169         WebKit2/Shared/API/c/WKBase.h
2170
2171 2011-01-14  Michael Saboff  <msaboff@apple.com>
2172
2173         Reviewed by Oliver Hunt.
2174
2175         Incorrect backtracking for nested alternatives
2176         https://bugs.webkit.org/show_bug.cgi?id=52387
2177
2178         In the process of propigating a datalabel it wasn't getting connected
2179         to a destination when the destination was an indirect jump.  Added
2180         code to recognize a direct backtrack destination that was an indirect
2181         jump and added mechanism to associate DataLabelPtrs with indirect
2182         jump entries.
2183         Removed dead method
2184         BacktrackDestination::linkDataLabelToHereIfExists()
2185
2186         * yarr/YarrJIT.cpp:
2187         (JSC::Yarr::YarrGenerator::IndirectJumpEntry::IndirectJumpEntry):
2188         (JSC::Yarr::YarrGenerator::IndirectJumpEntry::addDataLabel):
2189         (JSC::Yarr::YarrGenerator::GenerationState::addIndirectJumpEntry):
2190         (JSC::Yarr::YarrGenerator::GenerationState::emitIndirectJumpTable):
2191         Changes to link indirect jumps with DataLabelPtr's.
2192         (JSC::Yarr::YarrGenerator::BacktrackDestination::clearSubDataLabelPtr):
2193         (JSC::Yarr::YarrGenerator::TermGenerationState::linkDataLabelToBacktrackIfExists): 
2194         Updated to handle immediate linking of indirect jumps to
2195         DataLabelPtr.
2196         (JSC::Yarr::YarrGenerator::generateParenthesesDisjunction): Changed to
2197         reflect updated linkDataLabelToBacktrackIfExists().
2198
2199 2011-01-14  Pavel Podivilov  <podivilov@chromium.org>
2200
2201         Reviewed by Yury Semikhatsky.
2202
2203         Web Inspector: provide script column offset to frontend.
2204         https://bugs.webkit.org/show_bug.cgi?id=52377
2205
2206         * parser/SourceCode.h:
2207         (JSC::SourceCode::SourceCode):
2208         (JSC::SourceCode::firstColumn):
2209
2210 2011-01-13  Darin Adler  <darin@apple.com>
2211
2212         Reviewed by Geoff Garen.
2213
2214         <rdar://problem/5469576> Use __PTK_FRAMEWORK_JAVASCRIPTCORE_KEY0 if available.
2215
2216         * DerivedSources.make: Create a header file, HeaderDetection.h, that tells
2217         us whether pthread_machdep.h is available.
2218         * wtf/FastMalloc.cpp: If __PTK_FRAMEWORK_JAVASCRIPTCORE_KEY0 is available, then
2219         don't do the pthread_getspecific_function_pointer trick.
2220         (WTF::setThreadHeap): Ditto, but set thread-specific data.
2221         (WTF::TCMalloc_ThreadCache::GetThreadHeap): Ditto, but get rather than set.
2222
2223 2011-01-13  Xan Lopez  <xlopez@igalia.com>
2224
2225         Reviewed by Gavin Barraclough.
2226
2227         JIT requires VM overcommit (particularly on x86-64), Linux does not by default support this without swap?
2228         https://bugs.webkit.org/show_bug.cgi?id=42756
2229
2230         The FixedVMPool Allocator does not work well on systems where
2231         allocating very large amounts of memory upfront is not reasonable,
2232         like Linux without overcommit enabled. As a workaround, on Linux,
2233         default to the values used in embedded environments (in the MB
2234         range), and only jump to the GB range if we detect at runtime that
2235         overcommit is enabled. Should fix crashes on Linux/x86_64 with
2236         less than 3 or 4GB of RAM.
2237
2238         * jit/ExecutableAllocatorFixedVMPool.cpp:
2239         (JSC::FixedVMPoolAllocator::free): use new variables for VM pool
2240         size and coalesce limit.
2241         (JSC::ExecutableAllocator::isValid): swap the variables from
2242         embedded to generic values at runtime, on linux, if overcommit is
2243         enabled.
2244         (JSC::ExecutableAllocator::underMemoryPressure): use new variables
2245         for VM pool size and coalesce limit.
2246
2247 2011-01-12  Xan Lopez  <xlopez@igalia.com>
2248
2249         Reviewed by Martin Robinson.
2250
2251         Add new Yarr.h header to the list file.
2252
2253         * GNUmakefile.am: ditto.
2254
2255 2011-01-12  Martin Robinson  <mrobinson@igalia.com>
2256
2257         Missing Source/JavaScriptCore/assembler/MacroAssemblerARMv7.h in WebKitGtk tarball
2258         https://bugs.webkit.org/show_bug.cgi?id=52299
2259
2260         * GNUmakefile.am: Fix the GTK+ build on ARMv7 by including missing source
2261         files in the source list.
2262
2263 2011-01-12  Peter Varga  <pvarga@webkit.org>
2264
2265         Reviewed by Gavin Barraclough.
2266
2267         Add Yarr.h to YARR
2268         https://bugs.webkit.org/show_bug.cgi?id=51021
2269
2270         Move other common constants and functions from YARR's different files
2271         to Yarr.h.
2272         Use Yarr.h header instead of including other YARR headers where it
2273         is possible.
2274
2275         * JavaScriptCore.gypi:
2276         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
2277         * JavaScriptCore.xcodeproj/project.pbxproj:
2278         * runtime/RegExp.cpp:
2279         * yarr/Yarr.h: Added.
2280         * yarr/YarrInterpreter.cpp:
2281         * yarr/YarrInterpreter.h:
2282         * yarr/YarrJIT.cpp:
2283         (JSC::Yarr::jitCompile):
2284         (JSC::Yarr::execute):
2285         * yarr/YarrJIT.h:
2286         * yarr/YarrParser.h:
2287         * yarr/YarrPattern.cpp:
2288         (JSC::Yarr::YarrPattern::compile):
2289         (JSC::Yarr::YarrPattern::YarrPattern):
2290         * yarr/YarrPattern.h:
2291
2292 2011-01-12  Sheriff Bot  <webkit.review.bot@gmail.com>
2293
2294         Unreviewed, rolling out r75595.
2295         http://trac.webkit.org/changeset/75595
2296         https://bugs.webkit.org/show_bug.cgi?id=52286
2297
2298         It broke fast/regex/pcre-test-1.html (Requested by Ossy on
2299         #webkit).
2300
2301         * JavaScriptCore.gypi:
2302         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
2303         * JavaScriptCore.xcodeproj/project.pbxproj:
2304         * runtime/RegExp.cpp:
2305         * yarr/Yarr.h: Removed.
2306         * yarr/YarrInterpreter.cpp:
2307         * yarr/YarrInterpreter.h:
2308         * yarr/YarrJIT.cpp:
2309         (JSC::Yarr::jitCompile):
2310         * yarr/YarrJIT.h:
2311         (JSC::Yarr::execute):
2312         * yarr/YarrParser.h:
2313         * yarr/YarrPattern.cpp:
2314         (JSC::Yarr::compile):
2315         (JSC::Yarr::YarrPattern::YarrPattern):
2316         * yarr/YarrPattern.h:
2317
2318 2011-01-12  Peter Varga  <pvarga@webkit.org>
2319
2320         Reviewed by Gavin Barraclough.
2321
2322         Add Yarr.h to YARR
2323         https://bugs.webkit.org/show_bug.cgi?id=51021
2324
2325         Move other common constants and functions from YARR's different files
2326         to Yarr.h.
2327         Use Yarr.h header instead of including other YARR headers where it
2328         is possible.
2329
2330         * JavaScriptCore.gypi:
2331         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
2332         * JavaScriptCore.xcodeproj/project.pbxproj:
2333         * runtime/RegExp.cpp:
2334         * yarr/Yarr.h: Added.
2335         * yarr/YarrInterpreter.cpp:
2336         * yarr/YarrInterpreter.h:
2337         * yarr/YarrJIT.cpp:
2338         (JSC::Yarr::jitCompile):
2339         (JSC::Yarr::execute):
2340         * yarr/YarrJIT.h:
2341         * yarr/YarrParser.h:
2342         * yarr/YarrPattern.cpp:
2343         (JSC::Yarr::YarrPattern::compile):
2344         (JSC::Yarr::YarrPattern::YarrPattern):
2345         * yarr/YarrPattern.h:
2346
2347 2011-01-11  Michael Saboff  <msaboff@apple.com>
2348
2349         Reviewed by Geoffrey Garen.
2350
2351         Missing call to popTempSortVector() for exception case in JSArray::sort.
2352         https://bugs.webkit.org/show_bug.cgi?id=50718
2353
2354         Fix to patch of 50718 that added pushTempSortVector() and 
2355         popTempSortVector() to JSArray::sort() to mark elements during sort.
2356         Need to add popTempSortVector() for the return case if toString()
2357         had an exception.
2358
2359         * runtime/JSArray.cpp:
2360         (JSC::JSArray::sort): Added popTempSortVector()
2361
2362 2011-01-11  Xan Lopez  <xlopez@igalia.com>
2363
2364         Reviewed by Darin Adler.
2365
2366         Microoptimization in ~JSString
2367         https://bugs.webkit.org/show_bug.cgi?id=52222
2368
2369         The case where m_fibers is 0 seems to be the most common one
2370         (almost 1/2 of the time, followed at some distance by m_fibers = 1
2371         in 1/4 of the cases in a typical SunSpider execution). We can save
2372         one comparison in this common case by doing a bit of refactoring
2373         in the JSString destructor; overall a 0.3% progression, but only
2374         the string tests show improvement.
2375
2376         * runtime/JSString.h:
2377         (JSC::RopeBuilder::~JSString):
2378
2379 2011-01-10  Michael Saboff  <msaboff@apple.com>
2380
2381         Reviewed by Geoffrey Garen.
2382
2383         ASSERTION Failure in JSC::binaryChop
2384         https://bugs.webkit.org/show_bug.cgi?id=25614
2385
2386         Changed JITStubs::cti_register_file_check() to use the current stack's
2387         return PC to find the bytecode for handling the exception in the prior
2388         frame.  Also added the appropriate arrity check routine call to the
2389         JIT to bytecode vector (m_callReturnIndexVector) in the CodeBlock.
2390
2391         * jit/JIT.cpp:
2392         (JSC::JIT::privateCompile): Changed the arrity check call location
2393         so that it gets added to the m_calls list so that it's included in
2394         CodeBlock::m_callReturnIndexVector.
2395         * jit/JITStubs.cpp:
2396         (JSC::DEFINE_STUB_FUNCTION): Use the current call frame's return PC.
2397
2398 2011-01-10  Daniel Bates  <dbates@rim.com>
2399
2400         Reviewed by Martin Robinson.
2401
2402         Remove extraneous COMPILER(GCC) condition when checking GCC_VERSION_AT_LEAST()
2403         https://bugs.webkit.org/show_bug.cgi?id=52178
2404
2405         It is sufficient to test GCC_VERSION_AT_LEAST() instead of both COMPILER(GCC) and
2406         GCC_VERSION_AT_LEAST(). Notice GCC_VERSION_AT_LEAST() is defined to be 0 when we
2407         are not compiling with GCC.
2408
2409         Fixes style issues at the callsites (i.e. replace comma with comma-space in
2410         macro function argument list). Also, makes a spelling correction in a comment.
2411
2412         * jit/ExecutableAllocator.h:
2413         (JSC::ExecutableAllocator::cacheFlush):
2414         * wtf/Platform.h:
2415
2416 2011-01-10  Geoffrey Garen  <ggaren@apple.com>
2417
2418         Build fix: removed some uses of nextNumber that I missed last time.
2419
2420         * runtime/Heap.cpp:
2421         (JSC::Heap::reset):
2422         (JSC::Heap::collectAllGarbage):
2423
2424 2011-01-10  Daniel Bates  <dbates@rim.com>
2425
2426         Reviewed by Darin Adler.
2427
2428         Use __builtin_expect when compiling using RVCT in GNU mode
2429         https://bugs.webkit.org/show_bug.cgi?id=51866
2430
2431         We should only use __builtin_expect if we are compiling with GCC or RVCT 3 or higher in GNU mode
2432         as pointed out by Siddharth Mathur per <http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0202h/Cjabddedbde.html>.
2433
2434         * wtf/AlwaysInline.h:
2435         * wtf/Platform.h: Removed define WTF_COMPILER_RVCT4_OR_GREATER. Instead added macro
2436         function RVCT_VERSION_AT_LEAST so that we can test for an arbitrary minimum RVCT
2437         version.
2438
2439 2011-01-10  Geoffrey Garen  <ggaren@apple.com>
2440
2441         Reviewed by Oliver Hunt.
2442
2443         Moved Collector.* => Heap.*, since the file contains a class named "Heap".
2444
2445         * API/JSCallbackObject.cpp:
2446         * Android.mk:
2447         * CMakeLists.txt:
2448         * GNUmakefile.am:
2449         * JavaScriptCore.gypi:
2450         * JavaScriptCore.pro:
2451         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
2452         * JavaScriptCore.xcodeproj/project.pbxproj:
2453         * interpreter/Interpreter.cpp:
2454         * interpreter/RegisterFile.h:
2455         * jit/JITStubs.cpp:
2456         * runtime/Collector.cpp: Removed.
2457         * runtime/Collector.h: Removed.
2458         * runtime/CollectorHeapIterator.h:
2459         * runtime/GCActivityCallbackCF.cpp:
2460         * runtime/Heap.cpp: Copied from JavaScriptCore/runtime/Collector.cpp.
2461         * runtime/Heap.h: Copied from JavaScriptCore/runtime/Collector.h.
2462         * runtime/InitializeThreading.cpp:
2463         * runtime/JSCell.h:
2464         * runtime/JSGlobalData.cpp:
2465         * runtime/JSGlobalData.h:
2466         * runtime/JSLock.cpp:
2467         * runtime/JSNumberCell.h:
2468         * runtime/MachineStackMarker.cpp:
2469         * runtime/MemoryStatistics.h:
2470         * runtime/Protect.h:
2471         * runtime/UString.cpp:
2472         * runtime/WeakGCMap.h:
2473         * runtime/WeakGCPtr.h:
2474
2475 2011-01-10  Xan Lopez  <xlopez@igalia.com>
2476
2477         Reviewed by Gavin Barraclough.
2478
2479         Remove unused isString() case in JSString::toPrimitiveString()
2480         https://bugs.webkit.org/show_bug.cgi?id=52167
2481
2482         We never call toPrimitiveString() with strings, so remove the
2483         check and add an ASSERT ensuring this never happens. 0.7% overall
2484         progression in sunspider, since one of the call sites is very hot.
2485
2486         * runtime/JSString.h:
2487         (JSC::JSValue::toPrimitiveString):
2488
2489 2011-01-10  Peter Varga  <pvarga@inf.u-szeged.hu>
2490
2491         Reviewed by Gavin Barraclough.
2492
2493         Rename the existing YARR files and classes
2494         https://bugs.webkit.org/show_bug.cgi?id=51872
2495
2496         Replace the "Regex" prefix with "Yarr" in the name of YARR files and classes.
2497
2498         * Android.mk:
2499         * CMakeLists.txt:
2500         * GNUmakefile.am:
2501         * JavaScriptCore.gypi:
2502         * JavaScriptCore.pro:
2503         * JavaScriptCore.xcodeproj/project.pbxproj:
2504         * runtime/RegExp.cpp:
2505         (JSC::RegExp::compile):
2506         (JSC::RegExp::match):
2507         (JSC::RegExp::printTraceData):
2508         * yarr/YarrInterpreter.cpp: Renamed from Source/JavaScriptCore/yarr/RegexInterpreter.cpp.
2509         (JSC::Yarr::Interpreter::appendParenthesesDisjunctionContext):
2510         (JSC::Yarr::Interpreter::popParenthesesDisjunctionContext):
2511         (JSC::Yarr::Interpreter::DisjunctionContext::DisjunctionContext):
2512         (JSC::Yarr::Interpreter::DisjunctionContext::operator new):
2513         (JSC::Yarr::Interpreter::allocDisjunctionContext):
2514         (JSC::Yarr::Interpreter::freeDisjunctionContext):
2515         (JSC::Yarr::Interpreter::ParenthesesDisjunctionContext::ParenthesesDisjunctionContext):
2516         (JSC::Yarr::Interpreter::ParenthesesDisjunctionContext::operator new):
2517         (JSC::Yarr::Interpreter::ParenthesesDisjunctionContext::restoreOutput):
2518         (JSC::Yarr::Interpreter::ParenthesesDisjunctionContext::getDisjunctionContext):
2519         (JSC::Yarr::Interpreter::allocParenthesesDisjunctionContext):
2520         (JSC::Yarr::Interpreter::freeParenthesesDisjunctionContext):
2521         (JSC::Yarr::Interpreter::InputStream::InputStream):
2522         (JSC::Yarr::Interpreter::InputStream::next):
2523         (JSC::Yarr::Interpreter::InputStream::rewind):
2524         (JSC::Yarr::Interpreter::InputStream::read):
2525         (JSC::Yarr::Interpreter::InputStream::readPair):
2526         (JSC::Yarr::Interpreter::InputStream::readChecked):
2527         (JSC::Yarr::Interpreter::InputStream::reread):
2528         (JSC::Yarr::Interpreter::InputStream::prev):
2529         (JSC::Yarr::Interpreter::InputStream::getPos):
2530         (JSC::Yarr::Interpreter::InputStream::setPos):
2531         (JSC::Yarr::Interpreter::InputStream::atStart):
2532         (JSC::Yarr::Interpreter::InputStream::atEnd):
2533         (JSC::Yarr::Interpreter::InputStream::checkInput):
2534         (JSC::Yarr::Interpreter::InputStream::uncheckInput):
2535         (JSC::Yarr::Interpreter::InputStream::isNotAvailableInput):
2536         (JSC::Yarr::Interpreter::testCharacterClass):
2537         (JSC::Yarr::Interpreter::checkCharacter):
2538         (JSC::Yarr::Interpreter::checkCasedCharacter):
2539         (JSC::Yarr::Interpreter::checkCharacterClass):
2540         (JSC::Yarr::Interpreter::tryConsumeBackReference):
2541         (JSC::Yarr::Interpreter::matchAssertionBOL):
2542         (JSC::Yarr::Interpreter::matchAssertionEOL):
2543         (JSC::Yarr::Interpreter::matchAssertionWordBoundary):
2544         (JSC::Yarr::Interpreter::backtrackPatternCharacter):
2545         (JSC::Yarr::Interpreter::backtrackPatternCasedCharacter):
2546         (JSC::Yarr::Interpreter::matchCharacterClass):
2547         (JSC::Yarr::Interpreter::backtrackCharacterClass):
2548         (JSC::Yarr::Interpreter::matchBackReference):
2549         (JSC::Yarr::Interpreter::backtrackBackReference):
2550         (JSC::Yarr::Interpreter::recordParenthesesMatch):
2551         (JSC::Yarr::Interpreter::resetMatches):
2552         (JSC::Yarr::Interpreter::parenthesesDoBacktrack):
2553         (JSC::Yarr::Interpreter::matchParenthesesOnceBegin):
2554         (JSC::Yarr::Interpreter::matchParenthesesOnceEnd):
2555         (JSC::Yarr::Interpreter::backtrackParenthesesOnceBegin):
2556         (JSC::Yarr::Interpreter::backtrackParenthesesOnceEnd):
2557         (JSC::Yarr::Interpreter::matchParenthesesTerminalBegin):
2558         (JSC::Yarr::Interpreter::matchParenthesesTerminalEnd):
2559         (JSC::Yarr::Interpreter::backtrackParenthesesTerminalBegin):
2560         (JSC::Yarr::Interpreter::backtrackParenthesesTerminalEnd):
2561         (JSC::Yarr::Interpreter::matchParentheticalAssertionBegin):
2562         (JSC::Yarr::Interpreter::matchParentheticalAssertionEnd):
2563         (JSC::Yarr::Interpreter::backtrackParentheticalAssertionBegin):
2564         (JSC::Yarr::Interpreter::backtrackParentheticalAssertionEnd):
2565         (JSC::Yarr::Interpreter::matchParentheses):
2566         (JSC::Yarr::Interpreter::backtrackParentheses):
2567         (JSC::Yarr::Interpreter::lookupForBeginChars):
2568         (JSC::Yarr::Interpreter::matchDisjunction):
2569         (JSC::Yarr::Interpreter::matchNonZeroDisjunction):
2570         (JSC::Yarr::Interpreter::interpret):
2571         (JSC::Yarr::Interpreter::Interpreter):
2572         (JSC::Yarr::ByteCompiler::ParenthesesStackEntry::ParenthesesStackEntry):
2573         (JSC::Yarr::ByteCompiler::ByteCompiler):
2574         (JSC::Yarr::ByteCompiler::compile):
2575         (JSC::Yarr::ByteCompiler::checkInput):
2576         (JSC::Yarr::ByteCompiler::assertionBOL):
2577         (JSC::Yarr::ByteCompiler::assertionEOL):
2578         (JSC::Yarr::ByteCompiler::assertionWordBoundary):
2579         (JSC::Yarr::ByteCompiler::atomPatternCharacter):
2580         (JSC::Yarr::ByteCompiler::atomCharacterClass):
2581         (JSC::Yarr::ByteCompiler::atomBackReference):
2582         (JSC::Yarr::ByteCompiler::atomParenthesesOnceBegin):
2583         (JSC::Yarr::ByteCompiler::atomParenthesesTerminalBegin):
2584         (JSC::Yarr::ByteCompiler::atomParenthesesSubpatternBegin):
2585         (JSC::Yarr::ByteCompiler::atomParentheticalAssertionBegin):
2586         (JSC::Yarr::ByteCompiler::atomParentheticalAssertionEnd):
2587         (JSC::Yarr::ByteCompiler::popParenthesesStack):
2588         (JSC::Yarr::ByteCompiler::dumpDisjunction):
2589         (JSC::Yarr::ByteCompiler::closeAlternative):
2590         (JSC::Yarr::ByteCompiler::closeBodyAlternative):
2591         (JSC::Yarr::ByteCompiler::atomParenthesesSubpatternEnd):
2592         (JSC::Yarr::ByteCompiler::atomParenthesesOnceEnd):
2593         (JSC::Yarr::ByteCompiler::atomParenthesesTerminalEnd):
2594         (JSC::Yarr::ByteCompiler::regexBegin):
2595         (JSC::Yarr::ByteCompiler::regexEnd):
2596         (JSC::Yarr::ByteCompiler::alternativeBodyDisjunction):
2597         (JSC::Yarr::ByteCompiler::alternativeDisjunction):
2598         (JSC::Yarr::ByteCompiler::emitDisjunction):
2599         (JSC::Yarr::byteCompile):
2600         (JSC::Yarr::interpret):
2601         * yarr/YarrInterpreter.h: Renamed from Source/JavaScriptCore/yarr/RegexInterpreter.h.
2602         (JSC::Yarr::ByteTerm::ByteTerm):
2603         (JSC::Yarr::ByteTerm::BOL):
2604         (JSC::Yarr::ByteTerm::CheckInput):
2605         (JSC::Yarr::ByteTerm::EOL):
2606         (JSC::Yarr::ByteTerm::WordBoundary):
2607         (JSC::Yarr::ByteTerm::BackReference):
2608         (JSC::Yarr::ByteTerm::BodyAlternativeBegin):
2609         (JSC::Yarr::ByteTerm::BodyAlternativeDisjunction):
2610         (JSC::Yarr::ByteTerm::BodyAlternativeEnd):
2611         (JSC::Yarr::ByteTerm::AlternativeBegin):
2612         (JSC::Yarr::ByteTerm::AlternativeDisjunction):
2613         (JSC::Yarr::ByteTerm::AlternativeEnd):
2614         (JSC::Yarr::ByteTerm::SubpatternBegin):
2615         (JSC::Yarr::ByteTerm::SubpatternEnd):
2616         (JSC::Yarr::ByteTerm::invert):
2617         (JSC::Yarr::ByteTerm::capture):
2618         (JSC::Yarr::ByteDisjunction::ByteDisjunction):
2619         (JSC::Yarr::BytecodePattern::BytecodePattern):
2620         (JSC::Yarr::BytecodePattern::~BytecodePattern):
2621         * yarr/YarrJIT.cpp: Renamed from Source/JavaScriptCore/yarr/RegexJIT.cpp.
2622         (JSC::Yarr::YarrGenerator::optimizeAlternative):
2623         (JSC::Yarr::YarrGenerator::matchCharacterClassRange):
2624         (JSC::Yarr::YarrGenerator::matchCharacterClass):
2625         (JSC::Yarr::YarrGenerator::jumpIfNoAvailableInput):
2626         (JSC::Yarr::YarrGenerator::jumpIfAvailableInput):
2627         (JSC::Yarr::YarrGenerator::checkInput):
2628         (JSC::Yarr::YarrGenerator::atEndOfInput):
2629         (JSC::Yarr::YarrGenerator::notAtEndOfInput):
2630         (JSC::Yarr::YarrGenerator::jumpIfCharEquals):
2631         (JSC::Yarr::YarrGenerator::jumpIfCharNotEquals):
2632         (JSC::Yarr::YarrGenerator::readCharacter):
2633         (JSC::Yarr::YarrGenerator::storeToFrame):
2634         (JSC::Yarr::YarrGenerator::storeToFrameWithPatch):
2635         (JSC::Yarr::YarrGenerator::loadFromFrame):
2636         (JSC::Yarr::YarrGenerator::loadFromFrameAndJump):
2637         (JSC::Yarr::YarrGenerator::IndirectJumpEntry::IndirectJumpEntry):
2638         (JSC::Yarr::YarrGenerator::IndirectJumpEntry::addJump):
2639         (JSC::Yarr::YarrGenerator::AlternativeBacktrackRecord::AlternativeBacktrackRecord):
2640         (JSC::Yarr::YarrGenerator::GenerationState::GenerationState):
2641         (JSC::Yarr::YarrGenerator::GenerationState::addIndirectJumpEntry):
2642         (JSC::Yarr::YarrGenerator::GenerationState::emitIndirectJumpTable):
2643         (JSC::Yarr::YarrGenerator::GenerationState::incrementParenNestingLevel):
2644         (JSC::Yarr::YarrGenerator::GenerationState::decrementParenNestingLevel):
2645         (JSC::Yarr::YarrGenerator::GenerationState::addParenthesesTail):
2646         (JSC::Yarr::YarrGenerator::GenerationState::emitParenthesesTail):
2647         (JSC::Yarr::YarrGenerator::GenerationState::addJumpToNextInteration):
2648         (JSC::Yarr::YarrGenerator::GenerationState::addJumpsToNextInteration):
2649         (JSC::Yarr::YarrGenerator::GenerationState::addDataLabelToNextIteration):
2650         (JSC::Yarr::YarrGenerator::GenerationState::linkToNextIteration):
2651         (JSC::Yarr::YarrGenerator::BacktrackDestination::BacktrackDestination):
2652         (JSC::Yarr::YarrGenerator::BacktrackDestination::clear):
2653         (JSC::Yarr::YarrGenerator::BacktrackDestination::clearDataLabel):
2654         (JSC::Yarr::YarrGenerator::BacktrackDestination::hasDestination):
2655         (JSC::Yarr::YarrGenerator::BacktrackDestination::isStackOffset):
2656         (JSC::Yarr::YarrGenerator::BacktrackDestination::isLabel):
2657         (JSC::Yarr::YarrGenerator::BacktrackDestination::isJumpList):
2658         (JSC::Yarr::YarrGenerator::BacktrackDestination::hasDataLabel):
2659         (JSC::Yarr::YarrGenerator::BacktrackDestination::copyTarget):
2660         (JSC::Yarr::YarrGenerator::BacktrackDestination::copyTo):
2661         (JSC::Yarr::YarrGenerator::BacktrackDestination::addBacktrackJump):
2662         (JSC::Yarr::YarrGenerator::BacktrackDestination::setStackOffset):
2663         (JSC::Yarr::YarrGenerator::BacktrackDestination::setLabel):
2664         (JSC::Yarr::YarrGenerator::BacktrackDestination::setNextBacktrackLabel):
2665         (JSC::Yarr::YarrGenerator::BacktrackDestination::copyBacktrackToLabel):
2666         (JSC::Yarr::YarrGenerator::BacktrackDestination::setBacktrackToLabel):
2667         (JSC::Yarr::YarrGenerator::BacktrackDestination::setBacktrackJumpList):
2668         (JSC::Yarr::YarrGenerator::BacktrackDestination::setBacktrackSourceLabel):
2669         (JSC::Yarr::YarrGenerator::BacktrackDestination::setDataLabel):
2670         (JSC::Yarr::YarrGenerator::BacktrackDestination::setSubDataLabelPtr):
2671         (JSC::Yarr::YarrGenerator::BacktrackDestination::linkToNextBacktrack):
2672         (JSC::Yarr::YarrGenerator::BacktrackDestination::getStackOffset):
2673         (JSC::Yarr::YarrGenerator::BacktrackDestination::getLabel):
2674         (JSC::Yarr::YarrGenerator::BacktrackDestination::getBacktrackJumps):
2675         (JSC::Yarr::YarrGenerator::BacktrackDestination::getDataLabel):
2676         (JSC::Yarr::YarrGenerator::BacktrackDestination::jumpToBacktrack):
2677         (JSC::Yarr::YarrGenerator::BacktrackDestination::linkDataLabelToHereIfExists):
2678         (JSC::Yarr::YarrGenerator::BacktrackDestination::plantJumpToBacktrackIfExists):
2679         (JSC::Yarr::YarrGenerator::BacktrackDestination::linkAlternativeBacktracks):
2680         (JSC::Yarr::YarrGenerator::BacktrackDestination::linkAlternativeBacktracksTo):
2681         (JSC::Yarr::YarrGenerator::TermGenerationState::TermGenerationState):
2682         (JSC::Yarr::YarrGenerator::TermGenerationState::resetAlternative):
2683         (JSC::Yarr::YarrGenerator::TermGenerationState::alternativeValid):
2684         (JSC::Yarr::YarrGenerator::TermGenerationState::nextAlternative):
2685         (JSC::Yarr::YarrGenerator::TermGenerationState::alternative):
2686         (JSC::Yarr::YarrGenerator::TermGenerationState::isLastAlternative):
2687         (JSC::Yarr::YarrGenerator::TermGenerationState::resetTerm):
2688         (JSC::Yarr::YarrGenerator::TermGenerationState::termValid):
2689         (JSC::Yarr::YarrGenerator::TermGenerationState::nextTerm):
2690         (JSC::Yarr::YarrGenerator::TermGenerationState::term):
2691         (JSC::Yarr::YarrGenerator::TermGenerationState::isLastTerm):
2692         (JSC::Yarr::YarrGenerator::TermGenerationState::getSubParenNum):
2693         (JSC::Yarr::YarrGenerator::TermGenerationState::isMainDisjunction):
2694         (JSC::Yarr::YarrGenerator::TermGenerationState::setParenthesesTail):
2695         (JSC::Yarr::YarrGenerator::TermGenerationState::getParenthesesTail):
2696         (JSC::Yarr::YarrGenerator::TermGenerationState::lookaheadTerm):
2697         (JSC::Yarr::YarrGenerator::TermGenerationState::isSinglePatternCharacterLookaheadTerm):
2698         (JSC::Yarr::YarrGenerator::TermGenerationState::inputOffset):
2699         (JSC::Yarr::YarrGenerator::TermGenerationState::clearBacktrack):
2700         (JSC::Yarr::YarrGenerator::TermGenerationState::jumpToBacktrack):
2701         (JSC::Yarr::YarrGenerator::TermGenerationState::plantJumpToBacktrackIfExists):
2702         (JSC::Yarr::YarrGenerator::TermGenerationState::linkDataLabelToBacktrackIfExists):
2703         (JSC::Yarr::YarrGenerator::TermGenerationState::addBacktrackJump):
2704         (JSC::Yarr::YarrGenerator::TermGenerationState::setBacktrackDataLabel):
2705         (JSC::Yarr::YarrGenerator::TermGenerationState::setBackTrackStackOffset):
2706         (JSC::Yarr::YarrGenerator::TermGenerationState::setBacktrackLabel):
2707         (JSC::Yarr::YarrGenerator::TermGenerationState::linkAlternativeBacktracks):
2708         (JSC::Yarr::YarrGenerator::TermGenerationState::linkAlternativeBacktracksTo):
2709         (JSC::Yarr::YarrGenerator::TermGenerationState::setBacktrackLink):
2710         (JSC::Yarr::YarrGenerator::TermGenerationState::chainBacktracks):
2711         (JSC::Yarr::YarrGenerator::TermGenerationState::chainBacktrackJumps):
2712         (JSC::Yarr::YarrGenerator::TermGenerationState::getBacktrackDestination):
2713         (JSC::Yarr::YarrGenerator::TermGenerationState::propagateBacktrackingFrom):
2714         (JSC::Yarr::YarrGenerator::ParenthesesTail::ParenthesesTail):
2715         (JSC::Yarr::YarrGenerator::ParenthesesTail::processBacktracks):
2716         (JSC::Yarr::YarrGenerator::ParenthesesTail::setNextIteration):
2717         (JSC::Yarr::YarrGenerator::ParenthesesTail::addAfterParenJump):
2718         (JSC::Yarr::YarrGenerator::ParenthesesTail::generateCode):
2719         (JSC::Yarr::YarrGenerator::generateAssertionBOL):
2720         (JSC::Yarr::YarrGenerator::generateAssertionEOL):
2721         (JSC::Yarr::YarrGenerator::matchAssertionWordchar):
2722         (JSC::Yarr::YarrGenerator::generateAssertionWordBoundary):
2723         (JSC::Yarr::YarrGenerator::generatePatternCharacterSingle):
2724         (JSC::Yarr::YarrGenerator::generatePatternCharacterPair):
2725         (JSC::Yarr::YarrGenerator::generatePatternCharacterFixed):
2726         (JSC::Yarr::YarrGenerator::generatePatternCharacterGreedy):
2727         (JSC::Yarr::YarrGenerator::generatePatternCharacterNonGreedy):
2728         (JSC::Yarr::YarrGenerator::generateCharacterClassSingle):
2729         (JSC::Yarr::YarrGenerator::generateCharacterClassFixed):
2730         (JSC::Yarr::YarrGenerator::generateCharacterClassGreedy):
2731         (JSC::Yarr::YarrGenerator::generateCharacterClassNonGreedy):
2732         (JSC::Yarr::YarrGenerator::generateParenthesesDisjunction):
2733         (JSC::Yarr::YarrGenerator::generateParenthesesSingle):
2734         (JSC::Yarr::YarrGenerator::generateParenthesesGreedyNoBacktrack):
2735         (JSC::Yarr::YarrGenerator::generateParentheticalAssertion):
2736         (JSC::Yarr::YarrGenerator::generateTerm):
2737         (JSC::Yarr::YarrGenerator::generateDisjunction):
2738         (JSC::Yarr::YarrGenerator::generateEnter):
2739         (JSC::Yarr::YarrGenerator::generateReturn):
2740         (JSC::Yarr::YarrGenerator::YarrGenerator):
2741         (JSC::Yarr::YarrGenerator::generate):
2742         (JSC::Yarr::YarrGenerator::compile):
2743         (JSC::Yarr::jitCompile):
2744         * yarr/YarrJIT.h: Renamed from Source/JavaScriptCore/yarr/RegexJIT.h.
2745         (JSC::Yarr::YarrCodeBlock::YarrCodeBlock):
2746         (JSC::Yarr::YarrCodeBlock::~YarrCodeBlock):
2747         (JSC::Yarr::YarrCodeBlock::setFallBack):
2748         (JSC::Yarr::YarrCodeBlock::isFallBack):
2749         (JSC::Yarr::YarrCodeBlock::set):
2750         (JSC::Yarr::YarrCodeBlock::execute):
2751         (JSC::Yarr::YarrCodeBlock::getAddr):
2752         (JSC::Yarr::execute):
2753         * yarr/YarrParser.h: Renamed from Source/JavaScriptCore/yarr/RegexParser.h.
2754         (JSC::Yarr::Parser::CharacterClassParserDelegate::CharacterClassParserDelegate):
2755         (JSC::Yarr::Parser::CharacterClassParserDelegate::begin):
2756         (JSC::Yarr::Parser::CharacterClassParserDelegate::atomPatternCharacter):
2757         (JSC::Yarr::Parser::CharacterClassParserDelegate::atomBuiltInCharacterClass):
2758         (JSC::Yarr::Parser::CharacterClassParserDelegate::end):
2759         (JSC::Yarr::Parser::CharacterClassParserDelegate::assertionWordBoundary):
2760         (JSC::Yarr::Parser::CharacterClassParserDelegate::atomBackReference):
2761         (JSC::Yarr::Parser::Parser):
2762         (JSC::Yarr::Parser::parseEscape):
2763         (JSC::Yarr::Parser::parseAtomEscape):
2764         (JSC::Yarr::Parser::parseCharacterClassEscape):
2765         (JSC::Yarr::Parser::parseCharacterClass):
2766         (JSC::Yarr::Parser::parseParenthesesBegin):
2767         (JSC::Yarr::Parser::parseParenthesesEnd):
2768         (JSC::Yarr::Parser::parseQuantifier):
2769         (JSC::Yarr::Parser::parseTokens):
2770         (JSC::Yarr::Parser::parse):
2771         (JSC::Yarr::Parser::saveState):
2772         (JSC::Yarr::Parser::restoreState):
2773         (JSC::Yarr::Parser::atEndOfPattern):
2774         (JSC::Yarr::Parser::peek):
2775         (JSC::Yarr::Parser::peekIsDigit):
2776         (JSC::Yarr::Parser::peekDigit):
2777         (JSC::Yarr::Parser::consume):
2778         (JSC::Yarr::Parser::consumeDigit):
2779         (JSC::Yarr::Parser::consumeNumber):
2780         (JSC::Yarr::Parser::consumeOctal):
2781         (JSC::Yarr::Parser::tryConsume):
2782         (JSC::Yarr::Parser::tryConsumeHex):
2783         (JSC::Yarr::parse):
2784         * yarr/YarrPattern.cpp: Renamed from Source/JavaScriptCore/yarr/RegexPattern.cpp.
2785         (JSC::Yarr::CharacterClassConstructor::CharacterClassConstructor):
2786         (JSC::Yarr::CharacterClassConstructor::reset):
2787         (JSC::Yarr::CharacterClassConstructor::append):
2788         (JSC::Yarr::CharacterClassConstructor::putChar):
2789         (JSC::Yarr::CharacterClassConstructor::isUnicodeUpper):
2790         (JSC::Yarr::CharacterClassConstructor::isUnicodeLower):
2791         (JSC::Yarr::CharacterClassConstructor::putRange):
2792         (JSC::Yarr::CharacterClassConstructor::charClass):
2793         (JSC::Yarr::CharacterClassConstructor::addSorted):
2794         (JSC::Yarr::CharacterClassConstructor::addSortedRange):
2795         (JSC::Yarr::BeginCharHelper::BeginCharHelper):
2796         (JSC::Yarr::BeginCharHelper::addBeginChar):
2797         (JSC::Yarr::BeginCharHelper::merge):
2798         (JSC::Yarr::BeginCharHelper::addCharacter):
2799         (JSC::Yarr::BeginCharHelper::linkHotTerms):
2800         (JSC::Yarr::YarrPatternConstructor::YarrPatternConstructor):
2801         (JSC::Yarr::YarrPatternConstructor::~YarrPatternConstructor):
2802         (JSC::Yarr::YarrPatternConstructor::reset):
2803         (JSC::Yarr::YarrPatternConstructor::assertionBOL):
2804         (JSC::Yarr::YarrPatternConstructor::assertionEOL):
2805         (JSC::Yarr::YarrPatternConstructor::assertionWordBoundary):
2806         (JSC::Yarr::YarrPatternConstructor::atomPatternCharacter):
2807         (JSC::Yarr::YarrPatternConstructor::atomBuiltInCharacterClass):
2808         (JSC::Yarr::YarrPatternConstructor::atomCharacterClassBegin):
2809         (JSC::Yarr::YarrPatternConstructor::atomCharacterClassAtom):
2810         (JSC::Yarr::YarrPatternConstructor::atomCharacterClassRange):
2811         (JSC::Yarr::YarrPatternConstructor::atomCharacterClassBuiltIn):
2812         (JSC::Yarr::YarrPatternConstructor::atomCharacterClassEnd):
2813         (JSC::Yarr::YarrPatternConstructor::atomParenthesesSubpatternBegin):
2814         (JSC::Yarr::YarrPatternConstructor::atomParentheticalAssertionBegin):
2815         (JSC::Yarr::YarrPatternConstructor::atomParenthesesEnd):
2816         (JSC::Yarr::YarrPatternConstructor::atomBackReference):
2817         (JSC::Yarr::YarrPatternConstructor::copyDisjunction):
2818         (JSC::Yarr::YarrPatternConstructor::copyTerm):
2819         (JSC::Yarr::YarrPatternConstructor::quantifyAtom):
2820         (JSC::Yarr::YarrPatternConstructor::disjunction):
2821         (JSC::Yarr::YarrPatternConstructor::regexBegin):
2822         (JSC::Yarr::YarrPatternConstructor::regexEnd):
2823         (JSC::Yarr::YarrPatternConstructor::regexError):
2824         (JSC::Yarr::YarrPatternConstructor::setupAlternativeOffsets):
2825         (JSC::Yarr::YarrPatternConstructor::setupDisjunctionOffsets):
2826         (JSC::Yarr::YarrPatternConstructor::setupOffsets):
2827         (JSC::Yarr::YarrPatternConstructor::checkForTerminalParentheses):
2828         (JSC::Yarr::YarrPatternConstructor::optimizeBOL):
2829         (JSC::Yarr::YarrPatternConstructor::addBeginTerm):
2830         (JSC::Yarr::YarrPatternConstructor::setupDisjunctionBeginTerms):
2831         (JSC::Yarr::YarrPatternConstructor::setupAlternativeBeginTerms):
2832         (JSC::Yarr::YarrPatternConstructor::setupBeginChars):
2833         (JSC::Yarr::compile):
2834         (JSC::Yarr::YarrPattern::YarrPattern):
2835         * yarr/YarrPattern.h: Renamed from Source/JavaScriptCore/yarr/RegexPattern.h.
2836         (JSC::Yarr::CharacterRange::CharacterRange):
2837         (JSC::Yarr::CharacterClassTable::create):
2838         (JSC::Yarr::CharacterClassTable::CharacterClassTable):
2839         (JSC::Yarr::CharacterClass::CharacterClass):
2840         (JSC::Yarr::PatternTerm::PatternTerm):
2841         (JSC::Yarr::PatternTerm::ForwardReference):
2842         (JSC::Yarr::PatternTerm::BOL):
2843         (JSC::Yarr::PatternTerm::EOL):
2844         (JSC::Yarr::PatternTerm::WordBoundary):
2845         (JSC::Yarr::PatternTerm::invert):
2846         (JSC::Yarr::PatternTerm::capture):
2847         (JSC::Yarr::PatternTerm::quantify):
2848         (JSC::Yarr::PatternAlternative::PatternAlternative):
2849         (JSC::Yarr::PatternAlternative::lastTerm):
2850         (JSC::Yarr::PatternAlternative::removeLastTerm):
2851         (JSC::Yarr::PatternAlternative::setOnceThrough):
2852         (JSC::Yarr::PatternAlternative::onceThrough):
2853         (JSC::Yarr::PatternDisjunction::PatternDisjunction):
2854         (JSC::Yarr::PatternDisjunction::~PatternDisjunction):
2855         (JSC::Yarr::PatternDisjunction::addNewAlternative):
2856         (JSC::Yarr::TermChain::TermChain):
2857         (JSC::Yarr::BeginChar::BeginChar):
2858         (JSC::Yarr::YarrPattern::~YarrPattern):
2859         (JSC::Yarr::YarrPattern::reset):
2860         (JSC::Yarr::YarrPattern::containsIllegalBackReference):
2861         (JSC::Yarr::YarrPattern::newlineCharacterClass):
2862         (JSC::Yarr::YarrPattern::digitsCharacterClass):
2863         (JSC::Yarr::YarrPattern::spacesCharacterClass):
2864         (JSC::Yarr::YarrPattern::wordcharCharacterClass):
2865         (JSC::Yarr::YarrPattern::nondigitsCharacterClass):
2866         (JSC::Yarr::YarrPattern::nonspacesCharacterClass):
2867         (JSC::Yarr::YarrPattern::nonwordcharCharacterClass):
2868
2869 2011-01-10  Gavin Barraclough  <barraclough@apple.com>
2870
2871         Windows build fix.
2872
2873         * parser/SyntaxChecker.h:
2874
2875 2011-01-10  Dave Tapuska  <dtapuska@rim.com>
2876
2877         Reviewed by Gavin Barraclough.
2878
2879         Add CTI ASM versions for RVCT ARM THUMB2 mode.
2880
2881         https://bugs.webkit.org/show_bug.cgi?id=52154
2882
2883         * jit/JITStubs.cpp:
2884         (JSC::ctiTrampoline):
2885         (JSC::ctiVMThrowTrampoline):
2886         (JSC::ctiOpThrowNotCaught):
2887
2888 2011-01-10  Gavin Barraclough  <barraclough@apple.com>
2889
2890         Qt build fix.
2891
2892         * JavaScriptCore.pro:
2893
2894 2011-01-10  Gavin Barraclough  <barraclough@apple.com>
2895
2896         Reviewed by Oliver Hunt.
2897
2898         Bug 52079 - Syntax errors should be early errors.
2899
2900         From chapter 16 the spec:
2901             An implementation must report most errors at the time the relevant ECMAScript language construct is
2902             evaluated. An early error is an error that can be detected and reported prior to the evaluation of
2903             any construct in the Program containing the error. An implementation must report early errors in a
2904             Program prior to the first evaluation of that Program. Early errors in eval code are reported at
2905             the time eval is called but prior to evaluation of any construct within the eval code. All errors
2906             that are not early errors are runtime errors.
2907
2908             An implementation must treat any instance of the following kinds of errors as an early error:
2909                 * Any syntax error."
2910
2911         * JavaScriptCore.xcodeproj/project.pbxproj:
2912             Added new files.
2913         * bytecode/CodeBlock.cpp:
2914             Removed op_throw_syntax_error.
2915         * bytecode/Opcode.h:
2916             Removed op_throw_syntax_error.
2917         * bytecompiler/BytecodeGenerator.cpp:
2918         (JSC::BytecodeGenerator::generate):
2919             If m_expressionTooDeep then throw a runtime error.
2920         (JSC::BytecodeGenerator::BytecodeGenerator):
2921             Initialize m_expressionTooDeep.
2922         (JSC::BytecodeGenerator::emitThrowExpressionTooDeepException):
2923             Sets m_expressionTooDeep.
2924         * bytecompiler/BytecodeGenerator.h:
2925             Added m_expressionTooDeep, removed emitThrowSyntaxError.
2926         * bytecompiler/NodesCodegen.cpp:
2927         (JSC::RegExpNode::emitBytecode):
2928         (JSC::ContinueNode::emitBytecode):
2929         (JSC::BreakNode::emitBytecode):
2930         (JSC::ReturnNode::emitBytecode):
2931         (JSC::LabelNode::emitBytecode):
2932             Conditions that threw syntax error are now handled during parsing;
2933             during bytecompilation these are now just ASSERTs.
2934         * interpreter/Interpreter.cpp:
2935         (JSC::Interpreter::privateExecute):
2936         * jit/JIT.cpp:
2937         (JSC::JIT::privateCompileMainPass):
2938         * jit/JIT.h:
2939         * jit/JITOpcodes.cpp:
2940         * jit/JITOpcodes32_64.cpp:
2941         * jit/JITStubs.cpp:
2942         * jit/JITStubs.h:
2943             Removed op_throw_syntax_error.
2944         * parser/ASTBuilder.h:
2945         (JSC::ASTBuilder::createRegExp):
2946             Renamed; added syntax check.
2947         * parser/JSParser.cpp:
2948         (JSC::JSParser::breakIsValid):
2949         (JSC::JSParser::hasLabel):
2950         (JSC::JSParser::Scope::Scope):
2951         (JSC::JSParser::Scope::setIsFunction):
2952         (JSC::JSParser::Scope::isFunctionBoundary):
2953         (JSC::JSParser::ScopeRef::hasContainingScope):
2954         (JSC::JSParser::ScopeRef::containingScope):
2955         (JSC::JSParser::AutoPopScopeRef::AutoPopScopeRef):
2956         (JSC::JSParser::AutoPopScopeRef::~AutoPopScopeRef):
2957         (JSC::JSParser::AutoPopScopeRef::setPopped):
2958         (JSC::JSParser::popScopeInternal):
2959         (JSC::JSParser::popScope):
2960         (JSC::jsParse):
2961         (JSC::JSParser::JSParser):
2962         (JSC::JSParser::parseProgram):
2963         (JSC::JSParser::parseBreakStatement):
2964         (JSC::JSParser::parseContinueStatement):
2965         (JSC::JSParser::parseReturnStatement):
2966         (JSC::JSParser::parseTryStatement):
2967         (JSC::JSParser::parseFunctionInfo):
2968         (JSC::JSParser::parseExpressionOrLabelStatement):
2969         (JSC::JSParser::parsePrimaryExpression):
2970         * parser/JSParser.h:
2971         * parser/Nodes.h:
2972         * parser/Parser.cpp:
2973         (JSC::Parser::parse):
2974         * parser/SyntaxChecker.h:
2975         (JSC::SyntaxChecker::createRegExp):
2976             Renamed; added syntax check.
2977         * runtime/ExceptionHelpers.cpp:
2978         (JSC::createOutOfMemoryError):
2979         (JSC::throwOutOfMemoryError):
2980         * runtime/ExceptionHelpers.h:
2981             Broke out createOutOfMemoryError.
2982         * runtime/Executable.cpp:
2983         (JSC::EvalExecutable::compileInternal):
2984         (JSC::ProgramExecutable::compileInternal):
2985         (JSC::FunctionExecutable::compileForCallInternal):
2986         (JSC::FunctionExecutable::compileForConstructInternal):
2987             Add check for exception after bytecode generation.
2988         * runtime/RegExpConstructor.cpp:
2989         (JSC::constructRegExp):
2990         * runtime/RegExpPrototype.cpp:
2991         (JSC::regExpProtoFuncCompile):
2992             RegExp error prefixes not included in error string.
2993         * yarr/RegexParser.h:
2994         (JSC::Yarr::Parser::parse):
2995             Removed regexBegin/regexEnd/regexError.
2996         * yarr/RegexPattern.cpp:
2997         (JSC::Yarr::RegexPatternConstructor::regexBegin):
2998             Removed regexEnd/regexError.
2999         (JSC::Yarr::compileRegex):
3000             Add call to regexBegin (no longer called from the parser).
3001         * yarr/YarrSyntaxChecker.cpp: Added.
3002         (JSC::Yarr::SyntaxChecker::assertionBOL):
3003         (JSC::Yarr::SyntaxChecker::assertionEOL):
3004         (JSC::Yarr::SyntaxChecker::assertionWordBoundary):
3005         (JSC::Yarr::SyntaxChecker::atomPatternCharacter):
3006         (JSC::Yarr::SyntaxChecker::atomBuiltInCharacterClass):
3007         (JSC::Yarr::SyntaxChecker::atomCharacterClassBegin):
3008         (JSC::Yarr::SyntaxChecker::atomCharacterClassAtom):
3009         (JSC::Yarr::SyntaxChecker::atomCharacterClassRange):
3010         (JSC::Yarr::SyntaxChecker::atomCharacterClassBuiltIn):
3011         (JSC::Yarr::SyntaxChecker::atomCharacterClassEnd):
3012         (JSC::Yarr::SyntaxChecker::atomParenthesesSubpatternBegin):
3013         (JSC::Yarr::SyntaxChecker::atomParentheticalAssertionBegin):
3014         (JSC::Yarr::SyntaxChecker::atomParenthesesEnd):
3015         (JSC::Yarr::SyntaxChecker::atomBackReference):
3016         (JSC::Yarr::SyntaxChecker::quantifyAtom):
3017         (JSC::Yarr::SyntaxChecker::disjunction):
3018         (JSC::Yarr::checkSyntax):
3019         * yarr/YarrSyntaxChecker.h: Added.
3020             Check RegExp syntax.
3021
3022 2011-01-10  Adam Roben  <aroben@apple.com>
3023
3024         Roll out r75289
3025
3026         It was causing assertion failures. See <http://webkit.org/b/52156>.
3027
3028         * wtf/StackBounds.cpp:
3029         (WTF::StackBounds::initialize):
3030
3031 2011-01-08  Patrick Gansterer  <paroga@webkit.org>
3032
3033         Reviewed by Darin Adler.
3034
3035         Unify string table adding in AtomicString
3036         https://bugs.webkit.org/show_bug.cgi?id=51927
3037
3038         Move code for adding a string into a separate function.
3039         This removes multiple occurrence of the same logic.
3040
3041         * wtf/text/AtomicString.cpp:
3042         (WTF::addToStringTable): Added.
3043         (WTF::AtomicString::add): Use addToStringTable().
3044         (WTF::AtomicString::fromUTF8): Ditto.
3045
3046 2011-01-07  Geoffrey Garen  <ggaren@apple.com>
3047
3048         Reviewed by Gavin Barraclough.
3049
3050         Split machine stack marking functions into their own class (MachineStackMarker)
3051         https://bugs.webkit.org/show_bug.cgi?id=52088
3052
3053         * API/APIShims.h:
3054         (JSC::APIEntryShimWithoutLock::APIEntryShimWithoutLock): Moved registerThread()
3055         call behind an #ifdef because we shouldn't be registering threads at all
3056         if we don't support usage on multiple threads.
3057
3058         * Android.mk:
3059         * CMakeLists.txt:
3060         * GNUmakefile.am:
3061         * JavaScriptCore.gypi:
3062         * JavaScriptCore.pro:
3063         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
3064         * JavaScriptCore.xcodeproj/project.pbxproj: Updated projects.
3065
3066         * runtime/Collector.cpp:
3067         (JSC::Heap::Heap):
3068         (JSC::Heap::destroy):
3069         (JSC::Heap::markRoots):
3070         * runtime/Collector.h:
3071         (JSC::Heap::machineStackMarker): Moved code to machineStackMarker.
3072
3073         * runtime/JSGlobalData.h:
3074         (JSC::JSGlobalData::makeUsableFromMultipleThreads): Removed an unnecessary
3075         level of indirection, to make Heap less of a God class.
3076
3077         * runtime/MachineStackMarker.h: Copied from Source/JavaScriptCore/runtime/Collector.h.
3078         * runtime/MachineStackMarker.cpp: Copied from Source/JavaScriptCore/runtime/Collector.cpp.
3079         (JSC::MachineStackMarker::MachineStackMarker):
3080         (JSC::MachineStackMarker::~MachineStackMarker):
3081         (JSC::MachineStackMarker::makeUsableFromMultipleThreads):
3082         (JSC::MachineStackMarker::registerThread):
3083         (JSC::MachineStackMarker::unregisterThread):
3084         (JSC::MachineStackMarker::markCurrentThreadConservativelyInternal):
3085         (JSC::MachineStackMarker::markCurrentThreadConservatively):
3086         (JSC::MachineStackMarker::markOtherThreadConservatively):
3087         (JSC::MachineStackMarker::markMachineStackConservatively): Moved code from Heap.
3088
3089 2011-01-07  Gavin Barraclough  <barraclough@apple.com>
3090
3091         Reviewed by Geoff Garen.
3092
3093         Bug 26276 - Need a mechanism to determine stack extent on WINDOWS, SOLARIS, OPENBSD, SYMBIAN, HAIKU, WINCE platforms
3094
3095         Fix for win32.  The base of the stack is stored in the "deallocation stack" field of the
3096         Thread Information Block - see: http://en.wikipedia.org/wiki/Win32_Thread_Information_Block
3097         for more information!
3098
3099         * wtf/StackBounds.cpp:
3100         (WTF::StackBounds::initialize):
3101
3102 2011-01-07  Adam Roben  <aroben@apple.com>
3103
3104         Update react-to-vsprops-changes.py after r74855
3105
3106         * JavaScriptCore.vcproj/JavaScriptCore/react-to-vsprops-changes.py:
3107
3108 2011-01-07  Carlos Garcia Campos  <cgarcia@igalia.com>
3109
3110         Reviewed by Martin Robinson.
3111
3112         [GTK] Port scrollbar painting to GtkStyleContext
3113         https://bugs.webkit.org/show_bug.cgi?id=52051
3114
3115         * wtf/gobject/GTypedefs.h: Add GtkStyleContext forward
3116         declaration.
3117
3118 2011-01-07  Daniel Bates  <dbates@rim.com>
3119
3120         Reviewed by Martin Robinson.
3121
3122         Enable PCRE computed gotos when compiling with RCVT 4.0 or greater in GNU mode
3123         https://bugs.webkit.org/show_bug.cgi?id=52034
3124
3125         Derived from a patch by Eli Fidler.
3126
3127         RVCT 4 or greater in GNU mode supports the computed goto GNU language extension
3128         as per <http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0348c/ch03s07s12.html>.
3129
3130         * pcre/pcre_exec.cpp: Modified to check for feature, HAVE(COMPUTED_GOTO), instead
3131         of hardcoding the GCC compiler.
3132         * wtf/Platform.h: Define WTF_COMPILER_RVCT4_OR_GREATER if __ARMCC_VERSION >= 400000.
3133
3134 2011-01-06  Gavin Barraclough  <barraclough@apple.com>
3135
3136         Reviewed by Geoff Garen.
3137
3138         Bug 52035 - Unregistering DOMWrapperWorlds is unsafe
3139
3140         The method DOMWrapperWorld::unregisterWorld() effectively calls the DOMWrapperWorld's
3141         destructor early, in order to release wrappers once we know we no longer intend to use them.
3142         Whilst it is okay to have a method to throw away wrappers (assuming we know we're willing to
3143         lose any state stored on them) it is not okay to deregister the world from the JSGlobalData.
3144         A sequence of events that triggers the bug would look like this:
3145
3146         (1) Create a DOMWrapperWorld.
3147         (2) Register a timer in the world.
3148         (3) Call unregisterWorld() on the world.
3149         (4) Timer goes off, code is executed in the world, creates a Node not attached to a Document.
3150         (5) We attempt to lookup a wrapper map for the world on the JSGlobalData, but because we've
3151             called forgetWorld() none exists.
3152         (6) Attempt to add a wrapper to a NULL map.
3153
3154         Fix the problem by not removing the JSGlobalData's wrapper map until the world really goes away.
3155
3156         * runtime/WeakGCMap.h:
3157         (JSC::WeakGCMap::clear):
3158
3159 2011-01-06  Gavin Barraclough  <barraclough@apple.com>
3160
3161         Reviewed by Darin Adler.
3162
3163         Bug 52021 - zeroDouble broken on ARMv7
3164
3165         The bug here is that zeroDouble was working incorrectly,
3166         leading to op_loop_if_true failing - specifically in the
3167         case where the value being checked is 0.0 encoded as a
3168         double (rather than an integer immediate).
3169
3170         Additionally this patch removes a redundant duplicate compare
3171         in some (many) case.
3172
3173         * assembler/ARMv7Assembler.h:
3174         (JSC::ARMv7Assembler::vcmp_F64):
3175         (JSC::ARMv7Assembler::vcmpz_F64):
3176         * assembler/MacroAssemblerARM.h:
3177         (JSC::MacroAssemblerARM::branchDoubleNonZero):
3178         (JSC::MacroAssemblerARM::branchDoubleZeroOrNaN):
3179         * assembler/MacroAssemblerARMv7.h:
3180         (JSC::MacroAssemblerARMv7::branchDouble):
3181         (JSC::MacroAssemblerARMv7::branchDoubleNonZero):
3182         (JSC::MacroAssemblerARMv7::branchDoubleZeroOrNaN):
3183         (JSC::MacroAssemblerARMv7::compare32):
3184         * assembler/MacroAssemblerMIPS.h:
3185         (JSC::MacroAssemblerMIPS::branchDoubleNonZero):
3186         (JSC::MacroAssemblerMIPS::branchDoubleZeroOrNaN):
3187         * assembler/MacroAssemblerX86Common.h:
3188         (JSC::MacroAssemblerX86Common::branchDoubleNonZero):
3189         (JSC::MacroAssemblerX86Common::branchDoubleZeroOrNaN):
3190         * jit/JITOpcodes32_64.cpp:
3191         (JSC::JIT::emit_op_jfalse):
3192         (JSC::JIT::emit_op_jtrue):
3193
3194 2011-01-06  Michael Saboff  <msaboff@apple.com>
3195
3196         Reviewed by Gavin Barraclough.
3197
3198         Added debug code to compare the results of JIT regexp with 
3199         interpreted regexp and displays discrepencies.  This debug code is
3200         controlled by the ENABLE_YARR_JIT_DEBUG macro in wtf/Platform.h and
3201         is only valid if ENABLE_YARR_JIT is enabled.
3202
3203         Fixed a discovered problem in RegExp::printTraceData, changing
3204         m_pattern to the getter pattern().
3205         Also deleted an extraneous semicolon.
3206
3207         Enhancement: Add Regexp Debug Compare between JIT and Interpreter
3208         https://bugs.webkit.org/show_bug.cgi?id=51834
3209
3210         * runtime/RegExp.cpp:
3211         (JSC::RegExp::compile):
3212         (JSC::RegExp::match):
3213         (JSC::RegExp::printTraceData):
3214         * wtf/Platform.h:
3215
3216 2011-01-06  Patrick Gansterer  <paroga@webkit.org>
3217
3218         Reviewed by Eric Seidel.
3219
3220         [WINCE] Remove JSC::g_stackBase
3221         https://bugs.webkit.org/show_bug.cgi?id=51779
3222
3223         * wtf/StackBounds.cpp:
3224
3225 2011-01-06  Joone Hur  <joone.hur@collabora.co.uk>
3226
3227         Reviewed by Eric Seidel.
3228
3229         WML Parser should treat line/column number in a consistent way
3230         https://bugs.webkit.org/show_bug.cgi?id=51601
3231
3232         Add the equality operators to TextPosition class.
3233
3234         * wtf/text/TextPosition.h:
3235         (WTF::TextPosition::operator==): Added.
3236         (WTF::TextPosition::operator!=): Added.
3237         (WTF::TextPosition::belowRangePosition): Use belowBase() instead of base().
3238         (WTF::ZeroBasedNumber::operator==): Added.
3239         (WTF::ZeroBasedNumber::operator!=): Added.
3240         (WTF::OneBasedNumber::operator==): Added.
3241         (WTF::OneBasedNumber::operator!=): Added.
3242
3243 2011-01-06  Patrick Gansterer  <paroga@webkit.org>
3244
3245         Reviewed by Gavin Barraclough.
3246
3247         [WINCE] Determine stack extent
3248         https://bugs.webkit.org/show_bug.cgi?id=26276
3249
3250         Scan the stack for writeable pages and use the limits.
3251
3252         * wtf/StackBounds.cpp:
3253         (WTF::detectGrowingDownward):
3254         (WTF::isPageWritable):
3255         (WTF::getLowerStackBound):
3256         (WTF::getUpperStackBound):
3257         (WTF::StackBounds::initialize):
3258
3259 2011-01-05  Steve Falkenburg  <sfalken@apple.com>
3260
3261         Windows build fix.
3262
3263         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreCommon.vsprops: Revert change to additional library search path needed to find ICU.
3264
3265 2011-01-05  Steve Falkenburg  <sfalken@apple.com>
3266
3267         Reviewed by Darin Adler.
3268
3269         Debug and Release builds on Windows clobber each other
3270         https://bugs.webkit.org/show_bug.cgi?id=49185
3271         
3272         Changes the structure of WebKitBuild build products directory so we
3273         completely separate each build configuration into independent directories.
3274         
3275         Although we previously had per-configuration directories for obj, this change adds
3276         per-configuration directories for bin, lib, obj, and include. Each configuration's
3277         build products are stored within a directory inside of WebKitBuild.
3278         
3279         Most use of $(WebKitOutputDir) in the build files has been replaced by $(ConfigurationBuildDir),
3280         defined in common.vsprops to be $(WebKitOutputDir)\$(ConfigurationName).
3281         
3282         For PGO, $(ConfigurationBuildDir) points to the same directory (Release_PGO) to allow
3283         for proper operation of the instrumentation/optimization scripts.
3284
3285         * JavaScriptCore.vcproj/JavaScriptCore.make:
3286         * JavaScriptCore.vcproj/JavaScriptCore.sln:
3287         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
3288         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreCommon.vsprops:
3289         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreGenerated.make:
3290         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreGenerated.vcproj:
3291         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreGeneratedCommon.vsprops:
3292         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCorePGOOptimize.vsprops: Added.
3293         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCorePostBuild.cmd:
3294         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCorePreBuild.cmd:
3295         * JavaScriptCore.vcproj/JavaScriptCore/build-generated-files.sh:
3296         * JavaScriptCore.vcproj/JavaScriptCore/react-to-vsprops-changes.py:
3297         * JavaScriptCore.vcproj/JavaScriptCoreSubmit.sln:
3298         * JavaScriptCore.vcproj/WTF/WTF.vcproj:
3299         * JavaScriptCore.vcproj/WTF/WTFCommon.vsprops:
3300         * JavaScriptCore.vcproj/WTF/WTFPostBuild.cmd:
3301         * JavaScriptCore.vcproj/WTF/WTFPreBuild.cmd:
3302         * JavaScriptCore.vcproj/jsc/jsc.vcproj:
3303         * JavaScriptCore.vcproj/jsc/jscCommon.vsprops:
3304         * JavaScriptCore.vcproj/jsc/jscPostBuild.cmd:
3305         * JavaScriptCore.vcproj/jsc/jscPreBuild.cmd:
3306         * JavaScriptCore.vcproj/testapi/testapiCommon.vsprops:
3307         * JavaScriptCore.vcproj/testapi/testapiPostBuild.cmd:
3308         * JavaScriptCore.vcproj/testapi/testapiPreBuild.cmd:
3309
3310 2011-01-05  Brent Fulgham  <bfulgham@webkit.org>
3311
3312         Unreviewed build fix.
3313
3314         * wtf/Encoder.h: Add <stdint.h> include for systems that
3315         do not natively know about uint8_t, etc.
3316
3317 2011-01-05  Patrick Gansterer  <paroga@webkit.org>
3318
3319         Reviewed by Andreas Kling.
3320
3321         [CMake] Fix the usage of SOURCE_GROUP
3322         https://bugs.webkit.org/show_bug.cgi?id=51739
3323
3324         * CMakeLists.txt:
3325
3326 2011-01-05  Andras Becsi  <abecsi@webkit.org>
3327
3328         Reviewed by Csaba Osztrogonác.
3329
3330         [Qt][V8] Fix the build after recent changes.
3331
3332         * pcre/pcre.pri: Correct the path after Source was introduced.
3333
3334 2011-01-04  Steve Falkenburg  <sfalken@apple.com>
3335
3336         Build fix. Update path to FindSafari after source code reorganization.
3337
3338         * JavaScriptCore.vcproj/JavaScriptCore.sln:
3339
3340 2011-01-04  Daniel Bates  <dbates@rim.com>
3341
3342         Fix the Android build after changeset 74975 <http://trac.webkit.org/changeset/74975>
3343         (https://bugs.webkit.org/show_bug.cgi?id=51855).
3344
3345         * wtf/ThreadingPthreads.cpp: Add include of PassOwnPtr.h.
3346         (WTF::runThreadWithRegistration): Use -> instead of . to dereference pointer.
3347
3348 2011-01-04  Martin Robinson  <mrobinson@igalia.com>
3349
3350         Try to fix the EFL build.
3351
3352         * wtf/CMakeLists.txt: Remove PlatformRefPtr from the CMake source list.
3353
3354 2011-01-04  James Robinson  <jamesr@chromium.org>
3355
3356         Reviewed by Darin Adler.
3357
3358         StackBounds initialization in WTFThreadData should be guarded by #if USE(JSC)
3359         https://bugs.webkit.org/show_bug.cgi?id=51881
3360
3361         The StackBounds class is only used by JavaScriptCore.
3362
3363         * wtf/WTFThreadData.cpp:
3364         (WTF::WTFThreadData::WTFThreadData):
3365         * wtf/WTFThreadData.h:
3366         (WTF::WTFThreadData::resetCurrentIdentifierTable):
3367
3368 2011-01-03  Martin Robinson  <mrobinson@igalia.com>
3369
3370         Reviewed by Darin Adler.
3371
3372         Remove the last non-GObject usage of PlatformRefPtr and move the code to GRefPtr
3373         https://bugs.webkit.org/show_bug.cgi?id=51846
3374
3375         * GNUmakefile.am: Remove PlatformRefPtr.h from the sources list.
3376         * JavaScriptCore.vcproj/WTF/WTF.vcproj: Ditto.
3377         * jit/ExecutableAllocator.h: Change references to PlatformRefPtr to RefPtr.
3378         (JSC::ExecutableAllocator::cacheFlush): Ditto.
3379         * wtf/PlatformRefPtr.h: Removed.
3380         * wtf/RandomNumber.cpp: Change references to PlatformRefPtr to RefPtr.
3381         (WTF::randomNumber): Ditto.
3382         * wtf/brew/RefPtrBrew.h: Ditto.
3383         (WTF::refIfNotNull): Added.
3384         (WTF::derefIfNotNull): Added.
3385         * wtf/brew/ShellBrew.h: Change references to PlatformRefPtr to RefPtr.
3386         (WTF::createRefPtrInstance): Modified to return a RefPtr.
3387         * wtf/gobject/GRefPtr.cpp: 
3388         (WTF::refGPtr): Moved from PlatformRefPtr here.
3389         (WTF::derefGPtr): Ditto.
3390         * wtf/gobject/GRefPtr.h: Ditto.
3391         (WTF::GRefPtr::GRefPtr): Ditto.
3392         (WTF::GRefPtr::~GRefPtr): Ditto.
3393         (WTF::GRefPtr::clear): Ditto.
3394         (WTF::GRefPtr::isHashTableDeletedValue): Ditto.
3395         (WTF::GRefPtr::get): Ditto.
3396         (WTF::GRefPtr::operator*): Ditto.
3397         (WTF::GRefPtr::operator->): Ditto.
3398         (WTF::GRefPtr::operator!): Ditto.
3399         (WTF::GRefPtr::operator UnspecifiedBoolType): Ditto.
3400         (WTF::GRefPtr::hashTableDeletedValue): Ditto.
3401         (WTF::::operator): Ditto.
3402         (WTF::::swap): Ditto.
3403         (WTF::swap): Ditto.
3404         (WTF::operator==): Ditto.
3405         (WTF::operator!=): Ditto.
3406         (WTF::static_pointer_cast): Ditto.
3407         (WTF::const_pointer_cast): Ditto.
3408         (WTF::getPtr): Ditto.
3409         (WTF::adoptGRef): Ditto.
3410         (WTF::refGPtr): Ditto.
3411         (WTF::derefGPtr): Ditto.
3412
3413 2011-01-04  Daniel Bates  <dbates@rim.com>
3414
3415         Reviewed by Adam Roben.
3416
3417         LEAK: Deallocate instance of ThreadFunctionInvocation if thread creation fails
3418         https://bugs.webkit.org/show_bug.cgi?id=51860
3419
3420         * wtf/ThreadingWin.cpp:
3421         (WTF::createThreadInternal):
3422
3423 2011-01-04  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
3424
3425         Reviewed by Ariya Hidayat.
3426
3427         [Qt][Symbian] Make sure that WebKit headers are included before platform headers on Symbian
3428         https://bugs.webkit.org/show_bug.cgi?id=31273
3429
3430         On Symbian PREPEND_INCLUDEPATH is the best way to make sure that WebKit headers
3431         are included before platform headers. On all other platforms continue to use
3432         INCLUDEPATH (as before). This is a continuation of r65877.
3433
3434         No new tests as there is no new functionality.
3435
3436         * JavaScriptCore.pri:
3437
3438 2011-01-04  Darin Adler  <darin@apple.com>
3439
3440         Try to fix Windows build.
3441
3442         * wtf/ThreadingWin.cpp: Added include of PassOwnPtr.h. Fixed paragraphing
3443         of conditional includes.
3444         (WTF::wtfThreadEntryPoint): Use -> instead of . to dereference pointer.
3445         (WTF::createThreadInternal): Tweaked #if to not need separate macro.
3446
3447 2011-01-04  Daniel Bates  <dbates@rim.com>
3448
3449         Reviewed by Adam Roben.
3450
3451         Extract ThreadFunctionInvocation into separate file and share between Apple Windows and Android
3452         https://bugs.webkit.org/show_bug.cgi?id=51855
3453
3454         Both the Apple Windows and Android ports implement a similar adapter structure,
3455         called ThreadFunctionInvocation and ThreadData respectively, as part of
3456         their thread creation process. Instead, we should share such an adapter
3457         structure and remove duplicate code.
3458
3459         * JavaScriptCore.gypi: Added header wtf/ThreadFunctionInvocation.h.
3460         * wtf/ThreadFunctionInvocation.h: Added.
3461         (WTF::ThreadFunctionInvocation::ThreadFunctionInvocation):
3462         * wtf/ThreadingPthreads.cpp: Removed Android-specific structure ThreadData; Instead, use ThreadFunctionInvocation.
3463         (WTF::runThreadWithRegistration):
3464         (WTF::createThreadInternal): 
3465         * wtf/ThreadingWin.cpp: Moved structure ThreadFunctionInvocation to its own file so that
3466         it can be shared with the Android implementation of createThreadInternal().
3467         (WTF::wtfThreadEntryPoint): Use OwnPtr to hold passed instance of ThreadFunctionInvocation.
3468
3469 2011-01-04  Daniel Bates  <dbates@rim.com>
3470
3471         Reviewed by Darin Adler.
3472
3473         Use __builtin_expect when compiling using RVCT in GNU mode
3474         https://bugs.webkit.org/show_bug.cgi?id=51866
3475
3476         Derived from a patch by Dave Tapuska.
3477
3478         * wtf/AlwaysInline.h:
3479
3480 2011-01-03  Darin Adler  <darin@apple.com>
3481
3482         Reviewed by Brady Eidson.
3483
3484         * wtf/Forward.h: Added Decoder and Encoder.
3485
3486 2011-01-03  Brady Eidson  <beidson@apple.com>
3487
3488         Reviewed by Darin Adler.
3489
3490         Add Encode/Decode machinery Darin and I plan to work with for back/forward stuff in WebKit2.
3491
3492         Starting out with a pure virtual interface to be implemented in WK2, but we might change that later.
3493
3494         * GNUmakefile.am:
3495         * JavaScriptCore.vcproj/WTF/WTF.vcproj:
3496         * JavaScriptCore.xcodeproj/project.pbxproj:
3497         * wtf/CMakeLists.txt:
3498
3499         * wtf/Decoder.h: Added.
3500         * wtf/Encoder.h: Added.
3501
3502 2011-01-03  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
3503
3504         Unreviewed build fix.
3505
3506         [Qt] Add NullPtr.cpp introduced in r71155 to the Qt build system.
3507
3508         This fix is required for builds where HAVE(NULLPTR) is false
3509         (e.g. some MSVC and Symbian builds).
3510
3511         * wtf/wtf.pri:
3512
3513 2011-01-02  Dan Bernstein  <mitz@apple.com>
3514
3515         Rubber-stamped by Simon Fraser.
3516
3517         <rdar://problem/8812159> Update copyright strings
3518
3519         * Info.plist:
3520