Result of Error.prototype.toString not ES5 conformant
[WebKit-https.git] / Source / JavaScriptCore / ChangeLog
1 2011-11-15  Gavin Barraclough  <barraclough@apple.com>
2
3         Result of Error.prototype.toString not ES5 conformant
4         https://bugs.webkit.org/show_bug.cgi?id=70889
5
6         Reviewed by Oliver Hunt.
7
8         * runtime/ErrorPrototype.cpp:
9         (JSC::errorProtoFuncToString):
10
11 2011-11-15  Simon Hausmann  <simon.hausmann@nokia.com>
12
13         [Qt] Centralize hide_symbols and ensure all libs are built with symbol visibility & bsymbolic_functions
14
15         Reviewed by Tor Arne Vestbø.
16
17         * Target.pri: Eliminate duplicated symbol stuff that lives now in default_post.prf.
18
19 2011-11-15  Yuqiang Xian  <yuqiang.xian@intel.com>
20
21         Remove DFGJITCompilerInlineMethods
22         https://bugs.webkit.org/show_bug.cgi?id=72366
23
24         Reviewed by Filip Pizlo.
25
26         Those methods are actually seldom used. Modify the few such places and
27         remove DFGJITCompilerInlineMethods stuffs totally.
28
29         * GNUmakefile.list.am:
30         * JavaScriptCore.xcodeproj/project.pbxproj:
31         * dfg/DFGJITCompiler.h:
32         (JSC::DFG::JITCompiler::addressOfDoubleConstant):
33         * dfg/DFGJITCompilerInlineMethods.h: Removed.
34         * dfg/DFGSpeculativeJIT.cpp:
35         * dfg/DFGSpeculativeJIT.h:
36         (JSC::DFG::SpeculativeJIT::silentFillFPR):
37         * dfg/DFGSpeculativeJIT32_64.cpp:
38         (JSC::DFG::SpeculativeJIT::fillJSValue):
39         (JSC::DFG::SpeculativeJIT::cachedGetMethod):
40
41 2011-11-14  Filip Pizlo  <fpizlo@apple.com>
42
43         DFG::SpeculativeJIT and DFG::JITCodeGenerator should be combined
44         https://bugs.webkit.org/show_bug.cgi?id=72348
45
46         Reviewed by Gavin Barraclough.
47         
48         Moved all of JITCodeGenerator into SpeculativeJIT.
49
50         * CMakeLists.txt:
51         * GNUmakefile.list.am:
52         * JavaScriptCore.xcodeproj/project.pbxproj:
53         * Target.pri:
54         * dfg/DFGJITCodeGenerator.cpp: Removed.
55         * dfg/DFGJITCodeGenerator.h: Removed.
56         * dfg/DFGJITCodeGenerator32_64.cpp: Removed.
57         * dfg/DFGJITCodeGenerator64.cpp: Removed.
58         * dfg/DFGJITCompiler.cpp:
59         * dfg/DFGRepatch.cpp:
60         (JSC::DFG::generateProtoChainAccessStub):
61         (JSC::DFG::tryCacheGetByID):
62         (JSC::DFG::tryCachePutByID):
63         * dfg/DFGSpeculativeJIT.cpp:
64         (JSC::DFG::SpeculativeJIT::clearGenerationInfo):
65         (JSC::DFG::SpeculativeJIT::fillStorage):
66         (JSC::DFG::SpeculativeJIT::useChildren):
67         (JSC::DFG::SpeculativeJIT::isStrictInt32):
68         (JSC::DFG::SpeculativeJIT::isKnownInteger):
69         (JSC::DFG::SpeculativeJIT::isKnownNumeric):
70         (JSC::DFG::SpeculativeJIT::isKnownCell):
71         (JSC::DFG::SpeculativeJIT::isKnownNotCell):
72         (JSC::DFG::SpeculativeJIT::isKnownNotInteger):
73         (JSC::DFG::SpeculativeJIT::isKnownNotNumber):
74         (JSC::DFG::SpeculativeJIT::isKnownBoolean):
75         (JSC::DFG::SpeculativeJIT::writeBarrier):
76         (JSC::DFG::SpeculativeJIT::markCellCard):
77         (JSC::DFG::SpeculativeJIT::nonSpeculativeCompare):
78         (JSC::DFG::SpeculativeJIT::nonSpeculativeStrictEq):
79         (JSC::DFG::dataFormatString):
80         (JSC::DFG::SpeculativeJIT::dump):
81         (JSC::DFG::SpeculativeJIT::checkConsistency):
82         (JSC::DFG::GPRTemporary::GPRTemporary):
83         (JSC::DFG::GPRTemporary::adopt):
84         (JSC::DFG::FPRTemporary::FPRTemporary):
85         * dfg/DFGSpeculativeJIT.h:
86         (JSC::DFG::SpeculativeJIT::at):
87         (JSC::DFG::SpeculativeJIT::lock):
88         (JSC::DFG::SpeculativeJIT::unlock):
89         (JSC::DFG::SpeculativeJIT::canReuse):
90         (JSC::DFG::SpeculativeJIT::reuse):
91         (JSC::DFG::SpeculativeJIT::allocate):
92         (JSC::DFG::SpeculativeJIT::tryAllocate):
93         (JSC::DFG::SpeculativeJIT::fprAllocate):
94         (JSC::DFG::SpeculativeJIT::isFilled):
95         (JSC::DFG::SpeculativeJIT::isFilledDouble):
96         (JSC::DFG::SpeculativeJIT::use):
97         (JSC::DFG::SpeculativeJIT::selectScratchGPR):
98         (JSC::DFG::SpeculativeJIT::silentSpillGPR):
99         (JSC::DFG::SpeculativeJIT::silentSpillFPR):
100         (JSC::DFG::SpeculativeJIT::silentFillGPR):
101         (JSC::DFG::SpeculativeJIT::silentFillFPR):
102         (JSC::DFG::SpeculativeJIT::silentSpillAllRegisters):
103         (JSC::DFG::SpeculativeJIT::silentFillAllRegisters):
104         (JSC::DFG::SpeculativeJIT::boxDouble):
105         (JSC::DFG::SpeculativeJIT::unboxDouble):
106         (JSC::DFG::SpeculativeJIT::spill):
107         (JSC::DFG::SpeculativeJIT::isConstant):
108         (JSC::DFG::SpeculativeJIT::isJSConstant):
109         (JSC::DFG::SpeculativeJIT::isInt32Constant):
110         (JSC::DFG::SpeculativeJIT::isDoubleConstant):
111         (JSC::DFG::SpeculativeJIT::isNumberConstant):
112         (JSC::DFG::SpeculativeJIT::isBooleanConstant):
113         (JSC::DFG::SpeculativeJIT::isFunctionConstant):
114         (JSC::DFG::SpeculativeJIT::valueOfInt32Constant):
115         (JSC::DFG::SpeculativeJIT::valueOfNumberConstant):
116         (JSC::DFG::SpeculativeJIT::addressOfDoubleConstant):
117         (JSC::DFG::SpeculativeJIT::valueOfJSConstant):
118         (JSC::DFG::SpeculativeJIT::valueOfBooleanConstant):
119         (JSC::DFG::SpeculativeJIT::valueOfFunctionConstant):
120         (JSC::DFG::SpeculativeJIT::isNullConstant):
121         (JSC::DFG::SpeculativeJIT::identifier):
122         (JSC::DFG::SpeculativeJIT::flushRegisters):
123         (JSC::DFG::SpeculativeJIT::isFlushed):
124         (JSC::DFG::SpeculativeJIT::valueOfJSConstantAsImmPtr):
125         (JSC::DFG::SpeculativeJIT::bitOp):
126         (JSC::DFG::SpeculativeJIT::shiftOp):
127         (JSC::DFG::SpeculativeJIT::detectPeepHoleBranch):
128         (JSC::DFG::SpeculativeJIT::addressOfCallData):
129         (JSC::DFG::SpeculativeJIT::tagOfCallData):
130         (JSC::DFG::SpeculativeJIT::payloadOfCallData):
131         (JSC::DFG::SpeculativeJIT::integerResult):
132         (JSC::DFG::SpeculativeJIT::noResult):
133         (JSC::DFG::SpeculativeJIT::cellResult):
134         (JSC::DFG::SpeculativeJIT::booleanResult):
135         (JSC::DFG::SpeculativeJIT::jsValueResult):
136         (JSC::DFG::SpeculativeJIT::storageResult):
137         (JSC::DFG::SpeculativeJIT::doubleResult):
138         (JSC::DFG::SpeculativeJIT::initConstantInfo):
139         (JSC::DFG::SpeculativeJIT::resetCallArguments):
140         (JSC::DFG::SpeculativeJIT::addCallArgument):
141         (JSC::DFG::SpeculativeJIT::setupArguments):
142         (JSC::DFG::SpeculativeJIT::setupArgumentsExecState):
143         (JSC::DFG::SpeculativeJIT::setupArgumentsWithExecState):
144         (JSC::DFG::SpeculativeJIT::setupTwoStubArgs):
145         (JSC::DFG::SpeculativeJIT::setupStubArguments):
146         (JSC::DFG::SpeculativeJIT::callOperation):
147         (JSC::DFG::SpeculativeJIT::appendCallWithExceptionCheck):
148         (JSC::DFG::SpeculativeJIT::appendCallWithExceptionCheckSetResult):
149         (JSC::DFG::SpeculativeJIT::setupResults):
150         (JSC::DFG::SpeculativeJIT::appendCallSetResult):
151         (JSC::DFG::SpeculativeJIT::addBranch):
152         (JSC::DFG::SpeculativeJIT::linkBranches):
153         (JSC::DFG::SpeculativeJIT::block):
154         (JSC::DFG::SpeculativeJIT::checkConsistency):
155         (JSC::DFG::SpeculativeJIT::BranchRecord::BranchRecord):
156         (JSC::DFG::IntegerOperand::IntegerOperand):
157         (JSC::DFG::IntegerOperand::~IntegerOperand):
158         (JSC::DFG::IntegerOperand::index):
159         (JSC::DFG::IntegerOperand::format):
160         (JSC::DFG::IntegerOperand::gpr):
161         (JSC::DFG::IntegerOperand::use):
162         (JSC::DFG::DoubleOperand::DoubleOperand):
163         (JSC::DFG::DoubleOperand::~DoubleOperand):
164         (JSC::DFG::DoubleOperand::index):
165         (JSC::DFG::DoubleOperand::fpr):
166         (JSC::DFG::DoubleOperand::use):
167         (JSC::DFG::JSValueOperand::JSValueOperand):
168         (JSC::DFG::JSValueOperand::~JSValueOperand):
169         (JSC::DFG::JSValueOperand::index):
170         (JSC::DFG::JSValueOperand::gpr):
171         (JSC::DFG::JSValueOperand::jsValueRegs):
172         (JSC::DFG::JSValueOperand::isDouble):
173         (JSC::DFG::JSValueOperand::fill):
174         (JSC::DFG::JSValueOperand::tagGPR):
175         (JSC::DFG::JSValueOperand::payloadGPR):
176         (JSC::DFG::JSValueOperand::fpr):
177         (JSC::DFG::JSValueOperand::use):
178         (JSC::DFG::StorageOperand::StorageOperand):
179         (JSC::DFG::StorageOperand::~StorageOperand):
180         (JSC::DFG::StorageOperand::index):
181         (JSC::DFG::StorageOperand::gpr):
182         (JSC::DFG::StorageOperand::use):
183         (JSC::DFG::GPRTemporary::~GPRTemporary):
184         (JSC::DFG::GPRTemporary::gpr):
185         (JSC::DFG::FPRTemporary::~FPRTemporary):
186         (JSC::DFG::FPRTemporary::fpr):
187         (JSC::DFG::FPRTemporary::FPRTemporary):
188         (JSC::DFG::GPRResult::GPRResult):
189         (JSC::DFG::GPRResult2::GPRResult2):
190         (JSC::DFG::FPRResult::FPRResult):
191         (JSC::DFG::FPRResult::lockedResult):
192         (JSC::DFG::SpeculativeJIT::SpeculativeJIT):
193         * dfg/DFGSpeculativeJIT32_64.cpp:
194         (JSC::DFG::SpeculativeJIT::fillInteger):
195         (JSC::DFG::SpeculativeJIT::fillDouble):
196         (JSC::DFG::SpeculativeJIT::fillJSValue):
197         (JSC::DFG::SpeculativeJIT::nonSpeculativeValueToNumber):
198         (JSC::DFG::SpeculativeJIT::nonSpeculativeValueToInt32):
199         (JSC::DFG::SpeculativeJIT::nonSpeculativeUInt32ToNumber):
200         (JSC::DFG::SpeculativeJIT::nonSpeculativeKnownConstantArithOp):
201         (JSC::DFG::SpeculativeJIT::nonSpeculativeBasicArithOp):
202         (JSC::DFG::SpeculativeJIT::cachedGetById):
203         (JSC::DFG::SpeculativeJIT::cachedPutById):
204         (JSC::DFG::SpeculativeJIT::cachedGetMethod):
205         (JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompareNull):
206         (JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranchNull):
207         (JSC::DFG::SpeculativeJIT::nonSpeculativeCompareNull):
208         (JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranch):
209         (JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompare):
210         (JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeStrictEq):
211         (JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeStrictEq):
212         (JSC::DFG::SpeculativeJIT::emitCall):
213         * dfg/DFGSpeculativeJIT64.cpp:
214         (JSC::DFG::SpeculativeJIT::fillInteger):
215         (JSC::DFG::SpeculativeJIT::fillDouble):
216         (JSC::DFG::SpeculativeJIT::fillJSValue):
217         (JSC::DFG::SpeculativeJIT::nonSpeculativeValueToNumber):
218         (JSC::DFG::SpeculativeJIT::nonSpeculativeValueToInt32):
219         (JSC::DFG::SpeculativeJIT::nonSpeculativeUInt32ToNumber):
220         (JSC::DFG::SpeculativeJIT::nonSpeculativeKnownConstantArithOp):
221         (JSC::DFG::SpeculativeJIT::nonSpeculativeBasicArithOp):
222         (JSC::DFG::SpeculativeJIT::cachedGetById):
223         (JSC::DFG::SpeculativeJIT::cachedPutById):
224         (JSC::DFG::SpeculativeJIT::cachedGetMethod):
225         (JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompareNull):
226         (JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranchNull):
227         (JSC::DFG::SpeculativeJIT::nonSpeculativeCompareNull):
228         (JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranch):
229         (JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompare):
230         (JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeStrictEq):
231         (JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeStrictEq):
232         (JSC::DFG::SpeculativeJIT::emitCall):
233         * runtime/JSFunction.h:
234
235 2011-11-14  Filip Pizlo  <fpizlo@apple.com>
236
237         Weak reference harvesters should run to fixpoint
238         https://bugs.webkit.org/show_bug.cgi?id=72346
239
240         Reviewed by Oliver Hunt.
241
242         * heap/Heap.cpp:
243         (JSC::Heap::markRoots):
244         * heap/ListableHandler.h:
245         (JSC::ListableHandler::next):
246         (JSC::ListableHandler::List::head):
247         (JSC::ListableHandler::List::removeNext):
248         (JSC::ListableHandler::List::removeAll):
249         * heap/MarkStack.cpp:
250         (JSC::MarkStackThreadSharedData::reset):
251         (JSC::SlotVisitor::harvestWeakReferences):
252         * heap/MarkStack.h:
253         (JSC::MarkStack::isEmpty):
254
255 2011-11-14  Oliver Hunt  <oliver@apple.com>
256
257         Start migrating typed array impl types to WTF
258         https://bugs.webkit.org/show_bug.cgi?id=72336
259
260         Reviewed by Geoffrey Garen.
261
262         Add typed array impls to WTF forwarding header.
263
264         * wtf/Forward.h:
265
266 2011-11-14  Julien Chaffraix  <jchaffraix@webkit.org>
267
268         Add --css-grid-layout to build-webkit and the build systems
269         https://bugs.webkit.org/show_bug.cgi?id=72320
270
271         Reviewed by Ojan Vafai.
272
273         * Configurations/FeatureDefines.xcconfig:
274
275 2011-11-14  Geoffrey Garen  <ggaren@apple.com>
276
277         A little bit of arguments / activation cleanup
278         https://bugs.webkit.org/show_bug.cgi?id=72339
279
280         Reviewed by Gavin Barraclough.
281         
282         Renamed copyRegisters => tearOff to match bytecode and other terminology.
283         
284         Renamed setActivation => didTearOffActivation to indicate that this is a
285         notification the object may choose to ignore. Moved "Should I ignore?"
286         code into the arguments object to avoid duplication elsewhere.
287
288         * interpreter/Interpreter.cpp:
289         (JSC::Interpreter::unwindCallFrame):
290         (JSC::Interpreter::privateExecute):
291         (JSC::Interpreter::retrieveArguments):
292         * jit/JITStubs.cpp:
293         (JSC::DEFINE_STUB_FUNCTION):
294         * runtime/Arguments.h:
295         (JSC::Arguments::createAndTearOff):
296         (JSC::Arguments::didTearOffActivation):
297         (JSC::Arguments::finishCreationButDontTearOff):
298         (JSC::Arguments::finishCreation):
299         (JSC::Arguments::finishCreationAndTearOff):
300         (JSC::Arguments::tearOff):
301
302         * runtime/JSActivation.h:
303         (JSC::JSActivation::tearOff): Moved Activation's code into its own header
304         because that's where it belongs.
305
306 2011-11-14  Gavin Barraclough  <barraclough@apple.com>
307
308         Should sign the jsc binary
309         https://bugs.webkit.org/show_bug.cgi?id=72332
310
311         Reviewed by David Kilzer.
312
313         * Configurations/JSC.xcconfig:
314         * entitlements.plist: Added.
315
316 2011-11-14  Filip Pizlo  <fpizlo@apple.com>
317
318         DFG's inline references to objects should be tracked
319         https://bugs.webkit.org/show_bug.cgi?id=72313
320
321         Reviewed by Gavin Barraclough.
322         
323         Added a pinCell() method in the parser that currently creates a
324         dummy constant in CodeBlock. Added calls to pinCell() wherever the
325         DFG would inline a constant reference that the original code would
326         not have referred to.
327         
328         * dfg/DFGByteCodeParser.cpp:
329         (JSC::DFG::ByteCodeParser::getCellConstantIndex):
330         (JSC::DFG::ByteCodeParser::pinCell):
331         (JSC::DFG::ByteCodeParser::cellConstant):
332         (JSC::DFG::ByteCodeParser::handleCall):
333         (JSC::DFG::ByteCodeParser::handleInlining):
334         (JSC::DFG::ByteCodeParser::parseBlock):
335
336 2011-11-14  Filip Pizlo  <fpizlo@apple.com>
337
338         DFG put_by_id transition optimizations test the wrong structures
339         https://bugs.webkit.org/show_bug.cgi?id=72324
340
341         Reviewed by Gavin Barraclough.
342
343         * dfg/DFGByteCodeParser.cpp:
344         (JSC::DFG::ByteCodeParser::structureChainIsStillValid):
345         (JSC::DFG::ByteCodeParser::parseBlock):
346         * jit/JITPropertyAccess.cpp:
347         (JSC::JIT::privateCompilePutByIdTransition):
348
349 2011-11-14  Michael Saboff  <msaboff@apple.com>
350
351         Further changes and cleanup to JSString.h and cpp.
352
353         Reviewed by Darin Adler.
354
355         * runtime/JSString.cpp:
356         (JSC::JSString::resolveRope): Change PassRefPtr to RefPtr.  Eliminated exec in slow case calls.
357         (JSC::JSString::resolveRopeSlowCase8): Darin and I agreed that this should have 8 in name.
358         (JSC::JSString::resolveRopeSlowCase): Removed exec parameter.
359         * runtime/JSString.h:
360
361 2011-11-14  Adam Barth  <abarth@webkit.org>
362
363         DateMath.cpp should not depend on JavaScriptCore
364         https://bugs.webkit.org/show_bug.cgi?id=71747
365
366         Reviewed by Darin Adler.
367
368         This patch moves the JSC-specific parts of DateMath into JSDateMath in
369         JavaScriptCore.  There shouldn't be any behavior change.
370
371         * CMakeLists.txt:
372         * GNUmakefile.list.am:
373         * JavaScriptCore.gypi:
374         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
375         * JavaScriptCore.xcodeproj/project.pbxproj:
376         * Target.pri:
377         * runtime/DateConstructor.cpp:
378         * runtime/DateConversion.cpp:
379         * runtime/DateInstance.cpp:
380         * runtime/DateInstanceCache.h:
381         * runtime/DatePrototype.cpp:
382         * runtime/InitializeThreading.cpp:
383         * runtime/JSDateMath.cpp: Copied from Source/JavaScriptCore/wtf/DateMath.cpp.
384         (JSC::timeToMS):
385         (JSC::msToSeconds):
386         * runtime/JSDateMath.h: Copied from Source/JavaScriptCore/wtf/DateMath.h.
387         * wtf/DateMath.cpp:
388         (WTF::isLeapYear):
389         (WTF::msToDays):
390         (WTF::msToMinutes):
391         (WTF::msToHours):
392         (WTF::parseDateFromNullTerminatedCharacters):
393         (WTF::makeRFC2822DateString):
394         * wtf/DateMath.h:
395
396 2011-11-14  Michael Saboff  <msaboff@apple.com>
397
398         Towards 8 bit strings - Add 8 bit handling to JSString Ropes
399         https://bugs.webkit.org/show_bug.cgi?id=72317
400
401         Added bit to track that a rope is made up of all 8 bit fibers.
402         Created an 8 bit path (fast and slow cases) to handle 8 bit 
403         only ropes.
404
405         Reviewed by Oliver Hunt.
406
407         * runtime/JSString.cpp:
408         (JSC::JSString::resolveRope):
409         (JSC::JSString::resolveRopeSlowCase8):
410         (JSC::JSString::resolveRopeSlowCase16):
411         * runtime/JSString.h:
412         (JSC::RopeBuilder::finishCreation):
413         (JSC::RopeBuilder::is8Bit):
414         (JSC::jsSubstring8):
415
416 2011-11-14  Geoffrey Garen  <ggaren@apple.com>
417
418         A little bit of function call cleanup
419         https://bugs.webkit.org/show_bug.cgi?id=72314
420
421         Reviewed by Oliver Hunt.
422
423         * bytecompiler/BytecodeGenerator.cpp:
424         (JSC::BytecodeGenerator::emitCall): Renamed callFrame to registerOffset
425         because this value doesn't give you the offset of the callee's call frame.
426
427         (JSC::BytecodeGenerator::emitReturn): Tightened to use equality instead
428         of greater-than. Removed comment since its reasoning was wrong.
429         
430         (JSC::BytecodeGenerator::emitConstruct): Updated for rename mentioned above.
431
432         (JSC::BytecodeGenerator::isArgumentNumber): Provided a more precise way
433         to ask this question, giving the bytecode generator more freedom to change
434         internal implementation details.
435         
436         * bytecompiler/BytecodeGenerator.h: Reduced default vector capacity because
437         16 was overkill.
438         (JSC::CallArguments::registerOffset): Updated for rename mentioned above.
439
440         * bytecompiler/NodesCodegen.cpp:
441         (JSC::CallArguments::CallArguments):
442         (JSC::CallArguments::newArgument): Factored out argument allocation into
443         a helper function, so I can change it later.
444
445         (JSC::CallFunctionCallDotNode::emitBytecode):
446         (JSC::FunctionBodyNode::emitBytecode): Use helper function mentioned above.
447
448 2011-11-14  Tony Chang  <tony@chromium.org>
449
450         Remove the CSS3_FLEXBOX compile time flag and enable on all ports
451         https://bugs.webkit.org/show_bug.cgi?id=72196
452
453         Reviewed by Ojan Vafai.
454
455         * Configurations/FeatureDefines.xcconfig:
456
457 2011-11-14  Mark Rowe  <mrowe@apple.com>
458
459         <rdar://problem/10424154> testRegExp should not be installed as part of JavaScriptCore
460
461         testRegExp and testapi.js were being installed in the JavaScriptCore framework.
462         As test-only tools they shouldn't be installed there by default, only when
463         FORCE_TOOL_INSTALL is set to YES.
464
465         This patch incorprorates a few related changes:
466         1) Make the jsc and testRegExp targets be configured via .xcconfig files.
467         2) Sets up testRegExp so that SKIP_INSTALL is YES by default, and only NO when
468            FORCE_TOOL_INSTALL is YES.
469         3) Switches the testapi target to using a script build phase to install testapi.js
470            so that the installation will be skipped when SKIP_INSTALL is YES. I'm not sure
471            why this isn't the built-in behavior when a Copy Files build phase has "Copy only
472            when installing" checked, but it doesn't seem to be.
473         4) Other random cleanup such as removing a bogus group that refers to files that do
474            not exist, moving testRegExp.cpp in to the tests group, etc.
475
476         Reviewed by Geoff Garen.
477
478         * Configurations/JSC.xcconfig: Added.
479         * Configurations/TestRegExp.xcconfig: Added.
480         * JavaScriptCore.xcodeproj/project.pbxproj:
481
482 2011-11-14  Michael Saboff  <msaboff@apple.com>
483
484         Towards 8 bit strings - Add 8 bit paths to StringImpl methods
485         https://bugs.webkit.org/show_bug.cgi?id=72290
486
487         Added 8 bit patchs to StringImpl to number and find methods.
488
489         Reviewed by Oliver Hunt.
490
491         * wtf/text/StringImpl.cpp:
492         (WTF::StringImpl::toIntStrict):
493         (WTF::StringImpl::toUIntStrict):
494         (WTF::StringImpl::toInt64Strict):
495         (WTF::StringImpl::toUInt64Strict):
496         (WTF::StringImpl::toIntPtrStrict):
497         (WTF::StringImpl::toInt):
498         (WTF::StringImpl::toUInt):
499         (WTF::StringImpl::toInt64):
500         (WTF::StringImpl::toUInt64):
501         (WTF::StringImpl::toIntPtr):
502         (WTF::StringImpl::toDouble):
503         (WTF::StringImpl::toFloat):
504         (WTF::StringImpl::find):
505         (WTF::StringImpl::reverseFind):
506         * wtf/text/WTFString.cpp:
507         (WTF::toIntegralType):
508         (WTF::lengthOfCharactersAsInteger):
509         (WTF::charactersToIntStrict):
510         (WTF::charactersToUIntStrict):
511         (WTF::charactersToInt64Strict):
512         (WTF::charactersToUInt64Strict):
513         (WTF::charactersToIntPtrStrict):
514         (WTF::charactersToInt):
515         (WTF::charactersToUInt):
516         (WTF::charactersToInt64):
517         (WTF::charactersToUInt64):
518         (WTF::charactersToIntPtr):
519         (WTF::toDoubleType):
520         (WTF::charactersToDouble):
521         (WTF::charactersToFloat):
522         * wtf/text/WTFString.h:
523         (WTF::find):
524         (WTF::reverseFind):
525
526 2011-11-14  Vincent Scheib  <scheib@chromium.org>
527
528         Mouse Lock: Renaming to 'Pointer Lock': ENABLE Flags
529         https://bugs.webkit.org/show_bug.cgi?id=72286
530
531         Reviewed by Adam Barth.
532
533         * wtf/Platform.h:
534
535 2011-11-14  Gavin Barraclough  <barraclough@apple.com>
536
537         https://bugs.webkit.org/show_bug.cgi?id=72280
538
539         Rubber stamped by Geoff Garen.
540
541         Fix 32-bit Lion.
542
543         * JavaScriptCore.xcodeproj/project.pbxproj:
544         * wtf/OSAllocatorPosix.cpp:
545         (WTF::OSAllocator::reserveAndCommit):
546
547 2011-11-14  Geoffrey Garen  <ggaren@apple.com>
548
549         32-bit Build fix: declare virtual register indices to be int rather than
550         unsigned, since they can be positive or negative.
551         
552         For better clarity, explicitly use ReturnPC instead of -1 as the "invalid"
553         state, since we'll never load and operate on the ReturnPC as a JS value.
554
555         * jit/JIT.cpp:
556         (JSC::JIT::JIT):
557         * jit/JIT.h:
558         * jit/JITInlineMethods.h:
559         (JSC::JIT::emitLoadTag):
560         (JSC::JIT::emitLoadPayload):
561         (JSC::JIT::emitLoad):
562         (JSC::JIT::emitLoad2):
563         (JSC::JIT::emitLoadDouble):
564         (JSC::JIT::emitLoadInt32ToDouble):
565         (JSC::JIT::emitStore):
566         (JSC::JIT::emitStoreInt32):
567         (JSC::JIT::emitStoreAndMapInt32):
568         (JSC::JIT::emitStoreCell):
569         (JSC::JIT::emitStoreBool):
570         (JSC::JIT::emitStoreDouble):
571         (JSC::JIT::map):
572         (JSC::JIT::unmap):
573         (JSC::JIT::isMapped):
574         (JSC::JIT::getMappedPayload):
575         (JSC::JIT::getMappedTag):
576         (JSC::JIT::emitJumpSlowCaseIfNotJSCell):
577
578 2011-11-14  Michael Saboff  <msaboff@apple.com>
579
580         Remove unused m_data member from UStringSourceProvider
581         https://bugs.webkit.org/show_bug.cgi?id=72289
582
583         Removed unused m_data member from UStringSourceProvider.
584
585         Reviewed by Oliver Hunt.
586
587         * parser/SourceProvider.h:
588         (JSC::UStringSourceProvider::UStringSourceProvider):
589
590 2011-11-14  Michael Saboff  <msaboff@apple.com>
591
592         Towards 8 Bit Strings: Templatize YARR Parser
593         https://bugs.webkit.org/show_bug.cgi?id=72288
594
595         Changed Yarr::Parser to be a template based on character type.
596
597         Reviewed by Oliver Hunt.
598
599         * yarr/YarrParser.h:
600         (JSC::Yarr::Parser::Parser):
601         (JSC::Yarr::parse):
602
603 2011-11-14  Geoffrey Garen  <ggaren@apple.com>
604
605         32-bit build fix: Removed unused declaration.
606
607         * dfg/DFGJITCodeGenerator32_64.cpp:
608         (JSC::DFG::JITCodeGenerator::emitCall):
609
610 2011-11-12  Geoffrey Garen  <ggaren@apple.com>
611
612         Standardized the JS calling convention
613         https://bugs.webkit.org/show_bug.cgi?id=72221
614         
615         Reviewed by Oliver Hunt.
616
617         This patch standardizes the calling convention so that the caller always
618         sets up the callee's CallFrame. Adjustments for call type, callee type,
619         argument count, etc. now always take place after that initial setup.
620         
621         This is a step toward reversing the argument order, but also has these
622         immediate benefits (measured on x64):
623         
624         (1) 1% benchmark speedup across the board.
625         
626         (2) 50% code size reduction in baseline JIT function calls.
627         
628         (3) 1.5x speedup for single-dispatch .apply forwarding.
629         
630         (4) 1.1x speedup for multi-dispatch .apply forwarding.
631
632         This change affected the baseline JIT most, since the baseline JIT had
633         lots of ad hoc calling conventions for different caller / callee types.
634
635         * assembler/MacroAssemblerX86_64.h:
636         (JSC::MacroAssemblerX86_64::branchPtr):
637         (JSC::MacroAssemblerX86_64::branchAddPtr): Optimize compare to 0 into
638         a test, like other assemblers do. (I added some compares to 0, and didn't
639         want them to be slow.)
640
641         * bytecode/CodeBlock.cpp:
642         (JSC::CodeBlock::dump): Merged op_load_varargs into op_call_varargs so
643         op_call_varargs could share code generation with other forms of op_call.
644         This is also a small optimization, since op_*varargs no longer have to
645         pass arguments to each other through the register file.
646
647         (JSC::CallLinkInfo::unlink):
648         * bytecode/CodeBlock.h: Added a new call type: CallVarargs. This allows
649         us to link functions called through .apply syntax. We need to distinguish
650         CallVarargs from Call because CallVarargs changes its argument count
651         on each inovcation, so we must always link to the argument count checking
652         version of the callee.
653
654         * bytecode/Opcode.h:
655         * bytecompiler/BytecodeGenerator.cpp:
656         (JSC::BytecodeGenerator::emitCallVarargs):
657         * bytecompiler/BytecodeGenerator.h: Merged op_load_varargs into op_call_varargs.
658
659         * bytecompiler/NodesCodegen.cpp:
660         (JSC::ApplyFunctionCallDotNode::emitBytecode): Ditto. Also, simplified
661         some of this bytecode generation to remove redundant copies.
662
663         * dfg/DFGJITCodeGenerator32_64.cpp:
664         (JSC::DFG::JITCodeGenerator::emitCall):
665         * dfg/DFGJITCodeGenerator64.cpp:
666         (JSC::DFG::JITCodeGenerator::emitCall): Added a new call type: CallVarargs.
667         DFG doesn't support this type, but its code needs to change slightly
668         to accomodate a 3-state variable.
669
670         Stopped passing the argument count in regT1 because this is non-standard.
671         (The argument count goes in the CallFrame. This trades speed on the slow
672         path for speed and code size on the fast path, and simplicity on all paths.
673         A good trade, in my opinion.)
674
675         * dfg/DFGJITCompiler.cpp:
676         (JSC::DFG::JITCompiler::compileEntry):
677         (JSC::DFG::JITCompiler::link):
678         (JSC::DFG::JITCompiler::compile):
679         (JSC::DFG::JITCompiler::compileFunction): Tweaked code to make CallFrame
680         setup more obvious when single-stepping. Also, updated for argument count
681         not being in regT1.
682
683         * dfg/DFGJITCompiler.h:
684         (JSC::DFG::JITCompiler::addJSCall):
685         (JSC::DFG::JITCompiler::JSCallRecord::JSCallRecord): Added a new call
686         type: CallVarargs.
687
688         * dfg/DFGOperations.cpp: Do finish CallFrame setup in one place before
689         doing anything else. Don't check for stack overflow because we have no callee
690         registers, and our caller has already checked for its own registers.
691
692         * dfg/DFGRepatch.cpp:
693         (JSC::DFG::dfgLinkFor): We can link to our callee even if our argument
694         count doesn't match -- we just need to link to the argument count checking
695         version.
696
697         * interpreter/CallFrameClosure.h:
698         (JSC::CallFrameClosure::setArgument): BUG FIX: When supplying too many
699         arguments from C++, we need to supply a full copy of the arguments prior
700         to the subset copy that matches our callee's argument count. (That is what
701         the standard calling convention would have produced in JS.) I would have
702         split this into its own patch, but I couldn't find a way to get the JIT
703         to fail a regression test in this area without my patch applied.
704
705         * interpreter/Interpreter.cpp: Let the true code bomb begin!
706
707         (JSC::eval): Fixed up this helper function to operate on eval()'s CallFrame,
708         and not eval()'s caller frame. We no longer leave the CallFrame pointing
709         to eval()'s caller during a call to eval(), since that is not standard.
710
711         (JSC::loadVarargs): Factored out a shared helper function for use by JIT
712         and interpreter because half the code means one quarter the bugs -- in my
713         programming, at least.
714
715         (JSC::Interpreter::execute): Removed a now-unused way to invoke eval.
716         
717         (JSC::Interpreter::privateExecute): Removed an invalid ASSERT following
718         putDirect, because it got in the way of my testing. (When putting a
719         function, the cached base of a PutPropertySlot can be 0 to signify "do
720         not optimize".)
721         
722         op_call_eval: Updated for new, standard eval calling convention.
723         
724         op_load_varargs: Merged op_load_varargs into op_call_varargs.
725
726         op_call_varags: Updated for new, standard eval calling convention. Don't
727         check for stack overflow because the loadVarargs helper function already
728         checked.
729
730         * interpreter/Interpreter.h:
731         (JSC::Interpreter::execute): Headers are fun and educational!
732
733         * interpreter/RegisterFile.cpp:
734         (JSC::RegisterFile::growSlowCase):
735         * interpreter/RegisterFile.h:
736         (JSC::RegisterFile::grow): Factored out the slow case into a slow
737         case because it was cramping the style of my fast case.
738
739         * jit/JIT.cpp:
740         (JSC::JIT::privateCompile): Moved initialization of
741         RegisterFile::CodeBlock to make it more obvious when debugging. Removed
742         assumption that argument count is in regT1, as above. Removed call to
743         restoreArgumentReference() because the JITStubCall abstraction does this for us.
744
745         (JSC::JIT::linkFor): Link even if we miss on argument count, as above.
746
747         * jit/JIT.h:
748         * jit/JITCall32_64.cpp:
749         (JSC::JIT::emitSlow_op_call):
750         (JSC::JIT::emitSlow_op_call_eval):
751         (JSC::JIT::emitSlow_op_call_varargs):
752         (JSC::JIT::emitSlow_op_construct):
753         (JSC::JIT::emit_op_call_eval):
754         (JSC::JIT::emit_op_call_varargs): Share all function call code generation.
755         Don't count call_eval when accounting for linkable function calls because
756         eval doesn't link. (Its fast path is to perform the eval.)
757
758         (JSC::JIT::compileLoadVarargs): Ported this inline copying optimization
759         to our new calling convention. The key to this optimization is the
760         observation that, in a function that declares no arguments, if any
761         arguments are passed, they all end up right behind 'this'.
762
763         (JSC::JIT::compileCallEval):
764         (JSC::JIT::compileCallEvalSlowCase): Factored out eval for a little clarity.
765
766         (JSC::JIT::compileOpCall):
767         (JSC::JIT::compileOpCallSlowCase): If you are still with me, dear reader,
768         this is the whole point of my patch. The caller now unconditionally moves
769         the CallFrame forward and fills in the data it knows before taking any
770         branches to deal with weird caller/callee pairs.
771         
772         This also means that there is almost no slow path for calls -- it all
773         gets folded into the shared virtual call stub. The only things remaining
774         in the slow path are the rare case counter and a call to the stub.
775
776         * jit/JITOpcodes32_64.cpp:
777         (JSC::JIT::privateCompileCTIMachineTrampolines):
778         (JSC::JIT::privateCompileCTINativeCall): Updated for values being in
779         different registers or in memory, based on our new standard calling
780         convention.
781         
782         Added a shared path for calling out to CTI helper functions for non-JS
783         calls.
784
785         * jit/JITPropertyAccess32_64.cpp:
786         (JSC::JIT::emit_op_method_check): method_check emits its own code and
787         the following get_by_id's code, so it needs to add both when informing
788         result chaining of its result. This is important because the standard
789         calling convention can now take advantage of this chaining.
790
791         * jit/JITCall.cpp:
792         (JSC::JIT::compileLoadVarargs):
793         (JSC::JIT::compileCallEval):
794         (JSC::JIT::compileCallEvalSlowCase):
795         (JSC::JIT::compileOpCall):
796         (JSC::JIT::compileOpCallSlowCase):
797         * jit/JITOpcodes.cpp:
798         (JSC::JIT::privateCompileCTIMachineTrampolines):
799         (JSC::JIT::emit_op_call_eval):
800         (JSC::JIT::emit_op_call_varargs):
801         (JSC::JIT::emitSlow_op_call):
802         (JSC::JIT::emitSlow_op_call_eval):
803         (JSC::JIT::emitSlow_op_call_varargs):
804         (JSC::JIT::emitSlow_op_construct): Observe, as I write all of my code a
805         second time, now with 64 bits.
806
807         * jit/JITStubs.cpp:
808         (JSC::throwExceptionFromOpCall):
809         (JSC::jitCompileFor):
810         (JSC::arityCheckFor):
811         (JSC::lazyLinkFor): A lot of mechanical changes here for one purpose:
812         Exceptions thrown in the middle of a function call now use a shared helper
813         function (throwExceptionFromOpCall). This function understands that the
814         CallFrame currently points to the callEE, and the exception must be
815         thrown by the callER. (The old calling convention would often still have
816         the CallFrame pointing at the callER at the point of an exception. That
817         is not the way of our new, standard calling convention.)
818
819         (JSC::op_call_eval): Finish standard CallFrame setup before calling 
820         our eval helper function, which now depends on that setup.
821
822         * runtime/Arguments.h:
823         (JSC::Arguments::length): Renamed numProvidedArguments() to length()
824         because that's what other objects call it, and the difference made our
825         new loadVarargs helper function hard to read.
826
827         * runtime/Executable.cpp:
828         (JSC::FunctionExecutable::compileForCallInternal):
829         (JSC::FunctionExecutable::compileForConstructInternal): Interpreter build
830         fixes.
831
832         * runtime/FunctionPrototype.cpp:
833         (JSC::functionProtoFuncApply): Honor Arguments::MaxArguments even when
834         the .apply call_varargs optimization fails. (This bug appears on layout
835         tests when you disable the optimization.)
836
837 2011-11-11  Jer Noble  <jer.noble@apple.com>
838
839         Implement MediaController.
840         https://bugs.webkit.org/show_bug.cgi?id=71408
841
842         Reviewed by Eric Carlson.
843
844         Change the definition of WTF_USE_COREAUDIO to exclude Windows completely, as 
845         CoreAudioClock.h is not available there.
846
847         * wtf/Platform.h:
848
849 2011-11-14  Patrick Gansterer  <paroga@webkit.org>
850
851         [WIN] Remove dependency on pthread from FastMalloc
852         https://bugs.webkit.org/show_bug.cgi?id=72098
853
854         Reviewed by Adam Roben.
855
856         All pthread calls are already ported to native Windows calls.
857         Use the native version for all OS(WINDOWS) to remove the
858         runtime dependency on the pthread dll.
859
860         * wtf/FastMalloc.cpp:
861
862 2011-11-14  Simon Hausmann  <simon.hausmann@nokia.com>
863
864         [Qt] Replace use of QApplication with QGuiApplication.
865
866         Reviewed by Tor Arne Vestbø.
867
868         * wtf/qt/compat/qguiapplication.h:
869         (QGuiApplication::styleHints): Introduce styleHints wrapper hack.
870
871 2011-11-14  Carlos Garcia Campos  <cgarcia@igalia.com>
872
873         Unreviewed. Fix make distcheck build.
874
875         * GNUmakefile.list.am: Add missing files.
876
877 2011-11-11  Yury Semikhatsky  <yurys@chromium.org>
878
879         Web Inspector: function remote objetct should provide access to function position in the script
880         https://bugs.webkit.org/show_bug.cgi?id=71808
881
882         Exposed accessor for function source code.
883
884         Reviewed by Pavel Feldman.
885
886         * JavaScriptCore.exp:
887         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
888         * runtime/JSFunction.cpp:
889         (JSC::JSFunction::sourceCode):
890         * runtime/JSFunction.h:
891
892 2011-11-13  Yuqiang Xian  <yuqiang.xian@intel.com>
893
894         Fix silent spilling/filling GPRs in DFG 32_64
895         https://bugs.webkit.org/show_bug.cgi?id=72201
896
897         Reviewed by Gavin Barraclough.
898
899         Current silentSpillGPR/silentFillGPR may not work as expected for some
900         cases in 32_64. If there's a JSValue which was retained by two GPRs,
901         we may end up failing to spill/fill some GPRs or redundantly
902         spilling/filling some GPRs. For example, if we tend to exclude "eax"
903         from spilling while a JSValue is retained by both "eax" and "edx",
904         then "edx" won't be spilled as well (wrong). And if another JSValue is
905         retained by "ecx" and "ebx", both "ecx" and "ebx" will be spilled
906         twice. The similar problem applies to silentFillGPR.
907         The fix is to make silentSpillGPR/silentFillGPR more straightforward,
908         i.e., spilling/filling based on the GPR instead of the virtual
909         register. FPR spilling/filling is also modified accordingly to make it
910         consistent with GPR spilling/filling.
911
912         * dfg/DFGJITCodeGenerator.h:
913         (JSC::DFG::JITCodeGenerator::silentSpillGPR):
914         (JSC::DFG::JITCodeGenerator::silentSpillFPR):
915         (JSC::DFG::JITCodeGenerator::silentFillGPR):
916         (JSC::DFG::JITCodeGenerator::silentFillFPR):
917         (JSC::DFG::JITCodeGenerator::silentSpillAllRegisters):
918         (JSC::DFG::JITCodeGenerator::silentFillAllRegisters):
919
920 2011-11-12  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
921
922         [Qt][Symbian] Remove support for WINSCW compiler
923         https://bugs.webkit.org/show_bug.cgi?id=70178
924
925         Reviewed by Chang Shu.
926
927         * API/JSStringRef.h:
928         * create_hash_table: Revert r45553.
929         * runtime/JSGlobalData.cpp: Revert r45553.
930         * runtime/LiteralParser.cpp: Remove WINSCW comment.
931         (JSC::LiteralParser::Lexer::lexString):
932         * runtime/Lookup.h: Revert r45553.
933         * runtime/Structure.h: Revert r48461.
934         * wtf/Alignment.h:
935         * wtf/Assertions.h: Revert r52337.
936         * wtf/Compiler.h:
937         * wtf/ListRefPtr.h: Revert r48988.
938         (WTF::ListRefPtr::~ListRefPtr):
939         * wtf/OwnArrayPtr.h: Revert r45911.
940         (WTF::OwnArrayPtr::operator UnspecifiedBoolType):
941         * wtf/PassOwnArrayPtr.h:
942         (WTF::PassOwnArrayPtr::operator UnspecifiedBoolType):
943         * wtf/PassRefPtr.h:
944         * wtf/StaticConstructors.h:
945         * wtf/unicode/qt4/UnicodeQt4.h:
946
947 2011-11-12  Patrick Gansterer  <paroga@webkit.org>
948
949         Unreviewed. Add ENABLE(DFG_JIT) around DFGCorrectableJumpPoint code.
950
951         * dfg/DFGCorrectableJumpPoint.cpp:
952         * dfg/DFGCorrectableJumpPoint.h:
953
954 2011-11-12  Patrick Gansterer  <paroga@webkit.org>
955
956         [CMake] Move list of DFG source files into correct file
957         https://bugs.webkit.org/show_bug.cgi?id=72212
958
959         Reviewed by Daniel Bates.
960
961         The DFG files are platform independent. So move them from
962         the EFL specific file into the general CMakeLists.txt.
963
964         * CMakeLists.txt:
965         * PlatformEfl.cmake:
966
967 2011-11-12  Patrick Gansterer  <paroga@webkit.org>
968
969         Fix "unused variable" warning in JSLock
970         https://bugs.webkit.org/show_bug.cgi?id=72213
971
972         Reviewed by Anders Carlsson.
973
974         Use ASSERT_UNUSED() instead of ASSERT() to make sure
975         that the variable is also used in the release build.
976
977         * runtime/JSLock.cpp:
978         (JSC::JSLock::lock):
979         (JSC::JSLock::unlock):
980
981 2011-11-11  Gavin Barraclough  <barraclough@apple.com>
982
983         Update iOS compiler version.
984
985         Reviewed by David Kilzer.
986
987         * Configurations/CompilerVersion.xcconfig:
988             - Update compiler version.
989
990 2011-11-11  Gavin Barraclough  <barraclough@apple.com>
991
992         Update iOS port's configuration setting, particularly in Platform.h
993         https://bugs.webkit.org/show_bug.cgi?id=72187
994         
995         Reviewed by David Kilzer.
996
997         * interpreter/Interpreter.h:
998             - Lower the reentry depth.
999         * runtime/DatePrototype.cpp:
1000             - iOS also uses CF.
1001         * wtf/FastMalloc.cpp:
1002         (WTF::TCMalloc_PageHeap::IncrementalScavenge):
1003             - Update fastmalloc configuration for iOS.
1004         * wtf/OSAllocatorPosix.cpp:
1005         (WTF::OSAllocator::reserveAndCommit):
1006             - Added flag.
1007         * wtf/Platform.h:
1008             - Update platform configuration for iOS.
1009
1010 2011-11-11  David Kilzer  <ddkilzer@apple.com>
1011
1012         Only define BUILDING_ON_* and TARGETING_* macros when building for Mac OS X
1013         <http://webkit.org/b/72175>
1014
1015         Reviewed by Joseph Pecoraro.
1016
1017         * wtf/Platform.h: Move the definition of the BUILDING_ON_* and
1018         TARGETING_* macros to where the WTF_OS_MAC_OS_X macro is defined
1019         so that they're only defined on Mac OS X builds.  Also include
1020         Availability.h, which is needed on iOS builds.
1021
1022 2011-11-11  Darin Adler  <darin@apple.com>
1023
1024         Remove all releaseRef implementations except for RetainPtr
1025         https://bugs.webkit.org/show_bug.cgi?id=71423
1026
1027         Reviewed by Julien Chaffraix.
1028
1029         * API/JSRetainPtr.h: Removed releaseRef.
1030         * wtf/PassRefPtr.h: Removed releaseRef.
1031
1032 2011-11-11  Darin Adler  <darin@apple.com>
1033
1034         * JavaScriptCore.xcodeproj/project.pbxproj: Let a newer Xcode update this file.
1035         If an older Xcode downgrades this file and we have a risk of some kind of
1036         oscillating commit situation, please contact me so I know not to do this again.
1037
1038 2011-11-11  Mark Hahnenberg  <mhahnenberg@apple.com>
1039
1040         Add jsCast to replace static_cast
1041         https://bugs.webkit.org/show_bug.cgi?id=72071
1042
1043         Reviewed by Geoffrey Garen.
1044
1045         Added new jsCast and changed all of the static_cast sites in functions that 
1046         are in the MethodTable to use jsCast instead.
1047
1048         * API/JSCallbackFunction.cpp:
1049         (JSC::JSCallbackFunction::toStringCallback):
1050         (JSC::JSCallbackFunction::valueOfCallback):
1051         * API/JSCallbackObject.h:
1052         (JSC::JSCallbackObject::visitChildren):
1053         * API/JSCallbackObjectFunctions.h:
1054         (JSC::::className):
1055         (JSC::::getOwnPropertySlot):
1056         (JSC::::getOwnPropertyDescriptor):
1057         (JSC::::put):
1058         (JSC::::deleteProperty):
1059         (JSC::::deletePropertyByIndex):
1060         (JSC::::getConstructData):
1061         (JSC::::hasInstance):
1062         (JSC::::getCallData):
1063         (JSC::::getOwnPropertyNames):
1064         * debugger/DebuggerActivation.cpp:
1065         (JSC::DebuggerActivation::visitChildren):
1066         (JSC::DebuggerActivation::className):
1067         (JSC::DebuggerActivation::getOwnPropertySlot):
1068         (JSC::DebuggerActivation::put):
1069         (JSC::DebuggerActivation::putWithAttributes):
1070         (JSC::DebuggerActivation::deleteProperty):
1071         (JSC::DebuggerActivation::getOwnPropertyNames):
1072         (JSC::DebuggerActivation::getOwnPropertyDescriptor):
1073         (JSC::DebuggerActivation::defineGetter):
1074         (JSC::DebuggerActivation::defineSetter):
1075         * runtime/Arguments.cpp:
1076         (JSC::Arguments::visitChildren):
1077         (JSC::Arguments::getOwnPropertySlotByIndex):
1078         (JSC::Arguments::getOwnPropertySlot):
1079         (JSC::Arguments::getOwnPropertyDescriptor):
1080         (JSC::Arguments::getOwnPropertyNames):
1081         (JSC::Arguments::putByIndex):
1082         (JSC::Arguments::put):
1083         (JSC::Arguments::deletePropertyByIndex):
1084         (JSC::Arguments::deleteProperty):
1085         * runtime/ArrayConstructor.cpp:
1086         (JSC::ArrayConstructor::getOwnPropertySlot):
1087         (JSC::ArrayConstructor::getOwnPropertyDescriptor):
1088         * runtime/ArrayPrototype.cpp:
1089         (JSC::ArrayPrototype::getOwnPropertySlot):
1090         (JSC::ArrayPrototype::getOwnPropertyDescriptor):
1091         * runtime/BooleanPrototype.cpp:
1092         (JSC::BooleanPrototype::getOwnPropertySlot):
1093         (JSC::BooleanPrototype::getOwnPropertyDescriptor):
1094         * runtime/DateConstructor.cpp:
1095         (JSC::DateConstructor::getOwnPropertySlot):
1096         (JSC::DateConstructor::getOwnPropertyDescriptor):
1097         * runtime/DatePrototype.cpp:
1098         (JSC::DatePrototype::getOwnPropertySlot):
1099         (JSC::DatePrototype::getOwnPropertyDescriptor):
1100         * runtime/ErrorPrototype.cpp:
1101         (JSC::ErrorPrototype::getOwnPropertySlot):
1102         (JSC::ErrorPrototype::getOwnPropertyDescriptor):
1103         * runtime/Executable.cpp:
1104         (JSC::ExecutableBase::clearCode):
1105         (JSC::EvalExecutable::visitChildren):
1106         (JSC::ProgramExecutable::visitChildren):
1107         (JSC::FunctionExecutable::visitChildren):
1108         * runtime/GetterSetter.cpp:
1109         (JSC::GetterSetter::visitChildren):
1110         * runtime/JSActivation.cpp:
1111         (JSC::JSActivation::visitChildren):
1112         (JSC::JSActivation::getOwnPropertyNames):
1113         (JSC::JSActivation::getOwnPropertySlot):
1114         (JSC::JSActivation::put):
1115         (JSC::JSActivation::putWithAttributes):
1116         * runtime/JSArray.cpp:
1117         (JSC::JSArray::getOwnPropertySlotByIndex):
1118         (JSC::JSArray::getOwnPropertySlot):
1119         (JSC::JSArray::getOwnPropertyDescriptor):
1120         (JSC::JSArray::put):
1121         (JSC::JSArray::putByIndex):
1122         (JSC::JSArray::deleteProperty):
1123         (JSC::JSArray::deletePropertyByIndex):
1124         (JSC::JSArray::getOwnPropertyNames):
1125         (JSC::JSArray::visitChildren):
1126         * runtime/JSBoundFunction.cpp:
1127         (JSC::JSBoundFunction::hasInstance):
1128         (JSC::JSBoundFunction::visitChildren):
1129         * runtime/JSByteArray.cpp:
1130         (JSC::JSByteArray::getOwnPropertySlot):
1131         (JSC::JSByteArray::getOwnPropertyDescriptor):
1132         (JSC::JSByteArray::getOwnPropertySlotByIndex):
1133         (JSC::JSByteArray::put):
1134         (JSC::JSByteArray::putByIndex):
1135         (JSC::JSByteArray::getOwnPropertyNames):
1136         * runtime/JSCell.h:
1137         (JSC::JSCell::visitChildren):
1138         (JSC::jsCast):
1139         * runtime/JSFunction.cpp:
1140         (JSC::JSFunction::visitChildren):
1141         (JSC::JSFunction::getCallData):
1142         (JSC::JSFunction::getOwnPropertySlot):
1143         (JSC::JSFunction::getOwnPropertyDescriptor):
1144         (JSC::JSFunction::getOwnPropertyNames):
1145         (JSC::JSFunction::put):
1146         (JSC::JSFunction::deleteProperty):
1147         (JSC::JSFunction::getConstructData):
1148         * runtime/JSGlobalData.cpp:
1149         (JSC::StackPreservingRecompiler::operator()):
1150         * runtime/JSGlobalObject.cpp:
1151         (JSC::JSGlobalObject::put):
1152         (JSC::JSGlobalObject::putWithAttributes):
1153         (JSC::JSGlobalObject::defineGetter):
1154         (JSC::JSGlobalObject::defineSetter):
1155         (JSC::JSGlobalObject::visitChildren):
1156         (JSC::JSGlobalObject::getOwnPropertySlot):
1157         (JSC::JSGlobalObject::getOwnPropertyDescriptor):
1158         (JSC::JSGlobalObject::clearRareData):
1159         * runtime/JSGlobalThis.cpp:
1160         (JSC::JSGlobalThis::visitChildren):
1161         * runtime/JSONObject.cpp:
1162         (JSC::JSONObject::getOwnPropertySlot):
1163         (JSC::JSONObject::getOwnPropertyDescriptor):
1164         * runtime/JSObject.cpp:
1165         (JSC::JSObject::finalize):
1166         (JSC::JSObject::visitChildren):
1167         (JSC::JSObject::getOwnPropertySlotByIndex):
1168         (JSC::JSObject::put):
1169         (JSC::JSObject::putByIndex):
1170         (JSC::JSObject::deleteProperty):
1171         (JSC::JSObject::deletePropertyByIndex):
1172         * runtime/JSObject.h:
1173         (JSC::JSObject::getOwnPropertySlot):
1174         * runtime/JSPropertyNameIterator.cpp:
1175         (JSC::JSPropertyNameIterator::visitChildren):
1176         * runtime/JSStaticScopeObject.cpp:
1177         (JSC::JSStaticScopeObject::visitChildren):
1178         (JSC::JSStaticScopeObject::put):
1179         (JSC::JSStaticScopeObject::putWithAttributes):
1180         (JSC::JSStaticScopeObject::getOwnPropertySlot):
1181         * runtime/JSString.cpp:
1182         (JSC::JSString::visitChildren):
1183         (JSC::JSString::toThisObject):
1184         (JSC::JSString::getOwnPropertySlot):
1185         (JSC::JSString::getOwnPropertySlotByIndex):
1186         * runtime/JSVariableObject.cpp:
1187         (JSC::JSVariableObject::deleteProperty):
1188         (JSC::JSVariableObject::getOwnPropertyNames):
1189         * runtime/JSWrapperObject.cpp:
1190         (JSC::JSWrapperObject::visitChildren):
1191         * runtime/MathObject.cpp:
1192         (JSC::MathObject::getOwnPropertySlot):
1193         (JSC::MathObject::getOwnPropertyDescriptor):
1194         * runtime/NativeErrorConstructor.cpp:
1195         (JSC::NativeErrorConstructor::visitChildren):
1196         * runtime/NumberConstructor.cpp:
1197         (JSC::NumberConstructor::getOwnPropertySlot):
1198         (JSC::NumberConstructor::getOwnPropertyDescriptor):
1199         * runtime/NumberPrototype.cpp:
1200         (JSC::NumberPrototype::getOwnPropertySlot):
1201         (JSC::NumberPrototype::getOwnPropertyDescriptor):
1202         * runtime/ObjectConstructor.cpp:
1203         (JSC::ObjectConstructor::getOwnPropertySlot):
1204         (JSC::ObjectConstructor::getOwnPropertyDescriptor):
1205         * runtime/ObjectPrototype.cpp:
1206         (JSC::ObjectPrototype::put):
1207         (JSC::ObjectPrototype::getOwnPropertySlotByIndex):
1208         (JSC::ObjectPrototype::getOwnPropertySlot):
1209         (JSC::ObjectPrototype::getOwnPropertyDescriptor):
1210         * runtime/RegExpConstructor.cpp:
1211         (JSC::RegExpConstructor::getOwnPropertySlot):
1212         (JSC::RegExpConstructor::getOwnPropertyDescriptor):
1213         (JSC::RegExpConstructor::put):
1214         * runtime/RegExpMatchesArray.h:
1215         (JSC::RegExpMatchesArray::getOwnPropertySlot):
1216         (JSC::RegExpMatchesArray::getOwnPropertySlotByIndex):
1217         (JSC::RegExpMatchesArray::getOwnPropertyDescriptor):
1218         (JSC::RegExpMatchesArray::put):
1219         (JSC::RegExpMatchesArray::putByIndex):
1220         (JSC::RegExpMatchesArray::deleteProperty):
1221         (JSC::RegExpMatchesArray::deletePropertyByIndex):
1222         (JSC::RegExpMatchesArray::getOwnPropertyNames):
1223         * runtime/RegExpObject.cpp:
1224         (JSC::RegExpObject::visitChildren):
1225         (JSC::RegExpObject::getOwnPropertySlot):
1226         (JSC::RegExpObject::getOwnPropertyDescriptor):
1227         (JSC::RegExpObject::put):
1228         * runtime/RegExpPrototype.cpp:
1229         (JSC::RegExpPrototype::getOwnPropertySlot):
1230         (JSC::RegExpPrototype::getOwnPropertyDescriptor):
1231         * runtime/ScopeChain.cpp:
1232         (JSC::ScopeChainNode::visitChildren):
1233         * runtime/StringConstructor.cpp:
1234         (JSC::StringConstructor::getOwnPropertySlot):
1235         (JSC::StringConstructor::getOwnPropertyDescriptor):
1236         * runtime/StringObject.cpp:
1237         (JSC::StringObject::getOwnPropertySlot):
1238         (JSC::StringObject::getOwnPropertySlotByIndex):
1239         (JSC::StringObject::getOwnPropertyDescriptor):
1240         (JSC::StringObject::deleteProperty):
1241         (JSC::StringObject::getOwnPropertyNames):
1242         * runtime/StringPrototype.cpp:
1243         (JSC::StringPrototype::getOwnPropertySlot):
1244         (JSC::StringPrototype::getOwnPropertyDescriptor):
1245         * runtime/Structure.cpp:
1246         (JSC::Structure::visitChildren):
1247         * runtime/StructureChain.cpp:
1248         (JSC::StructureChain::visitChildren):
1249
1250 2011-11-11  Gavin Barraclough  <barraclough@apple.com>
1251
1252         Enable DFG JIT for ARMv7/iOS.
1253
1254         Rubber stamped by Oliver Hunt.
1255
1256         * wtf/Platform.h:
1257             - enable DFG JIT for ARMv7/iOS.
1258
1259 2011-11-11  Mark Hahnenberg  <mhahnenberg@apple.com>
1260
1261         De-virtualize supportsProfiling, supportsRichSourceInfo, shouldInterruptScript in JSGlobalObject
1262         https://bugs.webkit.org/show_bug.cgi?id=72035
1263
1264         Reviewed by Geoffrey Garen.
1265
1266         De-virtualized the methods through the use of a new method table just for JSGlobalObject and subclasses.
1267
1268         * JavaScriptCore.exp:
1269         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1270         * bytecompiler/BytecodeGenerator.cpp: Changed call sites to use the new GlobalObjectMethodTable.
1271         (JSC::BytecodeGenerator::BytecodeGenerator):
1272         * interpreter/Interpreter.cpp: Ditto.
1273         (JSC::Interpreter::execute):
1274         * runtime/JSGlobalObject.cpp: Added a static const GlobalObjectMethodTable with the correct function pointers.
1275         * runtime/JSGlobalObject.h: Added a field in JSGlobalObject to keep track of the current method table.
1276         (JSC::JSGlobalObject::JSGlobalObject):
1277         (JSC::JSGlobalObject::globalObjectMethodTable): The new struct to contain the function pointers.
1278         (JSC::JSGlobalObject::supportsProfiling): Made static to put in the method table.
1279         (JSC::JSGlobalObject::supportsRichSourceInfo): Ditto.
1280         (JSC::JSGlobalObject::shouldInterruptScript): Ditto.
1281         * runtime/TimeoutChecker.cpp: Changed call sites to use the new GlobalObjectMethodTable for lookup.
1282         (JSC::TimeoutChecker::didTimeOut):
1283
1284 2011-11-11  Mark Hahnenberg  <mhahnenberg@apple.com>
1285
1286         De-virtualize JSGlobalObject::allowsAccessFrom
1287         https://bugs.webkit.org/show_bug.cgi?id=71969
1288
1289         Reviewed by Darin Adler.
1290
1291         * runtime/JSGlobalObject.h: Removed allowsAccessFrom from JSGlobalObject since it is exclusive to 
1292         JSDOMWindowBase and WebScriptObject.
1293
1294 2011-11-11  Sheriff Bot  <webkit.review.bot@gmail.com>
1295
1296         Unreviewed, rolling out r99950.
1297         http://trac.webkit.org/changeset/99950
1298         https://bugs.webkit.org/show_bug.cgi?id=72117
1299
1300         "Landed wrong patch by mistake" (Requested by yurys on
1301         #webkit).
1302
1303         * JavaScriptCore.exp:
1304         * runtime/JSFunction.cpp:
1305         * runtime/JSFunction.h:
1306
1307 2011-11-11  Patrick Gansterer  <paroga@webkit.org>
1308
1309         Unreviewed. Build fix for !ENABLE(JIT) after r99898.
1310
1311         * bytecode/CodeBlock.cpp:
1312         (JSC::CodeBlock::CodeBlock):
1313
1314 2011-11-10  Dan Bernstein  <mitz@apple.com>
1315
1316         Disabling assertions breaks the debug build
1317         https://bugs.webkit.org/show_bug.cgi?id=72091
1318
1319         Reviewed by Geoff Garen.
1320
1321         * dfg/DFGNode.h: Made hasIdentifier() available when assertions are
1322         disabled. It is used in Graph::dump().
1323         * runtime/JSObject.cpp:
1324         (JSC::JSObject::visitChildren): Update m_isCheckingForDefaultMarkViolation
1325         only if assertions are enabled.
1326         * wtf/Deque.h:
1327         (WTF::::checkIndexValidity): Changed ASSERT to ASSERT_UNUSED.
1328         * wtf/ThreadRestrictionVerifier.h:
1329         (WTF::ThreadRestrictionVerifier::setShared): Guarded the definition of
1330         a local variable that is only used in an assertion.
1331
1332 2011-11-10  Filip Pizlo  <fpizlo@apple.com>
1333
1334         JSString forgets to clear m_fibers when resolving ropes
1335         https://bugs.webkit.org/show_bug.cgi?id=72089
1336
1337         Reviewed by Geoff Garen.
1338
1339         * runtime/JSString.cpp:
1340         (JSC::JSString::resolveRopeSlowCase):
1341
1342 2011-11-09  Filip Pizlo  <fpizlo@apple.com>
1343
1344         DFG byte array support sometimes clamps values incorrectly
1345         https://bugs.webkit.org/show_bug.cgi?id=71975
1346
1347         Reviewed by Oliver Hunt.
1348
1349         * dfg/DFGSpeculativeJIT.cpp:
1350         (JSC::DFG::SpeculativeJIT::compilePutByValForByteArray):
1351
1352 2011-11-10  Filip Pizlo  <fpizlo@apple.com>
1353
1354         ValueProfile/PredictedType contains dead code, and doesn't recognize functions
1355         https://bugs.webkit.org/show_bug.cgi?id=72065
1356
1357         Reviewed by Gavin Barraclough and Geoff Garen.
1358         
1359         Added PredictFunction support, and did some cleaning up along the way.
1360         ValueProfile no longer has statistics machinery, because we never used
1361         it. Rearranged some bits in PredictedType to more easily make room for
1362         one more object type. Changed some debug code to use more consistent
1363         conventions (ByteArray becomes Bytearray so that if we ever have a
1364         "Byte" prediction we don't get confused between a prediction that is
1365         the union of Byte and Array and a prediction that indicates precisely
1366         a ByteArray).
1367
1368         * bytecode/PredictedType.cpp:
1369         (JSC::predictionToString):
1370         (JSC::predictionFromClassInfo):
1371         * bytecode/PredictedType.h:
1372         (JSC::isFunctionPrediction):
1373         * bytecode/ValueProfile.cpp:
1374         * bytecode/ValueProfile.h:
1375         (JSC::ValueProfile::dump):
1376         * dfg/DFGAbstractState.cpp:
1377         (JSC::DFG::AbstractState::execute):
1378         * dfg/DFGPropagator.cpp:
1379         (JSC::DFG::Propagator::propagateNodePredictions):
1380
1381 2011-11-10  David Kilzer  <ddkilzer@apple.com>
1382
1383         <http://webkit.org/b/72049> Specify testapi.js install path using JAVASCRIPTCORE_FRAMEWORKS_DIR
1384
1385         Reviewed by Joseph Pecoraro.
1386
1387         * JavaScriptCore.xcodeproj/project.pbxproj: The testapi.js
1388         script should use JAVASCRIPTCORE_FRAMEWORKS_DIR in its dstPath
1389         for installation.  Also removed "Versions/A/" from the path
1390         since this is unneeded due the default symlinks present in the
1391         framework.
1392
1393 2011-11-10  Gavin Barraclough  <barraclough@apple.com>
1394
1395         Add ARMv7 support to the DFG JIT
1396         https://bugs.webkit.org/show_bug.cgi?id=72061
1397
1398         Reviewed by Geoff Garen.
1399
1400         * dfg/DFGAssemblyHelpers.h:
1401         (JSC::DFG::AssemblyHelpers::preserveReturnAddressAfterCall):
1402         (JSC::DFG::AssemblyHelpers::restoreReturnAddressBeforeReturn):
1403         (JSC::DFG::AssemblyHelpers::emitPutImmediateToCallFrameHeader):
1404         (JSC::DFG::AssemblyHelpers::boxDouble):
1405         (JSC::DFG::AssemblyHelpers::unboxDouble):
1406             - Add CPU(ARM) copies of these functions.
1407         * dfg/DFGJITCodeGenerator.h:
1408         (JSC::DFG::JITCodeGenerator::spill):
1409             - Fix matching of '}' re #if blocks, makes some tools happy.
1410         (JSC::DFG::JITCodeGenerator::setupArguments):
1411         (JSC::DFG::JITCodeGenerator::setupArgumentsWithExecState):
1412         (JSC::DFG::JITCodeGenerator::appendCallWithExceptionCheckSetResult):
1413         (JSC::DFG::JITCodeGenerator::appendCallSetResult):
1414             - Add CPU(ARM) / 4 argument register copies of these functions.
1415         * dfg/DFGJITCodeGenerator32_64.cpp:
1416         (JSC::DFG::JITCodeGenerator::nonSpeculativeValueToInt32):
1417             - Should use callOperation to plant a call to a DFG_OPERATION.
1418         (JSC::DFG::JITCodeGenerator::cachedGetById):
1419         (JSC::DFG::JITCodeGenerator::cachedPutById):
1420             - These methods need to plant a relinkable jump; we currently do so
1421               using beginUninterruptedSequence() / endUninterruptedSequence().
1422         * dfg/DFGJITCodeGenerator64.cpp:
1423         (JSC::DFG::JITCodeGenerator::nonSpeculativeValueToInt32):
1424             - Should use callOperation to plant a call to a DFG_OPERATION.
1425         * dfg/DFGJITCompiler.cpp:
1426         (JSC::DFG::JITCompiler::linkOSRExits):
1427             - This method needs to plant a relinkable jump; we currently do so
1428               using beginUninterruptedSequence() / endUninterruptedSequence().
1429         (JSC::DFG::JITCompiler::compileBody):
1430             - Add abstraction to retrieve the pc after a call.
1431         * dfg/DFGOSRExitCompiler.cpp:
1432             - Fix a bug - CodeLocationLabel needs a data address rather than an
1433               executable one, but can just take a MacroAssemblerCodePtr instead!
1434         * dfg/DFGOperations.cpp:
1435         * dfg/DFGSpeculativeJIT.cpp:
1436         (JSC::DFG::compileClampDoubleToByte):
1437             - Add FIXME comment to come back to! - bug#72054.
1438         * dfg/DFGSpeculativeJIT.h:
1439         (JSC::DFG::SpeculativeJIT::speculationCheck):
1440             - Add missing method (ooops, required by bug#72047)
1441         * dfg/DFGSpeculativeJIT32_64.cpp:
1442             - Need to wrap fmod on ARMv7.
1443
1444
1445 2011-11-10  Filip Pizlo  <fpizlo@apple.com>
1446
1447         DFG should not reparse code that was just parsed
1448         https://bugs.webkit.org/show_bug.cgi?id=71977
1449
1450         Reviewed by Geoff Garen.
1451         
1452         The instruction stream of a code block is now kept around until
1453         the next GC. When doing either an optimizing compilation of an
1454         executable, or inlining of an executable, we now try to find the
1455         already preexisting bytecode. If we find it, we don't have to parse.
1456         If we don't find it, we parse as before. Inlining takes the extra
1457         step of caching code blocks, so if the same executable gets inlined
1458         multiple times into the same caller, then we parse it at most once
1459         even if prior to inlining that executable did not have any code
1460         blocks with an instruction stream.
1461         
1462         Also fixed a silly bug where the strict mode for various operations
1463         was being determined by looking at the machine code block rather
1464         than the inlinee.
1465
1466         To enable the delete-on-next-GC policy, I introduced the notion
1467         of an ultra weak finalizer, which anyone can register during
1468         tracing. This is thread-safe (for parallel GC) and
1469         stop-the-world-safe (so calls to free() are postponed until the
1470         world is resumed). This required reusing some facilities previously
1471         created for WeakReferenceHarvester, so I created a common utility
1472         class. I also retweaked the handling of WeakReferenceHarvesters,
1473         since they should be executed during stop-the-world since in the
1474         future we may want to allow them to call drain().
1475         
1476         2% win on SunSpider. 2% win on V8, when run in my harness. Neutral
1477         elsewhere.
1478
1479         * JavaScriptCore.xcodeproj/project.pbxproj:
1480         * bytecode/CodeBlock.cpp:
1481         (JSC::CodeBlock::CodeBlock):
1482         (JSC::CodeBlock::visitAggregate):
1483         (JSC::CodeBlock::copyPostParseDataFrom):
1484         (JSC::CodeBlock::copyPostParseDataFromAlternative):
1485         (JSC::CodeBlock::finalizeUnconditionally):
1486         * bytecode/CodeBlock.h:
1487         (JSC::CodeBlock::canProduceCopyWithBytecode):
1488         (JSC::CodeBlock::discardBytecodeLater):
1489         (JSC::CodeBlock::handleBytecodeDiscardingOpportunity):
1490         (JSC::GlobalCodeBlock::GlobalCodeBlock):
1491         (JSC::ProgramCodeBlock::ProgramCodeBlock):
1492         (JSC::EvalCodeBlock::EvalCodeBlock):
1493         (JSC::FunctionCodeBlock::FunctionCodeBlock):
1494         (JSC::BytecodeDestructionBlocker::BytecodeDestructionBlocker):
1495         (JSC::BytecodeDestructionBlocker::~BytecodeDestructionBlocker):
1496         * dfg/DFGAssemblyHelpers.h:
1497         (JSC::DFG::AssemblyHelpers::strictModeFor):
1498         * dfg/DFGByteCodeCache.h: Added.
1499         (JSC::DFG::CodeBlockKey::CodeBlockKey):
1500         (JSC::DFG::CodeBlockKey::operator==):
1501         (JSC::DFG::CodeBlockKey::hash):
1502         (JSC::DFG::CodeBlockKey::executable):
1503         (JSC::DFG::CodeBlockKey::kind):
1504         (JSC::DFG::CodeBlockKey::isHashTableDeletedValue):
1505         (JSC::DFG::CodeBlockKeyHash::hash):
1506         (JSC::DFG::CodeBlockKeyHash::equal):
1507         (JSC::DFG::ByteCodeCache::ByteCodeCache):
1508         (JSC::DFG::ByteCodeCache::~ByteCodeCache):
1509         (JSC::DFG::ByteCodeCache::get):
1510         * dfg/DFGByteCodeParser.cpp:
1511         (JSC::DFG::ByteCodeParser::handleInlining):
1512         * dfg/DFGJITCodeGenerator32_64.cpp:
1513         (JSC::DFG::JITCodeGenerator::cachedPutById):
1514         * dfg/DFGJITCodeGenerator64.cpp:
1515         (JSC::DFG::JITCodeGenerator::cachedPutById):
1516         * dfg/DFGSpeculativeJIT64.cpp:
1517         (JSC::DFG::SpeculativeJIT::compile):
1518         * heap/Heap.cpp:
1519         (JSC::Heap::finalizeUnconditionally):
1520         (JSC::Heap::markRoots):
1521         (JSC::Heap::collect):
1522         * heap/Heap.h:
1523         * heap/ListableHandler.h: Added.
1524         (JSC::ListableHandler::ListableHandler):
1525         (JSC::ListableHandler::~ListableHandler):
1526         (JSC::ListableHandler::List::List):
1527         (JSC::ListableHandler::List::addNotThreadSafe):
1528         (JSC::ListableHandler::List::addThreadSafe):
1529         (JSC::ListableHandler::List::hasNext):
1530         (JSC::ListableHandler::List::removeNext):
1531         * heap/MarkStack.cpp:
1532         (JSC::MarkStackThreadSharedData::MarkStackThreadSharedData):
1533         (JSC::SlotVisitor::harvestWeakReferences):
1534         (JSC::SlotVisitor::finalizeUnconditionally):
1535         * heap/MarkStack.h:
1536         (JSC::MarkStack::addWeakReferenceHarvester):
1537         (JSC::MarkStack::addUnconditionalFinalizer):
1538         * heap/SlotVisitor.h:
1539         * heap/UnconditionalFinalizer.h: Added.
1540         (JSC::UnconditionalFinalizer::~UnconditionalFinalizer):
1541         * heap/WeakReferenceHarvester.h:
1542         (JSC::WeakReferenceHarvester::WeakReferenceHarvester):
1543         (JSC::WeakReferenceHarvester::~WeakReferenceHarvester):
1544         * runtime/Executable.cpp:
1545         (JSC::EvalExecutable::compileInternal):
1546         (JSC::ProgramExecutable::compileInternal):
1547         (JSC::FunctionExecutable::baselineCodeBlockFor):
1548         (JSC::FunctionExecutable::codeBlockWithBytecodeFor):
1549         (JSC::FunctionExecutable::produceCodeBlockFor):
1550         (JSC::FunctionExecutable::compileForCallInternal):
1551         (JSC::FunctionExecutable::compileForConstructInternal):
1552         * runtime/Executable.h:
1553         (JSC::FunctionExecutable::profiledCodeBlockFor):
1554
1555 2011-11-10  Gavin Barraclough  <barraclough@apple.com>
1556
1557         Add ARMv7 register info for the DFG JIT
1558         https://bugs.webkit.org/show_bug.cgi?id=72050
1559
1560         Reviewed by Geoff Garen.
1561
1562         * dfg/DFGFPRInfo.h:
1563         (JSC::DFG::FPRInfo::toRegister):
1564         (JSC::DFG::FPRInfo::toIndex):
1565         (JSC::DFG::FPRInfo::debugName):
1566         * dfg/DFGGPRInfo.h:
1567         (JSC::DFG::GPRInfo::toRegister):
1568         (JSC::DFG::GPRInfo::toIndex):
1569         (JSC::DFG::GPRInfo::debugName):
1570
1571 2011-11-10  Gavin Barraclough  <barraclough@apple.com>
1572
1573         #ifdef CPU(X86) specific div/mod code in DFGSpeculativeJIT32_64
1574         https://bugs.webkit.org/show_bug.cgi?id=72047
1575
1576         Reviewed by Geoff Garen.
1577
1578         We currently don't attempt to abstract divide through the macro assembler,
1579         due to these instructions commonly having specific requirements. This means
1580         there is architecture specific code in the JIT - #ifdef it, and provide a
1581         common implementation.
1582
1583         * dfg/DFGSpeculativeJIT32_64.cpp:
1584         (JSC::DFG::fmodAsDFGOperation):
1585         (JSC::DFG::SpeculativeJIT::compile):
1586
1587 2011-11-10  Gavin Barraclough  <barraclough@apple.com>
1588
1589         Add ENABLE_VALUE_PROFILER support for ARMv7
1590         https://bugs.webkit.org/show_bug.cgi?id=72043
1591
1592         Reviewed by Geoff Garen.
1593
1594         This requires us to make a bucketCounterRegister available; to do so we'll need to spill more registers on entry to JIT code.
1595
1596         * jit/JITArithmetic32_64.cpp:
1597         (JSC::JIT::emitSlow_op_mod):
1598             - cleanup location of UNUSED_PARAM
1599         * jit/JITStubs.cpp:
1600         (JSC::ctiTrampoline):
1601         (JSC::ctiVMThrowTrampoline):
1602         (JSC::ctiOpThrowNotCaught):
1603         (JSC::JITThunks::JITThunks):
1604         * jit/JITStubs.h:
1605             - Update JITStackFrame structure & asm code to spill more registers.
1606         * jit/JSInterfaceJIT.h:
1607             - Assign a bucketCounterRegister.
1608
1609 2011-11-10  Gavin Barraclough  <barraclough@apple.com>
1610
1611         Fix sampling counters on ARMv7, move add64 functionality to macro assembler
1612         https://bugs.webkit.org/show_bug.cgi?id=72040
1613
1614         Reviewed by Geoff Garen.
1615
1616         The ability to add an integer to a uint64_t in memory is poorly copied in
1617         multiple places & ifdef'ed on architecture, addWithCarry32 is also a badly
1618         designed interface since add32 is not required to set flags (we have no
1619         concept of flags in the macro assembler interface).
1620
1621         * assembler/MacroAssemblerARMv7.h:
1622         (JSC::MacroAssemblerARMv7::add64):
1623         * assembler/MacroAssemblerX86.h:
1624         (JSC::MacroAssemblerX86::add64):
1625         * assembler/MacroAssemblerX86_64.h:
1626         (JSC::MacroAssemblerX86_64::add64):
1627         * dfg/DFGAssemblyHelpers.cpp:
1628         * dfg/DFGAssemblyHelpers.h:
1629         (JSC::DFG::AssemblyHelpers::emitCount):
1630         * dfg/DFGJITCodeGenerator.cpp:
1631         (JSC::DFG::JITCodeGenerator::writeBarrier):
1632         * jit/JIT.h:
1633         * jit/JITInlineMethods.h:
1634         (JSC::JIT::emitCount):
1635
1636 011-11-10  Ryuan Choi  <ryuan.choi@samsung.com>
1637
1638         [CMAKE] Refactoring CMakeLists${PORT}.txt to Platform${PORT}.cmake
1639         https://bugs.webkit.org/show_bug.cgi?id=56705
1640
1641         Reviewed by Adam Roben.
1642
1643         * CMakeLists.txt:
1644         * PlatformEfl.cmake: Renamed from Source/JavaScriptCore/CMakeListsEfl.txt.
1645         * PlatformWinCE.cmake: Renamed from Source/JavaScriptCore/CMakeListsWinCE.txt.
1646         * shell/CMakeLists.txt:
1647         * shell/PlatformEfl.cmake: Renamed from Source/JavaScriptCore/shell/CMakeListsEfl.txt.
1648         * shell/PlatformWinCE.cmake: Renamed from Source/JavaScriptCore/shell/CMakeListsWinCE.txt.
1649         * wtf/CMakeLists.txt:
1650         * wtf/PlatformEfl.cmake: Renamed from Source/JavaScriptCore/wtf/CMakeListsEfl.txt.
1651         * wtf/PlatformWinCE.cmake: Renamed from Source/JavaScriptCore/wtf/CMakeListsWinCE.txt.
1652
1653 2011-11-10  Carlos Garcia Campos  <cgarcia@igalia.com>
1654
1655         Unreviewed. Fix make distcheck build.
1656
1657         * GNUmakefile.list.am: Add missing files.
1658
1659 2011-11-09  Michael Saboff  <msaboff@apple.com>
1660
1661         Towards 8 Bit Strings: Templatize JSC::LiteralParser class by character type
1662         https://bugs.webkit.org/show_bug.cgi?id=71862
1663
1664         Changed LiteralParser to be templatized of character type.
1665
1666         Moved five enums out of class definition to work around a clang compiler defect.
1667
1668         Added lexIdentifier templated method to break out character specific versions.
1669         Added static setParserTokenString templated method to handle setting approriately
1670         sized string pointer.
1671
1672         To keep code in LiteralParser.cpp and keep LiteralParser.h small, the two
1673         flavors of LiteralParser are explicitly instantiated at the end of
1674         LiteralParser.cpp.
1675
1676         Reviewed by Oliver Hunt.
1677
1678         * API/JSValueRef.cpp:
1679         (JSValueMakeFromJSONString):
1680         * JavaScriptCore.exp:
1681         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1682         * interpreter/Interpreter.cpp:
1683         (JSC::Interpreter::callEval):
1684         (JSC::Interpreter::execute):
1685         * runtime/JSGlobalObjectFunctions.cpp:
1686         (JSC::globalFuncEval):
1687         * runtime/JSONObject.cpp:
1688         (JSC::JSONProtoFuncParse):
1689         * runtime/LiteralParser.cpp:
1690         (JSC::isJSONWhiteSpace):
1691         (JSC::::tryJSONPParse):
1692         (JSC::::makeIdentifier):
1693         (JSC::::Lexer::lex):
1694         (JSC::::Lexer::lexIdentifier):
1695         (JSC::::Lexer::next):
1696         (JSC::LChar):
1697         (JSC::UChar):
1698         (JSC::isSafeStringCharacter):
1699         (JSC::::Lexer::lexString):
1700         (JSC::::Lexer::lexNumber):
1701         (JSC::::parse):
1702         * runtime/LiteralParser.h:
1703         (JSC::LiteralParser::LiteralParser):
1704         (JSC::LiteralParser::getErrorMessage):
1705         (JSC::LiteralParser::tryLiteralParse):
1706         (JSC::LiteralParser::Lexer::Lexer):
1707         (JSC::LiteralParser::Lexer::currentToken):
1708         (JSC::LiteralParser::Lexer::getErrorMessage):
1709         * runtime/UString.h:
1710         (JSC::LChar):
1711         (JSC::UChar):
1712         * wtf/text/StringBuilder.cpp:
1713         (WTF::StringBuilder::append):
1714         * wtf/text/StringBuilder.h:
1715         (WTF::StringBuilder::append):
1716
1717 2011-11-09  Filip Pizlo  <fpizlo@apple.com>
1718
1719         Multiple CodeBlock should be able to share the same instruction
1720         stream without copying
1721         https://bugs.webkit.org/show_bug.cgi?id=71978
1722
1723         Reviewed by Oliver Hunt.
1724         
1725         This refactors CodeBlock::m_instructions to be a Vector boxed in a
1726         ref-counted object, but otherwise does not take advantage of this.
1727         
1728         This is performance neutral.
1729
1730         * bytecode/CodeBlock.cpp:
1731         (JSC::CodeBlock::printStructure):
1732         (JSC::CodeBlock::printStructures):
1733         (JSC::CodeBlock::dump):
1734         (JSC::CodeBlock::CodeBlock):
1735         (JSC::CodeBlock::visitAggregate):
1736         (JSC::CodeBlock::shrinkToFit):
1737         * bytecode/CodeBlock.h:
1738         (JSC::CodeBlock::hasInstructions):
1739         (JSC::CodeBlock::numberOfInstructions):
1740         (JSC::CodeBlock::instructions):
1741         * jit/JIT.cpp:
1742         (JSC::JIT::JIT):
1743
1744 2011-11-09  Gavin Barraclough  <barraclough@apple.com>
1745
1746         Renovate ARMv7 assembler/macro-assembler
1747         https://bugs.webkit.org/show_bug.cgi?id=71982
1748
1749         Reviewed by Geoff Garen.
1750
1751         ARMv7Assembler:
1752         * add support for strb (byte stores)
1753         * rename the VMOV_CtoS opcodes (there are currently backwards!)
1754         * add support for adc (add with carry)
1755         * add support for vsqrt, vabs
1756         * add support for vmov (between FPRs, and to/from GPR pairs).
1757         * remove '_F64' postfixes from instructions (these aren't helpful, functions can already be distinguished by their signatures).
1758         * rename vcvt_F64_S32  to vcvt_signedToFloatingPoint, the prior postfix was unhelpful in failing to distinguish the types (S32 indicates a single precision register, but the type could be float, int32, or uint32).
1759         * rename vcvtr_S32_F64 to vcvt_floatingPointToSigned, as for previous, also vcvtr was the incorrect name for the operation (the emitted instruction truncates).
1760
1761         MacroAssemblerARMv7:
1762         * add 3-operand versions of and32, lshift32, or32, rshift32, urshift32, sub32, xor32, 
1763         * add store8, and store32 imm to base-index.
1764         * fix load32WithCompactAddressOffsetPatch to work for all gprs (the fix is a little kludgy but functional; to do better we'll have to also fix the repatching code).
1765         * Update supportsFloating* flags (all features now supported).
1766         * add moveDouble, storeDouble to absolute address, addDouble to absolute address
1767         * add 3-operand double operations.
1768         * implement sqrtDouble/absDouble
1769         * add branchTruncateDoubleToInt32, implement truncateDoubleToInt32
1770         * move should do nothing if src == dest
1771         * branchTest8-on-memory can be implemented in terms of branchTest32-on-register (branchTest8-on-register has been removed).
1772         * add 3-operand branchAdd32, branchSub32, also branchAdd32 absolute address.
1773
1774 2011-11-09  Gavin Barraclough  <barraclough@apple.com>
1775
1776         https://bugs.webkit.org/show_bug.cgi?id=71873
1777
1778         Reviewed by Geoff Garen.
1779
1780         Incrementally re-landing these changes, trying to determine what went wrong.
1781         (The whole patch failed tests on the build bot but worked locally.
1782
1783         * dfg/DFGByteCodeParser.cpp:
1784         (JSC::DFG::ByteCodeParser::handleIntrinsic):
1785
1786 2011-11-09  Filip Pizlo  <fpizlo@apple.com>
1787
1788         DFG OSR exit code should be lazily generated
1789         https://bugs.webkit.org/show_bug.cgi?id=71744
1790
1791         Reviewed by Gavin Barraclough.
1792         
1793         The OSR exit code is now generated the first time it is executed,
1794         rather than right after speculative compilation. Because most OSR
1795         exits are never taken, this should greatly reduce both code size
1796         and compilation time.
1797         
1798         This is a 1% win on SunSpider, and a 1% win on V8 when running in
1799         my harness. No change in V8 in V8's harness (due to the long runs,
1800         so compile time is not an issue) and no change in Kraken (again,
1801         long runs of small code so compile time has no measurable effect).
1802
1803         * CMakeListsEfl.txt:
1804         * GNUmakefile.list.am:
1805         * JavaScriptCore.xcodeproj/project.pbxproj:
1806         * Target.pri:
1807         * assembler/AbstractMacroAssembler.h:
1808         * assembler/MacroAssemblerX86.h:
1809         (JSC::MacroAssemblerX86::jump):
1810         * assembler/MacroAssemblerX86_64.h:
1811         (JSC::MacroAssemblerX86_64::jump):
1812         * assembler/X86Assembler.h:
1813         (JSC::X86Assembler::jmp_m):
1814         * bytecode/CodeBlock.h:
1815         (JSC::CodeBlock::createDFGDataIfNecessary):
1816         (JSC::CodeBlock::appendDFGOSREntryData):
1817         (JSC::CodeBlock::numberOfDFGOSREntries):
1818         (JSC::CodeBlock::dfgOSREntryData):
1819         (JSC::CodeBlock::dfgOSREntryDataForBytecodeIndex):
1820         (JSC::CodeBlock::appendOSRExit):
1821         (JSC::CodeBlock::appendSpeculationRecovery):
1822         (JSC::CodeBlock::numberOfOSRExits):
1823         (JSC::CodeBlock::numberOfSpeculationRecoveries):
1824         (JSC::CodeBlock::osrExit):
1825         (JSC::CodeBlock::speculationRecovery):
1826         * dfg/DFGAssemblyHelpers.h:
1827         (JSC::DFG::AssemblyHelpers::debugCall):
1828         * dfg/DFGCorrectableJumpPoint.cpp: Added.
1829         (JSC::DFG::CorrectableJumpPoint::codeLocationForRepatch):
1830         * dfg/DFGCorrectableJumpPoint.h: Added.
1831         (JSC::DFG::CorrectableJumpPoint::CorrectableJumpPoint):
1832         (JSC::DFG::CorrectableJumpPoint::switchToLateJump):
1833         (JSC::DFG::CorrectableJumpPoint::correctInitialJump):
1834         (JSC::DFG::CorrectableJumpPoint::correctLateJump):
1835         (JSC::DFG::CorrectableJumpPoint::initialJump):
1836         (JSC::DFG::CorrectableJumpPoint::lateJump):
1837         (JSC::DFG::CorrectableJumpPoint::correctJump):
1838         (JSC::DFG::CorrectableJumpPoint::getJump):
1839         * dfg/DFGJITCompiler.cpp:
1840         (JSC::DFG::JITCompiler::linkOSRExits):
1841         (JSC::DFG::JITCompiler::compileBody):
1842         (JSC::DFG::JITCompiler::link):
1843         * dfg/DFGJITCompiler.h:
1844         * dfg/DFGOSRExit.cpp: Added.
1845         (JSC::DFG::OSRExit::OSRExit):
1846         (JSC::DFG::OSRExit::dump):
1847         * dfg/DFGOSRExit.h:
1848         * dfg/DFGOSRExitCompiler.cpp: Added.
1849         * dfg/DFGOSRExitCompiler.h:
1850         * dfg/DFGOSRExitCompiler32_64.cpp:
1851         (JSC::DFG::OSRExitCompiler::compileExit):
1852         * dfg/DFGOSRExitCompiler64.cpp:
1853         (JSC::DFG::OSRExitCompiler::compileExit):
1854         * dfg/DFGOperations.cpp:
1855         * dfg/DFGSpeculativeJIT.cpp:
1856         * dfg/DFGSpeculativeJIT.h:
1857         (JSC::DFG::SpeculativeJIT::speculationCheck):
1858         * dfg/DFGThunks.cpp: Added.
1859         (JSC::DFG::osrExitGenerationThunkGenerator):
1860         * dfg/DFGThunks.h: Added.
1861         * jit/JITCode.h:
1862         (JSC::JITCode::dataAddressAtOffset):
1863         * runtime/JSGlobalData.h:
1864
1865 2011-11-09  Mark Hahnenberg  <mhahnenberg@apple.com>
1866
1867         Fixing build breakage
1868
1869         Unreviewed build fix
1870
1871         * JavaScriptCore.exp:
1872         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1873
1874 2011-11-09  Mark Hahnenberg  <mhahnenberg@apple.com>
1875
1876         De-virtualize JSVariableObject::isDynamicScope
1877         https://bugs.webkit.org/show_bug.cgi?id=71933
1878
1879         Reviewed by Geoffrey Garen.
1880
1881         * runtime/JSActivation.cpp:
1882         * runtime/JSActivation.h: Inlined and de-virtualized isDynamicScope
1883         (JSC::JSActivation::isDynamicScope):
1884         * runtime/JSGlobalObject.cpp:
1885         * runtime/JSGlobalObject.h: Inlined and de-virtualized isDynamicScope
1886         (JSC::JSGlobalObject::isDynamicScope):
1887         * runtime/JSStaticScopeObject.cpp:
1888         * runtime/JSStaticScopeObject.h: Inlined and de-virtualized isDynamicScope
1889         (JSC::JSStaticScopeObject::createStructure): Changed createStructure to use new JSType
1890         (JSC::JSStaticScopeObject::isDynamicScope):
1891         * runtime/JSType.h: Added new type for JSStaticScopeObject
1892         * runtime/JSVariableObject.cpp: De-virtualized and added an implementation that checks the 
1893         object's type and calls the corresponding implementation.
1894         (JSC::JSVariableObject::isDynamicScope):
1895         * runtime/JSVariableObject.h:
1896
1897 2011-11-09  Mark Hahnenberg  <mhahnenberg@apple.com>
1898
1899         De-virtualize JSGlobalObject::hasOwnPropertyForWrite
1900         https://bugs.webkit.org/show_bug.cgi?id=71934
1901
1902         Reviewed by Geoffrey Garen.
1903
1904         * runtime/JSGlobalObject.h: Removed the virtual-ness of hasOwnPropertyForWrite since nobody overrides it.
1905
1906 2011-11-09  Gavin Barraclough  <barraclough@apple.com>
1907
1908         https://bugs.webkit.org/show_bug.cgi?id=71873
1909
1910         Reviewed by Geoff Garen.
1911
1912         Incrementally re-landing these changes, trying to determine what went wrong.
1913         (The whole patch failed tests on the build bot but worked locally.
1914
1915         * assembler/MacroAssemblerARM.h:
1916         (JSC::MacroAssemblerARM::absDouble):
1917         * assembler/MacroAssemblerARMv7.h:
1918         * assembler/MacroAssemblerMIPS.h:
1919         (JSC::MacroAssemblerMIPS::absDouble):
1920         * assembler/MacroAssemblerSH4.h:
1921         (JSC::MacroAssemblerSH4::absDouble):
1922         * assembler/MacroAssemblerX86.h:
1923         (JSC::MacroAssemblerX86::absDouble):
1924         * assembler/MacroAssemblerX86Common.h:
1925         * assembler/MacroAssemblerX86_64.h:
1926         (JSC::MacroAssemblerX86_64::absDouble):
1927         * dfg/DFGSpeculativeJIT32_64.cpp:
1928         (JSC::DFG::SpeculativeJIT::compile):
1929         * dfg/DFGSpeculativeJIT64.cpp:
1930         (JSC::DFG::SpeculativeJIT::compile):
1931         * jit/ThunkGenerators.cpp:
1932         (JSC::absThunkGenerator):
1933
1934 2011-11-09  Mark Hahnenberg  <mhahnenberg@apple.com>
1935
1936         De-virtualize JSObject::getOwnPropertyDescriptor
1937         https://bugs.webkit.org/show_bug.cgi?id=71523
1938
1939         Reviewed by Sam Weinig.
1940
1941         Added getOwnPropertyDescriptor to the MethodTable, changed all of the 
1942         virtual versions of getOwnPropertyDescriptor to static ones, and 
1943         changed all of the call sites to the corresponding lookup in the MethodTable.
1944
1945         * API/JSCallbackObject.h:
1946         * API/JSCallbackObjectFunctions.h:
1947         (JSC::::getOwnPropertyDescriptor):
1948         * JavaScriptCore.exp:
1949         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
1950         * debugger/DebuggerActivation.cpp:
1951         (JSC::DebuggerActivation::getOwnPropertyDescriptor):
1952         * debugger/DebuggerActivation.h:
1953         * runtime/Arguments.cpp:
1954         (JSC::Arguments::getOwnPropertyDescriptor):
1955         * runtime/Arguments.h:
1956         * runtime/ArrayConstructor.cpp:
1957         (JSC::ArrayConstructor::getOwnPropertyDescriptor):
1958         * runtime/ArrayConstructor.h:
1959         * runtime/ArrayPrototype.cpp:
1960         (JSC::ArrayPrototype::getOwnPropertyDescriptor):
1961         * runtime/ArrayPrototype.h:
1962         * runtime/BooleanPrototype.cpp:
1963         (JSC::BooleanPrototype::getOwnPropertyDescriptor):
1964         * runtime/BooleanPrototype.h:
1965         * runtime/ClassInfo.h:
1966         * runtime/DateConstructor.cpp:
1967         (JSC::DateConstructor::getOwnPropertyDescriptor):
1968         * runtime/DateConstructor.h:
1969         * runtime/DatePrototype.cpp:
1970         (JSC::DatePrototype::getOwnPropertyDescriptor):
1971         * runtime/DatePrototype.h:
1972         * runtime/ErrorPrototype.cpp:
1973         (JSC::ErrorPrototype::getOwnPropertyDescriptor):
1974         * runtime/ErrorPrototype.h:
1975         * runtime/JSArray.cpp:
1976         (JSC::JSArray::getOwnPropertyDescriptor):
1977         * runtime/JSArray.h:
1978         * runtime/JSByteArray.cpp:
1979         (JSC::JSByteArray::getOwnPropertyDescriptor):
1980         * runtime/JSByteArray.h:
1981         * runtime/JSCell.cpp:
1982         (JSC::JSCell::getOwnPropertyDescriptor):
1983         * runtime/JSCell.h:
1984         * runtime/JSFunction.cpp:
1985         (JSC::JSFunction::getOwnPropertyDescriptor):
1986         * runtime/JSFunction.h:
1987         * runtime/JSGlobalObject.cpp:
1988         (JSC::JSGlobalObject::getOwnPropertyDescriptor):
1989         * runtime/JSGlobalObject.h:
1990         * runtime/JSNotAnObject.cpp:
1991         (JSC::JSNotAnObject::getOwnPropertyDescriptor):
1992         * runtime/JSNotAnObject.h:
1993         * runtime/JSONObject.cpp:
1994         (JSC::JSONObject::getOwnPropertyDescriptor):
1995         * runtime/JSONObject.h:
1996         * runtime/JSObject.cpp:
1997         (JSC::JSObject::vtableAnchor):
1998         (JSC::JSObject::propertyIsEnumerable):
1999         (JSC::JSObject::getOwnPropertyDescriptor):
2000         (JSC::JSObject::getPropertyDescriptor):
2001         (JSC::JSObject::defineOwnProperty):
2002         * runtime/JSObject.h:
2003         * runtime/JSString.cpp: Removed getOwnPropertyDescriptor, since this seems to be a relic from a 
2004         bygone era when getOwnPropertyDescriptor was rooted in JSCell rather than JSObject.  There were 
2005         no call sites for this version of getOwnPropertyDescriptor in the entire project.
2006         * runtime/JSString.h:
2007         * runtime/Lookup.h:
2008         (JSC::getStaticPropertyDescriptor):
2009         (JSC::getStaticFunctionDescriptor):
2010         (JSC::getStaticValueDescriptor):
2011         * runtime/MathObject.cpp:
2012         (JSC::MathObject::getOwnPropertyDescriptor):
2013         * runtime/MathObject.h:
2014         * runtime/NumberConstructor.cpp:
2015         (JSC::NumberConstructor::getOwnPropertyDescriptor):
2016         * runtime/NumberConstructor.h:
2017         * runtime/NumberPrototype.cpp:
2018         (JSC::NumberPrototype::getOwnPropertyDescriptor):
2019         * runtime/NumberPrototype.h:
2020         * runtime/ObjectConstructor.cpp:
2021         (JSC::ObjectConstructor::getOwnPropertyDescriptor):
2022         (JSC::objectConstructorGetOwnPropertyDescriptor):
2023         * runtime/ObjectConstructor.h:
2024         * runtime/ObjectPrototype.cpp:
2025         (JSC::ObjectPrototype::getOwnPropertyDescriptor):
2026         * runtime/ObjectPrototype.h:
2027         * runtime/RegExpConstructor.cpp:
2028         (JSC::RegExpConstructor::getOwnPropertyDescriptor):
2029         * runtime/RegExpConstructor.h:
2030         * runtime/RegExpMatchesArray.h:
2031         (JSC::RegExpMatchesArray::getOwnPropertyDescriptor):
2032         * runtime/RegExpObject.cpp:
2033         (JSC::RegExpObject::getOwnPropertyDescriptor):
2034         * runtime/RegExpObject.h:
2035         * runtime/RegExpPrototype.cpp:
2036         (JSC::RegExpPrototype::getOwnPropertyDescriptor):
2037         * runtime/RegExpPrototype.h:
2038         * runtime/StringConstructor.cpp:
2039         (JSC::StringConstructor::getOwnPropertyDescriptor):
2040         * runtime/StringConstructor.h:
2041         * runtime/StringObject.cpp:
2042         (JSC::StringObject::vtableAnchor): Added to prevent a weak vtable.
2043         (JSC::StringObject::getOwnPropertyDescriptor):
2044         * runtime/StringObject.h:
2045         * runtime/StringPrototype.cpp:
2046         (JSC::StringPrototype::getOwnPropertyDescriptor):
2047         * runtime/StringPrototype.h:
2048
2049 2011-11-09  Gavin Barraclough  <barraclough@apple.com>
2050
2051         https://bugs.webkit.org/show_bug.cgi?id=71873
2052
2053         Reviewed by Geoff Garen.
2054
2055         Incrementally re-landing these changes, trying to determine what went wrong.
2056         (The whole patch failed tests on the build bot but worked locally.
2057
2058         * assembler/MacroAssemblerARM.h:
2059         (JSC::MacroAssemblerARM::supportsFloatingPoint):
2060         (JSC::MacroAssemblerARM::supportsFloatingPointTruncate):
2061         (JSC::MacroAssemblerARM::supportsFloatingPointSqrt):
2062         (JSC::MacroAssemblerARM::supportsFloatingPointAbs):
2063         * assembler/MacroAssemblerARMv7.h:
2064         (JSC::MacroAssemblerARMv7::supportsFloatingPoint):
2065         (JSC::MacroAssemblerARMv7::supportsFloatingPointTruncate):
2066         (JSC::MacroAssemblerARMv7::supportsFloatingPointSqrt):
2067         (JSC::MacroAssemblerARMv7::supportsFloatingPointAbs):
2068         * assembler/MacroAssemblerMIPS.h:
2069         (JSC::MacroAssemblerMIPS::supportsFloatingPoint):
2070         (JSC::MacroAssemblerMIPS::supportsFloatingPointTruncate):
2071         (JSC::MacroAssemblerMIPS::supportsFloatingPointSqrt):
2072         (JSC::MacroAssemblerMIPS::supportsFloatingPointAbs):
2073         * assembler/MacroAssemblerSH4.h:
2074         (JSC::MacroAssemblerSH4::supportsFloatingPoint):
2075         (JSC::MacroAssemblerSH4::supportsFloatingPointTruncate):
2076         (JSC::MacroAssemblerSH4::supportsFloatingPointSqrt):
2077         (JSC::MacroAssemblerSH4::supportsFloatingPointAbs):
2078         * assembler/MacroAssemblerX86.h:
2079         (JSC::MacroAssemblerX86::supportsFloatingPoint):
2080         (JSC::MacroAssemblerX86::supportsFloatingPointTruncate):
2081         (JSC::MacroAssemblerX86::supportsFloatingPointSqrt):
2082         (JSC::MacroAssemblerX86::supportsFloatingPointAbs):
2083         * assembler/MacroAssemblerX86_64.h:
2084         (JSC::MacroAssemblerX86_64::supportsFloatingPoint):
2085         (JSC::MacroAssemblerX86_64::supportsFloatingPointTruncate):
2086         (JSC::MacroAssemblerX86_64::supportsFloatingPointSqrt):
2087         (JSC::MacroAssemblerX86_64::supportsFloatingPointAbs):
2088         * jit/ThunkGenerators.cpp:
2089         (JSC::absThunkGenerator):
2090
2091 2011-11-08  Darin Adler  <darin@apple.com>
2092
2093         Add code path in HashTable for emptyValueIsZero that does not require copying the empty value
2094         https://bugs.webkit.org/show_bug.cgi?id=71875
2095
2096         Reviewed by Anders Carlsson.
2097
2098         This is a step along the path of making OwnPtr work as HashMap value types.
2099
2100         * wtf/Alignment.h: Moved the AlignedBufferChar and AlignedBuffer types from Vector.h here.
2101         Also fixed include style. To include other WTF headers inside WTF, we use "" includes.
2102         I did not change the code to fix style checker complaints.
2103
2104         * wtf/HashTable.h: Added includes as needed and fixed include style.
2105         (WTF::doubleHash): Removed the uneeeded and inappropriate "static" in this function, which
2106         gave it internal linkage for no good reason.
2107         (WTF::HashTable::checkKey): Made this use AlignedBuffer for the deleted value check to avoid
2108         construction/destruction problems instead of doing the trick where we construct and destroy
2109         an empty value twice. It's cleaner and simpler and avoids copying the empty value.
2110         (WTF::HashTable::initializeBucket): Specialized initializeBucket to use memset when the
2111         empty value is zero rather than copying an empty value.
2112
2113         * wtf/Vector.h: Moved the AlignedBufferChar and AlignedBuffer types into Alignment.h.
2114
2115 2011-11-09  Gabor Rapcsanyi  <rgabor@webkit.org>
2116
2117         Buildfix for 32bit debug mode.
2118
2119         Reviewed by Csaba Osztrogonác.
2120
2121         * dfg/DFGAbstractState.cpp:
2122         (JSC::DFG::AbstractState::dump):
2123         * dfg/DFGGraph.cpp:
2124         (JSC::DFG::Graph::dump):
2125
2126 2011-11-09  Andy Wingo  <wingo@igalia.com>
2127
2128         Enable the DFG JIT on X86-64 Linux platforms
2129         https://bugs.webkit.org/show_bug.cgi?id=71373
2130
2131         Reviewed by Csaba Osztrogonác.
2132
2133         * wtf/Platform.h (ENABLE_DFG_JIT): Enable the DFG JIT on the
2134         x86-64 GNU/Linux platform.
2135         * CMakeListsEfl.txt: Add JSValue64 implementations to EFL build.
2136
2137 2011-11-09  Csaba Osztrogonác  <ossy@webkit.org>
2138
2139         Enable the DFG JIT on x86-64 Linux platforms
2140         https://bugs.webkit.org/show_bug.cgi?id=71373
2141
2142         Enable DFG JIT by default on X86 Linux and Mac platforms
2143         https://bugs.webkit.org/show_bug.cgi?id=71686
2144
2145         Buildfix for stricter compilers: -Werror=unused-but-set-variable
2146
2147         Reviewed by Zoltan Herczeg.
2148
2149         * dfg/DFGSpeculativeJIT.cpp:
2150         (JSC::DFG::SpeculativeJIT::compilePutByValForByteArray):
2151         * dfg/DFGSpeculativeJIT32_64.cpp:
2152         (JSC::DFG::SpeculativeJIT::compile):
2153         * dfg/DFGSpeculativeJIT64.cpp:
2154         (JSC::DFG::SpeculativeJIT::compile):
2155
2156 2011-11-09  Sheriff Bot  <webkit.review.bot@gmail.com>
2157
2158         Unreviewed, rolling out r99678.
2159         http://trac.webkit.org/changeset/99678
2160         https://bugs.webkit.org/show_bug.cgi?id=71882
2161
2162         broke the build with -Werror=unused-but-set-variable
2163         (Requested by tronical_ on #webkit).
2164
2165         * CMakeListsEfl.txt:
2166         * wtf/Platform.h:
2167
2168 2011-11-09  Andy Wingo  <wingo@igalia.com>
2169
2170         Enable the DFG JIT on X86-64 Linux platforms
2171         https://bugs.webkit.org/show_bug.cgi?id=71373
2172
2173         Reviewed by Filip Pizlo.
2174
2175         * wtf/Platform.h (ENABLE_DFG_JIT): Enable the DFG JIT on the
2176         x86-64 GNU/Linux platform.
2177         * CMakeListsEfl.txt: Add JSValue64 implementations to EFL build.
2178
2179 2011-11-09  Mark Hahnenberg  <mhahnenberg@apple.com>
2180
2181         De-virtualize JSObject::defineOwnProperty
2182         https://bugs.webkit.org/show_bug.cgi?id=71429
2183
2184         Reviewed by Geoffrey Garen.
2185
2186         Added defineOwnProperty to the MethodTable, changed all the virtual 
2187         implementations of defineOwnProperty to static ones, and replaced 
2188         all call sites with corresponding lookups in the MethodTable.
2189
2190         * JavaScriptCore.exp:
2191         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
2192         * runtime/Arguments.cpp:
2193         (JSC::Arguments::createStrictModeCallerIfNecessary):
2194         (JSC::Arguments::createStrictModeCalleeIfNecessary):
2195         * runtime/ClassInfo.h:
2196         * runtime/JSCell.cpp:
2197         (JSC::JSCell::defineOwnProperty):
2198         * runtime/JSCell.h:
2199         * runtime/JSObject.cpp:
2200         (JSC::JSObject::defineOwnProperty):
2201         * runtime/JSObject.h:
2202         * runtime/ObjectConstructor.cpp:
2203         (JSC::objectConstructorDefineProperty):
2204         (JSC::defineProperties):
2205
2206 2011-11-09  Simon Hausmann  <simon.hausmann@nokia.com>
2207
2208         [Qt] Build system cleanup
2209         https://bugs.webkit.org/show_bug.cgi?id=71815
2210
2211         Reviewed by Kenneth Rohde Christiansen.
2212
2213         * wtf/wtf.pri: Moved the glib dependency to javascriptcore.prf.
2214
2215 2011-11-08  Simon Hausmann  <simon.hausmann@nokia.com>
2216
2217         [Qt] Replace use of QApplication with QGuiApplication
2218         https://bugs.webkit.org/show_bug.cgi?id=71794
2219
2220         Reviewed by Andreas Kling.
2221
2222         Add compat headers for use when building with Qt 4: QGuiApplication
2223         is typedef'ed to QApplication.
2224
2225         * wtf/qt/compat/QGuiApplication: Added.
2226         * wtf/qt/compat/qguiapplication.h: Added.
2227
2228 2011-11-08  Sheriff Bot  <webkit.review.bot@gmail.com>
2229
2230         Unreviewed, rolling out r99647.
2231         http://trac.webkit.org/changeset/99647
2232         https://bugs.webkit.org/show_bug.cgi?id=71876
2233
2234         It broke jsc and layout tests on all bot (Requested by
2235         Ossy_night on #webkit).
2236
2237         * assembler/MacroAssemblerARM.h:
2238         (JSC::MacroAssemblerARM::supportsFloatingPoint):
2239         (JSC::MacroAssemblerARM::supportsFloatingPointTruncate):
2240         (JSC::MacroAssemblerARM::supportsFloatingPointSqrt):
2241         (JSC::MacroAssemblerARM::supportsDoubleBitops):
2242         (JSC::MacroAssemblerARM::andnotDouble):
2243         * assembler/MacroAssemblerARMv7.h:
2244         (JSC::MacroAssemblerARMv7::supportsFloatingPoint):
2245         (JSC::MacroAssemblerARMv7::supportsFloatingPointTruncate):
2246         (JSC::MacroAssemblerARMv7::supportsFloatingPointSqrt):
2247         (JSC::MacroAssemblerARMv7::supportsDoubleBitops):
2248         * assembler/MacroAssemblerMIPS.h:
2249         (JSC::MacroAssemblerMIPS::andnotDouble):
2250         (JSC::MacroAssemblerMIPS::supportsFloatingPoint):
2251         (JSC::MacroAssemblerMIPS::supportsFloatingPointTruncate):
2252         (JSC::MacroAssemblerMIPS::supportsFloatingPointSqrt):
2253         (JSC::MacroAssemblerMIPS::supportsDoubleBitops):
2254         * assembler/MacroAssemblerSH4.h:
2255         (JSC::MacroAssemblerSH4::supportsFloatingPoint):
2256         (JSC::MacroAssemblerSH4::supportsFloatingPointTruncate):
2257         (JSC::MacroAssemblerSH4::supportsFloatingPointSqrt):
2258         (JSC::MacroAssemblerSH4::supportsDoubleBitops):
2259         (JSC::MacroAssemblerSH4::andnotDouble):
2260         * assembler/MacroAssemblerX86.h:
2261         (JSC::MacroAssemblerX86::MacroAssemblerX86):
2262         (JSC::MacroAssemblerX86::supportsFloatingPoint):
2263         (JSC::MacroAssemblerX86::supportsFloatingPointTruncate):
2264         (JSC::MacroAssemblerX86::supportsFloatingPointSqrt):
2265         (JSC::MacroAssemblerX86::supportsDoubleBitops):
2266         * assembler/MacroAssemblerX86Common.h:
2267         (JSC::MacroAssemblerX86Common::andnotDouble):
2268         * assembler/MacroAssemblerX86_64.h:
2269         (JSC::MacroAssemblerX86_64::supportsFloatingPoint):
2270         (JSC::MacroAssemblerX86_64::supportsFloatingPointTruncate):
2271         (JSC::MacroAssemblerX86_64::supportsFloatingPointSqrt):
2272         (JSC::MacroAssemblerX86_64::supportsDoubleBitops):
2273         * assembler/X86Assembler.h:
2274         * dfg/DFGByteCodeParser.cpp:
2275         (JSC::DFG::ByteCodeParser::handleIntrinsic):
2276         * dfg/DFGSpeculativeJIT32_64.cpp:
2277         (JSC::DFG::SpeculativeJIT::compile):
2278         * dfg/DFGSpeculativeJIT64.cpp:
2279         (JSC::DFG::SpeculativeJIT::compile):
2280         * jit/ThunkGenerators.cpp:
2281         (JSC::absThunkGenerator):
2282         * runtime/JSGlobalData.cpp:
2283
2284 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2285
2286         Better abstract 'abs' operation through the MacroAssembler.
2287         https://bugs.webkit.org/show_bug.cgi?id=71873
2288
2289         Reviewed by Geoff Garen.
2290
2291         Currently the x86 specific instruction sequence to perform a double abs
2292         is duplicated throughout the JITs / thunk generators.
2293
2294         * assembler/MacroAssemblerARM.h:
2295         (JSC::MacroAssemblerARM::supportsFloatingPoint):
2296         (JSC::MacroAssemblerARM::supportsFloatingPointTruncate):
2297         (JSC::MacroAssemblerARM::supportsFloatingPointSqrt):
2298         (JSC::MacroAssemblerARM::supportsFloatingPointAbs):
2299         (JSC::MacroAssemblerARM::absDouble):
2300             - Renamed supportsFloatingPointAbs, make these methods static so that
2301               we can check the JIT's capabilites before we begin compilation.
2302         * assembler/MacroAssemblerARMv7.h:
2303         (JSC::MacroAssemblerARMv7::supportsFloatingPoint):
2304         (JSC::MacroAssemblerARMv7::supportsFloatingPointTruncate):
2305         (JSC::MacroAssemblerARMv7::supportsFloatingPointSqrt):
2306         (JSC::MacroAssemblerARMv7::supportsFloatingPointAbs):
2307             - Renamed supportsFloatingPointAbs, make these methods static so that
2308               we can check the JIT's capabilites before we begin compilation.
2309         * assembler/MacroAssemblerMIPS.h:
2310         (JSC::MacroAssemblerMIPS::absDouble):
2311         (JSC::MacroAssemblerMIPS::supportsFloatingPoint):
2312         (JSC::MacroAssemblerMIPS::supportsFloatingPointTruncate):
2313         (JSC::MacroAssemblerMIPS::supportsFloatingPointSqrt):
2314         (JSC::MacroAssemblerMIPS::supportsFloatingPointAbs):
2315             - Renamed supportsFloatingPointAbs, make these methods static so that
2316               we can check the JIT's capabilites before we begin compilation.
2317         * assembler/MacroAssemblerSH4.h:
2318         (JSC::MacroAssemblerSH4::supportsFloatingPoint):
2319         (JSC::MacroAssemblerSH4::supportsFloatingPointTruncate):
2320         (JSC::MacroAssemblerSH4::supportsFloatingPointSqrt):
2321         (JSC::MacroAssemblerSH4::supportsFloatingPointAbs):
2322         (JSC::MacroAssemblerSH4::absDouble):
2323             - Renamed supportsFloatingPointAbs, make these methods static so that
2324               we can check the JIT's capabilites before we begin compilation.
2325         * assembler/MacroAssemblerX86.h:
2326         (JSC::MacroAssemblerX86::absDouble):
2327         (JSC::MacroAssemblerX86::supportsFloatingPoint):
2328         (JSC::MacroAssemblerX86::supportsFloatingPointTruncate):
2329         (JSC::MacroAssemblerX86::supportsFloatingPointSqrt):
2330         (JSC::MacroAssemblerX86::supportsFloatingPointAbs):
2331             - Made supports* methods static so that we can check the JIT's
2332               capabilites before we begin compilation. Added absDouble.
2333         * assembler/MacroAssemblerX86Common.h:
2334             - Removed andnotDouble, added s_maskSignBit.
2335         * assembler/MacroAssemblerX86_64.h:
2336         (JSC::MacroAssemblerX86_64::absDouble):
2337         (JSC::MacroAssemblerX86_64::supportsFloatingPoint):
2338         (JSC::MacroAssemblerX86_64::supportsFloatingPointTruncate):
2339         (JSC::MacroAssemblerX86_64::supportsFloatingPointSqrt):
2340         (JSC::MacroAssemblerX86_64::supportsFloatingPointAbs):
2341             - Made supports* methods static so that we can check the JIT's
2342               capabilites before we begin compilation. Added absDouble.
2343         * assembler/X86Assembler.h:
2344         (JSC::X86Assembler::andpd_rr):
2345         (JSC::X86Assembler::andpd_mr):
2346             - Added support for andpd instruction.
2347         * dfg/DFGByteCodeParser.cpp:
2348         (JSC::DFG::ByteCodeParser::handleIntrinsic):
2349             - Added checks for supportsFloatingPointAbs, supportsFloatingPointSqrt.
2350         * dfg/DFGSpeculativeJIT32_64.cpp:
2351         (JSC::DFG::SpeculativeJIT::compile):
2352             - Switched to use doubleAbs, we can now also reuse the operand register for the result.
2353         * dfg/DFGSpeculativeJIT64.cpp:
2354         (JSC::DFG::SpeculativeJIT::compile):
2355             - Switched to use doubleAbs, we can now also reuse the operand register for the result.
2356         * jit/ThunkGenerators.cpp:
2357             - Switched to use doubleAbs.
2358         (JSC::absThunkGenerator):
2359         * runtime/JSGlobalData.cpp:
2360             - Declared MacroAssemblerX86Common::s_maskSignBit here.
2361               This is a little ugly, but it doesn't seem worth adding a whole extra .cpp
2362               to the compile for just one constant.
2363
2364 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2365
2366         Move duplicates of SYMBOL_STRING* macros to the single location
2367         https://bugs.webkit.org/show_bug.cgi?id=71456
2368
2369         Reviewed by Sam Weinig.
2370
2371         * JavaScriptCore.xcodeproj/project.pbxproj:
2372         * dfg/DFGOperations.cpp:
2373         * jit/JITStubs.cpp:
2374         * wtf/InlineASM.h: Added.
2375             - Moved asm related macros.
2376
2377 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2378
2379         Move code to handle 8bit regs from X86Assembler to MacroAssembler
2380         https://bugs.webkit.org/show_bug.cgi?id=71867
2381
2382         Reviewed by Oliver Hunt.
2383
2384         This code is fine, but is in the wrong place really. X86 assembler should
2385         basically just format up exactly the instruction you request - not expand
2386         out to a set of instructions (that is what the macro assembler layer is
2387         for!). For other 8-bit ops, on X86 we don't guard against clients accessing
2388         the XH registers.
2389
2390         * assembler/MacroAssemblerX86Common.h:
2391         (JSC::MacroAssemblerX86Common::store8):
2392         * assembler/X86Assembler.h:
2393         (JSC::X86Assembler::movb_rm):
2394             - moved some code.
2395
2396 2011-11-08  Filip Pizlo  <fpizlo@apple.com>
2397
2398         Unreviewed build fix for GTK.
2399
2400         * GNUmakefile.list.am:
2401
2402 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2403
2404         Build fix.
2405
2406         * assembler/X86Assembler.h:
2407
2408 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2409
2410         Errrk, failed to commit this in last change.
2411
2412         * assembler/X86Assembler.h:
2413
2414 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2415
2416         Remove an unused method.
2417
2418         Rubber stamped by Geoff Garen.
2419
2420         * assembler/AbstractMacroAssembler.h:
2421         * assembler/AssemblerBuffer.h:
2422             - removed rewindToLabel.
2423
2424 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2425
2426         Fix OSR entry points to calculate offsets correctly WRT to branch compaction.
2427         https://bugs.webkit.org/show_bug.cgi?id=71864
2428
2429         Reviewed by Filip Pizlo.
2430
2431         * assembler/LinkBuffer.h:
2432         (JSC::LinkBuffer::offsetOf):
2433             - We use this to return the offsets into the code of the entry points.
2434         * dfg/DFGJITCompiler.cpp:
2435         (JSC::DFG::JITCompiler::compileEntry):
2436         (JSC::DFG::JITCompiler::compileBody):
2437         (JSC::DFG::JITCompiler::compile):
2438         (JSC::DFG::JITCompiler::compileFunction):
2439             - Move the construction of the speculative JIT outside of
2440               compileBody, such that it is still available to link the
2441               OSR entry points at the point we are linking.
2442         * dfg/DFGJITCompiler.h:
2443         (JSC::DFG::JITCompiler::noticeOSREntry):
2444             - Pass the label of the block & linkbuffer into noticeOSREntry.
2445         * dfg/DFGSpeculativeJIT.cpp:
2446         (JSC::DFG::SpeculativeJIT::compile):
2447         (JSC::DFG::SpeculativeJIT::linkOSREntries):
2448             - Moved call to noticeOSREntry until we we linking.
2449         * dfg/DFGSpeculativeJIT.h:
2450         * jit/JIT.cpp:
2451         (JSC::JIT::privateCompileMainPass):
2452         (JSC::JIT::privateCompileSlowCases):
2453         (JSC::JIT::privateCompile):
2454             - Moved calculation of entries until we we linking.
2455         * jit/JIT.h:
2456             - Removed some members.
2457
2458 2011-11-08  Filip Pizlo  <fpizlo@apple.com>
2459
2460         DFG OSR exit code should be generated by a separate compiler, not
2461         related to DFG::JITCompiler
2462         https://bugs.webkit.org/show_bug.cgi?id=71787
2463
2464         Reviewed by Gavin Barraclough.
2465         
2466         Moves the exitSpeculativeWithOSR() method from JITCompiler to
2467         OSRExitCompiler::compileExit().
2468
2469         * CMakeListsEfl.txt:
2470         * JavaScriptCore.xcodeproj/project.pbxproj:
2471         * Target.pri:
2472         * dfg/DFGJITCompiler.cpp:
2473         (JSC::DFG::JITCompiler::linkOSRExits):
2474         * dfg/DFGJITCompiler32_64.cpp: Removed.
2475         * dfg/DFGOSRExitCompiler.h: Added.
2476         (JSC::DFG::OSRExitCompiler::OSRExitCompiler):
2477         * dfg/DFGOSRExitCompiler32_64.cpp: Added.
2478         (JSC::DFG::OSRExitCompiler::compileExit):
2479         * dfg/DFGOSRExitCompiler64.cpp: Added.
2480         (JSC::DFG::OSRExitCompiler::compileExit):
2481         * runtime/JSValue.h:
2482
2483 2011-11-08  Filip Pizlo  <fpizlo@apple.com>
2484
2485         Basic DFG definitions should be moved out of DFGNode.h
2486         https://bugs.webkit.org/show_bug.cgi?id=71861
2487
2488         Rubber-stamped by Gavin Barraclough.
2489
2490         * JavaScriptCore.xcodeproj/project.pbxproj:
2491         * dfg/DFGCommon.h: Added.
2492         (JSC::DFG::NodeIndexTraits::defaultValue):
2493         * dfg/DFGNode.h:
2494         * dfg/DFGOSRExit.h:
2495         * dfg/DFGRegisterBank.h:
2496
2497 2011-11-08  Michael Saboff  <msaboff@apple.com>
2498
2499         Towards 8 Bit Strings: Templatize JSC::Parser class by Lexer type
2500         https://bugs.webkit.org/show_bug.cgi?id=71761
2501
2502         Templatized Parser based on Lexer<T>. Moved two enums,
2503         SourceElementsMode and FunctionRequirements out of Parser definition
2504         to work around a clang compiler defect.
2505
2506         Cleaned up SourceCode data() to return StringImpl* and eliminated
2507         the recently added stringData() virtual method.
2508
2509         To keep code in Parser.cpp and keep Parser.h small, the two flavors
2510         of Parser are explicitly instantiated at the end of Parser.cpp.
2511
2512         Reviewed by Gavin Barraclough.
2513
2514         * interpreter/Interpreter.cpp:
2515         (JSC::appendSourceToError):
2516         * parser/Lexer.cpp:
2517         (JSC::::setCode):
2518         (JSC::::sourceCode):
2519         * parser/Parser.cpp:
2520         (JSC::::Parser):
2521         (JSC::::~Parser):
2522         (JSC::::parseInner):
2523         (JSC::::didFinishParsing):
2524         (JSC::::allowAutomaticSemicolon):
2525         (JSC::::parseSourceElements):
2526         (JSC::::parseVarDeclaration):
2527         (JSC::::parseConstDeclaration):
2528         (JSC::::parseDoWhileStatement):
2529         (JSC::::parseWhileStatement):
2530         (JSC::::parseVarDeclarationList):
2531         (JSC::::parseConstDeclarationList):
2532         (JSC::::parseForStatement):
2533         (JSC::::parseBreakStatement):
2534         (JSC::::parseContinueStatement):
2535         (JSC::::parseReturnStatement):
2536         (JSC::::parseThrowStatement):
2537         (JSC::::parseWithStatement):
2538         (JSC::::parseSwitchStatement):
2539         (JSC::::parseSwitchClauses):
2540         (JSC::::parseSwitchDefaultClause):
2541         (JSC::::parseTryStatement):
2542         (JSC::::parseDebuggerStatement):
2543         (JSC::::parseBlockStatement):
2544         (JSC::::parseStatement):
2545         (JSC::::parseFormalParameters):
2546         (JSC::::parseFunctionBody):
2547         (JSC::::parseFunctionInfo):
2548         (JSC::::parseFunctionDeclaration):
2549         (JSC::::parseExpressionOrLabelStatement):
2550         (JSC::::parseExpressionStatement):
2551         (JSC::::parseIfStatement):
2552         (JSC::::parseExpression):
2553         (JSC::::parseAssignmentExpression):
2554         (JSC::::parseConditionalExpression):
2555         (JSC::::isBinaryOperator):
2556         (JSC::::parseBinaryExpression):
2557         (JSC::::parseProperty):
2558         (JSC::::parseObjectLiteral):
2559         (JSC::::parseStrictObjectLiteral):
2560         (JSC::::parseArrayLiteral):
2561         (JSC::::parsePrimaryExpression):
2562         (JSC::::parseArguments):
2563         (JSC::::parseMemberExpression):
2564         (JSC::::parseUnaryExpression):
2565         * parser/Parser.h:
2566         (JSC::::parse):
2567         (JSC::parse):
2568         * parser/SourceCode.h:
2569         (JSC::SourceCode::data):
2570         (JSC::SourceCode::subExpression):
2571         * parser/SourceProvider.h:
2572         (JSC::UStringSourceProvider::data):
2573
2574 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2575
2576         Fix PropertyAccessRecords in DFG JIT to take account of branch compaction.
2577         https://bugs.webkit.org/show_bug.cgi?id=71855
2578
2579         Reviewed by Filip Pizlo.
2580
2581         The DFG JIT presently calculates a set of offsets early, before branches have been compacted.
2582         This won't work on ARMv7.
2583
2584         * assembler/AbstractMacroAssembler.h:
2585         (JSC::AbstractMacroAssembler::differenceBetweenCodePtr):
2586         * assembler/LinkBuffer.h:
2587         (JSC::LinkBuffer::locationOf):
2588         * dfg/DFGJITCodeGenerator32_64.cpp:
2589         (JSC::DFG::JITCodeGenerator::cachedGetById):
2590         (JSC::DFG::JITCodeGenerator::cachedPutById):
2591         * dfg/DFGJITCodeGenerator64.cpp:
2592         (JSC::DFG::JITCodeGenerator::cachedGetById):
2593         (JSC::DFG::JITCodeGenerator::cachedPutById):
2594         * dfg/DFGJITCompiler.cpp:
2595         (JSC::DFG::JITCompiler::link):
2596         * dfg/DFGJITCompiler.h:
2597         (JSC::DFG::PropertyAccessRecord::PropertyAccessRecord):
2598         (JSC::DFG::JITCompiler::addPropertyAccess):
2599
2600 2011-11-08  Gavin Barraclough  <barraclough@apple.com>
2601
2602         DFG JIT calculation of OSR entry points is not THUMB2 safe
2603         https://bugs.webkit.org/show_bug.cgi?id=71852
2604
2605         Reviewed by Oliver Hunt.
2606
2607         Executable addresses are tagged with a low bit set to distinguish
2608         between THUMB2 and traditional ARM.
2609
2610         * dfg/DFGJITCompiler.cpp:
2611         (JSC::DFG::JITCompiler::exitSpeculativeWithOSR):
2612         * dfg/DFGJITCompiler32_64.cpp:
2613         (JSC::DFG::JITCompiler::exitSpeculativeWithOSR):
2614         * dfg/DFGOSREntry.cpp:
2615         (JSC::DFG::prepareOSREntry):
2616         * jit/JITCode.h:
2617         (JSC::JITCode::executableAddressAtOffset):
2618         (JSC::JITCode::start):
2619         (JSC::JITCode::size):
2620
2621 2011-11-08  Michael Saboff  <msaboff@apple.com>
2622
2623         JSC::Parser::Parser leaks Lexer member
2624         https://bugs.webkit.org/show_bug.cgi?id=71847
2625
2626         Changed m_lexer member of Parser to be OwnPtr to fix a memory leak.
2627
2628         Reviewed by Oliver Hunt.
2629
2630         * parser/Parser.cpp:
2631         (JSC::Parser::Parser):
2632         (JSC::Parser::parseFunctionBody):
2633         * parser/Parser.h:
2634
2635 2011-11-08  Yuqiang Xian  <yuqiang.xian@intel.com>
2636
2637         Enable DFG JIT by default on X86 Linux and Mac platforms
2638         https://bugs.webkit.org/show_bug.cgi?id=71686
2639
2640         Reviewed by Filip Pizlo.
2641
2642         We can get 9% on SunSpider, 89% on Kraken and 37% on V8, on Linux X86.
2643
2644         * wtf/Platform.h:
2645
2646 2011-11-08  Yuqiang Xian  <yuqiang.xian@intel.com>
2647
2648         DFG 32_64 - update make lists for efl, gtk, and Qt ports with DFG change r99519
2649         https://bugs.webkit.org/show_bug.cgi?id=71768
2650
2651         Reviewed by Geoffrey Garen.
2652
2653         Also includes a fix to make the newly introduced AssemblyHelpers
2654         friend of JSValue as we need the Tag definitions.
2655
2656         * CMakeListsEfl.txt:
2657         * GNUmakefile.list.am:
2658         * Target.pri:
2659         * runtime/JSValue.h:
2660
2661 2011-11-07  Yuqiang Xian  <yuqiang.xian@intel.com>
2662
2663         Fix gcc 4.4 compilation warnings in DFG 32_64
2664         https://bugs.webkit.org/show_bug.cgi?id=71762
2665
2666         Reviewed by Filip Pizlo.
2667
2668         * dfg/DFGJITCodeGenerator.h:
2669         (JSC::DFG::JITCodeGenerator::registersMatched):
2670
2671 2011-11-07  Filip Pizlo  <fpizlo@apple.com>
2672
2673         DFG code base should allow for classes not related to DFG::JITCompiler
2674         to use DFG idioms
2675         https://bugs.webkit.org/show_bug.cgi?id=71746
2676
2677         Reviewed by Gavin Barraclough.
2678
2679         * JavaScriptCore.xcodeproj/project.pbxproj:
2680         * dfg/DFGAssemblyHelpers.cpp: Added.
2681         (JSC::DFG::AssemblyHelpers::decodedCodeMapFor):
2682         (JSC::DFG::AssemblyHelpers::emitCount):
2683         (JSC::DFG::AssemblyHelpers::setSamplingFlag):
2684         (JSC::DFG::AssemblyHelpers::clearSamplingFlag):
2685         (JSC::DFG::AssemblyHelpers::jitAssertIsInt32):
2686         (JSC::DFG::AssemblyHelpers::jitAssertIsJSInt32):
2687         (JSC::DFG::AssemblyHelpers::jitAssertIsJSNumber):
2688         (JSC::DFG::AssemblyHelpers::jitAssertIsJSDouble):
2689         (JSC::DFG::AssemblyHelpers::jitAssertIsCell):
2690         * dfg/DFGAssemblyHelpers.h: Added.
2691         * dfg/DFGJITCompiler.cpp:
2692         * dfg/DFGJITCompiler.h:
2693         (JSC::DFG::JITCompiler::JITCompiler):
2694         (JSC::DFG::JITCompiler::graph):
2695         * dfg/DFGJITCompiler32_64.cpp:
2696         * dfg/DFGOSRExit.h: Added.
2697         (JSC::DFG::SpeculationRecovery::SpeculationRecovery):
2698         (JSC::DFG::SpeculationRecovery::type):
2699         (JSC::DFG::SpeculationRecovery::dest):
2700         (JSC::DFG::SpeculationRecovery::src):
2701         (JSC::DFG::OSRExit::numberOfRecoveries):
2702         (JSC::DFG::OSRExit::valueRecovery):
2703         (JSC::DFG::OSRExit::isArgument):
2704         (JSC::DFG::OSRExit::isVariable):
2705         (JSC::DFG::OSRExit::argumentForIndex):
2706         (JSC::DFG::OSRExit::variableForIndex):
2707         (JSC::DFG::OSRExit::operandForArgument):
2708         (JSC::DFG::OSRExit::operandForIndex):
2709         * dfg/DFGSpeculativeJIT.h:
2710
2711 2011-11-07  Filip Pizlo  <fpizlo@apple.com>
2712
2713         Switch back to 1+1 value profiling buckets, since it didn't help on arewefastyet,
2714         but it appears to help on other benchmarks.
2715
2716         Rubber stamped by Oliver Hunt.
2717
2718         * bytecode/ValueProfile.h:
2719
2720 2011-11-07  Ariya Hidayat  <ariya@sencha.com>
2721
2722         "use strict" can not contain escape sequences or line continuation
2723         https://bugs.webkit.org/show_bug.cgi?id=71532
2724
2725         Reviewed by Darin Adler.
2726
2727         Store the actual literal length (before the escapes and line
2728         continuation are encoded) while parsing the directive and use it
2729         for the directive comparison.
2730
2731         * parser/Parser.cpp:
2732         (JSC::Parser::parseSourceElements):
2733         (JSC::Parser::parseStatement):
2734         * parser/Parser.h:
2735
2736 2011-11-06  Filip Pizlo  <fpizlo@apple.com>
2737
2738         DFG operationCreateThis slow path may get the wrong callee in case of inlining
2739         https://bugs.webkit.org/show_bug.cgi?id=71647
2740
2741         Reviewed by Oliver Hunt.
2742         
2743         No new tests because I only saw this manifest itself when I had other bugs
2744         leading to spurious slow path executions.
2745
2746         * dfg/DFGJITCodeGenerator.h:
2747         (JSC::DFG::callOperation):
2748         * dfg/DFGOperations.cpp:
2749         * dfg/DFGOperations.h:
2750         * dfg/DFGSpeculativeJIT32_64.cpp:
2751         (JSC::DFG::SpeculativeJIT::compile):
2752         * dfg/DFGSpeculativeJIT64.cpp:
2753         (JSC::DFG::SpeculativeJIT::compile):
2754
2755 2011-11-07  Mark Hahnenberg  <mhahnenberg@apple.com>
2756
2757         De-virtualize JSObject::putWithAttributes
2758         https://bugs.webkit.org/show_bug.cgi?id=71716
2759
2760         Reviewed by Darin Adler.
2761
2762         Added putWithAttributes to the MethodTable, changed all the virtual 
2763         implementations of putWithAttributes to static ones, and replaced 
2764         all call sites with corresponding lookups in the MethodTable.
2765
2766         * API/JSObjectRef.cpp:
2767         (JSObjectSetProperty):
2768         * JavaScriptCore.exp:
2769         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
2770         * debugger/DebuggerActivation.cpp:
2771         (JSC::DebuggerActivation::putWithAttributes):
2772         * debugger/DebuggerActivation.h:
2773         * interpreter/Interpreter.cpp:
2774         (JSC::Interpreter::execute):
2775         * runtime/ClassInfo.h:
2776         * runtime/JSActivation.cpp:
2777         (JSC::JSActivation::putWithAttributes):
2778         * runtime/JSActivation.h:
2779         * runtime/JSCell.cpp:
2780         (JSC::JSCell::putWithAttributes):
2781         * runtime/JSCell.h:
2782         * runtime/JSGlobalObject.cpp:
2783         (JSC::JSGlobalObject::putWithAttributes):
2784         * runtime/JSGlobalObject.h:
2785         * runtime/JSObject.cpp:
2786         (JSC::JSObject::putWithAttributes):
2787         (JSC::putDescriptor):
2788         * runtime/JSObject.h:
2789         * runtime/JSStaticScopeObject.cpp:
2790         (JSC::JSStaticScopeObject::putWithAttributes):
2791         * runtime/JSStaticScopeObject.h:
2792         * runtime/JSVariableObject.cpp:
2793         (JSC::JSVariableObject::putWithAttributes):
2794         * runtime/JSVariableObject.h:
2795
2796 2011-11-07  Dmitry Lomov  <dslomov@google.com>
2797
2798         Unreviewed. Release build fix.
2799
2800         * parser/Lexer.cpp:
2801         (JSC::assertCharIsIn8BitRange):
2802
2803 2011-11-07  Filip Pizlo  <fpizlo@apple.com>
2804
2805         Switch the value profiler back to 8 buckets, because we suspect that while this
2806         is more expensive it's also more stable.
2807
2808         Rubber stamped by Geoff Garen.
2809
2810         * bytecode/ValueProfile.h:
2811
2812 2011-11-07  Andrew Wason  <rectalogic@rectalogic.com>
2813
2814         Uninitialized Heap member var
2815         https://bugs.webkit.org/show_bug.cgi?id=71722
2816
2817         Reviewed by Filip Pizlo.
2818
2819         * heap/Heap.cpp:
2820         (JSC::Heap::Heap): Initialize m_blockFreeingThreadShouldQuit
2821
2822 2011-11-07  Yuqiang Xian  <yuqiang.xian@intel.com>
2823
2824         DFG 32_64 - registers cannot be reused arbitrarily if speculation failures are possible
2825         https://bugs.webkit.org/show_bug.cgi?id=71684
2826
2827         Reviewed by Filip Pizlo.
2828
2829         Currently in DFG JIT, we try to reuse the physical register of an
2830         operand for temporary usage if the current use of the operand is the
2831         last use. But sometimes this can be wrong, for example if there are
2832         possible speculation failures and we need to fallback to baseline JIT,
2833         the value of the operand which is supposed to be hold in the physical
2834         register can be modified by register reusing. The fixes the last
2835         inspector failures in layout test on Mac 32-bit if switching on DFG.
2836
2837         * dfg/DFGSpeculativeJIT32_64.cpp:
2838         (JSC::DFG::SpeculativeJIT::emitObjectOrOtherBranch):
2839         (JSC::DFG::SpeculativeJIT::compile):
2840
2841 2011-11-07  Ryosuke Niwa  <rniwa@webkit.org>
2842
2843         REGRESSION(r99436): Broke Snow Leopard debug build
2844         https://bugs.webkit.org/show_bug.cgi?id=71713
2845
2846         Reviewed by Darin Adler.
2847
2848         Put the assertion in a template and use template specialization
2849         to avoid warning when instantiated with UChar or LChar.
2850
2851         In the long term, we should have traits for unsigned integral types
2852         and use that to specialize template instead of specializing it for UChar and LChar.
2853
2854         * parser/Lexer.cpp:
2855         (JSC::assertCharIsIn8BitRange):
2856         (JSC::::append8):
2857
2858 2011-11-07  ChangSeok Oh  <shivamidow@gmail.com>
2859
2860         [EFL] Support requestAnimationFrame API
2861         https://bugs.webkit.org/show_bug.cgi?id=67112
2862
2863         Reviewed by Andreas Kling.
2864
2865         Let EFL port use REQUEST_ANIMATION_FRAME_TIMER.
2866
2867         * wtf/Platform.h:
2868
2869 2011-11-07  Michael Saboff  <msaboff@apple.com>
2870
2871         Towards 8 Bit Strings: Templatize JSC::Lexer class by character type
2872         https://bugs.webkit.org/show_bug.cgi?id=71331
2873
2874         Change the Lexer class to be a template class based on the character
2875         type of the source.  In the process updated the parseIdentifier()
2876         and parseString() methods to create 8 bit strings where possible.
2877         Also added some helper methods for accumulating temporary string
2878         data in the 8 and 16 bit vectors.
2879
2880         Changed the SourceProvider::data() virtual method to return a
2881         StringImpl* instead of a UChar*.
2882
2883         Updated the KeywordLookup generator to create code to match keywords
2884         for both 8 and 16 bit source strings.
2885
2886         Due to a compiler bug (<rdar://problem/10194295>) moved enum
2887         definition outside of Lexer class declaration.  Remove second enum
2888         no longer needed.
2889
2890         Reviewed by Darin Adler.
2891
2892         * KeywordLookupGenerator.py:
2893         * interpreter/Interpreter.cpp:
2894         (JSC::Interpreter::callEval):
2895         * parser/Lexer.cpp:
2896         (JSC::::Lexer):
2897         (JSC::::~Lexer):
2898         (JSC::::getInvalidCharMessage):
2899         (JSC::::currentCharacter):
2900         (JSC::::setCode):
2901         (JSC::::internalShift):
2902         (JSC::::shift):
2903         (JSC::::peek):
2904         (JSC::::getUnicodeCharacter):
2905         (JSC::::shiftLineTerminator):
2906         (JSC::::lastTokenWasRestrKeyword):
2907         (JSC::::record8):
2908         (JSC::::append8):
2909         (JSC::::append16):
2910         (JSC::::record16):
2911         (JSC::::parseIdentifier):
2912         (JSC::::parseIdentifierSlowCase):
2913         (JSC::::parseString):
2914         (JSC::::parseStringSlowCase):
2915         (JSC::::parseHex):
2916         (JSC::::parseOctal):
2917         (JSC::::parseDecimal):
2918         (JSC::::parseNumberAfterDecimalPoint):
2919         (JSC::::parseNumberAfterExponentIndicator):
2920         (JSC::::parseMultilineComment):
2921         (JSC::::nextTokenIsColon):
2922         (JSC::::lex):
2923         (JSC::::scanRegExp):
2924         (JSC::::skipRegExp):
2925         (JSC::::clear):
2926         (JSC::::sourceCode):
2927         * parser/Lexer.h:
2928         (JSC::Lexer::append16):
2929         (JSC::Lexer::currentOffset):
2930         (JSC::Lexer::setOffsetFromCharOffset):
2931         (JSC::::isWhiteSpace):
2932         (JSC::::isLineTerminator):
2933         (JSC::::convertHex):
2934         (JSC::::convertUnicode):
2935         (JSC::::makeIdentifier):
2936         (JSC::::setCodeStart):
2937         (JSC::::makeIdentifierLCharFromUChar):
2938         (JSC::::lexExpectIdentifier):
2939         * parser/Parser.cpp:
2940         (JSC::Parser::Parser):
2941         (JSC::Parser::parseProperty):
2942         (JSC::Parser::parseMemberExpression):
2943         * parser/Parser.h:
2944         (JSC::Parser::next):
2945         (JSC::Parser::nextExpectIdentifier):
2946         * parser/ParserArena.h:
2947         (JSC::IdentifierArena::makeIdentifier):
2948         (JSC::IdentifierArena::makeIdentifierLCharFromUChar):
2949         * parser/SourceCode.h:
2950         (JSC::SourceCode::subExpression):
2951         * parser/SourceProvider.h:
2952         (JSC::UStringSourceProvider::stringData):
2953         * parser/SourceProviderCache.h:
2954         * parser/SyntaxChecker.h:
2955         * runtime/FunctionPrototype.cpp:
2956         (JSC::insertSemicolonIfNeeded):
2957         * runtime/Identifier.cpp:
2958         (JSC::IdentifierTable::add):
2959         (JSC::IdentifierLCharFromUCharTranslator::hash):
2960         (JSC::IdentifierLCharFromUCharTranslator::equal):
2961         (JSC::IdentifierLCharFromUCharTranslator::translate):
2962         (JSC::Identifier::add8):
2963         * runtime/Identifier.h:
2964         (JSC::Identifier::Identifier):
2965         (JSC::Identifier::createLCharFromUChar):
2966         (JSC::Identifier::canUseSingleCharacterString):
2967         (JSC::IdentifierCharBufferTranslator::hash):
2968         (JSC::IdentifierCharBufferTranslator::equal):
2969         (JSC::IdentifierCharBufferTranslator::translate):
2970         (JSC::Identifier::add):
2971         (JSC::Identifier::equal):
2972         (JSC::IdentifierTable::add):
2973         * runtime/JSGlobalObjectFunctions.cpp:
2974         (JSC::decode):
2975         (JSC::parseIntOverflow):
2976         (JSC::globalFuncUnescape):
2977         * runtime/JSGlobalObjectFunctions.h:
2978         (JSC::parseIntOverflow):
2979         * runtime/LiteralParser.cpp:
2980         (JSC::LiteralParser::tryJSONPParse):
2981         (JSC::LiteralParser::Lexer::lexString):
2982         * wtf/text/StringImpl.h:
2983
2984 2011-11-07  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2985
2986         [Qt] Put the jsc binary in 'bin' instead of leaving it deep in the build tree
2987
2988         Allows us to not package up the whole Source/JavaScriptCore directory for the
2989         buildbots.
2990
2991         Reviewed-by Simon Hausmann.
2992
2993         * jsc.pro:
2994
2995 2011-11-06  Filip Pizlo  <fpizlo@apple.com>
2996
2997         REGRESSION(r99374): GTK+ build of the jsc binary doesn't like the call
2998         to initializeMainThread, and crashes
2999         https://bugs.webkit.org/show_bug.cgi?id=71643
3000
3001         Reviewed by Sam Weinig.
3002
3003         * jsc.cpp:
3004         (main):
3005
3006 2011-11-06  Sam Weinig  <sam@webkit.org>
3007
3008         Add space missing from some class declarations
3009         https://bugs.webkit.org/show_bug.cgi?id=71632
3010
3011         Reviewed by Anders Carlsson.
3012
3013         * assembler/AssemblerBufferWithConstantPool.h:
3014         * bytecode/CodeBlock.h:
3015         * dfg/DFGVariableAccessData.h:
3016         * heap/VTableSpectrum.h:
3017         * jit/ExecutableAllocator.cpp:
3018         * jit/ExecutableAllocatorFixedVMPool.cpp:
3019         * wtf/MetaAllocatorHandle.h:
3020         * wtf/UnionFind.h:
3021
3022 2011-11-06  Sam Weinig  <sam@webkit.org>
3023
3024         Allow use of FINAL in JavaScriptCore
3025         https://bugs.webkit.org/show_bug.cgi?id=71630
3026
3027         Reviewed by Anders Carlsson.
3028
3029         * Configurations/Base.xcconfig:
3030         Don't warn about C++11 extensions used in C++98 mode.
3031
3032 2011-11-05  Filip Pizlo  <fpizlo@apple.com>
3033
3034         Value profiling should just use two buckets
3035         https://bugs.webkit.org/show_bug.cgi?id=71619
3036
3037         Reviewed by Gavin Barraclough.
3038         
3039         Added one more configuration options (like Heuristics::minimumOptimizationDelay),
3040         improved debugging in JIT optimization support, changed the number of buckets
3041         in the value profile from 9 to 2, and wrote a more optimal value profiling path
3042         in the old JIT to take advantage of this. It's still possible to play around with
3043         larger numbers of buckets, and we should probably keep this for a little while
3044         until we convince ourselves that using just two buckets is the right call.
3045
3046         * bytecode/CodeBlock.cpp:
3047         (JSC::CodeBlock::shouldOptimizeNow):
3048         * bytecode/ValueProfile.h:
3049         * jit/JITInlineMethods.h:
3050         (JSC::JIT::emitValueProfilingSite):
3051         * jit/JITStubs.cpp:
3052         (JSC::DEFINE_STUB_FUNCTION):
3053         * runtime/Heuristics.cpp:
3054         (JSC::Heuristics::initializeHeuristics):
3055         * runtime/Heuristics.h:
3056
3057 2011-11-03  Filip Pizlo  <fpizlo@apple.com>
3058
3059         JSC should be able to sample itself in a more flexible way than just sampling flags
3060         https://bugs.webkit.org/show_bug.cgi?id=71522
3061
3062         Reviewed by Gavin Barraclough.
3063         
3064         Added a construct that looks like SamplingRegion samplingRegion("name").
3065
3066         * JavaScriptCore.exp:
3067         * JavaScriptCore.xcodeproj/project.pbxproj:
3068         * bytecode/SamplingTool.cpp:
3069         (JSC::SamplingRegion::Locker::Locker):
3070         (JSC::SamplingRegion::Locker::~Locker):
3071         (JSC::SamplingRegion::sample):
3072         (JSC::SamplingRegion::dump):
3073         (JSC::SamplingRegion::dumpInternal):
3074         (JSC::SamplingThread::threadStartFunc):
3075         * bytecode/SamplingTool.h:
3076         (JSC::SamplingRegion::SamplingRegion):
3077         (JSC::SamplingRegion::~SamplingRegion):
3078         (JSC::SamplingRegion::exchangeCurrent):
3079         * bytecompiler/BytecodeGenerator.cpp:
3080         (JSC::BytecodeGenerator::generate):
3081         * dfg/DFGDriver.cpp:
3082         (JSC::DFG::compile):
3083         * heap/Heap.cpp:
3084         (JSC::Heap::markRoots):
3085         (JSC::Heap::collect):
3086         * heap/VTableSpectrum.cpp:
3087         (JSC::VTableSpectrum::countVPtr):
3088         (JSC::VTableSpectrum::dump):
3089         * heap/VTableSpectrum.h:
3090         * jsc.cpp:
3091         (main):
3092         (runWithScripts):
3093         * parser/Parser.h:
3094         (JSC::parse):
3095         * runtime/Executable.cpp:
3096         (JSC::EvalExecutable::compileInternal):
3097         (JSC::ProgramExecutable::compileInternal):
3098         (JSC::FunctionExecutable::compileForCallInternal):
3099         (JSC::FunctionExecutable::compileForConstructInternal):
3100         * wtf/Atomics.h:
3101         (WTF::weakCompareAndSwap):
3102         * wtf/Platform.h:
3103         * wtf/Spectrum.h: Added.
3104         (WTF::Spectrum::Spectrum):
3105         (WTF::Spectrum::add):
3106         (WTF::Spectrum::get):
3107         (WTF::Spectrum::begin):
3108         (WTF::Spectrum::end):
3109         (WTF::Spectrum::KeyAndCount::KeyAndCount):
3110         (WTF::Spectrum::KeyAndCount::operator<):
3111         (WTF::Spectrum::buildList):
3112         * wtf/wtf.pri:
3113
3114 2011-11-05  Sam Weinig  <sam@webkit.org>
3115
3116         Fix windows build.
3117
3118         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3119
3120 2011-11-04  Sam Weinig  <sam@webkit.org>
3121
3122         Reduce the number of putWithAttributes
3123         https://bugs.webkit.org/show_bug.cgi?id=71597
3124
3125         Reviewed by Adam Roben.
3126
3127         * JavaScriptCore.exp:
3128         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3129         Remove exports of removed functions.
3130
3131         * runtime/JSActivation.cpp:
3132         (JSC::JSActivation::putWithAttributes):
3133         Calling the overload without the extra parameters does the same thing.
3134
3135         * runtime/JSObject.cpp:
3136         (JSC::JSObject::putWithAttributes):
3137         * runtime/JSObject.h:
3138         Remove four unused JSObject::putWithAttributes overloads and make one of the remaining
3139         two overloads not virtual, since no one overrides it.
3140
3141 2011-11-04  Pratik Solanki  <psolanki@apple.com>
3142
3143         sqrtDouble and andnotDouble should be declared noreturn
3144         https://bugs.webkit.org/show_bug.cgi?id=71592
3145
3146         Reviewed by Sam Weinig.
3147
3148         * assembler/MacroAssemblerARMv7.h:
3149
3150 2011-11-04  Mark Hahnenberg  <mhahnenberg@apple.com>
3151
3152         De-virtualize JSObject::hasInstance
3153         https://bugs.webkit.org/show_bug.cgi?id=71430
3154
3155         Reviewed by Darin Adler.
3156
3157         Added hasInstance to the MethodTable, changed all the virtual 
3158         implementations of hasInstance to static ones, and replaced 
3159         all call sites with corresponding lookups in the MethodTable.
3160
3161         * API/JSCallbackObject.h:
3162         * API/JSCallbackObjectFunctions.h:
3163         (JSC::::hasInstance):
3164         * API/JSValueRef.cpp:
3165         (JSValueIsInstanceOfConstructor):
3166         * JavaScriptCore.exp:
3167         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3168         * interpreter/Interpreter.cpp:
3169         (JSC::Interpreter::privateExecute):
3170         * jit/JITStubs.cpp:
3171         (JSC::DEFINE_STUB_FUNCTION):
3172         * runtime/ClassInfo.h:
3173         * runtime/JSBoundFunction.cpp:
3174         (JSC::JSBoundFunction::hasInstance):
3175         * runtime/JSBoundFunction.h:
3176         * runtime/JSCell.cpp:
3177         (JSC::JSCell::hasInstance):
3178         * runtime/JSCell.h:
3179         * runtime/JSObject.cpp:
3180         (JSC::JSObject::hasInstance):
3181         * runtime/JSObject.h:
3182
3183 2011-11-04  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
3184
3185         [Qt] Refactor and clean up the qmake build system
3186
3187         The qmake build system has accumulated a bit of cruft and redundancy
3188         over time. There's also a fairly tight coupling between how to build
3189         the various targets, and _what_ to build, making it harder to add new
3190         rules or sources. This patch aims to elevate these issues somewhat.
3191
3192         This is a short-list of the changes:
3193
3194           * The rules for how to build targets are now mostly contained as
3195             prf-files in Tools/qmake/mkspecs/features. Using mkspecs also
3196             allows us to do pre- and post-processing of each project file,
3197             which helps to clean up the actual project files.
3198
3199           * Derived sources are no longer generated as a separate make-step
3200             but is part of each target's project file as a subdir. Makefile
3201             rules are used to ensure that we run make on the derived sources
3202             before running qmake on the actual target makefile. This makes
3203             it easier to keep a proper dependency between derived sources
3204             and the target.
3205
3206           * We use GNU make and the compiler to generate dependencies on
3207             UNIX-based systems running Qt 5. This allows us to lessen the
3208             need to run qmake, which should reduce compile time.
3209
3210           * WebKit2 is now build by default if building with Qt 5. It can
3211             be disabled by passing --no-webkit2 to build-webkit.
3212
3213         The result of these changes are hopefully a cleaner and easier
3214         build system to modify, and faster build times due to no longer
3215         running qmake on every single build. It's also a first step
3216         towards possibly generating the list of sources using another
3217         build system.
3218
3219         https://bugs.webkit.org/show_bug.cgi?id=71222
3220
3221         Reviewed by Simon Hausmann.
3222
3223         * DerivedSources.pri: Added.
3224         * DerivedSources.pro: Removed.
3225         * JavaScriptCore.pro:
3226         * Target.pri: Copied from Source/JavaScriptCore/JavaScriptCore.pro.
3227         * headers.pri: Removed.
3228         * jsc.pro:
3229         * wtf/wtf.pri:
3230         * yarr/yarr.pri:
3231
3232 2011-11-04  Yuqiang Xian  <yuqiang.xian@intel.com>
3233
3234         More code clean-up in DFG 32_64
3235         https://bugs.webkit.org/show_bug.cgi?id=71540
3236
3237         Remove unnecessary code duplications, and fix compilation warnings.
3238
3239         Reviewed by Gavin Barraclough.
3240
3241         * dfg/DFGJITCompiler.cpp:
3242         (JSC::DFG::JITCompiler::emitCount):
3243         (JSC::DFG::JITCompiler::setSamplingFlag):
3244         (JSC::DFG::JITCompiler::clearSamplingFlag):
3245         (JSC::DFG::JITCompiler::jitAssertIsCell):
3246         * dfg/DFGJITCompiler32_64.cpp:
3247         * dfg/DFGSpeculativeJIT32_64.cpp:
3248         (JSC::DFG::SpeculativeJIT::compile):
3249
3250 2011-11-04  Csaba Osztrogonác  <ossy@webkit.org>
3251
3252         De-virtualize JSObject::hasInstance
3253         https://bugs.webkit.org/show_bug.cgi?id=71430
3254
3255         Unreviewed rolling out r99238, because it made a test crash on all platform.
3256
3257         * API/JSCallbackObject.h:
3258         * API/JSCallbackObjectFunctions.h:
3259         (JSC::::hasInstance):
3260         * API/JSValueRef.cpp:
3261         (JSValueIsInstanceOfConstructor):
3262         * JavaScriptCore.exp:
3263         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3264         * interpreter/Interpreter.cpp:
3265         (JSC::Interpreter::privateExecute):
3266         * jit/JITStubs.cpp:
3267         (JSC::DEFINE_STUB_FUNCTION):
3268         * runtime/ClassInfo.h:
3269         * runtime/JSBoundFunction.cpp:
3270         (JSC::JSBoundFunction::hasInstance):
3271         * runtime/JSBoundFunction.h:
3272         * runtime/JSCell.cpp:
3273         * runtime/JSCell.h:
3274         * runtime/JSObject.cpp:
3275         (JSC::JSObject::hasInstance):
3276         * runtime/JSObject.h:
3277
3278 2011-11-03  Mark Hahnenberg  <mhahnenberg@apple.com>
3279
3280         De-virtualize JSObject::getPropertyNames
3281         https://bugs.webkit.org/show_bug.cgi?id=71306
3282
3283         Reviewed by Darin Adler.
3284
3285         Added getPropertyNames to the MethodTable, changed all the virtual 
3286         implementations of getPropertyNames to static ones, and replaced 
3287         all call sites with corresponding lookups in the MethodTable.
3288
3289         * API/JSObjectRef.cpp:
3290         (JSObjectCopyPropertyNames):
3291         * JavaScriptCore.exp:
3292         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3293         * debugger/DebuggerActivation.cpp:
3294         (JSC::DebuggerActivation::getOwnPropertyNames):
3295         * runtime/ClassInfo.h:
3296         * runtime/JSCell.cpp:
3297         (JSC::JSCell::getPropertyNames):
3298         * runtime/JSCell.h:
3299         * runtime/JSObject.cpp:
3300         (JSC::JSObject::getPropertyNames):
3301         (JSC::JSObject::getOwnPropertyNames):
3302         * runtime/JSObject.h:
3303         * runtime/JSPropertyNameIterator.cpp:
3304         (JSC::JSPropertyNameIterator::create):
3305         * runtime/ScopeChain.cpp:
3306         (JSC::ScopeChainNode::print):
3307         * runtime/Structure.cpp:
3308         (JSC::Structure::getPropertyNamesFromStructure):
3309         * runtime/Structure.h:
3310
3311 2011-11-03  Darin Adler  <darin@apple.com>
3312
3313         Change remaining callers of releaseRef to call leakRef
3314         https://bugs.webkit.org/show_bug.cgi?id=71422
3315
3316         * wtf/text/AtomicString.cpp:
3317         (WTF::HashAndUTF8CharactersTranslator::translate): Use leakRef.
3318
3319 2011-11-02  Darin Adler  <darin@apple.com>
3320
3321         Change remaining callers of releaseRef to call leakRef
3322         https://bugs.webkit.org/show_bug.cgi?id=71422
3323
3324         * wtf/text/AtomicString.cpp:
3325         (WTF::HashAndUTF8CharactersTranslator::translate): Use leakRef.
3326
3327 2011-11-03  Mark Hahnenberg  <mhahnenberg@apple.com>
3328
3329         De-virtualize JSObject::hasInstance
3330         https://bugs.webkit.org/show_bug.cgi?id=71430
3331
3332         Reviewed by Darin Adler.
3333
3334         Added hasInstance to the MethodTable, changed all the virtual 
3335         implementations of hasInstance to static ones, and replaced 
3336         all call sites with corresponding lookups in the MethodTable.
3337
3338         * API/JSCallbackObject.h:
3339         * API/JSCallbackObjectFunctions.h:
3340         (JSC::::hasInstance):
3341         * API/JSValueRef.cpp:
3342         (JSValueIsInstanceOfConstructor):
3343         * JavaScriptCore.exp:
3344         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3345         * interpreter/Interpreter.cpp:
3346         (JSC::Interpreter::privateExecute):
3347         * jit/JITStubs.cpp:
3348         (JSC::DEFINE_STUB_FUNCTION):
3349         * runtime/ClassInfo.h:
3350         * runtime/JSBoundFunction.cpp:
3351         (JSC::JSBoundFunction::hasInstance):
3352         * runtime/JSBoundFunction.h:
3353         * runtime/JSCell.cpp:
3354         (JSC::JSCell::hasInstance):
3355         * runtime/JSCell.h:
3356         * runtime/JSObject.cpp:
3357         (JSC::JSObject::hasInstance):
3358         * runtime/JSObject.h:
3359
3360 2011-11-03  Filip Pizlo  <fpizlo@apple.com>
3361
3362         JIT-specific code should be able to refer to register types even on JIT-disabled builds
3363         https://bugs.webkit.org/show_bug.cgi?id=71498
3364
3365         Reviewed by Gavin Barraclough.
3366
3367         * assembler/MacroAssembler.h:
3368         (MacroAssembler::MacroAssembler):
3369
3370 2011-11-03  Mark Hahnenberg  <mhahnenberg@apple.com>
3371
3372         De-virtualize JSObject::className
3373         https://bugs.webkit.org/show_bug.cgi?id=71428
3374
3375         Reviewed by Sam Weinig.
3376
3377         Added className to the MethodTable, changed all the virtual 
3378         implementations of className to static ones, and replaced 
3379         all call sites with corresponding lookups in the MethodTable.
3380
3381         * API/JSCallbackObject.h:
3382         * API/JSCallbackObjectFunctions.h:
3383         (JSC::::className):
3384         * JavaScriptCore.exp:
3385         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3386         * debugger/DebuggerActivation.cpp:
3387         (JSC::DebuggerActivation::className):
3388         * debugger/DebuggerActivation.h:
3389         * jsc.cpp:
3390         (GlobalObject::createStructure):
3391         * profiler/Profiler.cpp:
3392         (JSC::Profiler::createCallIdentifier):
3393         * runtime/ClassInfo.h:
3394         * runtime/JSCell.cpp:
3395         (JSC::JSCell::className):
3396         * runtime/JSCell.h:
3397         * runtime/JSObject.cpp:
3398         (JSC::JSObject::className):
3399         * runtime/JSObject.h:
3400         * runtime/ObjectPrototype.cpp:
3401         (JSC::objectProtoFuncToString):
3402         * testRegExp.cpp:
3403         (GlobalObject::createStructure):
3404
3405 2011-11-02  Jer Noble  <jer.noble@apple.com>
3406
3407         Add Clock class and platform-specific implementations.
3408         https://bugs.webkit.org/show_bug.cgi?id=71341
3409
3410         Reviewed by Sam Weinig.
3411
3412         Add WTF_USE_COREAUDIO macro for use by PlatformClockCA.
3413
3414         * wtf/Platform.h:
3415
3416 2011-11-03  Pavel Feldman  <pfeldman@chromium.org>
3417
3418         Not reviewed: fixing win build. step2.
3419
3420         * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
3421
3422 2011-11-03  Pavel Feldman  <pfeldman@chromium.org>