cd54fa0b2b23a8c60e0a2e59f4c0cc699d06527b
[WebKit-https.git] / JSTests / ChangeLog
1 2017-01-10  Skachkov Oleksandr  <gskachkov@gmail.com>
2
3         Calling async arrow function which is in a class's member function will cause error
4         https://bugs.webkit.org/show_bug.cgi?id=166879
5
6         Reviewed by Saam Barati.
7
8         * stress/async-arrow-functions-lexical-binding-in-class.js: Added.
9         (shouldBe):
10         (shouldBeAsync):
11         (BaseClass.prototype.baseClassValue):
12         (BaseClass.prototype.get property):
13         (BaseClass):
14         (runSomething):
15         (ChildClass.prototype.classValue):
16         (ChildClass.prototype.get classProperty):
17         (ChildClass.prototype.asyncValueExp):
18         (ChildClass.prototype.asyncValueBody):
19         (ChildClass.prototype.asyncThisPropExp):
20         (ChildClass.prototype.asyncThisPropBody):
21         (ChildClass.prototype.asyncThisPropInEvalExp):
22         (ChildClass.prototype.asyncThisPropInEvalBody):
23         (ChildClass.prototype.asyncThisValueExp):
24         (ChildClass.prototype.asyncThisValueBody):
25         (ChildClass.prototype.asyncThisValueInEvalExp):
26         (ChildClass.prototype.asyncThisValueInEvalBody):
27         (ChildClass):
28         (ChildClass2):
29         (ChildClass2.prototype.classValue):
30         (ChildClass2.prototype.get classProperty):
31         * stress/async-arrow-functions-lexical-super-binding.js:
32
33 2017-01-09  Yusuke Suzuki  <utatane.tea@gmail.com>
34
35         [JSC] Prototype dynamic-import
36         https://bugs.webkit.org/show_bug.cgi?id=165724
37
38         Reviewed by Saam Barati.
39
40         * stress/import-basic.js: Added.
41         (async.async.load):
42         (async):
43         (catch):
44         * stress/import-from-eval.js: Added.
45         (async):
46         (catch):
47         * stress/import-syntax.js: Added.
48         (testSyntaxError):
49         * stress/import-tests/cocoa.js: Added.
50         (export.Cocoa):
51         (export.hello):
52         * stress/import-tests/multiple.js: Added.
53         (export.result):
54         * stress/import-tests/multiple2.js: Added.
55         (export.ok):
56         * stress/import-tests/should.js: Added.
57         (export.shouldBe):
58         (export.shouldThrow):
59         * stress/modules-syntax-error.js:
60
61 2017-01-09  Commit Queue  <commit-queue@webkit.org>
62
63         Unreviewed, rolling out r210476.
64         https://bugs.webkit.org/show_bug.cgi?id=166859
65
66         "4% JSBench regression" (Requested by keith_mi_ on #webkit).
67
68         Reverted changeset:
69
70         "Add a slice intrinsic to the DFG/FTL"
71         https://bugs.webkit.org/show_bug.cgi?id=166707
72         http://trac.webkit.org/changeset/210476
73
74 2017-01-06  Saam Barati  <sbarati@apple.com>
75
76         Add a slice intrinsic to the DFG/FTL
77         https://bugs.webkit.org/show_bug.cgi?id=166707
78
79         Reviewed by Filip Pizlo.
80
81         * stress/array-slice-intrinsic.js: Added.
82         (assert):
83         (shallowEq):
84         (runTest1):
85         (runTest2):
86         * stress/array-slice-jettison-on-constructor-change.js: Added.
87         (assert):
88         (runTest1):
89         (runTest2):
90         (addRandomProperties):
91         (runTests):
92         * stress/array-slice-osr-exit-2.js: Added.
93         (assert):
94         (Foo):
95         (shallowEq):
96         (runTest1):
97         (runTest2):
98         (addRandomProperties):
99         (runTests):
100         * stress/array-slice-osr-exit.js: Added.
101         (assert):
102         (Foo):
103         (shallowEq):
104         (runTest1):
105         (runTest2):
106         (addRandomProperties):
107         (runTests):
108
109 2017-01-06  Michael Saboff  <msaboff@apple.com>
110
111         @putByValDirect in Array.of and Array.from overwrites non-writable/configurable properties
112         https://bugs.webkit.org/show_bug.cgi?id=153486
113
114         Reviewed by Saam Barati.
115
116         New regression test.
117
118         * stress/regress-153486.js: Added.
119         (shouldEqual):
120         (makeUnwriteableUnconfigurableObject):
121         (testArrayOf):
122         (testArrayFrom):
123         (runTest):
124
125 2016-12-30  Filip Pizlo  <fpizlo@apple.com>
126
127         DeferGC::~DeferGC should be super cheap
128         https://bugs.webkit.org/show_bug.cgi?id=166626
129
130         Reviewed by Saam Barati.
131
132         * stress/slow-path-generator-updating-current-node-dfg.js:
133         * stress/unshift-array-storage.js:
134
135 2017-01-04  JF Bastien  <jfbastien@apple.com>
136
137         WebAssembly: sections with the same name are allowed
138         https://bugs.webkit.org/show_bug.cgi?id=166708
139
140         Reviewed by Saam Barati.
141
142         * wasm/self-test/test_BuilderJSON.js:
143         (SectionsWithSameCustomName):
144
145 2017-01-04  Saam Barati  <sbarati@apple.com>
146
147         stress/spread-calling.js timing out on the bots
148         https://bugs.webkit.org/show_bug.cgi?id=166689
149         <rdar://problem/29779182>
150
151         Reviewed by Mark Lam.
152
153         * stress/spread-calling.js:
154
155 2017-01-04  JF Bastien  <jfbastien@apple.com>
156
157         WebAssembly JS API: add Module.sections
158         https://bugs.webkit.org/show_bug.cgi?id=165159
159         <rdar://problem/29760326>
160
161         Reviewed by Mark Lam.
162
163         As described here: https://github.com/WebAssembly/design/blob/master/JS.md#webassemblymodulecustomsections
164
165         * wasm/Builder.js: allow custom sections to be duplicated
166         * wasm/js-api/Module.customSection.js: Added.
167         (assert.throws.WebAssembly.Module.prototype.customSections):
168         (assert.eq):
169
170 2017-01-04  Saam Barati  <sbarati@apple.com>
171
172         We don't properly handle exceptions inside the nativeCallTrampoline macro in the LLInt
173         https://bugs.webkit.org/show_bug.cgi?id=163720
174
175         Reviewed by Mark Lam.
176
177         * stress/bound-function-tail-call-with-exception.js: Added.
178         (bar):
179         (foo):
180         (catch):
181
182 2017-01-03  JF Bastien  <jfbastien@apple.com>
183
184         WebAssembly JS API: check and test in-call / out-call values
185         https://bugs.webkit.org/show_bug.cgi?id=164876
186         <rdar://problem/29844107>
187
188         Reviewed by Saam Barati.
189
190         * wasm.yaml:
191         * wasm/assert.js: add an assert for NaN comparison
192         * wasm/fuzz/export-function.js: Added. Generate random wasm export
193         signatures, and call them with random parameters.
194         (const.paramExporter):
195         (const.setBuffer):
196         (const.types.generate):
197         (generate):
198         * wasm/js-api/export-arity.js: Added.
199         (const.paramExporter): Test that mismatched arities when JS calls
200         wasm follow the defined semantics: i32 is 0, f32 / f64 are NaN.
201         https://github.com/WebAssembly/design/blob/master/JS.md#exported-function-exotic-objects
202         * wasm/js-api/export-void-is-undef.js: Added. Test that "void"
203         wasm functions return "undefined" in JS.
204
205 2017-01-02  JF Bastien  <jfbastien@apple.com>
206
207         WebAssembly: handle and optimize wasm export → wasm import calls
208         https://bugs.webkit.org/show_bug.cgi?id=165282
209
210         Reviewed by Saam Barati.
211
212         * wasm/Builder.js: Add a Proxy to Builder.js, which intercepts
213         unknown property lookups. This creates way better error messages
214         on typos than 'undefined is not a function', which happens
215         semi-frequently as I typo opcode names (and which one is a typo is
216         hard to find because we chain builders).
217         (const._isValidValue):
218         (get target):
219         (const._importFunctionContinuation):
220         (const._importMemoryContinuation):
221         (const._importTableContinuation):
222         (const._exportFunctionContinuation):
223         (export.default.Builder.prototype._registerSectionBuilders.const.section.in.WASM.description.section.switch.section.case.string_appeared_here.this.section):
224         (export.default.Builder.prototype._registerSectionBuilders.this.Unknown):
225         * wasm/LowLevelBinary.js: Add limited support for var{u}int64 (only the 32-bit values)
226         (export.default.LowLevelBinary.prototype.varint32):
227         (export.default.LowLevelBinary.prototype.varuint64):
228         (export.default.LowLevelBinary.prototype.varint64):
229         * wasm/function-tests/exceptions.js: update error message
230         * wasm/function-tests/trap-load.js: update error message
231         * wasm/function-tests/trap-store.js: update error message
232         * wasm/js-api/wasm-to-wasm-bad-signature.js: Added. Test a bunch of bad wasm->wasm import signatures
233         (const.makeImportee.signature.switch):
234         (BadSignatureDropStartParams):
235         * wasm/js-api/wasm-to-wasm.js: Added. Test 64-bit wasm->wasm import calls
236         (const.callerModule):
237         (const.calleeModule):
238         (WasmToWasm):
239
240 2017-01-02  Saam Barati  <sbarati@apple.com>
241
242         WebAssembly: Some loads don't take into account the offset
243         https://bugs.webkit.org/show_bug.cgi?id=166616
244         <rdar://problem/29841541>
245
246         Reviewed by Keith Miller.
247
248         * wasm/function-tests/load-offset.js: Added.
249
250 2016-12-29  Saam Barati  <sbarati@apple.com>
251
252         WebAssembly: Rebase spec-tests now that wabt has been updated to produce certain kinds of invalid modules
253         https://bugs.webkit.org/show_bug.cgi?id=166491
254         <rdar://problem/29814999>
255
256         Reviewed by Yusuke Suzuki.
257
258         Based off these revisions:
259         - spec: b055d01ea1dfdd7a5231ae779095435f836de97f
260         - wabt: d0d44702c753f851b094615298a2f4d4e3c21035
261
262         The reason for the rebase is that wabt was updated to stop
263         silently rejecting invalid modules. This was needed because
264         some of the spec tests check to make sure that the module
265         is invalid, but wabt was silently ignoring the errors and
266         generating valid modules:
267         https://github.com/WebAssembly/wabt/issues/256
268
269         * wasm.yaml:
270         * wasm/spec-tests/address.wast.js:
271         * wasm/spec-tests/binary.wast.js:
272         * wasm/spec-tests/block.wast.js:
273         * wasm/spec-tests/br.wast.js:
274         * wasm/spec-tests/br_if.wast.js:
275         * wasm/spec-tests/br_table.wast.js:
276         * wasm/spec-tests/break-drop.wast.js:
277         * wasm/spec-tests/call.wast.js:
278         * wasm/spec-tests/call_indirect.wast.js:
279         * wasm/spec-tests/comments.wast.js:
280         * wasm/spec-tests/conversions.wast.js:
281         * wasm/spec-tests/custom_section.wast.js:
282         * wasm/spec-tests/endianness.wast.js:
283         * wasm/spec-tests/exports.wast.js:
284         * wasm/spec-tests/f32.wast.js:
285         * wasm/spec-tests/f32_cmp.wast.js:
286         * wasm/spec-tests/f64.wast.js:
287         * wasm/spec-tests/f64_cmp.wast.js:
288         * wasm/spec-tests/fac.wast.js:
289         * wasm/spec-tests/float_exprs.wast.js:
290         * wasm/spec-tests/float_literals.wast.js:
291         * wasm/spec-tests/float_memory.wast.js:
292         * wasm/spec-tests/float_misc.wast.js:
293         * wasm/spec-tests/forward.wast.js:
294         * wasm/spec-tests/func.wast.js:
295         * wasm/spec-tests/func_ptrs.wast.js:
296         * wasm/spec-tests/get_local.wast.js:
297         * wasm/spec-tests/globals.wast.js:
298         * wasm/spec-tests/i32.wast.js:
299         * wasm/spec-tests/i64.wast.js:
300         * wasm/spec-tests/imports.wast.js:
301         * wasm/spec-tests/int_exprs.wast.js:
302         * wasm/spec-tests/int_literals.wast.js:
303         * wasm/spec-tests/left-to-right.wast.js:
304         * wasm/spec-tests/linking.wast.js:
305         * wasm/spec-tests/loop.wast.js:
306         * wasm/spec-tests/memory.wast.js:
307         * wasm/spec-tests/memory_redundancy.wast.js:
308         * wasm/spec-tests/memory_trap.wast.js:
309         * wasm/spec-tests/names.wast.js:
310         * wasm/spec-tests/nop.wast.js:
311         * wasm/spec-tests/resizing.wast.js:
312         * wasm/spec-tests/return.wast.js:
313         * wasm/spec-tests/select.wast.js:
314         * wasm/spec-tests/set_local.wast.js:
315         * wasm/spec-tests/skip-stack-guard-page.wast.js:
316         * wasm/spec-tests/stack.wast.js:
317         * wasm/spec-tests/start.wast.js:
318         * wasm/spec-tests/store_retval.wast.js:
319         * wasm/spec-tests/switch.wast.js:
320         * wasm/spec-tests/tee_local.wast.js:
321         * wasm/spec-tests/traps.wast.js:
322         * wasm/spec-tests/typecheck.wast.js:
323         * wasm/spec-tests/unreachable.wast.js:
324         * wasm/spec-tests/unwind.wast.js:
325
326 2016-12-28  Saam Barati  <sbarati@apple.com>
327
328         WebAssembly: Don't allow duplicate export names
329         https://bugs.webkit.org/show_bug.cgi?id=166490
330         <rdar://problem/29815000>
331
332         Reviewed by Keith Miller.
333
334         * wasm.yaml:
335         * wasm/function-tests/invalid-duplicate-export.js: Added.
336
337 2016-12-28  Saam Barati  <sbarati@apple.com>
338
339         WebAssembly: Implement grow_memory and current_memory
340         https://bugs.webkit.org/show_bug.cgi?id=166448
341         <rdar://problem/29803676>
342
343         Reviewed by Keith Miller.
344
345         I rewrote some of the testWasmModuleFunctions that used Memory to use
346         the JS API since the jsc.cpp version can no longer use memory.
347
348         * wasm.yaml:
349         * wasm/function-tests/add-12.js:
350         (testWasmModuleFunctions):
351         * wasm/function-tests/br-if-loop-less-than.js:
352         (testWasmModuleFunctions):
353         * wasm/function-tests/brTableAsIf.js:
354         (testWasmModuleFunctions):
355         * wasm/function-tests/brTableManyValues.js:
356         (testWasmModuleFunctions):
357         * wasm/function-tests/brTableWithLoop.js:
358         (testWasmModuleFunctions):
359         * wasm/function-tests/dumb-eq-if-then-else.js:
360         * wasm/function-tests/eqz.js:
361         * wasm/function-tests/grow-memory-2.js: Added.
362         (const.func):
363         (assert.eq.instance.exports.foo):
364         * wasm/function-tests/grow-memory-3.js: Added.
365         * wasm/function-tests/grow-memory-4.js: Added.
366         (const.func):
367         * wasm/function-tests/grow-memory.js: Added.
368         (binaryShouldNotParse):
369         (assert.truthy):
370         (assert.eq):
371         (memory.grow):
372         * wasm/function-tests/i32-load.js:
373         (testWasmModuleFunctions):
374         * wasm/function-tests/i32-load8-s.js:
375         * wasm/function-tests/max.js:
376         * wasm/function-tests/min.js:
377         * wasm/js-api/memory-grow.js: Added.
378         (i.i):
379         (assertEq):
380         * wasm/js-api/test_memory.js:
381         * wasm/wasm.json:
382
383 2016-12-25  Yusuke Suzuki  <utatane.tea@gmail.com>
384
385         Propagate the source origin as much as possible
386         https://bugs.webkit.org/show_bug.cgi?id=166348
387
388         Reviewed by Darin Adler.
389
390         * stress/source-origin.js: Added.
391         (shouldBe):
392
393 2016-12-24  Caio Lima  <ticaiolima@gmail.com>
394
395         [test262] Fixing mapped arguments object property test case
396         https://bugs.webkit.org/show_bug.cgi?id=159398
397
398         Reviewed by Saam Barati.
399
400         * stress/arguments-bizarre-behaviour-disable-enumerability.js:
401         * stress/arguments-define-property.js: Added.
402         (assert):
403         (testProperties):
404         * stress/arguments-non-configurable.js: Added.
405         (assert):
406         (tryChangeNonConfigurableDescriptor):
407         (set tryChangeNonConfigurableDescriptor):
408         (tryChangeWritableOfNonConfigurableDescriptor):
409         * test262.yaml:
410
411 016-12-20  Caio Lima  <ticaiolima@gmail.com>
412
413         [test262] Fixing mapped arguments object property test case
414         https://bugs.webkit.org/show_bug.cgi?id=159398
415
416         Reviewed by .
417
418         * stress/arguments-bizarre-behaviour-disable-enumerability.js:
419         * stress/arguments-define-property.js: Added.
420         (assert):
421         (testProperties):
422         * stress/arguments-non-configurable.js: Added.
423         (assert):
424         (tryChangeNonConfigurableDescriptor):
425         (set tryChangeNonConfigurableDescriptor):
426         (tryChangeWritableOfNonConfigurableDescriptor):
427         * test262.yaml:
428
429 2016-12-23  Keith Miller  <keith_miller@apple.com>
430
431         WebAssembly: trap on bad division.
432         https://bugs.webkit.org/show_bug.cgi?id=164786
433
434         Reviewed by Mark Lam.
435
436         Also, mark conversions as passing.
437
438         * wasm.yaml:
439         * wasm/wasm.json:
440
441 2016-12-22  Keith Miller  <keith_miller@apple.com>
442
443         WebAssembly: Make spec-tests/f32.wast.js and spec-tests/f64.wast.js pass
444         https://bugs.webkit.org/show_bug.cgi?id=166447
445
446         Reviewed by Saam Barati.
447
448         * wasm.yaml:
449         * wasm/wasm.json:
450
451 2016-12-22  Saam Barati  <sbarati@apple.com>
452
453         WebAssembly: Make calling Wasm functions that returns or takes an i64 as a parameter an early exception
454         https://bugs.webkit.org/show_bug.cgi?id=166437
455         <rdar://problem/29793949>
456
457         Reviewed by Keith Miller.
458
459         * wasm.yaml:
460         * wasm/function-tests/i64-from-js-exceptions.js: Added.
461         (const.imp.import.sideEffects):
462         (assert.throws.instance.exports.foo.valueOf):
463
464 2016-12-22  Mark Lam  <mark.lam@apple.com>
465
466         De-duplicate finally blocks.
467         https://bugs.webkit.org/show_bug.cgi?id=160168
468
469         Reviewed by Saam Barati.
470
471         Re-landing r209952 with a few new tests added in test-finally.js.
472
473         * stress/deeply-nested-finallys.js: Copied from JSTests/stress/deeply-nested-finallys.js.
474         - Tests many levels of finally nesting.  This causes the old code to hang (and
475           crashes eventually) while trying to generate bytecode for the exponentially
476           duplicated finally blocks.  The new code completes this test almost instantly.
477
478         * stress/test-finally.js: Copied from JSTests/stress/test-finally.js.
479         - Tests control flow through various permutations of finally blocks.
480
481 2016-12-22  Saam Barati  <sbarati@apple.com>
482
483         WebAssembly: Make the spec-tests/address.wast.js test pass
484         https://bugs.webkit.org/show_bug.cgi?id=166429
485         <rdar://problem/29793220>
486
487         Reviewed by Keith Miller.
488
489         * wasm.yaml:
490
491 2016-12-22  Keith Miller  <keith_miller@apple.com>
492
493         WebAssembly: The validator should not allow unused stack entries at the end of a block
494         https://bugs.webkit.org/show_bug.cgi?id=166411
495
496         Reviewed by Saam Barati.
497
498         Test cleanup and enable new passing tests.
499
500         * wasm.yaml:
501         * wasm/function-tests/br-if-as-return.js:
502
503 2016-12-22  Saam Barati  <sbarati@apple.com>
504
505         WebAssembly: Make the spec-tests/start.wast.js test pass
506         https://bugs.webkit.org/show_bug.cgi?id=166416
507         <rdar://problem/29784532>
508
509         Reviewed by Yusuke Suzuki.
510
511         * wasm.yaml:
512
513 2016-12-21  Keith Miller  <keith_miller@apple.com>
514
515         WebAssembly: Fix decode floating point constants in unreachable code
516         https://bugs.webkit.org/show_bug.cgi?id=166400
517
518         Reviewed by Saam Barati.
519
520         * wasm.yaml:
521
522 2016-12-21  Keith Miller  <keith_miller@apple.com>
523
524         WebAssembly: Allow br, br_if, and br_table to act as a return
525         https://bugs.webkit.org/show_bug.cgi?id=166393
526
527         Reviewed by Saam Barati.
528
529         Add tests for breaks acting as returns and fix tests that
530         validate error messages.
531
532         * wasm/function-tests/br-as-return.js: Added.
533         * wasm/function-tests/br-if-as-return.js: Added.
534         * wasm/function-tests/br-table-as-return.js: Added.
535         * wasm/function-tests/if-no-else-non-void.js:
536         * wasm/function-tests/struct.js: Added.
537         * wasm/js-api/global-error.js:
538         (assert.throws):
539         * wasm/js-api/table.js:
540         (assert.throws):
541
542 2016-12-21  Saam Barati  <sbarati@apple.com>
543
544         WebAssembly: Import spec tests
545         https://bugs.webkit.org/show_bug.cgi?id=166395
546
547         Rubber stamped by Keith Miller.
548
549         This patch implements the Wasm spec's tests found here:
550         https://github.com/WebAssembly/spec/tree/master/interpreter/test
551         
552         These tests are in .wast s-epxression format. To convert
553         them to JS, I use a script from the wabt library, found here:
554         https://github.com/WebAssembly/wabt/blob/master/test/run-gen-spec-js.py
555         
556         I also added a script that automatically imports the tests as
557         JS files. The inputs to the script is the path to the Wasm spec
558         git repo and the path to the wabt git repo. This will make importing
559         new tests easy in the future.
560
561         The wasm spec imported is at commit: b055d01ea1dfdd7a5231ae779095435f836de97f
562         The wabt used to do the import is at commit: 622b42dced6d793e9d49e9b1fd1d1524defd1387
563
564         * wasm.yaml:
565         * wasm/import-spec-tests.rb: Added.
566         * wasm/spec-tests: Added.
567         * wasm/spec-tests/address.wast.js: Added.
568         (register):
569         (module):
570         (instance):
571         (assert_malformed):
572         (assert_invalid):
573         (assert_soft_invalid):
574         (assert_unlinkable):
575         (assert_uninstantiable):
576         (assert_trap):
577         (assert_return):
578         (assert_return_nan):
579         * wasm/spec-tests/binary.wast.js: Added.
580         (register):
581         (module):
582         (instance):
583         (assert_malformed):
584         (assert_invalid):
585         (assert_soft_invalid):
586         (assert_unlinkable):
587         (assert_uninstantiable):
588         (assert_trap):
589         (assert_return):
590         (assert_return_nan):
591         * wasm/spec-tests/block.wast.js: Added.
592         (register):
593         (module):
594         (instance):
595         (assert_malformed):
596         (assert_invalid):
597         (assert_soft_invalid):
598         (assert_unlinkable):
599         (assert_uninstantiable):
600         (assert_trap):
601         (assert_return):
602         (assert_return_nan):
603         * wasm/spec-tests/br.wast.js: Added.
604         (register):
605         (module):
606         (instance):
607         (assert_malformed):
608         (assert_invalid):
609         (assert_soft_invalid):
610         (assert_unlinkable):
611         (assert_uninstantiable):
612         (assert_trap):
613         (assert_return):
614         (assert_return_nan):
615         * wasm/spec-tests/br_if.wast.js: Added.
616         (register):
617         (module):
618         (instance):
619         (assert_malformed):
620         (assert_invalid):
621         (assert_soft_invalid):
622         (assert_unlinkable):
623         (assert_uninstantiable):
624         (assert_trap):
625         (assert_return):
626         (assert_return_nan):
627         * wasm/spec-tests/br_table.wast.js: Added.
628         (register):
629         (module):
630         (instance):
631         (assert_malformed):
632         (assert_invalid):
633         (assert_soft_invalid):
634         (assert_unlinkable):
635         (assert_uninstantiable):
636         (assert_trap):
637         (assert_return):
638         (assert_return_nan):
639         * wasm/spec-tests/break-drop.wast.js: Added.
640         (register):
641         (module):
642         (instance):
643         (assert_malformed):
644         (assert_invalid):
645         (assert_soft_invalid):
646         (assert_unlinkable):
647         (assert_uninstantiable):
648         (assert_trap):
649         (assert_return):
650         (assert_return_nan):
651         * wasm/spec-tests/call.wast.js: Added.
652         (register):
653         (module):
654         (instance):
655         (assert_malformed):
656         (assert_invalid):
657         (assert_soft_invalid):
658         (assert_unlinkable):
659         (assert_uninstantiable):
660         (assert_trap):
661         (assert_return):
662         (assert_return_nan):
663         * wasm/spec-tests/call_indirect.wast.js: Added.
664         (register):
665         (module):
666         (instance):
667         (assert_malformed):
668         (assert_invalid):
669         (assert_soft_invalid):
670         (assert_unlinkable):
671         (assert_uninstantiable):
672         (assert_trap):
673         (assert_return):
674         (assert_return_nan):
675         * wasm/spec-tests/comments.wast.js: Added.
676         (register):
677         (module):
678         (instance):
679         (assert_malformed):
680         (assert_invalid):
681         (assert_soft_invalid):
682         (assert_unlinkable):
683         (assert_uninstantiable):
684         (assert_trap):
685         (assert_return):
686         (assert_return_nan):
687         * wasm/spec-tests/conversions.wast.js: Added.
688         (register):
689         (module):
690         (instance):
691         (assert_malformed):
692         (assert_invalid):
693         (assert_soft_invalid):
694         (assert_unlinkable):
695         (assert_uninstantiable):
696         (assert_trap):
697         (assert_return):
698         (assert_return_nan):
699         * wasm/spec-tests/custom_section.wast.js: Added.
700         (register):
701         (module):
702         (instance):
703         (assert_malformed):
704         (assert_invalid):
705         (assert_soft_invalid):
706         (assert_unlinkable):
707         (assert_uninstantiable):
708         (assert_trap):
709         (assert_return):
710         (assert_return_nan):
711         * wasm/spec-tests/endianness.wast.js: Added.
712         (register):
713         (module):
714         (instance):
715         (assert_malformed):
716         (assert_invalid):
717         (assert_soft_invalid):
718         (assert_unlinkable):
719         (assert_uninstantiable):
720         (assert_trap):
721         (assert_return):
722         (assert_return_nan):
723         * wasm/spec-tests/exports.wast.js: Added.
724         (register):
725         (module):
726         (instance):
727         (assert_malformed):
728         (assert_invalid):
729         (assert_soft_invalid):
730         (assert_unlinkable):
731         (assert_uninstantiable):
732         (assert_trap):
733         (assert_return):
734         (assert_return_nan):
735         * wasm/spec-tests/f32.wast.js: Added.
736         (register):
737         (module):
738         (instance):
739         (assert_malformed):
740         (assert_invalid):
741         (assert_soft_invalid):
742         (assert_unlinkable):
743         (assert_uninstantiable):
744         (assert_trap):
745         (assert_return):
746         (assert_return_nan):
747         * wasm/spec-tests/f32_cmp.wast.js: Added.
748         (register):
749         (module):
750         (instance):
751         (assert_malformed):
752         (assert_invalid):
753         (assert_soft_invalid):
754         (assert_unlinkable):
755         (assert_uninstantiable):
756         (assert_trap):
757         (assert_return):
758         (assert_return_nan):
759         * wasm/spec-tests/f64.wast.js: Added.
760         (register):
761         (module):
762         (instance):
763         (assert_malformed):
764         (assert_invalid):
765         (assert_soft_invalid):
766         (assert_unlinkable):
767         (assert_uninstantiable):
768         (assert_trap):
769         (assert_return):
770         (assert_return_nan):
771         * wasm/spec-tests/f64_cmp.wast.js: Added.
772         (register):
773         (module):
774         (instance):
775         (assert_malformed):
776         (assert_invalid):
777         (assert_soft_invalid):
778         (assert_unlinkable):
779         (assert_uninstantiable):
780         (assert_trap):
781         (assert_return):
782         (assert_return_nan):
783         * wasm/spec-tests/fac.wast.js: Added.
784         (register):
785         (module):
786         (instance):
787         (assert_malformed):
788         (assert_invalid):
789         (assert_soft_invalid):
790         (assert_unlinkable):
791         (assert_uninstantiable):
792         (assert_trap):
793         (assert_return):
794         (assert_return_nan):
795         * wasm/spec-tests/float_exprs.wast.js: Added.
796         (register):
797         (module):
798         (instance):
799         (assert_malformed):
800         (assert_invalid):
801         (assert_soft_invalid):
802         (assert_unlinkable):
803         (assert_uninstantiable):
804         (assert_trap):
805         (assert_return):
806         (assert_return_nan):
807         * wasm/spec-tests/float_literals.wast.js: Added.
808         (register):
809         (module):
810         (instance):
811         (assert_malformed):
812         (assert_invalid):
813         (assert_soft_invalid):
814         (assert_unlinkable):
815         (assert_uninstantiable):
816         (assert_trap):
817         (assert_return):
818         (assert_return_nan):
819         * wasm/spec-tests/float_memory.wast.js: Added.
820         (register):
821         (module):
822         (instance):
823         (assert_malformed):
824         (assert_invalid):
825         (assert_soft_invalid):
826         (assert_unlinkable):
827         (assert_uninstantiable):
828         (assert_trap):
829         (assert_return):
830         (assert_return_nan):
831         * wasm/spec-tests/float_misc.wast.js: Added.
832         (register):
833         (module):
834         (instance):
835         (assert_malformed):
836         (assert_invalid):
837         (assert_soft_invalid):
838         (assert_unlinkable):
839         (assert_uninstantiable):
840         (assert_trap):
841         (assert_return):
842         (assert_return_nan):
843         * wasm/spec-tests/forward.wast.js: Added.
844         (register):
845         (module):
846         (instance):
847         (assert_malformed):
848         (assert_invalid):
849         (assert_soft_invalid):
850         (assert_unlinkable):
851         (assert_uninstantiable):
852         (assert_trap):
853         (assert_return):
854         (assert_return_nan):
855         * wasm/spec-tests/func.wast.js: Added.
856         (register):
857         (module):
858         (instance):
859         (assert_malformed):
860         (assert_invalid):
861         (assert_soft_invalid):
862         (assert_unlinkable):
863         (assert_uninstantiable):
864         (assert_trap):
865         (assert_return):
866         (assert_return_nan):
867         * wasm/spec-tests/func_ptrs.wast.js: Added.
868         (register):
869         (module):
870         (instance):
871         (assert_malformed):
872         (assert_invalid):
873         (assert_soft_invalid):
874         (assert_unlinkable):
875         (assert_uninstantiable):
876         (assert_trap):
877         (assert_return):
878         (assert_return_nan):
879         * wasm/spec-tests/get_local.wast.js: Added.
880         (register):
881         (module):
882         (instance):
883         (assert_malformed):
884         (assert_invalid):
885         (assert_soft_invalid):
886         (assert_unlinkable):
887         (assert_uninstantiable):
888         (assert_trap):
889         (assert_return):
890         (assert_return_nan):
891         * wasm/spec-tests/globals.wast.js: Added.
892         (register):
893         (module):
894         (instance):
895         (assert_malformed):
896         (assert_invalid):
897         (assert_soft_invalid):
898         (assert_unlinkable):
899         (assert_uninstantiable):
900         (assert_trap):
901         (assert_return):
902         (assert_return_nan):
903         * wasm/spec-tests/i32.wast.js: Added.
904         (register):
905         (module):
906         (instance):
907         (assert_malformed):
908         (assert_invalid):
909         (assert_soft_invalid):
910         (assert_unlinkable):
911         (assert_uninstantiable):
912         (assert_trap):
913         (assert_return):
914         (assert_return_nan):
915         * wasm/spec-tests/i64.wast.js: Added.
916         (register):
917         (module):
918         (instance):
919         (assert_malformed):
920         (assert_invalid):
921         (assert_soft_invalid):
922         (assert_unlinkable):
923         (assert_uninstantiable):
924         (assert_trap):
925         (assert_return):
926         (assert_return_nan):
927         * wasm/spec-tests/imports.wast.js: Added.
928         (register):
929         (module):
930         (instance):
931         (assert_malformed):
932         (assert_invalid):
933         (assert_soft_invalid):
934         (assert_unlinkable):
935         (assert_uninstantiable):
936         (assert_trap):
937         (assert_return):
938         (assert_return_nan):
939         * wasm/spec-tests/int_exprs.wast.js: Added.
940         (register):
941         (module):
942         (instance):
943         (assert_malformed):
944         (assert_invalid):
945         (assert_soft_invalid):
946         (assert_unlinkable):
947         (assert_uninstantiable):
948         (assert_trap):
949         (assert_return):
950         (assert_return_nan):
951         * wasm/spec-tests/int_literals.wast.js: Added.
952         (register):
953         (module):
954         (instance):
955         (assert_malformed):
956         (assert_invalid):
957         (assert_soft_invalid):
958         (assert_unlinkable):
959         (assert_uninstantiable):
960         (assert_trap):
961         (assert_return):
962         (assert_return_nan):
963         * wasm/spec-tests/left-to-right.wast.js: Added.
964         (register):
965         (module):
966         (instance):
967         (assert_malformed):
968         (assert_invalid):
969         (assert_soft_invalid):
970         (assert_unlinkable):
971         (assert_uninstantiable):
972         (assert_trap):
973         (assert_return):
974         (assert_return_nan):
975         * wasm/spec-tests/linking.wast.js: Added.
976         (register):
977         (module):
978         (instance):
979         (assert_malformed):
980         (assert_invalid):
981         (assert_soft_invalid):
982         (assert_unlinkable):
983         (assert_uninstantiable):
984         (assert_trap):
985         (assert_return):
986         (assert_return_nan):
987         * wasm/spec-tests/loop.wast.js: Added.
988         (register):
989         (module):
990         (instance):
991         (assert_malformed):
992         (assert_invalid):
993         (assert_soft_invalid):
994         (assert_unlinkable):
995         (assert_uninstantiable):
996         (assert_trap):
997         (assert_return):
998         (assert_return_nan):
999         * wasm/spec-tests/memory.wast.js: Added.
1000         (register):
1001         (module):
1002         (instance):
1003         (assert_malformed):
1004         (assert_invalid):
1005         (assert_soft_invalid):
1006         (assert_unlinkable):
1007         (assert_uninstantiable):
1008         (assert_trap):
1009         (assert_return):
1010         (assert_return_nan):
1011         * wasm/spec-tests/memory_redundancy.wast.js: Added.
1012         (register):
1013         (module):
1014         (instance):
1015         (assert_malformed):
1016         (assert_invalid):
1017         (assert_soft_invalid):
1018         (assert_unlinkable):
1019         (assert_uninstantiable):
1020         (assert_trap):
1021         (assert_return):
1022         (assert_return_nan):
1023         * wasm/spec-tests/memory_trap.wast.js: Added.
1024         (register):
1025         (module):
1026         (instance):
1027         (assert_malformed):
1028         (assert_invalid):
1029         (assert_soft_invalid):
1030         (assert_unlinkable):
1031         (assert_uninstantiable):
1032         (assert_trap):
1033         (assert_return):
1034         (assert_return_nan):
1035         * wasm/spec-tests/names.wast.js: Added.
1036         (register):
1037         (module):
1038         (instance):
1039         (assert_malformed):
1040         (assert_invalid):
1041         (assert_soft_invalid):
1042         (assert_unlinkable):
1043         (assert_uninstantiable):
1044         (assert_trap):
1045         (assert_return):
1046         (assert_return_nan):
1047         * wasm/spec-tests/nop.wast.js: Added.
1048         (register):
1049         (module):
1050         (instance):
1051         (assert_malformed):
1052         (assert_invalid):
1053         (assert_soft_invalid):
1054         (assert_unlinkable):
1055         (assert_uninstantiable):
1056         (assert_trap):
1057         (assert_return):
1058         (assert_return_nan):
1059         * wasm/spec-tests/resizing.wast.js: Added.
1060         (register):
1061         (module):
1062         (instance):
1063         (assert_malformed):
1064         (assert_invalid):
1065         (assert_soft_invalid):
1066         (assert_unlinkable):
1067         (assert_uninstantiable):
1068         (assert_trap):
1069         (assert_return):
1070         (assert_return_nan):
1071         * wasm/spec-tests/return.wast.js: Added.
1072         (register):
1073         (module):
1074         (instance):
1075         (assert_malformed):
1076         (assert_invalid):
1077         (assert_soft_invalid):
1078         (assert_unlinkable):
1079         (assert_uninstantiable):
1080         (assert_trap):
1081         (assert_return):
1082         (assert_return_nan):
1083         * wasm/spec-tests/select.wast.js: Added.
1084         (register):
1085         (module):
1086         (instance):
1087         (assert_malformed):
1088         (assert_invalid):
1089         (assert_soft_invalid):
1090         (assert_unlinkable):
1091         (assert_uninstantiable):
1092         (assert_trap):
1093         (assert_return):
1094         (assert_return_nan):
1095         * wasm/spec-tests/set_local.wast.js: Added.
1096         (register):
1097         (module):
1098         (instance):
1099         (assert_malformed):
1100         (assert_invalid):
1101         (assert_soft_invalid):
1102         (assert_unlinkable):
1103         (assert_uninstantiable):
1104         (assert_trap):
1105         (assert_return):
1106         (assert_return_nan):
1107         * wasm/spec-tests/skip-stack-guard-page.wast.js: Added.
1108         (register):
1109         (module):
1110         (instance):
1111         (assert_malformed):
1112         (assert_invalid):
1113         (assert_soft_invalid):
1114         (assert_unlinkable):
1115         (assert_uninstantiable):
1116         (assert_trap):
1117         (assert_return):
1118         (assert_return_nan):
1119         * wasm/spec-tests/stack.wast.js: Added.
1120         (register):
1121         (module):
1122         (instance):
1123         (assert_malformed):
1124         (assert_invalid):
1125         (assert_soft_invalid):
1126         (assert_unlinkable):
1127         (assert_uninstantiable):
1128         (assert_trap):
1129         (assert_return):
1130         (assert_return_nan):
1131         * wasm/spec-tests/start.wast.js: Added.
1132         (register):
1133         (module):
1134         (instance):
1135         (assert_malformed):
1136         (assert_invalid):
1137         (assert_soft_invalid):
1138         (assert_unlinkable):
1139         (assert_uninstantiable):
1140         (assert_trap):
1141         (assert_return):
1142         (assert_return_nan):
1143         * wasm/spec-tests/store_retval.wast.js: Added.
1144         (register):
1145         (module):
1146         (instance):
1147         (assert_malformed):
1148         (assert_invalid):
1149         (assert_soft_invalid):
1150         (assert_unlinkable):
1151         (assert_uninstantiable):
1152         (assert_trap):
1153         (assert_return):
1154         (assert_return_nan):
1155         * wasm/spec-tests/switch.wast.js: Added.
1156         (register):
1157         (module):
1158         (instance):
1159         (assert_malformed):
1160         (assert_invalid):
1161         (assert_soft_invalid):
1162         (assert_unlinkable):
1163         (assert_uninstantiable):
1164         (assert_trap):
1165         (assert_return):
1166         (assert_return_nan):
1167         * wasm/spec-tests/tee_local.wast.js: Added.
1168         (register):
1169         (module):
1170         (instance):
1171         (assert_malformed):
1172         (assert_invalid):
1173         (assert_soft_invalid):
1174         (assert_unlinkable):
1175         (assert_uninstantiable):
1176         (assert_trap):
1177         (assert_return):
1178         (assert_return_nan):
1179         * wasm/spec-tests/traps.wast.js: Added.
1180         (register):
1181         (module):
1182         (instance):
1183         (assert_malformed):
1184         (assert_invalid):
1185         (assert_soft_invalid):
1186         (assert_unlinkable):
1187         (assert_uninstantiable):
1188         (assert_trap):
1189         (assert_return):
1190         (assert_return_nan):
1191         * wasm/spec-tests/typecheck.wast.js: Added.
1192         (register):
1193         (module):
1194         (instance):
1195         (assert_malformed):
1196         (assert_invalid):
1197         (assert_soft_invalid):
1198         (assert_unlinkable):
1199         (assert_uninstantiable):
1200         (assert_trap):
1201         (assert_return):
1202         (assert_return_nan):
1203         * wasm/spec-tests/unreachable.wast.js: Added.
1204         (register):
1205         (module):
1206         (instance):
1207         (assert_malformed):
1208         (assert_invalid):
1209         (assert_soft_invalid):
1210         (assert_unlinkable):
1211         (assert_uninstantiable):
1212         (assert_trap):
1213         (assert_return):
1214         (assert_return_nan):
1215         * wasm/spec-tests/unwind.wast.js: Added.
1216         (register):
1217         (module):
1218         (instance):
1219         (assert_malformed):
1220         (assert_invalid):
1221         (assert_soft_invalid):
1222         (assert_unlinkable):
1223         (assert_uninstantiable):
1224         (assert_trap):
1225         (assert_return):
1226         (assert_return_nan):
1227
1228 2016-12-20  Keith Miller  <keith_miller@apple.com>
1229
1230         Add support for global
1231         https://bugs.webkit.org/show_bug.cgi?id=165171
1232
1233         Reviewed by Filip Pizlo.
1234
1235         * stress/global.js: Added.
1236
1237 2016-12-20  JF Bastien  <jfbastien@apple.com>
1238
1239         WebAssembly API: implement WebAssembly.LinkError
1240         https://bugs.webkit.org/show_bug.cgi?id=165805
1241         <rdar://problem/29747874>
1242
1243         Reviewed by Mark lam.
1244
1245         Update all exception sites which now throw WebAssembly.LinkError.
1246
1247         * wasm/js-api/element-data.js:
1248         * wasm/js-api/element.js:
1249         (assert.throws):
1250         * wasm/js-api/global-error.js:
1251         (new.Number):
1252         * wasm/js-api/table.js:
1253         (assert.throws):
1254         (new.WebAssembly.Table):
1255         * wasm/js-api/test_Data.js:
1256         * wasm/js-api/test_basic_api.js:
1257         (const.c.in.constructorProperties.switch):
1258         * wasm/js-api/test_memory.js:
1259         (test):
1260         (test.testMemImportError): Deleted.
1261
1262 2016-12-20  JF Bastien  <jfbastien@apple.com>
1263
1264         WebAssembly: unique function signatures
1265         https://bugs.webkit.org/show_bug.cgi?id=165957
1266         <rdar://problem/29735737>
1267
1268         Reviewed by Saam Barati.
1269
1270         * wasm/function-tests/table-basic.js: FIXME is now addressed,
1271         though instance to instance calls still need work which bug
1272         #165282 will address
1273         (i.assert.eq.foo):
1274         * wasm/js-api/unique-signature.js: Added.
1275         (CallIndirectWithDuplicateSignatures):
1276
1277 2016-12-19  Mark Lam  <mark.lam@apple.com>
1278
1279         Rolling out r209974 and r209952. They break some websites in mysterious ways. Step 2: Rollout r209952.
1280         https://bugs.webkit.org/show_bug.cgi?id=166049
1281
1282         Not reviewed.
1283
1284         * stress/deeply-nested-finallys.js: Removed.
1285         * stress/test-finally.js: Removed.
1286
1287 2016-12-19  Saam Barati  <sbarati@apple.com>
1288
1289         WebAssembly: Make running Wasm tests take less time by reducing some tests' iteration count and by splitting some tests into different files
1290         https://bugs.webkit.org/show_bug.cgi?id=166017
1291
1292         Reviewed by Yusuke Suzuki.
1293
1294         * wasm/function-tests/trap-load-2.js: Added.
1295         (assert):
1296         (wasmFrameCountFromError):
1297         (continuation):
1298         (i.catch):
1299         * wasm/function-tests/trap-load.js:
1300         (assert.continuation): Deleted.
1301         * wasm/function-tests/trap-store-2.js: Added.
1302         (import.Builder.from.string_appeared_here.assert):
1303         (continuation):
1304         (i.catch):
1305         * wasm/function-tests/trap-store.js:
1306         (assert.continuation): Deleted.
1307         (assert): Deleted.
1308         * wasm/js-api/test_memory.js:
1309         (test):
1310
1311 2016-12-18  Saam Barati  <sbarati@apple.com>
1312
1313         WebAssembly: Implement the WebAssembly.compile and WebAssembly.validate
1314         https://bugs.webkit.org/show_bug.cgi?id=165936
1315
1316         Reviewed by Mark Lam.
1317
1318         * wasm/js-api/Module-compile.js: Added.
1319         (async.testPromiseAPI):
1320         * wasm/js-api/test_basic_api.js:
1321         (const.c.in.constructorProperties.switch):
1322         * wasm/js-api/validate.js: Added.
1323         (assert.truthy.WebAssembly.validate.builder.WebAssembly):
1324
1325 2016-12-16  Mark Lam  <mark.lam@apple.com>
1326
1327         De-duplicate finally blocks.
1328         https://bugs.webkit.org/show_bug.cgi?id=160168
1329
1330         Reviewed by Keith Miller.
1331
1332         * stress/deeply-nested-finallys.js: Added.
1333         - Tests many levels of finally nesting.  This causes the old code to hang (and
1334           crashes eventually) while trying to generate bytecode for the exponentially
1335           duplicated finally blocks.  The new code completes this test almost instantly.
1336
1337         * stress/test-finally.js: Added.
1338         - Tests control flow through various permutations of finally blocks.
1339
1340 2016-12-16  Saam Barati  <sbarati@apple.com>
1341
1342         WebAssembly: WasmB3IRGenerator should throw exceptions instead of crash
1343         https://bugs.webkit.org/show_bug.cgi?id=165834
1344
1345         Reviewed by Keith Miller.
1346
1347         * wasm/function-tests/exceptions.js: Added.
1348         (import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.makeInstance):
1349         * wasm/function-tests/table-basic.js:
1350         (i.i.42.throw.new.Error):
1351
1352 2016-12-16  Keith Miller  <keith_miller@apple.com>
1353
1354         i64.eqz should use an Int64 zero
1355         https://bugs.webkit.org/show_bug.cgi?id=165942
1356
1357         Reviewed by Mark Lam.
1358
1359         * wasm/wasm.json:
1360
1361 2016-12-15  Keith Miller  <keith_miller@apple.com>
1362
1363         Fix validation of non-void if blocks with no else
1364         https://bugs.webkit.org/show_bug.cgi?id=165938
1365
1366         Reviewed by Saam Barati.
1367
1368         Add a new failing test and a fix an existing one.
1369
1370         * wasm/function-tests/dead-call.js:
1371         * wasm/function-tests/if-no-else-non-void.js: Added.
1372
1373 2016-12-15  Keith Miller  <keith_miller@apple.com>
1374
1375         Wasm should not create empty unlinked callsites
1376         https://bugs.webkit.org/show_bug.cgi?id=165933
1377
1378         Reviewed by Mark Lam.
1379
1380         * wasm/function-tests/dead-call.js: Added.
1381
1382 2016-12-15  JF Bastien  <jfbastien@apple.com>
1383
1384         WebAssembly: improve compilation error messages
1385         https://bugs.webkit.org/show_bug.cgi?id=163919
1386
1387         Reviewed by Saam Barati.
1388
1389         Update error messages in these tests.
1390         Use the assert.throws facility in many of them which weren't already.
1391
1392         * wasm/js-api/element.js:
1393         (assert.throws.new.WebAssembly.Module.builder.WebAssembly):
1394         (assert.throws):
1395         * wasm/js-api/global-error.js:
1396         (assert.throws.new.WebAssembly.Module.bin):
1397         (assert.throws):
1398         (new.Number):
1399         * wasm/js-api/table.js:
1400         (assert.throws.new.WebAssembly.Module.builder.WebAssembly):
1401         (assert.throws):
1402         (assertBadTableImport):
1403         * wasm/js-api/test_Data.js:
1404         (DataSectionWithoutMemory):
1405         * wasm/js-api/test_Start.js:
1406         (InvalidStartFunctionIndex):
1407         * wasm/js-api/test_basic_api.js:
1408         (const.c.in.constructorProperties.switch):
1409
1410 2016-12-15  JF Bastien  <jfbastien@apple.com>
1411
1412         WebAssembly API: improve data section errors
1413         https://bugs.webkit.org/show_bug.cgi?id=165733
1414
1415         Reviewed by Keith Miller.
1416
1417         * wasm/js-api/element-data.js: Added.
1418         (ElementBeforeData.set const):
1419         (ElementBeforeData): check the order of initialization, which is observable on failure
1420         * wasm/js-api/test_Data.js:
1421         (DataSectionWithoutMemory):
1422         (DataSectionOffTheEnd): Deleted.
1423         (DataSectionPartlyOffTheEnd): Deleted.
1424         (DataSectionEmptyOffTheEnd): Deleted.
1425         (DataSectionSeenByStart): Deleted.
1426
1427 2016-12-15  Keith Miller  <keith_miller@apple.com>
1428
1429         Fix 64-bit shift family Wasm opcodes
1430         https://bugs.webkit.org/show_bug.cgi?id=165902
1431
1432         Reviewed by Geoffrey Garen.
1433
1434         Add tests for shift family of instructions. Since
1435         we can't generate i64 values to pass to wasm we only compile
1436         the code for those functions. Attempting to generate any i64
1437         code using these instructions would have been enough to cause
1438         the B3 Validation error anyway.
1439
1440         * wasm/assert.js:
1441         * wasm/function-tests/rotl.js: Added.
1442         * wasm/function-tests/rotr.js: Added.
1443         * wasm/function-tests/shl.js: Added.
1444         * wasm/function-tests/shr-s.js: Added.
1445         * wasm/function-tests/shr-u.js: Added.
1446         * wasm/wasm.json:
1447
1448 2016-12-14  Keith Miller  <keith_miller@apple.com>
1449
1450         WebAssembly: test_BuilderJSON.js is broken
1451         https://bugs.webkit.org/show_bug.cgi?id=165893
1452
1453         Reviewed by Michael Saboff.
1454
1455         * wasm/Builder.js:
1456         (const._isValidValue):
1457         * wasm/self-test/test_BuilderJSON.js:
1458
1459 2016-12-14  Keith Miller  <keith_miller@apple.com>
1460
1461         Unreviewed, fix test.
1462
1463         * wasm/function-tests/i32-const.js:
1464
1465 2016-12-14  Keith Miller  <keith_miller@apple.com>
1466
1467         Wasm should decode constants correctly
1468         https://bugs.webkit.org/show_bug.cgi?id=165886
1469
1470         Reviewed by Saam Barati.
1471
1472         * wasm/Builder.js:
1473         (const._isValidValue):
1474         * wasm/Builder_WebAssemblyBinary.js:
1475         (const.putOp):
1476         * wasm/LowLevelBinary.js:
1477         (export.default.LowLevelBinary.prototype.float):
1478         (export.default.LowLevelBinary.prototype.double):
1479         * wasm/function-tests/f32-const.js: Added.
1480         * wasm/function-tests/f64-const.js: Added.
1481         * wasm/function-tests/i32-const.js: Added.
1482         * wasm/wasm.json:
1483
1484 2016-12-14  Saam Barati  <sbarati@apple.com>
1485
1486         WebAssembly: Add various low hanging fruit that will allow us to run the LLVM torture tests in Wasm
1487         https://bugs.webkit.org/show_bug.cgi?id=165883
1488
1489         Reviewed by Keith Miller.
1490
1491         * wasm/Builder.js:
1492         (export.default.Builder.prototype._registerSectionBuilders.switch.case.string_appeared_here.this.section):
1493         * wasm/Builder_WebAssemblyBinary.js:
1494         (const.emitters.Export):
1495         * wasm/js-api/table.js:
1496         (assertBadBinary):
1497         (assertBadTable):
1498         (assert.truthy):
1499         * wasm/js-api/test_memory.js:
1500         (binaryShouldNotParse):
1501         (test):
1502         (test.testMemImportError):
1503         (assert.truthy):
1504         (assert): Deleted.
1505
1506 2016-12-14  Filip Pizlo  <fpizlo@apple.com>
1507
1508         DirectTailCall implementation needs to tell the shuffler what to put into the ArgumentCount explicitly
1509         https://bugs.webkit.org/show_bug.cgi?id=165882
1510
1511         Reviewed by Mark Lam.
1512
1513         * stress/direct-tail-call-arity-mismatch-count-args.js: Added.
1514         (foo):
1515         (bar):
1516
1517 2016-12-14  Keith Miller  <keith_miller@apple.com>
1518
1519         WebAssembly JS API: implement Global
1520         https://bugs.webkit.org/show_bug.cgi?id=164133
1521
1522         Reviewed by Saam Barati.
1523
1524         * wasm/Builder.js:
1525         (export.default.Builder.prototype._registerSectionBuilders.switch.case.string_appeared_here.this.section):
1526         * wasm/Builder_WebAssemblyBinary.js:
1527         (const.valueType.WASM.description.type.i32.type.const.putGlobalType):
1528         (const.putOp):
1529         (const.putInitExpr):
1530         (const.emitters.Import):
1531         (const.emitters.Global):
1532         (const.emitters.Export):
1533         (const.emitters.Code):
1534         * wasm/LowLevelBinary.js:
1535         (export.default.LowLevelBinary.prototype.varuint32):
1536         (export.default.LowLevelBinary.prototype.varint32):
1537         * wasm/js-api/global-error.js: Added.
1538         (catch):
1539         (assert.truthy):
1540         * wasm/js-api/global-external-init-from-import.js: Added.
1541         * wasm/js-api/global-internal-init-from-import.js: Added.
1542         * wasm/js-api/global-mutate.js: Added.
1543         (createInternalGlobalModule):
1544         * wasm/js-api/globals-export.js: Added.
1545         * wasm/js-api/globals-import.js: Added.
1546         * wasm/wasm.json:
1547
1548 2016-12-13  Saam Barati  <sbarati@apple.com>
1549
1550         WebAssembly: implement the elements section
1551         https://bugs.webkit.org/show_bug.cgi?id=165715
1552
1553         Reviewed by Keith Miller.
1554
1555         * wasm/Builder.js:
1556         (export.default.Builder.prototype._registerSectionBuilders.switch.case.string_appeared_here.this.section):
1557         (export.default.Builder.prototype._registerSectionBuilders.switch):
1558         * wasm/Builder_WebAssemblyBinary.js:
1559         (const.emitters.Element):
1560         * wasm/function-tests/basic-element.js: Added.
1561         * wasm/js-api/element.js: Added.
1562         (assertBadBinary):
1563         (assertBadBinary.badInstantiation):
1564
1565 2016-12-13  Saam Barati  <sbarati@apple.com>
1566
1567         WebAssembly: implement the table section and table import
1568         https://bugs.webkit.org/show_bug.cgi?id=165716
1569
1570         Reviewed by Keith Miller.
1571
1572         * wasm/Builder.js:
1573         (const._importMemoryContinuation):
1574         (const._importTableContinuation):
1575         (export.default.Builder.prototype._registerSectionBuilders.switch.case.string_appeared_here.this.section):
1576         (const._importMemoryContinuation.section): Deleted.
1577         (const): Deleted.
1578         (const._importMemoryContinuation.assert): Deleted.
1579         * wasm/Builder_WebAssemblyBinary.js:
1580         (const.putResizableLimits):
1581         (const.putTable):
1582         (const.emitters.Import):
1583         (const.emitters.Table):
1584         * wasm/function-tests/call-indirect-params.js:
1585         * wasm/function-tests/call-indirect.js:
1586         * wasm/function-tests/table-basic-2.js: Added.
1587         (import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.makeInstance):
1588         (func):
1589         * wasm/function-tests/table-basic.js: Added.
1590         (import.Builder.from.string_appeared_here.import.as.assert.from.string_appeared_here.makeInstance):
1591         * wasm/js-api/call-indirect-results.js:
1592         (const.wasmModuleWhichImportJS): Deleted.
1593         (MonomorphicImport): Deleted.
1594         * wasm/js-api/call-indirect.js:
1595         (const.wasmModuleWhichImportJS):
1596         (const.makeTable):
1597         (Polyphic2Import):
1598         (VirtualImport):
1599         (MonomorphicImport): Deleted.
1600         * wasm/js-api/table.js: Added.
1601         (assertBadBinary):
1602         (assert.truthy):
1603         (assertBadTable):
1604         (assertBadTableImport):
1605         (assertBadBinary.assertBadTableInstance):
1606         (assertBadTableInstance):
1607         (new.WebAssembly.Table):
1608         * wasm/js-api/test_basic_api.js:
1609         (const.c.in.constructorProperties.switch):
1610
1611 2016-12-13  Commit Queue  <commit-queue@webkit.org>
1612
1613         Unreviewed, rolling out r209725.
1614         https://bugs.webkit.org/show_bug.cgi?id=165811
1615
1616         "Broke ARMv7 builds" (Requested by msaboff on #webkit).
1617
1618         Reverted changeset:
1619
1620         "REGRESSION(r209653): speedometer crashes making virtual slow
1621         path tailcalls"
1622         https://bugs.webkit.org/show_bug.cgi?id=165748
1623         http://trac.webkit.org/changeset/209725
1624
1625 2016-12-12  Michael Saboff  <msaboff@apple.com>
1626
1627         REGRESSION(r209653): speedometer crashes making virtual slow path tailcalls
1628         https://bugs.webkit.org/show_bug.cgi?id=165748
1629
1630         Reviewed by Filip Pizlo.
1631
1632         New regression test.
1633
1634         * stress/regress-165748.js: Added.
1635         (sum1):
1636         (sum2):
1637         (sum3):
1638         (sum4):
1639         (sum5):
1640         (sum6):
1641         (tailCaller):
1642         (test):
1643
1644 2016-12-12  Mark Lam  <mark.lam@apple.com>
1645
1646         Debug JSC test timeout: stress/string-prototype-replace-should-throw-out-of-memory-error-when-using-too-much-memory.js.ftl-no-cjit.
1647         https://bugs.webkit.org/show_bug.cgi?id=164630
1648
1649         Reviewed by Keith Miller.
1650
1651         Speculative fix for timeout issue.  It looks like this test just runs a bit
1652         slower on debug builds.  So, we'll give it a little more time to run.
1653
1654         * stress/string-prototype-replace-should-throw-out-of-memory-error-when-using-too-much-memory.js:
1655
1656 2016-12-11  Saam Barati  <sbarati@apple.com>
1657
1658         We should be able to throw exceptions from Wasm code and when Wasm frames are on the stack
1659         https://bugs.webkit.org/show_bug.cgi?id=165429
1660
1661         Reviewed by Keith Miller.
1662
1663         * wasm/function-tests/trap-load.js: Added.
1664         (assert):
1665         (wasmFrameCountFromError):
1666         (i.catch):
1667         (assert.continuation):
1668         * wasm/function-tests/trap-store.js: Added.
1669         (import.Builder.from.string_appeared_here.assert):
1670         (i.catch):
1671         (assert.continuation):
1672         (assert):
1673         * wasm/js-api/test_memory_constructor.js:
1674         (assert):
1675
1676 2016-12-10  Commit Queue  <commit-queue@webkit.org>
1677
1678         Unreviewed, rolling out r209653, r209654, r209663, and
1679         r209673.
1680         https://bugs.webkit.org/show_bug.cgi?id=165739
1681
1682         speedometer crashes (Requested by pizlo on #webkit).
1683
1684         Reverted changesets:
1685
1686         "JSVALUE64: Pass arguments in platform argument registers when
1687         making JavaScript calls"
1688         https://bugs.webkit.org/show_bug.cgi?id=160355
1689         http://trac.webkit.org/changeset/209653
1690
1691         "Unreviewed build fix for 32 bit builds."
1692         http://trac.webkit.org/changeset/209654
1693
1694         "Unreviewed build fix for the CLOOP after r209653"
1695         http://trac.webkit.org/changeset/209663
1696
1697         "REGRESSION(r209653) Crash in CallFrameShuffler::snapshot()"
1698         https://bugs.webkit.org/show_bug.cgi?id=165728
1699         http://trac.webkit.org/changeset/209673
1700
1701 2016-12-10  Michael Saboff  <msaboff@apple.com>
1702
1703         REGRESSION(r209653) Crash in CallFrameShuffler::snapshot()
1704         https://bugs.webkit.org/show_bug.cgi?id=165728
1705
1706         Reviewed by Filip Pizlo.
1707
1708         New regression test.
1709
1710         * stress/regress-165728.js: Added.
1711         (sum1):
1712         (sum2):
1713         (tailCaller):
1714         (test):
1715
1716 2016-12-10  Keith Miller  <keith_miller@apple.com>
1717
1718         Fix indirect_call if the result type is used.
1719         https://bugs.webkit.org/show_bug.cgi?id=165727
1720
1721         Reviewed by Michael Saboff.
1722
1723         * wasm/js-api/call-indirect-results.js: Added.
1724         (const.wasmModuleWhichImportJS):
1725         (MonomorphicImport):
1726
1727 2016-12-10  Yusuke Suzuki  <utatane.tea@gmail.com>
1728
1729         [JSC] Module namespace object behaves like immutable prototype exotic object
1730         https://bugs.webkit.org/show_bug.cgi?id=165598
1731
1732         Reviewed by Mark Lam.
1733
1734         * modules/namespace-prototype-assignment.js: Added.
1735         (else):
1736         (reportError):
1737         (shouldEqual):
1738         (shouldThrow):
1739         (stringify):
1740         (makeTestID):
1741         (doInternalSetPrototypeOf):
1742         (ordinarySetPrototypeOf):
1743         (setImmutablePrototype):
1744         (windowProxySetPrototypeOf):
1745         (initSetterExpectation):
1746         (throwIfNoExceptionPending):
1747         (objectSetPrototypeOf):
1748         (setUnderscoreProto):
1749         (reflectSetPrototypeOf):
1750         (setPrototypeOf):
1751         (newObjectProto.toString):
1752         (Symbol):
1753         (test):
1754         (runTests):
1755         * modules/namespace-set-prototype-of.js: Added.
1756         (shouldThrow):
1757         (TypeError.Cannot.set prototype):
1758
1759 2016-12-09  Michael Saboff  <msaboff@apple.com>
1760
1761         JSVALUE64: Pass arguments in platform argument registers when making JavaScript calls
1762         https://bugs.webkit.org/show_bug.cgi?id=160355
1763
1764         Reviewed by Filip Pizlo.
1765
1766         New microbenchmarks to measure call type performance.
1767
1768         * microbenchmarks/calling-computed-args.js: Added.
1769         * microbenchmarks/calling-many-callees.js: Added.
1770         * microbenchmarks/calling-one-callee-fixed.js: Added.
1771         * microbenchmarks/calling-one-callee.js: Added.
1772         * microbenchmarks/calling-poly-callees.js: Added.
1773         * microbenchmarks/calling-poly-extra-arity-callees.js: Added.
1774         * microbenchmarks/calling-tailcall.js: Added.
1775         * microbenchmarks/calling-virtual-arity-fixup-callees.js: Added.
1776         * microbenchmarks/calling-virtual-arity-fixup-stackargs.js: Added.
1777         * microbenchmarks/calling-virtual-callees.js: Added.
1778         * microbenchmarks/calling-virtual-extra-arity-callees.js: Added.
1779
1780 2016-12-09  Keith Miller  <keith_miller@apple.com>
1781
1782         Wasm should support call_indirect
1783         https://bugs.webkit.org/show_bug.cgi?id=165718
1784
1785         Reviewed by Filip Pizlo.
1786
1787         * wasm/Builder.js:
1788         * wasm/function-tests/call-indirect-params.js: Added.
1789         * wasm/function-tests/call-indirect.js: Added.
1790         * wasm/js-api/call-indirect.js: Added.
1791         (const.wasmModuleWhichImportJS):
1792         (MonomorphicImport):
1793         (Polyphic2Import):
1794         (VirtualImport):
1795         * wasm/wasm.json:
1796
1797 2016-12-09  JF Bastien  <jfbastien@apple.com>
1798
1799         WebAssembly: implement data section
1800         https://bugs.webkit.org/show_bug.cgi?id=165696
1801
1802         Reviewed by Keith Miller.
1803
1804         As specified in https://github.com/WebAssembly/design/blob/master/BinaryEncoding.md#data-section
1805         Note that some of the interesting corner cases are ill-defined by the spec: https://github.com/WebAssembly/design/issues/897
1806
1807         * wasm/Builder.js: create a data section from JavaScript
1808         * wasm/Builder_WebAssemblyBinary.js: assemble the data section into the proper binary encoding
1809         (const.emitters.Data):
1810         * wasm/js-api/test_Data.js: Added.
1811         (DataSection):
1812         (DataSectionOffTheEnd):
1813         (DataSectionPartlyOffTheEnd):
1814         (DataSectionEmptyOffTheEnd):
1815         (DataSectionSeenByStart):
1816         * wasm/self-test/test_BuilderJSON.js: make sure the JSON structure is fine (this sanity checks before going to binary)
1817
1818 2016-12-09  JF Bastien  <jfbastien@apple.com>
1819
1820         WebAssembly JS API: implement start function
1821         https://bugs.webkit.org/show_bug.cgi?id=165150
1822
1823         Reviewed by Saam Barati.
1824
1825         * wasm/Builder.js: allow building a .Start()
1826         * wasm/Builder_WebAssemblyBinary.js:
1827         * wasm/js-api/test_Start.js: Added.
1828         (const.emitters.Start): serialize a start section
1829         * wasm/self-test/test_BuilderJSON.js: validate the start section's content
1830
1831 2016-12-09  Saam Barati  <sbarati@apple.com>
1832
1833         WebAssembly JS API: implement importing and defining Memory
1834         https://bugs.webkit.org/show_bug.cgi?id=164134
1835
1836         Reviewed by Keith Miller.
1837
1838         * wasm/Builder.js:
1839         (const._importMemoryContinuation.section):
1840         (const._importMemoryContinuation.assert):
1841         (const._importMemoryContinuation):
1842         (const._exportFunctionContinuation.const): Deleted.
1843         (const._exportFunctionContinuation): Deleted.
1844         * wasm/Builder_WebAssemblyBinary.js:
1845         (const.emitters.Import):
1846         * wasm/js-api/test_basic_api.js:
1847         (const.c.in.constructorProperties.switch):
1848         * wasm/js-api/test_memory.js: Added.
1849         (assert):
1850         (binaryShouldNotParse):
1851         (test):
1852         (test.testMemImportError):
1853         * wasm/js-api/test_memory_constructor.js: Added.
1854         (assert):
1855         (throw.new.Error):
1856         (testInvalidSize):
1857         (assert.testInvalidInitial):
1858         (testInvalidInitial.testInvalidMaximum):
1859         (testInvalidInitial):
1860         (testInvalidMaximum):
1861         * wasm/self-test/test_BuilderJSON.js:
1862
1863 2016-12-08  JF Bastien  <jfbastien@apple.com>
1864
1865         WebAssembly: JSC::link* shouldn't need a CodeBlock
1866         https://bugs.webkit.org/show_bug.cgi?id=165591
1867
1868         Reviewed by Keith Miller.
1869
1870         test that wasm -> JS works, including the IC
1871
1872         * wasm/js-api/test_Instance.js:
1873         (const.wasmModuleWhichImportJS):
1874         (MonomorphicImport):
1875         (Polyphic2Import):
1876         (Polyphic3Import):
1877         (VirtualImport):
1878
1879 2016-12-08  Filip Pizlo  <fpizlo@apple.com>
1880
1881         Green the cloop bot by raising this threshold.
1882
1883         * mozilla/js1_5/Array/regress-101964.js:
1884
1885 2016-12-08  JF Bastien  <jfbastien@apple.com>
1886
1887         WebAssembly JS API: wire up Instance imports
1888         https://bugs.webkit.org/show_bug.cgi?id=165118
1889
1890         Reviewed by Saam Barati.
1891
1892         * wasm/js-api/test_Instance.js: add the test, disabled for now
1893
1894 2016-12-07  Keith Miller  <keith_miller@apple.com>
1895
1896         Add more missing trivial wasm ops.
1897         https://bugs.webkit.org/show_bug.cgi?id=165564
1898
1899         Add tests for drop and tee_local.
1900
1901         Reviewed by Geoffrey Garen.
1902
1903         * wasm/function-tests/drop.js: Added.
1904         * wasm/function-tests/nop.js: Added.
1905         * wasm/function-tests/tee-local.js: Added.
1906
1907 2016-12-06  Keith Miller  <keith_miller@apple.com>
1908
1909         Add support for truncation operators
1910         https://bugs.webkit.org/show_bug.cgi?id=165519
1911
1912         Reviewed by Geoffrey Garen.
1913
1914         * wasm/function-tests/i32-trunc-s-f32.js: Added.
1915         * wasm/function-tests/i32-trunc-s-f64.js: Added.
1916         * wasm/function-tests/i32-trunc-u-f32.js: Added.
1917         * wasm/function-tests/i32-trunc-u-f64.js: Added.
1918         * wasm/function-tests/i64-trunc-s-f32.js: Added.
1919         * wasm/function-tests/i64-trunc-s-f64.js: Added.
1920         * wasm/function-tests/i64-trunc-u-f32.js: Added.
1921         * wasm/function-tests/i64-trunc-u-f64.js: Added.
1922
1923 2016-12-06  Mark Lam  <mark.lam@apple.com>
1924
1925         Introduce the concept of Immutable Prototype Exotic Objects to comply with the spec.
1926         https://bugs.webkit.org/show_bug.cgi?id=165227
1927         <rdar://problem/29442665>
1928
1929         Reviewed by Saam Barati.
1930
1931         * stress/get-from-scope-dynamic-onto-proxy.js:
1932         - Updated error message.
1933
1934         * stress/proxy-dont-infinite-loop.js: Removed.
1935         * stress/proxy-json-path.js: Removed.
1936         * stress/rest-parameter-allocation-elimination-watchpoints-6.js: Removed.
1937         - Removed these tests because the issue they are testing relies on being able to
1938           set Object.prototype.__proto__ to something else (which is now not possible).
1939
1940 2016-12-05  Caitlin Potter  <caitp@igalia.com>
1941
1942         [JSC] report unexpected token when "async" is followed by identifier 
1943         https://bugs.webkit.org/show_bug.cgi?id=165091
1944
1945         Reviewed by Mark Lam.
1946
1947         * stress/bug-165091.js:
1948
1949 2016-12-05  Keith Miller  <keith_miller@apple.com>
1950
1951         Add Wasm i64 to i32 conversion.
1952         https://bugs.webkit.org/show_bug.cgi?id=165378
1953
1954         Reviewed by Filip Pizlo.
1955
1956         It turns out the wrap operation is just B3's Trunc.
1957
1958         * wasm/wasm.json:
1959
1960 2016-12-04  Keith Miller  <keith_miller@apple.com>
1961
1962         Add support for Wasm ctz and popcnt
1963         https://bugs.webkit.org/show_bug.cgi?id=165369
1964
1965         Reviewed by Saam Barati.
1966
1967         * wasm/function-tests/ctz.js: Added.
1968         * wasm/function-tests/popcnt.js: Added.
1969
1970 2016-12-03  JF Bastien  <jfbastien@apple.com>
1971
1972         WebAssembly: update binary format to 0xD version
1973         https://bugs.webkit.org/show_bug.cgi?id=165345
1974
1975         Reviewed by Keith Miller.
1976
1977         As described in the following PR: https://github.com/WebAssembly/design/pull/836
1978         Originally committed in r209175, reverted in r209242, and fixed in r209284.
1979
1980         * wasm/Builder.js:
1981         (const._normalizeFunctionSignature):
1982         * wasm/Builder_WebAssemblyBinary.js:
1983         (const.emitters.Type):
1984         (const.emitters.Code):
1985         * wasm/LowLevelBinary.js:
1986         (export.default.LowLevelBinary.prototype.block_type):
1987         (export.default.LowLevelBinary.prototype.inline_signature_type): Deleted.
1988         * wasm/WASM.js:
1989         * wasm/js-api/test_basic_api.js:
1990         * wasm/self-test/test_BuilderWebAssembly.js:
1991         (EmptyModule):
1992         (CustomSection):
1993         * wasm/self-test/test_WASM.js:
1994         * wasm/wasm.json:
1995
1996 2016-12-02  Keith Miller  <keith_miller@apple.com>
1997
1998         Add Wasm copysign
1999         https://bugs.webkit.org/show_bug.cgi?id=165355
2000
2001         Reviewed by Filip Pizlo.
2002
2003         * wasm/function-tests/copysign.js: Added.
2004
2005 2016-12-03  Commit Queue  <commit-queue@webkit.org>
2006
2007         Unreviewed, rolling out r209298.
2008         https://bugs.webkit.org/show_bug.cgi?id=165359
2009
2010         broke the build (Requested by smfr on #webkit).
2011
2012         Reverted changeset:
2013
2014         "Add Wasm copysign"
2015         https://bugs.webkit.org/show_bug.cgi?id=165355
2016         http://trac.webkit.org/changeset/209298
2017
2018 2016-12-02  Keith Miller  <keith_miller@apple.com>
2019
2020         Add Wasm copysign
2021         https://bugs.webkit.org/show_bug.cgi?id=165355
2022
2023         Reviewed by Filip Pizlo.
2024
2025         * wasm/function-tests/copysign.js: Added.
2026
2027 2016-12-02  Keith Miller  <keith_miller@apple.com>
2028
2029         Unreviewed, fix git having a breakdown over trying to reland a rollout.
2030
2031 2016-12-02  Keith Miller  <keith_miller@apple.com>
2032
2033         Add Wasm floating point nearest and trunc
2034         https://bugs.webkit.org/show_bug.cgi?id=165339
2035
2036         Reviewed by Saam Barati.
2037
2038         * wasm/function-tests/nearest.js: Added.
2039         * wasm/function-tests/trunc.js: Added.
2040
2041 2016-12-02  Caitlin Potter  <caitp@igalia.com>
2042
2043 [JSC] add additional bit to JSTokenType bitfield
2044         https://bugs.webkit.org/show_bug.cgi?id=165091
2045
2046         Reviewed by Geoffrey Garen.
2047
2048         * stress/bug-165091.js: Added.
2049         (shouldThrowSyntaxError):
2050
2051 2016-12-02  Commit Queue  <commit-queue@webkit.org>
2052
2053         Unreviewed, rolling out r209275 and r209276.
2054         https://bugs.webkit.org/show_bug.cgi?id=165348
2055
2056         "broke the arm build" (Requested by keith_miller on #webkit).
2057
2058         Reverted changesets:
2059
2060         "Add Wasm floating point nearest and trunc"
2061         https://bugs.webkit.org/show_bug.cgi?id=165339
2062         http://trac.webkit.org/changeset/209275
2063
2064         "Unreviewed, forgot to change instruction after renaming."
2065         http://trac.webkit.org/changeset/209276
2066
2067 2016-12-02  Keith Miller  <keith_miller@apple.com>
2068
2069         Add Wasm floating point nearest and trunc
2070         https://bugs.webkit.org/show_bug.cgi?id=165339
2071
2072         Reviewed by Filip Pizlo.
2073
2074         * wasm/function-tests/nearest.js: Added.
2075         * wasm/function-tests/trunc.js: Added.
2076
2077 2016-12-02  JF Bastien  <jfbastien@apple.com>
2078
2079         WebAssembly: revert patch causing odd breakage
2080         https://bugs.webkit.org/show_bug.cgi?id=165308
2081
2082         Unreviewed.
2083
2084         Bug #164724 seems to cause build issues which I haven't tracked down yet. WasmOps.h can't be found:
2085         ./Source/JavaScriptCore/wasm/WasmFormat.h:34:10: fatal error: 'WasmOps.h' file not found
2086
2087         It's weird since the file is auto-generated and has been for a while. #164724 merely includes it in WasmFormat.h.
2088
2089         * wasm/Builder.js:
2090         (const._normalizeFunctionSignature):
2091         * wasm/Builder_WebAssemblyBinary.js:
2092         (const.emitters.Type):
2093         (const.emitters.Code):
2094         * wasm/LowLevelBinary.js:
2095         (export.default.LowLevelBinary.prototype.inline_signature_type):
2096         (export.default.LowLevelBinary.prototype.block_type): Deleted.
2097         * wasm/WASM.js:
2098         * wasm/js-api/test_basic_api.js:
2099         * wasm/self-test/test_BuilderWebAssembly.js:
2100         (EmptyModule):
2101         (CustomSection):
2102         * wasm/self-test/test_WASM.js:
2103         * wasm/wasm.json:
2104
2105 2016-12-01  Ryan Haddad  <ryanhaddad@apple.com>
2106
2107         Skip flaky test ChakraCore/test/fieldopts/objtypespec-newobj-invalidation.1.js
2108         https://bugs.webkit.org/show_bug.cgi?id=162567
2109
2110         Reviewed by Saam Barati.
2111
2112         * ChakraCore.yaml:
2113
2114 2016-12-01  Keith Miller  <keith_miller@apple.com>
2115
2116         Add wasm int to floating point opcodes
2117         https://bugs.webkit.org/show_bug.cgi?id=165252
2118
2119         Reviewed by Geoffrey Garen.
2120
2121         Add tests for Wasm integral to floating point conversion opcodes.
2122
2123         * wasm/function-tests/int-to-floating-point.js: Added.
2124         * wasm/wasm.json:
2125
2126 2016-12-01  Geoffrey Garen  <ggaren@apple.com>
2127
2128         Land a test case for <rdar://problem/27889416>
2129         https://bugs.webkit.org/show_bug.cgi?id=165272
2130
2131         Reviewed by Saam Barati.
2132
2133         * stress/marked-argument-buffer.js: Added.
2134         (allocate):
2135         (test.o.toString):
2136         (test):
2137
2138 2016-11-29  Per Arne Vollan  <pvollan@apple.com>
2139
2140         [Win] Skip failing JSC tests.
2141         https://bugs.webkit.org/show_bug.cgi?id=165140
2142
2143         Reviewed by Mark Lam.
2144
2145         * ChakraCore.yaml:
2146         * microbenchmarks/tan.js:
2147
2148 2016-11-30  JF Bastien  <jfbastien@apple.com>
2149
2150         WebAssembly builder: don't throw when checker not implemented
2151         https://bugs.webkit.org/show_bug.cgi?id=165219
2152
2153         Reviewed by Mark Lam.
2154
2155         We should perform whichever checks we've implemented, and assume the rest are OK until bug #163421 is fixed.
2156
2157         * wasm/Builder.js:
2158         * wasm/README.md:
2159         * wasm/function-tests/add-12.js:
2160         * wasm/function-tests/br-if-loop-less-than.js:
2161         * wasm/function-tests/brTableAsIf.js:
2162         * wasm/function-tests/brTableManyValues.js:
2163         * wasm/function-tests/brTableWithLoop.js:
2164         * wasm/function-tests/dumb-eq-if-then-else.js:
2165         * wasm/function-tests/dumb-less-than-fallthrough.js:
2166         * wasm/function-tests/dumb-less-than-ite.js:
2167         * wasm/function-tests/eqz.js:
2168         * wasm/function-tests/factorial.js:
2169         * wasm/function-tests/float-sub.js:
2170         * wasm/function-tests/i32-load.js:
2171         * wasm/function-tests/i32-load8-s.js:
2172         * wasm/function-tests/if-then-else-fallthrough.js:
2173         * wasm/function-tests/if-then-fallthrough.js:
2174         * wasm/function-tests/loop-mult.js:
2175         * wasm/function-tests/loop-sum.js:
2176         * wasm/function-tests/max.js:
2177         * wasm/function-tests/min.js:
2178         * wasm/function-tests/ret5.js:
2179         * wasm/function-tests/select.js:
2180         * wasm/self-test/test_BuilderJSON.js:
2181
2182 2016-11-29  JF Bastien  <jfbastien@apple.com>
2183
2184         WebAssembly JS API: improve Instance
2185         https://bugs.webkit.org/show_bug.cgi?id=164757
2186
2187         Reviewed by Keith Miller.
2188
2189         An Instance's `exports` property wasn't populated with exports.
2190
2191         A follow-up patch will do imports.
2192
2193         A few things of note:
2194
2195          - LowLevelBinary: support 3-byte integers.
2196          - LowLevelBinary: support proper UTF-8 2003 code points (instead of UTF-16).
2197
2198         * wasm/Builder.js:
2199         * wasm/Builder_WebAssemblyBinary.js: wire up exports, stub other things out some more
2200         (const.emitters.Export):
2201         * wasm/LowLevelBinary.js:
2202         (export.default.LowLevelBinary.prototype.uint24): add, used for UTF-8
2203         (export.default.LowLevelBinary.prototype.string): support UTF-8
2204         (export.default.LowLevelBinary.prototype.getUint24): add, used for UTF-8
2205         (export.default.LowLevelBinary.prototype.getVaruint1): was missing
2206         (export.default.LowLevelBinary.prototype.getString): support UTF-8
2207         (export.default.LowLevelBinary):
2208         * wasm/js-api/test_Instance.js: instance.exports.answer() // <-- this is where the magic of this entire patch is
2209         (ExportedAnswerI32):
2210         * wasm/js-api/test_basic_api.js: punt test to later
2211         (const.c.in.constructorProperties.switch):
2212         * wasm/self-test/test_BuilderWebAssembly.js: UTF-8
2213         (CustomSection):
2214         * wasm/self-test/test_LowLevelBinary_string.js: UTF-8 now works
2215         * wasm/self-test/test_LowLevelBinary_uint16.js: was missing one value
2216         * wasm/self-test/test_LowLevelBinary_uint24.js: Copied from JSTests/wasm/self-test/test_LowLevelBinary_uint8.js.
2217         * wasm/self-test/test_LowLevelBinary_uint8.js: was missing one value
2218         * wasm/self-test/test_LowLevelBinary_varuint1.js: Added.
2219         * wasm/utilities.js: this `dump` thing was useful
2220         (const._dump):
2221
2222 2016-11-29  Saam Barati  <sbarati@apple.com>
2223
2224         We should be able optimize the pattern where we spread a function's rest parameter to another call
2225         https://bugs.webkit.org/show_bug.cgi?id=163865
2226
2227         Reviewed by Filip Pizlo.
2228
2229         * microbenchmarks/default-derived-constructor.js: Added.
2230         (createClassHierarchy.let.currentClass):
2231         (createClassHierarchy):
2232         * stress/call-varargs-spread.js: Added.
2233         (assert):
2234         (bar):
2235         (foo):
2236         * stress/load-varargs-on-new-array-with-spread-convert-to-static-loads.js: Added.
2237         (assert):
2238         (baz):
2239         (bar):
2240         (foo):
2241         * stress/new-array-with-spread-with-normal-spread-and-phantom-spread.js: Added.
2242         (assert):
2243         (foo):
2244         (escape):
2245         (bar):
2246         * stress/phantom-new-array-with-spread-osr-exit.js: Added.
2247         (assert):
2248         (baz):
2249         (bar):
2250         (effects):
2251         (foo):
2252         * stress/phantom-spread-forward-varargs.js: Added.
2253         (assert):
2254         (test1.bar):
2255         (test1.foo):
2256         (test1):
2257         (test2.bar):
2258         (test2.foo):
2259         (test3.baz):
2260         (test3.bar):
2261         (test3.foo):
2262         (test4.baz):
2263         (test4.bar):
2264         (test4.foo):
2265         (test5.baz):
2266         (test5.bar):
2267         (test5.foo):
2268         * stress/phantom-spread-osr-exit.js: Added.
2269         (assert):
2270         (baz):
2271         (bar):
2272         (effects):
2273         (foo):
2274         * stress/spread-call-convert-to-static-call.js: Added.
2275         (assert):
2276         (baz):
2277         (bar):
2278         (foo):
2279         * stress/spread-forward-call-varargs-stack-overflow.js: Added.
2280         (assert):
2281         (identity):
2282         (bar):
2283         (foo):
2284         * stress/spread-forward-varargs-rest-parameter-change-iterator-protocol-2.js: Added.
2285         (assert):
2286         (baz.Array.prototype.Symbol.iterator):
2287         (baz):
2288         (bar):
2289         (foo):
2290         (test):
2291         * stress/spread-forward-varargs-rest-parameter-change-iterator-protocol.js: Added.
2292         (assert):
2293         (baz.Array.prototype.Symbol.iterator):
2294         (baz):
2295         (bar):
2296         (foo):
2297         * stress/spread-forward-varargs-stack-overflow.js: Added.
2298         (assert):
2299         (bar):
2300         (foo):
2301
2302 2016-11-29  Caitlin Potter  <caitp@igalia.com>
2303
2304         [JSC] always wrap AwaitExpression operand in a new Promise
2305         https://bugs.webkit.org/show_bug.cgi?id=165181
2306
2307         Reviewed by Yusuke Suzuki.
2308
2309         * stress/async-await-basic.js:
2310         (async.awaitedPromisesAreWrapped):
2311
2312 2016-11-29  Keith Miller  <keith_miller@apple.com>
2313
2314         Add simple way to implement Wasm ops that require more than one B3 opcode
2315         https://bugs.webkit.org/show_bug.cgi?id=165129
2316
2317         Reviewed by Geoffrey Garen.
2318
2319         * wasm/function-tests/eqz.js: Added.
2320         * wasm/function-tests/max.js: Added.
2321         * wasm/function-tests/min.js: Added.
2322         * wasm/wasm.json:
2323
2324 2016-11-21  Yusuke Suzuki  <utatane.tea@gmail.com>
2325
2326         Crash in com.apple.JavaScriptCore: WTF::ThreadSpecific<WTF::WTFThreadData, + 142
2327         https://bugs.webkit.org/show_bug.cgi?id=164898
2328
2329         Reviewed by Darin Adler.
2330
2331         * stress/tagged-template-registry-key-collect.js: Added.
2332         (shouldBe):
2333         (tag):
2334         (i.eval):
2335         * stress/tagged-template-registry-key.js: Added.
2336         (shouldBe):
2337         (tag):
2338         (a):
2339         (b):
2340
2341 2016-11-20  Caitlin Potter  <caitp@igalia.com>
2342
2343         [JSC] speed up parsing of async functions
2344         https://bugs.webkit.org/show_bug.cgi?id=164808
2345
2346         Reviewed by Yusuke Suzuki.
2347
2348         Add tests for line terminator following "async" keyword in async
2349         function syntax.
2350
2351         * stress/async-await-syntax.js:
2352         (shouldBe):
2353
2354 2016-11-19  Mark Lam  <mark.lam@apple.com>
2355
2356         op_mod-* JSC tests needs a longer timeout too.
2357         https://bugs.webkit.org/show_bug.cgi?id=164994
2358
2359         Reviewed by Yusuke Suzuki.
2360
2361         * stress/op_mod-ConstVar.js:
2362         * stress/op_mod-VarConst.js:
2363         * stress/op_mod-VarVar.js:
2364
2365 2016-11-19  Mark Lam  <mark.lam@apple.com>
2366
2367         Add --timeoutMultiplier option to allow some tests more time to run.
2368         https://bugs.webkit.org/show_bug.cgi?id=164951
2369
2370         Reviewed by Yusuke Suzuki.
2371
2372         Extended the timeout for these tests by 50% more because they run quite slow on
2373         low-end machines.
2374
2375         * stress/op_div-ConstVar.js:
2376         * stress/op_div-VarConst.js:
2377         * stress/op_div-VarVar.js:
2378
2379 2016-11-18  Yusuke Suzuki  <utatane.tea@gmail.com>
2380
2381         REGRESSION(r208867): JSC test failure: ChakraCore.yaml/ChakraCore/test/strict/05.arguments_sm.js.default
2382         https://bugs.webkit.org/show_bug.cgi?id=164929
2383
2384         Reviewed by Mark Lam.
2385
2386         ES2017 drops arguments.caller and JavaScriptCore is updated to meet the spec.
2387         This patch rebaselines the result of ChakraCore test for JSC.
2388
2389         * ChakraCore/test/strict/05.arguments_sm.baseline-jsc:
2390
2391 2016-11-18  Joseph Pecoraro  <pecoraro@apple.com>
2392
2393         Web Inspector: Generator functions should have a displayable name when shown in stack traces
2394         https://bugs.webkit.org/show_bug.cgi?id=164844
2395         <rdar://problem/29300697>
2396
2397         Reviewed by Yusuke Suzuki.
2398
2399         * stress/generator-function-name.js:
2400         Add another test now that we name the inner generator function
2401         that we do not break the lexical resolution of names.
2402
2403 2016-11-17  Yusuke Suzuki  <utatane.tea@gmail.com>
2404
2405         [JSC] Drop arguments.caller
2406         https://bugs.webkit.org/show_bug.cgi?id=164859
2407
2408         Reviewed by Saam Barati.
2409
2410         * stress/strict-mode-arguments-caller.js: Added.
2411         (strictArguments):
2412         (shouldBe):
2413
2414 2016-11-17  Keith Miller  <keith_miller@apple.com>
2415
2416         Add rotate to Wasm
2417         https://bugs.webkit.org/show_bug.cgi?id=164871
2418
2419         Reviewed by Filip Pizlo.
2420
2421         * wasm/wasm.json:
2422
2423 2016-11-17  Keith Miller  <keith_miller@apple.com>
2424
2425         Add sqrt to Wasm
2426         https://bugs.webkit.org/show_bug.cgi?id=164877
2427
2428         Reviewed by Mark Lam.
2429
2430         B3 already has a Sqrt opcode we just need to map Wasm to it.
2431
2432         * wasm/wasm.json:
2433
2434 2016-11-17  Saam Barati  <sbarati@apple.com>
2435
2436         Remove async/await compile time flag and enable tests
2437         https://bugs.webkit.org/show_bug.cgi?id=164828
2438         <rdar://problem/28639334>
2439
2440         Reviewed by Yusuke Suzuki.
2441
2442         * stress/async-arrow-functions-lexical-arguments-binding.js:
2443         * stress/async-arrow-functions-lexical-new.target-binding.js:
2444         * stress/async-arrow-functions-lexical-super-binding.js:
2445         * stress/async-arrow-functions-lexical-this-binding.js:
2446         * stress/async-await-basic.js:
2447         * stress/async-await-long-loop.js:
2448         * stress/async-await-module-reserved-word.js:
2449         * stress/async-await-mozilla.js:
2450         (mozSyntaxErrors):
2451         * stress/async-await-reserved-word.js:
2452         * stress/async-await-syntax.js:
2453         * stress/async-await-throw-loop.js:
2454         * stress/async-function-create-nobaseline.js:
2455         * stress/async-function-create-optimized.js:
2456         * stress/async-function-declaration-sinking-no-double-allocate.js:
2457         * stress/async-function-declaration-sinking-osrexit.js:
2458         * stress/async-function-declaration-sinking-put.js:
2459         * stress/async-function-expression-sinking-no-double-allocate.js:
2460         * stress/async-function-expression-sinking-osrexit.js:
2461         * stress/async-function-expression-sinking-put.js:
2462         * test262.yaml:
2463
2464 2016-11-15  Mark Lam  <mark.lam@apple.com>
2465
2466         Make JSC test functions more robust.
2467         https://bugs.webkit.org/show_bug.cgi?id=164807
2468
2469         Reviewed by Keith Miller.
2470
2471         * stress/jsc-test-functions-should-be-more-robust.js: Added.
2472
2473 2016-11-15  Keith Miller  <keith_miller@apple.com>
2474
2475         B3 should support UDiv/UMod
2476         https://bugs.webkit.org/show_bug.cgi?id=164811
2477
2478         Reviewed by Filip Pizlo.
2479
2480         Link new instructions to wasm.
2481
2482         * wasm/wasm.json:
2483
2484 2016-11-15  Saam Barati  <sbarati@apple.com>
2485
2486         Debug JSC test timeout: stress/has-own-property-name-cache-symbols-and-strings.js.ftl-no-cjit-small-pool
2487         https://bugs.webkit.org/show_bug.cgi?id=163012
2488
2489         Unreviewed. This patch makes a test run for less time because it's timing out on the bots.
2490
2491         * stress/has-own-property-name-cache-symbols-and-strings.js:
2492
2493 2016-11-15  Mark Lam  <mark.lam@apple.com>
2494
2495         The jsc shell's setImpureGetterDelegate() should ensure that the set value is an ImpureGetter.
2496         https://bugs.webkit.org/show_bug.cgi?id=164781
2497         <rdar://problem/28418590>
2498
2499         Reviewed by Geoffrey Garen and Michael Saboff.
2500
2501         * stress/jsc-setImpureGetterDelegate-on-bad-type.js: Added.
2502
2503 2016-11-15  Yusuke Suzuki  <utatane.tea@gmail.com>
2504
2505         [DOMJIT] Allow using macro assembler scratches in FTL CheckDOM
2506         https://bugs.webkit.org/show_bug.cgi?id=164727
2507
2508         Reviewed by Filip Pizlo.
2509
2510         * stress/check-dom-with-signature.js: Added.
2511         (shouldBe):
2512         (calling):
2513         (i.array.forEach):
2514
2515 2016-11-14  Caitlin Potter  <caitp@igalia.com>
2516
2517         [JSC] do not reference AwaitExpression Promises in async function Promise chain
2518         https://bugs.webkit.org/show_bug.cgi?id=164753
2519
2520         Reviewed by Yusuke Suzuki.
2521
2522         * asyncFunctionTests.yaml:
2523         * stress/async-await-long-loop.js: Added.
2524         (shouldBe):
2525         (async.longLoop):
2526         * stress/async-await-throw-loop.js: Added.
2527         (shouldBe):
2528         (async.thrower):
2529         (async.throwLoop):
2530
2531 2016-11-14  Keith Miller  <keith_miller@apple.com>
2532
2533         Add Wasm select
2534         https://bugs.webkit.org/show_bug.cgi?id=164743
2535
2536         Reviewed by Saam Barati.
2537
2538         * wasm/function-tests/select.js: Added.
2539
2540 2016-11-14  Caitlin Potter  <caitp@igalia.com>
2541
2542         [JSC] Handle new_async_func / new_async_func_exp in DFG / FTL
2543         https://bugs.webkit.org/show_bug.cgi?id=164037
2544
2545         Reviewed by Yusuke Suzuki.
2546
2547         Add tests based on tests from https://trac.webkit.org/changeset/194216.
2548
2549         * asyncFunctionTests.yaml:
2550         * stress/async-function-create-nobaseline.js: Added.
2551         * stress/async-function-create-optimized.js: Added.
2552         * stress/async-function-declaration-sinking-no-double-allocate.js: Added.
2553         * stress/async-function-declaration-sinking-osrexit.js: Added.
2554         * stress/async-function-declaration-sinking-put.js: Added.
2555         * stress/async-function-expression-sinking-no-double-allocate.js: Added.
2556         * stress/async-function-expression-sinking-osrexit.js: Added.
2557         * stress/async-function-expression-sinking-put.js: Added.
2558
2559 2016-11-14  Mark Lam  <mark.lam@apple.com>
2560
2561         Some of JSStringView::SafeView methods are not idiomatically safe for JSString to StringView conversions.
2562         https://bugs.webkit.org/show_bug.cgi?id=164701
2563         <rdar://problem/27462104>
2564
2565         Reviewed by Darin Adler.
2566
2567         * stress/string-prototype-charCodeAt-on-too-long-rope.js: Added.
2568
2569 2016-11-14  Mark Lam  <mark.lam@apple.com>
2570
2571         RegExpObject::exec/match should handle errors gracefully.
2572         https://bugs.webkit.org/show_bug.cgi?id=155145
2573         <rdar://problem/27435934>
2574
2575         Reviewed by Keith Miller.
2576
2577         * stress/regexp-prototype-exec-on-too-long-rope.js: Added.
2578         * stress/regexp-prototype-match-on-too-long-rope.js: Added.
2579         * stress/regexp-prototype-test-on-too-long-rope.js: Added.
2580
2581 2016-11-14  Mark Lam  <mark.lam@apple.com>
2582
2583         Enhance run-jsc-stress-test script to allow optional test specific options to be added for all test run configurations.
2584         https://bugs.webkit.org/show_bug.cgi?id=164695
2585
2586         Reviewed by Keith Miller.
2587
2588         Replace use of runMisc* test run configurations with equivalents.
2589
2590         * stress/licm-no-pre-header-nested.js:
2591         * stress/licm-no-pre-header.js:
2592         * stress/licm-pre-header-cannot-exit-nested.js:
2593         * stress/licm-pre-header-cannot-exit.js:
2594         * stress/make-dictionary-repatch.js:
2595         * stress/retry-cache-later.js:
2596         * stress/shadow-chicken-reading-from-scope-after-ftl-osr-exit-bytecode-liveness.js:
2597         * stress/slow-path-generator-updating-current-node-dfg.js:
2598         * stress/unshift-array-storage.js:
2599
2600 2016-11-11  Joseph Pecoraro  <pecoraro@apple.com>
2601
2602         test262: DataView with explicit undefined byteLength should be the same as it not being present
2603         https://bugs.webkit.org/show_bug.cgi?id=164453
2604
2605         Reviewed by Darin Adler.
2606
2607         * stress/dataview-construct.js: Added.
2608         (assert):
2609         (shouldThrow):
2610         * test262.yaml:
2611
2612 2016-11-11  Joseph Pecoraro  <pecoraro@apple.com>
2613
2614         test262: DataView get methods should allow for missing offset, set methods should allow for missing value
2615         https://bugs.webkit.org/show_bug.cgi?id=164451
2616
2617         Reviewed by Darin Adler.
2618
2619         * test262.yaml:
2620
2621 2016-11-11  Saam Barati  <sbarati@apple.com>
2622
2623         We should have a more concise way of determining when we're varargs calling a function using rest parameters
2624         https://bugs.webkit.org/show_bug.cgi?id=164258
2625
2626         Reviewed by Yusuke Suzuki.
2627
2628         * microbenchmarks/call-using-spread.js: Added.
2629         (bar):
2630         (foo):
2631         * microbenchmarks/spread-large-array.js: Added.
2632         (foo):
2633         (arrays.push):
2634         * microbenchmarks/spread-small-array.js: Added.
2635         (foo):
2636         * stress/spread-array-iterator-watchpoint-2.js: Added.
2637         (foo):
2638         (arrayIterator.next):
2639         * stress/spread-array-iterator-watchpoint.js: Added.
2640         (foo):
2641         (Array.prototype.Symbol.iterator):
2642         * stress/spread-non-array.js: Added.
2643         (assert):
2644         (foo):
2645         (let.customIterator.Symbol.iterator):
2646         (bar):
2647
2648 2016-11-11  Keith Miller  <keith_miller@apple.com>
2649
2650         Relocate wasm tests and actually add them to the test runner
2651         https://bugs.webkit.org/show_bug.cgi?id=164668
2652
2653         Reviewed by Yusuke Suzuki.
2654
2655         This moves the Wasm tests from their current location down a level.
2656         Without relocating, the tests cannot properly be run by the wasm test runner.
2657
2658         * wasm.yaml:
2659         * wasm/Builder.js: Fix typos, yay lazy synatx checking!
2660         * wasm/LowLevelBinary.js: Fix typos, yay lazy synatx checking!
2661         (export.default.LowLevelBinary.prototype.get return):
2662         * wasm/function-tests/add-12.js: Renamed from JSTests/wasm/js-api/function-tests/add-12.js.
2663         * wasm/function-tests/br-if-loop-less-than.js: Renamed from JSTests/wasm/js-api/function-tests/br-if-loop-less-than.js.
2664         * wasm/function-tests/brTableAsIf.js: Renamed from JSTests/wasm/js-api/function-tests/brTableAsIf.js.
2665         * wasm/function-tests/brTableManyValues.js: Renamed from JSTests/wasm/js-api/function-tests/brTableManyValues.js.
2666         * wasm/function-tests/brTableWithLoop.js: Renamed from JSTests/wasm/js-api/function-tests/brTableWithLoop.js.
2667         * wasm/function-tests/dumb-eq-if-then-else.js: Renamed from JSTests/wasm/js-api/function-tests/dumb-eq-if-then-else.js.
2668         * wasm/function-tests/dumb-less-than-fallthrough.js: Renamed from JSTests/wasm/js-api/function-tests/dumb-less-than-fallthrough.js.
2669         * wasm/function-tests/dumb-less-than-ite.js: Renamed from JSTests/wasm/js-api/function-tests/dumb-less-than-ite.js.
2670         * wasm/function-tests/factorial.js: Renamed from JSTests/wasm/js-api/function-tests/factorial.js.
2671         * wasm/function-tests/float-sub.js: Renamed from JSTests/wasm/js-api/function-tests/float-sub.js.
2672         * wasm/function-tests/i32-load.js: Renamed from JSTests/wasm/js-api/function-tests/i32-load.js.
2673         * wasm/function-tests/i32-load8-s.js: Renamed from JSTests/wasm/js-api/function-tests/i32-load8-s.js.
2674         * wasm/function-tests/if-then-else-fallthrough.js: Renamed from JSTests/wasm/js-api/function-tests/if-then-else-fallthrough.js.
2675         * wasm/function-tests/if-then-fallthrough.js: Renamed from JSTests/wasm/js-api/function-tests/if-then-fallthrough.js.
2676         * wasm/function-tests/loop-mult.js: Renamed from JSTests/wasm/js-api/function-tests/loop-mult.js.
2677         * wasm/function-tests/loop-sum.js: Renamed from JSTests/wasm/js-api/function-tests/loop-sum.js.
2678         * wasm/function-tests/ret5.js: Renamed from JSTests/wasm/js-api/function-tests/ret5.js.
2679         * wasm/self-test/test_BuilderJSON.js: Rebasline
2680
2681 2016-11-11  Keith Miller  <keith_miller@apple.com>
2682
2683         Move Wasm tests to JS
2684         https://bugs.webkit.org/show_bug.cgi?id=164611
2685
2686         Reviewed by Geoffrey Garen.
2687
2688         This patch translates most of the tests from testWasm.cpp to the JS testing api. Most of the
2689         ommited tests were earliest tests, which tested trivial things, like adding two
2690         constants. Some tests are ommited for other reasons, however. These are:
2691
2692         1) Tests using I64 since the testing api does not yet know how to handle 64-bit numbers.  2)
2693         Tests that would validate the memory of the module once wasm was done with it since that's
2694         not really possible in JS.
2695
2696         In order to make such a translation easier this patch also adds some features to the JS
2697         testing api:
2698
2699         1) Blocks can now be done lexically by adding a lambda as the last argument of the block
2700         opcode. For example one can do:
2701             ...
2702             .Block("i32", b => b.I32Const(1) )
2703
2704         and the nested lambda will automatically have an end attached.
2705
2706         2) The JS testing api can now handle inline signature types.
2707
2708         3) Relocate some code to make it easier to follow and prevent 44 space indentation.
2709
2710         4) Rename varuint/varint to varuint32/varint32, this lets them be directly called from the
2711         wasm.json without being remapped.
2712
2713         5) Add support for Memory and Function sections to the Builder.
2714
2715         6) Add support for local variables.
2716
2717         On the JSC side, we needed to expose a new function to validate the compiled wasm code
2718         behaves the way we expect. At least until the JS Wasm API is finished. The new validation
2719         function, testWasmModuleFunctions, takes an array buffer containing the wasm binary, the
2720         number of functions in the blob and tests for each of those functions.
2721
2722         * wasm/Builder.js:
2723         (const._maybeRegisterType):
2724         (const): Deleted.
2725         (switch.typeof): Deleted.
2726         * wasm/Builder_WebAssemblyBinary.js:
2727         (const.emitters.Type):
2728         (const.emitters.Import):
2729         (const.emitters.Function):
2730         (const.emitters.Memory):
2731         (const.emitters.Code):
2732         (export.const.Binary):
2733         * wasm/LowLevelBinary.js:
2734         (export.default.LowLevelBinary.prototype.get return):
2735         (export.default.LowLevelBinary.prototype.varuint32):
2736         (export.default.LowLevelBinary.prototype.varint32):
2737         (export.default.LowLevelBinary.prototype.varuint1):
2738         (export.default.LowLevelBinary.prototype.varint7):
2739         (export.default.LowLevelBinary.prototype.varuint7):
2740         (export.default.LowLevelBinary.prototype.inline_signature_type):
2741         (export.default.LowLevelBinary.prototype.string):
2742         (export.default.LowLevelBinary.prototype.getVaruint32):
2743         (export.default.LowLevelBinary.prototype.getVarint32):
2744         (export.default.LowLevelBinary.prototype.getVaruint7):
2745         (export.default.LowLevelBinary.prototype.getString):
2746         (export.default.LowLevelBinary):
2747         (export.default.LowLevelBinary.prototype.varuint): Deleted.
2748         (export.default.LowLevelBinary.prototype.varint): Deleted.
2749         (export.default.LowLevelBinary.prototype.getVaruint): Deleted.
2750         (export.default.LowLevelBinary.prototype.getVarint): Deleted.
2751         * wasm/js-api/test_old_tests.js: Added.
2752         (ret5):
2753         (brTableWithLoop):
2754         (brTableManyValues):
2755         (run.brTableManyValues.brTableAsIf):
2756         (ifThenFallthrough):
2757         (ifThenElseFallthrough):
2758         (dumbLessThanFallthrough):
2759         (run.dumbLessThanFallthrough.floatSub):
2760         (run.floatSub.add12):
2761         (run.add12.factorial):
2762         (i32load):
2763         (run.i32load.i32load8s):
2764         (run.i32load8s.dumbEqIfThenElse):
2765         (run.dumbEqIfThenElse.dumbEqIfThenElse):
2766         (run.dumbEqIfThenElse.dumbLessThanIfThenElse):
2767         (run.dumbLessThanIfThenElse.loopSum):
2768         (run.loopSum.loopMult):
2769         (brIfLoopLessThan):
2770         (run.brIfLoopLessThan.run):
2771         * wasm/self-test/test_LowLevelBinary_varint32.js: Renamed from JSTests/wasm/self-test/test_LowLevelBinary_varint.js.
2772         * wasm/self-test/test_LowLevelBinary_varuint32.js: Renamed from JSTests/wasm/self-test/test_LowLevelBinary_varuint.js.
2773
2774         * wasm/Builder.js:
2775         (const._maybeRegisterType):
2776         (const): Deleted.
2777         (switch.typeof): Deleted.
2778         * wasm/Builder_WebAssemblyBinary.js:
2779         (const.emitters.Type):
2780         (const.emitters.Import):
2781         (const.emitters.Function):
2782         (const.emitters.Memory):
2783         (const.emitters.Code):
2784         (export.const.Binary):
2785         * wasm/LowLevelBinary.js:
2786         (export.default.LowLevelBinary.prototype.get return):
2787         (export.default.LowLevelBinary.prototype.varuint32):
2788         (export.default.LowLevelBinary.prototype.varint32):
2789         (export.default.LowLevelBinary.prototype.varuint1):
2790         (export.default.LowLevelBinary.prototype.varint7):
2791         (export.default.LowLevelBinary.prototype.varuint7):
2792         (export.default.LowLevelBinary.prototype.inline_signature_type):
2793         (export.default.LowLevelBinary.prototype.string):
2794         (export.default.LowLevelBinary.prototype.getVaruint32):
2795         (export.default.LowLevelBinary.prototype.getVarint32):
2796         (export.default.LowLevelBinary.prototype.getVaruint7):
2797         (export.default.LowLevelBinary.prototype.getString):
2798         (export.default.LowLevelBinary):
2799         (export.default.LowLevelBinary.prototype.varuint): Deleted.
2800         (export.default.LowLevelBinary.prototype.varint): Deleted.
2801         (export.default.LowLevelBinary.prototype.getVaruint): Deleted.
2802         (export.default.LowLevelBinary.prototype.getVarint): Deleted.
2803         * wasm/js-api/function-tests/add-12.js: Added.
2804         * wasm/js-api/function-tests/br-if-loop-less-than.js: Added.
2805         * wasm/js-api/function-tests/brTableAsIf.js: Added.
2806         * wasm/js-api/function-tests/brTableManyValues.js: Added.
2807         * wasm/js-api/function-tests/brTableWithLoop.js: Added.
2808         * wasm/js-api/function-tests/dumb-eq-if-then-else.js: Added.
2809         * wasm/js-api/function-tests/dumb-less-than-fallthrough.js: Added.
2810         * wasm/js-api/function-tests/dumb-less-than-ite.js: Added.
2811         * wasm/js-api/function-tests/factorial.js: Added.
2812         * wasm/js-api/function-tests/float-sub.js: Added.
2813         * wasm/js-api/function-tests/i32-load.js: Added.
2814         * wasm/js-api/function-tests/i32-load8-s.js: Added.
2815         * wasm/js-api/function-tests/if-then-else-fallthrough.js: Added.
2816         * wasm/js-api/function-tests/if-then-fallthrough.js: Added.
2817         * wasm/js-api/function-tests/loop-mult.js: Added.
2818         * wasm/js-api/function-tests/loop-sum.js: Added.
2819         * wasm/js-api/function-tests/ret5.js: Added.
2820         * wasm/self-test/test_LowLevelBinary_varint32.js: Renamed from JSTests/wasm/self-test/test_LowLevelBinary_varint.js.
2821         * wasm/self-test/test_LowLevelBinary_varuint32.js: Renamed from JSTests/wasm/self-test/test_LowLevelBinary_varuint.js.
2822
2823 2016-11-11  Saam Barati  <sbarati@apple.com>
2824
2825         We recursively grab a lock in the DFGBytecodeParser causing us to deadlock
2826         https://bugs.webkit.org/show_bug.cgi?id=164650
2827
2828         Reviewed by Geoffrey Garen.
2829
2830         * stress/dont-dead-lock-put-by-val-as-put-by-id.js: Added.
2831         (ident):
2832         (let.o.set foo):
2833         (foo):
2834
2835 2016-11-11  Chris Dumez  <cdumez@apple.com>
2836
2837         Unreviewed, rolling out r208584.
2838
2839         Seems to have regressed Speedometer by 1% on Mac
2840
2841         Reverted changeset:
2842
2843         "We should have a more concise way of determining when we're
2844         varargs calling a function using rest parameters"
2845         https://bugs.webkit.org/show_bug.cgi?id=164258
2846         http://trac.webkit.org/changeset/208584
2847
2848 2016-11-11  Chris Dumez  <cdumez@apple.com>
2849
2850         Unreviewed, rolling out r208117 and r208160.
2851
2852         Regressed Speedometer by >1.5%
2853
2854         Reverted changesets:
2855
2856         "We should have a way of profiling when a get_by_id is pure
2857         and to emit a PureGetById in the DFG/FTL"
2858         https://bugs.webkit.org/show_bug.cgi?id=163305
2859         http://trac.webkit.org/changeset/208117
2860
2861         "Debug JSC test microbenchmarks/pure-get-by-id-cse-2.js timing
2862         out"
2863         https://bugs.webkit.org/show_bug.cgi?id=164227
2864         http://trac.webkit.org/changeset/208160
2865
2866 2016-11-11  Saam Barati  <sbarati@apple.com>
2867
2868         We should have a more concise way of determining when we're varargs calling a function using rest parameters
2869         https://bugs.webkit.org/show_bug.cgi?id=164258
2870
2871         Reviewed by Yusuke Suzuki.
2872
2873         * microbenchmarks/call-using-spread.js: Added.
2874         (bar):
2875         (foo):
2876         * microbenchmarks/spread-large-array.js: Added.
2877         (foo):
2878         (arrays.push):
2879         * microbenchmarks/spread-small-array.js: Added.
2880         (foo):
2881         * stress/spread-array-iterator-watchpoint-2.js: Added.
2882         (foo):
2883         (arrayIterator.next):
2884         * stress/spread-array-iterator-watchpoint.js: Added.
2885         (foo):
2886         (Array.prototype.Symbol.iterator):
2887         * stress/spread-non-array.js: Added.
2888         (assert):
2889         (foo):
2890         (let.customIterator.Symbol.iterator):
2891         (bar):
2892
2893 2016-11-10  Mark Lam  <mark.lam@apple.com>
2894
2895         Fix broken have-a-bad-time-with-arguments.js test.
2896         https://bugs.webkit.org/show_bug.cgi?id=164626
2897
2898         Reviewed by Filip Pizlo.
2899
2900         But also saved a copy of the broken one as broken-have-a-bad-time-with-arguments-for-gc-testing.js
2901         because coincidentally, it stresses the GC in ways that help reveal bugs.
2902
2903         * stress/broken-have-a-bad-time-with-arguments-for-gc-testing.js: Added.
2904         (testFunction):
2905         (warmupFunction):
2906         (let.argsDeclIndex.in.argumentsDecls.let.indexToReturnIndex.in.indicesToReturn.let.insertElementActionIndex.in.insertElementActions.let.tierWarmupCountIndex.in.tierWarmupCounts.let.testArgsIndex.in.testArgsList.catch):
2907         * stress/have-a-bad-time-with-arguments.js:
2908
2909 2016-11-10  JF Bastien  <jfbastien@apple.com>
2910
2911         ASSERTION FAILED: length > offset encountered with wasm.yaml/wasm/js-api/test_Module.js.default-wasm
2912         https://bugs.webkit.org/show_bug.cgi?id=164597
2913
2914         Reviewed by Keith Miller.
2915
2916         Trim the array buffer before returning it: it's optimistically
2917         over-allocated to avoid growing all the time, but when parsed it
2918         can't have extra content.
2919
2920         * wasm/Builder_WebAssemblyBinary.js:
2921         (export.const.Binary):
2922         * wasm/LowLevelBinary.js:
2923         (export.default.LowLevelBinary.prototype.get return):
2924
2925 2016-11-10  Joseph Pecoraro  <pecoraro@apple.com>
2926
2927         test262: DataView / TypedArray methods should throw RangeErrors for negative numbers (ToIndex)
2928         https://bugs.webkit.org/show_bug.cgi?id=164450
2929
2930         Reviewed by Darin Adler.
2931
2932         * stress/dataview-typedarray-toindex.js: Added.
2933         Tests for all cases where ToIndex should be used.
2934
2935         * test262.yaml:
2936         New passing tests.
2937
2938 2016-11-10  Mark Lam  <mark.lam@apple.com>
2939
2940         Graph::methodOfGettingAValueProfileFor() should be returning the profile for the operand node.
2941         https://bugs.webkit.org/show_bug.cgi?id=164600
2942         <rdar://problem/28828676>
2943
2944         Reviewed by Filip Pizlo.
2945
2946         * stress/osr-exit-on-op-negate-should-no-fail-assertions.js: Added.
2947
2948 2016-11-08  Yusuke Suzuki  <utatane.tea@gmail.com>
2949
2950         [JSC] Avoid cloned arguments allocation in ArrayPrototype methods
2951         https://bugs.webkit.org/show_bug.cgi?id=164502
2952
2953         Reviewed by Saam Barati.
2954
2955         * stress/argument-intrinsic-basic.js: Added.
2956         (shouldBe):
2957         (builtin.createBuiltin):
2958         * stress/argument-intrinsic-inlining-with-result-escape.js: Added.
2959         (shouldBe):
2960         (builtin.createBuiltin):
2961         (escape):
2962         * stress/argument-intrinsic-nested-inlining.js: Added.
2963         (shouldBe):
2964         (builtin.createBuiltin):
2965         (builtinCaller1):
2966         (builtinCaller2):
2967         (escape):
2968         * stress/argument-intrinsic-not-convert-to-get-argument.js: Added.
2969         (shouldBe):
2970         (builtin.createBuiltin):
2971         * stress/argument-intrinsic-with-stack-write.js: Added.
2972         (shouldBe):
2973         (builtin.createBuiltin):
2974
2975 2016-11-09  Saam Barati  <sbarati@apple.com>
2976
2977         Math.min()/Math.max() with no arguments is lowered incorrectly in the BytecodeParser
2978         https://bugs.webkit.org/show_bug.cgi?id=164464
2979         <rdar://problem/29131452>
2980
2981         Reviewed by Darin Adler.
2982
2983         * stress/math-max-min-no-arguments.js: Added.
2984         (assert):
2985         (min):
2986         (max):
2987         (test):
2988
2989 2016-11-09  Saam Barati  <sbarati@apple.com>
2990
2991         TypeProfiler and running GC collection on another thread don't play nicely with each other
2992         https://bugs.webkit.org/show_bug.cgi?id=164441
2993         <rdar://problem/29132174>
2994
2995         Reviewed by Geoffrey Garen.
2996
2997         * typeProfiler/type-profiler-gc.js: Added.
2998         (bar):
2999         (foo):
3000
3001 2016-11-04  Mark Lam  <mark.lam@apple.com>
3002
3003         Error description code should be able to handle Symbol values.
3004         https://bugs.webkit.org/show_bug.cgi?id=164436
3005         <rdar://problem/29115583>
3006
3007         Reviewed by Filip Pizlo and Saam Barati.
3008
3009         * stress/error-description-on-symbols-should-not-crash.js: Added.
3010
3011 2016-11-03  Geoffrey Garen  <ggaren@apple.com>
3012
3013         EvalCodeCache should not give up in strict mode and other cases
3014         https://bugs.webkit.org/show_bug.cgi?id=164357
3015
3016         Reviewed by Michael Saboff.
3017
3018         * microbenchmarks/eval-cached.js: Added. 45x faster now.
3019         * stress/eval-cached.js: Added. Try running the same eval text in a bunch
3020         of different scopes and verify that we access the right scope.
3021
3022 2016-11-04  JF Bastien  <jfbastien@apple.com>
3023
3024         WebAssembly JS API: implement more sections
3025         https://bugs.webkit.org/show_bug.cgi?id=164023
3026
3027         Reviewed by Keith Miller.
3028
3029         On the JSC side:
3030
3031          - Put in parser stubs for all WebAssembly sections.
3032          - Parse Import, Export sections.
3033          - Use tryReserveCapacity instead of reserve, and bail out of the parser if it fails. This prevents the parser from bringing everything down when faced with a malicious input.
3034          - Encapsulate all parsed module information into its own structure, making it easier to pass around (from parser to Plan to Module to Instance).
3035          - Create WasmFormat.cpp to hold parsed module information's dtor to avoid including WasmMemory.h needlessly.
3036          - parseCode: avoid overflow through function size.
3037          - Remove all remainders of polyfill-prototype-1, and update license.
3038          - Add missing WasmOps.h and WasmValidateInlines.h auto-generation for cmake build.
3039
3040         On the Builder.js testing side:
3041
3042          - Implement Type, Import (function only), Export (function only) sections.
3043          - Check section order and uniqueness.
3044          - Optionally auto-generate the Type section from subsequent Export / Import / Code entries.
3045          - Allow re-exporting an import.
3046
3047         * wasm/Builder.js: build type, import, and export sections
3048         (const._normalizeFunctionSignature):
3049         * wasm/Builder_WebAssemblyBinary.js: Added. Forked from Builder.js
3050         (const.emitters.Type):
3051         (const.emitters.Import):
3052         (const.emitters.Function):
3053         (const.emitters.Table):
3054         (const.emitters.Memory):
3055         (const.emitters.Global):
3056         (const.emitters.Export):
3057         (const.emitters.Start):
3058         (const.emitters.Element):
3059         (const.emitters.Code):
3060         (const.emitters.Data):
3061         (export.const.Binary):
3062         * wasm/LowLevelBinary.js: Add a few useful outputs
3063         (export.default.LowLevelBinary.prototype.varuint1):
3064         (export.default.LowLevelBinary.prototype.varint7):
3065         * wasm/WASM.js: value type and external kind helpers
3066         * wasm/assert.js: array element-wise equality comparison
3067         (const._eq):
3068         * wasm/js-api/test_Module.js:
3069         (ModuleWithImports):
3070         * wasm/self-test/test_BuilderJSON.js: many more tests for all the new Builder APIs, and update to some older tests which now require a Type section or rejiggered Function signature
3071         (const.assertOpThrows):
3072         (SectionsWithSameCustomName):
3073         (TwoTypeSections):
3074         (EmptyImportSection):
3075         (ImportBeforeTypeSections):
3076         * wasm/self-test/test_BuilderWebAssembly.js: remove a test which wasn't helpful and is now obsolete
3077         (CustomSection):
3078
3079 2016-11-03  Mark Lam  <mark.lam@apple.com>
3080
3081         ClonedArguments need to also support haveABadTime mode.
3082         https://bugs.webkit.org/show_bug.cgi?id=164200
3083         <rdar://problem/27211336>
3084
3085         Reviewed by Geoffrey Garen.
3086
3087         * stress/have-a-bad-time-with-arguments.js: Added.
3088
3089 2016-11-03  Filip Pizlo  <fpizlo@apple.com>
3090
3091         DFG plays fast and loose with the shadow values of a Phi
3092         https://bugs.webkit.org/show_bug.cgi?id=164309
3093
3094         Reviewed by Saam Barati.
3095         
3096         This test demonstrates why the DFG needs to recognize the shadow value of a Phi.
3097
3098         * stress/dfg-ssa-swap.js: Added.
3099         (foo):
3100
3101 2016-11-03  Commit Queue  <commit-queue@webkit.org>
3102
3103         Unreviewed, rolling out r208364.
3104         https://bugs.webkit.org/show_bug.cgi?id=164402
3105
3106         broke the build (Requested by smfr on #webkit).
3107
3108         Reverted changeset:
3109
3110         "DFG plays fast and loose with the shadow values of a Phi"
3111         https://bugs.webkit.org/show_bug.cgi?id=164309
3112         http://trac.webkit.org/changeset/208364
3113
3114 2016-11-03  Filip Pizlo  <fpizlo@apple.com>
3115
3116         DFG plays fast and loose with the shadow values of a Phi
3117         https://bugs.webkit.org/show_bug.cgi?id=164309
3118
3119         Reviewed by Saam Barati.
3120         
3121         This test demonstrates why the DFG needs to recognize the shadow value of a Phi.
3122
3123         * stress/dfg-ssa-swap.js: Added.
3124         (foo):
3125
3126 2016-11-03  Saam Barati  <sbarati@apple.com>
3127
3128         Asking for a value profile prediction should be defensive against not finding a value profile
3129         https://bugs.webkit.org/show_bug.cgi?id=164306
3130
3131         Reviewed by Mark Lam.
3132
3133         * stress/inlined-tail-call-in-inlined-setter-should-not-crash-when-getting-value-profile.js: Added.
3134         (let.o.set foo):
3135         (bar):
3136
3137 2016-11-02  Saam Barati  <sbarati@apple.com>
3138
3139         Allocation elimination of rest parameter doesn't take into account indexed properties on Array.prototype/Object.prototype
3140         https://bugs.webkit.org/show_bug.cgi?id=164301
3141
3142         Reviewed by Geoffrey Garen.
3143
3144         * stress/rest-parameter-allocation-elimination-watchpoints-2.js: Added.
3145         (assert):
3146         (foo):
3147         * stress/rest-parameter-allocation-elimination-watchpoints-3.js: Added.
3148         (assert):
3149         (foo):
3150         * stress/rest-parameter-allocation-elimination-watchpoints-4.js: Added.
3151         (assert):
3152         (foo):
3153         * stress/rest-parameter-allocation-elimination-watchpoints-5.js: Added.
3154         (assert):
3155         (foo):
3156         * stress/rest-parameter-allocation-elimination-watchpoints-6.js: Added.
3157         (assert):
3158         (foo):
3159         * stress/rest-parameter-allocation-elimination-watchpoints.js: Added.
3160         (assert):
3161         (foo):
3162
3163 2016-11-01  Saam Barati  <sbarati@apple.com>
3164
3165         We should be able to eliminate rest parameter allocations
3166         https://bugs.webkit.org/show_bug.cgi?id=163925
3167
3168         Reviewed by Filip Pizlo.
3169
3170         * microbenchmarks/rest-parameter-allocation-elimination.js: Added.
3171         (assert):
3172         (test1.bar):
3173         (test1):
3174         (test2.jaz):
3175         (test2.jaz2.kaz):
3176         (test2.jaz2):
3177         (test2):
3178         (test3.foo):
3179         (test3.baz):
3180         (test3.jaz):
3181         (test3):
3182         (test4.baz):
3183         (test4.jaz):
3184         (test4):
3185         (test5.baz):
3186         (test5.jaz):
3187         (test5):
3188         (test6.baz):
3189         (test6.jaz):
3190         (test6):
3191         (test7.baz):
3192         (test7.jaz):
3193         (test7.check):
3194         (test7):
3195         (test8.baz):
3196         (test8.jaz):
3197         (test8.check):
3198         (test8):
3199         (test9.baz):
3200         (test9.jaz):
3201         (test9.check):
3202         (test9):
3203         (test10.baz):
3204         (test10.jaz):
3205         (test10):
3206         (test11.bar):
3207         (test11.foo):
3208         (test11.makeArguments):
3209         (test11.):
3210         (test12):
3211         (test12.bar):
3212         (test12.foo):
3213         (test12.makeArguments):
3214         (test12.):
3215         (test13.bar):
3216         (test13.top):
3217         (test13.foo):
3218         (test13.makeArguments):
3219         (test13.):
3220         (test13):
3221         (test14.bar):
3222         (test14.top):
3223         (test14.foo):
3224         (test14.makeArguments):
3225         (test14.):
3226         (test14):
3227         (test15.bar):
3228         (test15.top):
3229         (test15.foo):
3230         (test15.makeArguments):
3231         (test15.):
3232         (test15):
3233
3234 2016-11-01  Commit Queue  <commit-queue@webkit.org>
3235
3236         Unreviewed, rolling out r208208 and r208210.
3237         https://bugs.webkit.org/show_bug.cgi?id=164276
3238
3239         This change caused 28 JSC test failures. (Requested by
3240         ryanhaddad on #webkit).
3241
3242         Reverted changesets:
3243
3244         "We should be able to eliminate rest parameter allocations"
3245         https://bugs.webkit.org/show_bug.cgi?id=163925
3246         http://trac.webkit.org/changeset/208208
3247
3248         "Fix the EFL build."
3249         http://trac.webkit.org/changeset/208210
3250
3251 2016-10-31  Filip Pizlo  <fpizlo@apple.com>
3252
3253         JSC should support SharedArrayBuffer
3254         https://bugs.webkit.org/show_bug.cgi?id=163986
3255
3256         Reviewed by Keith Miller.
3257         
3258         This adds our own test for the various corner cases of SharedArrayBuffer. This test is meant to
3259         check all of the things that don't require concurrency.
3260
3261         * stress/SharedArrayBuffer.js: Added.
3262         (checkAtomics):
3263         (shouldFail):
3264         (Symbol):
3265         (runAtomic):
3266
3267 2016-10-31  Saam Barati  <sbarati@apple.com>
3268
3269         We should be able to eliminate rest parameter allocations
3270         https://bugs.webkit.org/show_bug.cgi?id=163925
3271
3272         Reviewed by Filip Pizlo.
3273
3274         * microbenchmarks/rest-parameter-allocation-elimination.js: Added.
3275         (assert):
3276         (test1.bar):
3277         (test1):
3278         (test2.jaz):
3279         (test2.jaz2.kaz):
3280         (test2.jaz2):
3281         (test2):
3282         (test3.foo):
3283         (test3.baz):
3284         (test3.jaz):
3285         (test3):
3286         (test4.baz):
3287         (test4.jaz):
3288         (test4):
3289         (test5.baz):
3290         (test5.jaz):
3291         (test5):
3292         (test6.baz):
3293         (test6.jaz):
3294         (test6):
3295         (test7.baz):
3296         (test7.jaz):
3297         (test7.check):
3298         (test7):
3299         (test8.baz):
3300         (test8.jaz):
3301         (test8.check):
3302         (test8):
3303         (test9.baz):
3304         (test9.jaz):
3305         (test9.check):
3306         (test9):
3307         (test10.baz):
3308         (test10.jaz):
3309         (test10):
3310         (test11.bar):
3311         (test11.foo):
3312         (test11.makeArguments):
3313         (test11.):
3314         (test12):
3315         (test12.bar):
3316         (test12.foo):
3317         (test12.makeArguments):
3318         (test12.):
3319         (test13.bar):
3320         (test13.top):
3321         (test13.foo):
3322         (test13.makeArguments):
3323         (test13.):
3324         (test13):
3325         (test14.bar):
3326         (test14.top):
3327         (test14.foo):
3328         (test14.makeArguments):
3329         (test14.):
3330         (test14):
3331         (test15.bar):
3332         (test15.top):
3333         (test15.foo):
3334         (test15.makeArguments):
3335         (test15.):
3336         (test15):
3337
3338 2016-10-31  Saam Barati  <sbarati@apple.com>
3339
3340         Debug JSC test microbenchmarks/pure-get-by-id-cse-2.js timing out
3341         https://bugs.webkit.org/show_bug.cgi?id=164227
3342
3343         Unreviewed timeout fix.
3344
3345         * microbenchmarks/pure-get-by-id-cse-2.js:
3346
3347 2016-10-31  Keith Miller  <keith_miller@apple.com>
3348
3349         autogenerated files from wasm.json should be in derived sources.
3350         https://bugs.webkit.org/show_bug.cgi?id=164152
3351
3352         Reviewed by Filip Pizlo.
3353
3354         Delete generation script since it is no longer used.
3355
3356         * wasm/generate-wasmops-header.js: Removed.
3357
3358 2016-10-29  Yusuke Suzuki  <utatane.tea@gmail.com>
3359
3360         [JSC] JSON.stringify should handle Proxy which is non JSArray but isArray is true
3361         https://bugs.webkit.org/show_bug.cgi?id=164123
3362
3363         Reviewed by Mark Lam.
3364
3365         * stress/json-stringify-with-non-jsarray-array.js: Added.
3366         (shouldBe):
3367         (shouldBe.JSON.stringify.new.Proxy):
3368
3369 2016-10-29  Saam Barati  <sbarati@apple.com>
3370
3371         We should have a way of profiling when a get_by_id is pure and to emit a PureGetById in the DFG/FTL
3372         https://bugs.webkit.org/show_bug.cgi?id=163305
3373
3374         Reviewed by Keith Miller.
3375
3376         * microbenchmarks/pure-get-by-id-cse-2.js: Added.
3377         (foo):
3378         * microbenchmarks/pure-get-by-id-cse.js: Added.
3379         (foo):
3380         * stress/pure-get-by-id-cse-correctness.js: Added.
3381         (assert):
3382         (foo):
3383         * stress/pure-get-by-id-on-non-object.js: Added.
3384         (assert):
3385         (foo):
3386
3387 2016-10-28  Csaba Osztrogonác  <ossy@webkit.org>
3388
3389         Skip JSTests/microbenchmarks/dense-set.js on memory limited devices
3390         https://bugs.webkit.org/show_bug.cgi?id=164128
3391
3392         Reviewed by Mark Lam.
3393
3394         * microbenchmarks/dense-set.js:
3395
3396 2016-10-20  Caitlin Potter  <caitp@igalia.com>
3397
3398         [JSC] implement runtime for async functions
3399         https://bugs.webkit.org/show_bug.cgi?id=163760
3400
3401         Reviewed by Yusuke Suzuki.
3402
3403         * stress/async-await-basic.js: Added.
3404         (shouldBe):
3405         (shouldBeAsync):
3406         (shouldThrow):
3407         (shouldThrowAsync):
3408         (shouldThrowSyntaxError):
3409         (let.AsyncFunction.async):
3410         (async.asyncFunctionForProto):
3411         (Object.getPrototypeOf.async):
3412         (Object.getPrototypeOf.async.method):
3413         (async):
3414         (async.method):
3415         (async.asyncNonConstructorDecl):
3416         (shouldThrow.new.async):
3417         (shouldThrow.new.async.nonConstructor):
3418         (async.asyncDecl):
3419         (async.f):
3420         (MyError):
3421         (async.asyncDeclThrower):
3422         (shouldThrowAsync.async):
3423         (resolveLater):
3424         (rejectLater):
3425         (async.resumeAfterNormal):
3426         (O.async.resumeAfterNormal):
3427         (resumeAfterNormalArrow.async):
3428         (async.resumeAfterThrow):
3429         (O.async.resumeAfterThrow):
3430         (resumeAfterThrowArrow.async):
3431         (catch):
3432         * stress/async-await-module-reserved-word.js: Added.
3433         (shouldThrow):
3434         (SyntaxError.Canstring_appeared_hereawait.checkModuleSyntaxError.String.raw.await):
3435         (checkModuleSyntaxError.String.raw.await):
3436         (checkModuleSyntaxError.String.raw.async.await):
3437         (SyntaxError.Cannot.declare.named):
3438         * stress/async-await-mozilla.js: Added.
3439         (shouldBe):
3440         (shouldBeAsync):
3441         (shouldThrow):
3442         (shouldThrowAsync):
3443         (assert):
3444         (shouldThrowSyntaxError):
3445         (mozSemantics.async.empty):
3446         (mozSemantics.async.simpleReturn):
3447         (mozSemantics.async.simpleAwait):
3448         (mozSemantics.async.simpleAwaitAsync):
3449         (mozSemantics.async.returnOtherAsync):
3450         (mozSemantics.async.simpleThrower):
3451         (mozSemantics.async.delegatedThrower):
3452         (mozSemantics.async.tryCatch):
3453         (mozSemantics.async.tryCatchThrow):
3454         (mozSemantics.async.wellFinally):
3455         (mozSemantics.async.finallyMayFail):
3456         (mozSemantics.async.embedded.async.inner):
3457         (mozSemantics.async.embedded):
3458         (mozSemantics.async.fib):
3459         (mozSemantics.async.isOdd.async.isEven):
3460         (mozSemantics.async.isOdd):
3461         (mozSemantics.hardcoreFib.async.fib2):
3462         (mozSemantics.namedAsyncExpr.async.simple):
3463         (mozSemantics.async.executionOrder.async.first):
3464         (mozSemantics.async.executionOrder.async.second):
3465         (mozSemantics.async.executionOrder.async.third):
3466         (mozSemantics.async.executionOrder):
3467         (mozSemantics.async.miscellaneous):
3468         (mozSemantics.thrower):
3469         (mozSemantics.async.defaultArgs):
3470         (mozSemantics.shouldThrow):
3471         (mozSemantics):
3472         (mozMethods.X):
3473         (mozMethods.X.prototype.async.getValue):
3474         (mozMethods.X.prototype.setValue):
3475         (mozMethods.X.prototype.async.increment):
3476         (mozMethods.X.prototype.async.getBaseClassName):
3477         (mozMethods.X.async.getStaticValue):
3478         (mozMethods.Y.prototype.async.getBaseClassName):
3479         (mozMethods.Y):
3480         (mozFunctionNameInferrence.async.test):
3481         (mozSyntaxErrors):
3482         * stress/async-await-reserved-word.js: Added.
3483         (assert):
3484         (shouldThrowSyntaxError):
3485         (AsyncFunction.async):
3486         * stress/async_arrow_functions_lexical_arguments_binding.js: Added.
3487         (shouldBe):
3488         (shouldBeAsync):
3489         (shouldThrowAsync):
3490         (noArgumentsArrow2.async):
3491         * stress/async_arrow_functions_lexical_new.target_binding.js: Added.
3492         (shouldBe):
3493         (shouldBeAsync):
3494         (shouldThrowAsync):
3495         (C1):
3496         (C2):
3497         (shouldThrowAsync.async):
3498         * stress/async_arrow_functions_lexical_super_binding.js: Added.
3499         (shouldBe):
3500         (shouldBeAsync):
3501         (BaseClass.prototype.baseClassValue):
3502         (BaseClass.prototype.get property):
3503         (BaseClass):
3504         (ChildClass.prototype.asyncSuperProp):
3505         (ChildClass.prototype.asyncSuperProp2):
3506         (ChildClass):
3507         (ChildClass2):
3508         * stress/async_arrow_functions_lexical_this_binding.js: Added.
3509         (shouldBe):
3510         (shouldBeAsync):
3511         (d.y):
3512
3513 2016-10-28  Csaba Osztrogonác  <ossy@webkit.org>
3514
3515         Skip 2 JS stress tests on memory limited devices
3516         https://bugs.webkit.org/show_bug.cgi?id=164125
3517
3518         Unreviewed quick fix to unbreak JSCOnly ARM bots as soon as possible.
3519
3520         * stress/joined-strings-should-not-exceed-max-string-length.js:
3521         * stress/string-prototype-replace-should-throw-out-of-memory-error-when-using-too-much-memory.js:
3522
3523 2016-10-27  Caitlin Potter  <caitp@igalia.com>
3524
3525         [JSC] forbid lexical redeclaration of generator formal parameters
3526         https://bugs.webkit.org/show_bug.cgi?id=163930
3527
3528         Reviewed by Yusuke Suzuki.
3529
3530         * stress/async-await-syntax.js:
3531         * stress/generator-syntax.js:
3532         (testSyntaxError.gen):
3533         (testSyntaxError.arguments):
3534         (testSyntaxError.eval):
3535         * test262.yaml:
3536
3537 2016-10-26  JF Bastien  <jfbastien@apple.com>
3538
3539         WebAssembly API: implement Instance
3540
3541         As described in: https://github.com/WebAssembly/design/blob/master/JS.md#webassemblyinstance-objects
3542
3543          - Take ownership of Wasm::Plan's compilation result when successfully creating a JSWebAssemblyModule object.
3544          - Construct a basic Instance with a Module.
3545          - Handle second argument (importObject) of WebAssembly.Instance.
3546          - Add reference text from the spec to WebAssembly.Module's code.
3547          - Expose and test an empty 'exports' ModuleNamespaceObject on WebAssembly.Instance.
3548
3549         The implementation isn't complete yet: it relies on further work for which I've filed bugs.
3550
3551         WebAssembly API: implement Instance
3552         https://bugs.webkit.org/show_bug.cgi?id=163998
3553
3554         Reviewed by Keith Miller.
3555
3556         * wasm/js-api/test_Instance.js: Added.
3557         (EmptyModule): use the Builder, create the simplest Module possible, and create an Instance from it
3558         * wasm/js-api/test_basic_api.js:
3559         (const.c.in.constructorProperties.switch): basic tests of the API
3560
3561 2016-10-26  Mark Lam  <mark.lam@apple.com>
3562
3563         JSGenericTypedArrayView::set() should check for exceptions.
3564         https://bugs.webkit.org/show_bug.cgi?id=164007
3565         <rdar://problem/28853775>
3566
3567         Reviewed by Filip Pizlo.
3568
3569         * stress/typed-array-view-set-should-not-crash-on-exception.js: Added.
3570
3571 2016-10-25  Mark Lam  <mark.lam@apple.com>
3572
3573         String.prototype.replace() should throw an OutOfMemoryError when using too much memory.
3574         https://bugs.webkit.org/show_bug.cgi?id=163996
3575         <rdar://problem/28263117>
3576
3577         Reviewed by Geoffrey Garen.
3578
3579         * stress/string-prototype-replace-should-throw-out-of-memory-error-when-using-too-much-memory.js: Added.
3580
3581 2016-10-25  Mark Lam  <mark.lam@apple.com>
3582
3583         JSStringJoiner::joinedLength() should limit joined string lengths to INT_MAX.
3584         https://bugs.webkit.org/show_bug.cgi?id=163937
3585         <rdar://problem/28642990>
3586
3587         Reviewed by Geoffrey Garen.
3588
3589         * stress/joined-strings-should-not-exceed-max-string-length.js: Added.
3590
3591 2016-10-25  JF Bastien  <jfbastien@apple.com>
3592
3593         WebAssembly JS API: simple Module test
3594         https://bugs.webkit.org/show_bug.cgi?id=163963
3595
3596         Reviewed by Filip Pizlo.
3597
3598         * wasm/LowLevelBinary.js:
3599         (export.default.LowLevelBinary.prototype.get return): get the ArrayBuffer
3600         (export.default.LowLevelBinary.prototype.hexdump): Deleted.
3601         (export.default.LowLevelBinary.prototype._maybeGrow): Deleted.
3602         * wasm/js-api/test_Module.js: Added.
3603         (EmptyModule): The most basic module possible
3604
3605 2016-10-25  JF Bastien  <jfbastien@apple.com>
3606
3607         WebAssembly JS API: implement Module
3608
3609         This implementation allows us to:
3610          - Syncrhonously create a WebAssembly.Module with a typed array.
3611          - Creates a compilation plan.
3612          - Parse the Module and creates corresponding code.
3613          - Throw WebAssembly.CompileError with mildly helpful [*] error messages on
3614            failure.
3615
3616         Consult the API documentation for expected behavior: https://github.com/WebAssembly/design/blob/master/JS.md#webassemblymodule-constructor
3617
3618         For now the implementation discards the generated code.
3619
3620         The next steps will be:
3621          - Expose a Module's exports.
3622          - Implement WebAssembly.Instance, which allows instantiating and running a
3623            compiled Module.
3624          - Beef up the testing infrastructure under JSTests/wasm so that more complex
3625            modules can be created and tested (instead of writing the bits by hand).
3626
3627         This patch also:
3628          - Adds assert.instanceof in assert.js.
3629          - Refactors Wasm::Parser and friends to accept const uint8_t* as well as a
3630            Vector, to avoid copying when invoked synchronously.
3631          - Remove useless Structure from some of the wasm constructors: they're already
3632            on the JSGlobalObject, visited properly and all.
3633          - Fix off-by-one error in parsing: Parser::parseUInt32 failed if the integer
3634            was exactly at end of file.
3635
3636          [*] On error messages while parsing: I filed https://bugs.webkit.org/show_bug.cgi?id=163919
3637
3638         WebAssembly JS API: implement Module
3639         https://bugs.webkit.org/show_bug.cgi?id=163903
3640
3641         Reviewed by Keith Miller.
3642
3643         * wasm/assert.js: use underscore in name, and remove when exporting to avoid clasing with builtin names
3644         (const._notUndef):
3645         (const._isUndef):
3646         (const._eq):
3647         (const._ge):
3648         (const._throws):
3649         * wasm/js-api/test_basic_api.js: test the WebAssembly.Module API
3650         (const.c.in.constructorProperties.switch):
3651
3652 2016-10-25  Keith Miller  <keith_miller@apple.com>
3653
3654         Add trivial Wasm conversion opcodes
3655         https://bugs.webkit.org/show_bug.cgi?id=163950
3656
3657         Reviewed by Filip Pizlo.
3658
3659         This patch differentiates between Wasm opcodes that are trivially mapped to a B3 opcode and
3660         those that are not.  Some of the Wasm opcodes that are currently a non-simple opcode will
3661         become simple as we add B3 opcodes for Wasm operations.  The remaining opcodes will need to
3662         be added via patchpoints in a later patch.
3663
3664         * wasm/generate-wasmops-header.js:
3665         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.Wasm.inline.bool.isSimple):
3666         * wasm/wasm.json:
3667
3668 2016-10-24  Yusuke Suzuki  <utatane.tea@gmail.com>
3669
3670         Arrow functions with concise bodies cannot return regular expressions
3671         https://bugs.webkit.org/show_bug.cgi?id=163162
3672
3673         Reviewed by Filip Pizlo.
3674
3675         * ChakraCore/test/Operators/instanceof.baseline-jsc:
3676         * ChakraCore/test/Regex/nul_character.baseline-jsc:
3677         * ChakraCore/test/es5/Lex_u3.baseline-jsc:
3678         * stress/parse-regexp-as-token.js: Added.
3679         (shouldBe):
3680
3681 2016-10-24  Keith Miller  <keith_miller@apple.com>
3682
3683         Wasm should support floating point operations.
3684         https://bugs.webkit.org/show_bug.cgi?id=163770
3685
3686         Reviewed by Michael Saboff.
3687
3688         Add appropriate b3op names for floating point wasm bytecodes, where they exist.
3689         Also, fix some WASM => Wasm in WasmOps.h generator script that I missed
3690         the first time I made the change.
3691
3692         * wasm/generate-wasmops-header.js:
3693         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.template.typename.Int.inline.bool.isValidOpType): Deleted.
3694         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.enum.BinaryOpType): Deleted.
3695         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.enum.UnaryOpType): Deleted.
3696         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.enum.LoadOpType): Deleted.
3697         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.enum.StoreOpType): Deleted.
3698         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.undef.CREATE_ENUM_VALUE.inline.bool.isControlOp): Deleted.
3699         * wasm/wasm.json:
3700
3701 2016-10-21  Saam Barati  <sbarati@apple.com>
3702
3703         SpeculativeJIT::compileTryGetById needs to pass in NeedsToSpill along both the cell speculation and untyped speculation path
3704         https://bugs.webkit.org/show_bug.cgi?id=163622
3705
3706         Reviewed by Yusuke Suzuki.
3707
3708         * stress/try-get-by-id-should-spill-registers-dfg.js: Added.
3709         (let.f.createBuiltin):
3710
3711 2016-10-21  Caitlin Potter  <caitp@igalia.com>
3712
3713         [JSC] don't crash when arguments to `new Function()` produce unexpected AST
3714         https://bugs.webkit.org/show_bug.cgi?id=163748
3715
3716         Reviewed by Mark Lam.
3717
3718         * stress/regress-163748.js: Added.
3719         (assert):
3720         (shouldThrowSyntaxError):
3721         (GeneratorFunction):
3722
3723 2016-10-20  Keith Miller  <keith_miller@apple.com>
3724
3725         Add support for WASM calls
3726         https://bugs.webkit.org/show_bug.cgi?id=161727
3727
3728         Reviewed by Filip Pizlo and Michael Saboff.
3729
3730         Add members of the Call category to the WASMOps special group.
3731
3732         * wasm/generate-wasmops-header.js:
3733
3734 2016-10-20  Yusuke Suzuki  <utatane.tea@gmail.com>
3735
3736         [JSC] Drop isEnvironmentRecord type info flag and use JSType information instead
3737         https://bugs.webkit.org/show_bug.cgi?id=163761
3738
3739         Reviewed by Keith Miller.
3740
3741         * modules/string-prototype-module-scope.js: Added.
3742         (shouldBe):
3743         (catch):
3744         (refer):
3745         * stress/string-prototype-scopes-global-lexical-environment-strict.js: Added.
3746         (shouldBe):
3747         (catch):
3748         * stress/string-prototype-scopes-global-lexical-environment.js: Added.
3749         (shouldBe):
3750         (catch):
3751         * stress/string-prototype-scopes-strict.js: Added.
3752         (shouldBe):
3753         (catch):
3754         (try.refer):
3755         (refer):
3756         * stress/string-prototype-scopes.js: Added.
3757         (shouldBe):
3758         (catch):
3759         (try.refer):
3760         (refer):
3761         (object.toString):
3762         (with):
3763
3764 2016-10-20  JF Bastien  <jfbastien@apple.com>
3765
3766         WebAssembly API: implement exception constructors properly
3767
3768          - Rename WebAssemblyObject to JSWebAssembly for consistency.
3769          - WebAssembly object now has its own prototype: add WebAssemblyPrototype, and
3770            use it to register JSWebAssembly's function properties through auto-generated
3771            .lut.h, instead of manually.
3772          - The error constructors used to throw (e.g. `new WebAssembly.CompileError()`).
3773          - Register WebAssembly's constructors from the global object, and hold a
3774            reference to their structure and prototype so that invoking the constructor
3775            can use the structure directly from the global object.
3776          - Add a prototype base field to global object creation. Previous ones all had
3777            Object's prototype as their base, but WebAssembly's error constructors have
3778            Error as their base.
3779          - Test for the error object's correctness.
3780          - Add missing #if ENABLE(WEBASSEMBLY)
3781
3782         WebAssembly API: implement exception constructors properly
3783         https://bugs.webkit.org/show_bug.cgi?id=163699
3784
3785         Reviewed by Keith Miller.
3786
3787         * wasm/js-api/test_basic_api.js:
3788         (const.c.in.constructorProperties): more tests
3789
3790 2016-10-20  Caitlin Potter  <caitp@igalia.com>
3791
3792         [JSC] disallow references to `await` in AsyncFunction formal parameters
3793         https://bugs.webkit.org/show_bug.cgi?id=163694
3794
3795         Reviewed by Saam Barati.
3796
3797         * stress/async-await-syntax.js:
3798
3799 2016-10-20  Keith Miller  <keith_miller@apple.com>
3800
3801         Invalid assertion in arguments elimination
3802         https://bugs.webkit.org/show_bug.cgi?id=163740
3803         <rdar://problem/27911462>
3804
3805         Reviewed by Michael Saboff.
3806
3807         * stress/direct-arguments-osr-entry.js: Added.
3808         (foo.):
3809         (foo):
3810
3811 2016-10-20  Caitlin Potter  <caitp@igalia.com>
3812
3813         [JSC] throw TypeError when constructing dynamically created JSGeneratorFunction
3814         https://bugs.webkit.org/show_bug.cgi?id=163714
3815
3816         Reviewed by Mark Lam.
3817
3818         Add missing test coverage that dynamically created
3819         JSGeneratorFunctions can not be constructed.
3820
3821         * stress/generator-function-constructor.js:
3822         (shouldThrow):
3823
3824 2016-10-19  JF Bastien  <jfbastien@apple.com>
3825
3826         JavaScript WebAssembly API: baby steps
3827
3828          - Expand WebAssembly constructors into their own files. This requires a lot of
3829            boilerplate, as well as adding the .lut.h files. All of the
3830            JSWebAssembly*.{h,cpp}, as well as Constructor and Prototype files, are
3831            currently the same between the 4 specified WebAssembly constructors. It'll be
3832            easy to implement individual functions on constructed objects as per the
3833            spec, and have each of these files diverge. The error constructors are also
3834            similar, except that their instance derives from ErrorInstance.
3835          - Use constructor macro when initializing the global object.
3836          - Dramatically improve testing of the WebAssembly API by checking for
3837            properties specified in the spec [*].
3838          - Clean up assert.js' exception testing.
3839          - Fix a copy-paste bug in wasm.json: floating-point const return values were
3840            swapped.
3841
3842         [*] https://github.com/WebAssembly/design/blob/master/JS.md
3843
3844         Implement more of the JavaScript WebAssembly API
3845         https://bugs.webkit.org/show_bug.cgi?id=163571
3846
3847         Reviewed by Keith Miller.
3848
3849         * wasm/assert.js:
3850         (export.const.isUndef): add this useful helper
3851         (export.const.throws): fold other throw checks into this one, and check message as well
3852         * wasm/js-api/test_basic_api.js:
3853         (const.checkOwnPropertyDescriptor): check own property descriptor follows the spec
3854         * wasm/self-test/test_BuilderJSON.js:
3855         (const.assertOpThrows): use new assert API
3856         (CheckedOpcodeArgumentsTooMany): ditto
3857         (CheckedOpcodeArgumentsNotEnough): ditto
3858         (CallInvalid): ditto
3859         (I32ConstInvalid): ditto
3860         (F32ConstInvalid): ditto (and this caugth the JSON copy-paste bug)
3861         (F64ConstInvalid): ditto
3862         * wasm/self-test/test_LowLevelBinary_varint.js: use new assert API
3863         * wasm/self-test/test_LowLevelBinary_varuint.js: use new assert API
3864         * wasm/utilities.js: add "global" object, used in basic API test (to access global.WebAssembly).
3865         * wasm/wasm.json: fix copy-paste
3866
3867 2016-10-19  Caitlin Potter  <caitp@igalia.com>
3868
3869         [JSC] forbid "use strict" directive in generator functions with non-simple parameters
3870         https://bugs.webkit.org/show_bug.cgi?id=163683
3871
3872         Reviewed by Geoffrey Garen.
3873
3874         Update various generator*-non-simple-param.js tests to be passing.
3875
3876         * test262.yaml:
3877
3878 2016-10-18  Mark Lam  <mark.lam@apple.com>
3879
3880         Invoking Object.prototype.__proto__ accessors directly should throw a TypeError.
3881         https://bugs.webkit.org/show_bug.cgi?id=154377
3882         <rdar://problem/27330808>
3883
3884         Reviewed by Filip Pizlo and Saam Barati.
3885
3886         * stress/object-prototype-proto-accessors-should-throw-on-undefined-this.js: Added.
3887
3888 2016-10-18  Keith Miller  <keith_miller@apple.com>
3889
3890         GetByVal to GetById conversion in the DFG is incorrect for getters with control flow
3891         https://bugs.webkit.org/show_bug.cgi?id=163629
3892
3893         Reviewed by Yusuke Suzuki.
3894
3895         * stress/get-by-val-to-id-with-getter.js: Added.
3896         (foo):
3897         (o.get hello):
3898
3899 2016-10-15  Filip Pizlo  <fpizlo@apple.com>
3900
3901         DFG and FTL should be able to use DirectCall ICs when they proved the callee or its executable
3902         https://bugs.webkit.org/show_bug.cgi?id=163371
3903
3904         Reviewed by Geoffrey Garen and Saam Barati.
3905         
3906         Add microbenchmarks for all of the cases that this patch optimizes.
3907
3908         * microbenchmarks/direct-call-arity-mismatch.js: Added.
3909         (foo):
3910         (bar):
3911         * microbenchmarks/direct-call.js: Added.
3912         (foo):
3913         (bar):
3914         * microbenchmarks/direct-construct-arity-mismatch.js: Added.
3915         (Foo):
3916         (bar):
3917         * microbenchmarks/direct-construct.js: Added.
3918         (Foo):
3919         (bar):
3920         * microbenchmarks/direct-tail-call-arity-mismatch.js: Added.
3921         (foo):
3922         (bar):
3923         * microbenchmarks/direct-tail-call-inlined-caller-arity-mismatch.js: Added.
3924         (foo):
3925         (bar):
3926         (baz):
3927         * microbenchmarks/direct-tail-call-inlined-caller.js: Added.
3928         (foo):
3929         (bar):
3930         (baz):
3931         * microbenchmarks/direct-tail-call.js: Added.
3932         (foo):
3933         (bar):
3934
3935 2016-10-18  Caitlin Potter  <caitp@igalia.com>
3936
3937         [JSC] ES6 Method functions should not have prototype
3938         https://bugs.webkit.org/show_bug.cgi?id=162530
3939
3940         Reviewed by Saam Barati.
3941
3942         Fix test262 expectations about MethodDefinitions
3943
3944         * ChakraCore/test/strict/05.arguments_sm.baseline-jsc:
3945         * stress/reflect-set.js:
3946         * test262.yaml:
3947
3948 2016-10-17  Keith Miller  <keith_miller@apple.com>
3949
3950         Add support for WASM Memory.
3951         https://bugs.webkit.org/show_bug.cgi?id=161710
3952
3953         Reviewed by Geoffrey Garen.
3954
3955         Add store and load opcodes to wasm.json. Additionally, add new
3956         enums for those opcodes in the generator.
3957
3958         * stress/wasm/generate-wasmops-header.js:
3959         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.enum.LoadOpType):
3960         (const.template.pragma.once.ENABLE.WEBASSEMBLY.include.cstdint.namespace.JSC.namespace.WASM.enum.StoreOpType):
3961
3962 2016-10-17  Saam Barati  <sbarati@apple.com>
3963
3964         Add more tests for the double->String conversion in ValueAdd constant folding
3965         https://bugs.webkit.org/show_bug.cgi?id=163517
3966
3967         Reviewed by Yusuke Suzuki.
3968
3969         * microbenchmarks/string-add-constant-folding.js:
3970         (test):
3971
3972 2016-10-17  JF Bastien  <jfbastien@apple.com>
3973
3974         WebAssembly JS API: implement basic stub
3975
3976         Implement the global WebAssembly JavaScript object, and its constructor +
3977         function properties as described in:
3978           https://github.com/WebAssembly/design/blob/master/JS.md
3979
3980         These don't do anything at the moment, the parent bug will take care of adding
3981         more functionality and associated tests.
3982
3983         WebAssembly JS API: implement basic stub
3984         https://bugs.webkit.org/show_bug.cgi?id=163404
3985
3986         Reviewed by Keith Miller.
3987
3988         * wasm.yaml:
3989         * wasm/js-api/test_basic_api.js: Added.
3990         (const.f.of.functionProperties.WebAssembly.f.undefined.throw.new.Error.Couldn.const.c.of.constructorProperties.WebAssembly.c.undefined.throw.new.Error.Couldn):
3991         (const.c.of.constructorProperties.catch):
3992
3993 2016-10-17  Yusuke Suzuki  <utatane.tea@gmail.com>
3994
3995         [DOMJIT] Use DOMJIT::Patchpoint in IC
3996         https://bugs.webkit.org/show_bug.cgi?id=163223
3997
3998         Reviewed by Saam Barati.
3999
4000         * stress/domjit-exception-ic.js: Added.
4001         (shouldBe):
4002         (access):
4003         * stress/domjit-exception.js: Added.
4004         (shouldBe):
4005         (access):
4006         * stress/domjit-getter-complex-with-incorrect-object.js: Added.
4007         (shouldThrow):
4008         (access):
4009         (i.shouldThrow):
4010         * stress/domjit-getter-complex.js: Added.
4011         (shouldBe):
4012         (access):
4013         * stress/domjit-getter-try-catch-getter-as-get-by-id-register-restoration.js: Added.
4014         (assert):
4015         (bar):
4016         (foo):
4017
4018 2016-10-15  Saam Barati  <sbarati@apple.com>
4019
4020         Assertion failed under operationToLowerCase with a rope with zero length
4021         https://bugs.webkit.org/show_bug.cgi?id=163314
4022
4023         Reviewed by Mark Lam.
4024
4025         * stress/to-lower-case-intrinsic-on-empty-rope.js: Added.
4026         (assert):
4027         (returnRope.helper):
4028         (returnRope):
4029         (lower):
4030
4031 2016-10-14  Benjamin Poulain  <bpoulain@apple.com>
4032
4033         [JSC] op_negate should with any type
4034         https://bugs.webkit.org/show_bug.cgi?id=162587
4035
4036         Reviewed by Saam Barati.
4037
4038         * stress/arith-abs-to-arith-negate-range-optimizaton.js: Added.
4039         Cover OSR Exits when converting Math.abs() into ArithNegate.
4040
4041         * stress/arith-negate-on-various-types.js: Added.
4042         Cover ArithNegate with all types.
4043
4044 2016-10-14  JF Bastien  <jfbastien@apple.com>
4045
4046         Basic WebAssembly testing
4047
4048         Create a small DSL in JavaScript which can build WebAssembly binary modules based on the JSON description of the format as described in:
4049         https://github.com/WebAssembly/design/blob/master/BinaryEncoding.md
4050
4051         This DSL can then be used to write small text description of valid and invalid WebAssembly binaries, making testing the JSC implementation much easier.
4052
4053         Details and example in README.md.
4054
4055         Basic WebAssembly testing
4056         https://bugs.webkit.org/show_bug.cgi?id=163267
4057
4058         Reviewed by Keith Miller.
4059
4060         * stress/wasm/wasm.json: Removed.
4061         * wasm.yaml: Added.
4062         * wasm/Builder.js: Added.
4063         (const._isValidValue):
4064         (const._BuildWebAssemblyBinary):
4065         (export.default.Builder):
4066         (export.default.Builder.prototype.setChecked):
4067         (export.default.Builder.prototype.setPreamble):
4068         (export.default.Builder.prototype._registerSectionBuilders.switch.case.string_appeared_here.this.section):
4069         (export.default.Builder.prototype._registerSectionBuilders.this.Unknown):
4070         (export.default.Builder.prototype._registerSectionBuilders):
4071         (export.default.Builder.prototype._addSection):
4072         (export.default.Builder.prototype.optimize):
4073         (export.default.Builder.prototype.json):
4074         (export.default.Builder.prototype.AsmJS):
4075         (export.default.Builder.prototype.WebAssembly):
4076         * wasm/LowLevelBinary.js: Added.
4077         (const._getterRangeCheck):
4078         (const._hexdump):
4079         (export.default.LowLevelBinary):
4080         (export.default.LowLevelBinary.prototype.newPatchable):
4081         (export.default.LowLevelBinary.prototype.hexdump):
4082         (export.default.LowLevelBinary.prototype._maybeGrow):
4083         (export.default.LowLevelBinary.prototype._push8):
4084         (export.default.LowLevelBinary.prototype.uint8):
4085         (export.default.LowLevelBinary.prototype.uint16):
4086         (export.default.LowLevelBinary.prototype.uint32):
4087         (export.default.LowLevelBinary.prototype.varuint):
4088         (export.default.LowLevelBinary.prototype.varint):
4089         (export.default.LowLevelBinary.prototype.varuint7):
4090         (export.default.LowLevelBinary.prototype.string):
4091         (export.default.LowLevelBinary.prototype.getSize):
4092         (export.default.LowLevelBinary.prototype.getUint8):
4093         (export.default.LowLevelBinary.prototype.getUint16):
4094         (export.default.LowLevelBinary.prototype.getUint32):
4095         (export.default.LowLevelBinary.prototype.getVaruint):
4096         (export.default.LowLevelBinary.prototype.getVarint):
4097         (export.default.LowLevelBinary.prototype.getVaruint7):
4098         (export.default.LowLevelBinary.prototype.getString):
4099         (PatchableLowLevelBinary):
4100         (PatchableLowLevelBinary.prototype._push8):
4101         (PatchableLowLevelBinary.prototype.apply):
4102         * wasm/README.md: Added.
4103         * wasm/WASM.js: Added.
4104         * wasm/assert.js: Added.
4105         (export.const.notUndef):
4106         (export.const.eq):
4107         (export.const.ge):
4108         (export.const.throwsError):
4109         (export.const.throwsRangeError):
4110         * wasm/generate-wasmops-header.js: Renamed from JSTests/stress/wasm/generate-wasmops-header.js.
4111         * wasm/self-test/test_BuilderJSON.js: Added.
4112         (const.assertOpThrows):
4113         (EmptyModule):
4114         (CustomMagicNumber):
4115         (CustomVersion):
4116         (CustomSection):
4117         (CustomSectionAllBytes):
4118         (CustomSectionInvalidByte):
4119         (TwoCustomSections):
4120         (EmptyCodeSection):
4121         (CodeSectionWithEmptyFunction):
4122         (CodeSectionWithEmptyFunctionWithParameters):
4123         (InvalidFunctionParameters):
4124         (SimpleFunction):
4125         (TwoSimpleFunctions):
4126         (TwoBuildersAtTheSameTime):
4127         (CheckedOpcodeArgumentsTooMany):
4128         (CheckedOpcodeArgumentsNotEnough):
4129         (CallNoArguments):
4130         (CallInvalid):
4131         (I32ConstInvalid):
4132         (F32ConstInvalid):
4133         (F64ConstInvalid):
4134         (CallManyFromStack):
4135         (OpcodeAdd):
4136         (OpcodeUnreachable):
4137         (OpcodeUnreachableCombinations):
4138         (OpcodeSelect):
4139         * wasm/self-test/test_BuilderWebAssembly.js: Added.
4140         (EmptyModule):
4141         (CustomSection):
4142         (Basic):
4143         * wasm/self-test/test_LowLevelBinary_encode.js: Added.
4144         * wasm/self-test/test_LowLevelBinary_string.js: Added.
4145         * wasm/self-test/test_LowLevelBinary_uint16.js: Added.
4146         * wasm/self-test/test_LowLevelBinary_uint32.js: Added.
4147         * wasm/self-test/test_LowLevelBinary_uint8.js: Added.
4148         * wasm/self-test/test_LowLevelBinary_varint.js: Added.
4149         * wasm/self-test/test_LowLevelBinary_varuint.js: Added.
4150         * wasm/self-test/test_LowLevelBinary_varuint7.js: Added.
4151         * wasm/self-test/test_WASM.js: Added.
4152         * wasm/test.sh: Added.
4153         * wasm/utilities.js: Added.
4154         (const._read.filename.switch):
4155         (const._load.filename.switch):
4156         (const._json.filename.switch):
4157         * wasm/wasm.json: Added.
4158
4159 2016-10-14  Joseph Pecoraro  <pecoraro@apple.com>
4160
4161         test262: @isConstructor incorrectly thinks Math.cos is a constructor
4162         https://bugs.webkit.org/show_bug.cgi?id=163437
4163
4164         Reviewed by Saam Barati.
4165
4166         * stress/is-constructor.js: Added.
4167         (assert):
4168         (prototype.assert):
4169         New test to cover the @isConstructor builtin.
4170
4171         * test262.yaml:
4172         Test now passes.
4173
4174 2016-10-14  Ryan Haddad  <ryanhaddad@apple.com>
4175
4176         Unreviewed, rolling out r207322.
4177
4178         This change caused JSC test failures
4179
4180         Reverted changeset:
4181
4182         "Fix Array.prototype.splice ES6 compliance."
4183         https://bugs.webkit.org/show_bug.cgi?id=163372
4184         http://trac.webkit.org/changeset/207322
4185
4186 2016-10-14  Mark Lam  <mark.lam@apple.com>
4187
4188         JSON.parse should not modify frozen objects.
4189         https://bugs.webkit.org/show_bug.cgi?id=163430
4190
4191         Reviewed by Saam Barati.
4192
4193         * stress/json-parse-on-frozen-object.js: Added.
4194
4195 2016-10-14  Joseph Pecoraro  <pecoraro@apple.com>
4196
4197         test262: Failure with RegExp.prototype.compile when pattern is undefined
4198         https://bugs.webkit.org/show_bug.cgi?id=163431
4199
4200         Reviewed by Yusuke Suzuki.
4201
4202         * test262.yaml:
4203
4204 2016-10-13  Joseph Pecoraro  <pecoraro@apple.com>
4205
4206         Exception message for expressions with multiple bracket accesses is inconsistent / incorrect
4207         https://bugs.webkit.org/show_bug.cgi?id=163426
4208
4209         Reviewed by Geoffrey Garen.
4210
4211         * ChakraCore/test/Error/CallNonFunction_3.baseline-jsc:
4212         * ChakraCore/test/Object/null.baseline-jsc:
4213         * stress/exception-in-to-property-key-should-be-handled-early.js:
4214         Better exception messages.
4215
4216 2016-10-13  Mark Lam  <mark.lam@apple.com>
4217
4218         Fix Array.prototype.splice ES6 compliance.
4219         https://bugs.webkit.org/show_bug.cgi?id=163372
4220
4221         Reviewed by Geoffrey Garen and Yusuke Suzuki.
4222
4223         * stress/array-splice-on-frozen-object.js: Added.
4224
4225 2016-10-12  Keith Miller  <keith_miller@apple.com>
4226
4227         Handle non-function, non-undefined comparator in Array.prototype.sort
4228         https://bugs.webkit.org/show_bug.cgi?id=163085
4229
4230         Reviewed by Yusuke Suzuki.
4231
4232         * ChakraCore/test/Array/array_sort.baseline-jsc:
4233         * stress/array-sort-bad-comparator.js: Added.
4234         (test):
4235
4236 2016-10-12  Mark Lam  <mark.lam@apple.com>
4237
4238         Array.prototype.slice should not modify frozen objects.
4239         https://bugs.webkit.org/show_bug.cgi?id=163338
4240
4241         Reviewed by Filip Pizlo.
4242
4243         * stress/array-slice-on-frozen-object.js: Added.
4244
4245 2016-10-11  Mark Lam  <mark.lam@apple.com>
4246
4247         Array.prototype.concat should not modify frozen objects.
4248         https://bugs.webkit.org/show_bug.cgi?id=163302
4249
4250         Reviewed by Filip Pizlo.
4251
4252         * stress/array-concat-on-frozen-object.js: Added.
4253
4254 2016-10-11  Saam Barati  <sbarati@apple.com>
4255
4256         ValueAdd should be constant folded if the operands are constant String,Primitive or Primitive,String
4257         https://bugs.webkit.org/show_bug.cgi?id=163182
4258
4259         Reviewed by Filip Pizlo.
4260
4261         * microbenchmarks/string-add-constant-folding.js: Added.
4262         (assert):
4263         (runTests):
4264         (add):
4265         (test):
4266
4267 2016-10-07  Mark Lam  <mark.lam@apple.com>
4268
4269         Object.freeze() and seal() should throw if [[PreventExtensions]]() fails.
4270         https://bugs.webkit.org/show_bug.cgi?id=163160
4271
4272         Reviewed by Saam Barati.
4273
4274         * stress/object-freeze-with-proxy-preventExtensions.js: Added.
4275         * stress/object-seal-with-proxy-preventExtensions.js: Added.
4276
4277 2016-10-05  Yusuke Suzuki  <utatane.tea@gmail.com>
4278
4279         [DOMJIT] Add initial CheckDOM and CallDOM implementations
4280         https://bugs.webkit.org/show_bug.cgi?id=162941
4281
4282         Reviewed by Filip Pizlo.
4283
4284         * stress/domjit-getter-poly.js: Added.
4285         (shouldBe):
4286         (access):
4287         * stress/domjit-getter-proto.js: Added.
4288         (shouldBe):
4289         (access):
4290         * stress/domjit-getter-super-poly.js: Added.
4291         (shouldBe):
4292         (access):
4293         * stress/domjit-getter.js: Added.
4294         (shouldBe):
4295         (access):
4296
4297 2016-10-04  Saam Barati  <sbarati@apple.com>
4298
4299         String.prototype.toLowerCase should be a DFG/FTL intrinsic
4300         https://bugs.webkit.org/show_bug.cgi?id=162887
4301
4302         Reviewed by Filip Pizlo and Yusuke Suzuki.
4303
4304         * microbenchmarks/to-lower-case.js: Added.
4305         (assert):
4306         (foo):
4307         (bar):
4308         * stress/to-lower-case.js: Added.
4309         (assert):
4310         (foo):
4311
4312 2016-10-04  JF Bastien  <jfbastien@apple.com>
4313
4314         WebAssembly: handle a few corner cases
4315         https://bugs.webkit.org/show_bug.cgi?id=162884
4316
4317         Reviewed by Keith Miller.
4318
4319         * stress/wasm/generate-wasmops-header.js:
4320         (const.opcodeIterator): max opcode value
4321
4322 2016-10-03  JF Bastien  <jfbastien@apple.com>
4323
4324         Auto-generate WASMOps.h, share with testing JSON file
4325         https://bugs.webkit.org/show_bug.cgi?id=162870
4326
4327         Reviewed by Keith Miller.
4328
4329         * stress/wasm/to-c++.js: Added. Generates WASMOps.h, siilar to the current one but with more data.
4330         (const.opcode_iterator):
4331         (opcode_macroizer):
4332         * stress/wasm/wasm.json: Added. Data from 0xC binary format version.
4333
4334 2016-10-03  Saam Barati  <sbarati@apple.com>
4335
4336         MapHash should speculate on the type of its child node
4337         https://bugs.webkit.org/show_bug.cgi?id=161922
4338
4339         Reviewed by Filip Pizlo.
4340
4341         * microbenchmarks/map-key-well-typed.js: Added.
4342         (assert):
4343         (intKey):
4344         (doubleKey):
4345         (objectKey):
4346         (stringKey):
4347         (booleanKey):
4348         (symbolKey):
4349         (cellKey):
4350         (assert.doubleKey):
4351         (assert.booleanKey):
4352
4353 2016-10-03  Yusuke Suzuki  <utatane.tea@gmail.com>
4354
4355         [ES6] GeneratorFunction (a.k.a. GeneratorWrapperFunction)'s prototype object does not have constructor property
4356         https://bugs.webkit.org/show_bug.cgi?id=162849
4357
4358         Reviewed by Geoffrey Garen.
4359
4360         * test262.yaml:
4361
4362 2016-10-01  Yusuke Suzuki  <utatane.tea@gmail.com>
4363
4364         [ES6] Align attributes of Generator related properties to spec
4365         https://bugs.webkit.org/show_bug.cgi?id=162839
4366
4367         Reviewed by Saam Barati.
4368
4369         * test262.yaml:
4370
4371 2016-10-01  Yusuke Suzuki  <utatane.tea@gmail.com>
4372
4373         [ES6] GeneratorFunction constructor should instantiate generator function
4374         https://bugs.webkit.org/show_bug.cgi?id=162838
4375
4376         Reviewed by Saam Barati.
4377
4378         * stress/generator-function-constructor-is-subclassible.js: Added.
4379         (shouldBe):
4380         (GeneratorFunction):
4381         (prototype.hello):
4382         * stress/generator-function-constructor.js:
4383         * test262.yaml:
4384
4385 2016-09-30  Saam Barati  <sbarati@apple.com>
4386
4387         Arrow functions should not allow duplicate parameter names
4388         https://bugs.webkit.org/show_bug.cgi?id=162741
4389
4390         Reviewed by Filip Pizlo.
4391
4392         * test262.yaml:
4393
4394 2016-09-30  Saam Barati  <sbarati@apple.com>
4395
4396         Make some microbenchmarks run for less time.
4397
4398         Rubber stamped by Filip Pizlo.
4399
4400         * microbenchmarks/bound-function-construction-performance.js:
4401         (foo):
4402         * microbenchmarks/getter-richards-try-catch.js:
4403
4404 2016-09-29  Joseph Pecoraro  <pecoraro@apple.com>
4405
4406         Arrow functions do not infer name from computed property but normal functions do
4407         https://bugs.webkit.org/show_bug.cgi?id=162720
4408
4409         Reviewed by Saam Barati.
4410
4411         * stress/inferred-names.js:
4412
4413 2016-09-29  Mark Lam  <mark.lam@apple.com>