Modify ASSERT_UNUSED and UNUSED_PARAM similar to Qt's Q_UNUSED.
[WebKit-https.git] / JavaScriptCore / ChangeLog
1 2010-08-31  Csaba Osztrogonác  <ossy@webkit.org>
2
3         Reviewed by Darin Adler.
4
5         Modify ASSERT_UNUSED and UNUSED_PARAM similar to Qt's Q_UNUSED.
6         https://bugs.webkit.org/show_bug.cgi?id=44870
7
8         * wtf/Assertions.h:
9         * wtf/UnusedParam.h:
10
11 2010-08-31  Benjamin Poulain  <benjamin.poulain@nokia.com>
12
13         Reviewed by Kenneth Rohde Christiansen.
14
15         JSC TimeoutChecker::didTimeOut overflows on ARM
16         https://bugs.webkit.org/show_bug.cgi?id=38538
17
18         Make getCPUTime() return values relative to the first call.
19         The previous implementation relied on simply on currentTime(), which
20         return a time since epoch and not a time since the thread started. This
21         made the return value of getCPUTime() overflow on 32 bits.
22
23         * runtime/TimeoutChecker.cpp:
24         (JSC::getCPUTime):
25
26 2010-08-30  Mihai Parparita  <mihaip@chromium.org>
27
28         Reviewed by Adam Barth.
29
30         HISTORY_ALWAYS_ASYNC should be removed (history should always be async)
31         https://bugs.webkit.org/show_bug.cgi?id=44315
32
33         Remove ENABLE_HISTORY_ALWAYS_ASYNC #define.
34
35         * wtf/Platform.h: 
36
37 2010-08-30  Chris Rogers  <crogers@google.com>
38
39         Reviewed by Kenneth Russell.
40
41         Fix namespace for wtf/Complex.h and wtf/Vector3.h
42         https://bugs.webkit.org/show_bug.cgi?id=44892
43
44         * wtf/Complex.h:
45         * wtf/Vector3.h:
46
47 2010-08-30  Andy Estes  <aestes@apple.com>
48
49         Reviewed by Eric Carlson.
50
51         Strings returned by asciiDebug() should be NULL-terminated.
52         https://bugs.webkit.org/show_bug.cgi?id=44866
53
54         * wtf/text/WTFString.cpp:
55         (asciiDebug):
56
57 2010-08-30  Zoltan Herczeg  <zherczeg@webkit.org>
58
59         Reviewed by Darin Adler.
60
61         Refactor number parsing in the lexer
62         https://bugs.webkit.org/show_bug.cgi?id=44104
63
64         Number parsing was full of gotos, and needed a complete
65         redesign to remove them (Only one remained). Furthermore
66         integer arithmetic is empolyed for fast cases (= small
67         integer numbers).
68
69         * parser/Lexer.cpp:
70         (JSC::Lexer::parseHex):
71         (JSC::Lexer::parseOctal):
72         (JSC::Lexer::parseDecimal):
73         (JSC::Lexer::parseNumberAfterDecimalPoint):
74         (JSC::Lexer::parseNumberAfterExponentIndicator):
75         (JSC::Lexer::lex):
76         * parser/Lexer.h:
77
78 2010-08-29  Darin Adler  <darin@apple.com>
79
80         Fix Qt build.
81
82         * wtf/unicode/glib/UnicodeMacrosFromICU.h: Added U_IS_BMP.
83         * wtf/unicode/qt4/UnicodeQt4.h: Ditto.
84         * wtf/unicode/wince/UnicodeWince.h: Ditto.
85
86 2010-08-29  Kwang Yul Seo  <skyul@company100.net>
87
88         Reviewed by Kent Tamura.
89
90         [BREWMP] Port vprintf_stderr_common
91         https://bugs.webkit.org/show_bug.cgi?id=33568
92
93         Use BREW's DBGPRINTF to output debug messages.
94
95         * wtf/Assertions.cpp:
96
97 2010-08-28  Gavin Barraclough  <barraclough@apple.com>
98
99         Reviewed by Oliver Hunt.
100
101         Bug 44830 - In Array's prototype functyions we're incorrectly handing large index values
102
103         We are in places casting doubles to unsigneds, and unsigneds to ints, without always check
104         that the result is within bounds. This is problematic in the case of double-to-unsigned
105         conversion because we should be saturating to array length.
106
107         Also, the error return value from Array.splice should be [], not undefined.
108
109         I don't see any security concerns here. These methods are spec'ed in such a way that they
110         can be applied to non Array objects, so in all cases the (potentially bogus) indices are
111         being passed to functions that will safely check accesses are within bounds.
112
113         * runtime/ArrayPrototype.cpp:
114         (JSC::argumentClampedIndexFromStartOrEnd):
115         (JSC::arrayProtoFuncJoin):
116         (JSC::arrayProtoFuncConcat):
117         (JSC::arrayProtoFuncReverse):
118         (JSC::arrayProtoFuncShift):
119         (JSC::arrayProtoFuncSlice):
120         (JSC::arrayProtoFuncSort):
121         (JSC::arrayProtoFuncSplice):
122         (JSC::arrayProtoFuncUnShift):
123         (JSC::arrayProtoFuncFilter):
124         (JSC::arrayProtoFuncMap):
125         (JSC::arrayProtoFuncEvery):
126         (JSC::arrayProtoFuncForEach):
127         (JSC::arrayProtoFuncSome):
128         (JSC::arrayProtoFuncReduce):
129         (JSC::arrayProtoFuncReduceRight):
130         (JSC::arrayProtoFuncIndexOf):
131         (JSC::arrayProtoFuncLastIndexOf):
132         * runtime/JSValue.h:
133         (JSC::JSValue::toUInt32):
134
135 2010-08-28  Pratik Solanki  <psolanki@apple.com>
136
137         Reviewed by Dan Bernstein.
138
139         Add an ENABLE define for purgeable memory support
140         https://bugs.webkit.org/show_bug.cgi?id=44777
141
142         * wtf/Platform.h:
143
144 2010-08-27  Kimmo Kinnunen  <kimmo.t.kinnunen@nokia.com>
145
146         Reviewed by Kenneth Rohde Christiansen.
147
148         [Qt] NPAPI Plugin metadata should be cached, and loading a plugin should not require loading every plugin
149         https://bugs.webkit.org/show_bug.cgi?id=43179
150
151         Add ENABLE_NETSCAPE_PLUGIN_METADATA_CACHE flag to enable persistent
152         NPAPI Plugin Cache. The flag is enabled by default.
153
154         * wtf/Platform.h: Add ENABLE_NETSCAPE_PLUGIN_METADATA_CACHE
155
156 2010-07-27  Jer Noble  <jer.noble@apple.com>
157
158         Reviewed by Eric Carlson.
159
160         Add JavaScript API to allow a page to go fullscreen.
161         rdar://problem/6867795
162         https://bugs.webkit.org/show_bug.cgi?id=43099
163
164         * wtf/Platform.h: Enable FULLSCREEN_API mode for the Mac (except iOS).
165
166 2010-08-27  Gavin Barraclough  <barraclough@apple.com>
167
168         Windows build fix pt 2.
169
170         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
171
172 2010-08-27  Gavin Barraclough  <barraclough@apple.com>
173
174         Windows build fix pt 1.
175
176         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
177
178 2010-08-27  Gavin Barraclough  <barraclough@apple.com>
179
180         Reviewed by Oliver Hunt.
181
182         Bug 44745 - Number.toFixed/toExponential/toPrecision are inaccurate.
183
184         These methods should be using a version of dtoa that can generate results accurate
185         to the requested precision, whereas our version of dtoa is only currently able to
186         support producing results sufficiently accurate to distinguish the value from any
187         other IEEE-754 double precision number.
188
189         This change has no impact on benchmarks we track.
190
191         On microbenchmarks for these functions, this is a slight regression where a high
192         precision is requested (dtoa now need to iterate further to generate a a greater
193         number of digits), but with smaller precision values (hopefully more common) this
194         improves performance, since it reduced the accurate of result dtoa is required,
195         to produce, and removes the need to pre-round values before calling dtoa. 
196
197         * JavaScriptCore.exp:
198             doubleToStringInJavaScriptFormat renamed to numberToString
199
200         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
201             doubleToStringInJavaScriptFormat renamed to numberToString
202
203         * runtime/UString.cpp:
204         (JSC::UString::number):
205             doubleToStringInJavaScriptFormat renamed to numberToString
206
207         * wtf/DecimalNumber.h:
208         (WTF::DecimalNumber::DecimalNumber):
209         (WTF::DecimalNumber::toStringDecimal):
210         (WTF::DecimalNumber::toStringExponential):
211             Remove all pre-rounding of values, instead call dtoa correctly.
212
213         * wtf/dtoa.cpp:
214         (WTF::dtoa):
215         * wtf/dtoa.h:
216             Reenable support for rounding to specific-figures/decimal-places in dtoa.
217             Modify to remove unbiased rounding, provide ECMA required away-from-zero.
218             Rewrite doubleToStringInJavaScriptFormat to use DecimalNumber, rename to
219             numberToString.
220
221 2010-08-27  Chao-ying Fu  <fu@mips.com>
222
223         Reviewed by Oliver Hunt.
224
225         Byte alignment issue on MIPS
226         https://bugs.webkit.org/show_bug.cgi?id=29415
227
228         MIPS accesses one byte at a time for now to avoid the help from the
229         kernel to fix unaligned accesses.
230
231         * wtf/text/AtomicString.cpp:
232         (WebCore::equal):
233         * wtf/text/StringHash.h:
234         (WebCore::StringHash::equal):
235
236 2010-08-27  Xan Lopez  <xlopez@igalia.com>
237
238         Reviewed by Tor Arne Vestbø.
239
240         Fix a couple of typos in comment.
241
242         * bytecode/CodeBlock.h:
243
244 2010-08-26  Gavin Barraclough  <barraclough@apple.com>
245
246         Windows build fix.
247
248         * wtf/dtoa.cpp:
249
250 2010-08-26  Gavin Barraclough  <baraclough@apple.com>
251
252         Reviewed by Sam Weinig.
253
254         Bug 44735 - Clean up dtoa.cpp
255         Remove unused & unmaintained code paths, reformat code to match
256         coding standard & use platform #defines from Platform.h directly.
257
258         * wtf/dtoa.cpp:
259         (WTF::storeInc):
260         (WTF::multadd):
261         (WTF::s2b):
262         (WTF::lo0bits):
263         (WTF::mult):
264         (WTF::pow5mult):
265         (WTF::lshift):
266         (WTF::diff):
267         (WTF::ulp):
268         (WTF::b2d):
269         (WTF::d2b):
270         (WTF::ratio):
271         (WTF::):
272         (WTF::strtod):
273         (WTF::quorem):
274         (WTF::dtoa):
275
276 2010-08-26  Gavin Barraclough  <barraclough@apple.com>
277
278         Rubber Stamped by Oliver Hunt.
279
280         Partially revert r65959. The toString changes regressed the v8 tests,
281         but keep the toFixed/toExponential/toPrecision changes.
282
283         * JavaScriptCore.exp:
284         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
285         * runtime/NumberPrototype.cpp:
286         * runtime/UString.cpp:
287         (JSC::UString::number):
288         * wtf/DecimalNumber.h:
289         * wtf/dtoa.cpp:
290         (WTF::append):
291         (WTF::doubleToStringInJavaScriptFormat):
292         * wtf/dtoa.h:
293         * wtf/text/WTFString.cpp:
294         * wtf/text/WTFString.h:
295
296 2010-08-26  James Robinson  <jamesr@chromium.org>
297
298         Reviewed by Darin Fisher.
299
300         [chromium] Remove the USE(GLES2_RENDERING) define and associated code
301         https://bugs.webkit.org/show_bug.cgi?id=43761
302
303         Remove WTF_USE_GLES2_RENDERING from the list of defines in chromium, it's unused.
304
305         * wtf/Platform.h:
306
307 2010-08-26  Gavin Barraclough  <barraclough@apple.com>
308
309         Rolling out r64608, this regressed performance.
310
311         * JavaScriptCore.xcodeproj/project.pbxproj:
312         * assembler/ARMAssembler.cpp:
313         (JSC::ARMAssembler::executableCopy):
314         * assembler/LinkBuffer.h:
315         (JSC::LinkBuffer::LinkBuffer):
316         (JSC::LinkBuffer::~LinkBuffer):
317         (JSC::LinkBuffer::performFinalization):
318         * assembler/MIPSAssembler.h:
319         (JSC::MIPSAssembler::executableCopy):
320         * assembler/X86Assembler.h:
321         (JSC::X86Assembler::executableCopy):
322         * bytecode/StructureStubInfo.h:
323         (JSC::StructureStubInfo::initGetByIdProto):
324         (JSC::StructureStubInfo::initGetByIdChain):
325         (JSC::StructureStubInfo::initGetByIdSelfList):
326         (JSC::StructureStubInfo::initGetByIdProtoList):
327         (JSC::StructureStubInfo::initPutByIdTransition):
328         * jit/ExecutableAllocator.cpp:
329         (JSC::ExecutablePool::systemAlloc):
330         * jit/ExecutableAllocator.h:
331         (JSC::ExecutablePool::create):
332         (JSC::ExecutableAllocator::ExecutableAllocator):
333         (JSC::ExecutableAllocator::poolForSize):
334         (JSC::ExecutablePool::ExecutablePool):
335         (JSC::ExecutablePool::poolAllocate):
336         * jit/ExecutableAllocatorFixedVMPool.cpp:
337         (JSC::FixedVMPoolAllocator::allocInternal):
338         * jit/JIT.cpp:
339         (JSC::JIT::privateCompile):
340         * jit/JIT.h:
341         (JSC::JIT::compileGetByIdProto):
342         (JSC::JIT::compileGetByIdSelfList):
343         (JSC::JIT::compileGetByIdProtoList):
344         (JSC::JIT::compileGetByIdChainList):
345         (JSC::JIT::compileGetByIdChain):
346         (JSC::JIT::compilePutByIdTransition):
347         (JSC::JIT::compilePatchGetArrayLength):
348         * jit/JITOpcodes.cpp:
349         (JSC::JIT::privateCompileCTIMachineTrampolines):
350         * jit/JITOpcodes32_64.cpp:
351         (JSC::JIT::privateCompileCTIMachineTrampolines):
352         (JSC::JIT::privateCompileCTINativeCall):
353         * jit/JITPropertyAccess.cpp:
354         (JSC::JIT::stringGetByValStubGenerator):
355         (JSC::JIT::privateCompilePutByIdTransition):
356         (JSC::JIT::privateCompilePatchGetArrayLength):
357         (JSC::JIT::privateCompileGetByIdProto):
358         (JSC::JIT::privateCompileGetByIdSelfList):
359         (JSC::JIT::privateCompileGetByIdProtoList):
360         (JSC::JIT::privateCompileGetByIdChainList):
361         (JSC::JIT::privateCompileGetByIdChain):
362         * jit/JITPropertyAccess32_64.cpp:
363         (JSC::JIT::stringGetByValStubGenerator):
364         (JSC::JIT::privateCompilePutByIdTransition):
365         (JSC::JIT::privateCompilePatchGetArrayLength):
366         (JSC::JIT::privateCompileGetByIdProto):
367         (JSC::JIT::privateCompileGetByIdSelfList):
368         (JSC::JIT::privateCompileGetByIdProtoList):
369         (JSC::JIT::privateCompileGetByIdChainList):
370         (JSC::JIT::privateCompileGetByIdChain):
371         * jit/JITStubs.cpp:
372         (JSC::JITThunks::tryCachePutByID):
373         (JSC::JITThunks::tryCacheGetByID):
374         (JSC::DEFINE_STUB_FUNCTION):
375         (JSC::getPolymorphicAccessStructureListSlot):
376         * jit/JITStubs.h:
377         * jit/SpecializedThunkJIT.h:
378         (JSC::SpecializedThunkJIT::finalize):
379         * runtime/ExceptionHelpers.cpp:
380         * runtime/ExceptionHelpers.h:
381         * runtime/Executable.cpp:
382         (JSC::EvalExecutable::compileInternal):
383         (JSC::ProgramExecutable::compileInternal):
384         (JSC::FunctionExecutable::compileForCallInternal):
385         (JSC::FunctionExecutable::compileForConstructInternal):
386         (JSC::FunctionExecutable::reparseExceptionInfo):
387         (JSC::EvalExecutable::reparseExceptionInfo):
388         * yarr/RegexJIT.cpp:
389         (JSC::Yarr::RegexGenerator::compile):
390
391 2010-08-26  Gavin Barraclough  <barraclough@apple.com>
392
393         Reviewed by Brady Eidson.
394
395         Bug 44655 - Add debug only convenience methods to obtain a Vector<char> from a String/StringImpl.
396
397         * wtf/text/WTFString.cpp:
398         (asciiDebug):
399             Return a Vector<char> containing the contents of a string as ASCII.
400
401 2010-08-26  Sam Weinig  <sam@webkit.org>
402
403         Reviewed by Darin Adler.
404
405         Add PassOwnArrayPtr
406         https://bugs.webkit.org/show_bug.cgi?id=44627
407
408         * GNUmakefile.am:
409         * JavaScriptCore.vcproj/WTF/WTF.vcproj:
410         * JavaScriptCore.xcodeproj/project.pbxproj:
411         Add the new files.
412
413         * wtf/Forward.h:
414         Forward declare PassOwnArrayPtr.
415         
416         * wtf/OwnArrayPtr.h:
417         Mimic the OwnPtr interface.
418
419         * wtf/OwnArrayPtrCommon.h: Added.
420         (WTF::deleteOwnedArrayPtr):
421         Move delete function here so it can be shared by OwnArrayPtr and
422         PassOwnArrayPtr.
423
424         * wtf/PassOwnArrayPtr.h: Added.
425         Mimic the PassOwnPtr interface.
426
427 2010-08-26  Oliver Hunt  <oliver@apple.com>
428
429         Reviewed by Gavin Barraclough.
430
431         [JSC] JavaScript parsing error when loading Equifax web page
432         https://bugs.webkit.org/show_bug.cgi?id=42900
433
434         '-->' is ostensibly only meant to occur when there is only
435         whitespace preceeding it on the line.  However firefox treats
436         multiline comments as a space character, so they are allowed.
437         One side effect of the firefox model is that any line terminators
438         inside the multiline comment are ignored, so
439
440             foo/*
441             */-->
442
443         is treated as
444
445             foo -->
446
447         and so '-->' will not be a comment in this case.  Happily this simply
448         means that to fix this issue all we need to do is stop updating
449         m_atLineStart when handling multiline comments.
450
451         * parser/Lexer.cpp:
452         (JSC::Lexer::lex):
453
454 2010-08-25  Oliver Hunt  <oliver@apple.com>
455
456         Reviewed by Geoffrey Garen.
457
458         Improve overflow handling in StringImpl::Replace
459         https://bugs.webkit.org/show_bug.cgi?id=42502
460         <rdar://problem/8203794>
461
462         Harden StringImpl::replace against overflow -- I can't see how this
463         could be abused, but it's better to be safe than sorry.
464
465         * wtf/text/StringImpl.cpp:
466         (WTF::StringImpl::replace):
467
468 2010-08-26  Martin Robinson  <mrobinson@igalia.com>
469
470         Reviewed by Xan Lopez.
471
472         [GTK] The GNUmakefile.am files contain a myriad of confusing preprocessor and compiler flag definitions
473         https://bugs.webkit.org/show_bug.cgi?id=44624
474
475         Clean up GNUmakefile.am.
476
477         * GNUmakefile.am: Alphabetize the include order in javascriptcore_cppflags. Move
478         a couple include lines from the top-level GNUmakefile.am.
479
480 2010-08-25  Xan Lopez  <xlopez@igalia.com>
481
482         Reviewed by Kent Tamura.
483
484         Local variables 'k' and 'y' in s2b() in dtoa.cpp are computed but not used
485         https://bugs.webkit.org/show_bug.cgi?id=29259
486
487         Remove unused code in dtoa.cpp, spotted by Wan-Teh Chang.
488
489         * wtf/dtoa.cpp:
490         (WTF::s2b):
491
492 2010-08-25  Kwang Yul Seo  <skyul@company100.net>
493
494         Reviewed by Kevin Ollivier.
495
496         [BREWMP] Add build system
497         https://bugs.webkit.org/show_bug.cgi?id=44645
498
499         Make waf script portable so that we can add more ports.
500
501         * wscript:
502
503 2010-08-25  Michael Saboff  <msaboff@apple.com>
504
505         Reviewed by Sam Weinig.
506
507         Remove the single entry regular expression cache introduced as part of
508         the fix for https://bugs.webkit.org/show_bug.cgi?id=41238.
509         The performance problem in Dromaeo that initiated that bug is no 
510         longer present. Dromaeo has been modified so that the regular
511         expression tests are somewhat random and don't benefit from a
512         single entry cache.
513
514         * runtime/RegExp.cpp:
515         (JSC::RegExp::RegExp):
516         (JSC::RegExp::match):
517         * runtime/RegExp.h:
518
519 2010-08-25  Martin Robinson  <mrobinson@igalia.com>
520
521         Reviewed by Gustavo Noronha Silva.
522
523         Cairo and EFL port shouldn't depend on glib.
524         https://bugs.webkit.org/show_bug.cgi?id=44354
525
526         Replace GRefPtr with PlatformRefPtr. Keep GLib specific bits in
527         GRefPtr.h.
528
529         * GNUmakefile.am: Add PlatformRefPtr.h to the source list.
530         * wtf/PlatformRefPtr.h: Migrated from GRefPtr.h.
531         (WTF::PlatformRefPtr::PlatformRefPtr): Ditto.
532         (WTF::PlatformRefPtr::~PlatformRefPtr): Ditto.
533         (WTF::PlatformRefPtr::clear): Ditto.
534         (WTF::PlatformRefPtr::get): Ditto.
535         (WTF::PlatformRefPtr::operator*): Ditto.
536         (WTF::PlatformRefPtr::operator->): Ditto.
537         (WTF::PlatformRefPtr::operator!): Ditto.
538         (WTF::PlatformRefPtr::operator UnspecifiedBoolType): Ditto.
539         (WTF::PlatformRefPtr::hashTableDeletedValue): Ditto.
540         (WTF::::operator): Ditto.
541         (WTF::::swap): Ditto.
542         (WTF::swap): Ditto.
543         (WTF::operator==): Ditto.
544         (WTF::operator!=): Ditto.
545         (WTF::static_pointer_cast): Ditto.
546         (WTF::const_pointer_cast): Ditto.
547         (WTF::getPtr): Ditto.
548         (WTF::adoptPlatformRef): Ditto.
549         * wtf/gobject/GRefPtr.cpp: Changes to reflect new names.
550         (WTF::refPlatformPtr):
551         (WTF::derefPlatformPtr):
552         * wtf/gobject/GRefPtr.h: Ditto.
553         (WTF::refPlatformPtr):
554         (WTF::derefPlatformPtr):
555
556 2010-08-25  Xan Lopez  <xlopez@igalia.com>
557
558         Reviewed by Alexey Proskuryakov.
559
560         Remove dead code in JSGlobalObject
561         https://bugs.webkit.org/show_bug.cgi?id=44615
562
563         The recursion data member in the JSGlobalObject and its getter
564         plus inc/dec methods seems to be unused, remove them.
565
566         * runtime/JSGlobalObject.cpp:
567         (JSC::JSGlobalObject::init):
568         * runtime/JSGlobalObject.h:
569
570 2010-08-25  Michael Saboff  <msaboff@apple.com>
571
572         Reviewed by Geoffrey Garen.
573
574         Changed the initial and subsequent allocation of vector storage to
575         Array()s. The changes are to limit sparse arrays to 100000 entries
576         and fixed the sparse map to vector storage conversion to use the 
577         minimum amount of memory needed to store the current number of entries.
578         These changes address https://bugs.webkit.org/show_bug.cgi?id=43707
579
580         * runtime/JSArray.cpp:
581         (JSC::JSArray::putSlowCase):
582         (JSC::JSArray::getNewVectorLength):
583
584 2010-08-16  Gabor Loki  <loki@webkit.org>
585
586         Reviewed by Gavin Barraclough.
587
588         Avoid increasing required alignment of target type warning
589         https://bugs.webkit.org/show_bug.cgi?id=43963
590
591         Fix platform independent alignment warnings.
592
593         * wtf/ListHashSet.h:
594         (WTF::ListHashSetNodeAllocator::pool):
595
596 2010-08-19  Gabor Loki  <loki@webkit.org>
597
598         Reviewed by Gavin Barraclough.
599
600         Enable truncated floating point feature on ARM
601         https://bugs.webkit.org/show_bug.cgi?id=44233
602
603         Enable truncated floating point feature with the help of VCVTR.S32.F64
604         instruction. If VCVTR.S32.F64 can't fit the result into a 32-bit
605         integer/register, it saturates at INT_MAX or INT_MIN. Testing this
606         looks quicker than testing FPSCR for exception.
607
608         Inspired by Jacob Bramley's patch from JaegerMonkey
609
610         * assembler/ARMAssembler.h:
611         (JSC::ARMAssembler::):
612         (JSC::ARMAssembler::cmn_r):
613         (JSC::ARMAssembler::vcvtr_s32_f64_r):
614         * assembler/MacroAssemblerARM.h:
615         (JSC::MacroAssemblerARM::supportsFloatingPointTruncate):
616         (JSC::MacroAssemblerARM::branchTruncateDoubleToInt32):
617
618 2010-08-24  Gavin Barraclough  <barraclough@apple.com>
619
620         Windows build fix.
621
622         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
623
624 2010-08-24  Gavin Barraclough  <barraclough@apple.com>
625
626         Windows build fix.
627
628         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
629         * wtf/DecimalNumber.h:
630         (WTF::DecimalNumber::intPow10):
631         * wtf/dtoa.cpp:
632         * wtf/dtoa.h:
633
634 2010-08-23  Gavin Barraclough  <barraclough@apple.com>
635
636         Reviewed by Oliver Hunt.
637
638         https://bugs.webkit.org/show_bug.cgi?id=44487
639
640         Number.toExponential/toFixed/toPrecision all contain a spaghetti of duplicated
641         code & unnecessary complexity. Add a new DecimalNumber class to encapsulate
642         double to string conversion, share the implementations of rounding &
643         decimal-fraction/exponential formatting.
644
645         * JavaScriptCore.exp:
646             Update exports.
647
648         * runtime/NumberPrototype.cpp:
649         (JSC::toThisNumber):
650         (JSC::getIntegerArgumentInRange):
651             Helper methods used in implementing toExponential/toFixed/toString.
652         (JSC::numberProtoFuncToExponential):
653         (JSC::numberProtoFuncToFixed):
654         (JSC::numberProtoFuncToPrecision):
655             Reimplemented using new DecimalNumber class.
656             
657         * runtime/UString.cpp:
658         (JSC::UString::number):
659             Updated to call numberToString.
660
661         * wtf/DecimalNumber.h: Added.
662         (WTF::):
663         (WTF::DecimalNumber::DecimalNumber):
664         (WTF::DecimalNumber::toStringDecimal):
665         (WTF::DecimalNumber::toStringExponential):
666         (WTF::DecimalNumber::sign):
667         (WTF::DecimalNumber::exponent):
668         (WTF::DecimalNumber::significand):
669         (WTF::DecimalNumber::precision):
670         (WTF::DecimalNumber::init):
671         (WTF::DecimalNumber::isZero):
672         (WTF::DecimalNumber::roundToPrecision):
673             New class to perform double to string conversion.
674             Has three constructors, which allow conversion with no rounding,
675             rounding to significant-figures, or rounding to decimal-places,
676             and two methods for formatting strings, either using decimal
677             fraction or exponential encoding. Internal implementation uses
678             pre-rounding of the values before calling dtoa rather than
679             relying on dtoa to correctly round, which does not produce
680             fully accurate results. Hopefully we can address this in the
681             near future.
682
683         * wtf/dtoa.cpp:
684         (WTF::intPow10):
685         * wtf/dtoa.h:
686             intPow10 is used internally by DecimalNumber.
687             
688         * wtf/text/WTFString.cpp:
689         (WTF::copyToString):
690         (WTF::nanOrInfToString):
691             Used internally in numberToString for NaN/Infinity handling.
692         (WTF::numberToString):
693             Added new method to convert doubles to strings.
694
695         * wtf/text/WTFString.h:
696             Added declaration for numberToString. This is here because
697             we should switch over to using this for all double to string
698             conversion in WebCore (see section 2.4.4.3 of the HTML5 spec).
699
700 2010-08-24  Oliver Hunt  <oliver@apple.com>
701
702         Reviewed by Geoff Garen.
703
704         Don't seed the JS random number generator from time()
705         https://bugs.webkit.org/show_bug.cgi?id=41868
706         <rdar://problem/8171025>
707
708         Switch to using the secure random number generator to
709         seed the fast random generator, and make the generator
710         be per global object.
711
712         * runtime/JSGlobalData.cpp:
713         (JSC::JSGlobalData::JSGlobalData):
714         * runtime/JSGlobalData.h:
715         * runtime/JSGlobalObject.h:
716         (JSC::JSGlobalObject::JSGlobalObjectData::JSGlobalObjectData):
717         (JSC::JSGlobalObject::weakRandomNumber):
718         * runtime/MathObject.cpp:
719         (JSC::mathProtoFuncRandom):
720
721 2010-08-24  Oliver Hunt  <oliver@apple.com>
722
723         Reviewed by Beth Dakin.
724
725         Make overflow guards in UString::utf8 explicit
726         https://bugs.webkit.org/show_bug.cgi?id=44540
727
728         Add an explicit overflow check prior to allocating our buffer,
729         rather than implicitly relying on the guard in convertUTF16ToUTF8.
730
731         * runtime/UString.cpp:
732         (JSC::UString::utf8):
733
734 2010-08-24  Yael Aharon  <yael.aharon@nokia.com>
735
736         Reviewed by Simon Hausmann.
737
738         [Symbian] Fix commit/decommit of system memory using RChunk
739
740         Swap accidentially reversed start and m_base values for determining the
741         offset within the RChunk.
742
743         * wtf/PageReservation.h:
744         (WTF::PageReservation::systemCommit):
745         (WTF::PageReservation::systemDecommit):
746
747 2010-08-23  Patrick Gansterer  <paroga@paroga.com>
748
749         Rubber-stamped by Gabor Loki.
750
751         [WINCE] Buildfix for GeneratedJITStubs after r64818
752         https://bugs.webkit.org/show_bug.cgi?id=44469
753
754         Use " THUNK_RETURN_ADDRESS_OFFSET" instead of "#offset#".
755
756         * jit/JITStubs.cpp:
757
758 2010-08-23  Oliver Hunt  <oliver@apple.com>
759
760         Reviewed by Darin Adler.
761
762         [REGRESSION] Interpreter incorrectly excludes prototype chain when validating put_by_id_transition
763         https://bugs.webkit.org/show_bug.cgi?id=44240
764         <rdar://problem/8328995>
765
766         Fix an error I introduced when cleaning up the interpreter side of the logic
767         to prevent setters being called in object initialisers.
768
769         * interpreter/Interpreter.cpp:
770         (JSC::Interpreter::privateExecute):
771
772 2010-08-23  Michael Saboff  <msaboff@apple.com>
773
774         Reviewed by Oliver Hunt.
775
776         Fixed case where a single character search string in a string.replace()
777         did not properly handle back reference replacement.  The fix is to 
778         check for a '$' as part of the check to see if we can execute the
779         single character replace optimization.
780         https://bugs.webkit.org/show_bug.cgi?id=44067
781
782         * runtime/StringPrototype.cpp:
783         (JSC::stringProtoFuncReplace):
784
785 2010-08-23  Oliver Hunt  <oliver@apple.com>
786
787         Reviewed by Gavin Barraclough.
788
789         JSON.stringify is much slower than Firefox on particular pathological input
790         https://bugs.webkit.org/show_bug.cgi?id=44456
791
792         Make StringBuilder::reserveCapacity reserve additional space so we don't end up
793         repeatedly copying the entire result string.
794
795         * runtime/StringBuilder.h:
796         (JSC::StringBuilder::append):
797         (JSC::StringBuilder::reserveCapacity):
798
799 2010-08-23  Jian Li  <jianli@chromium.org>
800
801         Reviewed by Darin Fisher.
802
803         Handle blob resource.
804         https://bugs.webkit.org/show_bug.cgi?id=43941
805
806         * JavaScriptCore.exp: Add an export that is neede by BlobResourceHandle.
807
808 2010-08-19  Andreas Kling  <andreas.kling@nokia.com>
809
810         Reviewed by Geoffrey Garen.
811
812         JSC: Move the static_cast into to(U)Int32 fast case
813         https://bugs.webkit.org/show_bug.cgi?id=44037
814
815         Do the static_cast<(u)int32_t> inline to avoid the function call overhead
816         for easily converted values (within (u)int32_t range.)
817
818         * runtime/JSValue.cpp:
819         (JSC::toInt32SlowCase):
820         (JSC::toUInt32SlowCase):
821         * runtime/JSValue.h:
822         (JSC::JSValue::toInt32):
823         (JSC::JSValue::toUInt32):
824
825 2010-08-18  Andreas Kling  <andreas.kling@nokia.com>
826
827         Reviewed by Geoffrey Garen.
828
829         REGRESSION(r58469): Math.pow() always returns double-backed JSValue which is extremely slow as array subscript
830         https://bugs.webkit.org/show_bug.cgi?id=43742
831
832         Add codegen for pow() to return Int32 values when possible.
833
834         * jit/ThunkGenerators.cpp:
835         (JSC::powThunkGenerator):
836
837 2010-08-18  Gabor Loki  <loki@webkit.org>
838
839         Reviewed by Gavin Barraclough.
840
841         The JITStackFrame is wrong using Thumb-2 JIT with JSVALUE32_64
842         https://bugs.webkit.org/show_bug.cgi?id=43897
843
844         A 64 bits wide member in a structure is aligned to 8 bytes on ARM by
845         default, but this is not taken into account in the offset defines of
846         JITStackFrame.
847
848         * jit/JITStubs.cpp:
849         * jit/JITStubs.h:
850
851 2010-08-18  Gavin Barraclough  <barraclough@apple.com>
852
853         Rubber stamped by Sam Weinig.
854
855         Rename UString::substr to substringSharingImpl, add to WTF::String.
856         Now WTF::String can do everything that JSC::UString can do!
857
858         * JavaScriptCore.exp:
859         * bytecode/CodeBlock.cpp:
860         (JSC::escapeQuotes):
861         * bytecompiler/NodesCodegen.cpp:
862         (JSC::substitute):
863         * parser/SourceProvider.h:
864         (JSC::UStringSourceProvider::getRange):
865         * runtime/FunctionPrototype.cpp:
866         (JSC::insertSemicolonIfNeeded):
867         * runtime/JSGlobalObjectFunctions.cpp:
868         (JSC::parseInt):
869         * runtime/JSONObject.cpp:
870         (JSC::gap):
871         (JSC::Stringifier::indent):
872         (JSC::Stringifier::unindent):
873         * runtime/JSString.cpp:
874         (JSC::JSString::replaceCharacter):
875         * runtime/NumberPrototype.cpp:
876         (JSC::numberProtoFuncToFixed):
877         (JSC::numberProtoFuncToPrecision):
878         * runtime/StringPrototype.cpp:
879         (JSC::stringProtoFuncReplace):
880         (JSC::trimString):
881         * runtime/UString.cpp:
882         (JSC::UString::substringSharingImpl):
883         * runtime/UString.h:
884         * wtf/text/WTFString.cpp:
885         (WTF::String::substringSharingImpl):
886         * wtf/text/WTFString.h:
887
888 2010-08-18  Gavin Barraclough  <barraclough@apple.com>
889
890         Windows build fix.
891
892         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
893         * JavaScriptCore.xcodeproj/project.pbxproj:
894
895 2010-08-18  Gavin Barraclough  <barraclough@apple.com>
896
897         Windows build fix.
898
899         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
900         * JavaScriptCore.xcodeproj/project.pbxproj:
901
902 2010-08-17  Gavin Barraclough  <barraclough@apple.com>
903
904         Reviewed by Sam Weinig.
905
906         Bug 44146 - Remove toDouble/toUInt32 methods from UString.
907
908         These methods all implement JavaScript language specific behaviour, and as such
909         are not suited to being on a generic string object.  They are also inefficient
910         and incorrectly used, refactor & cleanup.  Uses of these methods really divide
911         out into two cases.
912
913         ToNumber:
914         Uses of toDouble from JSString and from parseFloat are implementing ecma's
915         ToNumber conversion from strings (see ecma-262 9.3.1), so UString::toDouble
916         should largely just be moved out to a global jsToNumber function.  ToNumber is
917         capable of recognizing either decimal or hexadecimal numbers, but parseFloat
918         should only recognize decimal values.  This is currently handled by testing for
919         hexadecimal before calling toDouble, which should unnecessary - instead we can
920         just split out the two parts to the grammar into separate functions. Also,
921         strtod recognizes a set of literals (nan, inf, and infinity - all with any
922         capitalization) - which are not defined by any of the specs we are implementing.
923         To handle this we need to perform additional work in toDouble to convert the
924         unsupported cases of infinities back to NaNs.  Instead we should simply remove
925         support for this literals from strtod.  This should provide a more desirable
926         behaviour for all clients of strtod.
927
928         Indexed properties:
929         Uses of the toStrictUInt32 methods are were all converting property names to
930         indices, and all uses of toUInt32 were incorrect; in all cases we should have
931         been calling toUInt32.  This error results in some incorrect behaviour in the
932         DOM (accessing property "0 " of a NodeList should fail; it currently does not).
933         Move this method onto Identifier (our canonical property name), and make it
934         always perform a strict conversion. Add a layout test to check NodeList does
935         convert indexed property names correctly.
936
937         * JavaScriptCore.exp:
938         * runtime/Arguments.cpp:
939         (JSC::Arguments::getOwnPropertySlot):
940         (JSC::Arguments::getOwnPropertyDescriptor):
941         (JSC::Arguments::put):
942         (JSC::Arguments::deleteProperty):
943         * runtime/Identifier.cpp:
944         (JSC::Identifier::toUInt32):
945         * runtime/Identifier.h:
946         (JSC::Identifier::toUInt32):
947         * runtime/JSArray.cpp:
948         (JSC::JSArray::getOwnPropertySlot):
949         (JSC::JSArray::getOwnPropertyDescriptor):
950         (JSC::JSArray::put):
951         (JSC::JSArray::deleteProperty):
952         * runtime/JSArray.h:
953         (JSC::Identifier::toArrayIndex):
954         * runtime/JSByteArray.cpp:
955         (JSC::JSByteArray::getOwnPropertySlot):
956         (JSC::JSByteArray::getOwnPropertyDescriptor):
957         (JSC::JSByteArray::put):
958         * runtime/JSGlobalObjectFunctions.cpp:
959         (JSC::isInfinity):
960         (JSC::jsHexIntegerLiteral):
961         (JSC::jsStrDecimalLiteral):
962         (JSC::jsToNumber):
963         (JSC::parseFloat):
964         * runtime/JSGlobalObjectFunctions.h:
965         * runtime/JSString.cpp:
966         (JSC::JSString::getPrimitiveNumber):
967         (JSC::JSString::toNumber):
968         (JSC::JSString::getStringPropertyDescriptor):
969         * runtime/JSString.h:
970         (JSC::JSString::getStringPropertySlot):
971         * runtime/ObjectPrototype.cpp:
972         (JSC::ObjectPrototype::put):
973         * runtime/StringObject.cpp:
974         (JSC::StringObject::deleteProperty):
975         * runtime/UString.cpp:
976         * runtime/UString.h:
977         * wtf/dtoa.cpp:
978         (WTF::strtod):
979
980 2010-08-17  Gavin Barraclough  <barraclough@apple.com>
981
982         Reviewed by Sam Weinig.
983
984         Bug 44099 - REGRESSION(r65468): Crashes in StringImpl::find
985
986         Bug 44080 introuduced a couple of cases in which array bounds could be overrun.
987         One of these was fixed in r65493, this patch fixes the other and address the
988         concerns voiced in comment #6 by restructuring the loops to remove the code
989         dupliction without introducing an additional if check.
990
991         * wtf/text/StringImpl.cpp:
992         (WTF::StringImpl::find):
993         (WTF::StringImpl::findIgnoringCase):
994         (WTF::StringImpl::reverseFind):
995         (WTF::StringImpl::reverseFindIgnoringCase):
996
997 2010-08-17  No'am Rosenthal  <noam.rosenthal@nokia.com>
998
999         Reviewed by Ariya Hidayat.
1000
1001         [Qt] Move the accelerated compositing build flag to the right place
1002         https://bugs.webkit.org/show_bug.cgi?id=43882
1003
1004         * wtf/Platform.h:
1005
1006 2010-08-17  Yuta Kitamura  <yutak@chromium.org>
1007
1008         Reviewed by Shinichiro Hamaji.
1009
1010         Avoid uninitialized memory read in StringImpl::find().
1011
1012         REGRESSION(r65468): Crashes in StringImpl::find
1013         https://bugs.webkit.org/show_bug.cgi?id=44099
1014
1015         * wtf/text/StringImpl.cpp:
1016         (WTF::StringImpl::find):
1017
1018 2010-08-16  Gavin Barraclough  <barraclough@apple.com>
1019
1020         Rubber stamped by Sam Weinig
1021
1022         Add VectorTraits to String & DefaultHash traits to UString to unify behaviour.
1023
1024         * runtime/UString.h:
1025         (JSC::UStringHash::hash):
1026         (JSC::UStringHash::equal):
1027         (WTF::):
1028         * wtf/text/WTFString.h:
1029         (WTF::):
1030
1031 2010-08-16  Gavin Barraclough  <barraclough@apple.com>
1032
1033         Rubber stamped by Sam Weinig
1034
1035         Remove unnecessary includes from UString.h, add new includes as necessary.
1036
1037         * profiler/CallIdentifier.h:
1038         * profiler/ProfileNode.h:
1039         * runtime/DateConversion.cpp:
1040         * runtime/Identifier.h:
1041         (JSC::IdentifierRepHash::hash):
1042         * runtime/RegExpCache.h:
1043         * runtime/RegExpKey.h:
1044         * runtime/UString.cpp:
1045         (JSC::UString::substr):
1046         * runtime/UString.h:
1047         * wtf/text/WTFString.h:
1048
1049 2010-08-16  Gavin Barraclough  <barraclough@apple.com>
1050
1051         Reviewed by Sam Weinig
1052
1053         Bug 44080 - String find/reverseFind methods need tidying up
1054         These methods have a couple of problems with their interface, and implementation.
1055
1056         These methods take and int index, and return an int - however this is problematic
1057         since on 64-bit string indices may have a full 32-bit range.  This spills out into
1058         surrounding code, which unsafely casts string indices from unsigned to int. Code
1059         checking the result of these methods check for a mix of "== -1", "< 0", and
1060         "== notFound".  Clean this up by changing these methods to take an unsigned
1061         starting index, and return a size_t. with a failed match indicated by notFound.
1062         reverseFind also has a special meaning for the starting index argument, in that a
1063         negative index is interpreted as an offset back from the end of the string. Remove
1064         this functionality, in the (1!) case where it is used we should just calculate the
1065         offset by subtracting from the string's length.
1066
1067         The implementation has a few problems too.  The code is not in webkit style, in
1068         using assorted abbreviations in variable names, and implementations of similar
1069         find methods with differing argument types were unnecessarily inconsistent. When
1070         find is passed const char* data the string would be handled as latin1 (zero
1071         extended to UTF-16) for all characters but the first; this is sign extended.
1072         Case-insensitive find is broken for unicode strings; the hashing optimization is
1073         not unicode safe, and could result in false negatives.
1074
1075         Unify UString find methods to match String.
1076
1077         * JavaScriptCore.exp:
1078         * bytecode/CodeBlock.cpp:
1079         (JSC::escapeQuotes):
1080         * bytecompiler/NodesCodegen.cpp:
1081         (JSC::substitute):
1082         * runtime/JSString.cpp:
1083         (JSC::JSString::replaceCharacter):
1084         * runtime/RegExp.cpp:
1085         (JSC::RegExp::RegExp):
1086         * runtime/RegExpKey.h:
1087         (JSC::RegExpKey::getFlagsValue):
1088         * runtime/StringPrototype.cpp:
1089         (JSC::substituteBackreferencesSlow):
1090         (JSC::substituteBackreferences):
1091         (JSC::stringProtoFuncReplace):
1092         (JSC::stringProtoFuncIndexOf):
1093         (JSC::stringProtoFuncLastIndexOf):
1094         (JSC::stringProtoFuncSplit):
1095         * runtime/UString.cpp:
1096         * runtime/UString.h:
1097         (JSC::UString::find):
1098         (JSC::UString::reverseFind):
1099         * wtf/text/AtomicString.h:
1100         (WTF::AtomicString::find):
1101         * wtf/text/StringImpl.cpp:
1102         (WTF::StringImpl::find):
1103         (WTF::StringImpl::findCaseInsensitive):
1104         (WTF::StringImpl::reverseFind):
1105         (WTF::StringImpl::reverseFindCaseInsensitive):
1106         (WTF::StringImpl::endsWith):
1107         (WTF::StringImpl::replace):
1108         * wtf/text/StringImpl.h:
1109         (WTF::StringImpl::startsWith):
1110         * wtf/text/WTFString.cpp:
1111         (WTF::String::split):
1112         * wtf/text/WTFString.h:
1113         (WTF::String::find):
1114         (WTF::String::reverseFind):
1115         (WTF::String::findCaseInsensitive):
1116         (WTF::String::reverseFindCaseInsensitive):
1117         (WTF::String::contains):
1118         (WTF::find):
1119         (WTF::reverseFind):
1120
1121 2010-08-16  Kevin Ollivier  <kevino@theolliviers.com>
1122
1123         [wx] Build fix, do not build WebCore as a convenience library as this leads to
1124         errors in the Win build w/export symbols and causes problems with DOM bindings
1125         debugging in gdb. 
1126
1127         * wscript:
1128
1129 2010-08-16  Leandro Pereira  <leandro@profusion.mobi>
1130
1131         [EFL] Build fix after r65366.
1132
1133         * CMakeLists.txt: Use if (VAR) instead of if (${VAR}) to check if
1134         they're empty.
1135         * jsc/CMakeLists.txt: Ditto.
1136         * wtf/CMakeLists.txt: Ditto.
1137
1138 2010-08-15  Kevin Ollivier  <kevino@theolliviers.com>
1139
1140         [wx] Build fix, don't build intermediate source in DerivedSources dir.
1141
1142         * wscript:
1143
1144 2010-08-14  Patrick Gansterer  <paroga@paroga.com>
1145
1146         Reviewed by Kenneth Rohde Christiansen.
1147
1148         [CMake] Add preprocessor detection for generator scripts
1149         https://bugs.webkit.org/show_bug.cgi?id=43984
1150
1151         * CMakeLists.txt:
1152
1153 2010-08-14  Patrick Gansterer  <paroga@paroga.com>
1154
1155         Reviewed by Kenneth Rohde Christiansen.
1156
1157         [CMake] Set target properties only if available
1158         https://bugs.webkit.org/show_bug.cgi?id=43978
1159
1160         * CMakeLists.txt:
1161         * jsc/CMakeLists.txt:
1162         * wtf/CMakeLists.txt:
1163
1164 2010-08-13  Kevin Ollivier  <kevino@theolliviers.com>
1165
1166         [wx] Build fix, add CString to the list of forwards.
1167
1168         * wtf/Forward.h:
1169
1170 2010-08-13  Gavin Barraclough  <barraclough@apple.com>
1171
1172         Windows build fix
1173
1174         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1175
1176 2010-08-13  Gavin Barraclough  <barraclough@apple.com>
1177
1178         Windows build fix
1179
1180         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1181
1182 2010-08-13  Gavin Barraclough  <barraclough@apple.com>
1183
1184         Windows build fix
1185
1186         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1187
1188 2010-08-13  Gavin Barraclough  <barraclough@apple.com>
1189
1190         Rubber stamped by Sam Weinig.
1191         Switch String::/UString::ascii() to return a CString.
1192
1193         * JavaScriptCore.exp:
1194         * JavaScriptCore.xcodeproj/project.pbxproj:
1195         * bytecode/CodeBlock.cpp:
1196         (JSC::CodeBlock::dump):
1197         * bytecode/SamplingTool.cpp:
1198         (JSC::SamplingTool::dump):
1199         * interpreter/CallFrame.cpp:
1200         (JSC::CallFrame::dumpCaller):
1201         * jsc.cpp:
1202         (runWithScripts):
1203         (runInteractive):
1204         * runtime/Identifier.h:
1205         (JSC::Identifier::ascii):
1206         * runtime/ScopeChain.cpp:
1207         (JSC::ScopeChainNode::print):
1208         * runtime/UString.cpp:
1209         (JSC::UString::ascii):
1210         (JSC::UString::latin1):
1211         * runtime/UString.h:
1212         * wtf/text/StringImpl.cpp:
1213         (WTF::StringImpl::asciiOLD):
1214         * wtf/text/StringImpl.h:
1215         * wtf/text/WTFString.cpp:
1216         (WTF::String::ascii):
1217         (WTF::String::latin1):
1218         * wtf/text/WTFString.h:
1219
1220 2010-08-13  Gabor Loki  <loki@webkit.org>
1221
1222         Reviewed by Gavin Barraclough.
1223
1224         Avoid increasing required alignment of target type warning on ARM
1225         https://bugs.webkit.org/show_bug.cgi?id=38045
1226
1227         The reinterpret_cast<Type1*>([pointer to Type2]) expressions - where
1228         sizeof(Type1) > sizeof(Type2) - cause the following warning on ARM:
1229         increases required alignment of target type warnings.
1230         Casting the type of [pointer to Type2] object to void* bypasses the
1231         warning.
1232
1233         * assembler/ARMAssembler.cpp:
1234         (JSC::ARMAssembler::executableCopy):
1235         * assembler/AssemblerBuffer.h:
1236         (JSC::AssemblerBuffer::putShortUnchecked):
1237         (JSC::AssemblerBuffer::putIntUnchecked):
1238         (JSC::AssemblerBuffer::putInt64Unchecked):
1239         * interpreter/RegisterFile.h:
1240         (JSC::RegisterFile::RegisterFile):
1241         (JSC::RegisterFile::grow):
1242         * jit/JITStubs.cpp:
1243         * pcre/pcre_compile.cpp:
1244         (jsRegExpCompile):
1245         * runtime/JSArray.cpp:
1246         (JSC::JSArray::putSlowCase):
1247         (JSC::JSArray::increaseVectorLength):
1248         (JSC::JSArray::increaseVectorPrefixLength):
1249         (JSC::JSArray::shiftCount):
1250         (JSC::JSArray::unshiftCount):
1251         * wtf/FastMalloc.cpp:
1252         (WTF::PageHeapAllocator::New):
1253         (WTF::TCMalloc_Central_FreeList::Populate):
1254         * wtf/MD5.cpp:
1255         (WTF::reverseBytes):
1256         (WTF::MD5::addBytes):
1257         (WTF::MD5::checksum):
1258         * wtf/StdLibExtras.h:
1259         (isPointerTypeAlignmentOkay):
1260         (reinterpret_cast_ptr):
1261         * wtf/Vector.h:
1262         (WTF::VectorBuffer::inlineBuffer):
1263         * wtf/qt/StringQt.cpp:
1264         (WTF::String::String):
1265
1266 2010-08-13  Gavin Barraclough  <barraclough@apple.com>
1267
1268         Reviewed by Sam Weinig
1269
1270         Unify UString::UTF8String() & String::utf8() methods,
1271         remove UString::cost() & make atArrayIndex a free function.
1272
1273         * JavaScriptCore.exp:
1274         * bytecode/CodeBlock.cpp:
1275         (JSC::constantName):
1276         (JSC::idName):
1277         (JSC::CodeBlock::registerName):
1278         (JSC::regexpName):
1279         (JSC::printGlobalResolveInfo):
1280         (JSC::printStructureStubInfo):
1281         (JSC::CodeBlock::printStructure):
1282         (JSC::CodeBlock::printStructures):
1283         * jsc.cpp:
1284         (functionPrint):
1285         (functionDebug):
1286         (runInteractive):
1287         (fillBufferWithContentsOfFile):
1288         * pcre/pcre_exec.cpp:
1289         (Histogram::~Histogram):
1290         * profiler/CallIdentifier.h:
1291         (JSC::CallIdentifier::c_str):
1292         * profiler/Profile.cpp:
1293         (JSC::Profile::debugPrintDataSampleStyle):
1294         * profiler/ProfileGenerator.cpp:
1295         (JSC::ProfileGenerator::willExecute):
1296         (JSC::ProfileGenerator::didExecute):
1297         * profiler/ProfileNode.cpp:
1298         (JSC::ProfileNode::debugPrintData):
1299         (JSC::ProfileNode::debugPrintDataSampleStyle):
1300         * runtime/Arguments.cpp:
1301         (JSC::Arguments::getOwnPropertySlot):
1302         (JSC::Arguments::getOwnPropertyDescriptor):
1303         (JSC::Arguments::put):
1304         (JSC::Arguments::deleteProperty):
1305         * runtime/DateConversion.cpp:
1306         (JSC::parseDate):
1307         * runtime/Identifier.h:
1308         (JSC::Identifier::toStrictUInt32):
1309         * runtime/JSArray.cpp:
1310         (JSC::JSArray::getOwnPropertySlot):
1311         (JSC::JSArray::getOwnPropertyDescriptor):
1312         (JSC::JSArray::put):
1313         (JSC::JSArray::deleteProperty):
1314         * runtime/JSArray.h:
1315         (JSC::toArrayIndex):
1316         * runtime/JSGlobalObjectFunctions.cpp:
1317         (JSC::encode):
1318         (JSC::parseInt):
1319         (JSC::globalFuncJSCPrint):
1320         * runtime/JSString.h:
1321         (JSC::RopeBuilder::JSString):
1322         * runtime/UString.cpp:
1323         (JSC::UString::toDouble):
1324         (JSC::putUTF8Triple):
1325         (JSC::UString::utf8):
1326         * runtime/UString.h:
1327         (JSC::UString::~UString):
1328         (JSC::UString::isNull):
1329         (JSC::UString::isEmpty):
1330         (JSC::UString::impl):
1331         * wtf/text/WTFString.cpp:
1332         (WTF::String::utf8):
1333         * wtf/text/WTFString.h:
1334         (WTF::String::~String):
1335         (WTF::String::swap):
1336         (WTF::String::isNull):
1337         (WTF::String::isEmpty):
1338         (WTF::String::impl):
1339         (WTF::String::length):
1340         (WTF::String::String):
1341         (WTF::String::isHashTableDeletedValue):
1342
1343 2010-08-12  Zoltan Herczeg  <zherczeg@webkit.org>
1344
1345         Reviewed by Gavin Barraclough.
1346
1347         Refactoring the fpu code generator for the ARM port
1348         https://bugs.webkit.org/show_bug.cgi?id=43842
1349
1350         Support up to 32 double precision registers, and the
1351         recent VFP instruction formats. This patch is mainly
1352         a style change which keeps the current functionality.
1353
1354         * assembler/ARMAssembler.h:
1355         (JSC::ARMRegisters::):
1356         (JSC::ARMAssembler::):
1357         (JSC::ARMAssembler::emitInst):
1358         (JSC::ARMAssembler::emitDoublePrecisionInst):
1359         (JSC::ARMAssembler::emitSinglePrecisionInst):
1360         (JSC::ARMAssembler::vadd_f64_r):
1361         (JSC::ARMAssembler::vdiv_f64_r):
1362         (JSC::ARMAssembler::vsub_f64_r):
1363         (JSC::ARMAssembler::vmul_f64_r):
1364         (JSC::ARMAssembler::vcmp_f64_r):
1365         (JSC::ARMAssembler::vsqrt_f64_r):
1366         (JSC::ARMAssembler::vmov_vfp_r):
1367         (JSC::ARMAssembler::vmov_arm_r):
1368         (JSC::ARMAssembler::vcvt_f64_s32_r):
1369         (JSC::ARMAssembler::vcvt_s32_f64_r):
1370         (JSC::ARMAssembler::vmrs_apsr):
1371         * assembler/MacroAssemblerARM.h:
1372         (JSC::MacroAssemblerARM::addDouble):
1373         (JSC::MacroAssemblerARM::divDouble):
1374         (JSC::MacroAssemblerARM::subDouble):
1375         (JSC::MacroAssemblerARM::mulDouble):
1376         (JSC::MacroAssemblerARM::sqrtDouble):
1377         (JSC::MacroAssemblerARM::convertInt32ToDouble):
1378         (JSC::MacroAssemblerARM::branchDouble):
1379         (JSC::MacroAssemblerARM::branchConvertDoubleToInt32):
1380
1381 2010-08-12  Sheriff Bot  <webkit.review.bot@gmail.com>
1382
1383         Unreviewed, rolling out r65295.
1384         http://trac.webkit.org/changeset/65295
1385         https://bugs.webkit.org/show_bug.cgi?id=43950
1386
1387         It broke 4 sputnik tests (Requested by Ossy on #webkit).
1388
1389         * JavaScriptCore.exp:
1390         * bytecode/CodeBlock.cpp:
1391         (JSC::constantName):
1392         (JSC::idName):
1393         (JSC::CodeBlock::registerName):
1394         (JSC::regexpName):
1395         (JSC::printGlobalResolveInfo):
1396         (JSC::printStructureStubInfo):
1397         (JSC::CodeBlock::printStructure):
1398         (JSC::CodeBlock::printStructures):
1399         * jsc.cpp:
1400         (functionPrint):
1401         (functionDebug):
1402         (runInteractive):
1403         (fillBufferWithContentsOfFile):
1404         * pcre/pcre_exec.cpp:
1405         (Histogram::~Histogram):
1406         * profiler/CallIdentifier.h:
1407         (JSC::CallIdentifier::c_str):
1408         * profiler/Profile.cpp:
1409         (JSC::Profile::debugPrintDataSampleStyle):
1410         * profiler/ProfileGenerator.cpp:
1411         (JSC::ProfileGenerator::willExecute):
1412         (JSC::ProfileGenerator::didExecute):
1413         * profiler/ProfileNode.cpp:
1414         (JSC::ProfileNode::debugPrintData):
1415         (JSC::ProfileNode::debugPrintDataSampleStyle):
1416         * runtime/Arguments.cpp:
1417         (JSC::Arguments::getOwnPropertySlot):
1418         (JSC::Arguments::getOwnPropertyDescriptor):
1419         (JSC::Arguments::put):
1420         (JSC::Arguments::deleteProperty):
1421         * runtime/DateConversion.cpp:
1422         (JSC::parseDate):
1423         * runtime/Identifier.h:
1424         (JSC::Identifier::Identifier):
1425         (JSC::Identifier::toArrayIndex):
1426         * runtime/JSArray.cpp:
1427         (JSC::JSArray::getOwnPropertySlot):
1428         (JSC::JSArray::getOwnPropertyDescriptor):
1429         (JSC::JSArray::put):
1430         (JSC::JSArray::deleteProperty):
1431         * runtime/JSArray.h:
1432         * runtime/JSGlobalObjectFunctions.cpp:
1433         (JSC::encode):
1434         (JSC::parseInt):
1435         (JSC::globalFuncJSCPrint):
1436         * runtime/JSString.h:
1437         (JSC::RopeBuilder::JSString):
1438         * runtime/UString.cpp:
1439         (JSC::UString::toDouble):
1440         (JSC::UString::UTF8String):
1441         * runtime/UString.h:
1442         (JSC::UString::isNull):
1443         (JSC::UString::isEmpty):
1444         (JSC::UString::impl):
1445         (JSC::UString::cost):
1446         (JSC::UString::~UString):
1447         (JSC::UString::toArrayIndex):
1448         * wtf/text/WTFString.cpp:
1449         (WTF::String::utf8):
1450         * wtf/text/WTFString.h:
1451         (WTF::String::String):
1452         (WTF::String::isHashTableDeletedValue):
1453         (WTF::String::length):
1454         (WTF::String::operator[]):
1455         (WTF::String::isNull):
1456         (WTF::String::isEmpty):
1457         (WTF::String::impl):
1458
1459 2010-08-12  Gavin Barraclough  <barraclough@apple.com>
1460
1461         Windows build fix.
1462
1463         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1464
1465 2010-08-12  Gavin Barraclough  <barraclough@apple.com>
1466
1467         Reviewed by Sam Weinig
1468
1469         Unify UString::UTF8String() & String::utf8() methods,
1470         remove UString::cost() & make atArrayIndex a free function.
1471
1472         * JavaScriptCore.exp:
1473         * bytecode/CodeBlock.cpp:
1474         (JSC::constantName):
1475         (JSC::idName):
1476         (JSC::CodeBlock::registerName):
1477         (JSC::regexpName):
1478         (JSC::printGlobalResolveInfo):
1479         (JSC::printStructureStubInfo):
1480         (JSC::CodeBlock::printStructure):
1481         (JSC::CodeBlock::printStructures):
1482         * jsc.cpp:
1483         (functionPrint):
1484         (functionDebug):
1485         (runInteractive):
1486         (fillBufferWithContentsOfFile):
1487         * pcre/pcre_exec.cpp:
1488         (Histogram::~Histogram):
1489         * profiler/CallIdentifier.h:
1490         (JSC::CallIdentifier::c_str):
1491         * profiler/Profile.cpp:
1492         (JSC::Profile::debugPrintDataSampleStyle):
1493         * profiler/ProfileGenerator.cpp:
1494         (JSC::ProfileGenerator::willExecute):
1495         (JSC::ProfileGenerator::didExecute):
1496         * profiler/ProfileNode.cpp:
1497         (JSC::ProfileNode::debugPrintData):
1498         (JSC::ProfileNode::debugPrintDataSampleStyle):
1499         * runtime/Arguments.cpp:
1500         (JSC::Arguments::getOwnPropertySlot):
1501         (JSC::Arguments::getOwnPropertyDescriptor):
1502         (JSC::Arguments::put):
1503         (JSC::Arguments::deleteProperty):
1504         * runtime/DateConversion.cpp:
1505         (JSC::parseDate):
1506         * runtime/Identifier.h:
1507         (JSC::Identifier::toStrictUInt32):
1508         * runtime/JSArray.cpp:
1509         (JSC::JSArray::getOwnPropertySlot):
1510         (JSC::JSArray::getOwnPropertyDescriptor):
1511         (JSC::JSArray::put):
1512         (JSC::JSArray::deleteProperty):
1513         * runtime/JSArray.h:
1514         (JSC::toArrayIndex):
1515         * runtime/JSGlobalObjectFunctions.cpp:
1516         (JSC::encode):
1517         (JSC::parseInt):
1518         (JSC::globalFuncJSCPrint):
1519         * runtime/JSString.h:
1520         (JSC::RopeBuilder::JSString):
1521         * runtime/UString.cpp:
1522         (JSC::UString::toDouble):
1523         (JSC::putUTF8Triple):
1524         (JSC::UString::utf8):
1525         * runtime/UString.h:
1526         (JSC::UString::~UString):
1527         (JSC::UString::isNull):
1528         (JSC::UString::isEmpty):
1529         (JSC::UString::impl):
1530         * wtf/text/WTFString.cpp:
1531         (WTF::String::utf8):
1532         * wtf/text/WTFString.h:
1533         (WTF::String::~String):
1534         (WTF::String::swap):
1535         (WTF::String::isNull):
1536         (WTF::String::isEmpty):
1537         (WTF::String::impl):
1538         (WTF::String::length):
1539         (WTF::String::String):
1540         (WTF::String::isHashTableDeletedValue):
1541
1542 2010-08-12  Gavin Barraclough  <barraclough@apple.com>
1543
1544         Eeerk! - revert accidentally committed changes in UString!
1545
1546         * JavaScriptCore.exp:
1547         * runtime/UString.cpp:
1548         (JSC::UString::UString):
1549         * runtime/UString.h:
1550
1551 2010-08-12  Gavin Barraclough  <barraclough@apple.com>
1552
1553         Reviewed by Sam Weinig
1554
1555         Change UString constructors to match those in WTF::String.
1556         This changes behaviour of UString((char*)0) to create null
1557         strings, akin to UString() rather than UString::empty().
1558         (This matches String).  Remove unused constructors from
1559         UString, and add null-terminated UTF-16 constructor, to
1560         match String.  Move String's constructor into the .cpp to
1561         match UString.
1562
1563         * JavaScriptCore.exp:
1564         * debugger/DebuggerCallFrame.cpp:
1565         (JSC::DebuggerCallFrame::calculatedFunctionName):
1566         * runtime/RegExpKey.h:
1567         (JSC::RegExpKey::RegExpKey):
1568         * runtime/SmallStrings.cpp:
1569         (JSC::SmallStrings::createSingleCharacterString):
1570         * runtime/UString.cpp:
1571         (JSC::UString::UString):
1572         * runtime/UString.h:
1573         (JSC::UString::UString):
1574         (JSC::UString::swap):
1575         (JSC::UString::adopt):
1576         (JSC::UString::operator[]):
1577         * wtf/text/WTFString.h:
1578         (WTF::String::String):
1579         (WTF::String::adopt):
1580         (WTF::String::operator[]):
1581
1582 2010-08-12  David Levin  <levin@chromium.org>
1583
1584         Reviewed by NOBODY (build fix).
1585
1586         * runtime/UString.h: Removed unneccessary #include.
1587
1588 2010-08-12  Gavin Barraclough  <barraclough@apple.com>
1589
1590         Reviewed by Sam Weinig
1591
1592         Revert changes to ALWAYS_INLINEness of a couple of functions in UString.
1593         This appears to have degraded performance.
1594
1595         * runtime/UString.cpp:
1596         (JSC::UString::ascii):
1597         * runtime/UString.h:
1598         (JSC::UString::length):
1599         (JSC::UString::isEmpty):
1600         (JSC::UString::~UString):
1601
1602 2010-08-12  Csaba Osztrogonác  <ossy@webkit.org>
1603
1604         Reviewed by Antonio Gomes.
1605
1606         [Qt] Fix warnings: unknown conversion type character 'l' in format
1607         https://bugs.webkit.org/show_bug.cgi?id=43359
1608
1609         Qt port doesn't call any printf in String::format(...), consequently
1610         using __attribute__((format(printf,m,n))) is incorrect and causes
1611         false positive warnings on Windows if you build with MinGW.
1612
1613         Qt port calls QString::vsprintf(...) , which is platform
1614         independent, and handles %lli, %llu and %llx on all platforms.
1615         (http://trac.webkit.org/changeset/35712)
1616
1617         * wtf/text/WTFString.h:
1618
1619 2010-08-12  Gabor Loki  <loki@webkit.org>
1620
1621         Reviewed by Geoffrey Garen.
1622
1623         Fix the array subscript is above array bounds warning in ByteArray on ARM.
1624         https://bugs.webkit.org/show_bug.cgi?id=43358
1625
1626         The warning is very similar to this one: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37861
1627
1628         * wtf/ByteArray.cpp:
1629         (WTF::ByteArray::create):
1630
1631 2010-08-12  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
1632
1633         Reviewed by Martin Robinson.
1634
1635         [GTK] Use GSettings to save/restore Web Inspector settings
1636         https://bugs.webkit.org/show_bug.cgi?id=43512
1637
1638         * wtf/gobject/GRefPtr.cpp: Added support for GVariant, used by our
1639         GSettings support.
1640         (WTF::refGPtr):
1641         (WTF::derefGPtr):
1642         * wtf/gobject/GRefPtr.h:
1643
1644 2010-08-12  Gabor Loki  <loki@webkit.org>
1645
1646         Reviewed by Simon Hausmann.
1647
1648         The scratch register should be saved in YARR with ARM JIT
1649         https://bugs.webkit.org/show_bug.cgi?id=43910
1650
1651         Reported by Jocelyn Turcotte.
1652
1653         * yarr/RegexJIT.cpp:
1654         (JSC::Yarr::RegexGenerator::generateEnter):
1655         (JSC::Yarr::RegexGenerator::generateReturn):
1656
1657 2010-08-11  Gavin Barraclough  <barraclough@apple.com>
1658
1659         Windows build fix.
1660
1661         * JavaScriptCore.xcodeproj/project.pbxproj:
1662         * wtf/Forward.h:
1663
1664 2010-08-11  Leo Yang  <leo.yang@torchmobile.com.cn>
1665
1666         Reviewed by Geoffrey Garen.
1667
1668         Date("") should be an invalid date. For IE, Firefox and Chrome, Date("") is invalid date,
1669         which means isNaN(new Date("")) should return true.
1670         https://bugs.webkit.org/show_bug.cgi?id=43793
1671         Tests: fast/js/date-constructor.html
1672
1673         * runtime/JSGlobalData.cpp:
1674         (JSC::JSGlobalData::resetDateCache):
1675
1676 2010-08-11  Gavin Barraclough  <barraclough@apple.com>
1677
1678         Windows & !JIT build fix.
1679
1680         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1681         * JavaScriptCore.xcodeproj/project.pbxproj:
1682         * runtime/RegExp.cpp:
1683         (JSC::RegExp::match):
1684
1685 2010-08-11  Gavin Barraclough  <barraclough@apple.com>
1686
1687         Rubber stamp by sam weinig
1688
1689         Touch a file to stop the bot rolling a bit change out!
1690
1691         * runtime/UString.cpp:
1692         (JSC::UString::ascii):
1693
1694 2010-08-11  Kevin Ollivier  <kevino@theolliviers.com>
1695
1696         [wx] Build fix for wx and WebDOM bindings, add CString classes to the list of forwards.
1697
1698         * wtf/Forward.h:
1699
1700 2010-08-11  Gavin Barraclough  <barraclough@apple.com>
1701
1702         Rubber stamps by Darin Adler & Sam Weinig.
1703
1704         Bug 43867 - Some UString cleanup
1705
1706         Change JSC::UString data(), size(), and from(), to characters(), length(), and number() to match WTF::String.
1707         Move string concatenation methods to a new header to simplify down UString.h.  Remove is8Bit().
1708
1709         * API/JSClassRef.cpp:
1710         (OpaqueJSClass::~OpaqueJSClass):
1711         (OpaqueJSClass::className):
1712         * API/OpaqueJSString.cpp:
1713         (OpaqueJSString::create):
1714         * JavaScriptCore.exp:
1715         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1716         * JavaScriptCore.xcodeproj/project.pbxproj:
1717         * bytecode/CodeBlock.cpp:
1718         (JSC::constantName):
1719         (JSC::idName):
1720         (JSC::CodeBlock::registerName):
1721         (JSC::regexpName):
1722         * bytecode/EvalCodeCache.h:
1723         (JSC::EvalCodeCache::get):
1724         * bytecompiler/NodesCodegen.cpp:
1725         (JSC::ResolveNode::emitBytecode):
1726         (JSC::FunctionCallResolveNode::emitBytecode):
1727         (JSC::ReadModifyResolveNode::emitBytecode):
1728         (JSC::processClauseList):
1729         * parser/ASTBuilder.h:
1730         (JSC::ASTBuilder::createRegex):
1731         * parser/ParserArena.h:
1732         (JSC::IdentifierArena::makeNumericIdentifier):
1733         * parser/SourceProvider.h:
1734         (JSC::UStringSourceProvider::data):
1735         (JSC::UStringSourceProvider::length):
1736         * profiler/Profiler.cpp:
1737         * runtime/Arguments.cpp:
1738         (JSC::Arguments::getOwnPropertySlot):
1739         (JSC::Arguments::getOwnPropertyNames):
1740         (JSC::Arguments::put):
1741         (JSC::Arguments::deleteProperty):
1742         * runtime/ArrayPrototype.cpp:
1743         (JSC::arrayProtoFuncToString):
1744         * runtime/DatePrototype.cpp:
1745         (JSC::formatLocaleDate):
1746         * runtime/ExceptionHelpers.cpp:
1747         * runtime/FunctionConstructor.cpp:
1748         * runtime/FunctionPrototype.cpp:
1749         (JSC::insertSemicolonIfNeeded):
1750         * runtime/Identifier.h:
1751         (JSC::Identifier::characters):
1752         (JSC::Identifier::length):
1753         * runtime/JSGlobalObjectFunctions.cpp:
1754         (JSC::decode):
1755         (JSC::parseInt):
1756         (JSC::parseFloat):
1757         (JSC::globalFuncEscape):
1758         (JSC::globalFuncUnescape):
1759         * runtime/JSNumberCell.cpp:
1760         (JSC::JSNumberCell::toString):
1761         * runtime/JSONObject.cpp:
1762         (JSC::gap):
1763         (JSC::Stringifier::appendQuotedString):
1764         (JSC::Stringifier::appendStringifiedValue):
1765         (JSC::Stringifier::indent):
1766         (JSC::Stringifier::unindent):
1767         (JSC::Walker::walk):
1768         * runtime/JSString.cpp:
1769         (JSC::JSString::replaceCharacter):
1770         (JSC::JSString::getIndexSlowCase):
1771         * runtime/JSString.h:
1772         (JSC::RopeBuilder::JSString):
1773         (JSC::RopeBuilder::appendValueInConstructAndIncrementLength):
1774         (JSC::RopeBuilder::fiberCount):
1775         (JSC::jsSingleCharacterSubstring):
1776         (JSC::jsNontrivialString):
1777         (JSC::JSString::getIndex):
1778         (JSC::jsString):
1779         (JSC::jsStringWithFinalizer):
1780         (JSC::jsSubstring):
1781         (JSC::jsOwnedString):
1782         * runtime/JSStringBuilder.h:
1783         (JSC::JSStringBuilder::append):
1784         * runtime/LiteralParser.h:
1785         (JSC::LiteralParser::Lexer::Lexer):
1786         * runtime/NumberPrototype.cpp:
1787         (JSC::numberProtoFuncToString):
1788         (JSC::numberProtoFuncToFixed):
1789         (JSC::numberProtoFuncToExponential):
1790         (JSC::numberProtoFuncToPrecision):
1791         * runtime/NumericStrings.h:
1792         (JSC::NumericStrings::add):
1793         (JSC::NumericStrings::lookupSmallString):
1794         * runtime/Operations.h:
1795         (JSC::jsString):
1796         * runtime/RegExp.cpp:
1797         (JSC::RegExp::match):
1798         * runtime/RegExpCache.cpp:
1799         (JSC::RegExpCache::lookupOrCreate):
1800         (JSC::RegExpCache::create):
1801         * runtime/RegExpConstructor.cpp:
1802         (JSC::RegExpConstructor::getRightContext):
1803         * runtime/RegExpObject.cpp:
1804         (JSC::RegExpObject::match):
1805         * runtime/RegExpPrototype.cpp:
1806         (JSC::regExpProtoFuncToString):
1807         * runtime/StringBuilder.h:
1808         (JSC::StringBuilder::append):
1809         * runtime/StringConcatenate.h: Copied from JavaScriptCore/runtime/UString.h.
1810         (JSC::):
1811         (JSC::sumWithOverflow):
1812         (JSC::tryMakeString):
1813         (JSC::makeString):
1814         * runtime/StringObject.cpp:
1815         (JSC::StringObject::getOwnPropertyNames):
1816         * runtime/StringPrototype.cpp:
1817         (JSC::substituteBackreferencesSlow):
1818         (JSC::localeCompare):
1819         (JSC::jsSpliceSubstringsWithSeparators):
1820         (JSC::stringProtoFuncReplace):
1821         (JSC::stringProtoFuncCharAt):
1822         (JSC::stringProtoFuncCharCodeAt):
1823         (JSC::stringProtoFuncIndexOf):
1824         (JSC::stringProtoFuncLastIndexOf):
1825         (JSC::stringProtoFuncSlice):
1826         (JSC::stringProtoFuncSplit):
1827         (JSC::stringProtoFuncSubstr):
1828         (JSC::stringProtoFuncSubstring):
1829         (JSC::stringProtoFuncToLowerCase):
1830         (JSC::stringProtoFuncToUpperCase):
1831         (JSC::stringProtoFuncFontsize):
1832         (JSC::stringProtoFuncLink):
1833         (JSC::trimString):
1834         * runtime/UString.cpp:
1835         (JSC::UString::number):
1836         (JSC::UString::ascii):
1837         (JSC::UString::operator[]):
1838         (JSC::UString::toDouble):
1839         (JSC::UString::find):
1840         (JSC::UString::rfind):
1841         (JSC::UString::substr):
1842         (JSC::operator==):
1843         (JSC::operator<):
1844         (JSC::operator>):
1845         (JSC::UString::UTF8String):
1846         * runtime/UString.h:
1847         (JSC::UString::UString):
1848         (JSC::UString::adopt):
1849         (JSC::UString::length):
1850         (JSC::UString::characters):
1851         (JSC::UString::isNull):
1852         (JSC::UString::isEmpty):
1853         (JSC::UString::impl):
1854         (JSC::UString::cost):
1855         (JSC::operator==):
1856         (JSC::operator!=):
1857         (JSC::codePointCompare):
1858         (JSC::UString::toArrayIndex):
1859         (JSC::IdentifierRepHash::hash):
1860         (WTF::):
1861         * yarr/RegexJIT.cpp:
1862         (JSC::Yarr::jitCompileRegex):
1863         * yarr/RegexParser.h:
1864         (JSC::Yarr::Parser::Parser):
1865
1866 2010-08-11  Gabor Loki  <loki@webkit.org>
1867
1868         Qt build fix (ARMv7).
1869
1870         Fix invalid conversion from int to Condition.
1871         Add ARMv7Assembler.cpp to JavaScriptCore.pro.
1872
1873         * JavaScriptCore.pro:
1874         * assembler/ARMv7Assembler.h:
1875         (JSC::ARMv7Assembler::):
1876         (JSC::ARMv7Assembler::JmpSrc::JmpSrc):
1877
1878 2010-08-11  Nathan Lawrence  <nlawrence@apple.com>
1879
1880         Reviewed by Geoffrey Garen.
1881
1882         At collection time, we frequently want to mark a cell, while checking
1883         whether it was originally checked.  Previously, this was a get
1884         operation follwed by a set operation.  Fusing the two saves
1885         computation and gives a 0.5% sunspider speedup.
1886
1887         * runtime/Collector.h:
1888         (JSC::CollectorBitmap::getset):
1889         (JSC::Heap::checkMarkCell):
1890         * runtime/JSArray.h:
1891         (JSC::MarkStack::drain):
1892         * runtime/JSCell.h:
1893         (JSC::MarkStack::append):
1894
1895 2010-08-11  Steve Falkenburg  <sfalken@apple.com>
1896
1897         Reviewed by Adam Roben.
1898
1899         Improve vsprops copying for Windows build
1900         https://bugs.webkit.org/show_bug.cgi?id=41982
1901
1902         When we detect a new SDK, always copy a new set of vsprops files.
1903         Previously, if someone updated their SDK after updating their sources,
1904         they could end up with out-of-date vsprops files.
1905
1906         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCoreGenerated.make:
1907
1908 2010-08-10  Darin Adler  <darin@apple.com>
1909
1910         Reviewed by Sam Weinig.
1911
1912         Add leakRef and clear to all RefPtr variants
1913         https://bugs.webkit.org/show_bug.cgi?id=42389
1914
1915         * API/JSRetainPtr.h: Changed all uses of "template <...>" to instead do
1916         "template<...>". We should probably put this in the style guide and do it
1917         consitently. Fixed other minor style issues. Defined many of the inlined
1918         functions outside the class definition, to avoid style checker warnings
1919         about multiple statements on a single line and for slightly better clarity
1920         of the class definition itself. Renamed releaseRef to leakRef. Added a
1921         releaseRef that calls leakRef so we don't have to rename all callers oat
1922         once. Added a clear function.
1923
1924         * wtf/PassRefPtr.h: Changed all uses of releaseRef to leakRef.
1925
1926         * wtf/RefPtr.h: Changed all uses of "template <...>" to instead do
1927         "template<...>". Tidied up declarations and comments a bit.
1928          Changed all uses of releaseRef to leakRef.
1929
1930         * wtf/RetainPtr.h: Changed all uses of "template <...>" to instead do
1931         "template<...>". Defined many of the inlined functions outside the class
1932         definition, to avoid style checker warnings about multiple statements on
1933         a single line and for slightly better clarity of the class definition itself.
1934         Renamed releaseRef to leakRef. Added a releaseRef that calls leakRef so we
1935         don't have to rename all callers at once. Added a clear function.
1936
1937 2010-08-10  Dumitru Daniliuc  <dumi@chromium.org>
1938
1939         Unreviewed, reverting an unintentional change to a file submitted in r65108.
1940
1941         * bytecode/CodeBlock.h:
1942         (JSC::binaryChop):
1943
1944 2010-08-10  Gavin Barraclough  <barraclough@apple.com>
1945
1946         Rubber stamped by Sam Weinig
1947
1948         Bug 43817 - Remove UString::Rep
1949         UString::Rep has for a long time been replaced by UStringImpl (Rep
1950         remaining as a typedef).  UStringImpl has since been removed too
1951         (unified with StringImpl). Remove Rep, rename rep() to impl() and
1952         m_rep to m_impl.  Also add impl() method to Identifier, and rename
1953         its UString member from _ustring to m_string.
1954
1955         * API/JSCallbackObject.h:
1956         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::getPrivateProperty):
1957         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::setPrivateProperty):
1958         (JSC::JSCallbackObjectData::JSPrivatePropertyMap::deletePrivateProperty):
1959         * API/JSCallbackObjectFunctions.h:
1960         (JSC::::getOwnPropertySlot):
1961         (JSC::::put):
1962         (JSC::::deleteProperty):
1963         (JSC::::getOwnPropertyNames):
1964         (JSC::::staticValueGetter):
1965         (JSC::::staticFunctionGetter):
1966         * API/JSClassRef.cpp:
1967         (tryCreateStringFromUTF8):
1968         (OpaqueJSClass::OpaqueJSClass):
1969         (OpaqueJSClass::~OpaqueJSClass):
1970         (OpaqueJSClassContextData::OpaqueJSClassContextData):
1971         * API/JSClassRef.h:
1972         * API/OpaqueJSString.cpp:
1973         (OpaqueJSString::ustring):
1974         * bytecode/EvalCodeCache.h:
1975         (JSC::EvalCodeCache::get):
1976         * bytecode/JumpTable.h:
1977         (JSC::StringJumpTable::offsetForValue):
1978         (JSC::StringJumpTable::ctiForValue):
1979         * bytecompiler/BytecodeGenerator.cpp:
1980         (JSC::BytecodeGenerator::addVar):
1981         (JSC::BytecodeGenerator::addGlobalVar):
1982         (JSC::BytecodeGenerator::BytecodeGenerator):
1983         (JSC::BytecodeGenerator::addParameter):
1984         (JSC::BytecodeGenerator::registerFor):
1985         (JSC::BytecodeGenerator::willResolveToArguments):
1986         (JSC::BytecodeGenerator::uncheckedRegisterForArguments):
1987         (JSC::BytecodeGenerator::constRegisterFor):
1988         (JSC::BytecodeGenerator::isLocal):
1989         (JSC::BytecodeGenerator::isLocalConstant):
1990         (JSC::BytecodeGenerator::addConstant):
1991         (JSC::BytecodeGenerator::emitLoad):
1992         (JSC::BytecodeGenerator::findScopedProperty):
1993         (JSC::keyForCharacterSwitch):
1994         (JSC::prepareJumpTableForStringSwitch):
1995         * bytecompiler/BytecodeGenerator.h:
1996         * bytecompiler/NodesCodegen.cpp:
1997         (JSC::processClauseList):
1998         * interpreter/Interpreter.cpp:
1999         (JSC::Interpreter::privateExecute):
2000         * jit/JITStubs.cpp:
2001         (JSC::DEFINE_STUB_FUNCTION):
2002         * parser/JSParser.cpp:
2003         (JSC::JSParser::parseStrictObjectLiteral):
2004         * pcre/pcre_exec.cpp:
2005         (Histogram::add):
2006         * profiler/CallIdentifier.h:
2007         (JSC::CallIdentifier::Hash::hash):
2008         * profiler/Profile.cpp:
2009         * profiler/ProfileNode.cpp:
2010         (JSC::ProfileNode::debugPrintDataSampleStyle):
2011         * profiler/ProfileNode.h:
2012         * runtime/ArrayPrototype.cpp:
2013         (JSC::arrayProtoFuncToString):
2014         * runtime/Identifier.cpp:
2015         (JSC::Identifier::equal):
2016         (JSC::IdentifierCStringTranslator::hash):
2017         (JSC::IdentifierCStringTranslator::equal):
2018         (JSC::IdentifierCStringTranslator::translate):
2019         (JSC::Identifier::add):
2020         (JSC::IdentifierUCharBufferTranslator::hash):
2021         (JSC::IdentifierUCharBufferTranslator::equal):
2022         (JSC::IdentifierUCharBufferTranslator::translate):
2023         (JSC::Identifier::addSlowCase):
2024         * runtime/Identifier.h:
2025         (JSC::Identifier::Identifier):
2026         (JSC::Identifier::ustring):
2027         (JSC::Identifier::impl):
2028         (JSC::Identifier::data):
2029         (JSC::Identifier::size):
2030         (JSC::Identifier::ascii):
2031         (JSC::Identifier::isNull):
2032         (JSC::Identifier::isEmpty):
2033         (JSC::Identifier::toUInt32):
2034         (JSC::Identifier::toStrictUInt32):
2035         (JSC::Identifier::toArrayIndex):
2036         (JSC::Identifier::toDouble):
2037         (JSC::Identifier::equal):
2038         (JSC::Identifier::add):
2039         * runtime/InitializeThreading.cpp:
2040         (JSC::initializeThreadingOnce):
2041         * runtime/InternalFunction.cpp:
2042         (JSC::InternalFunction::displayName):
2043         * runtime/JSFunction.cpp:
2044         (JSC::JSFunction::displayName):
2045         * runtime/JSGlobalObject.h:
2046         (JSC::JSGlobalObject::addStaticGlobals):
2047         * runtime/JSStaticScopeObject.h:
2048         (JSC::JSStaticScopeObject::JSStaticScopeObject):
2049         * runtime/JSString.h:
2050         (JSC::):
2051         (JSC::RopeBuilder::appendStringInConstruct):
2052         (JSC::RopeBuilder::appendValueInConstructAndIncrementLength):
2053         (JSC::jsSingleCharacterSubstring):
2054         (JSC::jsSubstring):
2055         * runtime/JSVariableObject.cpp:
2056         (JSC::JSVariableObject::deleteProperty):
2057         (JSC::JSVariableObject::symbolTableGet):
2058         * runtime/JSVariableObject.h:
2059         (JSC::JSVariableObject::symbolTableGet):
2060         (JSC::JSVariableObject::symbolTablePut):
2061         (JSC::JSVariableObject::symbolTablePutWithAttributes):
2062         * runtime/Lookup.cpp:
2063         (JSC::HashTable::createTable):
2064         (JSC::HashTable::deleteTable):
2065         * runtime/Lookup.h:
2066         (JSC::HashEntry::initialize):
2067         (JSC::HashEntry::setKey):
2068         (JSC::HashEntry::key):
2069         (JSC::HashTable::entry):
2070         * runtime/PropertyMapHashTable.h:
2071         (JSC::PropertyMapEntry::PropertyMapEntry):
2072         * runtime/PropertyNameArray.cpp:
2073         (JSC::PropertyNameArray::add):
2074         * runtime/PropertyNameArray.h:
2075         (JSC::PropertyNameArray::add):
2076         (JSC::PropertyNameArray::addKnownUnique):
2077         * runtime/RegExp.cpp:
2078         (JSC::RegExp::match):
2079         * runtime/RegExpCache.cpp:
2080         (JSC::RegExpCache::create):
2081         * runtime/RegExpKey.h:
2082         (JSC::RegExpKey::RegExpKey):
2083         * runtime/SmallStrings.cpp:
2084         (JSC::SmallStringsStorage::rep):
2085         (JSC::SmallStrings::singleCharacterStringRep):
2086         * runtime/SmallStrings.h:
2087         * runtime/StringPrototype.cpp:
2088         (JSC::jsSpliceSubstringsWithSeparators):
2089         (JSC::stringProtoFuncMatch):
2090         (JSC::stringProtoFuncSearch):
2091         * runtime/Structure.cpp:
2092         (JSC::Structure::~Structure):
2093         (JSC::Structure::despecifyDictionaryFunction):
2094         (JSC::Structure::addPropertyTransitionToExistingStructure):
2095         (JSC::Structure::addPropertyTransition):
2096         (JSC::Structure::copyPropertyTable):
2097         (JSC::Structure::get):
2098         (JSC::Structure::despecifyFunction):
2099         (JSC::Structure::put):
2100         (JSC::Structure::hasTransition):
2101         (JSC::Structure::remove):
2102         (JSC::Structure::checkConsistency):
2103         * runtime/Structure.h:
2104         (JSC::Structure::get):
2105         (JSC::Structure::hasTransition):
2106         * runtime/StructureTransitionTable.h:
2107         * runtime/SymbolTable.h:
2108         * runtime/UString.cpp:
2109         (JSC::UString::UString):
2110         (JSC::UString::toStrictUInt32):
2111         (JSC::UString::substr):
2112         * runtime/UString.h:
2113         (JSC::UString::UString):
2114         (JSC::UString::adopt):
2115         (JSC::UString::data):
2116         (JSC::UString::size):
2117         (JSC::UString::isNull):
2118         (JSC::UString::isEmpty):
2119         (JSC::UString::impl):
2120         (JSC::UString::cost):
2121         (JSC::operator==):
2122         (JSC::codePointCompare):
2123         (JSC::IdentifierRepHash::hash):
2124         (WTF::):
2125
2126 2010-08-10  Gavin Barraclough  <barraclough@apple.com>
2127
2128         Bug 43816 - Remove UStringImpl
2129         The class was actually removed a long time ago, replaced by StringImpl.
2130         UStringImpl is just a typedef onto StringImpl.  Remove this.
2131
2132         * API/JSClassRef.cpp:
2133         (OpaqueJSClass::OpaqueJSClass):
2134         * JavaScriptCore.xcodeproj/project.pbxproj:
2135         * runtime/JSString.cpp:
2136         (JSC::JSString::resolveRope):
2137         (JSC::JSString::replaceCharacter):
2138         * runtime/JSString.h:
2139         (JSC::RopeBuilder::RopeIterator::operator*):
2140         (JSC::RopeBuilder::JSString):
2141         (JSC::RopeBuilder::appendStringInConstruct):
2142         (JSC::RopeBuilder::appendValueInConstructAndIncrementLength):
2143         (JSC::jsSingleCharacterSubstring):
2144         (JSC::jsSubstring):
2145         * runtime/JSStringBuilder.h:
2146         (JSC::jsMakeNontrivialString):
2147         * runtime/RopeImpl.cpp:
2148         (JSC::RopeImpl::derefFibersNonRecursive):
2149         * runtime/RopeImpl.h:
2150         (JSC::RopeImpl::deref):
2151         * runtime/SmallStrings.cpp:
2152         (JSC::SmallStringsStorage::SmallStringsStorage):
2153         * runtime/StringConstructor.cpp:
2154         (JSC::stringFromCharCodeSlowCase):
2155         * runtime/StringPrototype.cpp:
2156         (JSC::jsSpliceSubstringsWithSeparators):
2157         (JSC::stringProtoFuncFontsize):
2158         (JSC::stringProtoFuncLink):
2159         * runtime/UString.cpp:
2160         (JSC::initializeUString):
2161         * runtime/UString.h:
2162         (JSC::UString::adopt):
2163         (JSC::tryMakeString):
2164         (JSC::makeString):
2165         * runtime/UStringImpl.h: Removed.
2166
2167 2010-08-10  Patrick Gansterer  <paroga@paroga.com>
2168
2169         Reviewed by Eric Seidel.
2170
2171         Make FastMalloc more portable.
2172         https://bugs.webkit.org/show_bug.cgi?id=41790
2173
2174         * wtf/FastMalloc.cpp:
2175         (WTF::TCMalloc_Central_FreeList::Populate):
2176         (WTF::TCMalloc_ThreadCache::CreateCacheIfNecessary):
2177
2178 2010-08-10  Patrick Gansterer  <paroga@paroga.com>
2179
2180         Reviewed by David Levin.
2181
2182         [WINCE] Buildfix for CE 6.0
2183         https://bugs.webkit.org/show_bug.cgi?id=43027
2184
2185         CE 6.0 doesn't define localtime in the system include files.
2186
2187         * wtf/Platform.h: Include ce_time.h on all OS(WINCE).
2188
2189 2010-08-10  Gavin Barraclough  <barraclough@apple.com>
2190
2191         Rubber stamped by Sam Weinig.
2192
2193         Bug 43786 - Move AtomicStringHash from WebCore to WTF
2194         Also remove deprecated string headers from WebCore/platform/text.
2195
2196         * GNUmakefile.am:
2197         * JavaScriptCore.gypi:
2198         * JavaScriptCore.vcproj/WTF/WTF.vcproj:
2199         * JavaScriptCore.xcodeproj/project.pbxproj:
2200         * wtf/text/AtomicString.h:
2201         * wtf/text/AtomicStringHash.h: Copied from WebCore/platform/text/AtomicStringHash.h.
2202
2203 2010-08-09  Oliver Hunt  <oliver@apple.com>
2204
2205         Fix Qt/ARM again, this time including the other changed file.
2206
2207         * jit/JIT.h:
2208
2209 2010-08-09  Oliver Hunt  <oliver@apple.com>
2210
2211         Fix Qt/ARM
2212
2213         C++ overload resolution I stab at thee
2214
2215         * jit/JITInlineMethods.h:
2216         (JSC::JIT::beginUninterruptedSequence):
2217         (JSC::JIT::endUninterruptedSequence):
2218
2219 2010-08-09  Oliver Hunt  <oliver@apple.com>
2220
2221         Reviewed by Gavin Barraclough.
2222
2223         Allow an assembler/macroassembler to compact branches to more concise forms when linking
2224         https://bugs.webkit.org/show_bug.cgi?id=43745
2225
2226         This patch makes it possible for an assembler to convert jumps into a different
2227         (presumably more efficient) form at link time.  Currently implemented in the
2228         ARMv7 JIT as that already had logic to delay linking of jumps until the end of
2229         compilation already.  The ARMv7 JIT chooses between either a 4 byte short jump
2230         or a full 32-bit offset (and rewrites ITTT instructions as appropriate), so does
2231         not yet produce the most compact form possible.  The general design of the linker
2232         should make it relatively simple to introduce new branch types with little effort,
2233         as the linker has no knowledge of the exact form of any of the branches.
2234
2235         * JavaScriptCore.xcodeproj/project.pbxproj:
2236         * assembler/ARMv7Assembler.cpp: Added.
2237         (JSC::):
2238           Record jump sizes
2239
2240         * assembler/ARMv7Assembler.h:
2241         (JSC::ARMv7Assembler::LinkRecord::LinkRecord):
2242         (JSC::ARMv7Assembler::LinkRecord::from):
2243         (JSC::ARMv7Assembler::LinkRecord::setFrom):
2244         (JSC::ARMv7Assembler::LinkRecord::to):
2245         (JSC::ARMv7Assembler::LinkRecord::type):
2246         (JSC::ARMv7Assembler::LinkRecord::linkType):
2247         (JSC::ARMv7Assembler::LinkRecord::setLinkType):
2248           Encapsulate LinkRecord fields so we can compress the values somewhat
2249
2250         (JSC::ARMv7Assembler::JmpSrc::JmpSrc):
2251           Need to record the jump type now
2252
2253         (JSC::ARMv7Assembler::b):
2254         (JSC::ARMv7Assembler::blx):
2255         (JSC::ARMv7Assembler::bx):
2256           Need to pass the jump types
2257
2258         (JSC::ARMv7Assembler::executableOffsetFor):
2259         (JSC::ARMv7Assembler::jumpSizeDelta):
2260         (JSC::ARMv7Assembler::linkRecordSourceComparator):
2261         (JSC::ARMv7Assembler::computeJumpType):
2262         (JSC::ARMv7Assembler::convertJumpTo):
2263         (JSC::ARMv7Assembler::recordLinkOffsets):
2264         (JSC::ARMv7Assembler::jumpsToLink):
2265         (JSC::ARMv7Assembler::link):
2266         (JSC::ARMv7Assembler::unlinkedCode):
2267           Helper functions for the linker
2268
2269         (JSC::ARMv7Assembler::linkJump):
2270         (JSC::ARMv7Assembler::canBeShortJump):
2271         (JSC::ARMv7Assembler::linkLongJump):
2272         (JSC::ARMv7Assembler::linkShortJump):
2273         (JSC::ARMv7Assembler::linkJumpAbsolute):
2274            Moving code around for the various jump linking functions
2275
2276         * assembler/AbstractMacroAssembler.h:
2277         (JSC::AbstractMacroAssembler::beginUninterruptedSequence):
2278         (JSC::AbstractMacroAssembler::endUninterruptedSequence):
2279           We have to track uninterrupted sequences in any assembler that compacts
2280           branches as that's not something we're allowed to do in such sequences.
2281           AbstractMacroAssembler has a nop version of these functions as it makes the
2282           code elsewhere nicer.
2283
2284         * assembler/LinkBuffer.h:
2285         (JSC::LinkBuffer::LinkBuffer):
2286         (JSC::LinkBuffer::link):
2287         (JSC::LinkBuffer::patch):
2288         (JSC::LinkBuffer::locationOf):
2289         (JSC::LinkBuffer::locationOfNearCall):
2290         (JSC::LinkBuffer::returnAddressOffset):
2291         (JSC::LinkBuffer::trampolineAt):
2292           Updated these functions to adjust for any changed offsets in the linked code
2293
2294         (JSC::LinkBuffer::applyOffset):
2295           A helper function to deal with the now potentially moved labels
2296
2297         (JSC::LinkBuffer::linkCode):
2298           The new and mighty linker function
2299
2300         * assembler/MacroAssemblerARMv7.h:
2301         (JSC::MacroAssemblerARMv7::MacroAssemblerARMv7):
2302         (JSC::MacroAssemblerARMv7::beginUninterruptedSequence):
2303         (JSC::MacroAssemblerARMv7::endUninterruptedSequence):
2304         (JSC::MacroAssemblerARMv7::jumpsToLink):
2305         (JSC::MacroAssemblerARMv7::unlinkedCode):
2306         (JSC::MacroAssemblerARMv7::computeJumpType):
2307         (JSC::MacroAssemblerARMv7::convertJumpTo):
2308         (JSC::MacroAssemblerARMv7::recordLinkOffsets):
2309         (JSC::MacroAssemblerARMv7::jumpSizeDelta):
2310         (JSC::MacroAssemblerARMv7::link):
2311         (JSC::MacroAssemblerARMv7::jump):
2312         (JSC::MacroAssemblerARMv7::branchMul32):
2313         (JSC::MacroAssemblerARMv7::breakpoint):
2314         (JSC::MacroAssemblerARMv7::nearCall):
2315         (JSC::MacroAssemblerARMv7::call):
2316         (JSC::MacroAssemblerARMv7::ret):
2317         (JSC::MacroAssemblerARMv7::tailRecursiveCall):
2318         (JSC::MacroAssemblerARMv7::executableOffsetFor):
2319         (JSC::MacroAssemblerARMv7::inUninterruptedSequence):
2320         (JSC::MacroAssemblerARMv7::makeJump):
2321         (JSC::MacroAssemblerARMv7::makeBranch):
2322            All branches need to pass on their type now
2323
2324         * jit/ExecutableAllocator.h:
2325         (JSC::ExecutablePool::returnLastBytes):
2326            We can't know ahead of time how much space will be necessary to
2327            hold the linked code if we're compacting branches, this new
2328            function allows us to return the unused bytes at the end of linking
2329
2330         * jit/JIT.cpp:
2331         (JSC::JIT::JIT):
2332         (JSC::JIT::privateCompile):
2333         * jit/JIT.h:
2334         (JSC::JIT::compile):
2335            The JIT class now needs to take a linker offset so that recompilation
2336            can generate the same jumps when using branch compaction.
2337         * jit/JITArithmetic32_64.cpp:
2338         (JSC::JIT::emitSlow_op_mod):
2339         * jit/JITOpcodes.cpp:
2340         (JSC::JIT::privateCompileCTIMachineTrampolines):
2341         * jit/JITOpcodes32_64.cpp:
2342         (JSC::JIT::privateCompileCTIMachineTrampolines):
2343         (JSC::JIT::privateCompileCTINativeCall):
2344           Update for new trampolineAt changes
2345
2346         * wtf/FastMalloc.cpp:
2347         (WTF::TCMallocStats::):
2348         * wtf/Platform.h:
2349
2350 2010-08-09  Gavin Barraclough  <barraclough@apple.com>
2351
2352         Qt build fix III.
2353
2354         * wtf/text/WTFString.h:
2355
2356 2010-08-09  Gavin Barraclough  <barraclough@apple.com>
2357
2358         Qt build fix.
2359
2360         * wtf/qt/StringQt.cpp:
2361
2362 2010-08-06  Gavin Barraclough  <barraclough@apple.com>
2363
2364         Rubber stamped by Sam Weinig
2365
2366         Bug 43594 - Add string forwards to Forward.h
2367         This allows us to remove forward declarations for these classes from
2368         WebCore/WebKit (a step in moving these class from WebCore:: to WTF::).
2369
2370         * JavaScriptCore.xcodeproj/project.pbxproj:
2371         * wtf/Forward.h:
2372
2373 2010-08-07  Sheriff Bot  <webkit.review.bot@gmail.com>
2374
2375         Unreviewed, rolling out r64938.
2376         http://trac.webkit.org/changeset/64938
2377         https://bugs.webkit.org/show_bug.cgi?id=43685
2378
2379         Did not compile on several ports (Requested by abarth on
2380         #webkit).
2381
2382         * Android.mk:
2383         * CMakeLists.txt:
2384         * GNUmakefile.am:
2385         * JavaScriptCore.gypi:
2386         * JavaScriptCore.pro:
2387         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
2388         * JavaScriptCore.xcodeproj/project.pbxproj:
2389         * assembler/AbstractMacroAssembler.h:
2390         * assembler/MacroAssembler.h:
2391         * assembler/MacroAssemblerX86.h:
2392         (JSC::MacroAssemblerX86::load32):
2393         (JSC::MacroAssemblerX86::store32):
2394         * assembler/X86Assembler.h:
2395         (JSC::X86Assembler::movl_rm):
2396         (JSC::X86Assembler::movl_mr):
2397         * bytecode/CodeBlock.cpp:
2398         (JSC::CodeBlock::markAggregate):
2399         * bytecode/Instruction.h:
2400         (JSC::PolymorphicAccessStructureList::PolymorphicStubInfo::):
2401         (JSC::PolymorphicAccessStructureList::PolymorphicStubInfo::set):
2402         (JSC::PolymorphicAccessStructureList::PolymorphicAccessStructureList):
2403         * bytecode/StructureStubInfo.cpp:
2404         (JSC::StructureStubInfo::deref):
2405         * bytecode/StructureStubInfo.h:
2406         (JSC::StructureStubInfo::initGetByIdProto):
2407         (JSC::StructureStubInfo::initGetByIdChain):
2408         (JSC::StructureStubInfo::):
2409         * jit/JIT.h:
2410         * jit/JITMarkObjects.cpp: Removed.
2411         * jit/JITPropertyAccess.cpp:
2412         (JSC::JIT::compileGetDirectOffset):
2413         (JSC::JIT::testPrototype):
2414         (JSC::JIT::privateCompilePutByIdTransition):
2415         (JSC::JIT::privateCompileGetByIdProto):
2416         (JSC::JIT::privateCompileGetByIdProtoList):
2417         (JSC::JIT::privateCompileGetByIdChainList):
2418         (JSC::JIT::privateCompileGetByIdChain):
2419         * jit/JITPropertyAccess32_64.cpp:
2420         (JSC::JIT::compileGetDirectOffset):
2421         (JSC::JIT::testPrototype):
2422         (JSC::JIT::privateCompilePutByIdTransition):
2423         (JSC::JIT::privateCompileGetByIdProto):
2424         (JSC::JIT::privateCompileGetByIdProtoList):
2425         (JSC::JIT::privateCompileGetByIdChainList):
2426         (JSC::JIT::privateCompileGetByIdChain):
2427         * jit/JITStubs.cpp:
2428         (JSC::setupPolymorphicProtoList):
2429         * wtf/Platform.h:
2430
2431 2010-08-07  Nathan Lawrence  <nlawrence@apple.com>
2432
2433         Reviewed by Geoffrey Garen.
2434
2435         The JIT code contains a number of direct references to GC'd objects.
2436         When we have movable objects, these references will need to be
2437         updated.
2438
2439         * Android.mk:
2440         * CMakeLists.txt:
2441         * GNUmakefile.am:
2442         * JavaScriptCore.gypi:
2443         * JavaScriptCore.pro:
2444         * JavaScriptCore.xcodeproj/project.pbxproj:
2445         * assembler/AbstractMacroAssembler.h:
2446         (JSC::AbstractMacroAssembler::int32AtLocation):
2447         (JSC::AbstractMacroAssembler::pointerAtLocation):
2448         (JSC::AbstractMacroAssembler::jumpTarget):
2449         * assembler/MacroAssembler.h:
2450         (JSC::MacroAssembler::loadPtrWithPatch):
2451             Normally, loadPtr will optimize when the register is eax.  Since
2452             the slightly smaller instruction changes the offsets, it messes up
2453             our ability to repatch the code.  We added this new instruction
2454             that garuntees a constant size.
2455         * assembler/MacroAssemblerX86.h:
2456         (JSC::MacroAssemblerX86::load32WithPatch):
2457             Changed load32 in the same way described above.
2458         (JSC::MacroAssemblerX86::load32):
2459             Moved the logic to optimize laod32 from movl_mr to load32
2460         (JSC::MacroAssemblerX86::store32):
2461             Moved the logic to optimize store32 from movl_rm to store32
2462         * assembler/X86Assembler.h:
2463         (JSC::X86Assembler::movl_rm):
2464         (JSC::X86Assembler::movl_mr):
2465         (JSC::X86Assembler::int32AtLocation):
2466         (JSC::X86Assembler::pointerAtLocation):
2467         (JSC::X86Assembler::jumpTarget):
2468         * bytecode/CodeBlock.cpp:
2469         (JSC::CodeBlock::markAggregate):
2470         * bytecode/Instruction.h:
2471             As described in StructureStubInfo.h, we needed to add additional
2472             fields to both StructureStubInfo and
2473             PolymorphicAccessStructureList so that we can determine the
2474             structure of the JITed code at patch time.
2475         (JSC::PolymorphicAccessStructureList::PolymorphicStubInfo::set):
2476         (JSC::PolymorphicAccessStructureList::PolymorphicAccessStructureList):
2477         * bytecode/StructureStubInfo.cpp:
2478         (JSC::StructureStubInfo::markAggregate):
2479             Added this function to mark the JITed code that correosponds to
2480             this structure stub info.
2481         * bytecode/StructureStubInfo.h:
2482         (JSC::StructureStubInfo::initGetByIdProto):
2483         (JSC::StructureStubInfo::initGetByIdChain):
2484         (JSC::StructureStubInfo::):
2485         * jit/JIT.h:
2486         * jit/JITMarkObjects.cpp: Added.
2487         (JSC::JIT::patchPrototypeStructureAddress):
2488         (JSC::JIT::patchGetDirectOffset):
2489         (JSC::JIT::markGetByIdProto):
2490         (JSC::JIT::markGetByIdChain):
2491         (JSC::JIT::markGetByIdProtoList):
2492         (JSC::JIT::markPutByIdTransition):
2493         (JSC::JIT::markGlobalObjectReference):
2494         * jit/JITPropertyAccess.cpp:
2495             Added asserts for the patch offsets.
2496         (JSC::JIT::compileGetDirectOffset):
2497         (JSC::JIT::testPrototype):
2498         (JSC::JIT::privateCompilePutByIdTransition):
2499         (JSC::JIT::privateCompileGetByIdProto):
2500         (JSC::JIT::privateCompileGetByIdProtoList):
2501         (JSC::JIT::privateCompileGetByIdChainList):
2502         (JSC::JIT::privateCompileGetByIdChain):
2503         * jit/JITPropertyAccess32_64.cpp:
2504         (JSC::JIT::compileGetDirectOffset):
2505         (JSC::JIT::testPrototype):
2506         (JSC::JIT::privateCompilePutByIdTransition):
2507         (JSC::JIT::privateCompileGetByIdProto):
2508         (JSC::JIT::privateCompileGetByIdProtoList):
2509         (JSC::JIT::privateCompileGetByIdChainList):
2510         (JSC::JIT::privateCompileGetByIdChain):
2511         * jit/JITStubs.cpp:
2512         (JSC::setupPolymorphicProtoList):
2513         * wtf/Platform.h:
2514             Added ENABLE_MOVABLE_GC_OBJECTS flag
2515
2516 2010-08-07  Michael Saboff  <msaboff@apple.com>
2517
2518         Reviewed by Geoffrey Garen.
2519
2520         Revert JSArray to point to the beginning of the contained ArrayStorage
2521         struct.  This is described in
2522         https://bugs.webkit.org/show_bug.cgi?id=43526.
2523
2524         * jit/JITPropertyAccess.cpp:
2525         (JSC::JIT::emit_op_get_by_val):
2526         (JSC::JIT::emit_op_put_by_val):
2527         (JSC::JIT::privateCompilePatchGetArrayLength):
2528         * jit/JITPropertyAccess32_64.cpp:
2529         (JSC::JIT::emit_op_get_by_val):
2530         (JSC::JIT::emit_op_put_by_val):
2531         (JSC::JIT::privateCompilePatchGetArrayLength):
2532         * runtime/JSArray.cpp:
2533         (JSC::JSArray::JSArray):
2534         (JSC::JSArray::~JSArray):
2535         (JSC::JSArray::getOwnPropertySlot):
2536         (JSC::JSArray::getOwnPropertyDescriptor):
2537         (JSC::JSArray::put):
2538         (JSC::JSArray::putSlowCase):
2539         (JSC::JSArray::deleteProperty):
2540         (JSC::JSArray::getOwnPropertyNames):
2541         (JSC::JSArray::getNewVectorLength):
2542         (JSC::JSArray::increaseVectorLength):
2543         (JSC::JSArray::increaseVectorPrefixLength):
2544         (JSC::JSArray::setLength):
2545         (JSC::JSArray::pop):
2546         (JSC::JSArray::push):
2547         (JSC::JSArray::shiftCount):
2548         (JSC::JSArray::unshiftCount):
2549         (JSC::JSArray::sortNumeric):
2550         (JSC::JSArray::sort):
2551         (JSC::JSArray::fillArgList):
2552         (JSC::JSArray::copyToRegisters):
2553         (JSC::JSArray::compactForSorting):
2554         (JSC::JSArray::subclassData):
2555         (JSC::JSArray::setSubclassData):
2556         (JSC::JSArray::checkConsistency):
2557         * runtime/JSArray.h:
2558         (JSC::JSArray::length):
2559         (JSC::JSArray::canGetIndex):
2560         (JSC::JSArray::getIndex):
2561         (JSC::JSArray::setIndex):
2562         (JSC::JSArray::uncheckedSetIndex):
2563         (JSC::JSArray::markChildrenDirect):
2564
2565 2010-08-07  Kwang Yul Seo  <skyul@company100.net>
2566
2567         Reviewed by Eric Seidel.
2568
2569         Add ENABLE(YARR) guard around JSGlobalData::m_regexAllocator
2570         https://bugs.webkit.org/show_bug.cgi?id=43399
2571
2572         m_regexAllocator is used only by RegExp::compile which is guarded with ENABLE(YARR).
2573
2574         * runtime/JSGlobalData.h:
2575
2576 2010-08-07  Patrick Roland Gansterer  <paroga@paroga.com>
2577
2578         Reviewed by Eric Seidel.
2579
2580         [Qt] Enable JIT on WinCE
2581         https://bugs.webkit.org/show_bug.cgi?id=43303
2582
2583         Add ExtraCompiler for generating GeneratedJITStubs_MSVC.asm.
2584
2585         * DerivedSources.pro:
2586
2587 2010-08-07  Dan Bernstein  <mitz@apple.com>
2588
2589         Reviewed by Anders Carlsson.
2590
2591         Created a separate SimpleFontData constructor exclusively for SVG fonts and moved the CTFontRef
2592         from SimpleFontData to FontPlatformData.
2593         https://bugs.webkit.org/show_bug.cgi?id=43674
2594
2595         * wtf/Platform.h: Moved definitions of WTF_USE_CORE_TEXT and WTF_USE_ATSUI here from WebCore/config.h.
2596
2597 2010-08-07  Zoltan Herczeg  <zherczeg@webkit.org>
2598
2599         Reviewed by Eric Seidel.
2600
2601         Bitmap.h has no default constructor
2602         https://bugs.webkit.org/show_bug.cgi?id=43619
2603
2604         Without a constructor, the initial bits of the Bitmap class
2605         are undefinied. If only a few, or zero bits are 0, the memory
2606         area provided by AlignedMemoryAllocator can be easly exhausted.
2607
2608         Csaba Osztrogonác helped to find this bug.
2609
2610         * wtf/Bitmap.h:
2611         (WTF::::Bitmap):
2612
2613 2010-08-06  Rafael Antognolli  <antognolli@profusion.mobi>
2614
2615         [EFL] Build fix.
2616
2617         * CMakeLists.txt: add runtime/CGHandle.cpp.
2618
2619 2010-08-06  Jessie Berlin  <jberlin@apple.com>
2620
2621         Roll out http://trac.webkit.org/changeset/64801, which broke the Safari Windows Build.
2622         Unreviewed.
2623
2624         * JavaScriptCore.xcodeproj/project.pbxproj:
2625         * wtf/Forward.h:
2626
2627 2010-08-06  Jessie Berlin  <jberlin@apple.com>
2628
2629         Windows Build Fix (continued). Unreviewed.
2630
2631         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
2632
2633 2010-08-06  Jessie Berlin  <jberlin@apple.com>
2634
2635         Windows Build Fix. Unreviewed.
2636
2637         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
2638         Add GCHandle.h and GCHandle.cpp.
2639
2640 2010-08-06  Nathan Lawrence  <nlawrence@apple.com>
2641
2642         Reviewed by Geoffrey Garen.
2643
2644         https://bugs.webkit.org/show_bug.cgi?id=43207
2645
2646         WeakGCPtr's should instead of directly pointing to the GC'd object
2647         should be directed to an array of pointers that can be updated for
2648         movable objects.
2649
2650         * Android.mk:
2651         * GNUmakefile.am:
2652         * JavaScriptCore.exp:
2653         * JavaScriptCore.gypi:
2654         * JavaScriptCore.pro:
2655         * JavaScriptCore.xcodeproj/project.pbxproj:
2656         * runtime/Collector.cpp:
2657         (JSC::Heap::destroy):
2658         (JSC::Heap::allocateBlock):
2659         (JSC::Heap::freeBlock):
2660         (JSC::Heap::updateWeakGCHandles):
2661         (JSC::WeakGCHandlePool::update):
2662         (JSC::Heap::addWeakGCHandle):
2663         (JSC::Heap::markRoots):
2664         * runtime/Collector.h:
2665         (JSC::Heap::weakGCHandlePool):
2666         * runtime/GCHandle.cpp: Added.
2667         (JSC::WeakGCHandle::pool):
2668         (JSC::WeakGCHandlePool::WeakGCHandlePool):
2669         (JSC::WeakGCHandlePool::allocate):
2670         (JSC::WeakGCHandlePool::free):
2671         (JSC::WeakGCHandlePool::operator new):
2672         * runtime/GCHandle.h: Added.
2673         (JSC::WeakGCHandle::isValidPtr):
2674         (JSC::WeakGCHandle::isPtr):
2675         (JSC::WeakGCHandle::isNext):
2676         (JSC::WeakGCHandle::invalidate):
2677         (JSC::WeakGCHandle::get):
2678         (JSC::WeakGCHandle::set):
2679         (JSC::WeakGCHandle::getNextInFreeList):
2680         (JSC::WeakGCHandle::setNextInFreeList):
2681         (JSC::WeakGCHandlePool::isFull):
2682         * runtime/WeakGCPtr.h:
2683         (JSC::WeakGCPtr::WeakGCPtr):
2684         (JSC::WeakGCPtr::~WeakGCPtr):
2685         (JSC::WeakGCPtr::get):
2686         (JSC::WeakGCPtr::clear):
2687         (JSC::WeakGCPtr::assign):
2688         (JSC::get):
2689
2690 2010-08-06  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2691
2692         Reviewed by Antonio Gomes.
2693
2694         [Qt] Fix warnings about difference in symbol visiblity on Mac OS X
2695
2696         * jsc.pro:
2697
2698 2010-08-06  Zoltan Herczeg  <zherczeg@webkit.org>
2699
2700         Reviewed by Darin Adler.
2701
2702         Refactor identifier parsing in lexer
2703         https://bugs.webkit.org/show_bug.cgi?id=41845
2704
2705         The code is refactored to avoid gotos. The new code
2706         has the same performance as the old one.
2707
2708         SunSpider --parse-only: no change (from 34.0ms to 33.6ms)
2709         SunSpider: no change (from 523.2ms to 523.5ms)
2710
2711         * parser/Lexer.cpp:
2712         (JSC::Lexer::parseIdent):
2713         (JSC::Lexer::lex):
2714         * parser/Lexer.h:
2715
2716 2010-08-06  Gabor Loki  <loki@webkit.org>
2717
2718         Reviewed by Gavin Barraclough.
2719
2720         The ARM JIT does not support JSValue32_64 with RVCT
2721         https://bugs.webkit.org/show_bug.cgi?id=43411
2722
2723         JSValue32_64 is enabled for RVCT by default.
2724
2725         * create_jit_stubs:
2726         * jit/JITStubs.cpp:
2727         (JSC::ctiTrampoline):
2728         (JSC::ctiVMThrowTrampoline):
2729         (JSC::ctiOpThrowNotCaught):
2730         * wtf/Platform.h:
2731
2732 2010-08-05  Chao-ying Fu  <fu@mips.com>
2733
2734         Reviewed by Darin Adler.
2735
2736         Define WTF_USE_ARENA_ALLOC_ALIGNMENT_INTEGER for MIPS
2737         https://bugs.webkit.org/show_bug.cgi?id=43514
2738
2739         MIPS needs to define WTF_USE_ARENA_ALLOC_ALIGNMENT_INTEGER, so that
2740         RenderArena::allocate() can return 8-byte aligned memory to avoid
2741         exceptions on sdc1/ldc1.
2742
2743         * wtf/Platform.h:
2744
2745 2010-08-05  Gavin Barraclough  <barraclough@apple.com>
2746
2747         Rubber stamped by Sam Weinig
2748
2749         Bug 43594 - Add string forwards to Forward.h
2750         This allows us to remove forward declarations for these classes from
2751         WebCore/WebKit (a step in moving these class from WebCore:: to WTF::).
2752
2753         * JavaScriptCore.xcodeproj/project.pbxproj:
2754         * wtf/Forward.h:
2755
2756 2010-08-05  Geoffrey Garen  <ggaren@apple.com>
2757
2758         Reviewed by Mark Rowe.
2759
2760         Fixed leak seen on buildbot.
2761
2762         * runtime/GCActivityCallbackCF.cpp:
2763         (JSC::DefaultGCActivityCallback::DefaultGCActivityCallback):
2764         (JSC::DefaultGCActivityCallback::~DefaultGCActivityCallback):
2765         (JSC::DefaultGCActivityCallback::operator()): Make out timer a RetainPtr,
2766         since anything less would be uncivilized.
2767
2768 2010-08-05  Andy Estes  <aestes@apple.com>
2769
2770         Reviewed by David Kilzer.
2771
2772         Rename iOS-related OS and PLATFORM macros.
2773         https://bugs.webkit.org/show_bug.cgi?id=43493
2774         
2775         Rename WTF_OS_IPHONE_OS to WTF_OS_IOS, WTF_PLATFORM_IPHONE to
2776         WTF_PLATFORM_IOS, and WTF_PLATFORM_IPHONE_SIMULATOR to
2777         WTF_PLATFORM_IOS_SIMULATOR.
2778
2779         * jit/ExecutableAllocator.h:
2780         * jit/JITStubs.cpp:
2781         * profiler/ProfilerServer.mm:
2782         (-[ProfilerServer init]):
2783         * wtf/FastMalloc.cpp:
2784         (WTF::TCMallocStats::):
2785         * wtf/Platform.h:
2786         * wtf/unicode/icu/CollatorICU.cpp:
2787         (WTF::Collator::userDefault):
2788
2789 2010-08-05  Nathan Lawrence  <nlawrence@apple.com>
2790
2791         Reviewed by Darin Adler.
2792
2793         https://bugs.webkit.org/show_bug.cgi?id=43464
2794
2795         Currently, the global object is being embedded in the JavaScriptCore
2796         bytecode, however since the global object is the same for all opcodes
2797         in a code block, we can have the global object just be a member of the
2798         associated code block.
2799
2800         Additionally, I added an assert inside of emitOpcode that verifies
2801         that the last generated opcode was of the correct length.
2802
2803         * bytecode/CodeBlock.cpp:
2804         (JSC::CodeBlock::CodeBlock):
2805         (JSC::CodeBlock::derefStructures):
2806         (JSC::CodeBlock::markAggregate):
2807         * bytecode/CodeBlock.h:
2808         (JSC::CodeBlock::globalObject):
2809         (JSC::GlobalCodeBlock::GlobalCodeBlock):
2810         (JSC::ProgramCodeBlock::ProgramCodeBlock):
2811         (JSC::EvalCodeBlock::EvalCodeBlock):
2812         (JSC::FunctionCodeBlock::FunctionCodeBlock):
2813         * bytecode/Opcode.h:
2814         (JSC::opcodeLength):
2815         * bytecompiler/BytecodeGenerator.cpp:
2816         (JSC::BytecodeGenerator::BytecodeGenerator):
2817         (JSC::BytecodeGenerator::emitOpcode):
2818             Added an assert to check that the last generated opcode is the
2819             correct length.
2820         (JSC::BytecodeGenerator::rewindBinaryOp):
2821             Changed the last opcode to op_end since the length will no longer
2822             be correct.
2823         (JSC::BytecodeGenerator::rewindUnaryOp):
2824             Changed the last opcode to op_end since the length will no longer
2825             be correct.
2826         (JSC::BytecodeGenerator::emitResolve):
2827         (JSC::BytecodeGenerator::emitGetScopedVar):
2828         (JSC::BytecodeGenerator::emitPutScopedVar):
2829         (JSC::BytecodeGenerator::emitResolveWithBase):
2830         * bytecompiler/BytecodeGenerator.h:
2831         * interpreter/Interpreter.cpp:
2832         (JSC::Interpreter::resolveGlobal):
2833         (JSC::Interpreter::resolveGlobalDynamic):
2834         (JSC::Interpreter::privateExecute):
2835         * jit/JITOpcodes.cpp:
2836         (JSC::JIT::emit_op_get_global_var):
2837         (JSC::JIT::emit_op_put_global_var):
2838         (JSC::JIT::emit_op_resolve_global):
2839         (JSC::JIT::emitSlow_op_resolve_global):
2840         (JSC::JIT::emit_op_resolve_global_dynamic):
2841         (JSC::JIT::emitSlow_op_resolve_global_dynamic):
2842         * jit/JITOpcodes32_64.cpp:
2843         (JSC::JIT::emit_op_get_global_var):
2844         (JSC::JIT::emit_op_put_global_var):
2845         (JSC::JIT::emit_op_resolve_global):
2846         (JSC::JIT::emitSlow_op_resolve_global):
2847         * jit/JITStubs.cpp:
2848         (JSC::cti_op_resolve_global):
2849         * runtime/Executable.cpp:
2850         (JSC::FunctionExecutable::compileForCallInternal):
2851         (JSC::FunctionExecutable::compileForConstructInternal):
2852         (JSC::FunctionExecutable::reparseExceptionInfo):
2853
2854 2010-08-05  Gavin Barraclough  <barraclough@apple.com>
2855
2856         Reviewed by Sam Weinig.
2857
2858         Bug 43185 - Switch RegisterFile over to use PageAllocation
2859
2860         Remove platform-specific memory allocation code.
2861
2862         * interpreter/RegisterFile.cpp:
2863         (JSC::RegisterFile::~RegisterFile):
2864         (JSC::RegisterFile::releaseExcessCapacity):
2865         * interpreter/RegisterFile.h:
2866         (JSC::RegisterFile::RegisterFile):
2867         (JSC::RegisterFile::grow):
2868         (JSC::RegisterFile::checkAllocatedOkay):
2869         * wtf/PageAllocation.cpp:
2870         (WTF::PageAllocation::lastError):
2871         * wtf/PageAllocation.h:
2872         (WTF::PageAllocation::allocate):
2873         (WTF::PageAllocation::allocateAt):
2874         (WTF::PageAllocation::allocateAligned):
2875         (WTF::PageAllocation::pageSize):
2876         (WTF::PageAllocation::isPageAligned):
2877         (WTF::PageAllocation::isPowerOfTwo):
2878         * wtf/PageReservation.h:
2879         (WTF::PageReservation::commit):
2880         (WTF::PageReservation::decommit):
2881         (WTF::PageReservation::reserve):
2882         (WTF::PageReservation::reserveAt):
2883
2884 2010-08-05  Michael Saboff  <msaboff@apple.com>
2885
2886         Reviewed by Darin Adler.
2887
2888         Fixed https://bugs.webkit.org/show_bug.cgi?id=43401 where array 
2889         content aren't properly initialized as part of unshift.  
2890
2891         * runtime/JSArray.cpp:
2892         (JSC::JSArray::unshiftCount):
2893
2894 2010-08-05  Jian Li  <jianli@chromium.org>
2895
2896         Reviewed by David Levin.
2897
2898         Unify blob related feature defines to ENABLE(BLOB).
2899         https://bugs.webkit.org/show_bug.cgi?id=43081
2900
2901         * Configurations/FeatureDefines.xcconfig:
2902
2903 2010-08-05  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2904
2905         Rubber-stamped by Xan Lopez.
2906
2907         Remove GHashTable left-overs. GHashTable is ref-counted, and is
2908         correctly supported by GRefPtr.
2909
2910         * wtf/gobject/GOwnPtr.h:
2911
2912 2010-08-05  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2913
2914         Unreviewed.
2915
2916         Typo fix that makes distcheck happy.
2917
2918         * GNUmakefile.am:
2919
2920 2010-08-03  Geoffrey Garen  <ggaren@apple.com>
2921
2922         Reviewed by Oliver Hunt and Beth Dakin.
2923
2924         https://bugs.webkit.org/show_bug.cgi?id=43461
2925         Invalid NaN parsing
2926         
2927         * wtf/dtoa.cpp: Turn off the dtoa feature that allows you to specify a
2928         non-standard NaN representation, since our NaN encoding assumes that all
2929         true NaNs have the standard bit pattern.
2930
2931         * API/JSValueRef.cpp:
2932         (JSValueMakeNumber): Don't allow an API client to accidentally specify
2933         a non-standard NaN either.
2934
2935 2010-08-04  Gavin Barraclough  <barraclough@apple.com>
2936
2937         Windows build fix part II.
2938
2939         * wtf/PageReservation.h:
2940         (WTF::PageReservation::systemReserve):
2941
2942 2010-08-04  Gavin Barraclough  <barraclough@apple.com>
2943
2944         Windows build fix.
2945
2946         * wtf/PageReservation.h:
2947         (WTF::PageReservation::systemReserve):
2948
2949 2010-08-04  Gavin Barraclough  <barraclough@apple.com>
2950
2951         Build fix - add new header to !Mac projects.
2952
2953         * GNUmakefile.am:
2954         * JavaScriptCore.gypi:
2955         * JavaScriptCore.vcproj/WTF/WTF.vcproj:
2956
2957 2010-08-04  Gavin Barraclough  <barraclough@apple.com>
2958
2959         Reviewed by Sam Weinig.
2960
2961         Bug 43515 - Fix small design issues with PageAllocation, split out PageReservation.
2962
2963         The PageAllocation class has a number of issues:
2964         * Changes in bug #43269 accidentally switched SYMBIAN over to use malloc/free to allocate
2965           blocks of memory for the GC heap, instead of allocating RChunks.  Revert this change in
2966           behaviour.
2967         * In order for PageAllocation to work correctly on WinCE we should be decommitting memory
2968           before deallocating.  In order to simplify understanding the expected state at deallocate,
2969           split behaviour out into PageAllocation and PageReservation classes.  Require that all
2970           memory be decommitted before calling deallocate on a PageReservation, add asserts to
2971           enforce this.
2972         * add many missing asserts.
2973         * inline more functions.
2974         * remove ability to create sub-PageAllocations from an existing PageAllocations object -
2975           this presented an interface that would allow sub regions to be deallocated, which would
2976           not have provided expected behaviour.
2977         * remove writable/executable arguments to commit, this value can be cached at the point
2978           the memory is reserved.
2979         * remove writable/executable arguments to allocateAligned, protection other than RW is not
2980           supported.
2981         * add missing checks for overflow & failed allocation to mmap path through allocateAligned.
2982
2983         * JavaScriptCore.xcodeproj/project.pbxproj:
2984         * jit/ExecutableAllocator.cpp:
2985         (JSC::ExecutableAllocator::intializePageSize):
2986         * jit/ExecutableAllocator.h:
2987         (JSC::ExecutablePool::Allocation::Allocation):
2988         (JSC::ExecutablePool::Allocation::base):
2989         (JSC::ExecutablePool::Allocation::size):
2990         (JSC::ExecutablePool::Allocation::operator!):
2991         * jit/ExecutableAllocatorFixedVMPool.cpp:
2992         (JSC::FixedVMPoolAllocator::reuse):
2993         (JSC::FixedVMPoolAllocator::coalesceFreeSpace):
2994         (JSC::FixedVMPoolAllocator::FixedVMPoolAllocator):
2995         (JSC::FixedVMPoolAllocator::alloc):
2996         (JSC::FixedVMPoolAllocator::free):
2997         (JSC::FixedVMPoolAllocator::allocInternal):
2998         * runtime/AlignedMemoryAllocator.h:
2999         (JSC::::allocate):
3000         (JSC::::AlignedMemoryAllocator):
3001         * runtime/Collector.cpp:
3002         (JSC::Heap::allocateBlock):
3003         * runtime/Collector.h:
3004         * wtf/PageAllocation.cpp:
3005         * wtf/PageAllocation.h:
3006         (WTF::PageAllocation::operator!):
3007         (WTF::PageAllocation::allocate):
3008         (WTF::PageAllocation::allocateAt):
3009         (WTF::PageAllocation::allocateAligned):
3010         (WTF::PageAllocation::deallocate):
3011         (WTF::PageAllocation::pageSize):
3012         (WTF::PageAllocation::systemAllocate):
3013         (WTF::PageAllocation::systemAllocateAt):
3014         (WTF::PageAllocation::systemAllocateAligned):
3015         (WTF::PageAllocation::systemDeallocate):
3016         (WTF::PageAllocation::systemPageSize):
3017         * wtf/PageReservation.h: Copied from JavaScriptCore/wtf/PageAllocation.h.
3018         (WTF::PageReservation::PageReservation):
3019         (WTF::PageReservation::commit):
3020         (WTF::PageReservation::decommit):
3021         (WTF::PageReservation::reserve):
3022         (WTF::PageReservation::reserveAt):
3023         (WTF::PageReservation::deallocate):
3024         (WTF::PageReservation::systemCommit):
3025         (WTF::PageReservation::systemDecommit):
3026         (WTF::PageReservation::systemReserve):
3027         (WTF::PageReservation::systemReserveAt):
3028         * wtf/Platform.h:
3029
3030 2010-08-04  Sheriff Bot  <webkit.review.bot@gmail.com>
3031
3032         Unreviewed, rolling out r64655.
3033         http://trac.webkit.org/changeset/64655
3034         https://bugs.webkit.org/show_bug.cgi?id=43496
3035
3036         JavaScriptCore references patch seems to have caused
3037         regressions in QT and GTK builds (Requested by nlawrence on
3038         #webkit).
3039
3040         * bytecode/CodeBlock.cpp:
3041         (JSC::CodeBlock::markAggregate):
3042         * runtime/Collector.cpp:
3043         (JSC::Heap::markConservatively):
3044         * runtime/JSCell.h:
3045         (JSC::JSValue::asCell):
3046         (JSC::MarkStack::append):
3047         * runtime/JSGlobalObject.cpp:
3048         (JSC::markIfNeeded):
3049         * runtime/JSONObject.cpp:
3050         (JSC::Stringifier::Holder::object):
3051         * runtime/JSObject.h:
3052         (JSC::JSObject::prototype):
3053         * runtime/JSStaticScopeObject.cpp:
3054         (JSC::JSStaticScopeObject::markChildren):
3055         * runtime/JSValue.h:
3056         (JSC::JSValue::):
3057         (JSC::JSValue::JSValue):
3058         (JSC::JSValue::asCell):
3059         * runtime/MarkStack.h:
3060         * runtime/NativeErrorConstructor.cpp:
3061         * runtime/NativeErrorConstructor.h:
3062         * runtime/Structure.h:
3063         (JSC::Structure::storedPrototype):
3064
3065 2010-08-04  Gavin Barraclough  <barraclough@apple.com>
3066
3067         Rubber stamped by Sam Weinig.
3068
3069         Enable JSVALUE64 for CPU(PPC64).
3070         Basic browsing seems to work.
3071
3072         * wtf/Platform.h:
3073
3074 2010-08-04  Nathan Lawrence  <nlawrence@apple.com>
3075
3076         Reviewed by Darin Adler.
3077
3078         Refactoring MarkStack::append to take a reference.  This is in
3079         preparation for movable objects when we will need to update pointers.
3080         http://bugs.webkit.org/show_bug.cgi?id=41177
3081
3082         Unless otherwise noted, all changes are to either return by reference
3083         or pass a reference to MarkStack::append.
3084
3085         * bytecode/CodeBlock.cpp:
3086         (JSC::CodeBlock::markAggregate):
3087         * runtime/Collector.cpp:
3088         (JSC::Heap::markConservatively):
3089             Added a temporary variable to prevent marking from changing an
3090             unknown value on the stack
3091         * runtime/JSCell.h:
3092         (JSC::JSValue::asCell):
3093         (JSC::MarkStack::append):
3094         (JSC::MarkStack::appendInternal):
3095         * runtime/JSGlobalObject.cpp:
3096         (JSC::markIfNeeded):
3097         * runtime/JSONObject.cpp:
3098         (JSC::Stringifier::Holder::object):
3099         * runtime/JSObject.h:
3100         (JSC::JSObject::prototype):
3101         * runtime/JSStaticScopeObject.cpp:
3102         (JSC::JSStaticScopeObject::markChildren):
3103         * runtime/JSValue.h:
3104         (JSC::JSValue::JSValue):
3105         (JSC::JSValue::asCell):
3106         * runtime/MarkStack.h:
3107         * runtime/NativeErrorConstructor.cpp:
3108         (JSC::NativeErrorConstructor::createStructure):
3109             Changed the structure flags to include a custom markChildren.
3110         (JSC::NativeErrorConstructor::markChildren):
3111             Update the prototype of the stored structure.
3112         * runtime/NativeErrorConstructor.h:
3113             Added structure flags.
3114         * runtime/Structure.h:
3115         (JSC::Structure::storedPrototype):
3116
3117 2010-08-03  Nathan Lawrence  <nlawrence@apple.com>
3118
3119         Reviewed by Oliver Hunt.
3120
3121         Tightened up some get_by_id_chain* code generation
3122         https://bugs.webkit.org/show_bug.cgi?id=40935
3123
3124         This is in the style of
3125         https://bugs.webkit.org/show_bug.cgi?id=30539, and changed code to
3126         call accessor functions when it was not necessary to directly access
3127         the private variables.
3128
3129         * jit/JIT.h:
3130         * jit/JITPropertyAccess.cpp:
3131         (JSC::JIT::compileGetDirectOffset):
3132         (JSC::JIT::testPrototype):
3133         (JSC::JIT::privateCompilePutByIdTransition):
3134         (JSC::JIT::privateCompileGetByIdChainList):
3135         (JSC::JIT::privateCompileGetByIdChain):
3136         * jit/JITPropertyAccess32_64.cpp:
3137         (JSC::JIT::testPrototype):
3138         (JSC::JIT::privateCompilePutByIdTransition):
3139         (JSC::JIT::privateCompileGetByIdChainList):
3140         (JSC::JIT::privateCompileGetByIdChain):
3141
3142 2010-08-03  Adam Roben  <aroben@apple.com>
3143
3144         Turn on PLATFORM_STRATEGIES on Windows
3145
3146         Fixes <http://webkit.org/b/43431>.
3147
3148         Reviewed by Anders Carlsson.
3149
3150         * wtf/Platform.h:
3151
3152 2010-08-04  Gabor Loki  <loki@webkit.org>
3153
3154         Reviewed by Geoffrey Garen.
3155
3156         Enable JSValue32_64 for GCC on ARM by default
3157         https://bugs.webkit.org/show_bug.cgi?id=43410
3158
3159         * wtf/Platform.h:
3160
3161 2010-08-03  Gavin Barraclough  <barraclough@apple.com>
3162
3163         Speculative windows build fix.
3164
3165         * wtf/Bitmap.h:
3166
3167 2010-08-03  Gavin Barraclough  <barraclough@apple.com>
3168
3169         Build fix following r64624.
3170
3171         * JavaScriptCore.xcodeproj/project.pbxproj:
3172         * wtf/PageAllocation.h:
3173
3174 2010-08-03  Nathan Lawrence  <nlawrence@apple.com>
3175
3176         Reviewed by Gavin Barraclough.
3177
3178         https://bugs.webkit.org/show_bug.cgi?id=43269
3179
3180         Added new allocateAligned methods to PageAllocation.  In order to
3181         prevent a regress in performance, the function needs to be inlined.
3182
3183         Additionally, I ported the symbian block allocator to use
3184         PageAllocation and added a new WTF::Bitmap class to support this.
3185
3186         * GNUmakefile.am:
3187         * JavaScriptCore.gypi:
3188         * JavaScriptCore.xcodeproj/project.pbxproj:
3189         * runtime/AlignedMemoryAllocator.h: Added.
3190         (JSC::AlignedMemory::deallocate):
3191         (JSC::AlignedMemory::base):
3192         (JSC::AlignedMemory::AlignedMemory):
3193         (JSC::AlignedMemoryAllocator::destroy):
3194         (JSC::AlignedMemoryAllocator::allocate):
3195         (JSC::AlignedMemoryAllocator::AlignedMemoryAllocator):
3196         (JSC::AlignedMemoryAllocator::~AlignedMemoryAllocator):
3197         (JSC::AlignedMemoryAllocator::free):
3198         * runtime/Collector.cpp:
3199         (JSC::Heap::Heap):
3200         (JSC::Heap::destroy):
3201         (JSC::Heap::allocateBlock):
3202         (JSC::Heap::freeBlock):
3203         (JSC::Heap::freeBlocks):
3204         (JSC::Heap::allocate):
3205         (JSC::Heap::shrinkBlocks):
3206         (JSC::Heap::markConservatively):
3207         (JSC::Heap::clearMarkBits):
3208         (JSC::Heap::markedCells):
3209         * runtime/Collector.h:
3210         (JSC::CollectorHeap::collectorBlock):
3211         * runtime/CollectorHeapIterator.h:
3212         (JSC::CollectorHeapIterator::operator*):
3213         (JSC::LiveObjectIterator::operator++):
3214         (JSC::DeadObjectIterator::operator++):
3215         * wtf/Bitmap.h: Added.
3216         (WTF::Bitmap::get):
3217         (WTF::Bitmap::set):
3218         (WTF::Bitmap::clear):
3219         (WTF::Bitmap::clearAll):
3220         (WTF::Bitmap::advanceToNextFreeBit):
3221         (WTF::Bitmap::count):
3222         (WTF::Bitmap::isEmpty):
3223         (WTF::Bitmap::isFull):
3224         * wtf/PageAllocation.h:
3225         (WTF::PageAllocation::operator UnspecifiedBoolType):
3226         (WTF::PageAllocation::allocateAligned):
3227         (WTF::PageAllocation::reserveAligned):
3228         * wtf/Platform.h:
3229         * wtf/symbian: Removed.
3230         * wtf/symbian/BlockAllocatorSymbian.cpp: Removed.
3231         * wtf/symbian/BlockAllocatorSymbian.h: Removed.
3232
3233 2010-08-03  Michael Saboff  <msaboff@apple.com>
3234
3235         Reviewed by Gavin Barraclough.
3236
3237         Fix for https://bugs.webkit.org/show_bug.cgi?id=43314.  The prior code
3238         was using the wrong "length" value to move array contents when adding
3239         space to the beginning of an array for an unshift() or similar
3240         operation.  Instead of using m_vectorLength, the length of the
3241         allocated JSValue array, the code was using m_length, the declared
3242         length of the array.  These two values do not need to match.
3243
3244         * JavaScriptCore.xcodeproj/project.pbxproj:
3245         * runtime/JSArray.cpp:
3246         (JSC::JSArray::increaseVectorPrefixLength):
3247
3248 2010-08-03  Chao-ying Fu  <fu@mips.com>
3249
3250         Reviewed by Gavin Barraclough.
3251
3252         Fix following https://bugs.webkit.org/show_bug.cgi?id=43089
3253         (accidentally inverted a compiler version check).
3254
3255         * jit/ExecutableAllocator.h:
3256         (JSC::ExecutableAllocator::cacheFlush):
3257
3258 2010-08-03  Patrick Gansterer  <paroga@paroga.com>
3259
3260         Reviewed by Gavin Barraclough.
3261
3262         Implement DEFINE_STUB_FUNCTION for WinCE.
3263         https://bugs.webkit.org/show_bug.cgi?id=34953
3264
3265         * jit/JITStubs.cpp:
3266         (JSC::):
3267         (JSC::DEFINE_STUB_FUNCTION):
3268
3269 2010-08-02  Gavin Barraclough  <barraclough@apple.com>
3270
3271         Reviewed by Oliver Hunt.
3272
3273         Bug 43390 - Do not CRASH if we run out of room for jit code.
3274
3275         Change the ExecutableAllocator implementations not to crash, and to return 0 if memory cannot be allocated.
3276         The assemblers should pass this through without trying to use it in executableCopy.
3277         Change the LinkBuffer to handle this, and to provide an allocationSuccessful() method to test for this.
3278
3279         Change the JIT to throw an exception if allocation fails.
3280         Make JIT optimizations fail gracefully if memory cannot be allocated (use non-optimized path).
3281         Change YARR JIT to fallback to PCRE 
3282
3283         * assembler/ARMAssembler.cpp:
3284         (JSC::ARMAssembler::executableCopy):
3285         * assembler/ARMv7Assembler.h:
3286         (JSC::ARMv7Assembler::executableCopy):
3287         * assembler/LinkBuffer.h:
3288         (JSC::LinkBuffer::allocationSuccessful):
3289         * assembler/MIPSAssembler.h:
3290         (JSC::MIPSAssembler::executableCopy):
3291         * assembler/X86Assembler.h:
3292         (JSC::X86Assembler::executableCopy):
3293         * bytecode/StructureStubInfo.h:
3294         (JSC::StructureStubInfo::initGetByIdProto):
3295         (JSC::StructureStubInfo::initGetByIdChain):
3296         (JSC::StructureStubInfo::initGetByIdSelfList):
3297         (JSC::StructureStubInfo::initGetByIdProtoList):
3298         (JSC::StructureStubInfo::initPutByIdTransition):
3299         * jit/ExecutableAllocator.cpp:
3300         (JSC::ExecutablePool::systemAlloc):
3301         * jit/ExecutableAllocatorFixedVMPool.cpp:
3302         (JSC::FixedVMPoolAllocator::allocInternal):
3303         * jit/JIT.cpp:
3304         (JSC::JIT::privateCompile):
3305         * jit/JIT.h:
3306         (JSC::JIT::compileGetByIdProto):
3307         (JSC::JIT::compileGetByIdSelfList):
3308         (JSC::JIT::compileGetByIdProtoList):
3309         (JSC::JIT::compileGetByIdChainList):
3310         (JSC::JIT::compileGetByIdChain):
3311         (JSC::JIT::compilePutByIdTransition):
3312         (JSC::JIT::compilePatchGetArrayLength):
3313         * jit/JITOpcodes.cpp:
3314         (JSC::JIT::privateCompileCTIMachineTrampolines):
3315         * jit/JITOpcodes32_64.cpp:
3316         (JSC::JIT::privateCompileCTIMachineTrampolines):
3317         (JSC::JIT::privateCompileCTINativeCall):
3318         * jit/JITPropertyAccess.cpp:
3319         (JSC::JIT::stringGetByValStubGenerator):
3320         (JSC::JIT::privateCompilePutByIdTransition):
3321         (JSC::JIT::privateCompilePatchGetArrayLength):
3322         (JSC::JIT::privateCompileGetByIdProto):
3323         (JSC::JIT::privateCompileGetByIdSelfList):
3324         (JSC::JIT::privateCompileGetByIdProtoList):
3325         (JSC::JIT::privateCompileGetByIdChainList):
3326         (JSC::JIT::privateCompileGetByIdChain):
3327         * jit/JITPropertyAccess32_64.cpp:
3328         (JSC::JIT::stringGetByValStubGenerator):
3329         (JSC::JIT::privateCompilePutByIdTransition):
3330         (JSC::JIT::privateCompilePatchGetArrayLength):
3331         (JSC::JIT::privateCompileGetByIdProto):
3332         (JSC::JIT::privateCompileGetByIdSelfList):
3333         (JSC::JIT::privateCompileGetByIdProtoList):
3334         (JSC::JIT::privateCompileGetByIdChainList):
3335         (JSC::JIT::privateCompileGetByIdChain):
3336         * jit/JITStubs.cpp:
3337         (JSC::JITThunks::tryCachePutByID):
3338         (JSC::JITThunks::tryCacheGetByID):
3339         (JSC::DEFINE_STUB_FUNCTION):
3340         (JSC::setupPolymorphicProtoList):
3341         * jit/JITStubs.h:
3342         * jit/SpecializedThunkJIT.h:
3343         (JSC::SpecializedThunkJIT::finalize):
3344         * runtime/ExceptionHelpers.cpp:
3345         (JSC::createOutOfMemoryError):
3346         * runtime/ExceptionHelpers.h:
3347         * runtime/Executable.cpp:
3348         (JSC::EvalExecutable::compileInternal):
3349         (JSC::ProgramExecutable::compileInternal):
3350         (JSC::FunctionExecutable::compileForCallInternal):
3351         (JSC::FunctionExecutable::compileForConstructInternal):
3352         (JSC::FunctionExecutable::reparseExceptionInfo):
3353         (JSC::EvalExecutable::reparseExceptionInfo):
3354         * yarr/RegexJIT.cpp:
3355         (JSC::Yarr::RegexGenerator::compile):
3356
3357 2010-08-03  Geoffrey Garen  <ggaren@apple.com>
3358
3359         Reviewed by Oliver Hunt.
3360
3361         Fixed a crash seen on the GTK 64bit buildbot.
3362         
3363         When JSArray is allocated for the vptr stealing hack, it's not allocated
3364         in the heap, so the JSArray constructor can't safely call Heap::heap().
3365         
3366         Since this was subtle enough to confuse smart people, I've changed JSArray
3367         to have an explicit vptr stealing constructor.
3368
3369         * JavaScriptCore.xcodeproj/project.pbxproj:
3370         * runtime/JSArray.cpp:
3371         (JSC::JSArray::JSArray):
3372         * runtime/JSArray.h:
3373         (JSC::JSArray::):
3374         * runtime/JSGlobalData.cpp:
3375         (JSC::JSGlobalData::storeVPtrs):
3376
3377 2010-08-03  Alex Milowski  <alex@milowski.com>
3378
3379         Reviewed by Beth Dakin.
3380
3381         Changed the ENABLE_MATHML value to enable MathML by default.
3382
3383         * Configurations/FeatureDefines.xcconfig:
3384
3385 2010-08-03  Michael Saboff  <msaboff@apple.com>
3386
3387         Reviewed by Gavin Barraclough.
3388
3389         Change to keep returned pointer from malloc family functions to
3390         quiet memory leak detect.  The pointer is saved in the new m_allocBase
3391         member of the ArrayStorage structure.  This fixes the issue found in 
3392         https://bugs.webkit.org/show_bug.cgi?id=43229.
3393
3394         As part of this change, we use m_allocBase when reallocating and
3395         freeing the memory associated with ArrayStorage.
3396
3397         * runtime/JSArray.cpp:
3398         (JSC::JSArray::JSArray):
3399         (JSC::JSArray::~JSArray):
3400         (JSC::JSArray::putSlowCase):
3401         (JSC::JSArray::increaseVectorLength):
3402         (JSC::JSArray::increaseVectorPrefixLength):
3403         * runtime/JSArray.h:
3404
3405 2010-08-03  Geoffrey Garen  <ggaren@apple.com>
3406
3407         Reviewed by Mark Rowe.
3408
3409         https://bugs.webkit.org/show_bug.cgi?id=43444
3410         PLATFORM(CF) is false on Windows in JavaScriptCore
3411
3412         Moved some PLATFORM(WIN) #defines down into JavaScriptCore.
3413
3414         * wtf/Platform.h: Added WTF_PLATFORM_CF 1 and WTF_USE_PTHREADS 0, inherited
3415         from WebCore/config.h. Removed WTF_USE_WININET 1 since WebCore/config.h
3416         just #undefined that later.
3417
3418 2010-08-03  Geoffrey Garen  <ggaren@apple.com>
3419
3420         Try to fix Windows build: Don't use GCActivityCallbackCF on Windows, since
3421         PLATFORM(CF) is not defined on Windows.
3422         
3423         We'll need to enable the GC activity callback some other way, but this
3424         change should get the build back to normal.
3425
3426         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
3427
3428         * runtime/GCActivityCallbackCF.cpp: Make it easier to detect this error
3429         in the future with an explicit error message.
3430
3431 2010-08-03  Geoffrey Garen  <ggaren@apple.com>
3432
3433         Try to fix Windows build: update .def file.
3434
3435         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3436
3437 2010-08-03  Nathan Lawrence  <nlawrence@apple.com>
3438
3439         Reviewed by Oliver Hunt.
3440
3441         https://bugs.webkit.org/show_bug.cgi?id=41318
3442         GC should reclaim garbage even when new objects are not being allocated rapidly
3443
3444         Added a callback in JavaScriptCore that gets triggered after an
3445         allocation causes the heap to reset.  This is useful for adding a
3446         timer that will trigger garbage collection after the "last" allocation.
3447
3448         Also needed was to add lock and unlock methods to JSLock that needed
3449         only a JSGlobalData object versus an ExecState object.
3450
3451         * CMakeLists.txt:
3452         * GNUmakefile.am:
3453         * JavaScriptCore.exp:
3454         * JavaScriptCore.gypi:
3455         * JavaScriptCore.pro:
3456         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
3457         * JavaScriptCore.xcodeproj/project.pbxproj:
3458         * jit/JITPropertyAccess.cpp:
3459         (JSC::JIT::emit_op_put_by_val):
3460         * runtime/Collector.cpp:
3461         (JSC::Heap::Heap):
3462         (JSC::Heap::reset):
3463         (JSC::Heap::setActivityCallback):
3464         * runtime/Collector.h:
3465         * runtime/GCActivityCallback.cpp: Added.
3466         (JSC::DefaultGCActivityCallback::DefaultGCActivityCallback):
3467         (JSC::DefaultGCActivityCallback::~DefaultGCActivityCallback):
3468         (JSC::DefaultGCActivityCallback::operator()):
3469         * runtime/GCActivityCallback.h: Added.
3470         (JSC::GCActivityCallback::~GCActivityCallback):
3471         (JSC::GCActivityCallback::operator()):
3472         (JSC::GCActivityCallback::GCActivityCallback):
3473         (JSC::DefaultGCActivityCallback::create):
3474         * runtime/GCActivityCallbackCF.cpp: Added.
3475         (JSC::DefaultGCActivityCallbackPlatformData::trigger):
3476         (JSC::DefaultGCActivityCallback::DefaultGCActivityCallback):
3477         (JSC::DefaultGCActivityCallback::~DefaultGCActivityCallback):
3478         (JSC::DefaultGCActivityCallback::operator()):
3479         * runtime/JSLock.cpp:
3480         (JSC::JSLock::JSLock):
3481         * runtime/JSLock.h:
3482
3483 2010-08-02  Kevin Ollivier  <kevino@theolliviers.com>
3484
3485         [wx] Build fix after removal of need to compile ExecutableAllocatorPosix.cpp
3486
3487         * wscript:
3488
3489 2010-08-02  Mahesh Kulkarni  <mahesh.kulkarni@nokia.com>
3490
3491         Reviewed by Simon Hausmann.
3492
3493         [QT] build fix for symbian
3494         https://bugs.webkit.org/show_bug.cgi?id=43234
3495
3496         1) wrong order of passing param's
3497         2) static_cast complains on symbian so using reinterpret_cast
3498
3499         No new tests added. Just a build fix for qt symbian
3500
3501         * wtf/PageAllocation.cpp:
3502         (WTF::PageAllocation::commit):
3503         (WTF::PageAllocation::decommit):
3504         (WTF::PageAllocation::reserve):
3505
3506 2010-07-30  Luiz Agostini  <luiz.agostini@openbossa.org>
3507
3508         Reviewed by Simon Fraser.
3509
3510         Enabling view modes to all platforms
3511         https://bugs.webkit.org/show_bug.cgi?id=37505
3512
3513         Removing ENABLE_WIDGETS_10_SUPPORT flag.
3514
3515         As view mode media feature is not part of widget 1.0 specification
3516         any more the ENABLE_WIDGETS_10_SUPPORT flag may be removed. The only use
3517         of this flag was related to view mode media feature implementation in Qt. 
3518
3519         * wtf/Platform.h:
3520
3521 2010-07-30  Andy Estes  <aestes@apple.com>
3522
3523         Reviewed by David Kilzer.
3524
3525         Add Xcode support for compiling WebKit against iOS SDKs.
3526         https://bugs.webkit.org/show_bug.cgi?id=42796
3527
3528         * Configurations/Base.xcconfig:
3529         * Configurations/DebugRelease.xcconfig:
3530         * Configurations/FeatureDefines.xcconfig:
3531
3532 2010-07-30  Dumitru Daniliuc  <dumi@chromium.org>
3533
3534         Reviewed by Davin Levin.
3535
3536         Added a yield() function.
3537         https://bugs.webkit.org/show_bug.cgi?id=42843
3538
3539         * JavaScriptCore.exp:
3540         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3541         * wtf/Threading.h:
3542         * wtf/ThreadingPthreads.cpp:
3543         (WTF::yield):
3544         * wtf/ThreadingWin.cpp:
3545         (WTF::yield):
3546         * wtf/gtk/ThreadingGtk.cpp:
3547         (WTF::yield):
3548         * wtf/qt/ThreadingQt.cpp:
3549         (WTF::yield):
3550
3551 2010-07-30  Rafael Antognolli  <antognolli@profusion.mobi>
3552
3553         Reviewed by Antonio Gomes.
3554
3555         [EFL] Add library version and soname to EFL generated libraries and binary.
3556         https://bugs.webkit.org/show_bug.cgi?id=43212
3557
3558         Add version and soname to libjavascriptcore.so and libwtf.so in case of
3559         linking as shared libraries, and version to jsc executable.
3560
3561         * CMakeLists.txt:
3562         * jsc/CMakeLists.txt:
3563         * wtf/CMakeLists.txt:
3564
3565 2010-07-30  Mahesh Kulkarni  <mahesh.kulkarni@nokia.com>
3566
3567         Reviewed by Simon Hausmann.
3568
3569         [QT] build fix for symbian
3570         https://bugs.webkit.org/show_bug.cgi?id=43234
3571
3572         * wtf/PageAllocation.h:
3573         (WTF::PageAllocation::PageAllocation):
3574
3575 2010-07-29  Sheriff Bot  <webkit.review.bot@gmail.com>
3576
3577         Unreviewed, rolling out r64313.
3578         http://trac.webkit.org/changeset/64313
3579         https://bugs.webkit.org/show_bug.cgi?id=43233