summaryrefslogtreecommitdiff
path: root/deps/v8/test/mjsunit
diff options
context:
space:
mode:
authorRefael Ackermann <refack@gmail.com>2014-09-29 13:20:04 +0400
committerFedor Indutny <fedor@indutny.com>2014-10-08 15:35:57 +0400
commit939278ac059b44439d41aab12bf552c8ae3c52d0 (patch)
tree86c586915a96d308b1b04de679a8ae293caf3e41 /deps/v8/test/mjsunit
parent4412a71d76a0fa002f627ec21d2337e089da6764 (diff)
downloadnode-new-939278ac059b44439d41aab12bf552c8ae3c52d0.tar.gz
deps: update v8 to 3.28.73
Reviewed-By: Fedor Indutny <fedor@indutny.com> PR-URL: https://github.com/joyent/node/pull/8476
Diffstat (limited to 'deps/v8/test/mjsunit')
-rw-r--r--deps/v8/test/mjsunit/allocation-site-info.js729
-rw-r--r--deps/v8/test/mjsunit/apply.js8
-rw-r--r--deps/v8/test/mjsunit/array-construct-transition.js18
-rw-r--r--deps/v8/test/mjsunit/array-constructor-feedback.js326
-rw-r--r--deps/v8/test/mjsunit/array-feedback.js303
-rw-r--r--deps/v8/test/mjsunit/array-literal-feedback.js103
-rw-r--r--deps/v8/test/mjsunit/array-literal-transitions.js203
-rw-r--r--deps/v8/test/mjsunit/array-natives-elements.js70
-rw-r--r--deps/v8/test/mjsunit/array-push-unshift-read-only-length.js107
-rw-r--r--deps/v8/test/mjsunit/array-shift2.js18
-rw-r--r--deps/v8/test/mjsunit/array-shift3.js15
-rw-r--r--deps/v8/test/mjsunit/assert-opt-and-deopt.js2
-rw-r--r--deps/v8/test/mjsunit/binary-op-newspace.js2
-rw-r--r--deps/v8/test/mjsunit/bounds-checks-elimination.js123
-rw-r--r--deps/v8/test/mjsunit/builtins.js11
-rw-r--r--deps/v8/test/mjsunit/compiler/inline-arguments.js26
-rw-r--r--deps/v8/test/mjsunit/compiler/math-floor-global.js2
-rw-r--r--deps/v8/test/mjsunit/compiler/math-floor-local.js2
-rw-r--r--deps/v8/test/mjsunit/const-eval-init.js33
-rw-r--r--deps/v8/test/mjsunit/const-redecl.js82
-rw-r--r--deps/v8/test/mjsunit/constant-folding-2.js11
-rw-r--r--deps/v8/test/mjsunit/cross-realm-filtering.js141
-rw-r--r--deps/v8/test/mjsunit/debug-break-native.js42
-rw-r--r--deps/v8/test/mjsunit/debug-compile-event.js26
-rw-r--r--deps/v8/test/mjsunit/debug-compile-optimized.js18
-rw-r--r--deps/v8/test/mjsunit/debug-is-active.js28
-rw-r--r--deps/v8/test/mjsunit/debug-mirror-cache.js3
-rw-r--r--deps/v8/test/mjsunit/debug-script.js2
-rw-r--r--deps/v8/test/mjsunit/debug-scripts-request.js2
-rw-r--r--deps/v8/test/mjsunit/debug-stepin-positions.js3
-rw-r--r--deps/v8/test/mjsunit/debug-toggle-mirror-cache.js40
-rw-r--r--deps/v8/test/mjsunit/define-property-gc.js2
-rw-r--r--deps/v8/test/mjsunit/deserialize-reference.js8
-rw-r--r--deps/v8/test/mjsunit/dictionary-properties.js48
-rw-r--r--deps/v8/test/mjsunit/elements-kind-depends.js2
-rw-r--r--deps/v8/test/mjsunit/elements-kind.js337
-rw-r--r--deps/v8/test/mjsunit/elements-transition-hoisting.js20
-rw-r--r--deps/v8/test/mjsunit/elements-transition.js164
-rw-r--r--deps/v8/test/mjsunit/error-tostring-omit.js18
-rw-r--r--deps/v8/test/mjsunit/es6/array-iterator.js (renamed from deps/v8/test/mjsunit/harmony/array-iterator.js)95
-rw-r--r--deps/v8/test/mjsunit/es6/collection-iterator.js200
-rw-r--r--deps/v8/test/mjsunit/es6/collections.js (renamed from deps/v8/test/mjsunit/harmony/collections.js)454
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises-throw-in-reject.js61
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises-undefined-reject.js57
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/async-task-event.js61
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/events.js124
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reentry.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-reentry.js)2
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-after-resolve.js37
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-caught-all.js72
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-caught-late.js34
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-caught-uncaught.js36
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-in-constructor.js39
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-all.js69
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-late.js76
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-uncaught.js69
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-with-invalid-reject.js77
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-with-throw-in-reject.js87
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/reject-with-undefined-reject.js77
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-caught-all.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-caught-all.js)40
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-caught-late.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-caught-late.js)8
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-caught-uncaught.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-caught-uncaught.js)12
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-in-constructor.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-throw-in-constructor.js)10
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-uncaught-all.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-uncaught-all.js)43
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-uncaught-uncaught.js (renamed from deps/v8/test/mjsunit/es6/debug-promises-uncaught-uncaught.js)42
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-with-throw-in-reject.js90
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/throw-with-undefined-reject.js88
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/try-reject-in-constructor.js42
-rw-r--r--deps/v8/test/mjsunit/es6/debug-promises/try-throw-reject-in-constructor.js44
-rw-r--r--deps/v8/test/mjsunit/es6/debug-stepin-collections-foreach.js118
-rw-r--r--deps/v8/test/mjsunit/es6/iteration-semantics.js (renamed from deps/v8/test/mjsunit/harmony/iteration-semantics.js)88
-rw-r--r--deps/v8/test/mjsunit/es6/iteration-syntax.js (renamed from deps/v8/test/mjsunit/harmony/iteration-syntax.js)2
-rw-r--r--deps/v8/test/mjsunit/es6/math-cbrt.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-clz32.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-expm1.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-fround.js43
-rw-r--r--deps/v8/test/mjsunit/es6/math-hyperbolic.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-hypot.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-log1p.js47
-rw-r--r--deps/v8/test/mjsunit/es6/math-log2-log10.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-sign.js2
-rw-r--r--deps/v8/test/mjsunit/es6/math-trunc.js2
-rw-r--r--deps/v8/test/mjsunit/es6/mirror-collections.js144
-rw-r--r--deps/v8/test/mjsunit/es6/mirror-promises.js27
-rw-r--r--deps/v8/test/mjsunit/es6/mirror-symbols.js38
-rw-r--r--deps/v8/test/mjsunit/es6/promises.js42
-rw-r--r--deps/v8/test/mjsunit/es6/regress/regress-2186.js (renamed from deps/v8/test/mjsunit/harmony/regress/regress-2186.js)2
-rw-r--r--deps/v8/test/mjsunit/es6/regress/regress-cr372788.js (renamed from deps/v8/test/mjsunit/regress/regress-2336.js)38
-rw-r--r--deps/v8/test/mjsunit/es6/regress/regress-crbug-248025.js (renamed from deps/v8/test/mjsunit/harmony/regress/regress-crbug-248025.js)2
-rw-r--r--deps/v8/test/mjsunit/es6/regress/regress-crbug-346141.js (renamed from deps/v8/test/mjsunit/harmony/regress/regress-crbug-346141.js)2
-rw-r--r--deps/v8/test/mjsunit/es6/string-html.js159
-rw-r--r--deps/v8/test/mjsunit/es6/string-iterator.js89
-rw-r--r--deps/v8/test/mjsunit/es6/symbols.js (renamed from deps/v8/test/mjsunit/harmony/symbols.js)46
-rw-r--r--deps/v8/test/mjsunit/es6/typed-array-iterator.js39
-rw-r--r--deps/v8/test/mjsunit/es6/unscopables.js664
-rw-r--r--deps/v8/test/mjsunit/es6/weak_collections.js333
-rw-r--r--deps/v8/test/mjsunit/es7/object-observe-debug-event.js51
-rw-r--r--deps/v8/test/mjsunit/es7/object-observe-runtime.js18
-rw-r--r--deps/v8/test/mjsunit/es7/object-observe.js13
-rw-r--r--deps/v8/test/mjsunit/fast-non-keyed.js6
-rw-r--r--deps/v8/test/mjsunit/fast-prototype.js13
-rw-r--r--deps/v8/test/mjsunit/global-const-var-conflicts.js13
-rw-r--r--deps/v8/test/mjsunit/harmony/array-fill.js4
-rw-r--r--deps/v8/test/mjsunit/harmony/arrow-functions.js48
-rw-r--r--deps/v8/test/mjsunit/harmony/block-conflicts.js133
-rw-r--r--deps/v8/test/mjsunit/harmony/block-const-assign.js3
-rw-r--r--deps/v8/test/mjsunit/harmony/block-early-errors.js3
-rw-r--r--deps/v8/test/mjsunit/harmony/block-for.js42
-rw-r--r--deps/v8/test/mjsunit/harmony/block-leave.js1
-rw-r--r--deps/v8/test/mjsunit/harmony/block-let-crankshaft.js258
-rw-r--r--deps/v8/test/mjsunit/harmony/block-let-declaration.js28
-rw-r--r--deps/v8/test/mjsunit/harmony/block-let-semantics.js1
-rw-r--r--deps/v8/test/mjsunit/harmony/block-scoping.js12
-rw-r--r--deps/v8/test/mjsunit/harmony/debug-blockscopes.js13
-rw-r--r--deps/v8/test/mjsunit/harmony/debug-evaluate-blockscopes.js1
-rw-r--r--deps/v8/test/mjsunit/harmony/empty-for.js72
-rw-r--r--deps/v8/test/mjsunit/harmony/generators-debug-liveedit.js119
-rw-r--r--deps/v8/test/mjsunit/harmony/generators-iteration.js52
-rw-r--r--deps/v8/test/mjsunit/harmony/generators-parsing.js45
-rw-r--r--deps/v8/test/mjsunit/harmony/generators-poisoned-properties.js42
-rw-r--r--deps/v8/test/mjsunit/harmony/generators-runtime.js24
-rw-r--r--deps/v8/test/mjsunit/harmony/private.js20
-rw-r--r--deps/v8/test/mjsunit/harmony/proxies-example-membrane.js2
-rw-r--r--deps/v8/test/mjsunit/harmony/proxies-hash.js2
-rw-r--r--deps/v8/test/mjsunit/harmony/proxies-json.js2
-rw-r--r--deps/v8/test/mjsunit/harmony/proxies-symbols.js2
-rw-r--r--deps/v8/test/mjsunit/harmony/proxies-with-unscopables.js153
-rw-r--r--deps/v8/test/mjsunit/harmony/proxies.js2
-rw-r--r--deps/v8/test/mjsunit/harmony/regress/regress-3426.js7
-rw-r--r--deps/v8/test/mjsunit/harmony/set-prototype-of.js2
-rw-r--r--deps/v8/test/mjsunit/harmony/string-codepointat.js91
-rw-r--r--deps/v8/test/mjsunit/harmony/string-fromcodepoint.js62
-rw-r--r--deps/v8/test/mjsunit/json-stringify-recursive.js2
-rw-r--r--deps/v8/test/mjsunit/keyed-load-dictionary-stub.js20
-rw-r--r--deps/v8/test/mjsunit/math-abs.js2
-rw-r--r--deps/v8/test/mjsunit/math-floor-part1.js2
-rw-r--r--deps/v8/test/mjsunit/math-floor-part2.js2
-rw-r--r--deps/v8/test/mjsunit/math-floor-part3.js2
-rw-r--r--deps/v8/test/mjsunit/math-floor-part4.js2
-rw-r--r--deps/v8/test/mjsunit/migrations.js311
-rw-r--r--deps/v8/test/mjsunit/mirror-object.js16
-rw-r--r--deps/v8/test/mjsunit/mirror-script.js2
-rw-r--r--deps/v8/test/mjsunit/mjsunit.js27
-rw-r--r--deps/v8/test/mjsunit/mjsunit.status264
-rw-r--r--deps/v8/test/mjsunit/object-define-property.js20
-rw-r--r--deps/v8/test/mjsunit/object-toprimitive.js2
-rw-r--r--deps/v8/test/mjsunit/opt-elements-kind.js23
-rw-r--r--deps/v8/test/mjsunit/osr-elements-kind.js103
-rw-r--r--deps/v8/test/mjsunit/outobject-double-for-in.js66
-rw-r--r--deps/v8/test/mjsunit/override-read-only-property.js2
-rw-r--r--deps/v8/test/mjsunit/own-symbols.js55
-rw-r--r--deps/v8/test/mjsunit/packed-elements.js18
-rw-r--r--deps/v8/test/mjsunit/polymorph-arrays.js12
-rw-r--r--deps/v8/test/mjsunit/proto-accessor.js2
-rw-r--r--deps/v8/test/mjsunit/readonly.js3
-rw-r--r--deps/v8/test/mjsunit/regress-3456.js13
-rw-r--r--deps/v8/test/mjsunit/regress/debug-prepare-step-in.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-1170.js11
-rw-r--r--deps/v8/test/mjsunit/regress/regress-1199637.js16
-rw-r--r--deps/v8/test/mjsunit/regress/regress-1213575.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-1530.js48
-rw-r--r--deps/v8/test/mjsunit/regress/regress-1708.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-2790.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-320532.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3281.js7
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3307.js24
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3315.js26
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3334.js13
-rw-r--r--deps/v8/test/mjsunit/regress/regress-334.js8
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3359.js12
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3380.js16
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3392.js18
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3404.js27
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3462.js48
-rw-r--r--deps/v8/test/mjsunit/regress/regress-3476.js24
-rw-r--r--deps/v8/test/mjsunit/regress/regress-370827.js21
-rw-r--r--deps/v8/test/mjsunit/regress/regress-373283.js18
-rw-r--r--deps/v8/test/mjsunit/regress/regress-377290.js17
-rw-r--r--deps/v8/test/mjsunit/regress/regress-379770.js26
-rw-r--r--deps/v8/test/mjsunit/regress/regress-380049.js9
-rw-r--r--deps/v8/test/mjsunit/regress/regress-380092.js22
-rw-r--r--deps/v8/test/mjsunit/regress/regress-381313.js42
-rw-r--r--deps/v8/test/mjsunit/regress/regress-392114.js66
-rw-r--r--deps/v8/test/mjsunit/regress/regress-99167.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-cntl-descriptors-enum.js4
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-245480.js38
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-350864.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-374838.js20
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-380512.js12
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-381534.js40
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-382513.js11
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-385002.js15
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-387599.js19
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-387627.js13
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-387636.js14
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-390918.js18
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-390925.js9
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-393988.js8
-rw-r--r--deps/v8/test/mjsunit/regress/regress-crbug-401915.js20
-rw-r--r--deps/v8/test/mjsunit/regress/regress-create-exception.js2
-rw-r--r--deps/v8/test/mjsunit/regress/regress-debug-context-load.js8
-rw-r--r--deps/v8/test/mjsunit/regress/regress-double-property.js9
-rw-r--r--deps/v8/test/mjsunit/regress/regress-escape-preserve-smi-representation.js13
-rw-r--r--deps/v8/test/mjsunit/regress/regress-freeze-setter.js (renamed from deps/v8/test/mjsunit/regress/regress-global-freeze-const.js)4
-rw-r--r--deps/v8/test/mjsunit/regress/regress-function-constructor-receiver.js17
-rw-r--r--deps/v8/test/mjsunit/regress/regress-mask-array-length.js10
-rw-r--r--deps/v8/test/mjsunit/regress/regress-regexp-nocase.js (renamed from deps/v8/test/mjsunit/harmony/typeof.js)11
-rw-r--r--deps/v8/test/mjsunit/regress/regress-set-flags-stress-compact.js10
-rw-r--r--deps/v8/test/mjsunit/regress/regress-update-field-type-attributes.js12
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/apply.js9
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybuffergetbytelength.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybufferinitialize.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybufferisview.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybufferneuter.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybuffersliceimpl.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbytelength.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbyteoffset.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/arrayconcat.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/availablelocalesof.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/basicjsonstringify.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/booleanize.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/boundfunctiongetbindings.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/break.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/breakiteratoradopttext.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/breakiteratorbreaktype.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/breakiteratorcurrent.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/breakiteratorfirst.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/breakiteratornext.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/canonicalizelanguagetag.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/changebreakonexception.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/charfromcode.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/checkexecutionstate.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/checkisbootstrapping.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/clearbreakpoint.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/clearfunctiontypefeedback.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/clearstepping.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/collectstacktrace.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/compilestring.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/constructdouble.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createbreakiterator.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createcollator.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createglobalprivatesymbol.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createjsfunctionproxy.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createjsproxy.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createprivateownsymbol.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createprivatesymbol.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/createsymbol.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetbuffer.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat32.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat64.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetint16.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetint32.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetint8.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetuint16.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetuint32.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewgetuint8.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewinitialize.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat32.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat64.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetint16.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetint32.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetint8.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetuint16.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetuint32.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dataviewsetuint8.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/datecacheversion.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/datecurrenttime.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/datelocaltimezone.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/datemakeday.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/dateparsestring.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/datesetvalue.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/datetoutc.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugasynctaskevent.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugbreak.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugcallbacksupportsstepping.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugconstructedby.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugdisassembleconstructor.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugdisassemblefunction.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugevaluate.js12
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugevaluateglobal.js10
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debuggetproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debuggetpropertydetails.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debuggetprototype.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugindexedinterceptorelementvalue.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugnamedinterceptorpropertyvalue.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpoppromise.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpreparestepinifstepping.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugprintscopes.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpromiseevent.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpromiserejectevent.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpropertyattributesfromdetails.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpropertyindexfromdetails.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpropertytypefromdetails.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugpushpromise.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugreferencedby.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/debugtrace.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/defineaccessorpropertyunchecked.js9
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/defineapiaccessorproperty.js9
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/definedatapropertyunchecked.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/deleteproperty.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/deoptimizefunction.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/doublehi.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/doublelo.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/enqueuemicrotask.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/estimatenumberofelements.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/executeindebugcontext.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/finisharrayprototypesetup.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/fix.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/flattenstring.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionbindarguments.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functiongetinferredname.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functiongetname.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functiongetscript.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functiongetscriptsourceposition.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functiongetsourcecode.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionisapifunction.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionisarrow.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionisbuiltin.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionisgenerator.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionmarknameshouldprintasanonymous.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionnameshouldprintasanonymous.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionremoveprototype.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionsetinstanceclassname.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionsetlength.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionsetname.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/functionsetprototype.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getallscopesdetails.js10
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getargumentsproperty.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getarraykeys.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getbreaklocations.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getcalltrap.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getconstructordelegate.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getconstructtrap.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getdataproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getdefaulticulocale.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getdefaultreceiver.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getframecount.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getframedetails.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getfunctioncodepositionfromsource.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getfunctiondelegate.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getfunctionscopecount.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getfunctionscopedetails.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/gethandler.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getheapusage.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getimplfrominitializedintlobject.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getindexedinterceptorelementnames.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getinterceptorinfo.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getlanguagetagvariants.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getnamedinterceptorpropertynames.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getobjectcontextnotifierperformchange.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectgetnotifier.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectobserve.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getobservationstate.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getoptimizationcount.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getownelementnames.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getownproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getownpropertynames.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getpropertynames.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getpropertynamesfast.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getprototype.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getrootnan.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getscopecount.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getscopedetails.js10
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getscript.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getstepinpositions.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/gettemplatefield.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getthreadcount.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getthreaddetails.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getv8version.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getweakmapentries.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/getweaksetvalues.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/globalprint.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/globalproxy.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/haselement.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/hasownproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/hasproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/havesamemap.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/internalcompare.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/internaldateformat.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/internaldateparse.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/internalnumberformat.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/internalnumberparse.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/internalsetprototype.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isattachedglobal.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isbreakonexception.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isconcurrentrecompilationsupported.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isextensible.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isinitializedintlobject.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isinitializedintlobjectoftype.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isinprototypechain.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isjsfunctionproxy.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isjsglobalproxy.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isjsmodule.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isjsproxy.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isobserved.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isoptimized.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/ispropertyenumerable.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/issloppymodefunction.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/istemplate.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/isvalidsmi.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/keyedgetproperty.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/liveeditcheckanddropactivations.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/liveeditcomparestrings.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/liveeditfunctionsetscript.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/loadmutabledouble.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/lookupaccessor.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapclear.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapdelete.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapget.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapgetsize.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/maphas.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapinitialize.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapiteratorinitialize.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapiteratornext.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mapset.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/markasinitializedintlobjectoftype.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathacos.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathasin.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathatan.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathatan2.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathexprt.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathfloorrt.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathfround.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathlogrt.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/mathsqrtrt.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/maxsmi.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/movearraycontents.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/neveroptimizefunction.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/newarguments.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/newobjectfrombound.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/newstring.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/newstringwrapper.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/newsymbolwrapper.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/notifycontextdisposed.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberadd.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberand.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbercompare.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberdiv.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberequals.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberimul.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbermod.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbermul.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberor.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbersar.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbershl.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbershr.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbersub.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertoexponential.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertofixed.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertointeger.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertointegermapminuszero.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertojsint32.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertojsuint32.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertoprecision.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertoradixstring.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numbertostringrt.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberunaryminus.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/numberxor.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/objectfreeze.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/objectwascreatedincurrentorigin.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/observationweakmapcreate.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/observerobjectandrecordhavesameorigin.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/optimizeobjectforaddingmultipleproperties.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/ownkeys.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/parsejson.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/preventextensions.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/pushifabsent.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/quotejsonstring.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/regexpcompile.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/regexpconstructresult.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/regexpexecmultiple.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/regexpexecrt.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/regexpinitializeobject.js9
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/removearrayholes.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/rempio2.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/roundnumber.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/runmicrotasks.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/runninginsimulator.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setadd.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setclear.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setcode.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setdebugeventlistener.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setdelete.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setdisablebreak.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setflags.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setfunctionbreakpoint.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setgetsize.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/sethas.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setinitialize.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setisobserved.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setiteratorinitialize.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setiteratornext.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setprototype.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/setscopevariablevalue.js10
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/smilexicographiccompare.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/sparsejoinwithseparator.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/specialarrayfunctions.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringbuilderconcat.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringbuilderjoin.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringcharcodeatrt.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringequals.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringindexof.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringlastindexof.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringlocalecompare.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringmatch.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringnormalize.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringparsefloat.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringparseint.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringreplaceglobalregexpwithstring.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringreplaceonecharwithstring.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringsplit.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringtoarray.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringtolowercase.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringtonumber.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringtouppercase.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/stringtrim.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/symboldescription.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/symbolisprivate.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/symbolregistry.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/tobool.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/tofastproperties.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/traceenter.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/traceexit.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/truncatestring.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/trymigrateinstance.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typedarraygetbuffer.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typedarraygetlength.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typedarrayinitialize.js9
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typedarrayinitializefromarraylike.js8
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typedarraymaxsizeinheap.js4
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typedarraysetfastcases.js7
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/typeof.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/unblockconcurrentrecompilation.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/uriescape.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/uriunescape.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/weakcollectiondelete.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/weakcollectionget.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/weakcollectionhas.js6
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/weakcollectioninitialize.js5
-rw-r--r--deps/v8/test/mjsunit/runtime-gen/weakcollectionset.js7
-rw-r--r--deps/v8/test/mjsunit/sin-cos.js97
-rw-r--r--deps/v8/test/mjsunit/stack-traces-overflow.js23
-rw-r--r--deps/v8/test/mjsunit/stack-traces.js20
-rw-r--r--deps/v8/test/mjsunit/tools/profviz-test.default460
-rw-r--r--deps/v8/test/mjsunit/tools/tickprocessor-test.default20
-rw-r--r--deps/v8/test/mjsunit/tools/tickprocessor-test.func-info7
-rw-r--r--deps/v8/test/mjsunit/tools/tickprocessor-test.gc-state7
-rw-r--r--deps/v8/test/mjsunit/tools/tickprocessor-test.ignore-unknown15
-rw-r--r--deps/v8/test/mjsunit/tools/tickprocessor-test.separate-ic20
-rw-r--r--deps/v8/test/mjsunit/tools/tickprocessor.js6
-rw-r--r--deps/v8/test/mjsunit/value-wrapper-accessor.js10
-rw-r--r--deps/v8/test/mjsunit/with-readonly.js2
552 files changed, 10340 insertions, 2654 deletions
diff --git a/deps/v8/test/mjsunit/allocation-site-info.js b/deps/v8/test/mjsunit/allocation-site-info.js
index 35b60ee266..9984f5bd2c 100644
--- a/deps/v8/test/mjsunit/allocation-site-info.js
+++ b/deps/v8/test/mjsunit/allocation-site-info.js
@@ -25,25 +25,9 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Flags: --noalways-opt
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-// support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-support_smi_only_arrays = true;
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
var elements_kind = {
fast_smi_only : 'fast smi only elements',
fast : 'fast elements',
@@ -73,10 +57,6 @@ function isHoley(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
@@ -88,403 +68,402 @@ function assertNotHoley(obj, name_opt) {
assertEquals(false, isHoley(obj), name_opt);
}
-if (support_smi_only_arrays) {
- obj = [];
- assertNotHoley(obj);
- assertKind(elements_kind.fast_smi_only, obj);
+obj = [];
+assertNotHoley(obj);
+assertKind(elements_kind.fast_smi_only, obj);
- obj = [1, 2, 3];
- assertNotHoley(obj);
- assertKind(elements_kind.fast_smi_only, obj);
+obj = [1, 2, 3];
+assertNotHoley(obj);
+assertKind(elements_kind.fast_smi_only, obj);
- obj = new Array();
- assertNotHoley(obj);
- assertKind(elements_kind.fast_smi_only, obj);
+obj = new Array();
+assertNotHoley(obj);
+assertKind(elements_kind.fast_smi_only, obj);
- obj = new Array(0);
- assertNotHoley(obj);
- assertKind(elements_kind.fast_smi_only, obj);
+obj = new Array(0);
+assertNotHoley(obj);
+assertKind(elements_kind.fast_smi_only, obj);
- obj = new Array(2);
- assertHoley(obj);
- assertKind(elements_kind.fast_smi_only, obj);
+obj = new Array(2);
+assertHoley(obj);
+assertKind(elements_kind.fast_smi_only, obj);
- obj = new Array(1,2,3);
- assertNotHoley(obj);
- assertKind(elements_kind.fast_smi_only, obj);
+obj = new Array(1,2,3);
+assertNotHoley(obj);
+assertKind(elements_kind.fast_smi_only, obj);
- obj = new Array(1, "hi", 2, undefined);
- assertNotHoley(obj);
- assertKind(elements_kind.fast, obj);
+obj = new Array(1, "hi", 2, undefined);
+assertNotHoley(obj);
+assertKind(elements_kind.fast, obj);
- function fastliteralcase(literal, value) {
- literal[0] = value;
- return literal;
- }
+function fastliteralcase(literal, value) {
+ literal[0] = value;
+ return literal;
+}
- function get_standard_literal() {
- var literal = [1, 2, 3];
- return literal;
- }
+function get_standard_literal() {
+ var literal = [1, 2, 3];
+ return literal;
+}
- // Case: [1,2,3] as allocation site
- obj = fastliteralcase(get_standard_literal(), 1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = fastliteralcase(get_standard_literal(), 1.5);
+// Case: [1,2,3] as allocation site
+obj = fastliteralcase(get_standard_literal(), 1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = fastliteralcase(get_standard_literal(), 1.5);
+assertKind(elements_kind.fast_double, obj);
+obj = fastliteralcase(get_standard_literal(), 2);
+assertKind(elements_kind.fast_double, obj);
+
+// The test below is in a loop because arrays that live
+// at global scope without the chance of being recreated
+// don't have allocation site information attached.
+for (i = 0; i < 2; i++) {
+ obj = fastliteralcase([5, 3, 2], 1.5);
assertKind(elements_kind.fast_double, obj);
- obj = fastliteralcase(get_standard_literal(), 2);
+ obj = fastliteralcase([3, 6, 2], 1.5);
assertKind(elements_kind.fast_double, obj);
- // The test below is in a loop because arrays that live
- // at global scope without the chance of being recreated
- // don't have allocation site information attached.
- for (i = 0; i < 2; i++) {
- obj = fastliteralcase([5, 3, 2], 1.5);
- assertKind(elements_kind.fast_double, obj);
- obj = fastliteralcase([3, 6, 2], 1.5);
- assertKind(elements_kind.fast_double, obj);
-
- // Note: thanks to pessimistic transition store stubs, we'll attempt
- // to transition to the most general elements kind seen at a particular
- // store site. So, the elements kind will be double.
- obj = fastliteralcase([2, 6, 3], 2);
- assertKind(elements_kind.fast_double, obj);
- }
+ // Note: thanks to pessimistic transition store stubs, we'll attempt
+ // to transition to the most general elements kind seen at a particular
+ // store site. So, the elements kind will be double.
+ obj = fastliteralcase([2, 6, 3], 2);
+ assertKind(elements_kind.fast_double, obj);
+}
- // Verify that we will not pretransition the double->fast path.
- obj = fastliteralcase(get_standard_literal(), "elliot");
- assertKind(elements_kind.fast, obj);
- obj = fastliteralcase(get_standard_literal(), 3);
- assertKind(elements_kind.fast, obj);
+// Verify that we will not pretransition the double->fast path.
+obj = fastliteralcase(get_standard_literal(), "elliot");
+assertKind(elements_kind.fast, obj);
+obj = fastliteralcase(get_standard_literal(), 3);
+assertKind(elements_kind.fast, obj);
- // Make sure this works in crankshafted code too.
+// Make sure this works in crankshafted code too.
%OptimizeFunctionOnNextCall(get_standard_literal);
- get_standard_literal();
- obj = get_standard_literal();
- assertKind(elements_kind.fast, obj);
+get_standard_literal();
+obj = get_standard_literal();
+assertKind(elements_kind.fast, obj);
+
+function fastliteralcase_smifast(value) {
+ var literal = [1, 2, 3, 4];
+ literal[0] = value;
+ return literal;
+}
- function fastliteralcase_smifast(value) {
- var literal = [1, 2, 3, 4];
- literal[0] = value;
- return literal;
- }
+obj = fastliteralcase_smifast(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = fastliteralcase_smifast("carter");
+assertKind(elements_kind.fast, obj);
+obj = fastliteralcase_smifast(2);
+assertKind(elements_kind.fast, obj);
+
+// Case: make sure transitions from packed to holey are tracked
+function fastliteralcase_smiholey(index, value) {
+ var literal = [1, 2, 3, 4];
+ literal[index] = value;
+ return literal;
+}
- obj = fastliteralcase_smifast(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = fastliteralcase_smifast("carter");
- assertKind(elements_kind.fast, obj);
- obj = fastliteralcase_smifast(2);
- assertKind(elements_kind.fast, obj);
+obj = fastliteralcase_smiholey(5, 1);
+assertKind(elements_kind.fast_smi_only, obj);
+assertHoley(obj);
+obj = fastliteralcase_smiholey(0, 1);
+assertKind(elements_kind.fast_smi_only, obj);
+assertHoley(obj);
+
+function newarraycase_smidouble(value) {
+ var a = new Array();
+ a[0] = value;
+ return a;
+}
- // Case: make sure transitions from packed to holey are tracked
- function fastliteralcase_smiholey(index, value) {
- var literal = [1, 2, 3, 4];
- literal[index] = value;
- return literal;
- }
+// Case: new Array() as allocation site, smi->double
+obj = newarraycase_smidouble(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = newarraycase_smidouble(1.5);
+assertKind(elements_kind.fast_double, obj);
+obj = newarraycase_smidouble(2);
+assertKind(elements_kind.fast_double, obj);
+
+function newarraycase_smiobj(value) {
+ var a = new Array();
+ a[0] = value;
+ return a;
+}
- obj = fastliteralcase_smiholey(5, 1);
- assertKind(elements_kind.fast_smi_only, obj);
- assertHoley(obj);
- obj = fastliteralcase_smiholey(0, 1);
- assertKind(elements_kind.fast_smi_only, obj);
- assertHoley(obj);
+// Case: new Array() as allocation site, smi->fast
+obj = newarraycase_smiobj(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = newarraycase_smiobj("gloria");
+assertKind(elements_kind.fast, obj);
+obj = newarraycase_smiobj(2);
+assertKind(elements_kind.fast, obj);
+
+function newarraycase_length_smidouble(value) {
+ var a = new Array(3);
+ a[0] = value;
+ return a;
+}
- function newarraycase_smidouble(value) {
- var a = new Array();
- a[0] = value;
- return a;
- }
+// Case: new Array(length) as allocation site
+obj = newarraycase_length_smidouble(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = newarraycase_length_smidouble(1.5);
+assertKind(elements_kind.fast_double, obj);
+obj = newarraycase_length_smidouble(2);
+assertKind(elements_kind.fast_double, obj);
+
+// Try to continue the transition to fast object.
+// TODO(mvstanton): re-enable commented out code when
+// FLAG_pretenuring_call_new is turned on in the build.
+obj = newarraycase_length_smidouble("coates");
+assertKind(elements_kind.fast, obj);
+obj = newarraycase_length_smidouble(2);
+// assertKind(elements_kind.fast, obj);
+
+function newarraycase_length_smiobj(value) {
+ var a = new Array(3);
+ a[0] = value;
+ return a;
+}
- // Case: new Array() as allocation site, smi->double
- obj = newarraycase_smidouble(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = newarraycase_smidouble(1.5);
- assertKind(elements_kind.fast_double, obj);
- obj = newarraycase_smidouble(2);
- assertKind(elements_kind.fast_double, obj);
+// Case: new Array(<length>) as allocation site, smi->fast
+obj = newarraycase_length_smiobj(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = newarraycase_length_smiobj("gloria");
+assertKind(elements_kind.fast, obj);
+obj = newarraycase_length_smiobj(2);
+assertKind(elements_kind.fast, obj);
+
+function newarraycase_list_smidouble(value) {
+ var a = new Array(1, 2, 3);
+ a[0] = value;
+ return a;
+}
+
+obj = newarraycase_list_smidouble(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = newarraycase_list_smidouble(1.5);
+assertKind(elements_kind.fast_double, obj);
+obj = newarraycase_list_smidouble(2);
+assertKind(elements_kind.fast_double, obj);
+
+function newarraycase_list_smiobj(value) {
+ var a = new Array(4, 5, 6);
+ a[0] = value;
+ return a;
+}
- function newarraycase_smiobj(value) {
- var a = new Array();
- a[0] = value;
+obj = newarraycase_list_smiobj(1);
+assertKind(elements_kind.fast_smi_only, obj);
+obj = newarraycase_list_smiobj("coates");
+assertKind(elements_kind.fast, obj);
+obj = newarraycase_list_smiobj(2);
+assertKind(elements_kind.fast, obj);
+
+// Case: array constructor calls with out of date feedback.
+// The boilerplate should incorporate all feedback, but the input array
+// should be minimally transitioned based on immediate need.
+(function() {
+ function foo(i) {
+ // We have two cases, one for literals one for constructed arrays.
+ var a = (i == 0)
+ ? [1, 2, 3]
+ : new Array(1, 2, 3);
return a;
}
- // Case: new Array() as allocation site, smi->fast
- obj = newarraycase_smiobj(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = newarraycase_smiobj("gloria");
- assertKind(elements_kind.fast, obj);
- obj = newarraycase_smiobj(2);
- assertKind(elements_kind.fast, obj);
-
- function newarraycase_length_smidouble(value) {
- var a = new Array(3);
- a[0] = value;
- return a;
+ for (i = 0; i < 2; i++) {
+ a = foo(i);
+ b = foo(i);
+ b[5] = 1; // boilerplate goes holey
+ assertHoley(foo(i));
+ a[0] = 3.5; // boilerplate goes holey double
+ assertKind(elements_kind.fast_double, a);
+ assertNotHoley(a);
+ c = foo(i);
+ assertKind(elements_kind.fast_double, c);
+ assertHoley(c);
}
+})();
- // Case: new Array(length) as allocation site
- obj = newarraycase_length_smidouble(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = newarraycase_length_smidouble(1.5);
- assertKind(elements_kind.fast_double, obj);
- obj = newarraycase_length_smidouble(2);
- assertKind(elements_kind.fast_double, obj);
+function newarraycase_onearg(len, value) {
+ var a = new Array(len);
+ a[0] = value;
+ return a;
+}
- // Try to continue the transition to fast object.
- // TODO(mvstanton): re-enable commented out code when
- // FLAG_pretenuring_call_new is turned on in the build.
- obj = newarraycase_length_smidouble("coates");
- assertKind(elements_kind.fast, obj);
- obj = newarraycase_length_smidouble(2);
- // assertKind(elements_kind.fast, obj);
+obj = newarraycase_onearg(5, 3.5);
+assertKind(elements_kind.fast_double, obj);
+obj = newarraycase_onearg(10, 5);
+assertKind(elements_kind.fast_double, obj);
+obj = newarraycase_onearg(0, 5);
+assertKind(elements_kind.fast_double, obj);
+
+// Verify that cross context calls work
+var realmA = Realm.current();
+var realmB = Realm.create();
+assertEquals(0, realmA);
+assertEquals(1, realmB);
+
+function instanceof_check(type) {
+ assertTrue(new type() instanceof type);
+ assertTrue(new type(5) instanceof type);
+ assertTrue(new type(1,2,3) instanceof type);
+}
- function newarraycase_length_smiobj(value) {
- var a = new Array(3);
- a[0] = value;
- return a;
- }
+function instanceof_check2(type) {
+ assertTrue(new type() instanceof type);
+ assertTrue(new type(5) instanceof type);
+ assertTrue(new type(1,2,3) instanceof type);
+}
- // Case: new Array(<length>) as allocation site, smi->fast
- obj = newarraycase_length_smiobj(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = newarraycase_length_smiobj("gloria");
- assertKind(elements_kind.fast, obj);
- obj = newarraycase_length_smiobj(2);
- assertKind(elements_kind.fast, obj);
+var realmBArray = Realm.eval(realmB, "Array");
+instanceof_check(Array);
+instanceof_check(realmBArray);
- function newarraycase_list_smidouble(value) {
- var a = new Array(1, 2, 3);
- a[0] = value;
- return a;
- }
+// instanceof_check2 is here because the call site goes through a state.
+// Since instanceof_check(Array) was first called with the current context
+// Array function, it went from (uninit->Array) then (Array->megamorphic).
+// We'll get a different state traversal if we start with realmBArray.
+// It'll go (uninit->realmBArray) then (realmBArray->megamorphic). Recognize
+// that state "Array" implies an AllocationSite is present, and code is
+// configured to use it.
+instanceof_check2(realmBArray);
+instanceof_check2(Array);
- obj = newarraycase_list_smidouble(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = newarraycase_list_smidouble(1.5);
- assertKind(elements_kind.fast_double, obj);
- obj = newarraycase_list_smidouble(2);
- assertKind(elements_kind.fast_double, obj);
+ %OptimizeFunctionOnNextCall(instanceof_check);
- function newarraycase_list_smiobj(value) {
- var a = new Array(4, 5, 6);
- a[0] = value;
- return a;
+// No de-opt will occur because HCallNewArray wasn't selected, on account of
+// the call site not being monomorphic to Array.
+instanceof_check(Array);
+assertOptimized(instanceof_check);
+instanceof_check(realmBArray);
+assertOptimized(instanceof_check);
+
+// Try to optimize again, but first clear all type feedback, and allow it
+// to be monomorphic on first call. Only after crankshafting do we introduce
+// realmBArray. This should deopt the method.
+ %DeoptimizeFunction(instanceof_check);
+ %ClearFunctionTypeFeedback(instanceof_check);
+instanceof_check(Array);
+instanceof_check(Array);
+ %OptimizeFunctionOnNextCall(instanceof_check);
+instanceof_check(Array);
+assertOptimized(instanceof_check);
+
+instanceof_check(realmBArray);
+assertUnoptimized(instanceof_check);
+
+// Case: make sure nested arrays benefit from allocation site feedback as
+// well.
+(function() {
+ // Make sure we handle nested arrays
+ function get_nested_literal() {
+ var literal = [[1,2,3,4], [2], [3]];
+ return literal;
}
- obj = newarraycase_list_smiobj(1);
- assertKind(elements_kind.fast_smi_only, obj);
- obj = newarraycase_list_smiobj("coates");
- assertKind(elements_kind.fast, obj);
- obj = newarraycase_list_smiobj(2);
+ obj = get_nested_literal();
assertKind(elements_kind.fast, obj);
-
- // Case: array constructor calls with out of date feedback.
- // The boilerplate should incorporate all feedback, but the input array
- // should be minimally transitioned based on immediate need.
- (function() {
- function foo(i) {
- // We have two cases, one for literals one for constructed arrays.
- var a = (i == 0)
- ? [1, 2, 3]
- : new Array(1, 2, 3);
- return a;
- }
-
- for (i = 0; i < 2; i++) {
- a = foo(i);
- b = foo(i);
- b[5] = 1; // boilerplate goes holey
- assertHoley(foo(i));
- a[0] = 3.5; // boilerplate goes holey double
- assertKind(elements_kind.fast_double, a);
- assertNotHoley(a);
- c = foo(i);
- assertKind(elements_kind.fast_double, c);
- assertHoley(c);
- }
- })();
-
- function newarraycase_onearg(len, value) {
- var a = new Array(len);
- a[0] = value;
- return a;
+ obj[0][0] = 3.5;
+ obj[2][0] = "hello";
+ obj = get_nested_literal();
+ assertKind(elements_kind.fast_double, obj[0]);
+ assertKind(elements_kind.fast_smi_only, obj[1]);
+ assertKind(elements_kind.fast, obj[2]);
+
+ // A more complex nested literal case.
+ function get_deep_nested_literal() {
+ var literal = [[1], [[2], "hello"], 3, [4]];
+ return literal;
}
- obj = newarraycase_onearg(5, 3.5);
- assertKind(elements_kind.fast_double, obj);
- obj = newarraycase_onearg(10, 5);
- assertKind(elements_kind.fast_double, obj);
- obj = newarraycase_onearg(0, 5);
- assertKind(elements_kind.fast_double, obj);
- // Now pass a length that forces the dictionary path.
- obj = newarraycase_onearg(100000, 5);
- assertKind(elements_kind.dictionary, obj);
- assertTrue(obj.length == 100000);
-
- // Verify that cross context calls work
- var realmA = Realm.current();
- var realmB = Realm.create();
- assertEquals(0, realmA);
- assertEquals(1, realmB);
-
- function instanceof_check(type) {
- assertTrue(new type() instanceof type);
- assertTrue(new type(5) instanceof type);
- assertTrue(new type(1,2,3) instanceof type);
+ obj = get_deep_nested_literal();
+ assertKind(elements_kind.fast_smi_only, obj[1][0]);
+ obj[0][0] = 3.5;
+ obj[1][0][0] = "goodbye";
+ assertKind(elements_kind.fast_double, obj[0]);
+ assertKind(elements_kind.fast, obj[1][0]);
+
+ obj = get_deep_nested_literal();
+ assertKind(elements_kind.fast_double, obj[0]);
+ assertKind(elements_kind.fast, obj[1][0]);
+})();
+
+// Perform a gc because without it the test below can experience an
+// allocation failure at an inconvenient point. Allocation mementos get
+// cleared on gc, and they can't deliver elements kind feedback when that
+// happens.
+gc();
+
+// Make sure object literals with array fields benefit from the type feedback
+// that allocation mementos provide.
+(function() {
+ // A literal in an object
+ function get_object_literal() {
+ var literal = {
+ array: [1,2,3],
+ data: 3.5
+ };
+ return literal;
}
- function instanceof_check2(type) {
- assertTrue(new type() instanceof type);
- assertTrue(new type(5) instanceof type);
- assertTrue(new type(1,2,3) instanceof type);
+ obj = get_object_literal();
+ assertKind(elements_kind.fast_smi_only, obj.array);
+ obj.array[1] = 3.5;
+ assertKind(elements_kind.fast_double, obj.array);
+ obj = get_object_literal();
+ assertKind(elements_kind.fast_double, obj.array);
+
+ function get_nested_object_literal() {
+ var literal = {
+ array: [[1],[2],[3]],
+ data: 3.5
+ };
+ return literal;
}
- var realmBArray = Realm.eval(realmB, "Array");
- instanceof_check(Array);
- instanceof_check(realmBArray);
-
- // instanceof_check2 is here because the call site goes through a state.
- // Since instanceof_check(Array) was first called with the current context
- // Array function, it went from (uninit->Array) then (Array->megamorphic).
- // We'll get a different state traversal if we start with realmBArray.
- // It'll go (uninit->realmBArray) then (realmBArray->megamorphic). Recognize
- // that state "Array" implies an AllocationSite is present, and code is
- // configured to use it.
- instanceof_check2(realmBArray);
- instanceof_check2(Array);
+ obj = get_nested_object_literal();
+ assertKind(elements_kind.fast, obj.array);
+ assertKind(elements_kind.fast_smi_only, obj.array[1]);
+ obj.array[1][0] = 3.5;
+ assertKind(elements_kind.fast_double, obj.array[1]);
+ obj = get_nested_object_literal();
+ assertKind(elements_kind.fast_double, obj.array[1]);
- %OptimizeFunctionOnNextCall(instanceof_check);
+ %OptimizeFunctionOnNextCall(get_nested_object_literal);
+ get_nested_object_literal();
+ obj = get_nested_object_literal();
+ assertKind(elements_kind.fast_double, obj.array[1]);
- // No de-opt will occur because HCallNewArray wasn't selected, on account of
- // the call site not being monomorphic to Array.
- instanceof_check(Array);
- assertOptimized(instanceof_check);
- instanceof_check(realmBArray);
- assertOptimized(instanceof_check);
+ // Make sure we handle nested arrays
+ function get_nested_literal() {
+ var literal = [[1,2,3,4], [2], [3]];
+ return literal;
+ }
- // Try to optimize again, but first clear all type feedback, and allow it
- // to be monomorphic on first call. Only after crankshafting do we introduce
- // realmBArray. This should deopt the method.
- %DeoptimizeFunction(instanceof_check);
- %ClearFunctionTypeFeedback(instanceof_check);
- instanceof_check(Array);
- instanceof_check(Array);
- %OptimizeFunctionOnNextCall(instanceof_check);
- instanceof_check(Array);
- assertOptimized(instanceof_check);
-
- instanceof_check(realmBArray);
- assertUnoptimized(instanceof_check);
-
- // Case: make sure nested arrays benefit from allocation site feedback as
- // well.
- (function() {
- // Make sure we handle nested arrays
- function get_nested_literal() {
- var literal = [[1,2,3,4], [2], [3]];
- return literal;
- }
-
- obj = get_nested_literal();
- assertKind(elements_kind.fast, obj);
- obj[0][0] = 3.5;
- obj[2][0] = "hello";
- obj = get_nested_literal();
- assertKind(elements_kind.fast_double, obj[0]);
- assertKind(elements_kind.fast_smi_only, obj[1]);
- assertKind(elements_kind.fast, obj[2]);
-
- // A more complex nested literal case.
- function get_deep_nested_literal() {
- var literal = [[1], [[2], "hello"], 3, [4]];
- return literal;
- }
-
- obj = get_deep_nested_literal();
- assertKind(elements_kind.fast_smi_only, obj[1][0]);
- obj[0][0] = 3.5;
- obj[1][0][0] = "goodbye";
- assertKind(elements_kind.fast_double, obj[0]);
- assertKind(elements_kind.fast, obj[1][0]);
-
- obj = get_deep_nested_literal();
- assertKind(elements_kind.fast_double, obj[0]);
- assertKind(elements_kind.fast, obj[1][0]);
- })();
-
-
- // Make sure object literals with array fields benefit from the type feedback
- // that allocation mementos provide.
- (function() {
- // A literal in an object
- function get_object_literal() {
- var literal = {
- array: [1,2,3],
- data: 3.5
- };
- return literal;
- }
-
- obj = get_object_literal();
- assertKind(elements_kind.fast_smi_only, obj.array);
- obj.array[1] = 3.5;
- assertKind(elements_kind.fast_double, obj.array);
- obj = get_object_literal();
- assertKind(elements_kind.fast_double, obj.array);
-
- function get_nested_object_literal() {
- var literal = {
- array: [[1],[2],[3]],
- data: 3.5
- };
- return literal;
- }
-
- obj = get_nested_object_literal();
- assertKind(elements_kind.fast, obj.array);
- assertKind(elements_kind.fast_smi_only, obj.array[1]);
- obj.array[1][0] = 3.5;
- assertKind(elements_kind.fast_double, obj.array[1]);
- obj = get_nested_object_literal();
- assertKind(elements_kind.fast_double, obj.array[1]);
+ obj = get_nested_literal();
+ assertKind(elements_kind.fast, obj);
+ obj[0][0] = 3.5;
+ obj[2][0] = "hello";
+ obj = get_nested_literal();
+ assertKind(elements_kind.fast_double, obj[0]);
+ assertKind(elements_kind.fast_smi_only, obj[1]);
+ assertKind(elements_kind.fast, obj[2]);
+
+ // A more complex nested literal case.
+ function get_deep_nested_literal() {
+ var literal = [[1], [[2], "hello"], 3, [4]];
+ return literal;
+ }
- %OptimizeFunctionOnNextCall(get_nested_object_literal);
- get_nested_object_literal();
- obj = get_nested_object_literal();
- assertKind(elements_kind.fast_double, obj.array[1]);
-
- // Make sure we handle nested arrays
- function get_nested_literal() {
- var literal = [[1,2,3,4], [2], [3]];
- return literal;
- }
-
- obj = get_nested_literal();
- assertKind(elements_kind.fast, obj);
- obj[0][0] = 3.5;
- obj[2][0] = "hello";
- obj = get_nested_literal();
- assertKind(elements_kind.fast_double, obj[0]);
- assertKind(elements_kind.fast_smi_only, obj[1]);
- assertKind(elements_kind.fast, obj[2]);
-
- // A more complex nested literal case.
- function get_deep_nested_literal() {
- var literal = [[1], [[2], "hello"], 3, [4]];
- return literal;
- }
-
- obj = get_deep_nested_literal();
- assertKind(elements_kind.fast_smi_only, obj[1][0]);
- obj[0][0] = 3.5;
- obj[1][0][0] = "goodbye";
- assertKind(elements_kind.fast_double, obj[0]);
- assertKind(elements_kind.fast, obj[1][0]);
-
- obj = get_deep_nested_literal();
- assertKind(elements_kind.fast_double, obj[0]);
- assertKind(elements_kind.fast, obj[1][0]);
- })();
-}
+ obj = get_deep_nested_literal();
+ assertKind(elements_kind.fast_smi_only, obj[1][0]);
+ obj[0][0] = 3.5;
+ obj[1][0][0] = "goodbye";
+ assertKind(elements_kind.fast_double, obj[0]);
+ assertKind(elements_kind.fast, obj[1][0]);
+
+ obj = get_deep_nested_literal();
+ assertKind(elements_kind.fast_double, obj[0]);
+ assertKind(elements_kind.fast, obj[1][0]);
+})();
diff --git a/deps/v8/test/mjsunit/apply.js b/deps/v8/test/mjsunit/apply.js
index 413ee937c6..abbc9a11b4 100644
--- a/deps/v8/test/mjsunit/apply.js
+++ b/deps/v8/test/mjsunit/apply.js
@@ -25,6 +25,8 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+// Flags: --allow-natives-syntax
+
function f0() {
return this;
}
@@ -114,7 +116,8 @@ function al() {
for (var j = 1; j < 0x40000000; j <<= 1) {
try {
- var a = new Array(j);
+ var a = %NormalizeElements([]);
+ a.length = j;
a[j - 1] = 42;
assertEquals(42 + j, al.apply(345, a));
} catch (e) {
@@ -122,7 +125,8 @@ for (var j = 1; j < 0x40000000; j <<= 1) {
for (; j < 0x40000000; j <<= 1) {
var caught = false;
try {
- a = new Array(j);
+ a = %NormalizeElements([]);
+ a.length = j;
a[j - 1] = 42;
al.apply(345, a);
assertUnreachable("Apply of array with length " + a.length +
diff --git a/deps/v8/test/mjsunit/array-construct-transition.js b/deps/v8/test/mjsunit/array-construct-transition.js
index f8d7c830e5..3847f9405a 100644
--- a/deps/v8/test/mjsunit/array-construct-transition.js
+++ b/deps/v8/test/mjsunit/array-construct-transition.js
@@ -25,15 +25,11 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays
+// Flags: --allow-natives-syntax
-support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6));
-
-if (support_smi_only_arrays) {
- var a = new Array(0, 1, 2);
- assertTrue(%HasFastSmiElements(a));
- var b = new Array(0.5, 1.2, 2.3);
- assertTrue(%HasFastDoubleElements(b));
- var c = new Array(0.5, 1.2, new Object());
- assertTrue(%HasFastObjectElements(c));
-}
+var a = new Array(0, 1, 2);
+assertTrue(%HasFastSmiElements(a));
+var b = new Array(0.5, 1.2, 2.3);
+assertTrue(%HasFastDoubleElements(b));
+var c = new Array(0.5, 1.2, new Object());
+assertTrue(%HasFastObjectElements(c));
diff --git a/deps/v8/test/mjsunit/array-constructor-feedback.js b/deps/v8/test/mjsunit/array-constructor-feedback.js
index 45d5c58c77..c2c1a1842f 100644
--- a/deps/v8/test/mjsunit/array-constructor-feedback.js
+++ b/deps/v8/test/mjsunit/array-constructor-feedback.js
@@ -25,24 +25,10 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Flags: --noalways-opt
// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-// support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-support_smi_only_arrays = true;
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
var elements_kind = {
fast_smi_only : 'fast smi only elements',
@@ -73,183 +59,161 @@ function isHoley(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
-if (support_smi_only_arrays) {
-
- // Test: If a call site goes megamorphic, it retains the ability to
- // use allocation site feedback (if FLAG_allocation_site_pretenuring
- // is on).
- (function() {
- function bar(t, len) {
- return new t(len);
- }
-
- a = bar(Array, 10);
- a[0] = 3.5;
- b = bar(Array, 1);
- assertKind(elements_kind.fast_double, b);
- c = bar(Object, 3);
- b = bar(Array, 10);
- // TODO(mvstanton): re-enable when FLAG_allocation_site_pretenuring
- // is on in the build.
- // assertKind(elements_kind.fast_double, b);
- })();
-
-
- // Test: ensure that crankshafted array constructor sites are deopted
- // if another function is used.
- (function() {
- function bar0(t) {
- return new t();
- }
- a = bar0(Array);
- a[0] = 3.5;
- b = bar0(Array);
- assertKind(elements_kind.fast_double, b);
+// Test: If a call site goes megamorphic, it retains the ability to
+// use allocation site feedback (if FLAG_allocation_site_pretenuring
+// is on).
+(function() {
+ function bar(t, len) {
+ return new t(len);
+ }
+
+ a = bar(Array, 10);
+ a[0] = 3.5;
+ b = bar(Array, 1);
+ assertKind(elements_kind.fast_double, b);
+ c = bar(Object, 3);
+ b = bar(Array, 10);
+ // TODO(mvstanton): re-enable when FLAG_allocation_site_pretenuring
+ // is on in the build.
+ // assertKind(elements_kind.fast_double, b);
+})();
+
+
+// Test: ensure that crankshafted array constructor sites are deopted
+// if another function is used.
+(function() {
+ function bar0(t) {
+ return new t();
+ }
+ a = bar0(Array);
+ a[0] = 3.5;
+ b = bar0(Array);
+ assertKind(elements_kind.fast_double, b);
%OptimizeFunctionOnNextCall(bar0);
- b = bar0(Array);
- assertKind(elements_kind.fast_double, b);
- assertOptimized(bar0);
- // bar0 should deopt
- b = bar0(Object);
- assertUnoptimized(bar0)
- // When it's re-optimized, we should call through the full stub
- bar0(Array);
+ b = bar0(Array);
+ assertKind(elements_kind.fast_double, b);
+ assertOptimized(bar0);
+ // bar0 should deopt
+ b = bar0(Object);
+ assertUnoptimized(bar0)
+ // When it's re-optimized, we should call through the full stub
+ bar0(Array);
%OptimizeFunctionOnNextCall(bar0);
- b = bar0(Array);
- // This only makes sense to test if we allow crankshafting
- if (4 != %GetOptimizationStatus(bar0)) {
- // We also lost our ability to record kind feedback, as the site
- // is megamorphic now.
- assertKind(elements_kind.fast_smi_only, b);
- assertOptimized(bar0);
- b[0] = 3.5;
- c = bar0(Array);
- assertKind(elements_kind.fast_smi_only, c);
- }
- })();
-
-
- // Test: Ensure that inlined array calls in crankshaft learn from deopts
- // based on the move to a dictionary for the array.
- (function() {
- function bar(len) {
- return new Array(len);
- }
- a = bar(10);
- a[0] = "a string";
- a = bar(10);
- assertKind(elements_kind.fast, a);
- %OptimizeFunctionOnNextCall(bar);
- a = bar(10);
- assertKind(elements_kind.fast, a);
- assertOptimized(bar);
- // bar should deopt because the length is too large.
- a = bar(100000);
- assertUnoptimized(bar);
- assertKind(elements_kind.dictionary, a);
- // The allocation site now has feedback that means the array constructor
- // will not be inlined.
- %OptimizeFunctionOnNextCall(bar);
- a = bar(100000);
- assertKind(elements_kind.dictionary, a);
- assertOptimized(bar);
+ b = bar0(Array);
+ // This only makes sense to test if we allow crankshafting
+ if (4 != %GetOptimizationStatus(bar0)) {
+ // We also lost our ability to record kind feedback, as the site
+ // is megamorphic now.
+ assertKind(elements_kind.fast_smi_only, b);
+ assertOptimized(bar0);
+ b[0] = 3.5;
+ c = bar0(Array);
+ assertKind(elements_kind.fast_smi_only, c);
+ }
+})();
- // If the argument isn't a smi, it bails out as well
- a = bar("oops");
- assertOptimized(bar);
- assertKind(elements_kind.fast, a);
- function barn(one, two, three) {
- return new Array(one, two, three);
- }
+// Test: Ensure that inlined array calls in crankshaft learn from deopts
+// based on the move to a dictionary for the array.
+(function() {
+ function bar(len) {
+ return new Array(len);
+ }
+ a = bar(10);
+ a[0] = "a string";
+ a = bar(10);
+ assertKind(elements_kind.fast, a);
+ %OptimizeFunctionOnNextCall(bar);
+ a = bar(10);
+ assertKind(elements_kind.fast, a);
+ assertOptimized(bar);
+ bar(100000);
+ assertOptimized(bar);
+
+ // If the argument isn't a smi, things should still work.
+ a = bar("oops");
+ assertOptimized(bar);
+ assertKind(elements_kind.fast, a);
+
+ function barn(one, two, three) {
+ return new Array(one, two, three);
+ }
- barn(1, 2, 3);
- barn(1, 2, 3);
- %OptimizeFunctionOnNextCall(barn);
- barn(1, 2, 3);
- assertOptimized(barn);
- a = barn(1, "oops", 3);
- // The method should deopt, but learn from the failure to avoid inlining
- // the array.
- assertKind(elements_kind.fast, a);
- assertUnoptimized(barn);
+ barn(1, 2, 3);
+ barn(1, 2, 3);
%OptimizeFunctionOnNextCall(barn);
- a = barn(1, "oops", 3);
- assertOptimized(barn);
- })();
-
-
- // Test: When a method with array constructor is crankshafted, the type
- // feedback for elements kind is baked in. Verify that transitions don't
- // change it anymore
- (function() {
- function bar() {
- return new Array();
- }
- a = bar();
- bar();
+ barn(1, 2, 3);
+ assertOptimized(barn);
+ a = barn(1, "oops", 3);
+ assertOptimized(barn);
+})();
+
+
+// Test: When a method with array constructor is crankshafted, the type
+// feedback for elements kind is baked in. Verify that transitions don't
+// change it anymore
+(function() {
+ function bar() {
+ return new Array();
+ }
+ a = bar();
+ bar();
%OptimizeFunctionOnNextCall(bar);
- b = bar();
- // This only makes sense to test if we allow crankshafting
- if (4 != %GetOptimizationStatus(bar)) {
- assertOptimized(bar);
+ b = bar();
+ // This only makes sense to test if we allow crankshafting
+ if (4 != %GetOptimizationStatus(bar)) {
+ assertOptimized(bar);
%DebugPrint(3);
- b[0] = 3.5;
- c = bar();
- assertKind(elements_kind.fast_smi_only, c);
- assertOptimized(bar);
- }
- })();
-
-
- // Test: create arrays in two contexts, verifying that the correct
- // map for Array in that context will be used.
- (function() {
- function bar() { return new Array(); }
- bar();
- bar();
+ b[0] = 3.5;
+ c = bar();
+ assertKind(elements_kind.fast_smi_only, c);
+ assertOptimized(bar);
+ }
+})();
+
+
+// Test: create arrays in two contexts, verifying that the correct
+// map for Array in that context will be used.
+(function() {
+ function bar() { return new Array(); }
+ bar();
+ bar();
%OptimizeFunctionOnNextCall(bar);
- a = bar();
- assertTrue(a instanceof Array);
-
- var contextB = Realm.create();
- Realm.eval(contextB, "function bar2() { return new Array(); };");
- Realm.eval(contextB, "bar2(); bar2();");
- Realm.eval(contextB, "%OptimizeFunctionOnNextCall(bar2);");
- Realm.eval(contextB, "bar2();");
- assertFalse(Realm.eval(contextB, "bar2();") instanceof Array);
- assertTrue(Realm.eval(contextB, "bar2() instanceof Array"));
- })();
-
- // Test: create array with packed feedback, then optimize/inline
- // function. Verify that if we ask for a holey array then we deopt.
- // Reoptimization will proceed with the correct feedback and we
- // won't deopt anymore.
- (function() {
- function bar(len) { return new Array(len); }
- bar(0);
- bar(0);
+ a = bar();
+ assertTrue(a instanceof Array);
+
+ var contextB = Realm.create();
+ Realm.eval(contextB, "function bar2() { return new Array(); };");
+ Realm.eval(contextB, "bar2(); bar2();");
+ Realm.eval(contextB, "%OptimizeFunctionOnNextCall(bar2);");
+ Realm.eval(contextB, "bar2();");
+ assertFalse(Realm.eval(contextB, "bar2();") instanceof Array);
+ assertTrue(Realm.eval(contextB, "bar2() instanceof Array"));
+})();
+
+// Test: create array with packed feedback, then optimize function, which
+// should deal with arguments that create holey arrays.
+(function() {
+ function bar(len) { return new Array(len); }
+ bar(0);
+ bar(0);
%OptimizeFunctionOnNextCall(bar);
- a = bar(0);
- assertOptimized(bar);
+ a = bar(0);
+ assertOptimized(bar);
+ assertFalse(isHoley(a));
+ a = bar(1); // ouch!
+ assertOptimized(bar);
+ assertTrue(isHoley(a));
+ a = bar(100);
+ assertTrue(isHoley(a));
+ a = bar(0);
+ assertOptimized(bar);
+ // Crankshafted functions don't use mementos, so feedback still
+ // indicates a packed array is desired. (unless --nocrankshaft is in use).
+ if (4 != %GetOptimizationStatus(bar)) {
assertFalse(isHoley(a));
- a = bar(1); // ouch!
- assertUnoptimized(bar);
- assertTrue(isHoley(a));
- // Try again
- %OptimizeFunctionOnNextCall(bar);
- a = bar(100);
- assertOptimized(bar);
- assertTrue(isHoley(a));
- a = bar(0);
- assertOptimized(bar);
- assertTrue(isHoley(a));
- })();
-}
+ }
+})();
diff --git a/deps/v8/test/mjsunit/array-feedback.js b/deps/v8/test/mjsunit/array-feedback.js
index 4129be1f88..ffbb49b19a 100644
--- a/deps/v8/test/mjsunit/array-feedback.js
+++ b/deps/v8/test/mjsunit/array-feedback.js
@@ -25,25 +25,9 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Flags: --noalways-opt
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-// support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-support_smi_only_arrays = true;
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
var elements_kind = {
fast_smi_only : 'fast smi only elements',
fast : 'fast elements',
@@ -73,144 +57,153 @@ function isHoley(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
-if (support_smi_only_arrays) {
-
- // Verify that basic elements kind feedback works for non-constructor
- // array calls (as long as the call is made through an IC, and not
- // a CallStub).
- // (function (){
- // function create0() {
- // return Array();
- // }
-
- // // Calls through ICs need warm up through uninitialized, then
- // // premonomorphic first.
- // create0();
- // create0();
- // a = create0();
- // assertKind(elements_kind.fast_smi_only, a);
- // a[0] = 3.5;
- // b = create0();
- // assertKind(elements_kind.fast_double, b);
-
- // function create1(arg) {
- // return Array(arg);
- // }
-
- // create1(0);
- // create1(0);
- // a = create1(0);
- // assertFalse(isHoley(a));
- // assertKind(elements_kind.fast_smi_only, a);
- // a[0] = "hello";
- // b = create1(10);
- // assertTrue(isHoley(b));
- // assertKind(elements_kind.fast, b);
-
- // a = create1(100000);
- // assertKind(elements_kind.dictionary, a);
-
- // function create3(arg1, arg2, arg3) {
- // return Array(arg1, arg2, arg3);
- // }
-
- // create3();
- // create3();
- // a = create3(1,2,3);
- // a[0] = 3.5;
- // b = create3(1,2,3);
- // assertKind(elements_kind.fast_double, b);
- // assertFalse(isHoley(b));
- // })();
-
-
- // Verify that keyed calls work
- // (function (){
- // function create0(name) {
- // return this[name]();
- // }
-
- // name = "Array";
- // create0(name);
- // create0(name);
- // a = create0(name);
- // a[0] = 3.5;
- // b = create0(name);
- // assertKind(elements_kind.fast_double, b);
- // })();
-
-
- // Verify that the IC can't be spoofed by patching
- (function (){
- function create0() {
- return Array();
- }
-
- create0();
- create0();
- a = create0();
- assertKind(elements_kind.fast_smi_only, a);
- var oldArray = this.Array;
- this.Array = function() { return ["hi"]; };
- b = create0();
- assertEquals(["hi"], b);
- this.Array = oldArray;
- })();
-
- // Verify that calls are still made through an IC after crankshaft,
- // though the type information is reset.
- // TODO(mvstanton): instead, consume the type feedback gathered up
- // until crankshaft time.
- // (function (){
- // function create0() {
- // return Array();
- // }
-
- // create0();
- // create0();
- // a = create0();
- // a[0] = 3.5;
- // %OptimizeFunctionOnNextCall(create0);
- // create0();
- // // This test only makes sense if crankshaft is allowed
- // if (4 != %GetOptimizationStatus(create0)) {
- // create0();
- // b = create0();
- // assertKind(elements_kind.fast_smi_only, b);
- // b[0] = 3.5;
- // c = create0();
- // assertKind(elements_kind.fast_double, c);
- // assertOptimized(create0);
- // }
- // })();
-
-
- // Verify that cross context calls work
- (function (){
- var realmA = Realm.current();
- var realmB = Realm.create();
- assertEquals(0, realmA);
- assertEquals(1, realmB);
-
- function instanceof_check(type) {
- assertTrue(type() instanceof type);
- assertTrue(type(5) instanceof type);
- assertTrue(type(1,2,3) instanceof type);
- }
-
- var realmBArray = Realm.eval(realmB, "Array");
- instanceof_check(Array);
- instanceof_check(Array);
- instanceof_check(Array);
- instanceof_check(realmBArray);
- instanceof_check(realmBArray);
- instanceof_check(realmBArray);
- })();
-}
+// Verify that basic elements kind feedback works for non-constructor
+// array calls (as long as the call is made through an IC, and not
+// a CallStub).
+(function (){
+ function create0() {
+ return Array();
+ }
+
+ // Calls through ICs need warm up through uninitialized, then
+ // premonomorphic first.
+ create0();
+ a = create0();
+ assertKind(elements_kind.fast_smi_only, a);
+ a[0] = 3.5;
+ b = create0();
+ assertKind(elements_kind.fast_double, b);
+
+ function create1(arg) {
+ return Array(arg);
+ }
+
+ create1(0);
+ create1(0);
+ a = create1(0);
+ assertFalse(isHoley(a));
+ assertKind(elements_kind.fast_smi_only, a);
+ a[0] = "hello";
+ b = create1(10);
+ assertTrue(isHoley(b));
+ assertKind(elements_kind.fast, b);
+
+ a = create1(100000);
+ assertKind(elements_kind.fast_smi_only, a);
+
+ function create3(arg1, arg2, arg3) {
+ return Array(arg1, arg2, arg3);
+ }
+
+ create3(1,2,3);
+ create3(1,2,3);
+ a = create3(1,2,3);
+ a[0] = 3.035;
+ assertKind(elements_kind.fast_double, a);
+ b = create3(1,2,3);
+ assertKind(elements_kind.fast_double, b);
+ assertFalse(isHoley(b));
+})();
+
+
+// Verify that keyed calls work
+(function (){
+ function create0(name) {
+ return this[name]();
+ }
+
+ name = "Array";
+ create0(name);
+ create0(name);
+ a = create0(name);
+ a[0] = 3.5;
+ b = create0(name);
+ assertKind(elements_kind.fast_double, b);
+})();
+
+
+// Verify that feedback is turned off if the call site goes megamorphic.
+(function (){
+ function foo(arg) { return arg(); }
+ foo(Array);
+ foo(function() {});
+ foo(Array);
+
+ gc();
+
+ a = foo(Array);
+ a[0] = 3.5;
+ b = foo(Array);
+ // b doesn't benefit from elements kind feedback at a megamorphic site.
+ assertKind(elements_kind.fast_smi_only, b);
+})();
+
+
+// Verify that crankshaft consumes type feedback.
+(function (){
+ function create0() {
+ return Array();
+ }
+
+ create0();
+ create0();
+ a = create0();
+ a[0] = 3.5;
+ %OptimizeFunctionOnNextCall(create0);
+ create0();
+ create0();
+ b = create0();
+ assertKind(elements_kind.fast_double, b);
+ assertOptimized(create0);
+
+ function create1(arg) {
+ return Array(arg);
+ }
+
+ create1(8);
+ create1(8);
+ a = create1(8);
+ a[0] = 3.5;
+ %OptimizeFunctionOnNextCall(create1);
+ b = create1(8);
+ assertKind(elements_kind.fast_double, b);
+ assertOptimized(create1);
+
+ function createN(arg1, arg2, arg3) {
+ return Array(arg1, arg2, arg3);
+ }
+
+ createN(1, 2, 3);
+ createN(1, 2, 3);
+ a = createN(1, 2, 3);
+ a[0] = 3.5;
+ %OptimizeFunctionOnNextCall(createN);
+ b = createN(1, 2, 3);
+ assertKind(elements_kind.fast_double, b);
+ assertOptimized(createN);
+})();
+
+// Verify that cross context calls work
+(function (){
+ var realmA = Realm.current();
+ var realmB = Realm.create();
+ assertEquals(0, realmA);
+ assertEquals(1, realmB);
+
+ function instanceof_check(type) {
+ assertTrue(type() instanceof type);
+ assertTrue(type(5) instanceof type);
+ assertTrue(type(1,2,3) instanceof type);
+ }
+
+ var realmBArray = Realm.eval(realmB, "Array");
+ instanceof_check(Array);
+ instanceof_check(Array);
+ instanceof_check(Array);
+ instanceof_check(realmBArray);
+ instanceof_check(realmBArray);
+ instanceof_check(realmBArray);
+})();
diff --git a/deps/v8/test/mjsunit/array-literal-feedback.js b/deps/v8/test/mjsunit/array-literal-feedback.js
index cfda0f6d5f..ed9c4e879e 100644
--- a/deps/v8/test/mjsunit/array-literal-feedback.js
+++ b/deps/v8/test/mjsunit/array-literal-feedback.js
@@ -25,25 +25,9 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Flags: --noalways-opt
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-// support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-support_smi_only_arrays = true;
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
var elements_kind = {
fast_smi_only : 'fast smi only elements',
fast : 'fast elements',
@@ -73,58 +57,51 @@ function isHoley(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
-if (support_smi_only_arrays) {
-
- function get_literal(x) {
- var literal = [1, 2, x];
- return literal;
- }
+function get_literal(x) {
+ var literal = [1, 2, x];
+ return literal;
+}
- get_literal(3);
- // It's important to store a from before we crankshaft get_literal, because
- // mementos won't be created from crankshafted code at all.
- a = get_literal(3);
+get_literal(3);
+// It's important to store a from before we crankshaft get_literal, because
+// mementos won't be created from crankshafted code at all.
+a = get_literal(3);
%OptimizeFunctionOnNextCall(get_literal);
- get_literal(3);
- assertOptimized(get_literal);
- assertTrue(%HasFastSmiElements(a));
- // a has a memento so the transition caused by the store will affect the
- // boilerplate.
- a[0] = 3.5;
-
- // We should have transitioned the boilerplate array to double, and
- // crankshafted code should de-opt on the unexpected elements kind
- b = get_literal(3);
- assertTrue(%HasFastDoubleElements(b));
- assertEquals([1, 2, 3], b);
- assertUnoptimized(get_literal);
-
- // Optimize again
- get_literal(3);
+get_literal(3);
+assertOptimized(get_literal);
+assertTrue(%HasFastSmiElements(a));
+// a has a memento so the transition caused by the store will affect the
+// boilerplate.
+a[0] = 3.5;
+
+// We should have transitioned the boilerplate array to double, and
+// crankshafted code should de-opt on the unexpected elements kind
+b = get_literal(3);
+assertTrue(%HasFastDoubleElements(b));
+assertEquals([1, 2, 3], b);
+assertUnoptimized(get_literal);
+
+// Optimize again
+get_literal(3);
%OptimizeFunctionOnNextCall(get_literal);
- b = get_literal(3);
- assertTrue(%HasFastDoubleElements(b));
- assertOptimized(get_literal);
+b = get_literal(3);
+assertTrue(%HasFastDoubleElements(b));
+assertOptimized(get_literal);
- // Test: make sure allocation site information is updated through a
- // transition from SMI->DOUBLE->FAST
- (function() {
- function bar(a, b, c) {
- return [a, b, c];
- }
+// Test: make sure allocation site information is updated through a
+// transition from SMI->DOUBLE->FAST
+(function() {
+ function bar(a, b, c) {
+ return [a, b, c];
+ }
- a = bar(1, 2, 3);
- a[0] = 3.5;
- a[1] = 'hi';
- b = bar(1, 2, 3);
- assertKind(elements_kind.fast, b);
- })();
-}
+ a = bar(1, 2, 3);
+ a[0] = 3.5;
+ a[1] = 'hi';
+ b = bar(1, 2, 3);
+ assertKind(elements_kind.fast, b);
+})();
diff --git a/deps/v8/test/mjsunit/array-literal-transitions.js b/deps/v8/test/mjsunit/array-literal-transitions.js
index ca6033b217..e1624553f4 100644
--- a/deps/v8/test/mjsunit/array-literal-transitions.js
+++ b/deps/v8/test/mjsunit/array-literal-transitions.js
@@ -25,22 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
-
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-support_smi_only_arrays = %HasFastSmiElements([1,2,3,4,5,6,7,8,9,10]);
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
+// Flags: --allow-natives-syntax --expose-gc
// IC and Crankshaft support for smi-only elements in dynamic array literals.
function get(foo) { return foo; } // Used to generate dynamic values.
@@ -94,114 +79,112 @@ function array_literal_test() {
assertEquals(1, f0[0]);
}
-if (support_smi_only_arrays) {
- for (var i = 0; i < 3; i++) {
- array_literal_test();
- }
- %OptimizeFunctionOnNextCall(array_literal_test);
+for (var i = 0; i < 3; i++) {
array_literal_test();
+}
+ %OptimizeFunctionOnNextCall(array_literal_test);
+array_literal_test();
+
+function test_large_literal() {
- function test_large_literal() {
-
- function d() {
- gc();
- return 2.5;
- }
-
- function o() {
- gc();
- return new Object();
- }
-
- large =
- [ 0, 1, 2, 3, 4, 5, d(), d(), d(), d(), d(), d(), o(), o(), o(), o() ];
- assertFalse(%HasDictionaryElements(large));
- assertFalse(%HasFastSmiElements(large));
- assertFalse(%HasFastDoubleElements(large));
- assertTrue(%HasFastObjectElements(large));
- assertEquals(large,
- [0, 1, 2, 3, 4, 5, 2.5, 2.5, 2.5, 2.5, 2.5, 2.5,
- new Object(), new Object(), new Object(), new Object()]);
+ function d() {
+ gc();
+ return 2.5;
}
- for (var i = 0; i < 3; i++) {
- test_large_literal();
+ function o() {
+ gc();
+ return new Object();
}
- %OptimizeFunctionOnNextCall(test_large_literal);
+
+ large =
+ [ 0, 1, 2, 3, 4, 5, d(), d(), d(), d(), d(), d(), o(), o(), o(), o() ];
+ assertFalse(%HasDictionaryElements(large));
+ assertFalse(%HasFastSmiElements(large));
+ assertFalse(%HasFastDoubleElements(large));
+ assertTrue(%HasFastObjectElements(large));
+ assertEquals(large,
+ [0, 1, 2, 3, 4, 5, 2.5, 2.5, 2.5, 2.5, 2.5, 2.5,
+ new Object(), new Object(), new Object(), new Object()]);
+}
+
+for (var i = 0; i < 3; i++) {
test_large_literal();
+}
+ %OptimizeFunctionOnNextCall(test_large_literal);
+test_large_literal();
- function deopt_array(use_literal) {
- if (use_literal) {
- return [.5, 3, 4];
- } else {
- return new Array();
- }
+function deopt_array(use_literal) {
+ if (use_literal) {
+ return [.5, 3, 4];
+ } else {
+ return new Array();
}
+}
- deopt_array(false);
- deopt_array(false);
- deopt_array(false);
+deopt_array(false);
+deopt_array(false);
+deopt_array(false);
%OptimizeFunctionOnNextCall(deopt_array);
- var array = deopt_array(false);
- assertOptimized(deopt_array);
- deopt_array(true);
- assertOptimized(deopt_array);
- array = deopt_array(false);
- assertOptimized(deopt_array);
-
- // Check that unexpected changes in the objects stored into the boilerplate
- // also force a deopt.
- function deopt_array_literal_all_smis(a) {
- return [0, 1, a];
- }
+var array = deopt_array(false);
+assertOptimized(deopt_array);
+deopt_array(true);
+assertOptimized(deopt_array);
+array = deopt_array(false);
+assertOptimized(deopt_array);
+
+// Check that unexpected changes in the objects stored into the boilerplate
+// also force a deopt.
+function deopt_array_literal_all_smis(a) {
+ return [0, 1, a];
+}
- deopt_array_literal_all_smis(2);
- deopt_array_literal_all_smis(3);
- deopt_array_literal_all_smis(4);
- array = deopt_array_literal_all_smis(4);
- assertEquals(0, array[0]);
- assertEquals(1, array[1]);
- assertEquals(4, array[2]);
+deopt_array_literal_all_smis(2);
+deopt_array_literal_all_smis(3);
+deopt_array_literal_all_smis(4);
+array = deopt_array_literal_all_smis(4);
+assertEquals(0, array[0]);
+assertEquals(1, array[1]);
+assertEquals(4, array[2]);
%OptimizeFunctionOnNextCall(deopt_array_literal_all_smis);
- array = deopt_array_literal_all_smis(5);
- array = deopt_array_literal_all_smis(6);
- assertOptimized(deopt_array_literal_all_smis);
- assertEquals(0, array[0]);
- assertEquals(1, array[1]);
- assertEquals(6, array[2]);
-
- array = deopt_array_literal_all_smis(.5);
- assertUnoptimized(deopt_array_literal_all_smis);
- assertEquals(0, array[0]);
- assertEquals(1, array[1]);
- assertEquals(.5, array[2]);
-
- function deopt_array_literal_all_doubles(a) {
- return [0.5, 1, a];
- }
+array = deopt_array_literal_all_smis(5);
+array = deopt_array_literal_all_smis(6);
+assertOptimized(deopt_array_literal_all_smis);
+assertEquals(0, array[0]);
+assertEquals(1, array[1]);
+assertEquals(6, array[2]);
+
+array = deopt_array_literal_all_smis(.5);
+assertUnoptimized(deopt_array_literal_all_smis);
+assertEquals(0, array[0]);
+assertEquals(1, array[1]);
+assertEquals(.5, array[2]);
+
+function deopt_array_literal_all_doubles(a) {
+ return [0.5, 1, a];
+}
- deopt_array_literal_all_doubles(.5);
- deopt_array_literal_all_doubles(.5);
- deopt_array_literal_all_doubles(.5);
- array = deopt_array_literal_all_doubles(0.5);
- assertEquals(0.5, array[0]);
- assertEquals(1, array[1]);
- assertEquals(0.5, array[2]);
+deopt_array_literal_all_doubles(.5);
+deopt_array_literal_all_doubles(.5);
+deopt_array_literal_all_doubles(.5);
+array = deopt_array_literal_all_doubles(0.5);
+assertEquals(0.5, array[0]);
+assertEquals(1, array[1]);
+assertEquals(0.5, array[2]);
%OptimizeFunctionOnNextCall(deopt_array_literal_all_doubles);
- array = deopt_array_literal_all_doubles(5);
- array = deopt_array_literal_all_doubles(6);
- assertOptimized(deopt_array_literal_all_doubles);
- assertEquals(0.5, array[0]);
- assertEquals(1, array[1]);
- assertEquals(6, array[2]);
-
- var foo = new Object();
- array = deopt_array_literal_all_doubles(foo);
- assertUnoptimized(deopt_array_literal_all_doubles);
- assertEquals(0.5, array[0]);
- assertEquals(1, array[1]);
- assertEquals(foo, array[2]);
-}
+array = deopt_array_literal_all_doubles(5);
+array = deopt_array_literal_all_doubles(6);
+assertOptimized(deopt_array_literal_all_doubles);
+assertEquals(0.5, array[0]);
+assertEquals(1, array[1]);
+assertEquals(6, array[2]);
+
+var foo = new Object();
+array = deopt_array_literal_all_doubles(foo);
+assertUnoptimized(deopt_array_literal_all_doubles);
+assertEquals(0.5, array[0]);
+assertEquals(1, array[1]);
+assertEquals(foo, array[2]);
(function literals_after_osr() {
var color = [0];
diff --git a/deps/v8/test/mjsunit/array-natives-elements.js b/deps/v8/test/mjsunit/array-natives-elements.js
index cf848bb4b9..d63346d0a4 100644
--- a/deps/v8/test/mjsunit/array-natives-elements.js
+++ b/deps/v8/test/mjsunit/array-natives-elements.js
@@ -25,22 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays
-
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile time
-// sticks if built with snapshot. If --smi-only-arrays is deactivated by
-// default, only a no-snapshot build actually has smi-only arrays enabled in
-// this test case. Depending on whether smi-only arrays are actually enabled,
-// this test takes the appropriate code path to check smi-only arrays.
-
-support_smi_only_arrays = %HasFastSmiElements([1,2,3,4,5,6,7,8,9,10]);
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
+// Flags: --allow-natives-syntax
// IC and Crankshaft support for smi-only elements in dynamic array literals.
function get(foo) { return foo; } // Used to generate dynamic values.
@@ -54,29 +39,30 @@ function array_natives_test() {
assertTrue(%HasFastDoubleElements([1.1]));
assertTrue(%HasFastDoubleElements([1.1,2]));
- // Push
- var a0 = [1, 2, 3];
- if (%HasFastSmiElements(a0)) {
- assertTrue(%HasFastSmiElements(a0));
- a0.push(4);
- assertTrue(%HasFastSmiElements(a0));
- a0.push(1.3);
- assertTrue(%HasFastDoubleElements(a0));
- a0.push(1.5);
- assertTrue(%HasFastDoubleElements(a0));
- a0.push({});
- assertTrue(%HasFastObjectElements(a0));
- a0.push({});
- assertTrue(%HasFastObjectElements(a0));
- } else {
- assertTrue(%HasFastObjectElements(a0));
- a0.push(4);
- a0.push(1.3);
- a0.push(1.5);
- a0.push({});
- a0.push({});
- assertTrue(%HasFastObjectElements(a0));
+ // This code exists to eliminate the learning influence of AllocationSites
+ // on the following tests.
+ var __sequence = 0;
+ function make_array_string(literal) {
+ this.__sequence = this.__sequence + 1;
+ return "/* " + this.__sequence + " */ " + literal;
}
+ function make_array(literal) {
+ return eval(make_array_string(literal));
+ }
+
+ // Push
+ var a0 = make_array("[1, 2, 3]");
+ assertTrue(%HasFastSmiElements(a0));
+ a0.push(4);
+ assertTrue(%HasFastSmiElements(a0));
+ a0.push(1.3);
+ assertTrue(%HasFastDoubleElements(a0));
+ a0.push(1.5);
+ assertTrue(%HasFastDoubleElements(a0));
+ a0.push({});
+ assertTrue(%HasFastObjectElements(a0));
+ a0.push({});
+ assertTrue(%HasFastObjectElements(a0));
assertEquals([1,2,3,4,1.3,1.5,{},{}], a0);
// Concat
@@ -307,10 +293,8 @@ function array_natives_test() {
assertEquals([1.1,{},2,3], a4);
}
-if (support_smi_only_arrays) {
- for (var i = 0; i < 3; i++) {
- array_natives_test();
- }
- %OptimizeFunctionOnNextCall(array_natives_test);
+for (var i = 0; i < 3; i++) {
array_natives_test();
}
+%OptimizeFunctionOnNextCall(array_natives_test);
+array_natives_test();
diff --git a/deps/v8/test/mjsunit/array-push-unshift-read-only-length.js b/deps/v8/test/mjsunit/array-push-unshift-read-only-length.js
new file mode 100644
index 0000000000..67aa39787a
--- /dev/null
+++ b/deps/v8/test/mjsunit/array-push-unshift-read-only-length.js
@@ -0,0 +1,107 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function test(mode) {
+ var a = [];
+ Object.defineProperty(a, "length", { writable : false});
+
+ function check(f) {
+ try {
+ f(a);
+ } catch(e) { }
+ assertFalse(0 in a);
+ assertEquals(0, a.length);
+ }
+
+ function push(a) {
+ a.push(3);
+ }
+
+ if (mode == "fast properties") %ToFastProperties(a);
+
+ check(push);
+ check(push);
+ check(push);
+ %OptimizeFunctionOnNextCall(push);
+ check(push);
+
+ function unshift(a) {
+ a.unshift(3);
+ }
+
+ check(unshift);
+ check(unshift);
+ check(unshift);
+ %OptimizeFunctionOnNextCall(unshift);
+ check(unshift);
+}
+
+test("fast properties");
+
+test("normalized");
+
+var b = [];
+Object.defineProperty(b.__proto__, "0", {
+ set : function(v) {
+ b.x = v;
+ Object.defineProperty(b, "length", { writable : false });
+ },
+ get: function() {
+ return b.x;
+ }
+});
+
+b = [];
+try {
+ b.push(3, 4, 5);
+} catch(e) { }
+assertFalse(1 in b);
+assertFalse(2 in b);
+assertEquals(0, b.length);
+
+b = [];
+try {
+ b.unshift(3, 4, 5);
+} catch(e) { }
+assertFalse(1 in b);
+assertFalse(2 in b);
+assertEquals(0, b.length);
+
+b = [1, 2];
+try {
+ b.unshift(3, 4, 5);
+} catch(e) { }
+assertEquals(3, b[0]);
+assertEquals(4, b[1]);
+assertEquals(5, b[2]);
+assertEquals(1, b[3]);
+assertEquals(2, b[4]);
+assertEquals(5, b.length);
+
+b = [1, 2];
+
+Object.defineProperty(b.__proto__, "4", {
+ set : function(v) {
+ b.z = v;
+ Object.defineProperty(b, "length", { writable : false });
+ },
+ get: function() {
+ return b.z;
+ }
+});
+
+try {
+ b.unshift(3, 4, 5);
+} catch(e) { }
+
+// TODO(ulan): According to the ECMA-262 unshift should throw an exception
+// when moving b[0] to b[3] (see 15.4.4.13 step 6.d.ii). This is difficult
+// to do with our current implementation of SmartMove() in src/array.js and
+// it will regress performance. Uncomment the following line once acceptable
+// solution is found:
+// assertFalse(2 in b);
+// assertFalse(3 in b);
+// assertEquals(2, b.length);
diff --git a/deps/v8/test/mjsunit/array-shift2.js b/deps/v8/test/mjsunit/array-shift2.js
new file mode 100644
index 0000000000..73d8cd4ff1
--- /dev/null
+++ b/deps/v8/test/mjsunit/array-shift2.js
@@ -0,0 +1,18 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+Object.defineProperty(Array.prototype, "1", {
+ get: function() { return "element 1"; },
+ set: function(value) { }
+});
+function test(array) {
+ array.shift();
+ return array;
+}
+assertEquals(["element 1",2], test(["0",,2]));
+assertEquals(["element 1",{}], test([{},,{}]));
+%OptimizeFunctionOnNextCall(test);
+assertEquals(["element 1",0], test([{},,0]));
diff --git a/deps/v8/test/mjsunit/array-shift3.js b/deps/v8/test/mjsunit/array-shift3.js
new file mode 100644
index 0000000000..3a0afc596b
--- /dev/null
+++ b/deps/v8/test/mjsunit/array-shift3.js
@@ -0,0 +1,15 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+Array.prototype[1] = "element 1";
+function test(a) {
+ a.shift();
+ return a;
+}
+assertEquals(["element 1",{}], test([0,,{}]));
+assertEquals(["element 1",10], test([9,,10]));
+%OptimizeFunctionOnNextCall(test);
+assertEquals(["element 1",10], test([9,,10]));
diff --git a/deps/v8/test/mjsunit/assert-opt-and-deopt.js b/deps/v8/test/mjsunit/assert-opt-and-deopt.js
index d0caafa27c..e9aba1d3c9 100644
--- a/deps/v8/test/mjsunit/assert-opt-and-deopt.js
+++ b/deps/v8/test/mjsunit/assert-opt-and-deopt.js
@@ -137,7 +137,7 @@ OptTracker.prototype.DisableAsserts_ = function(func) {
case OptTracker.OptimizationState.NEVER:
return true;
}
- return false;
+ return true;
}
// (End of class OptTracker.)
diff --git a/deps/v8/test/mjsunit/binary-op-newspace.js b/deps/v8/test/mjsunit/binary-op-newspace.js
index dac7d24dba..52903f051a 100644
--- a/deps/v8/test/mjsunit/binary-op-newspace.js
+++ b/deps/v8/test/mjsunit/binary-op-newspace.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --noopt
+// Flags: --max-semi-space-size=1 --noopt
// Check that a mod where the stub code hits a failure in heap number
// allocation still works.
diff --git a/deps/v8/test/mjsunit/bounds-checks-elimination.js b/deps/v8/test/mjsunit/bounds-checks-elimination.js
new file mode 100644
index 0000000000..4ea7f17e52
--- /dev/null
+++ b/deps/v8/test/mjsunit/bounds-checks-elimination.js
@@ -0,0 +1,123 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --array-bounds-checks-elimination
+
+var a = []
+for (var i = 0; i < 9; i++) a[i] = i + 1;
+
+function test(f, arg1, arg2, expected) {
+ assertEquals(expected, f(arg1));
+ f(arg2);
+ %OptimizeFunctionOnNextCall(f);
+ assertEquals(expected, f(arg1));
+}
+
+test(function f0() {
+ return a[7] * a[6] * a[5] * a[4] * a[3] * a[2] * a[1] * a[0];
+}, 0, 1, 40320);
+
+test(function f1() {
+ return a[7] * a[6] * a[5] * a[4] * a[10] * a[2] * a[1] * a[0];
+}, 0, 1, NaN);
+
+test(function f2() {
+ return a[0] * a[1] * a[2] * a[3] * a[4] * a[5] * a[6] * a[7];
+}, 0, 1, 40320);
+
+test(function f3() {
+ return a[3] * a[0] * a[6] * a[7] * a[5] * a[1] * a[4] * a[2];
+}, 0, 1, 40320);
+
+test(function f4(b) {
+ return a[b+3] * a[0] * a[b+6] * a[7] * a[b+5] * a[1] * a[b+4] * a[2];
+}, 0, 1, 40320);
+
+test(function f5(b) {
+ return a[b+1] * a[0] * a[b+4] * a[7] * a[b+3] * a[1] * a[b+2] * a[2];
+}, 2, 3, 40320);
+
+test(function f6(b) {
+ var c;
+ if (b) c = a[3] * a[0] * a[6] * a[7];
+ return c * a[5] * a[1] * a[4] * a[2];
+}, true, false, 40320);
+
+test(function f7(b) {
+ var c = a[7];
+ if (b) c *= a[3] * a[0] * a[6];
+ return c * a[5] * a[1] * a[4] * a[2];
+}, true, false, 40320);
+
+test(function f8(b) {
+ var c = a[7];
+ if (b) c *= a[3] * a[0] * a[6];
+ return c * a[5] * a[10] * a[4] * a[2];
+}, true, false, NaN);
+
+test(function f9(b) {
+ var c = a[1];
+ if (b) {
+ c *= a[3] * a[0] * a[6];
+ } else {
+ c = a[6] * a[5] * a[4];
+ }
+ return c * a[5] * a[7] * a[4] * a[2];
+}, true, false, 40320);
+
+test(function fa(b) {
+ var c = a[1];
+ if (b) {
+ c = a[6] * a[b+5] * a[4];
+ } else {
+ c *= a[b+3] * a[0] * a[b+6];
+ }
+ return c * a[5] * a[b+7] * a[4] * a[2];
+}, 0, 1, 40320);
+
+test(function fb(b) {
+ var c = a[b-3];
+ if (b != 4) {
+ c = a[6] * a[b+1] * a[4];
+ } else {
+ c *= a[b-1] * a[0] * a[b+2];
+ }
+ return c * a[5] * a[b+3] * a[4] * a[b-2];
+}, 4, 3, 40320);
+
+test(function fc(b) {
+ var c = a[b-3];
+ if (b != 4) {
+ c = a[6] * a[b+1] * a[4];
+ } else {
+ c *= a[b-1] * a[0] * a[b+2];
+ }
+ return c * a[5] * a[b+3] * a[4] * a[b-2];
+}, 6, 3, NaN);
+
+test(function fd(b) {
+ var c = a[b-3];
+ if (b != 4) {
+ c = a[6] * a[b+1] * a[4];
+ } else {
+ c *= a[b-1] * a[0] * a[b+2];
+ }
+ return c * a[5] * a[b+3] * a[4] * a[b-2];
+}, 1, 4, NaN);
+
+test(function fe(b) {
+ var c = 1;
+ for (var i = 1; i < b-1; i++) {
+ c *= a[i-1] * a[i] * a[i+1];
+ }
+ return c;
+}, 8, 4, (40320 / 8 / 7) * (40320 / 8) * (40320 / 2));
+
+test(function ff(b) {
+ var c = 0;
+ for (var i = 0; i < b; i++) {
+ c += a[3] * a[0] * a[6] * a[7] * a[5] * a[1] * a[4] * a[2];
+ }
+ return c;
+}, 100, 4, 40320 * 100);
diff --git a/deps/v8/test/mjsunit/builtins.js b/deps/v8/test/mjsunit/builtins.js
index ce2c6802f0..fe7d35d8ea 100644
--- a/deps/v8/test/mjsunit/builtins.js
+++ b/deps/v8/test/mjsunit/builtins.js
@@ -38,6 +38,14 @@ function isFunction(obj) {
return typeof obj == "function";
}
+function isV8Native(name) {
+ return name == "GeneratorFunctionPrototype" ||
+ name == "SetIterator" ||
+ name == "MapIterator" ||
+ name == "ArrayIterator" ||
+ name == "StringIterator";
+}
+
function checkConstructor(func, name) {
// A constructor is a function with a prototype and properties on the
// prototype object besides "constructor";
@@ -54,12 +62,13 @@ function checkConstructor(func, name) {
assertFalse(proto_desc.writable, name);
assertFalse(proto_desc.configurable, name);
var prototype = proto_desc.value;
- assertEquals(name == "GeneratorFunctionPrototype" ? Object.prototype : null,
+ assertEquals(isV8Native(name) ? Object.prototype : null,
Object.getPrototypeOf(prototype),
name);
for (var i = 0; i < propNames.length; i++) {
var propName = propNames[i];
if (propName == "constructor") continue;
+ if (isV8Native(name)) continue;
var testName = name + "-" + propName;
var propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
assertTrue(propDesc.hasOwnProperty("value"), testName);
diff --git a/deps/v8/test/mjsunit/compiler/inline-arguments.js b/deps/v8/test/mjsunit/compiler/inline-arguments.js
index 1337ab237a..d52f31b5e9 100644
--- a/deps/v8/test/mjsunit/compiler/inline-arguments.js
+++ b/deps/v8/test/mjsunit/compiler/inline-arguments.js
@@ -309,3 +309,29 @@ test_toarr(toarr2);
delete forceDeopt.deopt;
outer();
})();
+
+
+// Test inlining of functions with %_Arguments and %_ArgumentsLength intrinsic.
+(function () {
+ function inner(len,a,b,c) {
+ assertSame(len, %_ArgumentsLength());
+ for (var i = 1; i < len; ++i) {
+ var c = String.fromCharCode(96 + i);
+ assertSame(c, %_Arguments(i));
+ }
+ }
+
+ function outer() {
+ inner(1);
+ inner(2, 'a');
+ inner(3, 'a', 'b');
+ inner(4, 'a', 'b', 'c');
+ inner(5, 'a', 'b', 'c', 'd');
+ inner(6, 'a', 'b', 'c', 'd', 'e');
+ }
+
+ outer();
+ outer();
+ %OptimizeFunctionOnNextCall(outer);
+ outer();
+})();
diff --git a/deps/v8/test/mjsunit/compiler/math-floor-global.js b/deps/v8/test/mjsunit/compiler/math-floor-global.js
index 4a3bcb7220..9ee649cb2d 100644
--- a/deps/v8/test/mjsunit/compiler/math-floor-global.js
+++ b/deps/v8/test/mjsunit/compiler/math-floor-global.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
// Test inlining of Math.floor when assigned to a global.
var flo = Math.floor;
diff --git a/deps/v8/test/mjsunit/compiler/math-floor-local.js b/deps/v8/test/mjsunit/compiler/math-floor-local.js
index 8424ac96d3..5ebe90b705 100644
--- a/deps/v8/test/mjsunit/compiler/math-floor-local.js
+++ b/deps/v8/test/mjsunit/compiler/math-floor-local.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
// Test inlining of Math.floor when assigned to a local.
var test_id = 0;
diff --git a/deps/v8/test/mjsunit/const-eval-init.js b/deps/v8/test/mjsunit/const-eval-init.js
index d3503845d0..50e3a8d0be 100644
--- a/deps/v8/test/mjsunit/const-eval-init.js
+++ b/deps/v8/test/mjsunit/const-eval-init.js
@@ -36,29 +36,29 @@ function testIntroduceGlobal() {
var source =
// Deleting 'x' removes the local const property.
"delete x;" +
- // Initialization turns into assignment to global 'x'.
+ // Initialization redefines global 'x'.
"const x = 3; assertEquals(3, x);" +
- // No constness of the global 'x'.
- "x = 4; assertEquals(4, x);";
+ // Test constness of the global 'x'.
+ "x = 4; assertEquals(3, x);";
eval(source);
}
testIntroduceGlobal();
-assertEquals(4, x);
+assertEquals("undefined", typeof x);
function testAssignExistingGlobal() {
var source =
// Delete 'x' to remove the local const property.
"delete x;" +
- // Initialization turns into assignment to global 'x'.
+ // Initialization redefines global 'x'.
"const x = 5; assertEquals(5, x);" +
- // No constness of the global 'x'.
- "x = 6; assertEquals(6, x);";
+ // Test constness of the global 'x'.
+ "x = 6; assertEquals(5, x);";
eval(source);
}
testAssignExistingGlobal();
-assertEquals(6, x);
+assertEquals("undefined", typeof x);
function testAssignmentArgument(x) {
function local() {
@@ -66,7 +66,7 @@ function testAssignmentArgument(x) {
eval(source);
}
local();
- assertEquals(7, x);
+ assertEquals("undefined", typeof x);
}
for (var i = 0; i < 5; i++) {
@@ -74,17 +74,18 @@ for (var i = 0; i < 5; i++) {
}
%OptimizeFunctionOnNextCall(testAssignmentArgument);
testAssignmentArgument();
-assertEquals(6, x);
+assertEquals("undefined", typeof x);
__defineSetter__('x', function() { throw 42; });
-function testAssignGlobalThrows() {
- // Initialization turns into assignment to global 'x' which
- // throws an exception.
- var source = "delete x; const x = 8";
+var finished = false;
+function testRedefineGlobal() {
+ // Initialization redefines global 'x'.
+ var source = "delete x; const x = 8; finished = true;";
eval(source);
}
-assertThrows("testAssignGlobalThrows()");
+testRedefineGlobal();
+assertTrue(finished);
function testInitFastCaseExtension() {
var source = "const x = 9; assertEquals(9, x); x = 10; assertEquals(9, x)";
@@ -111,7 +112,7 @@ function testAssignSurroundingContextSlot() {
eval(source);
}
local();
- assertEquals(13, x);
+ assertEquals(12, x);
}
testAssignSurroundingContextSlot();
diff --git a/deps/v8/test/mjsunit/const-redecl.js b/deps/v8/test/mjsunit/const-redecl.js
index c0b97e6ced..f311f0de66 100644
--- a/deps/v8/test/mjsunit/const-redecl.js
+++ b/deps/v8/test/mjsunit/const-redecl.js
@@ -49,37 +49,6 @@ function TestLocal(s,e) {
}
-// NOTE: TestGlobal usually only tests the given string in the context
-// of a global object in dictionary mode. This is because we use
-// delete to get rid of any added properties.
-function TestGlobal(s,e) {
- // Collect the global properties before the call.
- var properties = [];
- for (var key in this) properties.push(key);
- // Compute the result.
- var result;
- try {
- var code = s + (e ? "; $$$result=" + e : "");
- if (this.execScript) {
- execScript(code);
- } else {
- this.eval(code);
- }
- // Avoid issues if $$$result is not defined by
- // reading it through this.
- result = this.$$$result;
- } catch (x) {
- result = CheckException(x);
- }
- // Get rid of any introduced global properties before
- // returning the result.
- for (var key in this) {
- if (properties.indexOf(key) == -1) delete this[key];
- }
- return result;
-}
-
-
function TestContext(s,e) {
try {
// Use a with-statement to force the system to do dynamic
@@ -98,8 +67,6 @@ function TestAll(expected,s,opt_e) {
var msg = s;
if (opt_e) { e = opt_e; msg += "; " + opt_e; }
assertEquals(expected, TestLocal(s,e), "local:'" + msg + "'");
- // Redeclarations of global consts do not throw, they are silently ignored.
- assertEquals(42, TestGlobal(s, 42), "global:'" + msg + "'");
assertEquals(expected, TestContext(s,e), "context:'" + msg + "'");
}
@@ -112,7 +79,7 @@ function TestConflict(def0, def1) {
// Eval first definition.
TestAll("TypeError", 'eval("' + def0 +'"); ' + def1);
// Eval second definition.
- TestAll("TypeError", def0 + '; eval("' + def1 + '")');
+ TestAll("TypeError", def0 + '; eval("' + def1 +'")');
// Eval both definitions separately.
TestAll("TypeError", 'eval("' + def0 +'"); eval("' + def1 + '")');
}
@@ -234,47 +201,26 @@ var undefined = 1; // Should be silently ignored.
assertEquals(original_undef, undefined, "undefined got overwritten");
undefined = original_undef;
-var a; const a; const a = 1;
-assertEquals(1, a, "a has wrong value");
-a = 2;
-assertEquals(2, a, "a should be writable");
-
-var b = 1; const b = 2;
-assertEquals(2, b, "b has wrong value");
-
-var c = 1; const c = 2; const c = 3;
-assertEquals(3, c, "c has wrong value");
-
-const d = 1; const d = 2;
-assertEquals(1, d, "d has wrong value");
-
-const e = 1; var e = 2;
+const e = 1; eval('var e = 2');
assertEquals(1, e, "e has wrong value");
-const f = 1; const f;
-assertEquals(1, f, "f has wrong value");
-
-var g; const g = 1;
-assertEquals(1, g, "g has wrong value");
-g = 2;
-assertEquals(2, g, "g should be writable");
-
-const h; var h = 1;
-assertEquals(undefined,h, "h has wrong value");
+const h; eval('var h = 1');
+assertEquals(undefined, h, "h has wrong value");
eval("Object.defineProperty(this, 'i', { writable: true });"
+ "const i = 7;"
+ "assertEquals(7, i, \"i has wrong value\");");
var global = this;
-assertThrows(function() {
- Object.defineProperty(global, 'j', { writable: true })
-}, TypeError);
-const j = 2; // This is what makes the function above throw, because the
-// const declaration gets hoisted and makes the property non-configurable.
+Object.defineProperty(global, 'j', { value: 100, writable: true });
+assertEquals(100, j);
+// The const declaration stays configurable, so the declaration above goes
+// through even though the const declaration is hoisted above.
+const j = 2;
assertEquals(2, j, "j has wrong value");
-var k = 1; const k;
-// You could argue about the expected result here. For now, the winning
-// argument is that "const k;" is equivalent to "const k = undefined;".
-assertEquals(undefined, k, "k has wrong value");
+var k = 1;
+try { eval('const k'); } catch(e) { }
+assertEquals(1, k, "k has wrong value");
+try { eval('const k = 10'); } catch(e) { }
+assertEquals(1, k, "k has wrong value");
diff --git a/deps/v8/test/mjsunit/constant-folding-2.js b/deps/v8/test/mjsunit/constant-folding-2.js
index f429c6ca10..73cf040f5a 100644
--- a/deps/v8/test/mjsunit/constant-folding-2.js
+++ b/deps/v8/test/mjsunit/constant-folding-2.js
@@ -181,6 +181,17 @@ test(function mathRound() {
assertEquals(Math.pow(2, 52) + 1, Math.round(Math.pow(2, 52) + 1));
});
+test(function mathFround() {
+ assertTrue(isNaN(Math.fround(NaN)));
+ assertEquals("Infinity", String(1/Math.fround(0)));
+ assertEquals("-Infinity", String(1/Math.fround(-0)));
+ assertEquals("Infinity", String(Math.fround(Infinity)));
+ assertEquals("-Infinity", String(Math.fround(-Infinity)));
+ assertEquals("Infinity", String(Math.fround(1E200)));
+ assertEquals("-Infinity", String(Math.fround(-1E200)));
+ assertEquals(3.1415927410125732, Math.fround(Math.PI));
+});
+
test(function mathFloor() {
assertEquals(1, Math.floor(1.5));
assertEquals(-2, Math.floor(-1.5));
diff --git a/deps/v8/test/mjsunit/cross-realm-filtering.js b/deps/v8/test/mjsunit/cross-realm-filtering.js
new file mode 100644
index 0000000000..902cceb58f
--- /dev/null
+++ b/deps/v8/test/mjsunit/cross-realm-filtering.js
@@ -0,0 +1,141 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+var realms = [Realm.current(), Realm.create()];
+
+// Check stack trace filtering across security contexts.
+var thrower_script =
+ "(function () { Realm.eval(Realm.current(), 'throw Error()') })";
+Realm.shared = {
+ thrower_0: Realm.eval(realms[0], thrower_script),
+ thrower_1: Realm.eval(realms[1], thrower_script),
+};
+
+var script = " \
+ Error.prepareStackTrace = function(a, b) { return b; }; \
+ try { \
+ Realm.shared.thrower_0(); \
+ } catch (e) { \
+ Realm.shared.error_0 = e.stack; \
+ } \
+ try { \
+ Realm.shared.thrower_1(); \
+ } catch (e) { \
+ Realm.shared.error_1 = e.stack; \
+ } \
+";
+
+function assertNotIn(thrower, error) {
+ for (var i = 0; i < error.length; i++) {
+ assertFalse(false === error[i].getFunction());
+ }
+}
+
+Realm.eval(realms[1], script);
+assertSame(3, Realm.shared.error_0.length);
+assertSame(4, Realm.shared.error_1.length);
+
+assertTrue(Realm.shared.thrower_1 === Realm.shared.error_1[2].getFunction());
+assertNotIn(Realm.shared.thrower_0, Realm.shared.error_0);
+assertNotIn(Realm.shared.thrower_0, Realm.shared.error_1);
+
+Realm.eval(realms[0], script);
+assertSame(5, Realm.shared.error_0.length);
+assertSame(4, Realm.shared.error_1.length);
+
+assertTrue(Realm.shared.thrower_0 === Realm.shared.error_0[2].getFunction());
+assertNotIn(Realm.shared.thrower_1, Realm.shared.error_0);
+assertNotIn(Realm.shared.thrower_1, Realm.shared.error_1);
+
+
+// Check .caller filtering across security contexts.
+var caller_script = "(function (f) { f(); })";
+Realm.shared = {
+ caller_0 : Realm.eval(realms[0], caller_script),
+ caller_1 : Realm.eval(realms[1], caller_script),
+}
+
+script = " \
+ function f_0() { Realm.shared.result_0 = arguments.callee.caller; }; \
+ function f_1() { Realm.shared.result_1 = arguments.callee.caller; }; \
+ Realm.shared.caller_0(f_0); \
+ Realm.shared.caller_1(f_1); \
+";
+
+Realm.eval(realms[1], script);
+assertSame(null, Realm.shared.result_0);
+assertSame(Realm.shared.caller_1, Realm.shared.result_1);
+
+Realm.eval(realms[0], script);
+assertSame(Realm.shared.caller_0, Realm.shared.result_0);
+assertSame(null, Realm.shared.result_1);
+
+
+// Check function constructor.
+var ctor_script = "Function.constructor";
+var ctor_a_script =
+ "(function() { return Function.constructor.apply(this, ['return 1;']); })";
+var ctor_b_script = "Function.constructor.bind(this, 'return 1;')";
+var ctor_c_script =
+ "(function() { return Function.constructor.call(this, 'return 1;'); })";
+Realm.shared = {
+ ctor_0 : Realm.eval(realms[0], ctor_script),
+ ctor_1 : Realm.eval(realms[1], ctor_script),
+ ctor_a_0 : Realm.eval(realms[0], ctor_a_script),
+ ctor_a_1 : Realm.eval(realms[1], ctor_a_script),
+ ctor_b_0 : Realm.eval(realms[0], ctor_b_script),
+ ctor_b_1 : Realm.eval(realms[1], ctor_b_script),
+ ctor_c_0 : Realm.eval(realms[0], ctor_c_script),
+ ctor_c_1 : Realm.eval(realms[1], ctor_c_script),
+}
+
+var script_0 = " \
+ var ctor_0 = Realm.shared.ctor_0; \
+ Realm.shared.direct_0 = ctor_0('return 1'); \
+ Realm.shared.indirect_0 = (function() { return ctor_0('return 1;'); })(); \
+ Realm.shared.apply_0 = ctor_0.apply(this, ['return 1']); \
+ Realm.shared.bind_0 = ctor_0.bind(this, 'return 1')(); \
+ Realm.shared.call_0 = ctor_0.call(this, 'return 1'); \
+ Realm.shared.a_0 = Realm.shared.ctor_a_0(); \
+ Realm.shared.b_0 = Realm.shared.ctor_b_0(); \
+ Realm.shared.c_0 = Realm.shared.ctor_c_0(); \
+";
+
+script = script_0 + script_0.replace(/_0/g, "_1");
+
+Realm.eval(realms[0], script);
+assertSame(1, Realm.shared.direct_0());
+assertSame(1, Realm.shared.indirect_0());
+assertSame(1, Realm.shared.apply_0());
+assertSame(1, Realm.shared.bind_0());
+assertSame(1, Realm.shared.call_0());
+assertSame(1, Realm.shared.a_0());
+assertSame(1, Realm.shared.b_0());
+assertSame(1, Realm.shared.c_0());
+assertSame(undefined, Realm.shared.direct_1);
+assertSame(undefined, Realm.shared.indirect_1);
+assertSame(undefined, Realm.shared.apply_1);
+assertSame(undefined, Realm.shared.bind_1);
+assertSame(undefined, Realm.shared.call_1);
+assertSame(1, Realm.shared.a_1());
+assertSame(undefined, Realm.shared.b_1);
+assertSame(1, Realm.shared.c_1());
+
+Realm.eval(realms[1], script);
+assertSame(undefined, Realm.shared.direct_0);
+assertSame(undefined, Realm.shared.indirect_0);
+assertSame(undefined, Realm.shared.apply_0);
+assertSame(undefined, Realm.shared.bind_0);
+assertSame(undefined, Realm.shared.call_0);
+assertSame(1, Realm.shared.a_0());
+assertSame(undefined, Realm.shared.b_0);
+assertSame(1, Realm.shared.c_1());
+assertSame(1, Realm.shared.direct_1());
+assertSame(1, Realm.shared.indirect_1());
+assertSame(1, Realm.shared.apply_1());
+assertSame(1, Realm.shared.bind_1());
+assertSame(1, Realm.shared.call_1());
+assertSame(1, Realm.shared.a_1());
+assertSame(1, Realm.shared.b_1());
+assertSame(1, Realm.shared.c_1());
diff --git a/deps/v8/test/mjsunit/debug-break-native.js b/deps/v8/test/mjsunit/debug-break-native.js
new file mode 100644
index 0000000000..11d7274929
--- /dev/null
+++ b/deps/v8/test/mjsunit/debug-break-native.js
@@ -0,0 +1,42 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+Debug = debug.Debug
+var exception = null;
+
+function breakListener(event, exec_state, event_data, data) {
+ if (event != Debug.DebugEvent.Break) return;
+ try {
+ exec_state.prepareStep(Debug.StepAction.StepIn, 1);
+ // Assert that the break happens at an intended location.
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// break") > 0);
+ } catch (e) {
+ exception = e;
+ }
+}
+
+Debug.setListener(breakListener);
+
+debugger; // break
+
+function f(x) {
+ return x; // break
+} // break
+
+Debug.setBreakPoint(f, 0, 0); // break
+Debug.scripts(); // break
+debug.MakeMirror(f); // break
+
+new Error("123").stack; // break
+Math.sin(0); // break
+
+f("this should break"); // break
+
+Debug.setListener(null); // break
+
+f("this should not break");
+
+assertNull(exception);
diff --git a/deps/v8/test/mjsunit/debug-compile-event.js b/deps/v8/test/mjsunit/debug-compile-event.js
index 89a71ddb59..c38cd8477a 100644
--- a/deps/v8/test/mjsunit/debug-compile-event.js
+++ b/deps/v8/test/mjsunit/debug-compile-event.js
@@ -32,6 +32,7 @@ Debug = debug.Debug
var exception = false; // Exception in debug event listener.
var before_compile_count = 0;
var after_compile_count = 0;
+var compile_error_count = 0;
var current_source = ''; // Current source being compiled.
var source_count = 0; // Total number of scources compiled.
var host_compilations = 0; // Number of scources compiled through the API.
@@ -48,11 +49,12 @@ function compileSource(source) {
function listener(event, exec_state, event_data, data) {
try {
if (event == Debug.DebugEvent.BeforeCompile ||
- event == Debug.DebugEvent.AfterCompile) {
+ event == Debug.DebugEvent.AfterCompile ||
+ event == Debug.DebugEvent.CompileError) {
// Count the events.
if (event == Debug.DebugEvent.BeforeCompile) {
before_compile_count++;
- } else {
+ } else if (event == Debug.DebugEvent.AfterCompile) {
after_compile_count++;
switch (event_data.script().compilationType()) {
case Debug.ScriptCompilationType.Host:
@@ -62,6 +64,8 @@ function listener(event, exec_state, event_data, data) {
eval_compilations++;
break;
}
+ } else {
+ compile_error_count++;
}
// If the compiled source contains 'eval' there will be additional compile
@@ -81,9 +85,11 @@ function listener(event, exec_state, event_data, data) {
assertTrue('context' in msg.body.script);
// Check that we pick script name from //# sourceURL, iff present
- assertEquals(current_source.indexOf('sourceURL') >= 0 ?
- 'myscript.js' : undefined,
- event_data.script().name());
+ if (event == Debug.DebugEvent.AfterCompile) {
+ assertEquals(current_source.indexOf('sourceURL') >= 0 ?
+ 'myscript.js' : undefined,
+ event_data.script().name());
+ }
}
} catch (e) {
exception = e
@@ -105,11 +111,17 @@ compileSource('JSON.parse(\'{"a":1,"b":2}\')');
// Using JSON.parse does not causes additional compilation events.
compileSource('x=1; //# sourceURL=myscript.js');
+try {
+ compileSource('}');
+} catch(e) {
+}
+
// Make sure that the debug event listener was invoked.
assertFalse(exception, "exception in listener")
-// Number of before and after compile events should be the same.
-assertEquals(before_compile_count, after_compile_count);
+// Number of before and after + error events should be the same.
+assertEquals(before_compile_count, after_compile_count + compile_error_count);
+assertEquals(compile_error_count, 1);
// Check the actual number of events (no compilation through the API as all
// source compiled through eval).
diff --git a/deps/v8/test/mjsunit/debug-compile-optimized.js b/deps/v8/test/mjsunit/debug-compile-optimized.js
new file mode 100644
index 0000000000..468605abaa
--- /dev/null
+++ b/deps/v8/test/mjsunit/debug-compile-optimized.js
@@ -0,0 +1,18 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax --crankshaft
+
+Debug = debug.Debug;
+
+Debug.setListener(function() {});
+
+function f() {}
+f();
+f();
+%OptimizeFunctionOnNextCall(f);
+f();
+assertOptimized(f);
+
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/debug-is-active.js b/deps/v8/test/mjsunit/debug-is-active.js
new file mode 100644
index 0000000000..19968f0c10
--- /dev/null
+++ b/deps/v8/test/mjsunit/debug-is-active.js
@@ -0,0 +1,28 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+Debug = debug.Debug;
+
+function f() { return %_DebugIsActive() != 0; }
+
+assertFalse(f());
+assertFalse(f());
+Debug.setListener(function() {});
+assertTrue(f());
+Debug.setListener(null);
+assertFalse(f());
+
+%OptimizeFunctionOnNextCall(f);
+assertFalse(f());
+assertOptimized(f);
+
+Debug.setListener(function() {});
+assertTrue(f());
+assertOptimized(f);
+
+Debug.setListener(null);
+assertFalse(f());
+assertOptimized(f);
diff --git a/deps/v8/test/mjsunit/debug-mirror-cache.js b/deps/v8/test/mjsunit/debug-mirror-cache.js
index 07aaf880dc..c690aa0133 100644
--- a/deps/v8/test/mjsunit/debug-mirror-cache.js
+++ b/deps/v8/test/mjsunit/debug-mirror-cache.js
@@ -62,6 +62,9 @@ function listener(event, exec_state, event_data, data) {
json = '{"seq":0,"type":"request","command":"backtrace"}'
dcp.processDebugJSONRequest(json);
+ // Make sure looking up loaded scripts does not clear the cache.
+ Debug.scripts();
+
// Some mirrors where cached.
assertFalse(debug.next_handle_ == 0, "Mirror cache not used");
assertFalse(debug.mirror_cache_.length == 0, "Mirror cache not used");
diff --git a/deps/v8/test/mjsunit/debug-script.js b/deps/v8/test/mjsunit/debug-script.js
index 80d423e10b..5b5e75962f 100644
--- a/deps/v8/test/mjsunit/debug-script.js
+++ b/deps/v8/test/mjsunit/debug-script.js
@@ -59,7 +59,7 @@ for (i = 0; i < scripts.length; i++) {
}
// This has to be updated if the number of native scripts change.
-assertTrue(named_native_count == 19 || named_native_count == 20);
+assertTrue(named_native_count == 25 || named_native_count == 26);
// Only the 'gc' extension is loaded.
assertEquals(1, extension_count);
// This script and mjsunit.js has been loaded. If using d8, d8 loads
diff --git a/deps/v8/test/mjsunit/debug-scripts-request.js b/deps/v8/test/mjsunit/debug-scripts-request.js
index e027563b9b..f9fdde6348 100644
--- a/deps/v8/test/mjsunit/debug-scripts-request.js
+++ b/deps/v8/test/mjsunit/debug-scripts-request.js
@@ -108,3 +108,5 @@ debugger;
assertTrue(listenerComplete,
"listener did not run to completion, exception: " + exception);
assertFalse(exception, "exception in listener")
+
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/debug-stepin-positions.js b/deps/v8/test/mjsunit/debug-stepin-positions.js
index 722df53666..ff532e3dd7 100644
--- a/deps/v8/test/mjsunit/debug-stepin-positions.js
+++ b/deps/v8/test/mjsunit/debug-stepin-positions.js
@@ -37,12 +37,13 @@ function TestCase(fun, frame_number) {
var exception = false;
var codeSnippet = undefined;
var resultPositions = undefined;
+ var step = 0;
function listener(event, exec_state, event_data, data) {
try {
if (event == Debug.DebugEvent.Break ||
event == Debug.DebugEvent.Exception) {
- Debug.setListener(null);
+ if (step++ > 0) return;
assertHasLineMark(/pause/, exec_state.frame(0));
assertHasLineMark(/positions/, exec_state.frame(frame_number));
var frame = exec_state.frame(frame_number);
diff --git a/deps/v8/test/mjsunit/debug-toggle-mirror-cache.js b/deps/v8/test/mjsunit/debug-toggle-mirror-cache.js
new file mode 100644
index 0000000000..a44c11551e
--- /dev/null
+++ b/deps/v8/test/mjsunit/debug-toggle-mirror-cache.js
@@ -0,0 +1,40 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are
+// met:
+//
+// * Redistributions of source code must retain the above copyright
+// notice, this list of conditions and the following disclaimer.
+// * Redistributions in binary form must reproduce the above
+// copyright notice, this list of conditions and the following
+// disclaimer in the documentation and/or other materials provided
+// with the distribution.
+// * Neither the name of Google Inc. nor the names of its
+// contributors may be used to endorse or promote products derived
+// from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+// Flags: --expose-debug-as debug
+
+var handle1 = debug.MakeMirror(123).handle();
+assertEquals("number", debug.LookupMirror(handle1).type());
+
+debug.ToggleMirrorCache(false);
+var handle2 = debug.MakeMirror(123).handle();
+assertEquals(undefined, handle2);
+assertThrows(function() { debug.LookupMirror(handle2) });
+
+debug.ToggleMirrorCache(true);
+var handle3 = debug.MakeMirror(123).handle();
+assertEquals("number", debug.LookupMirror(handle3).type());
diff --git a/deps/v8/test/mjsunit/define-property-gc.js b/deps/v8/test/mjsunit/define-property-gc.js
index 573a7edbdc..b130b164b1 100644
--- a/deps/v8/test/mjsunit/define-property-gc.js
+++ b/deps/v8/test/mjsunit/define-property-gc.js
@@ -26,7 +26,7 @@
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// Tests the handling of GC issues in the defineProperty method.
-// Flags: --max-new-space-size=2
+// Flags: --max-semi-space-size=1
function Regular() {
this[0] = 0;
diff --git a/deps/v8/test/mjsunit/deserialize-reference.js b/deps/v8/test/mjsunit/deserialize-reference.js
new file mode 100644
index 0000000000..b032013159
--- /dev/null
+++ b/deps/v8/test/mjsunit/deserialize-reference.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --cache=code --serialize-toplevel
+
+var a = "123";
+assertEquals(a, "123");
diff --git a/deps/v8/test/mjsunit/dictionary-properties.js b/deps/v8/test/mjsunit/dictionary-properties.js
new file mode 100644
index 0000000000..0659268bac
--- /dev/null
+++ b/deps/v8/test/mjsunit/dictionary-properties.js
@@ -0,0 +1,48 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+// Test loading existent and nonexistent properties from dictionary
+// mode objects.
+
+function SlowObject() {
+ this.foo = 1;
+ this.bar = 2;
+ this.qux = 3;
+ delete this.qux;
+ assertFalse(%HasFastProperties(this));
+}
+function SlowObjectWithBaz() {
+ var o = new SlowObject();
+ o.baz = 4;
+ return o;
+}
+
+function Load(o) {
+ return o.baz;
+}
+
+for (var i = 0; i < 10; i++) {
+ var o1 = new SlowObject();
+ var o2 = SlowObjectWithBaz();
+ assertEquals(undefined, Load(o1));
+ assertEquals(4, Load(o2));
+}
+
+// Test objects getting optimized as fast prototypes.
+
+function SlowPrototype() {
+ this.foo = 1;
+}
+SlowPrototype.prototype.bar = 2;
+SlowPrototype.prototype.baz = 3;
+delete SlowPrototype.prototype.baz;
+new SlowPrototype;
+
+// Prototypes stay fast even after deleting properties.
+assertTrue(%HasFastProperties(SlowPrototype.prototype));
+var fast_proto = new SlowPrototype();
+assertTrue(%HasFastProperties(SlowPrototype.prototype));
+assertTrue(%HasFastProperties(fast_proto.__proto__));
diff --git a/deps/v8/test/mjsunit/elements-kind-depends.js b/deps/v8/test/mjsunit/elements-kind-depends.js
index 82f188b71e..539fbd0e42 100644
--- a/deps/v8/test/mjsunit/elements-kind-depends.js
+++ b/deps/v8/test/mjsunit/elements-kind-depends.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays
+// Flags: --allow-natives-syntax
function burn() {
var a = new Array(3);
diff --git a/deps/v8/test/mjsunit/elements-kind.js b/deps/v8/test/mjsunit/elements-kind.js
index 3aa513a378..64b4a094ff 100644
--- a/deps/v8/test/mjsunit/elements-kind.js
+++ b/deps/v8/test/mjsunit/elements-kind.js
@@ -25,22 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc --nostress-opt --typed-array-max_size_in-heap=2048
-
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
+// Flags: --allow-natives-syntax --expose-gc --nostress-opt --typed-array-max_size_in-heap=2048
var elements_kind = {
fast_smi_only : 'fast smi only elements',
@@ -131,10 +116,6 @@ function getKind(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
@@ -144,13 +125,11 @@ me.dance = 0xD15C0;
me.drink = 0xC0C0A;
assertKind(elements_kind.fast, me);
-if (support_smi_only_arrays) {
- var too = [1,2,3];
- assertKind(elements_kind.fast_smi_only, too);
- too.dance = 0xD15C0;
- too.drink = 0xC0C0A;
- assertKind(elements_kind.fast_smi_only, too);
-}
+var too = [1,2,3];
+assertKind(elements_kind.fast_smi_only, too);
+too.dance = 0xD15C0;
+too.drink = 0xC0C0A;
+assertKind(elements_kind.fast_smi_only, too);
// Make sure the element kind transitions from smi when a non-smi is stored.
function test_wrapper() {
@@ -166,7 +145,9 @@ function test_wrapper() {
}
assertKind(elements_kind.fast, you);
- assertKind(elements_kind.dictionary, new Array(0xDECAF));
+ var temp = [];
+ temp[0xDECAF] = 0;
+ assertKind(elements_kind.dictionary, temp);
var fast_double_array = new Array(0xDECAF);
for (var i = 0; i < 0xDECAF; i++) fast_double_array[i] = i / 2;
@@ -217,111 +198,106 @@ function test_wrapper() {
test_wrapper();
%ClearFunctionTypeFeedback(test_wrapper);
-if (support_smi_only_arrays) {
- %NeverOptimizeFunction(construct_smis);
+%NeverOptimizeFunction(construct_smis);
- // This code exists to eliminate the learning influence of AllocationSites
- // on the following tests.
- var __sequence = 0;
- function make_array_string() {
- this.__sequence = this.__sequence + 1;
- return "/* " + this.__sequence + " */ [0, 0, 0];"
- }
- function make_array() {
- return eval(make_array_string());
- }
+// This code exists to eliminate the learning influence of AllocationSites
+// on the following tests.
+var __sequence = 0;
+function make_array_string() {
+ this.__sequence = this.__sequence + 1;
+ return "/* " + this.__sequence + " */ [0, 0, 0];"
+}
+function make_array() {
+ return eval(make_array_string());
+}
- function construct_smis() {
- var a = make_array();
- a[0] = 0; // Send the COW array map to the steak house.
- assertKind(elements_kind.fast_smi_only, a);
- return a;
- }
+function construct_smis() {
+ var a = make_array();
+ a[0] = 0; // Send the COW array map to the steak house.
+ assertKind(elements_kind.fast_smi_only, a);
+ return a;
+}
%NeverOptimizeFunction(construct_doubles);
- function construct_doubles() {
- var a = construct_smis();
- a[0] = 1.5;
- assertKind(elements_kind.fast_double, a);
- return a;
- }
+function construct_doubles() {
+ var a = construct_smis();
+ a[0] = 1.5;
+ assertKind(elements_kind.fast_double, a);
+ return a;
+}
%NeverOptimizeFunction(construct_objects);
- function construct_objects() {
- var a = construct_smis();
- a[0] = "one";
- assertKind(elements_kind.fast, a);
- return a;
- }
+function construct_objects() {
+ var a = construct_smis();
+ a[0] = "one";
+ assertKind(elements_kind.fast, a);
+ return a;
+}
- // Test crankshafted transition SMI->DOUBLE.
+// Test crankshafted transition SMI->DOUBLE.
%NeverOptimizeFunction(convert_to_double);
- function convert_to_double(array) {
- array[1] = 2.5;
- assertKind(elements_kind.fast_double, array);
- assertEquals(2.5, array[1]);
- }
- var smis = construct_smis();
- for (var i = 0; i < 3; i++) convert_to_double(smis);
+function convert_to_double(array) {
+ array[1] = 2.5;
+ assertKind(elements_kind.fast_double, array);
+ assertEquals(2.5, array[1]);
+}
+var smis = construct_smis();
+for (var i = 0; i < 3; i++) convert_to_double(smis);
%OptimizeFunctionOnNextCall(convert_to_double);
- smis = construct_smis();
- convert_to_double(smis);
- // Test crankshafted transitions SMI->FAST and DOUBLE->FAST.
+smis = construct_smis();
+convert_to_double(smis);
+// Test crankshafted transitions SMI->FAST and DOUBLE->FAST.
%NeverOptimizeFunction(convert_to_fast);
- function convert_to_fast(array) {
- array[1] = "two";
- assertKind(elements_kind.fast, array);
- assertEquals("two", array[1]);
- }
- smis = construct_smis();
- for (var i = 0; i < 3; i++) convert_to_fast(smis);
- var doubles = construct_doubles();
- for (var i = 0; i < 3; i++) convert_to_fast(doubles);
- smis = construct_smis();
- doubles = construct_doubles();
+function convert_to_fast(array) {
+ array[1] = "two";
+ assertKind(elements_kind.fast, array);
+ assertEquals("two", array[1]);
+}
+smis = construct_smis();
+for (var i = 0; i < 3; i++) convert_to_fast(smis);
+var doubles = construct_doubles();
+for (var i = 0; i < 3; i++) convert_to_fast(doubles);
+smis = construct_smis();
+doubles = construct_doubles();
%OptimizeFunctionOnNextCall(convert_to_fast);
- convert_to_fast(smis);
- convert_to_fast(doubles);
- // Test transition chain SMI->DOUBLE->FAST (crankshafted function will
- // transition to FAST directly).
+convert_to_fast(smis);
+convert_to_fast(doubles);
+// Test transition chain SMI->DOUBLE->FAST (crankshafted function will
+// transition to FAST directly).
%NeverOptimizeFunction(convert_mixed);
- function convert_mixed(array, value, kind) {
- array[1] = value;
- assertKind(kind, array);
- assertEquals(value, array[1]);
- }
- smis = construct_smis();
- for (var i = 0; i < 3; i++) {
- convert_mixed(smis, 1.5, elements_kind.fast_double);
- }
- doubles = construct_doubles();
- for (var i = 0; i < 3; i++) {
- convert_mixed(doubles, "three", elements_kind.fast);
- }
- convert_mixed(construct_smis(), "three", elements_kind.fast);
- convert_mixed(construct_doubles(), "three", elements_kind.fast);
- %OptimizeFunctionOnNextCall(convert_mixed);
- smis = construct_smis();
- doubles = construct_doubles();
- convert_mixed(smis, 1, elements_kind.fast);
- convert_mixed(doubles, 1, elements_kind.fast);
- assertTrue(%HaveSameMap(smis, doubles));
+function convert_mixed(array, value, kind) {
+ array[1] = value;
+ assertKind(kind, array);
+ assertEquals(value, array[1]);
+}
+smis = construct_smis();
+for (var i = 0; i < 3; i++) {
+ convert_mixed(smis, 1.5, elements_kind.fast_double);
}
+doubles = construct_doubles();
+for (var i = 0; i < 3; i++) {
+ convert_mixed(doubles, "three", elements_kind.fast);
+}
+convert_mixed(construct_smis(), "three", elements_kind.fast);
+convert_mixed(construct_doubles(), "three", elements_kind.fast);
+ %OptimizeFunctionOnNextCall(convert_mixed);
+smis = construct_smis();
+doubles = construct_doubles();
+convert_mixed(smis, 1, elements_kind.fast);
+convert_mixed(doubles, 1, elements_kind.fast);
+assertTrue(%HaveSameMap(smis, doubles));
// Crankshaft support for smi-only elements in dynamic array literals.
function get(foo) { return foo; } // Used to generate dynamic values.
function crankshaft_test() {
- if (support_smi_only_arrays) {
- var a1 = [get(1), get(2), get(3)];
- assertKind(elements_kind.fast_smi_only, a1);
- }
+ var a1 = [get(1), get(2), get(3)];
+ assertKind(elements_kind.fast_smi_only, a1);
+
var a2 = new Array(get(1), get(2), get(3));
assertKind(elements_kind.fast_smi_only, a2);
var b = [get(1), get(2), get("three")];
assertKind(elements_kind.fast, b);
var c = [get(1), get(2), get(3.5)];
- if (support_smi_only_arrays) {
- assertKind(elements_kind.fast_double, c);
- }
+ assertKind(elements_kind.fast_double, c);
}
for (var i = 0; i < 3; i++) {
crankshaft_test();
@@ -335,85 +311,76 @@ crankshaft_test();
// DOUBLE->OBJECT, and SMI->OBJECT. No matter in which order these three are
// created, they must always end up with the same FAST map.
-// This test is meaningless without FAST_SMI_ONLY_ELEMENTS.
-if (support_smi_only_arrays) {
- // Preparation: create one pair of identical objects for each case.
- var a = [1, 2, 3];
- var b = [1, 2, 3];
- assertTrue(%HaveSameMap(a, b));
- assertKind(elements_kind.fast_smi_only, a);
- var c = [1, 2, 3];
- c["case2"] = true;
- var d = [1, 2, 3];
- d["case2"] = true;
- assertTrue(%HaveSameMap(c, d));
- assertFalse(%HaveSameMap(a, c));
- assertKind(elements_kind.fast_smi_only, c);
- var e = [1, 2, 3];
- e["case3"] = true;
- var f = [1, 2, 3];
- f["case3"] = true;
- assertTrue(%HaveSameMap(e, f));
- assertFalse(%HaveSameMap(a, e));
- assertFalse(%HaveSameMap(c, e));
- assertKind(elements_kind.fast_smi_only, e);
- // Case 1: SMI->DOUBLE, DOUBLE->OBJECT, SMI->OBJECT.
- a[0] = 1.5;
- assertKind(elements_kind.fast_double, a);
- a[0] = "foo";
- assertKind(elements_kind.fast, a);
- b[0] = "bar";
- assertTrue(%HaveSameMap(a, b));
- // Case 2: SMI->DOUBLE, SMI->OBJECT, DOUBLE->OBJECT.
- c[0] = 1.5;
- assertKind(elements_kind.fast_double, c);
- assertFalse(%HaveSameMap(c, d));
- d[0] = "foo";
- assertKind(elements_kind.fast, d);
- assertFalse(%HaveSameMap(c, d));
- c[0] = "bar";
- assertTrue(%HaveSameMap(c, d));
- // Case 3: SMI->OBJECT, SMI->DOUBLE, DOUBLE->OBJECT.
- e[0] = "foo";
- assertKind(elements_kind.fast, e);
- assertFalse(%HaveSameMap(e, f));
- f[0] = 1.5;
- assertKind(elements_kind.fast_double, f);
- assertFalse(%HaveSameMap(e, f));
- f[0] = "bar";
- assertKind(elements_kind.fast, f);
- assertTrue(%HaveSameMap(e, f));
-}
+// Preparation: create one pair of identical objects for each case.
+var a = [1, 2, 3];
+var b = [1, 2, 3];
+assertTrue(%HaveSameMap(a, b));
+assertKind(elements_kind.fast_smi_only, a);
+var c = [1, 2, 3];
+c["case2"] = true;
+var d = [1, 2, 3];
+d["case2"] = true;
+assertTrue(%HaveSameMap(c, d));
+assertFalse(%HaveSameMap(a, c));
+assertKind(elements_kind.fast_smi_only, c);
+var e = [1, 2, 3];
+e["case3"] = true;
+var f = [1, 2, 3];
+f["case3"] = true;
+assertTrue(%HaveSameMap(e, f));
+assertFalse(%HaveSameMap(a, e));
+assertFalse(%HaveSameMap(c, e));
+assertKind(elements_kind.fast_smi_only, e);
+// Case 1: SMI->DOUBLE, DOUBLE->OBJECT, SMI->OBJECT.
+a[0] = 1.5;
+assertKind(elements_kind.fast_double, a);
+a[0] = "foo";
+assertKind(elements_kind.fast, a);
+b[0] = "bar";
+assertTrue(%HaveSameMap(a, b));
+// Case 2: SMI->DOUBLE, SMI->OBJECT, DOUBLE->OBJECT.
+c[0] = 1.5;
+assertKind(elements_kind.fast_double, c);
+assertFalse(%HaveSameMap(c, d));
+d[0] = "foo";
+assertKind(elements_kind.fast, d);
+assertFalse(%HaveSameMap(c, d));
+c[0] = "bar";
+assertTrue(%HaveSameMap(c, d));
+// Case 3: SMI->OBJECT, SMI->DOUBLE, DOUBLE->OBJECT.
+e[0] = "foo";
+assertKind(elements_kind.fast, e);
+assertFalse(%HaveSameMap(e, f));
+f[0] = 1.5;
+assertKind(elements_kind.fast_double, f);
+assertFalse(%HaveSameMap(e, f));
+f[0] = "bar";
+assertKind(elements_kind.fast, f);
+assertTrue(%HaveSameMap(e, f));
// Test if Array.concat() works correctly with DOUBLE elements.
-if (support_smi_only_arrays) {
- var a = [1, 2];
- assertKind(elements_kind.fast_smi_only, a);
- var b = [4.5, 5.5];
- assertKind(elements_kind.fast_double, b);
- var c = a.concat(b);
- assertEquals([1, 2, 4.5, 5.5], c);
- assertKind(elements_kind.fast_double, c);
-}
+var a = [1, 2];
+assertKind(elements_kind.fast_smi_only, a);
+var b = [4.5, 5.5];
+assertKind(elements_kind.fast_double, b);
+var c = a.concat(b);
+assertEquals([1, 2, 4.5, 5.5], c);
+assertKind(elements_kind.fast_double, c);
// Test that Array.push() correctly handles SMI elements.
-if (support_smi_only_arrays) {
- var a = [1, 2];
- assertKind(elements_kind.fast_smi_only, a);
- a.push(3, 4, 5);
- assertKind(elements_kind.fast_smi_only, a);
- assertEquals([1, 2, 3, 4, 5], a);
-}
+var a = [1, 2];
+assertKind(elements_kind.fast_smi_only, a);
+a.push(3, 4, 5);
+assertKind(elements_kind.fast_smi_only, a);
+assertEquals([1, 2, 3, 4, 5], a);
// Test that Array.splice() and Array.slice() return correct ElementsKinds.
-if (support_smi_only_arrays) {
- var a = ["foo", "bar"];
- assertKind(elements_kind.fast, a);
- var b = a.splice(0, 1);
- assertKind(elements_kind.fast, b);
- var c = a.slice(0, 1);
- assertKind(elements_kind.fast, c);
-}
+var a = ["foo", "bar"];
+assertKind(elements_kind.fast, a);
+var b = a.splice(0, 1);
+assertKind(elements_kind.fast, b);
+var c = a.slice(0, 1);
+assertKind(elements_kind.fast, c);
// Throw away type information in the ICs for next stress run.
gc();
diff --git a/deps/v8/test/mjsunit/elements-transition-hoisting.js b/deps/v8/test/mjsunit/elements-transition-hoisting.js
index 76027b9ed1..9f229d2e17 100644
--- a/deps/v8/test/mjsunit/elements-transition-hoisting.js
+++ b/deps/v8/test/mjsunit/elements-transition-hoisting.js
@@ -25,21 +25,13 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays
+// Flags: --allow-natives-syntax
// Flags: --nostress-opt
// Ensure that ElementsKind transitions in various situations are hoisted (or
// not hoisted) correctly, don't change the semantics programs and don't trigger
// deopt through hoisting in important situations.
-support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6));
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
function test_wrapper() {
// Make sure that a simple elements array transitions inside a loop before
// stores to an array gets hoisted in a way that doesn't generate a deopt in
@@ -238,9 +230,7 @@ function test_wrapper() {
%ClearFunctionTypeFeedback(testStraightLineDupeElinination);
}
-if (support_smi_only_arrays) {
- // The test is called in a test wrapper that has type feedback cleared to
- // prevent the influence of allocation-sites, which learn from transitions.
- test_wrapper();
- %ClearFunctionTypeFeedback(test_wrapper);
-}
+// The test is called in a test wrapper that has type feedback cleared to
+// prevent the influence of allocation-sites, which learn from transitions.
+test_wrapper();
+%ClearFunctionTypeFeedback(test_wrapper);
diff --git a/deps/v8/test/mjsunit/elements-transition.js b/deps/v8/test/mjsunit/elements-transition.js
index 7298e68a12..f6a8188e2f 100644
--- a/deps/v8/test/mjsunit/elements-transition.js
+++ b/deps/v8/test/mjsunit/elements-transition.js
@@ -25,107 +25,95 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays
+// Flags: --allow-natives-syntax
// Flags: --nostress-opt
-support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
+// This code exists to eliminate the learning influence of AllocationSites
+// on the following tests.
+var __sequence = 0;
+function make_array_string(length) {
+ this.__sequence = this.__sequence + 1;
+ return "/* " + this.__sequence + " */ new Array(" + length + ");";
+}
+function make_array(length) {
+ return eval(make_array_string(length));
}
-if (support_smi_only_arrays) {
- // This code exists to eliminate the learning influence of AllocationSites
- // on the following tests.
- var __sequence = 0;
- function make_array_string(length) {
- this.__sequence = this.__sequence + 1;
- return "/* " + this.__sequence + " */ new Array(" + length + ");";
- }
- function make_array(length) {
- return eval(make_array_string(length));
- }
-
- function test(test_double, test_object, set, length) {
- // We apply the same operations to two identical arrays. The first array
- // triggers an IC miss, upon which the conversion stub is generated, but the
- // actual conversion is done in runtime. The second array, arriving at
- // the previously patched IC, is then converted using the conversion stub.
- var array_1 = make_array(length);
- var array_2 = make_array(length);
+function test(test_double, test_object, set, length) {
+ // We apply the same operations to two identical arrays. The first array
+ // triggers an IC miss, upon which the conversion stub is generated, but the
+ // actual conversion is done in runtime. The second array, arriving at
+ // the previously patched IC, is then converted using the conversion stub.
+ var array_1 = make_array(length);
+ var array_2 = make_array(length);
- // false, true, nice setter function, 20
- assertTrue(%HasFastSmiElements(array_1));
- assertTrue(%HasFastSmiElements(array_2));
- for (var i = 0; i < length; i++) {
- if (i == length - 5 && test_double) {
- // Trigger conversion to fast double elements at length-5.
- set(array_1, i, 0.5);
- set(array_2, i, 0.5);
- assertTrue(%HasFastDoubleElements(array_1));
- assertTrue(%HasFastDoubleElements(array_2));
- } else if (i == length - 3 && test_object) {
- // Trigger conversion to fast object elements at length-3.
- set(array_1, i, 'object');
- set(array_2, i, 'object');
- assertTrue(%HasFastObjectElements(array_1));
- assertTrue(%HasFastObjectElements(array_2));
- } else if (i != length - 7) {
- // Set the element to an integer but leave a hole at length-7.
- set(array_1, i, 2*i+1);
- set(array_2, i, 2*i+1);
- }
+ // false, true, nice setter function, 20
+ assertTrue(%HasFastSmiElements(array_1));
+ assertTrue(%HasFastSmiElements(array_2));
+ for (var i = 0; i < length; i++) {
+ if (i == length - 5 && test_double) {
+ // Trigger conversion to fast double elements at length-5.
+ set(array_1, i, 0.5);
+ set(array_2, i, 0.5);
+ assertTrue(%HasFastDoubleElements(array_1));
+ assertTrue(%HasFastDoubleElements(array_2));
+ } else if (i == length - 3 && test_object) {
+ // Trigger conversion to fast object elements at length-3.
+ set(array_1, i, 'object');
+ set(array_2, i, 'object');
+ assertTrue(%HasFastObjectElements(array_1));
+ assertTrue(%HasFastObjectElements(array_2));
+ } else if (i != length - 7) {
+ // Set the element to an integer but leave a hole at length-7.
+ set(array_1, i, 2*i+1);
+ set(array_2, i, 2*i+1);
}
+ }
- for (var i = 0; i < length; i++) {
- if (i == length - 5 && test_double) {
- assertEquals(0.5, array_1[i]);
- assertEquals(0.5, array_2[i]);
- } else if (i == length - 3 && test_object) {
- assertEquals('object', array_1[i]);
- assertEquals('object', array_2[i]);
- } else if (i != length - 7) {
- assertEquals(2*i+1, array_1[i]);
- assertEquals(2*i+1, array_2[i]);
- } else {
- assertEquals(undefined, array_1[i]);
- assertEquals(undefined, array_2[i]);
- }
+ for (var i = 0; i < length; i++) {
+ if (i == length - 5 && test_double) {
+ assertEquals(0.5, array_1[i]);
+ assertEquals(0.5, array_2[i]);
+ } else if (i == length - 3 && test_object) {
+ assertEquals('object', array_1[i]);
+ assertEquals('object', array_2[i]);
+ } else if (i != length - 7) {
+ assertEquals(2*i+1, array_1[i]);
+ assertEquals(2*i+1, array_2[i]);
+ } else {
+ assertEquals(undefined, array_1[i]);
+ assertEquals(undefined, array_2[i]);
}
-
- assertEquals(length, array_1.length);
- assertEquals(length, array_2.length);
}
- function run_test(test_double, test_object, set, length) {
- test(test_double, test_object, set, length);
+ assertEquals(length, array_1.length);
+ assertEquals(length, array_2.length);
+}
+
+function run_test(test_double, test_object, set, length) {
+ test(test_double, test_object, set, length);
%ClearFunctionTypeFeedback(test);
- }
+}
- run_test(false, false, function(a,i,v){ a[i] = v; }, 20);
- run_test(true, false, function(a,i,v){ a[i] = v; }, 20);
- run_test(false, true, function(a,i,v){ a[i] = v; }, 20);
- run_test(true, true, function(a,i,v){ a[i] = v; }, 20);
+run_test(false, false, function(a,i,v){ a[i] = v; }, 20);
+run_test(true, false, function(a,i,v){ a[i] = v; }, 20);
+run_test(false, true, function(a,i,v){ a[i] = v; }, 20);
+run_test(true, true, function(a,i,v){ a[i] = v; }, 20);
- run_test(false, false, function(a,i,v){ a[i] = v; }, 10000);
- run_test(true, false, function(a,i,v){ a[i] = v; }, 10000);
- run_test(false, true, function(a,i,v){ a[i] = v; }, 10000);
- run_test(true, true, function(a,i,v){ a[i] = v; }, 10000);
+run_test(false, false, function(a,i,v){ a[i] = v; }, 10000);
+run_test(true, false, function(a,i,v){ a[i] = v; }, 10000);
+run_test(false, true, function(a,i,v){ a[i] = v; }, 10000);
+run_test(true, true, function(a,i,v){ a[i] = v; }, 10000);
- // Check COW arrays
- function get_cow() { return [1, 2, 3]; }
+// Check COW arrays
+function get_cow() { return [1, 2, 3]; }
- function transition(x) { x[0] = 1.5; }
+function transition(x) { x[0] = 1.5; }
- var ignore = get_cow();
- transition(ignore); // Handled by runtime.
- var a = get_cow();
- var b = get_cow();
- transition(a); // Handled by IC.
- assertEquals(1.5, a[0]);
- assertEquals(1, b[0]);
-} else {
- print("Test skipped because smi only arrays are not supported.");
-}
+var ignore = get_cow();
+transition(ignore); // Handled by runtime.
+var a = get_cow();
+var b = get_cow();
+transition(a); // Handled by IC.
+assertEquals(1.5, a[0]);
+assertEquals(1, b[0]);
diff --git a/deps/v8/test/mjsunit/error-tostring-omit.js b/deps/v8/test/mjsunit/error-tostring-omit.js
index 111adfc212..9ff43fa9b2 100644
--- a/deps/v8/test/mjsunit/error-tostring-omit.js
+++ b/deps/v8/test/mjsunit/error-tostring-omit.js
@@ -37,23 +37,15 @@ function veryLongString() {
"Nam accumsan dignissim turpis a turpis duis.";
}
+assertTrue(veryLongString().length > 256);
-var re = /omitted/;
+var re = /...<omitted>.../;
try {
- veryLongString.nonexistentMethod();
+ Number.prototype.toFixed.call(veryLongString);
} catch (e) {
- assertTrue(e.message.length < 350);
- // TODO(verwaest): Proper error message.
- // assertTrue(re.test(e.message));
-}
-
-try {
- veryLongString().nonexistentMethod();
-} catch (e) {
- assertTrue(e.message.length < 350);
- // TODO(verwaest): Proper error message.
- // assertTrue(re.test(e.message));
+ assertTrue(e.message.length < 256);
+ assertTrue(re.test(e.message));
}
try {
diff --git a/deps/v8/test/mjsunit/harmony/array-iterator.js b/deps/v8/test/mjsunit/es6/array-iterator.js
index 6a402e7393..63a7415b96 100644
--- a/deps/v8/test/mjsunit/harmony/array-iterator.js
+++ b/deps/v8/test/mjsunit/es6/array-iterator.js
@@ -25,23 +25,40 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-iteration --allow-natives-syntax
+// Flags: --allow-natives-syntax
+
+
+var NONE = 0;
+var READ_ONLY = 1;
+var DONT_ENUM = 2;
+var DONT_DELETE = 4;
+
+
+function assertHasOwnProperty(object, name, attrs) {
+ assertTrue(object.hasOwnProperty(name));
+ var desc = Object.getOwnPropertyDescriptor(object, name);
+ assertEquals(desc.writable, !(attrs & READ_ONLY));
+ assertEquals(desc.enumerable, !(attrs & DONT_ENUM));
+ assertEquals(desc.configurable, !(attrs & DONT_DELETE));
+}
+
function TestArrayPrototype() {
- assertTrue(Array.prototype.hasOwnProperty('entries'));
- assertTrue(Array.prototype.hasOwnProperty('values'));
- assertTrue(Array.prototype.hasOwnProperty('keys'));
+ assertHasOwnProperty(Array.prototype, 'entries', DONT_ENUM);
+ assertHasOwnProperty(Array.prototype, 'values', DONT_ENUM);
+ assertHasOwnProperty(Array.prototype, 'keys', DONT_ENUM);
+ assertHasOwnProperty(Array.prototype, Symbol.iterator, DONT_ENUM);
- assertFalse(Array.prototype.propertyIsEnumerable('entries'));
- assertFalse(Array.prototype.propertyIsEnumerable('values'));
- assertFalse(Array.prototype.propertyIsEnumerable('keys'));
+ assertEquals(Array.prototype.values, Array.prototype[Symbol.iterator]);
}
TestArrayPrototype();
+
function assertIteratorResult(value, done, result) {
assertEquals({value: value, done: done}, result);
}
+
function TestValues() {
var array = ['a', 'b', 'c'];
var iterator = array.values();
@@ -55,6 +72,7 @@ function TestValues() {
}
TestValues();
+
function TestValuesMutate() {
var array = ['a', 'b', 'c'];
var iterator = array.values();
@@ -67,6 +85,7 @@ function TestValuesMutate() {
}
TestValuesMutate();
+
function TestKeys() {
var array = ['a', 'b', 'c'];
var iterator = array.keys();
@@ -80,6 +99,7 @@ function TestKeys() {
}
TestKeys();
+
function TestKeysMutate() {
var array = ['a', 'b', 'c'];
var iterator = array.keys();
@@ -92,6 +112,7 @@ function TestKeysMutate() {
}
TestKeysMutate();
+
function TestEntries() {
var array = ['a', 'b', 'c'];
var iterator = array.entries();
@@ -105,6 +126,7 @@ function TestEntries() {
}
TestEntries();
+
function TestEntriesMutate() {
var array = ['a', 'b', 'c'];
var iterator = array.entries();
@@ -117,29 +139,32 @@ function TestEntriesMutate() {
}
TestEntriesMutate();
+
function TestArrayIteratorPrototype() {
var array = [];
var iterator = array.values();
- var ArrayIterator = iterator.constructor;
- assertEquals(ArrayIterator.prototype, array.values().__proto__);
- assertEquals(ArrayIterator.prototype, array.keys().__proto__);
- assertEquals(ArrayIterator.prototype, array.entries().__proto__);
+ var ArrayIteratorPrototype = iterator.__proto__;
+
+ assertEquals(ArrayIteratorPrototype, array.values().__proto__);
+ assertEquals(ArrayIteratorPrototype, array.keys().__proto__);
+ assertEquals(ArrayIteratorPrototype, array.entries().__proto__);
- assertEquals(Object.prototype, ArrayIterator.prototype.__proto__);
+ assertEquals(Object.prototype, ArrayIteratorPrototype.__proto__);
assertEquals('Array Iterator', %_ClassOf(array.values()));
assertEquals('Array Iterator', %_ClassOf(array.keys()));
assertEquals('Array Iterator', %_ClassOf(array.entries()));
- var prototypeDescriptor =
- Object.getOwnPropertyDescriptor(ArrayIterator, 'prototype');
- assertFalse(prototypeDescriptor.configurable);
- assertFalse(prototypeDescriptor.enumerable);
- assertFalse(prototypeDescriptor.writable);
+ assertFalse(ArrayIteratorPrototype.hasOwnProperty('constructor'));
+ assertArrayEquals(['next'],
+ Object.getOwnPropertyNames(ArrayIteratorPrototype));
+ assertHasOwnProperty(ArrayIteratorPrototype, 'next', DONT_ENUM);
+ assertHasOwnProperty(ArrayIteratorPrototype, Symbol.iterator, DONT_ENUM);
}
TestArrayIteratorPrototype();
+
function TestForArrayValues() {
var buffer = [];
var array = [0, 'a', true, false, null, /* hole */, undefined, NaN];
@@ -151,12 +176,13 @@ function TestForArrayValues() {
assertEquals(8, buffer.length);
for (var i = 0; i < buffer.length - 1; i++) {
- assertEquals(array[i], buffer[i]);
+ assertSame(array[i], buffer[i]);
}
assertTrue(isNaN(buffer[buffer.length - 1]));
}
TestForArrayValues();
+
function TestForArrayKeys() {
var buffer = [];
var array = [0, 'a', true, false, null, /* hole */, undefined, NaN];
@@ -173,6 +199,7 @@ function TestForArrayKeys() {
}
TestForArrayKeys();
+
function TestForArrayEntries() {
var buffer = [];
var array = [0, 'a', true, false, null, /* hole */, undefined, NaN];
@@ -184,7 +211,7 @@ function TestForArrayEntries() {
assertEquals(8, buffer.length);
for (var i = 0; i < buffer.length - 1; i++) {
- assertEquals(array[i], buffer[i][1]);
+ assertSame(array[i], buffer[i][1]);
}
assertTrue(isNaN(buffer[buffer.length - 1][1]));
@@ -193,3 +220,33 @@ function TestForArrayEntries() {
}
}
TestForArrayEntries();
+
+
+function TestForArray() {
+ var buffer = [];
+ var array = [0, 'a', true, false, null, /* hole */, undefined, NaN];
+ var i = 0;
+ for (var value of array) {
+ buffer[i++] = value;
+ }
+
+ assertEquals(8, buffer.length);
+
+ for (var i = 0; i < buffer.length - 1; i++) {
+ assertSame(array[i], buffer[i]);
+ }
+ assertTrue(isNaN(buffer[buffer.length - 1]));
+}
+TestForArrayValues();
+
+
+function TestNonOwnSlots() {
+ var array = [0];
+ var iterator = array.values();
+ var object = {__proto__: iterator};
+
+ assertThrows(function() {
+ object.next();
+ }, TypeError);
+}
+TestNonOwnSlots();
diff --git a/deps/v8/test/mjsunit/es6/collection-iterator.js b/deps/v8/test/mjsunit/es6/collection-iterator.js
new file mode 100644
index 0000000000..5503fe58c0
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/collection-iterator.js
@@ -0,0 +1,200 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+
+(function TestSetIterator() {
+ var s = new Set;
+ var iter = s.values();
+ assertEquals('Set Iterator', %_ClassOf(iter));
+
+ var SetIteratorPrototype = iter.__proto__;
+ assertFalse(SetIteratorPrototype.hasOwnProperty('constructor'));
+ assertEquals(SetIteratorPrototype.__proto__, Object.prototype);
+
+ var propertyNames = Object.getOwnPropertyNames(SetIteratorPrototype);
+ assertArrayEquals(['next'], propertyNames);
+
+ assertEquals(new Set().values().__proto__, SetIteratorPrototype);
+ assertEquals(new Set().entries().__proto__, SetIteratorPrototype);
+})();
+
+
+(function TestSetIteratorValues() {
+ var s = new Set;
+ s.add(1);
+ s.add(2);
+ s.add(3);
+ var iter = s.values();
+
+ assertEquals({value: 1, done: false}, iter.next());
+ assertEquals({value: 2, done: false}, iter.next());
+ assertEquals({value: 3, done: false}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+})();
+
+
+(function TestSetIteratorKeys() {
+ assertEquals(Set.prototype.keys, Set.prototype.values);
+})();
+
+
+(function TestSetIteratorEntries() {
+ var s = new Set;
+ s.add(1);
+ s.add(2);
+ s.add(3);
+ var iter = s.entries();
+
+ assertEquals({value: [1, 1], done: false}, iter.next());
+ assertEquals({value: [2, 2], done: false}, iter.next());
+ assertEquals({value: [3, 3], done: false}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+})();
+
+
+(function TestSetIteratorMutations() {
+ var s = new Set;
+ s.add(1);
+ var iter = s.values();
+ assertEquals({value: 1, done: false}, iter.next());
+ s.add(2);
+ s.add(3);
+ s.add(4);
+ s.add(5);
+ assertEquals({value: 2, done: false}, iter.next());
+ s.delete(3);
+ assertEquals({value: 4, done: false}, iter.next());
+ s.delete(5);
+ assertEquals({value: undefined, done: true}, iter.next());
+ s.add(4);
+ assertEquals({value: undefined, done: true}, iter.next());
+})();
+
+
+(function TestSetInvalidReceiver() {
+ assertThrows(function() {
+ Set.prototype.values.call({});
+ }, TypeError);
+ assertThrows(function() {
+ Set.prototype.entries.call({});
+ }, TypeError);
+})();
+
+
+(function TestSetIteratorInvalidReceiver() {
+ var iter = new Set().values();
+ assertThrows(function() {
+ iter.next.call({});
+ });
+})();
+
+
+(function TestSetIteratorSymbol() {
+ assertEquals(Set.prototype[Symbol.iterator], Set.prototype.values);
+ assertTrue(Set.prototype.hasOwnProperty(Symbol.iterator));
+ assertFalse(Set.prototype.propertyIsEnumerable(Symbol.iterator));
+
+ var iter = new Set().values();
+ assertEquals(iter, iter[Symbol.iterator]());
+ assertEquals(iter[Symbol.iterator].name, '[Symbol.iterator]');
+})();
+
+
+(function TestMapIterator() {
+ var m = new Map;
+ var iter = m.values();
+ assertEquals('Map Iterator', %_ClassOf(iter));
+
+ var MapIteratorPrototype = iter.__proto__;
+ assertFalse(MapIteratorPrototype.hasOwnProperty('constructor'));
+ assertEquals(MapIteratorPrototype.__proto__, Object.prototype);
+
+ var propertyNames = Object.getOwnPropertyNames(MapIteratorPrototype);
+ assertArrayEquals(['next'], propertyNames);
+
+ assertEquals(new Map().values().__proto__, MapIteratorPrototype);
+ assertEquals(new Map().keys().__proto__, MapIteratorPrototype);
+ assertEquals(new Map().entries().__proto__, MapIteratorPrototype);
+})();
+
+
+(function TestMapIteratorValues() {
+ var m = new Map;
+ m.set(1, 11);
+ m.set(2, 22);
+ m.set(3, 33);
+ var iter = m.values();
+
+ assertEquals({value: 11, done: false}, iter.next());
+ assertEquals({value: 22, done: false}, iter.next());
+ assertEquals({value: 33, done: false}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+})();
+
+
+(function TestMapIteratorKeys() {
+ var m = new Map;
+ m.set(1, 11);
+ m.set(2, 22);
+ m.set(3, 33);
+ var iter = m.keys();
+
+ assertEquals({value: 1, done: false}, iter.next());
+ assertEquals({value: 2, done: false}, iter.next());
+ assertEquals({value: 3, done: false}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+})();
+
+
+(function TestMapIteratorEntries() {
+ var m = new Map;
+ m.set(1, 11);
+ m.set(2, 22);
+ m.set(3, 33);
+ var iter = m.entries();
+
+ assertEquals({value: [1, 11], done: false}, iter.next());
+ assertEquals({value: [2, 22], done: false}, iter.next());
+ assertEquals({value: [3, 33], done: false}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+ assertEquals({value: undefined, done: true}, iter.next());
+})();
+
+
+(function TestMapInvalidReceiver() {
+ assertThrows(function() {
+ Map.prototype.values.call({});
+ }, TypeError);
+ assertThrows(function() {
+ Map.prototype.keys.call({});
+ }, TypeError);
+ assertThrows(function() {
+ Map.prototype.entries.call({});
+ }, TypeError);
+})();
+
+
+(function TestMapIteratorInvalidReceiver() {
+ var iter = new Map().values();
+ assertThrows(function() {
+ iter.next.call({});
+ }, TypeError);
+})();
+
+
+(function TestMapIteratorSymbol() {
+ assertEquals(Map.prototype[Symbol.iterator], Map.prototype.entries);
+ assertTrue(Map.prototype.hasOwnProperty(Symbol.iterator));
+ assertFalse(Map.prototype.propertyIsEnumerable(Symbol.iterator));
+
+ var iter = new Map().values();
+ assertEquals(iter, iter[Symbol.iterator]());
+ assertEquals(iter[Symbol.iterator].name, '[Symbol.iterator]');
+})();
diff --git a/deps/v8/test/mjsunit/harmony/collections.js b/deps/v8/test/mjsunit/es6/collections.js
index 7bf7bf7063..1e2f232ee8 100644
--- a/deps/v8/test/mjsunit/harmony/collections.js
+++ b/deps/v8/test/mjsunit/es6/collections.js
@@ -25,10 +25,16 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-collections
// Flags: --expose-gc --allow-natives-syntax
+function assertSize(expected, collection) {
+ if (collection instanceof Map || collection instanceof Set) {
+ assertEquals(expected, collection.size);
+ }
+}
+
+
// Test valid getter and setter calls on Sets and WeakSets
function TestValidSetCalls(m) {
assertDoesNotThrow(function () { m.add(new Object) });
@@ -67,7 +73,7 @@ TestInvalidCalls(new WeakMap);
// Test expected behavior for Sets and WeakSets
function TestSet(set, key) {
assertFalse(set.has(key));
- assertSame(undefined, set.add(key));
+ assertSame(set, set.add(key));
assertTrue(set.has(key));
assertTrue(set.delete(key));
assertFalse(set.has(key));
@@ -92,7 +98,7 @@ TestSet(new WeakSet, new Object);
// Test expected mapping behavior for Maps and WeakMaps
function TestMapping(map, key, value) {
- assertSame(undefined, map.set(key, value));
+ assertSame(map, map.set(key, value));
assertSame(value, map.get(key));
}
function TestMapBehavior1(m) {
@@ -290,20 +296,19 @@ assertEquals("WeakSet", WeakSet.name);
// Test prototype property of Set, Map, WeakMap and WeakSet.
-// TODO(2793): Should all be non-writable, and the extra flag removed.
-function TestPrototype(C, writable) {
+function TestPrototype(C) {
assertTrue(C.prototype instanceof Object);
assertEquals({
value: {},
- writable: writable,
+ writable: false,
enumerable: false,
configurable: false
}, Object.getOwnPropertyDescriptor(C, "prototype"));
}
-TestPrototype(Set, true);
-TestPrototype(Map, true);
-TestPrototype(WeakMap, false);
-TestPrototype(WeakSet, false);
+TestPrototype(Set);
+TestPrototype(Map);
+TestPrototype(WeakMap);
+TestPrototype(WeakSet);
// Test constructor property of the Set, Map, WeakMap and WeakSet prototype.
@@ -311,6 +316,7 @@ function TestConstructor(C) {
assertFalse(C === Object.prototype.constructor);
assertSame(C, C.prototype.constructor);
assertSame(C, (new C).__proto__.constructor);
+ assertEquals(1, C.length);
}
TestConstructor(Set);
TestConstructor(Map);
@@ -852,3 +858,431 @@ for (var i = 9; i >= 0; i--) {
});
assertEquals(4950, accumulated);
})();
+
+
+(function TestMapForEachAllRemovedTransition() {
+ var map = new Map;
+ map.set(0, 0);
+
+ var buffer = [];
+ map.forEach(function(v) {
+ buffer.push(v);
+ if (v === 0) {
+ for (var i = 1; i < 4; i++) {
+ map.set(i, i);
+ }
+ }
+
+ if (v === 3) {
+ for (var i = 0; i < 4; i++) {
+ map.delete(i);
+ }
+ for (var i = 4; i < 8; i++) {
+ map.set(i, i);
+ }
+ }
+ });
+
+ assertArrayEquals([0, 1, 2, 3, 4, 5, 6, 7], buffer);
+})();
+
+
+(function TestMapForEachClearTransition() {
+ var map = new Map;
+ map.set(0, 0);
+
+ var i = 0;
+ var buffer = [];
+ map.forEach(function(v) {
+ buffer.push(v);
+ if (++i < 5) {
+ for (var j = 0; j < 5; j++) {
+ map.clear();
+ map.set(i, i);
+ }
+ }
+ });
+
+ assertArrayEquals([0, 1, 2, 3, 4], buffer);
+})();
+
+
+(function TestMapForEachNestedNonTrivialTransition() {
+ var map = new Map;
+ map.set(0, 0);
+ map.set(1, 1);
+ map.set(2, 2);
+ map.set(3, 3);
+ map.delete(0);
+
+ var i = 0;
+ var buffer = [];
+ map.forEach(function(v) {
+ if (++i > 10) return;
+
+ buffer.push(v);
+
+ if (v == 3) {
+ map.delete(1);
+ for (var j = 4; j < 10; j++) {
+ map.set(j, j);
+ }
+ for (var j = 4; j < 10; j += 2) {
+ map.delete(j);
+ }
+ map.delete(2);
+
+ for (var j = 10; j < 20; j++) {
+ map.set(j, j);
+ }
+ for (var j = 10; j < 20; j += 2) {
+ map.delete(j);
+ }
+
+ map.delete(3);
+ }
+ });
+
+ assertArrayEquals([1, 2, 3, 5, 7, 9, 11, 13, 15, 17], buffer);
+})();
+
+
+(function TestMapForEachAllRemovedTransitionNoClear() {
+ var map = new Map;
+ map.set(0, 0);
+
+ var buffer = [];
+ map.forEach(function(v) {
+ buffer.push(v);
+ if (v === 0) {
+ for (var i = 1; i < 8; i++) {
+ map.set(i, i);
+ }
+ }
+
+ if (v === 4) {
+ for (var i = 0; i < 8; i++) {
+ map.delete(i);
+ }
+ }
+ });
+
+ assertArrayEquals([0, 1, 2, 3, 4], buffer);
+})();
+
+
+(function TestMapForEachNoMoreElementsAfterTransition() {
+ var map = new Map;
+ map.set(0, 0);
+
+ var buffer = [];
+ map.forEach(function(v) {
+ buffer.push(v);
+ if (v === 0) {
+ for (var i = 1; i < 16; i++) {
+ map.set(i, i);
+ }
+ }
+
+ if (v === 4) {
+ for (var i = 5; i < 16; i++) {
+ map.delete(i);
+ }
+ }
+ });
+
+ assertArrayEquals([0, 1, 2, 3, 4], buffer);
+})();
+
+
+// Allows testing iterator-based constructors easily.
+var oneAndTwo = new Map();
+var k0 = {key: 0};
+var k1 = {key: 1};
+var k2 = {key: 2};
+oneAndTwo.set(k1, 1);
+oneAndTwo.set(k2, 2);
+
+
+function TestSetConstructor(ctor) {
+ var s = new ctor(null);
+ assertSize(0, s);
+
+ s = new ctor(undefined);
+ assertSize(0, s);
+
+ // No @@iterator
+ assertThrows(function() {
+ new ctor({});
+ }, TypeError);
+
+ // @@iterator not callable
+ assertThrows(function() {
+ var object = {};
+ object[Symbol.iterator] = 42;
+ new ctor(object);
+ }, TypeError);
+
+ // @@iterator result not object
+ assertThrows(function() {
+ var object = {};
+ object[Symbol.iterator] = function() {
+ return 42;
+ };
+ new ctor(object);
+ }, TypeError);
+
+ var s2 = new Set();
+ s2.add(k0);
+ s2.add(k1);
+ s2.add(k2);
+ s = new ctor(s2.values());
+ assertSize(3, s);
+ assertTrue(s.has(k0));
+ assertTrue(s.has(k1));
+ assertTrue(s.has(k2));
+}
+TestSetConstructor(Set);
+TestSetConstructor(WeakSet);
+
+
+function TestSetConstructorAddNotCallable(ctor) {
+ var originalPrototypeAdd = ctor.prototype.add;
+ assertThrows(function() {
+ ctor.prototype.add = 42;
+ new ctor(oneAndTwo.values());
+ }, TypeError);
+ ctor.prototype.add = originalPrototypeAdd;
+}
+TestSetConstructorAddNotCallable(Set);
+TestSetConstructorAddNotCallable(WeakSet);
+
+
+function TestSetConstructorGetAddOnce(ctor) {
+ var originalPrototypeAdd = ctor.prototype.add;
+ var getAddCount = 0;
+ Object.defineProperty(ctor.prototype, 'add', {
+ get: function() {
+ getAddCount++;
+ return function() {};
+ }
+ });
+ var s = new ctor(oneAndTwo.values());
+ assertEquals(1, getAddCount);
+ assertSize(0, s);
+ Object.defineProperty(ctor.prototype, 'add', {
+ value: originalPrototypeAdd,
+ writable: true
+ });
+}
+TestSetConstructorGetAddOnce(Set);
+TestSetConstructorGetAddOnce(WeakSet);
+
+
+function TestSetConstructorAddReplaced(ctor) {
+ var originalPrototypeAdd = ctor.prototype.add;
+ var addCount = 0;
+ ctor.prototype.add = function(value) {
+ addCount++;
+ originalPrototypeAdd.call(this, value);
+ ctor.prototype.add = null;
+ };
+ var s = new ctor(oneAndTwo.keys());
+ assertEquals(2, addCount);
+ assertSize(2, s);
+ ctor.prototype.add = originalPrototypeAdd;
+}
+TestSetConstructorAddReplaced(Set);
+TestSetConstructorAddReplaced(WeakSet);
+
+
+function TestSetConstructorOrderOfDoneValue(ctor) {
+ var valueCount = 0, doneCount = 0;
+ var iterator = {
+ next: function() {
+ return {
+ get value() {
+ valueCount++;
+ },
+ get done() {
+ doneCount++;
+ throw new Error();
+ }
+ };
+ }
+ };
+ iterator[Symbol.iterator] = function() {
+ return this;
+ };
+ assertThrows(function() {
+ new ctor(iterator);
+ });
+ assertEquals(1, doneCount);
+ assertEquals(0, valueCount);
+}
+TestSetConstructorOrderOfDoneValue(Set);
+TestSetConstructorOrderOfDoneValue(WeakSet);
+
+
+function TestSetConstructorNextNotAnObject(ctor) {
+ var iterator = {
+ next: function() {
+ return 'abc';
+ }
+ };
+ iterator[Symbol.iterator] = function() {
+ return this;
+ };
+ assertThrows(function() {
+ new ctor(iterator);
+ }, TypeError);
+}
+TestSetConstructorNextNotAnObject(Set);
+TestSetConstructorNextNotAnObject(WeakSet);
+
+
+function TestMapConstructor(ctor) {
+ var m = new ctor(null);
+ assertSize(0, m);
+
+ m = new ctor(undefined);
+ assertSize(0, m);
+
+ // No @@iterator
+ assertThrows(function() {
+ new ctor({});
+ }, TypeError);
+
+ // @@iterator not callable
+ assertThrows(function() {
+ var object = {};
+ object[Symbol.iterator] = 42;
+ new ctor(object);
+ }, TypeError);
+
+ // @@iterator result not object
+ assertThrows(function() {
+ var object = {};
+ object[Symbol.iterator] = function() {
+ return 42;
+ };
+ new ctor(object);
+ }, TypeError);
+
+ var m2 = new Map();
+ m2.set(k0, 'a');
+ m2.set(k1, 'b');
+ m2.set(k2, 'c');
+ m = new ctor(m2.entries());
+ assertSize(3, m);
+ assertEquals('a', m.get(k0));
+ assertEquals('b', m.get(k1));
+ assertEquals('c', m.get(k2));
+}
+TestMapConstructor(Map);
+TestMapConstructor(WeakMap);
+
+
+function TestMapConstructorSetNotCallable(ctor) {
+ var originalPrototypeSet = ctor.prototype.set;
+ assertThrows(function() {
+ ctor.prototype.set = 42;
+ new ctor(oneAndTwo.entries());
+ }, TypeError);
+ ctor.prototype.set = originalPrototypeSet;
+}
+TestMapConstructorSetNotCallable(Map);
+TestMapConstructorSetNotCallable(WeakMap);
+
+
+function TestMapConstructorGetAddOnce(ctor) {
+ var originalPrototypeSet = ctor.prototype.set;
+ var getSetCount = 0;
+ Object.defineProperty(ctor.prototype, 'set', {
+ get: function() {
+ getSetCount++;
+ return function() {};
+ }
+ });
+ var m = new ctor(oneAndTwo.entries());
+ assertEquals(1, getSetCount);
+ assertSize(0, m);
+ Object.defineProperty(ctor.prototype, 'set', {
+ value: originalPrototypeSet,
+ writable: true
+ });
+}
+TestMapConstructorGetAddOnce(Map);
+TestMapConstructorGetAddOnce(WeakMap);
+
+
+function TestMapConstructorSetReplaced(ctor) {
+ var originalPrototypeSet = ctor.prototype.set;
+ var setCount = 0;
+ ctor.prototype.set = function(key, value) {
+ setCount++;
+ originalPrototypeSet.call(this, key, value);
+ ctor.prototype.set = null;
+ };
+ var m = new ctor(oneAndTwo.entries());
+ assertEquals(2, setCount);
+ assertSize(2, m);
+ ctor.prototype.set = originalPrototypeSet;
+}
+TestMapConstructorSetReplaced(Map);
+TestMapConstructorSetReplaced(WeakMap);
+
+
+function TestMapConstructorOrderOfDoneValue(ctor) {
+ var valueCount = 0, doneCount = 0;
+ function FakeError() {}
+ var iterator = {
+ next: function() {
+ return {
+ get value() {
+ valueCount++;
+ },
+ get done() {
+ doneCount++;
+ throw new FakeError();
+ }
+ };
+ }
+ };
+ iterator[Symbol.iterator] = function() {
+ return this;
+ };
+ assertThrows(function() {
+ new ctor(iterator);
+ }, FakeError);
+ assertEquals(1, doneCount);
+ assertEquals(0, valueCount);
+}
+TestMapConstructorOrderOfDoneValue(Map);
+TestMapConstructorOrderOfDoneValue(WeakMap);
+
+
+function TestMapConstructorNextNotAnObject(ctor) {
+ var iterator = {
+ next: function() {
+ return 'abc';
+ }
+ };
+ iterator[Symbol.iterator] = function() {
+ return this;
+ };
+ assertThrows(function() {
+ new ctor(iterator);
+ }, TypeError);
+}
+TestMapConstructorNextNotAnObject(Map);
+TestMapConstructorNextNotAnObject(WeakMap);
+
+
+function TestMapConstructorIteratorNotObjectValues(ctor) {
+ assertThrows(function() {
+ new ctor(oneAndTwo.values());
+ }, TypeError);
+}
+TestMapConstructorIteratorNotObjectValues(Map);
+TestMapConstructorIteratorNotObjectValues(WeakMap);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-throw-in-reject.js b/deps/v8/test/mjsunit/es6/debug-promises-throw-in-reject.js
deleted file mode 100644
index cdf759606c..0000000000
--- a/deps/v8/test/mjsunit/es6/debug-promises-throw-in-reject.js
+++ /dev/null
@@ -1,61 +0,0 @@
-// Copyright 2014 the V8 project authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Flags: --harmony-promises --expose-debug-as debug
-
-// Test debug events when an exception is thrown inside a Promise, which is
-// caught by a custom promise, which throws a new exception in its reject
-// handler. We expect an Exception debug event with a promise to be triggered.
-
-Debug = debug.Debug;
-
-var log = [];
-var step = 0;
-
-var p = new Promise(function(resolve, reject) {
- log.push("resolve");
- resolve();
-});
-
-function MyPromise(resolver) {
- var reject = function() {
- log.push("throw reject");
- throw new Error("reject"); // event
- };
- var resolve = function() { };
- log.push("construct");
- resolver(resolve, reject);
-};
-
-MyPromise.prototype = p;
-p.constructor = MyPromise;
-
-var q = p.chain(
- function() {
- log.push("throw caught");
- throw new Error("caught");
- });
-
-function listener(event, exec_state, event_data, data) {
- try {
- if (event == Debug.DebugEvent.Exception) {
- assertEquals(["resolve", "construct", "end main",
- "throw caught", "throw reject"], log);
- assertEquals("reject", event_data.exception().message);
- assertEquals(q, event_data.promise());
- assertTrue(exec_state.frame(0).sourceLineText().indexOf('// event') > 0);
- }
- } catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
- }
-}
-
-Debug.setBreakOnUncaughtException();
-Debug.setListener(listener);
-
-log.push("end main");
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-undefined-reject.js b/deps/v8/test/mjsunit/es6/debug-promises-undefined-reject.js
deleted file mode 100644
index 5bad5bd370..0000000000
--- a/deps/v8/test/mjsunit/es6/debug-promises-undefined-reject.js
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright 2014 the V8 project authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Flags: --harmony-promises --expose-debug-as debug
-
-// Test debug events when an exception is thrown inside a Promise, which is
-// caught by a custom promise, which has no reject handler.
-// We expect an Exception event with a promise to be triggered.
-
-Debug = debug.Debug;
-
-var log = [];
-var step = 0;
-
-var p = new Promise(function(resolve, reject) {
- log.push("resolve");
- resolve();
-});
-
-function MyPromise(resolver) {
- var reject = undefined;
- var resolve = function() { };
- log.push("construct");
- resolver(resolve, reject);
-};
-
-MyPromise.prototype = p;
-p.constructor = MyPromise;
-
-var q = p.chain(
- function() {
- log.push("throw caught");
- throw new Error("caught"); // event
- });
-
-function listener(event, exec_state, event_data, data) {
- try {
- if (event == Debug.DebugEvent.Exception) {
- assertEquals(["resolve", "construct", "end main", "throw caught"], log);
- assertEquals("undefined is not a function",
- event_data.exception().message);
- assertEquals(q, event_data.promise());
- }
- } catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
- }
-}
-
-Debug.setBreakOnUncaughtException();
-Debug.setListener(listener);
-
-log.push("end main");
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/async-task-event.js b/deps/v8/test/mjsunit/es6/debug-promises/async-task-event.js
new file mode 100644
index 0000000000..88030a2e73
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/async-task-event.js
@@ -0,0 +1,61 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+Debug = debug.Debug;
+
+var base_id = -1;
+var exception = null;
+var expected = [
+ "enqueue #1",
+ "willHandle #1",
+ "then #1",
+ "enqueue #2",
+ "didHandle #1",
+ "willHandle #2",
+ "then #2",
+ "enqueue #3",
+ "didHandle #2",
+ "willHandle #3",
+ "didHandle #3"
+];
+
+function assertLog(msg) {
+ print(msg);
+ assertTrue(expected.length > 0);
+ assertEquals(expected.shift(), msg);
+ if (!expected.length) {
+ Debug.setListener(null);
+ }
+}
+
+function listener(event, exec_state, event_data, data) {
+ if (event != Debug.DebugEvent.AsyncTaskEvent) return;
+ try {
+ if (base_id < 0)
+ base_id = event_data.id();
+ var id = event_data.id() - base_id + 1;
+ assertEquals("Promise.resolve", event_data.name());
+ assertLog(event_data.type() + " #" + id);
+ } catch (e) {
+ print(e + e.stack)
+ exception = e;
+ }
+}
+
+Debug.setListener(listener);
+
+var resolver;
+var p = new Promise(function(resolve, reject) {
+ resolver = resolve;
+});
+p.then(function() {
+ assertLog("then #1");
+}).then(function() {
+ assertLog("then #2");
+});
+resolver();
+
+assertNull(exception);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/events.js b/deps/v8/test/mjsunit/es6/debug-promises/events.js
new file mode 100644
index 0000000000..a9f94543f4
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/events.js
@@ -0,0 +1,124 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --expose-debug-as debug
+
+Debug = debug.Debug;
+
+var eventsExpected = 16;
+var exception = null;
+var result = [];
+
+function updatePromise(promise, parentPromise, status, value) {
+ var i;
+ for (i = 0; i < result.length; ++i) {
+ if (result[i].promise === promise) {
+ result[i].parentPromise = parentPromise || result[i].parentPromise;
+ result[i].status = status || result[i].status;
+ result[i].value = value || result[i].value;
+ break;
+ }
+ }
+ assertTrue(i < result.length);
+}
+
+function listener(event, exec_state, event_data, data) {
+ if (event != Debug.DebugEvent.PromiseEvent) return;
+ try {
+ eventsExpected--;
+ assertTrue(event_data.promise().isPromise());
+ if (event_data.status() === 0) {
+ // New promise.
+ assertEquals("pending", event_data.promise().status());
+ result.push({ promise: event_data.promise().value(), status: 0 });
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ } else if (event_data.status() !== undefined) {
+ // Resolve/reject promise.
+ updatePromise(event_data.promise().value(),
+ undefined,
+ event_data.status(),
+ event_data.value().value());
+ } else {
+ // Chain promises.
+ assertTrue(event_data.parentPromise().isPromise());
+ updatePromise(event_data.promise().value(),
+ event_data.parentPromise().value());
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ }
+ } catch (e) {
+ print(e + e.stack)
+ exception = e;
+ }
+}
+
+Debug.setListener(listener);
+
+function resolver(resolve, reject) { resolve(); }
+
+var p1 = new Promise(resolver); // event
+var p2 = p1.then().then(); // event
+var p3 = new Promise(function(resolve, reject) { // event
+ reject("rejected");
+});
+var p4 = p3.then(); // event
+var p5 = p1.then(); // event
+
+function assertAsync(b, s) {
+ if (b) {
+ print(s, "succeeded");
+ } else {
+ %AbortJS(s + " FAILED!");
+ }
+}
+
+function testDone(iteration) {
+ function checkResult() {
+ if (eventsExpected === 0) {
+ assertAsync(result.length === 6, "result.length");
+
+ assertAsync(result[0].promise === p1, "result[0].promise");
+ assertAsync(result[0].parentPromise === undefined,
+ "result[0].parentPromise");
+ assertAsync(result[0].status === 1, "result[0].status");
+ assertAsync(result[0].value === undefined, "result[0].value");
+
+ assertAsync(result[1].parentPromise === p1,
+ "result[1].parentPromise");
+ assertAsync(result[1].status === 1, "result[1].status");
+
+ assertAsync(result[2].promise === p2, "result[2].promise");
+
+ assertAsync(result[3].promise === p3, "result[3].promise");
+ assertAsync(result[3].parentPromise === undefined,
+ "result[3].parentPromise");
+ assertAsync(result[3].status === -1, "result[3].status");
+ assertAsync(result[3].value === "rejected", "result[3].value");
+
+ assertAsync(result[4].promise === p4, "result[4].promise");
+ assertAsync(result[4].parentPromise === p3,
+ "result[4].parentPromise");
+ assertAsync(result[4].status === -1, "result[4].status");
+ assertAsync(result[4].value === "rejected", "result[4].value");
+
+ assertAsync(result[5].promise === p5, "result[5].promise");
+ assertAsync(result[5].parentPromise === p1,
+ "result[5].parentPromise");
+ assertAsync(result[5].status === 1, "result[5].status");
+
+ assertAsync(exception === null, "exception === null");
+ Debug.setListener(null);
+ } else if (iteration > 10) {
+ %AbortJS("Not all events were received!");
+ } else {
+ testDone(iteration + 1);
+ }
+ }
+
+ var iteration = iteration || 0;
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone();
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-reentry.js b/deps/v8/test/mjsunit/es6/debug-promises/reentry.js
index 03c7fc2c86..fbe54242dd 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-reentry.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reentry.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug
// Test reentry of special try catch for Promises.
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-after-resolve.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-after-resolve.js
new file mode 100644
index 0000000000..a0036cfd0f
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-after-resolve.js
@@ -0,0 +1,37 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we listen to uncaught exceptions and
+// the Promise is rejected in a chained closure after it has been resolved.
+// We expect no Exception debug event to be triggered.
+
+Debug = debug.Debug;
+
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve(reject);
+});
+
+var q = p.chain(
+ function(value) {
+ assertEquals(["resolve", "end main"], log);
+ value(new Error("reject"));
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ assertTrue(event != Debug.DebugEvent.Exception);
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnException();
+Debug.setListener(listener);
+
+log.push("end main");
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-all.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-all.js
new file mode 100644
index 0000000000..0fca57730a
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-all.js
@@ -0,0 +1,72 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we listen to all exceptions and
+// there is a catch handler for the to-be-rejected Promise.
+// We expect a normal Exception debug event to be triggered.
+
+Debug = debug.Debug;
+
+var log = [];
+var expected_events = 1;
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+var q = p.chain(
+ function(value) {
+ log.push("reject");
+ return Promise.reject(new Error("reject"));
+ });
+
+q.catch(
+ function(e) {
+ assertEquals("reject", e.message);
+ });
+
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("reject", event_data.exception().message);
+ assertSame(q, event_data.promise());
+ assertFalse(event_data.uncaught());
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "end main", "reject"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-late.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-late.js
new file mode 100644
index 0000000000..2ff13d5605
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-late.js
@@ -0,0 +1,34 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we only listen to uncaught exceptions, the Promise
+// is rejected, and a catch handler is installed right before the rejection.
+// We expect no debug event to be triggered.
+
+Debug = debug.Debug;
+
+var p = new Promise(function(resolve, reject) {
+ resolve();
+});
+
+var q = p.chain(
+ function() {
+ q.catch(function(e) {
+ assertEquals("caught", e.message);
+ });
+ return Promise.reject(Error("caught"));
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ assertTrue(event != Debug.DebugEvent.Exception);
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-uncaught.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-uncaught.js
new file mode 100644
index 0000000000..d3fd9f3ae7
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-caught-uncaught.js
@@ -0,0 +1,36 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we only listen to uncaught exceptions and
+// there is a catch handler for the to-be-rejected Promise.
+// We expect no debug event to be triggered.
+
+Debug = debug.Debug;
+
+var p = new Promise(function(resolve, reject) {
+ resolve();
+});
+
+var q = p.chain(
+ function() {
+ return Promise.reject(Error("caught reject"));
+ });
+
+q.catch(
+ function(e) {
+ assertEquals("caught reject", e.message);
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ assertTrue(event != Debug.DebugEvent.Exception);
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-in-constructor.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-in-constructor.js
new file mode 100644
index 0000000000..a05b3ac5d6
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-in-constructor.js
@@ -0,0 +1,39 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+// Test debug events when we only listen to uncaught exceptions and
+// the Promise is rejected in the Promise constructor.
+// We expect an Exception debug event with a promise to be triggered.
+
+Debug = debug.Debug;
+
+var steps = 0;
+var exception = null;
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ steps++;
+ assertEquals("uncaught", event_data.exception().message);
+ assertTrue(event_data.promise() instanceof Promise);
+ assertTrue(event_data.uncaught());
+ // Assert that the debug event is triggered at the throw site.
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ }
+ } catch (e) {
+ exception = e;
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+var p = new Promise(function(resolve, reject) {
+ reject(new Error("uncaught")); // event
+});
+
+assertEquals(1, steps);
+assertNull(exception);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-all.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-all.js
new file mode 100644
index 0000000000..beaf1878fe
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-all.js
@@ -0,0 +1,69 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we listen to all exceptions and
+// there is a catch handler for the to-be-rejected Promise.
+// We expect an Exception debug event with a promise to be triggered.
+
+Debug = debug.Debug;
+
+var expected_events = 1;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+var q = p.chain(
+ function() {
+ log.push("reject");
+ return Promise.reject(new Error("uncaught reject"));
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("uncaught reject", event_data.exception().message);
+ assertTrue(event_data.promise() instanceof Promise);
+ assertSame(q, event_data.promise());
+ assertTrue(event_data.uncaught());
+ // All of the frames on the stack are from native Javascript.
+ assertEquals(0, exec_state.frameCount());
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "end main", "reject"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-late.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-late.js
new file mode 100644
index 0000000000..4a883da13a
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-late.js
@@ -0,0 +1,76 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we only listen to uncaught exceptions and
+// there is a catch handler for the to-be-rejected Promise.
+// We expect an Exception debug event with a promise to be triggered.
+
+Debug = debug.Debug;
+
+var expected_events = 1;
+var log = [];
+
+var reject_closure;
+
+var p = new Promise(function(resolve, reject) {
+ log.push("postpone p");
+ reject_closure = reject;
+});
+
+var q = new Promise(function(resolve, reject) {
+ log.push("resolve q");
+ resolve();
+});
+
+q.then(function() {
+ log.push("reject p");
+ reject_closure(new Error("uncaught reject p")); // event
+})
+
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("uncaught reject p", event_data.exception().message);
+ assertTrue(event_data.promise() instanceof Promise);
+ assertSame(p, event_data.promise());
+ assertTrue(event_data.uncaught());
+ // Assert that the debug event is triggered at the throw site.
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["postpone p", "resolve q", "end main", "reject p"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-uncaught.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-uncaught.js
new file mode 100644
index 0000000000..86e2a815e7
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-uncaught-uncaught.js
@@ -0,0 +1,69 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when we only listen to uncaught exceptions and
+// there is no catch handler for the to-be-rejected Promise.
+// We expect an Exception debug event with a promise to be triggered.
+
+Debug = debug.Debug;
+
+var expected_events = 1;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+var q = p.chain(
+ function() {
+ log.push("reject");
+ return Promise.reject(Error("uncaught reject")); // event
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("uncaught reject", event_data.exception().message);
+ assertTrue(event_data.promise() instanceof Promise);
+ assertSame(q, event_data.promise());
+ assertTrue(event_data.uncaught());
+ // All of the frames on the stack are from native Javascript.
+ assertEquals(0, exec_state.frameCount());
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "end main", "reject"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-with-invalid-reject.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-with-invalid-reject.js
new file mode 100644
index 0000000000..fc6233da8d
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-with-invalid-reject.js
@@ -0,0 +1,77 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when a Promise is rejected, which is caught by a custom
+// promise, which has a number for reject closure. We expect an Exception debug
+// events trying to call the invalid reject closure.
+
+Debug = debug.Debug;
+
+var expected_events = 1;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+function MyPromise(resolver) {
+ var reject = 1;
+ var resolve = function() { };
+ log.push("construct");
+ resolver(resolve, reject);
+};
+
+MyPromise.prototype = new Promise(function() {});
+p.constructor = MyPromise;
+
+var q = p.chain(
+ function() {
+ log.push("reject caught");
+ return Promise.reject(new Error("caught"));
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("number is not a function", event_data.exception().message);
+ // All of the frames on the stack are from native Javascript.
+ assertEquals(0, exec_state.frameCount());
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "construct", "end main", "reject caught"],
+ log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
+
+log.push("end main");
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-with-throw-in-reject.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-with-throw-in-reject.js
new file mode 100644
index 0000000000..15e464ec60
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-with-throw-in-reject.js
@@ -0,0 +1,87 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when a Promise is rejected, which is caught by a
+// custom promise, which throws a new exception in its reject handler.
+// We expect two Exception debug events:
+// 1) when promise q is rejected.
+// 2) when the custom reject closure in MyPromise throws an exception.
+
+Debug = debug.Debug;
+
+var expected_events = 1;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+function MyPromise(resolver) {
+ var reject = function() {
+ log.push("throw in reject");
+ throw new Error("reject"); // event
+ };
+ var resolve = function() { };
+ log.push("construct");
+ resolver(resolve, reject);
+};
+
+MyPromise.prototype = new Promise(function() {});
+p.constructor = MyPromise;
+
+var q = p.chain(
+ function() {
+ log.push("reject caught");
+ return Promise.reject(new Error("caught"));
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("reject", event_data.exception().message);
+ // Assert that the debug event is triggered at the throw site.
+ assertTrue(
+ exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ }
+ } catch (e) {
+ // Signal a failure with exit code 1. This is necessary since the
+ // debugger swallows exceptions and we expect the chained function
+ // and this listener to be executed after the main script is finished.
+ print("Unexpected exception: " + e + "\n" + e.stack);
+ quit(1);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "construct", "end main",
+ "reject caught", "throw in reject"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/reject-with-undefined-reject.js b/deps/v8/test/mjsunit/es6/debug-promises/reject-with-undefined-reject.js
new file mode 100644
index 0000000000..d11c01ff73
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/reject-with-undefined-reject.js
@@ -0,0 +1,77 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when a Promise is rejected, which is caught by a custom
+// promise, which has undefined for reject closure. We expect an Exception
+// debug even calling the (undefined) custom rejected closure.
+
+Debug = debug.Debug;
+
+var expected_events = 1;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+function MyPromise(resolver) {
+ var reject = undefined;
+ var resolve = function() { };
+ log.push("construct");
+ resolver(resolve, reject);
+};
+
+MyPromise.prototype = new Promise(function() {});
+p.constructor = MyPromise;
+
+var q = p.chain(
+ function() {
+ log.push("reject caught");
+ return Promise.reject(new Error("caught"));
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ assertEquals("caught", event_data.exception().message);
+ // All of the frames on the stack are from native Javascript.
+ assertEquals(0, exec_state.frameCount());
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "construct", "end main", "reject caught"],
+ log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
+
+log.push("end main");
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-caught-all.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-caught-all.js
index 5189373e18..2fbf05141d 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-caught-all.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-caught-all.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug --allow-natives-syntax
// Test debug events when we listen to all exceptions and
// there is a catch handler for the exception thrown in a Promise.
@@ -10,8 +10,8 @@
Debug = debug.Debug;
+var expected_events = 1;
var log = [];
-var step = 0;
var p = new Promise(function(resolve, reject) {
log.push("resolve");
@@ -31,21 +31,15 @@ q.catch(
function listener(event, exec_state, event_data, data) {
try {
- // Ignore exceptions during startup in stress runs.
- if (step >= 1) return;
- assertEquals(["resolve", "end main", "throw"], log);
if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
assertEquals("caught", event_data.exception().message);
- assertEquals(undefined, event_data.promise());
+ assertSame(q, event_data.promise());
assertFalse(event_data.uncaught());
- step++;
}
} catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
+ %AbortJS(e + "\n" + e.stack);
}
}
@@ -53,3 +47,25 @@ Debug.setBreakOnException();
Debug.setListener(listener);
log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "end main", "throw"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-caught-late.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-caught-late.js
index 66e073d4a3..ac79aba769 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-caught-late.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-caught-late.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug --allow-natives-syntax
// Test debug events when we only listen to uncaught exceptions, the Promise
// throws, and a catch handler is installed right before throwing.
@@ -26,11 +26,7 @@ function listener(event, exec_state, event_data, data) {
try {
assertTrue(event != Debug.DebugEvent.Exception);
} catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
+ %AbortJS(e + "\n" + e.stack);
}
}
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-caught-uncaught.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-caught-uncaught.js
index 9620d31bdd..0ad9ce48a2 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-caught-uncaught.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-caught-uncaught.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug --allow-natives-syntax
// Test debug events when we only listen to uncaught exceptions and
// there is a catch handler for the exception thrown in a Promise.
@@ -16,23 +16,19 @@ var p = new Promise(function(resolve, reject) {
var q = p.chain(
function() {
- throw new Error("caught");
+ throw new Error("caught throw");
});
q.catch(
function(e) {
- assertEquals("caught", e.message);
+ assertEquals("caught throw", e.message);
});
function listener(event, exec_state, event_data, data) {
try {
assertTrue(event != Debug.DebugEvent.Exception);
} catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
+ %AbortJS(e + "\n" + e.stack);
}
}
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-throw-in-constructor.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-in-constructor.js
index d0267cefb5..fd6b4dd348 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-throw-in-constructor.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-in-constructor.js
@@ -2,10 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug
// Test debug events when we only listen to uncaught exceptions and
-// an exception is thrown in the the Promise constructor.
+// an exception is thrown in the Promise constructor.
// We expect an Exception debug event with a promise to be triggered.
Debug = debug.Debug;
@@ -15,8 +15,6 @@ var exception = null;
function listener(event, exec_state, event_data, data) {
try {
- // Ignore exceptions during startup in stress runs.
- if (step >= 1) return;
if (event == Debug.DebugEvent.Exception) {
assertEquals(0, step);
assertEquals("uncaught", event_data.exception().message);
@@ -27,10 +25,6 @@ function listener(event, exec_state, event_data, data) {
step++;
}
} catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
exception = e;
}
}
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-uncaught-all.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-uncaught-all.js
index 714e7da9c5..72f800bf5b 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-uncaught-all.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-uncaught-all.js
@@ -2,17 +2,16 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug --allow-natives-syntax
// Test debug events when we listen to all exceptions and
-// there is a catch handler for the exception thrown in a Promise.
+// there is no catch handler for the exception thrown in a Promise.
// We expect an Exception debug event with a promise to be triggered.
Debug = debug.Debug;
+var expected_events = 1;
var log = [];
-var step = 0;
-var exception = undefined;
var p = new Promise(function(resolve, reject) {
log.push("resolve");
@@ -28,24 +27,18 @@ var q = p.chain(
function listener(event, exec_state, event_data, data) {
try {
// Ignore exceptions during startup in stress runs.
- if (step >= 1) return;
- assertEquals(["resolve", "end main", "throw"], log);
if (event == Debug.DebugEvent.Exception) {
- assertEquals(0, step);
+ expected_events--;
+ assertTrue(expected_events >= 0);
assertEquals("uncaught", event_data.exception().message);
assertTrue(event_data.promise() instanceof Promise);
- assertEquals(q, event_data.promise());
+ assertSame(q, event_data.promise());
assertTrue(event_data.uncaught());
// Assert that the debug event is triggered at the throw site.
assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
- step++;
}
} catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
+ %AbortJS(e + "\n" + e.stack);
}
}
@@ -53,3 +46,25 @@ Debug.setBreakOnException();
Debug.setListener(listener);
log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "end main", "throw"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Rerun testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises-uncaught-uncaught.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-uncaught-uncaught.js
index fa97ac0d85..69aa8ebbd2 100644
--- a/deps/v8/test/mjsunit/es6/debug-promises-uncaught-uncaught.js
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-uncaught-uncaught.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-promises --expose-debug-as debug
+// Flags: --expose-debug-as debug --allow-natives-syntax
// Test debug events when we only listen to uncaught exceptions and
// there is a catch handler for the exception thrown in a Promise.
@@ -10,8 +10,8 @@
Debug = debug.Debug;
+var expected_events = 1;
var log = [];
-var step = 0;
var p = new Promise(function(resolve, reject) {
log.push("resolve");
@@ -25,26 +25,20 @@ var q = p.chain(
});
function listener(event, exec_state, event_data, data) {
+ if (event == Debug.DebugEvent.AsyncTaskEvent) return;
try {
- // Ignore exceptions during startup in stress runs.
- if (step >= 1) return;
- assertEquals(["resolve", "end main", "throw"], log);
if (event == Debug.DebugEvent.Exception) {
- assertEquals(0, step);
+ expected_events--;
+ assertTrue(expected_events >= 0);
assertEquals("uncaught", event_data.exception().message);
assertTrue(event_data.promise() instanceof Promise);
- assertEquals(q, event_data.promise());
+ assertSame(q, event_data.promise());
assertTrue(event_data.uncaught());
// Assert that the debug event is triggered at the throw site.
assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
- step++;
}
} catch (e) {
- // Signal a failure with exit code 1. This is necessary since the
- // debugger swallows exceptions and we expect the chained function
- // and this listener to be executed after the main script is finished.
- print("Unexpected exception: " + e + "\n" + e.stack);
- quit(1);
+ %AbortJS(e + "\n" + e.stack);
}
}
@@ -52,3 +46,25 @@ Debug.setBreakOnUncaughtException();
Debug.setListener(listener);
log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "end main", "throw"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/throw-with-throw-in-reject.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-with-throw-in-reject.js
new file mode 100644
index 0000000000..1ea1c7f9ff
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-with-throw-in-reject.js
@@ -0,0 +1,90 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when an exception is thrown inside a Promise, which is
+// caught by a custom promise, which throws a new exception in its reject
+// handler. We expect two Exception debug events:
+// 1) when the exception is thrown in the promise q.
+// 2) when the custom reject closure in MyPromise throws an exception.
+
+Debug = debug.Debug;
+
+var expected_events = 2;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+function MyPromise(resolver) {
+ var reject = function() {
+ log.push("throw in reject");
+ throw new Error("reject"); // event
+ };
+ var resolve = function() { };
+ log.push("construct");
+ resolver(resolve, reject);
+};
+
+MyPromise.prototype = new Promise(function() {});
+p.constructor = MyPromise;
+
+var q = p.chain(
+ function() {
+ log.push("throw caught");
+ throw new Error("caught"); // event
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ if (expected_events == 1) {
+ assertEquals(["resolve", "construct", "end main",
+ "throw caught"], log);
+ assertEquals("caught", event_data.exception().message);
+ } else if (expected_events == 0) {
+ assertEquals("reject", event_data.exception().message);
+ } else {
+ assertUnreachable();
+ }
+ assertSame(q, event_data.promise());
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf('// event') > 0);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "construct", "end main",
+ "throw caught", "throw in reject"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/throw-with-undefined-reject.js b/deps/v8/test/mjsunit/es6/debug-promises/throw-with-undefined-reject.js
new file mode 100644
index 0000000000..94dcdffa22
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/throw-with-undefined-reject.js
@@ -0,0 +1,88 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+// Test debug events when an exception is thrown inside a Promise, which is
+// caught by a custom promise, which has no reject handler.
+// We expect two Exception debug events:
+// 1) when the exception is thrown in the promise q.
+// 2) when calling the undefined custom reject closure in MyPromise throws.
+
+Debug = debug.Debug;
+
+var expected_events = 2;
+var log = [];
+
+var p = new Promise(function(resolve, reject) {
+ log.push("resolve");
+ resolve();
+});
+
+function MyPromise(resolver) {
+ var reject = undefined;
+ var resolve = function() { };
+ log.push("construct");
+ resolver(resolve, reject);
+};
+
+MyPromise.prototype = new Promise(function() {});
+p.constructor = MyPromise;
+
+var q = p.chain(
+ function() {
+ log.push("throw caught");
+ throw new Error("caught"); // event
+ });
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ expected_events--;
+ assertTrue(expected_events >= 0);
+ if (expected_events == 1) {
+ assertTrue(
+ exec_state.frame(0).sourceLineText().indexOf('// event') > 0);
+ assertEquals("caught", event_data.exception().message);
+ } else if (expected_events == 0) {
+ // All of the frames on the stack are from native Javascript.
+ assertEquals(0, exec_state.frameCount());
+ assertEquals("undefined is not a function",
+ event_data.exception().message);
+ } else {
+ assertUnreachable();
+ }
+ assertSame(q, event_data.promise());
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+log.push("end main");
+
+function testDone(iteration) {
+ function checkResult() {
+ try {
+ assertTrue(iteration < 10);
+ if (expected_events === 0) {
+ assertEquals(["resolve", "construct", "end main", "throw caught"], log);
+ } else {
+ testDone(iteration + 1);
+ }
+ } catch (e) {
+ %AbortJS(e + "\n" + e.stack);
+ }
+ }
+
+ // Run testDone through the Object.observe processing loop.
+ var dummy = {};
+ Object.observe(dummy, checkResult);
+ dummy.dummy = dummy;
+}
+
+testDone(0);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/try-reject-in-constructor.js b/deps/v8/test/mjsunit/es6/debug-promises/try-reject-in-constructor.js
new file mode 100644
index 0000000000..00981a67d0
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/try-reject-in-constructor.js
@@ -0,0 +1,42 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+// Test debug events when we only listen to uncaught exceptions and
+// the Promise is rejected within a try-catch in the Promise constructor.
+// We expect an Exception debug event with a promise to be triggered.
+
+Debug = debug.Debug;
+
+var step = 0;
+var exception = null;
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ assertEquals(0, step);
+ assertEquals("uncaught", event_data.exception().message);
+ assertTrue(event_data.promise() instanceof Promise);
+ assertTrue(event_data.uncaught());
+ // Assert that the debug event is triggered at the throw site.
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ step++;
+ }
+ } catch (e) {
+ exception = e;
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+var p = new Promise(function(resolve, reject) {
+ try { // This try-catch must not prevent this uncaught reject event.
+ reject(new Error("uncaught")); // event
+ } catch (e) { }
+});
+
+assertEquals(1, step);
+assertNull(exception);
diff --git a/deps/v8/test/mjsunit/es6/debug-promises/try-throw-reject-in-constructor.js b/deps/v8/test/mjsunit/es6/debug-promises/try-throw-reject-in-constructor.js
new file mode 100644
index 0000000000..feff81da90
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-promises/try-throw-reject-in-constructor.js
@@ -0,0 +1,44 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+// Test debug events when we only listen to uncaught exceptions and
+// an exception is thrown in the Promise constructor, but caught in an
+// inner try-catch. The Promise is rejected afterwards.
+// We expect an Exception debug event with a promise to be triggered.
+
+Debug = debug.Debug;
+
+var step = 0;
+var exception = null;
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Exception) {
+ assertEquals(0, step);
+ assertEquals("uncaught", event_data.exception().message);
+ assertTrue(event_data.promise() instanceof Promise);
+ assertTrue(event_data.uncaught());
+ // Assert that the debug event is triggered at the throw site.
+ assertTrue(exec_state.frame(0).sourceLineText().indexOf("// event") > 0);
+ step++;
+ }
+ } catch (e) {
+ exception = e;
+ }
+}
+
+Debug.setBreakOnUncaughtException();
+Debug.setListener(listener);
+
+var p = new Promise(function(resolve, reject) {
+ try { // This try-catch must not prevent this uncaught reject event.
+ throw new Error("caught");
+ } catch (e) { }
+ reject(new Error("uncaught")); // event
+});
+
+assertEquals(1, step);
+assertNull(exception);
diff --git a/deps/v8/test/mjsunit/es6/debug-stepin-collections-foreach.js b/deps/v8/test/mjsunit/es6/debug-stepin-collections-foreach.js
new file mode 100644
index 0000000000..08938f7751
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/debug-stepin-collections-foreach.js
@@ -0,0 +1,118 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+// Flags: --expose-debug-as debug
+
+Debug = debug.Debug
+
+var exception = false;
+
+function listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Break) {
+ if (breaks == 0) {
+ exec_state.prepareStep(Debug.StepAction.StepIn, 2);
+ breaks = 1;
+ } else if (breaks <= 3) {
+ breaks++;
+ // Check whether we break at the expected line.
+ print(event_data.sourceLineText());
+ assertTrue(event_data.sourceLineText().indexOf("Expected to step") > 0);
+ exec_state.prepareStep(Debug.StepAction.StepIn, 3);
+ }
+ }
+ } catch (e) {
+ exception = true;
+ }
+}
+
+function cb_set(num) {
+ print("element " + num); // Expected to step to this point.
+ return true;
+}
+
+function cb_map(key, val) {
+ print("key " + key + ", value " + val); // Expected to step to this point.
+ return true;
+}
+
+var s = new Set();
+s.add(1);
+s.add(2);
+s.add(3);
+s.add(4);
+
+var m = new Map();
+m.set('foo', 1);
+m.set('bar', 2);
+m.set('baz', 3);
+m.set('bat', 4);
+
+Debug.setListener(listener);
+
+var breaks = 0;
+debugger;
+s.forEach(cb_set);
+assertFalse(exception);
+assertEquals(4, breaks);
+
+breaks = 0;
+debugger;
+m.forEach(cb_map);
+assertFalse(exception);
+assertEquals(4, breaks);
+
+Debug.setListener(null);
+
+
+// Test two levels of builtin callbacks:
+// Array.forEach calls a callback function, which by itself uses
+// Array.forEach with another callback function.
+
+function second_level_listener(event, exec_state, event_data, data) {
+ try {
+ if (event == Debug.DebugEvent.Break) {
+ if (breaks == 0) {
+ exec_state.prepareStep(Debug.StepAction.StepIn, 3);
+ breaks = 1;
+ } else if (breaks <= 16) {
+ breaks++;
+ // Check whether we break at the expected line.
+ assertTrue(event_data.sourceLineText().indexOf("Expected to step") > 0);
+ // Step two steps further every four breaks to skip the
+ // forEach call in the first level of recurision.
+ var step = (breaks % 4 == 1) ? 6 : 3;
+ exec_state.prepareStep(Debug.StepAction.StepIn, step);
+ }
+ }
+ } catch (e) {
+ exception = true;
+ }
+}
+
+function cb_set_foreach(num) {
+ s.forEach(cb_set);
+ print("back to the first level of recursion.");
+}
+
+function cb_map_foreach(key, val) {
+ m.forEach(cb_set);
+ print("back to the first level of recursion.");
+}
+
+Debug.setListener(second_level_listener);
+
+breaks = 0;
+debugger;
+s.forEach(cb_set_foreach);
+assertFalse(exception);
+assertEquals(17, breaks);
+
+breaks = 0;
+debugger;
+m.forEach(cb_map_foreach);
+assertFalse(exception);
+assertEquals(17, breaks);
+
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/harmony/iteration-semantics.js b/deps/v8/test/mjsunit/es6/iteration-semantics.js
index 2449115dd4..7849b29abe 100644
--- a/deps/v8/test/mjsunit/harmony/iteration-semantics.js
+++ b/deps/v8/test/mjsunit/es6/iteration-semantics.js
@@ -25,7 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-iteration
// Flags: --harmony-generators --harmony-scoping --harmony-proxies
// Test for-of semantics.
@@ -41,13 +40,19 @@ function* values() {
}
}
+function wrap_iterator(iterator) {
+ var iterable = {};
+ iterable[Symbol.iterator] = function() { return iterator; };
+ return iterable;
+}
+
function integers_until(max) {
function next() {
var ret = { value: this.n, done: this.n == max };
this.n++;
return ret;
}
- return { next: next, n: 0 }
+ return wrap_iterator({ next: next, n: 0 });
}
function results(results) {
@@ -55,7 +60,7 @@ function results(results) {
function next() {
return results[i++];
}
- return { next: next }
+ return wrap_iterator({ next: next });
}
function* integers_from(n) {
@@ -72,44 +77,44 @@ function sum(x, tail) {
return x + tail;
}
-function fold(cons, seed, iter) {
- for (var x of iter) {
+function fold(cons, seed, iterable) {
+ for (var x of iterable) {
seed = cons(x, seed);
}
return seed;
}
-function* take(iter, n) {
+function* take(iterable, n) {
if (n == 0) return;
- for (let x of iter) {
+ for (let x of iterable) {
yield x;
if (--n == 0) break;
}
}
-function nth(iter, n) {
- for (let x of iter) {
+function nth(iterable, n) {
+ for (let x of iterable) {
if (n-- == 0) return x;
}
throw "unreachable";
}
-function* skip_every(iter, n) {
+function* skip_every(iterable, n) {
var i = 0;
- for (let x of iter) {
+ for (let x of iterable) {
if (++i % n == 0) continue;
yield x;
}
}
-function* iter_map(iter, f) {
- for (var x of iter) {
+function* iter_map(iterable, f) {
+ for (var x of iterable) {
yield f(x);
}
}
-function nested_fold(cons, seed, iter) {
+function nested_fold(cons, seed, iterable) {
var visited = []
- for (let x of iter) {
+ for (let x of iterable) {
for (let y of x) {
seed = cons(y, seed);
}
@@ -117,8 +122,8 @@ function nested_fold(cons, seed, iter) {
return seed;
}
-function* unreachable(iter) {
- for (let x of iter) {
+function* unreachable(iterable) {
+ for (let x of iterable) {
throw "not reached";
}
}
@@ -141,17 +146,19 @@ function never_getter(o, prop) {
return o;
}
-function remove_next_after(iter, n) {
+function remove_next_after(iterable, n) {
+ var iterator = iterable[Symbol.iterator]();
function next() {
if (n-- == 0) delete this.next;
- return iter.next();
+ return iterator.next();
}
- return { next: next }
+ return wrap_iterator({ next: next });
}
-function poison_next_after(iter, n) {
+function poison_next_after(iterable, n) {
+ var iterator = iterable[Symbol.iterator]();
function next() {
- return iter.next();
+ return iterator.next();
}
function next_getter() {
if (n-- < 0)
@@ -160,7 +167,7 @@ function poison_next_after(iter, n) {
}
var o = {};
Object.defineProperty(o, 'next', { get: next_getter });
- return o;
+ return wrap_iterator(o);
}
// Now, the tests.
@@ -204,13 +211,13 @@ assertEquals([1, 2],
{ value: 37, done: true },
never_getter(never_getter({}, 'done'), 'value')])));
-// Null and undefined do not cause an error.
-assertEquals(0, fold(sum, 0, unreachable(null)));
-assertEquals(0, fold(sum, 0, unreachable(undefined)));
+// Unlike the case with for-in, null and undefined cause an error.
+assertThrows('fold(sum, 0, unreachable(null))', TypeError);
+assertThrows('fold(sum, 0, unreachable(undefined))', TypeError);
// Other non-iterators do cause an error.
assertThrows('fold(sum, 0, unreachable({}))', TypeError);
-assertThrows('fold(sum, 0, unreachable("foo"))', TypeError);
+assertThrows('fold(sum, 0, unreachable(false))', TypeError);
assertThrows('fold(sum, 0, unreachable(37))', TypeError);
// "next" is looked up each time.
@@ -223,33 +230,33 @@ assertEquals(45,
assertEquals(45,
fold(sum, 0, poison_next_after(integers_until(10), 10)));
-function labelled_continue(iter) {
+function labelled_continue(iterable) {
var n = 0;
outer:
while (true) {
n++;
- for (var x of iter) continue outer;
+ for (var x of iterable) continue outer;
break;
}
return n;
}
assertEquals(11, labelled_continue(integers_until(10)));
-function labelled_break(iter) {
+function labelled_break(iterable) {
var n = 0;
outer:
while (true) {
n++;
- for (var x of iter) break outer;
+ for (var x of iterable) break outer;
}
return n;
}
assertEquals(1, labelled_break(integers_until(10)));
// Test continue/break in catch.
-function catch_control(iter, k) {
+function catch_control(iterable, k) {
var n = 0;
- for (var x of iter) {
+ for (var x of iterable) {
try {
return k(x);
} catch (e) {
@@ -274,9 +281,9 @@ assertEquals(5,
}));
// Test continue/break in try.
-function try_control(iter, k) {
+function try_control(iterable, k) {
var n = 0;
- for (var x of iter) {
+ for (var x of iterable) {
try {
var e = k(x);
if (e == "continue") continue;
@@ -313,16 +320,17 @@ assertEquals([1, 2],
.map(transparent_proxy))));
// Proxy iterators.
-function poison_proxy_after(x, n) {
- return Proxy.create({
+function poison_proxy_after(iterable, n) {
+ var iterator = iterable[Symbol.iterator]();
+ return wrap_iterator(Proxy.create({
get: function(receiver, name) {
if (name == 'next' && n-- < 0) throw "unreachable";
- return x[name];
+ return iterator[name];
},
// Needed for integers_until(10)'s this.n++.
set: function(receiver, name, val) {
- return x[name] = val;
+ return iterator[name] = val;
}
- });
+ }));
}
assertEquals(45, fold(sum, 0, poison_proxy_after(integers_until(10), 10)));
diff --git a/deps/v8/test/mjsunit/harmony/iteration-syntax.js b/deps/v8/test/mjsunit/es6/iteration-syntax.js
index 3bda78ed4e..356a97898a 100644
--- a/deps/v8/test/mjsunit/harmony/iteration-syntax.js
+++ b/deps/v8/test/mjsunit/es6/iteration-syntax.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-iteration --harmony-scoping
+// Flags: --harmony-scoping --use-strict
// Test for-of syntax.
diff --git a/deps/v8/test/mjsunit/es6/math-cbrt.js b/deps/v8/test/mjsunit/es6/math-cbrt.js
index 83d9eb5d75..713c020e42 100644
--- a/deps/v8/test/mjsunit/es6/math-cbrt.js
+++ b/deps/v8/test/mjsunit/es6/math-cbrt.js
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-maths
-
assertTrue(isNaN(Math.cbrt(NaN)));
assertTrue(isNaN(Math.cbrt(function() {})));
assertTrue(isNaN(Math.cbrt({ toString: function() { return NaN; } })));
diff --git a/deps/v8/test/mjsunit/es6/math-clz32.js b/deps/v8/test/mjsunit/es6/math-clz32.js
index 816f6a936e..3cbd4c3fcc 100644
--- a/deps/v8/test/mjsunit/es6/math-clz32.js
+++ b/deps/v8/test/mjsunit/es6/math-clz32.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-maths --allow-natives-syntax
+// Flags: --allow-natives-syntax
[NaN, Infinity, -Infinity, 0, -0, "abc", "Infinity", "-Infinity", {}].forEach(
function(x) {
diff --git a/deps/v8/test/mjsunit/es6/math-expm1.js b/deps/v8/test/mjsunit/es6/math-expm1.js
index de915c0969..b4e31a959b 100644
--- a/deps/v8/test/mjsunit/es6/math-expm1.js
+++ b/deps/v8/test/mjsunit/es6/math-expm1.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-maths --no-fast-math
+// Flags: --no-fast-math
assertTrue(isNaN(Math.expm1(NaN)));
assertTrue(isNaN(Math.expm1(function() {})));
diff --git a/deps/v8/test/mjsunit/es6/math-fround.js b/deps/v8/test/mjsunit/es6/math-fround.js
index ea432ea2de..c53396a38a 100644
--- a/deps/v8/test/mjsunit/es6/math-fround.js
+++ b/deps/v8/test/mjsunit/es6/math-fround.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-maths
+// Flags: --allow-natives-syntax
// Monkey-patch Float32Array.
Float32Array = function(x) { this[0] = 0; };
@@ -11,15 +11,33 @@ assertTrue(isNaN(Math.fround(NaN)));
assertTrue(isNaN(Math.fround(function() {})));
assertTrue(isNaN(Math.fround({ toString: function() { return NaN; } })));
assertTrue(isNaN(Math.fround({ valueOf: function() { return "abc"; } })));
-assertEquals("Infinity", String(1/Math.fround(0)));
-assertEquals("-Infinity", String(1/Math.fround(-0)));
-assertEquals("Infinity", String(Math.fround(Infinity)));
-assertEquals("-Infinity", String(Math.fround(-Infinity)));
+assertTrue(isNaN(Math.fround(NaN)));
+assertTrue(isNaN(Math.fround(function() {})));
+assertTrue(isNaN(Math.fround({ toString: function() { return NaN; } })));
+assertTrue(isNaN(Math.fround({ valueOf: function() { return "abc"; } })));
+
+function unopt(x) { return Math.fround(x); }
+function opt(y) { return Math.fround(y); }
-assertEquals("Infinity", String(Math.fround(1E200)));
-assertEquals("-Infinity", String(Math.fround(-1E200)));
-assertEquals("Infinity", String(1/Math.fround(1E-300)));
-assertEquals("-Infinity", String(1/Math.fround(-1E-300)));
+opt(0.1);
+opt(0.1);
+unopt(0.1);
+%NeverOptimizeFunction(unopt);
+%OptimizeFunctionOnNextCall(opt);
+
+function test(f) {
+ assertEquals("Infinity", String(1/f(0)));
+ assertEquals("-Infinity", String(1/f(-0)));
+ assertEquals("Infinity", String(f(Infinity)));
+ assertEquals("-Infinity", String(f(-Infinity)));
+ assertEquals("Infinity", String(f(1E200)));
+ assertEquals("-Infinity", String(f(-1E200)));
+ assertEquals("Infinity", String(1/f(1E-300)));
+ assertEquals("-Infinity", String(1/f(-1E-300)));
+}
+
+test(opt);
+test(unopt);
mantissa_23_shift = Math.pow(2, -23);
mantissa_29_shift = Math.pow(2, -23-29);
@@ -81,13 +99,16 @@ ieee754float.prototype.toSingleSubnormal = function(sign, exponent) {
var pi = new ieee754float(0, 0x400, 0x490fda, 0x14442d18);
-assertEquals(pi.toSingle(), Math.fround(pi.toDouble()));
+assertEquals(pi.toSingle(), opt(pi.toDouble()));
+assertEquals(pi.toSingle(), unopt(pi.toDouble()));
+
function fuzz_mantissa(sign, exp, m1inc, m2inc) {
for (var m1 = 0; m1 < (1 << 23); m1 += m1inc) {
for (var m2 = 0; m2 < (1 << 29); m2 += m2inc) {
var float = new ieee754float(sign, exp, m1, m2);
- assertEquals(float.toSingle(), Math.fround(float.toDouble()));
+ assertEquals(float.toSingle(), unopt(float.toDouble()));
+ assertEquals(float.toSingle(), opt(float.toDouble()));
}
}
}
diff --git a/deps/v8/test/mjsunit/es6/math-hyperbolic.js b/deps/v8/test/mjsunit/es6/math-hyperbolic.js
index c45a19c526..1ceb95182b 100644
--- a/deps/v8/test/mjsunit/es6/math-hyperbolic.js
+++ b/deps/v8/test/mjsunit/es6/math-hyperbolic.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-maths
-
[Math.sinh, Math.cosh, Math.tanh, Math.asinh, Math.acosh, Math.atanh].
forEach(function(fun) {
assertTrue(isNaN(fun(NaN)));
diff --git a/deps/v8/test/mjsunit/es6/math-hypot.js b/deps/v8/test/mjsunit/es6/math-hypot.js
index 1052627213..d2392df3a4 100644
--- a/deps/v8/test/mjsunit/es6/math-hypot.js
+++ b/deps/v8/test/mjsunit/es6/math-hypot.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-maths
-
assertTrue(isNaN(Math.hypot({})));
assertTrue(isNaN(Math.hypot(undefined, 1)));
assertTrue(isNaN(Math.hypot(1, undefined)));
diff --git a/deps/v8/test/mjsunit/es6/math-log1p.js b/deps/v8/test/mjsunit/es6/math-log1p.js
index eefea6ee38..5468444fda 100644
--- a/deps/v8/test/mjsunit/es6/math-log1p.js
+++ b/deps/v8/test/mjsunit/es6/math-log1p.js
@@ -2,22 +2,20 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-maths
-
assertTrue(isNaN(Math.log1p(NaN)));
assertTrue(isNaN(Math.log1p(function() {})));
assertTrue(isNaN(Math.log1p({ toString: function() { return NaN; } })));
assertTrue(isNaN(Math.log1p({ valueOf: function() { return "abc"; } })));
-assertEquals("Infinity", String(1/Math.log1p(0)));
-assertEquals("-Infinity", String(1/Math.log1p(-0)));
-assertEquals("Infinity", String(Math.log1p(Infinity)));
-assertEquals("-Infinity", String(Math.log1p(-1)));
+assertEquals(Infinity, 1/Math.log1p(0));
+assertEquals(-Infinity, 1/Math.log1p(-0));
+assertEquals(Infinity, Math.log1p(Infinity));
+assertEquals(-Infinity, Math.log1p(-1));
assertTrue(isNaN(Math.log1p(-2)));
assertTrue(isNaN(Math.log1p(-Infinity)));
-for (var x = 1E300; x > 1E-1; x *= 0.8) {
+for (var x = 1E300; x > 1E16; x *= 0.8) {
var expected = Math.log(x + 1);
- assertEqualsDelta(expected, Math.log1p(x), expected * 1E-14);
+ assertEqualsDelta(expected, Math.log1p(x), expected * 1E-16);
}
// Values close to 0:
@@ -37,5 +35,36 @@ function log1p(x) {
for (var x = 1E-1; x > 1E-300; x *= 0.8) {
var expected = log1p(x);
- assertEqualsDelta(expected, Math.log1p(x), expected * 1E-14);
+ assertEqualsDelta(expected, Math.log1p(x), expected * 1E-16);
}
+
+// Issue 3481.
+assertEquals(6.9756137364252422e-03,
+ Math.log1p(8070450532247929/Math.pow(2,60)));
+
+// Tests related to the fdlibm implementation.
+// Test largest double value.
+assertEquals(709.782712893384, Math.log1p(1.7976931348623157e308));
+// Test small values.
+assertEquals(Math.pow(2, -55), Math.log1p(Math.pow(2, -55)));
+assertEquals(9.313225741817976e-10, Math.log1p(Math.pow(2, -30)));
+// Cover various code paths.
+// -.2929 < x < .41422, k = 0
+assertEquals(-0.2876820724517809, Math.log1p(-0.25));
+assertEquals(0.22314355131420976, Math.log1p(0.25));
+// 0.41422 < x < 9.007e15
+assertEquals(2.3978952727983707, Math.log1p(10));
+// x > 9.007e15
+assertEquals(36.841361487904734, Math.log1p(10e15));
+// Normalize u.
+assertEquals(37.08337388996168, Math.log1p(12738099905822720));
+// Normalize u/2.
+assertEquals(37.08336444902049, Math.log1p(12737979646738432));
+// |f| = 0, k != 0
+assertEquals(1.3862943611198906, Math.log1p(3));
+// |f| != 0, k != 0
+assertEquals(1.3862945995384413, Math.log1p(3 + Math.pow(2,-20)));
+// final if-clause: k = 0
+assertEquals(0.5596157879354227, Math.log1p(0.75));
+// final if-clause: k != 0
+assertEquals(0.8109302162163288, Math.log1p(1.25));
diff --git a/deps/v8/test/mjsunit/es6/math-log2-log10.js b/deps/v8/test/mjsunit/es6/math-log2-log10.js
index 2ab496012c..4479894d7d 100644
--- a/deps/v8/test/mjsunit/es6/math-log2-log10.js
+++ b/deps/v8/test/mjsunit/es6/math-log2-log10.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-maths
-
[Math.log10, Math.log2].forEach( function(fun) {
assertTrue(isNaN(fun(NaN)));
assertTrue(isNaN(fun(fun)));
diff --git a/deps/v8/test/mjsunit/es6/math-sign.js b/deps/v8/test/mjsunit/es6/math-sign.js
index 8a89d62828..65f1609d63 100644
--- a/deps/v8/test/mjsunit/es6/math-sign.js
+++ b/deps/v8/test/mjsunit/es6/math-sign.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-maths
-
assertEquals("Infinity", String(1/Math.sign(0)));
assertEquals("-Infinity", String(1/Math.sign(-0)));
assertEquals(1, Math.sign(100));
diff --git a/deps/v8/test/mjsunit/es6/math-trunc.js b/deps/v8/test/mjsunit/es6/math-trunc.js
index ed91ed1380..9231576dda 100644
--- a/deps/v8/test/mjsunit/es6/math-trunc.js
+++ b/deps/v8/test/mjsunit/es6/math-trunc.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-maths
-
assertEquals("Infinity", String(1/Math.trunc(0)));
assertEquals("-Infinity", String(1/Math.trunc(-0)));
assertEquals("Infinity", String(1/Math.trunc(Math.PI/4)));
diff --git a/deps/v8/test/mjsunit/es6/mirror-collections.js b/deps/v8/test/mjsunit/es6/mirror-collections.js
new file mode 100644
index 0000000000..e10f5c1a98
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/mirror-collections.js
@@ -0,0 +1,144 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --expose-gc
+
+function testMapMirror(mirror) {
+ // Create JSON representation.
+ var serializer = debug.MakeMirrorSerializer();
+ var json = JSON.stringify(serializer.serializeValue(mirror));
+
+ // Check the mirror hierachy.
+ assertTrue(mirror instanceof debug.Mirror);
+ assertTrue(mirror instanceof debug.ValueMirror);
+ assertTrue(mirror instanceof debug.ObjectMirror);
+ assertTrue(mirror instanceof debug.MapMirror);
+
+ assertTrue(mirror.isMap());
+
+ // Parse JSON representation and check.
+ var fromJSON = eval('(' + json + ')');
+ assertEquals('map', fromJSON.type);
+}
+
+function testSetMirror(mirror) {
+ // Create JSON representation.
+ var serializer = debug.MakeMirrorSerializer();
+ var json = JSON.stringify(serializer.serializeValue(mirror));
+
+ // Check the mirror hierachy.
+ assertTrue(mirror instanceof debug.Mirror);
+ assertTrue(mirror instanceof debug.ValueMirror);
+ assertTrue(mirror instanceof debug.ObjectMirror);
+ assertTrue(mirror instanceof debug.SetMirror);
+
+ assertTrue(mirror.isSet());
+
+ // Parse JSON representation and check.
+ var fromJSON = eval('(' + json + ')');
+ assertEquals('set', fromJSON.type);
+}
+
+var o1 = new Object();
+var o2 = new Object();
+var o3 = new Object();
+
+// Test the mirror object for Maps
+var map = new Map();
+map.set(o1, 11);
+map.set(o2, 22);
+map.delete(o1);
+var mapMirror = debug.MakeMirror(map);
+testMapMirror(mapMirror);
+var entries = mapMirror.entries();
+assertEquals(1, entries.length);
+assertSame(o2, entries[0].key);
+assertEquals(22, entries[0].value);
+map.set(o1, 33);
+map.set(o3, o2);
+map.delete(o2);
+map.set(undefined, 44);
+entries = mapMirror.entries();
+assertEquals(3, entries.length);
+assertSame(o1, entries[0].key);
+assertEquals(33, entries[0].value);
+assertSame(o3, entries[1].key);
+assertSame(o2, entries[1].value);
+assertEquals(undefined, entries[2].key);
+assertEquals(44, entries[2].value);
+
+// Test the mirror object for Sets
+var set = new Set();
+set.add(o1);
+set.add(o2);
+set.delete(o1);
+set.add(undefined);
+var setMirror = debug.MakeMirror(set);
+testSetMirror(setMirror);
+var values = setMirror.values();
+assertEquals(2, values.length);
+assertSame(o2, values[0]);
+assertEquals(undefined, values[1]);
+
+// Test the mirror object for WeakMaps
+var weakMap = new WeakMap();
+weakMap.set(o1, 11);
+weakMap.set(new Object(), 22);
+weakMap.set(o3, 33);
+weakMap.set(new Object(), 44);
+var weakMapMirror = debug.MakeMirror(weakMap);
+testMapMirror(weakMapMirror);
+weakMap.set(new Object(), 55);
+assertTrue(weakMapMirror.entries().length <= 5);
+gc();
+
+function testWeakMapEntries(weakMapMirror) {
+ var entries = weakMapMirror.entries();
+ assertEquals(2, entries.length);
+ var found = 0;
+ for (var i = 0; i < entries.length; i++) {
+ if (Object.is(entries[i].key, o1)) {
+ assertEquals(11, entries[i].value);
+ found++;
+ }
+ if (Object.is(entries[i].key, o3)) {
+ assertEquals(33, entries[i].value);
+ found++;
+ }
+ }
+ assertEquals(2, found);
+}
+
+testWeakMapEntries(weakMapMirror);
+
+// Test the mirror object for WeakSets
+var weakSet = new WeakSet();
+weakSet.add(o1);
+weakSet.add(new Object());
+weakSet.add(o2);
+weakSet.add(new Object());
+weakSet.add(new Object());
+weakSet.add(o3);
+weakSet.delete(o2);
+var weakSetMirror = debug.MakeMirror(weakSet);
+testSetMirror(weakSetMirror);
+assertTrue(weakSetMirror.values().length <= 5);
+gc();
+
+function testWeakSetValues(weakSetMirror) {
+ var values = weakSetMirror.values();
+ assertEquals(2, values.length);
+ var found = 0;
+ for (var i = 0; i < values.length; i++) {
+ if (Object.is(values[i], o1)) {
+ found++;
+ }
+ if (Object.is(values[i], o3)) {
+ found++;
+ }
+ }
+ assertEquals(2, found);
+}
+
+testWeakSetValues(weakSetMirror);
diff --git a/deps/v8/test/mjsunit/es6/mirror-promises.js b/deps/v8/test/mjsunit/es6/mirror-promises.js
index 5a21a6b9e6..deeba8f549 100644
--- a/deps/v8/test/mjsunit/es6/mirror-promises.js
+++ b/deps/v8/test/mjsunit/es6/mirror-promises.js
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --expose-debug-as debug --harmony-promises
+// Flags: --expose-debug-as debug
// Test the mirror object for promises.
function MirrorRefCache(json_refs) {
@@ -39,7 +39,8 @@ function testPromiseMirror(promise, status, value) {
assertEquals("Object", mirror.className());
assertEquals("#<Promise>", mirror.toText());
assertSame(promise, mirror.value());
- assertEquals(value, mirror.promiseValue());
+ assertTrue(mirror.promiseValue() instanceof debug.Mirror);
+ assertEquals(value, mirror.promiseValue().value());
// Parse JSON representation and check.
var fromJSON = eval('(' + json + ')');
@@ -48,7 +49,7 @@ function testPromiseMirror(promise, status, value) {
assertEquals('function', refs.lookup(fromJSON.constructorFunction.ref).type);
assertEquals('Promise', refs.lookup(fromJSON.constructorFunction.ref).name);
assertEquals(status, fromJSON.status);
- assertEquals(value, fromJSON.promiseValue);
+ assertEquals(value, refs.lookup(fromJSON.promiseValue.ref).value);
}
// Test a number of different promises.
@@ -67,3 +68,23 @@ var thrownv = new Promise(function(resolve, reject) { throw 'throw' });
testPromiseMirror(resolvedv, "resolved", 'resolve');
testPromiseMirror(rejectedv, "rejected", 'reject');
testPromiseMirror(thrownv, "rejected", 'throw');
+
+// Test internal properties of different promises.
+var m1 = debug.MakeMirror(new Promise(
+ function(resolve, reject) { resolve(1) }));
+var ip = m1.internalProperties();
+assertEquals(2, ip.length);
+assertEquals("[[PromiseStatus]]", ip[0].name());
+assertEquals("[[PromiseValue]]", ip[1].name());
+assertEquals("resolved", ip[0].value().value());
+assertEquals(1, ip[1].value().value());
+
+var m2 = debug.MakeMirror(new Promise(function(resolve, reject) { reject(2) }));
+ip = m2.internalProperties();
+assertEquals("rejected", ip[0].value().value());
+assertEquals(2, ip[1].value().value());
+
+var m3 = debug.MakeMirror(new Promise(function(resolve, reject) { }));
+ip = m3.internalProperties();
+assertEquals("pending", ip[0].value().value());
+assertEquals("undefined", typeof(ip[1].value().value()));
diff --git a/deps/v8/test/mjsunit/es6/mirror-symbols.js b/deps/v8/test/mjsunit/es6/mirror-symbols.js
new file mode 100644
index 0000000000..f218332abf
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/mirror-symbols.js
@@ -0,0 +1,38 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+// Test the mirror object for symbols.
+
+function testSymbolMirror(symbol, description) {
+ // Create mirror and JSON representation.
+ var mirror = debug.MakeMirror(symbol);
+ var serializer = debug.MakeMirrorSerializer();
+ var json = JSON.stringify(serializer.serializeValue(mirror));
+
+ // Check the mirror hierachy.
+ assertTrue(mirror instanceof debug.Mirror);
+ assertTrue(mirror instanceof debug.ValueMirror);
+ assertTrue(mirror instanceof debug.SymbolMirror);
+
+ // Check the mirror properties.
+ assertTrue(mirror.isSymbol());
+ assertEquals(description, mirror.description());
+ assertEquals('symbol', mirror.type());
+ assertTrue(mirror.isPrimitive());
+ var description_text = description === undefined ? "" : description;
+ assertEquals('Symbol(' + description_text + ')', mirror.toText());
+ assertSame(symbol, mirror.value());
+
+ // Parse JSON representation and check.
+ var fromJSON = eval('(' + json + ')');
+ assertEquals('symbol', fromJSON.type);
+ assertEquals(description, fromJSON.description);
+}
+
+// Test a number of different symbols.
+testSymbolMirror(Symbol("a"), "a");
+testSymbolMirror(Symbol(12), "12");
+testSymbolMirror(Symbol.for("b"), "b");
+testSymbolMirror(Symbol(), undefined);
diff --git a/deps/v8/test/mjsunit/es6/promises.js b/deps/v8/test/mjsunit/es6/promises.js
index 6dfe9261a8..faf154ee0a 100644
--- a/deps/v8/test/mjsunit/es6/promises.js
+++ b/deps/v8/test/mjsunit/es6/promises.js
@@ -27,6 +27,42 @@
// Flags: --allow-natives-syntax
+// Make sure we don't rely on functions patchable by monkeys.
+var call = Function.prototype.call.call.bind(Function.prototype.call)
+var observe = Object.observe;
+var getOwnPropertyNames = Object.getOwnPropertyNames
+var defineProperty = Object.defineProperty
+
+function clear(o) {
+ if (o === null || (typeof o !== 'object' && typeof o !== 'function')) return
+ clear(o.__proto__)
+ var properties = getOwnPropertyNames(o)
+ for (var i in properties) {
+ clearProp(o, properties[i])
+ }
+}
+
+function clearProp(o, name) {
+ var poisoned = {caller: 0, callee: 0, arguments: 0}
+ try {
+ var x = o[name]
+ o[name] = undefined
+ clear(x)
+ } catch(e) {} // assertTrue(name in poisoned) }
+}
+
+// Find intrinsics and null them out.
+var globals = Object.getOwnPropertyNames(this)
+var whitelist = {Promise: true, TypeError: true}
+for (var i in globals) {
+ var name = globals[i]
+ if (name in whitelist || name[0] === name[0].toLowerCase()) delete globals[i]
+}
+for (var i in globals) {
+ if (globals[i]) clearProp(this, globals[i])
+}
+
+
var asyncAssertsExpected = 0;
function assertAsyncRan() { ++asyncAssertsExpected }
@@ -43,7 +79,7 @@ function assertAsync(b, s) {
function assertAsyncDone(iteration) {
var iteration = iteration || 0
var dummy = {}
- Object.observe(dummy,
+ observe(dummy,
function() {
if (asyncAssertsExpected === 0)
assertAsync(true, "all")
@@ -777,13 +813,13 @@ function assertAsyncDone(iteration) {
MyPromise.__proto__ = Promise
MyPromise.defer = function() {
log += "d"
- return this.__proto__.defer.call(this)
+ return call(this.__proto__.defer, this)
}
MyPromise.prototype.__proto__ = Promise.prototype
MyPromise.prototype.chain = function(resolve, reject) {
log += "c"
- return this.__proto__.__proto__.chain.call(this, resolve, reject)
+ return call(this.__proto__.__proto__.chain, this, resolve, reject)
}
log = ""
diff --git a/deps/v8/test/mjsunit/harmony/regress/regress-2186.js b/deps/v8/test/mjsunit/es6/regress/regress-2186.js
index 0921dceadb..c82242a10e 100644
--- a/deps/v8/test/mjsunit/harmony/regress/regress-2186.js
+++ b/deps/v8/test/mjsunit/es6/regress/regress-2186.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-collections
-
function heapify(i) {
return 2.0 * (i / 2);
}
diff --git a/deps/v8/test/mjsunit/regress/regress-2336.js b/deps/v8/test/mjsunit/es6/regress/regress-cr372788.js
index edfff60211..9b66a7e08b 100644
--- a/deps/v8/test/mjsunit/regress/regress-2336.js
+++ b/deps/v8/test/mjsunit/es6/regress/regress-cr372788.js
@@ -1,4 +1,4 @@
-// Copyright 2012 the V8 project authors. All rights reserved.
+// Copyright 2014 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
@@ -25,29 +25,21 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --expose-debug-as debug --expose-gc
+// Flags: --allow-natives-syntax
-// Check that we can cope with a debug listener that runs in the
-// GC epilogue and causes enough allocation to trigger a new GC during
-// the epilogue.
+var x = 0;
+var y = 0;
-var f = eval("(function f() { return 42; })");
+var thenable = { then: function(f) { x++; f(); } };
-Debug = debug.Debug;
+for (var i = 0; i < 3; ++i) {
+ Promise.resolve(thenable).then(function() { x++; y++; });
+}
+assertEquals(0, x);
-var called = false;
-
-function listener(event, exec_state, event_data, data) {
- if (event == Debug.DebugEvent.ScriptCollected) {
- if (!called) {
- called = true;
- gc();
- }
- }
-};
-
-Debug.scripts();
-Debug.setListener(listener);
-f = void 0;
-gc();
-assertTrue(called);
+(function check() {
+ Promise.resolve().chain(function() {
+ // Delay check until all handlers have run.
+ if (y < 3) check(); else assertEquals(6, x);
+ }).catch(function(e) { %AbortJS("FAILURE: " + e) });
+})();
diff --git a/deps/v8/test/mjsunit/harmony/regress/regress-crbug-248025.js b/deps/v8/test/mjsunit/es6/regress/regress-crbug-248025.js
index c598859566..b7982cda74 100644
--- a/deps/v8/test/mjsunit/harmony/regress/regress-crbug-248025.js
+++ b/deps/v8/test/mjsunit/es6/regress/regress-crbug-248025.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-iteration
-
// Filler long enough to trigger lazy parsing.
var filler = "//" + new Array(1024).join('x');
diff --git a/deps/v8/test/mjsunit/harmony/regress/regress-crbug-346141.js b/deps/v8/test/mjsunit/es6/regress/regress-crbug-346141.js
index 798b7704ec..2b9655e174 100644
--- a/deps/v8/test/mjsunit/harmony/regress/regress-crbug-346141.js
+++ b/deps/v8/test/mjsunit/es6/regress/regress-crbug-346141.js
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --harmony-symbols
-
var s = Symbol()
var o = {}
o[s] = 2
diff --git a/deps/v8/test/mjsunit/es6/string-html.js b/deps/v8/test/mjsunit/es6/string-html.js
new file mode 100644
index 0000000000..4f3feb56dd
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/string-html.js
@@ -0,0 +1,159 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Tests taken from:
+// http://mathias.html5.org/tests/javascript/string/
+
+assertEquals('_'.anchor('b'), '<a name="b">_</a>');
+assertEquals('<'.anchor('<'), '<a name="<"><</a>');
+assertEquals('_'.anchor(0x2A), '<a name="42">_</a>');
+assertEquals('_'.anchor('\x22'), '<a name="&quot;">_</a>');
+assertEquals(String.prototype.anchor.call(0x2A, 0x2A), '<a name="42">42</a>');
+assertThrows(function() {
+ String.prototype.anchor.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.anchor.call(null);
+}, TypeError);
+assertEquals(String.prototype.anchor.length, 1);
+
+assertEquals('_'.big(), '<big>_</big>');
+assertEquals('<'.big(), '<big><</big>');
+assertEquals(String.prototype.big.call(0x2A), '<big>42</big>');
+assertThrows(function() {
+ String.prototype.big.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.big.call(null);
+}, TypeError);
+assertEquals(String.prototype.big.length, 0);
+
+assertEquals('_'.blink(), '<blink>_</blink>');
+assertEquals('<'.blink(), '<blink><</blink>');
+assertEquals(String.prototype.blink.call(0x2A), '<blink>42</blink>');
+assertThrows(function() {
+ String.prototype.blink.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.blink.call(null);
+}, TypeError);
+assertEquals(String.prototype.blink.length, 0);
+
+assertEquals('_'.bold(), '<b>_</b>');
+assertEquals('<'.bold(), '<b><</b>');
+assertEquals(String.prototype.bold.call(0x2A), '<b>42</b>');
+assertThrows(function() {
+ String.prototype.bold.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.bold.call(null);
+}, TypeError);
+assertEquals(String.prototype.bold.length, 0);
+
+assertEquals('_'.fixed(), '<tt>_</tt>');
+assertEquals('<'.fixed(), '<tt><</tt>');
+assertEquals(String.prototype.fixed.call(0x2A), '<tt>42</tt>');
+assertThrows(function() {
+ String.prototype.fixed.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.fixed.call(null);
+}, TypeError);
+assertEquals(String.prototype.fixed.length, 0);
+
+assertEquals('_'.fontcolor('b'), '<font color="b">_</font>');
+assertEquals('<'.fontcolor('<'), '<font color="<"><</font>');
+assertEquals('_'.fontcolor(0x2A), '<font color="42">_</font>');
+assertEquals('_'.fontcolor('\x22'), '<font color="&quot;">_</font>');
+assertEquals(String.prototype.fontcolor.call(0x2A, 0x2A),
+ '<font color="42">42</font>');
+assertThrows(function() {
+ String.prototype.fontcolor.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.fontcolor.call(null);
+}, TypeError);
+assertEquals(String.prototype.fontcolor.length, 1);
+
+assertEquals('_'.fontsize('b'), '<font size="b">_</font>');
+assertEquals('<'.fontsize('<'), '<font size="<"><</font>');
+assertEquals('_'.fontsize(0x2A), '<font size="42">_</font>');
+assertEquals('_'.fontsize('\x22'), '<font size="&quot;">_</font>');
+assertEquals(String.prototype.fontsize.call(0x2A, 0x2A),
+ '<font size="42">42</font>');
+assertThrows(function() {
+ String.prototype.fontsize.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.fontsize.call(null);
+}, TypeError);
+assertEquals(String.prototype.fontsize.length, 1);
+
+assertEquals('_'.italics(), '<i>_</i>');
+assertEquals('<'.italics(), '<i><</i>');
+assertEquals(String.prototype.italics.call(0x2A), '<i>42</i>');
+assertThrows(function() {
+ String.prototype.italics.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.italics.call(null);
+}, TypeError);
+assertEquals(String.prototype.italics.length, 0);
+
+assertEquals('_'.link('b'), '<a href="b">_</a>');
+assertEquals('<'.link('<'), '<a href="<"><</a>');
+assertEquals('_'.link(0x2A), '<a href="42">_</a>');
+assertEquals('_'.link('\x22'), '<a href="&quot;">_</a>');
+assertEquals(String.prototype.link.call(0x2A, 0x2A), '<a href="42">42</a>');
+assertThrows(function() {
+ String.prototype.link.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.link.call(null);
+}, TypeError);
+assertEquals(String.prototype.link.length, 1);
+
+assertEquals('_'.small(), '<small>_</small>');
+assertEquals('<'.small(), '<small><</small>');
+assertEquals(String.prototype.small.call(0x2A), '<small>42</small>');
+assertThrows(function() {
+ String.prototype.small.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.small.call(null);
+}, TypeError);
+assertEquals(String.prototype.small.length, 0);
+
+assertEquals('_'.strike(), '<strike>_</strike>');
+assertEquals('<'.strike(), '<strike><</strike>');
+assertEquals(String.prototype.strike.call(0x2A), '<strike>42</strike>');
+assertThrows(function() {
+ String.prototype.strike.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.strike.call(null);
+}, TypeError);
+assertEquals(String.prototype.strike.length, 0);
+
+assertEquals('_'.sub(), '<sub>_</sub>');
+assertEquals('<'.sub(), '<sub><</sub>');
+assertEquals(String.prototype.sub.call(0x2A), '<sub>42</sub>');
+assertThrows(function() {
+ String.prototype.sub.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.sub.call(null);
+}, TypeError);
+assertEquals(String.prototype.sub.length, 0);
+
+assertEquals('_'.sup(), '<sup>_</sup>');
+assertEquals('<'.sup(), '<sup><</sup>');
+assertEquals(String.prototype.sup.call(0x2A), '<sup>42</sup>');
+assertThrows(function() {
+ String.prototype.sup.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.sup.call(null);
+}, TypeError);
+assertEquals(String.prototype.sup.length, 0);
diff --git a/deps/v8/test/mjsunit/es6/string-iterator.js b/deps/v8/test/mjsunit/es6/string-iterator.js
new file mode 100644
index 0000000000..e6bea6dfe7
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/string-iterator.js
@@ -0,0 +1,89 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+
+function TestStringPrototypeIterator() {
+ assertTrue(String.prototype.hasOwnProperty(Symbol.iterator));
+ assertFalse("".hasOwnProperty(Symbol.iterator));
+ assertFalse("".propertyIsEnumerable(Symbol.iterator));
+}
+TestStringPrototypeIterator();
+
+
+function assertIteratorResult(value, done, result) {
+ assertEquals({value: value, done: done}, result);
+}
+
+
+function TestManualIteration() {
+ var string = "abc";
+ var iterator = string[Symbol.iterator]();
+ assertIteratorResult('a', false, iterator.next());
+ assertIteratorResult('b', false, iterator.next());
+ assertIteratorResult('c', false, iterator.next());
+ assertIteratorResult(void 0, true, iterator.next());
+ assertIteratorResult(void 0, true, iterator.next());
+}
+TestManualIteration();
+
+
+function TestSurrogatePairs() {
+ var lo = "\uD834";
+ var hi = "\uDF06";
+ var pair = lo + hi;
+ var string = "abc" + pair + "def" + lo + pair + hi + lo;
+ var iterator = string[Symbol.iterator]();
+ assertIteratorResult('a', false, iterator.next());
+ assertIteratorResult('b', false, iterator.next());
+ assertIteratorResult('c', false, iterator.next());
+ assertIteratorResult(pair, false, iterator.next());
+ assertIteratorResult('d', false, iterator.next());
+ assertIteratorResult('e', false, iterator.next());
+ assertIteratorResult('f', false, iterator.next());
+ assertIteratorResult(lo, false, iterator.next());
+ assertIteratorResult(pair, false, iterator.next());
+ assertIteratorResult(hi, false, iterator.next());
+ assertIteratorResult(lo, false, iterator.next());
+ assertIteratorResult(void 0, true, iterator.next());
+ assertIteratorResult(void 0, true, iterator.next());
+}
+TestSurrogatePairs();
+
+
+function TestStringIteratorPrototype() {
+ var iterator = ""[Symbol.iterator]();
+ var StringIteratorPrototype = iterator.__proto__;
+ assertFalse(StringIteratorPrototype.hasOwnProperty('constructor'));
+ assertEquals(StringIteratorPrototype.__proto__, Object.prototype);
+ assertArrayEquals(['next'],
+ Object.getOwnPropertyNames(StringIteratorPrototype));
+ assertEquals('[object String Iterator]', "" + iterator);
+}
+TestStringIteratorPrototype();
+
+
+function TestForOf() {
+ var lo = "\uD834";
+ var hi = "\uDF06";
+ var pair = lo + hi;
+ var string = "abc" + pair + "def" + lo + pair + hi + lo;
+ var expected = ['a', 'b', 'c', pair, 'd', 'e', 'f', lo, pair, hi, lo];
+
+ var i = 0;
+ for (var char of string) {
+ assertEquals(expected[i++], char);
+ }
+
+ assertEquals(expected.length, i);
+}
+TestForOf();
+
+
+function TestNonOwnSlots() {
+ var iterator = ""[Symbol.iterator]();
+ var object = {__proto__: iterator};
+
+ assertThrows(function() { object.next(); }, TypeError);
+}
+TestNonOwnSlots();
diff --git a/deps/v8/test/mjsunit/harmony/symbols.js b/deps/v8/test/mjsunit/es6/symbols.js
index 220439291c..0b07002700 100644
--- a/deps/v8/test/mjsunit/harmony/symbols.js
+++ b/deps/v8/test/mjsunit/es6/symbols.js
@@ -25,7 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-symbols --harmony-collections
// Flags: --expose-gc --allow-natives-syntax
var symbols = []
@@ -102,7 +101,9 @@ TestConstructor()
function TestValueOf() {
for (var i in symbols) {
+ assertTrue(symbols[i] === Object(symbols[i]).valueOf())
assertTrue(symbols[i] === symbols[i].valueOf())
+ assertTrue(Symbol.prototype.valueOf.call(Object(symbols[i])) === symbols[i])
assertTrue(Symbol.prototype.valueOf.call(symbols[i]) === symbols[i])
}
}
@@ -113,7 +114,7 @@ function TestToString() {
for (var i in symbols) {
assertThrows(function() { String(symbols[i]) }, TypeError)
assertThrows(function() { symbols[i] + "" }, TypeError)
- assertTrue(isValidSymbolString(String(Object(symbols[i]))))
+ assertThrows(function() { String(Object(symbols[i])) }, TypeError)
assertTrue(isValidSymbolString(symbols[i].toString()))
assertTrue(isValidSymbolString(Object(symbols[i]).toString()))
assertTrue(
@@ -127,6 +128,8 @@ TestToString()
function TestToBoolean() {
for (var i in symbols) {
+ assertTrue(Boolean(Object(symbols[i])))
+ assertFalse(!Object(symbols[i]))
assertTrue(Boolean(symbols[i]).valueOf())
assertFalse(!symbols[i])
assertTrue(!!symbols[i])
@@ -144,8 +147,10 @@ TestToBoolean()
function TestToNumber() {
for (var i in symbols) {
- assertSame(NaN, Number(symbols[i]).valueOf())
- assertSame(NaN, symbols[i] + 0)
+ assertThrows(function() { Number(Object(symbols[i])) }, TypeError)
+ assertThrows(function() { +Object(symbols[i]) }, TypeError)
+ assertThrows(function() { Number(symbols[i]) }, TypeError)
+ assertThrows(function() { symbols[i] + 0 }, TypeError)
}
}
TestToNumber()
@@ -367,6 +372,34 @@ for (var i in objs) {
}
+function TestDefineProperties() {
+ var properties = {}
+ for (var i in symbols) {
+ Object.defineProperty(
+ properties, symbols[i], {value: {value: i}, enumerable: i % 2 === 0})
+ }
+ var o = Object.defineProperties({}, properties)
+ for (var i in symbols) {
+ assertEquals(i % 2 === 0, symbols[i] in o)
+ }
+}
+TestDefineProperties()
+
+
+function TestCreate() {
+ var properties = {}
+ for (var i in symbols) {
+ Object.defineProperty(
+ properties, symbols[i], {value: {value: i}, enumerable: i % 2 === 0})
+ }
+ var o = Object.create(Object.prototype, properties)
+ for (var i in symbols) {
+ assertEquals(i % 2 === 0, symbols[i] in o)
+ }
+}
+TestCreate()
+
+
function TestCachedKeyAfterScavenge() {
gc();
// Keyed property lookup are cached. Hereby we assume that the keys are
@@ -412,8 +445,9 @@ TestGetOwnPropertySymbolsWithProto()
function TestWellKnown() {
var symbols = [
- "create", "hasInstance", "isConcatSpreadable", "isRegExp",
- "iterator", "toStringTag", "unscopables"
+ // TODO(rossberg): reactivate once implemented.
+ // "hasInstance", "isConcatSpreadable", "isRegExp",
+ "iterator", /* "toStringTag", */ "unscopables"
]
for (var i in symbols) {
diff --git a/deps/v8/test/mjsunit/es6/typed-array-iterator.js b/deps/v8/test/mjsunit/es6/typed-array-iterator.js
new file mode 100644
index 0000000000..a2e4906c19
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/typed-array-iterator.js
@@ -0,0 +1,39 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+
+var constructors = [Uint8Array, Int8Array,
+ Uint16Array, Int16Array,
+ Uint32Array, Int32Array,
+ Float32Array, Float64Array,
+ Uint8ClampedArray];
+
+function TestTypedArrayPrototype(constructor) {
+ assertTrue(constructor.prototype.hasOwnProperty('entries'));
+ assertTrue(constructor.prototype.hasOwnProperty('values'));
+ assertTrue(constructor.prototype.hasOwnProperty('keys'));
+ assertTrue(constructor.prototype.hasOwnProperty(Symbol.iterator));
+
+ assertFalse(constructor.prototype.propertyIsEnumerable('entries'));
+ assertFalse(constructor.prototype.propertyIsEnumerable('values'));
+ assertFalse(constructor.prototype.propertyIsEnumerable('keys'));
+ assertFalse(constructor.prototype.propertyIsEnumerable(Symbol.iterator));
+
+ assertEquals(Array.prototype.entries, constructor.prototype.entries);
+ assertEquals(Array.prototype.values, constructor.prototype.values);
+ assertEquals(Array.prototype.keys, constructor.prototype.keys);
+ assertEquals(Array.prototype.values, constructor.prototype[Symbol.iterator]);
+}
+constructors.forEach(TestTypedArrayPrototype);
+
+
+function TestTypedArrayValues(constructor) {
+ var array = [1, 2, 3];
+ var i = 0;
+ for (var value of new constructor(array)) {
+ assertEquals(array[i++], value);
+ }
+ assertEquals(i, array.length);
+}
+constructors.forEach(TestTypedArrayValues);
diff --git a/deps/v8/test/mjsunit/es6/unscopables.js b/deps/v8/test/mjsunit/es6/unscopables.js
new file mode 100644
index 0000000000..678536dba4
--- /dev/null
+++ b/deps/v8/test/mjsunit/es6/unscopables.js
@@ -0,0 +1,664 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-unscopables
+// Flags: --harmony-collections
+
+var global = this;
+var globalProto = Object.getPrototypeOf(global);
+
+// Number of objects being tested. There is an assert ensuring this is correct.
+var objectCount = 21;
+
+
+function runTest(f) {
+ function restore(object, oldProto) {
+ delete object[Symbol.unscopables];
+ delete object.x;
+ delete object.x_;
+ delete object.y;
+ delete object.z;
+ Object.setPrototypeOf(object, oldProto);
+ }
+
+ function getObject(i) {
+ var objects = [
+ {},
+ [],
+ function() {},
+ function() {
+ return arguments;
+ }(),
+ function() {
+ 'use strict';
+ return arguments;
+ }(),
+ Object(1),
+ Object(true),
+ Object('bla'),
+ new Date,
+ new RegExp,
+ new Set,
+ new Map,
+ new WeakMap,
+ new WeakSet,
+ new ArrayBuffer(10),
+ new Int32Array(5),
+ Object,
+ Function,
+ Date,
+ RegExp,
+ global
+ ];
+
+ assertEquals(objectCount, objects.length);
+ return objects[i];
+ }
+
+ // Tests depends on this not being there to start with.
+ delete Array.prototype[Symbol.unscopables];
+
+ if (f.length === 1) {
+ for (var i = 0; i < objectCount; i++) {
+ var object = getObject(i);
+ var oldObjectProto = Object.getPrototypeOf(object);
+ f(object);
+ restore(object, oldObjectProto);
+ }
+ } else {
+ for (var i = 0; i < objectCount; i++) {
+ for (var j = 0; j < objectCount; j++) {
+ var object = getObject(i);
+ var proto = getObject(j);
+ if (object === proto) {
+ continue;
+ }
+ var oldObjectProto = Object.getPrototypeOf(object);
+ var oldProtoProto = Object.getPrototypeOf(proto);
+ f(object, proto);
+ restore(object, oldObjectProto);
+ restore(proto, oldProtoProto);
+ }
+ }
+ }
+}
+
+// Test array first, since other tests are changing
+// Array.prototype[Symbol.unscopables].
+function TestArrayPrototypeUnscopables() {
+ var descr = Object.getOwnPropertyDescriptor(Array.prototype,
+ Symbol.unscopables);
+ assertFalse(descr.enumerable);
+ assertFalse(descr.writable);
+ assertTrue(descr.configurable);
+ assertEquals(null, Object.getPrototypeOf(descr.value));
+
+ var copyWithin = 'local copyWithin';
+ var entries = 'local entries';
+ var fill = 'local fill';
+ var find = 'local find';
+ var findIndex = 'local findIndex';
+ var keys = 'local keys';
+ var values = 'local values';
+
+ var array = [];
+ array.toString = 42;
+
+ with (array) {
+ assertEquals('local copyWithin', copyWithin);
+ assertEquals('local entries', entries);
+ assertEquals('local fill', fill);
+ assertEquals('local find', find);
+ assertEquals('local findIndex', findIndex);
+ assertEquals('local keys', keys);
+ assertEquals('local values', values);
+ assertEquals(42, toString);
+ }
+}
+TestArrayPrototypeUnscopables();
+
+
+
+function TestBasics(object) {
+ var x = 1;
+ var y = 2;
+ var z = 3;
+ object.x = 4;
+ object.y = 5;
+
+ with (object) {
+ assertEquals(4, x);
+ assertEquals(5, y);
+ assertEquals(3, z);
+ }
+
+ object[Symbol.unscopables] = {x: true};
+ with (object) {
+ assertEquals(1, x);
+ assertEquals(5, y);
+ assertEquals(3, z);
+ }
+
+ object[Symbol.unscopables] = {x: 0, y: true};
+ with (object) {
+ assertEquals(1, x);
+ assertEquals(2, y);
+ assertEquals(3, z);
+ }
+}
+runTest(TestBasics);
+
+
+function TestUnscopableChain(object) {
+ var x = 1;
+ object.x = 2;
+
+ with (object) {
+ assertEquals(2, x);
+ }
+
+ object[Symbol.unscopables] = {
+ __proto__: {x: true}
+ };
+ with (object) {
+ assertEquals(1, x);
+ }
+}
+runTest(TestUnscopableChain);
+
+
+function TestBasicsSet(object) {
+ var x = 1;
+ object.x = 2;
+
+ with (object) {
+ assertEquals(2, x);
+ }
+
+ object[Symbol.unscopables] = {x: true};
+ with (object) {
+ assertEquals(1, x);
+ x = 3;
+ assertEquals(3, x);
+ }
+
+ assertEquals(3, x);
+ assertEquals(2, object.x);
+}
+runTest(TestBasicsSet);
+
+
+function TestOnProto(object, proto) {
+ var x = 1;
+ var y = 2;
+ var z = 3;
+ proto.x = 4;
+
+ Object.setPrototypeOf(object, proto);
+ object.y = 5;
+
+ with (object) {
+ assertEquals(4, x);
+ assertEquals(5, y);
+ assertEquals(3, z);
+ }
+
+ proto[Symbol.unscopables] = {x: true};
+ with (object) {
+ assertEquals(1, x);
+ assertEquals(5, y);
+ assertEquals(3, z);
+ }
+
+ object[Symbol.unscopables] = {y: true};
+ with (object) {
+ assertEquals(4, x);
+ assertEquals(2, y);
+ assertEquals(3, z);
+ }
+
+ proto[Symbol.unscopables] = {y: true};
+ object[Symbol.unscopables] = {x: true};
+ with (object) {
+ assertEquals(1, x);
+ assertEquals(5, y);
+ assertEquals(3, z);
+ }
+}
+runTest(TestOnProto);
+
+
+function TestSetBlockedOnProto(object, proto) {
+ var x = 1;
+ object.x = 2;
+
+ with (object) {
+ assertEquals(2, x);
+ }
+
+ Object.setPrototypeOf(object, proto);
+ proto[Symbol.unscopables] = {x: true};
+ with (object) {
+ assertEquals(1, x);
+ x = 3;
+ assertEquals(3, x);
+ }
+
+ assertEquals(3, x);
+ assertEquals(2, object.x);
+}
+runTest(TestSetBlockedOnProto);
+
+
+function TestNonObject(object) {
+ var x = 1;
+ var y = 2;
+ object.x = 3;
+ object.y = 4;
+
+ object[Symbol.unscopables] = 'xy';
+ with (object) {
+ assertEquals(3, x);
+ assertEquals(4, y);
+ }
+
+ object[Symbol.unscopables] = null;
+ with (object) {
+ assertEquals(3, x);
+ assertEquals(4, y);
+ }
+}
+runTest(TestNonObject);
+
+
+function TestChangeDuringWith(object) {
+ var x = 1;
+ var y = 2;
+ object.x = 3;
+ object.y = 4;
+
+ with (object) {
+ assertEquals(3, x);
+ assertEquals(4, y);
+ object[Symbol.unscopables] = {x: true};
+ assertEquals(1, x);
+ assertEquals(4, y);
+ }
+}
+runTest(TestChangeDuringWith);
+
+
+function TestChangeDuringWithWithPossibleOptimization(object) {
+ var x = 1;
+ object.x = 2;
+ with (object) {
+ for (var i = 0; i < 1000; i++) {
+ if (i === 500) object[Symbol.unscopables] = {x: true};
+ assertEquals(i < 500 ? 2: 1, x);
+ }
+ }
+}
+TestChangeDuringWithWithPossibleOptimization({});
+
+
+function TestChangeDuringWithWithPossibleOptimization2(object) {
+ var x = 1;
+ object.x = 2;
+ object[Symbol.unscopables] = {x: true};
+ with (object) {
+ for (var i = 0; i < 1000; i++) {
+ if (i === 500) delete object[Symbol.unscopables];
+ assertEquals(i < 500 ? 1 : 2, x);
+ }
+ }
+}
+TestChangeDuringWithWithPossibleOptimization2({});
+
+
+function TestChangeDuringWithWithPossibleOptimization3(object) {
+ var x = 1;
+ object.x = 2;
+ object[Symbol.unscopables] = {};
+ with (object) {
+ for (var i = 0; i < 1000; i++) {
+ if (i === 500) object[Symbol.unscopables].x = true;
+ assertEquals(i < 500 ? 2 : 1, x);
+ }
+ }
+}
+TestChangeDuringWithWithPossibleOptimization3({});
+
+
+function TestChangeDuringWithWithPossibleOptimization4(object) {
+ var x = 1;
+ object.x = 2;
+ object[Symbol.unscopables] = {x: true};
+ with (object) {
+ for (var i = 0; i < 1000; i++) {
+ if (i === 500) delete object[Symbol.unscopables].x;
+ assertEquals(i < 500 ? 1 : 2, x);
+ }
+ }
+}
+TestChangeDuringWithWithPossibleOptimization4({});
+
+
+function TestAccessorReceiver(object, proto) {
+ var x = 'local';
+
+ Object.defineProperty(proto, 'x', {
+ get: function() {
+ assertEquals(object, this);
+ return this.x_;
+ },
+ configurable: true
+ });
+ proto.x_ = 'proto';
+
+ Object.setPrototypeOf(object, proto);
+ proto.x_ = 'object';
+
+ with (object) {
+ assertEquals('object', x);
+ }
+}
+runTest(TestAccessorReceiver);
+
+
+function TestUnscopablesGetter(object) {
+ // This test gets really messy when object is the global since the assert
+ // functions are properties on the global object and the call count gets
+ // completely different.
+ if (object === global) return;
+
+ var x = 'local';
+ object.x = 'object';
+
+ var callCount = 0;
+ Object.defineProperty(object, Symbol.unscopables, {
+ get: function() {
+ callCount++;
+ return {};
+ },
+ configurable: true
+ });
+ with (object) {
+ assertEquals('object', x);
+ }
+ // Once for HasBinding
+ assertEquals(1, callCount);
+
+ callCount = 0;
+ Object.defineProperty(object, Symbol.unscopables, {
+ get: function() {
+ callCount++;
+ return {x: true};
+ },
+ configurable: true
+ });
+ with (object) {
+ assertEquals('local', x);
+ }
+ // Once for HasBinding
+ assertEquals(1, callCount);
+
+ callCount = 0;
+ Object.defineProperty(object, Symbol.unscopables, {
+ get: function() {
+ callCount++;
+ return callCount == 1 ? {} : {x: true};
+ },
+ configurable: true
+ });
+ with (object) {
+ x = 1;
+ }
+ // Once for HasBinding
+ assertEquals(1, callCount);
+ assertEquals(1, object.x);
+ assertEquals('local', x);
+ with (object) {
+ x = 2;
+ }
+ // One more HasBinding.
+ assertEquals(2, callCount);
+ assertEquals(1, object.x);
+ assertEquals(2, x);
+}
+runTest(TestUnscopablesGetter);
+
+
+var global = this;
+function TestUnscopablesGetter2() {
+ var x = 'local';
+
+ var globalProto = Object.getPrototypeOf(global);
+ var protos = [{}, [], function() {}, global];
+ var objects = [{}, [], function() {}];
+
+ protos.forEach(function(proto) {
+ objects.forEach(function(object) {
+ Object.defineProperty(proto, 'x', {
+ get: function() {
+ assertEquals(object, this);
+ return 'proto';
+ },
+ configurable: true
+ });
+
+ object.__proto__ = proto;
+ Object.defineProperty(object, 'x', {
+ get: function() {
+ assertEquals(object, this);
+ return 'object';
+ },
+ configurable: true
+ });
+
+ with (object) {
+ assertEquals('object', x);
+ }
+
+ object[Symbol.unscopables] = {x: true};
+ with (object) {
+ assertEquals('local', x);
+ }
+
+ delete proto[Symbol.unscopables];
+ delete object[Symbol.unscopables];
+ });
+ });
+
+ delete global.x;
+ Object.setPrototypeOf(global, globalProto);
+}
+TestUnscopablesGetter2();
+
+
+function TestSetterOnBlacklisted(object, proto) {
+ var x = 'local';
+ Object.defineProperty(proto, 'x', {
+ set: function(x) {
+ assertUnreachable();
+ },
+ get: function() {
+ return 'proto';
+ },
+ configurable: true
+ });
+ Object.setPrototypeOf(object, proto);
+ Object.defineProperty(object, 'x', {
+ get: function() {
+ return this.x_;
+ },
+ set: function(x) {
+ this.x_ = x;
+ },
+ configurable: true
+ });
+ object.x_ = 1;
+
+ with (object) {
+ x = 2;
+ assertEquals(2, x);
+ }
+
+ assertEquals(2, object.x);
+
+ object[Symbol.unscopables] = {x: true};
+
+ with (object) {
+ x = 3;
+ assertEquals(3, x);
+ }
+
+ assertEquals(2, object.x);
+}
+runTest(TestSetterOnBlacklisted);
+
+
+function TestObjectsAsUnscopables(object, unscopables) {
+ var x = 1;
+ object.x = 2;
+
+ with (object) {
+ assertEquals(2, x);
+ object[Symbol.unscopables] = unscopables;
+ assertEquals(2, x);
+ }
+}
+runTest(TestObjectsAsUnscopables);
+
+
+function TestAccessorOnUnscopables(object) {
+ var x = 1;
+ object.x = 2;
+
+ var unscopables = {
+ get x() {
+ assertUnreachable();
+ }
+ };
+
+ with (object) {
+ assertEquals(2, x);
+ object[Symbol.unscopables] = unscopables;
+ assertEquals(1, x);
+ }
+}
+runTest(TestAccessorOnUnscopables);
+
+
+function TestLengthUnscopables(object, proto) {
+ var length = 2;
+ with (object) {
+ assertEquals(1, length);
+ object[Symbol.unscopables] = {length: true};
+ assertEquals(2, length);
+ delete object[Symbol.unscopables];
+ assertEquals(1, length);
+ }
+}
+TestLengthUnscopables([1], Array.prototype);
+TestLengthUnscopables(function(x) {}, Function.prototype);
+TestLengthUnscopables(new String('x'), String.prototype);
+
+
+function TestFunctionNameUnscopables(object) {
+ var name = 'local';
+ with (object) {
+ assertEquals('f', name);
+ object[Symbol.unscopables] = {name: true};
+ assertEquals('local', name);
+ delete object[Symbol.unscopables];
+ assertEquals('f', name);
+ }
+}
+TestFunctionNameUnscopables(function f() {});
+
+
+function TestFunctionPrototypeUnscopables() {
+ var prototype = 'local';
+ var f = function() {};
+ var g = function() {};
+ Object.setPrototypeOf(f, g);
+ var fp = f.prototype;
+ var gp = g.prototype;
+ with (f) {
+ assertEquals(fp, prototype);
+ f[Symbol.unscopables] = {prototype: true};
+ assertEquals('local', prototype);
+ delete f[Symbol.unscopables];
+ assertEquals(fp, prototype);
+ }
+}
+TestFunctionPrototypeUnscopables(function() {});
+
+
+function TestFunctionArgumentsUnscopables() {
+ var func = function() {
+ var arguments = 'local';
+ var args = func.arguments;
+ with (func) {
+ assertEquals(args, arguments);
+ func[Symbol.unscopables] = {arguments: true};
+ assertEquals('local', arguments);
+ delete func[Symbol.unscopables];
+ assertEquals(args, arguments);
+ }
+ }
+ func(1);
+}
+TestFunctionArgumentsUnscopables();
+
+
+function TestArgumentsLengthUnscopables() {
+ var func = function() {
+ var length = 'local';
+ with (arguments) {
+ assertEquals(1, length);
+ arguments[Symbol.unscopables] = {length: true};
+ assertEquals('local', length);
+ }
+ }
+ func(1);
+}
+TestArgumentsLengthUnscopables();
+
+
+function TestFunctionCallerUnscopables() {
+ var func = function() {
+ var caller = 'local';
+ with (func) {
+ assertEquals(TestFunctionCallerUnscopables, caller);
+ func[Symbol.unscopables] = {caller: true};
+ assertEquals('local', caller);
+ delete func[Symbol.unscopables];
+ assertEquals(TestFunctionCallerUnscopables, caller);
+ }
+ }
+ func(1);
+}
+TestFunctionCallerUnscopables();
+
+
+function TestGetUnscopablesGetterThrows() {
+ var object = {
+ get x() {
+ assertUnreachable();
+ }
+ };
+ function CustomError() {}
+ Object.defineProperty(object, Symbol.unscopables, {
+ get: function() {
+ throw new CustomError();
+ }
+ });
+ assertThrows(function() {
+ with (object) {
+ x;
+ }
+ }, CustomError);
+}
+TestGetUnscopablesGetterThrows();
diff --git a/deps/v8/test/mjsunit/es6/weak_collections.js b/deps/v8/test/mjsunit/es6/weak_collections.js
deleted file mode 100644
index 74235e7d2c..0000000000
--- a/deps/v8/test/mjsunit/es6/weak_collections.js
+++ /dev/null
@@ -1,333 +0,0 @@
-// Copyright 2012 the V8 project authors. All rights reserved.
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following
-// disclaimer in the documentation and/or other materials provided
-// with the distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived
-// from this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-// Flags: --expose-gc --allow-natives-syntax
-
-
-// Note: this test is superseded by harmony/collections.js.
-// IF YOU CHANGE THIS FILE, apply the same changes to harmony/collections.js!
-// TODO(rossberg): Remove once non-weak collections have caught up.
-
-// Test valid getter and setter calls on WeakSets.
-function TestValidSetCalls(m) {
- assertDoesNotThrow(function () { m.add(new Object) });
- assertDoesNotThrow(function () { m.has(new Object) });
- assertDoesNotThrow(function () { m.delete(new Object) });
-}
-TestValidSetCalls(new WeakSet);
-
-
-// Test valid getter and setter calls on WeakMaps
-function TestValidMapCalls(m) {
- assertDoesNotThrow(function () { m.get(new Object) });
- assertDoesNotThrow(function () { m.set(new Object) });
- assertDoesNotThrow(function () { m.has(new Object) });
- assertDoesNotThrow(function () { m.delete(new Object) });
-}
-TestValidMapCalls(new WeakMap);
-
-
-// Test invalid getter and setter calls for WeakMap
-function TestInvalidCalls(m) {
- assertThrows(function () { m.get(undefined) }, TypeError);
- assertThrows(function () { m.set(undefined, 0) }, TypeError);
- assertThrows(function () { m.get(null) }, TypeError);
- assertThrows(function () { m.set(null, 0) }, TypeError);
- assertThrows(function () { m.get(0) }, TypeError);
- assertThrows(function () { m.set(0, 0) }, TypeError);
- assertThrows(function () { m.get('a-key') }, TypeError);
- assertThrows(function () { m.set('a-key', 0) }, TypeError);
-}
-TestInvalidCalls(new WeakMap);
-
-
-// Test expected behavior for WeakSets
-function TestSet(set, key) {
- assertFalse(set.has(key));
- assertSame(undefined, set.add(key));
- assertTrue(set.has(key));
- assertTrue(set.delete(key));
- assertFalse(set.has(key));
- assertFalse(set.delete(key));
- assertFalse(set.has(key));
-}
-function TestSetBehavior(set) {
- for (var i = 0; i < 20; i++) {
- TestSet(set, new Object);
- TestSet(set, i);
- TestSet(set, i / 100);
- TestSet(set, 'key-' + i);
- }
- var keys = [ +0, -0, +Infinity, -Infinity, true, false, null, undefined ];
- for (var i = 0; i < keys.length; i++) {
- TestSet(set, keys[i]);
- }
-}
-TestSet(new WeakSet, new Object);
-
-
-// Test expected mapping behavior for WeakMaps
-function TestMapping(map, key, value) {
- assertSame(undefined, map.set(key, value));
- assertSame(value, map.get(key));
-}
-function TestMapBehavior1(m) {
- TestMapping(m, new Object, 23);
- TestMapping(m, new Object, 'the-value');
- TestMapping(m, new Object, new Object);
-}
-TestMapBehavior1(new WeakMap);
-
-
-// Test expected querying behavior of WeakMaps
-function TestQuery(m) {
- var key = new Object;
- var values = [ 'x', 0, +Infinity, -Infinity, true, false, null, undefined ];
- for (var i = 0; i < values.length; i++) {
- TestMapping(m, key, values[i]);
- assertTrue(m.has(key));
- assertFalse(m.has(new Object));
- }
-}
-TestQuery(new WeakMap);
-
-
-// Test expected deletion behavior of WeakMaps
-function TestDelete(m) {
- var key = new Object;
- TestMapping(m, key, 'to-be-deleted');
- assertTrue(m.delete(key));
- assertFalse(m.delete(key));
- assertFalse(m.delete(new Object));
- assertSame(m.get(key), undefined);
-}
-TestDelete(new WeakMap);
-
-
-// Test GC of WeakMaps with entry
-function TestGC1(m) {
- var key = new Object;
- m.set(key, 'not-collected');
- gc();
- assertSame('not-collected', m.get(key));
-}
-TestGC1(new WeakMap);
-
-
-// Test GC of WeakMaps with chained entries
-function TestGC2(m) {
- var head = new Object;
- for (key = head, i = 0; i < 10; i++, key = m.get(key)) {
- m.set(key, new Object);
- }
- gc();
- var count = 0;
- for (key = head; key != undefined; key = m.get(key)) {
- count++;
- }
- assertEquals(11, count);
-}
-TestGC2(new WeakMap);
-
-
-// Test property attribute [[Enumerable]]
-function TestEnumerable(func) {
- function props(x) {
- var array = [];
- for (var p in x) array.push(p);
- return array.sort();
- }
- assertArrayEquals([], props(func));
- assertArrayEquals([], props(func.prototype));
- assertArrayEquals([], props(new func()));
-}
-TestEnumerable(WeakMap);
-TestEnumerable(WeakSet);
-
-
-// Test arbitrary properties on WeakMaps
-function TestArbitrary(m) {
- function TestProperty(map, property, value) {
- map[property] = value;
- assertEquals(value, map[property]);
- }
- for (var i = 0; i < 20; i++) {
- TestProperty(m, i, 'val' + i);
- TestProperty(m, 'foo' + i, 'bar' + i);
- }
- TestMapping(m, new Object, 'foobar');
-}
-TestArbitrary(new WeakMap);
-
-
-// Test direct constructor call
-assertThrows(function() { WeakMap(); }, TypeError);
-assertThrows(function() { WeakSet(); }, TypeError);
-
-
-// Test some common JavaScript idioms for WeakMaps
-var m = new WeakMap;
-assertTrue(m instanceof WeakMap);
-assertTrue(WeakMap.prototype.set instanceof Function)
-assertTrue(WeakMap.prototype.get instanceof Function)
-assertTrue(WeakMap.prototype.has instanceof Function)
-assertTrue(WeakMap.prototype.delete instanceof Function)
-assertTrue(WeakMap.prototype.clear instanceof Function)
-
-
-// Test some common JavaScript idioms for WeakSets
-var s = new WeakSet;
-assertTrue(s instanceof WeakSet);
-assertTrue(WeakSet.prototype.add instanceof Function)
-assertTrue(WeakSet.prototype.has instanceof Function)
-assertTrue(WeakSet.prototype.delete instanceof Function)
-assertTrue(WeakSet.prototype.clear instanceof Function)
-
-
-// Test class of instance and prototype.
-assertEquals("WeakMap", %_ClassOf(new WeakMap))
-assertEquals("Object", %_ClassOf(WeakMap.prototype))
-assertEquals("WeakSet", %_ClassOf(new WeakSet))
-assertEquals("Object", %_ClassOf(WeakMap.prototype))
-
-
-// Test name of constructor.
-assertEquals("WeakMap", WeakMap.name);
-assertEquals("WeakSet", WeakSet.name);
-
-
-// Test prototype property of WeakMap and WeakSet.
-function TestPrototype(C) {
- assertTrue(C.prototype instanceof Object);
- assertEquals({
- value: {},
- writable: false,
- enumerable: false,
- configurable: false
- }, Object.getOwnPropertyDescriptor(C, "prototype"));
-}
-TestPrototype(WeakMap);
-TestPrototype(WeakSet);
-
-
-// Test constructor property of the WeakMap and WeakSet prototype.
-function TestConstructor(C) {
- assertFalse(C === Object.prototype.constructor);
- assertSame(C, C.prototype.constructor);
- assertSame(C, (new C).__proto__.constructor);
-}
-TestConstructor(WeakMap);
-TestConstructor(WeakSet);
-
-
-// Test the WeakMap and WeakSet global properties themselves.
-function TestDescriptor(global, C) {
- assertEquals({
- value: C,
- writable: true,
- enumerable: false,
- configurable: true
- }, Object.getOwnPropertyDescriptor(global, C.name));
-}
-TestDescriptor(this, WeakMap);
-TestDescriptor(this, WeakSet);
-
-
-// Regression test for WeakMap prototype.
-assertTrue(WeakMap.prototype.constructor === WeakMap)
-assertTrue(Object.getPrototypeOf(WeakMap.prototype) === Object.prototype)
-
-
-// Regression test for issue 1617: The prototype of the WeakMap constructor
-// needs to be unique (i.e. different from the one of the Object constructor).
-assertFalse(WeakMap.prototype === Object.prototype);
-var o = Object.create({});
-assertFalse("get" in o);
-assertFalse("set" in o);
-assertEquals(undefined, o.get);
-assertEquals(undefined, o.set);
-var o = Object.create({}, { myValue: {
- value: 10,
- enumerable: false,
- configurable: true,
- writable: true
-}});
-assertEquals(10, o.myValue);
-
-
-// Regression test for issue 1884: Invoking any of the methods for Harmony
-// maps, sets, or weak maps, with a wrong type of receiver should be throwing
-// a proper TypeError.
-var alwaysBogus = [ undefined, null, true, "x", 23, {} ];
-var bogusReceiversTestSet = [
- { proto: WeakMap.prototype,
- funcs: [ 'get', 'set', 'has', 'delete' ],
- receivers: alwaysBogus.concat([ new WeakSet ]),
- },
- { proto: WeakSet.prototype,
- funcs: [ 'add', 'has', 'delete' ],
- receivers: alwaysBogus.concat([ new WeakMap ]),
- },
-];
-function TestBogusReceivers(testSet) {
- for (var i = 0; i < testSet.length; i++) {
- var proto = testSet[i].proto;
- var funcs = testSet[i].funcs;
- var receivers = testSet[i].receivers;
- for (var j = 0; j < funcs.length; j++) {
- var func = proto[funcs[j]];
- for (var k = 0; k < receivers.length; k++) {
- assertThrows(function () { func.call(receivers[k], {}) }, TypeError);
- }
- }
- }
-}
-TestBogusReceivers(bogusReceiversTestSet);
-
-
-// Test WeakMap clear
-(function() {
- var k = new Object();
- var w = new WeakMap();
- w.set(k, 23);
- assertTrue(w.has(k));
- assertEquals(23, w.get(k));
- w.clear();
- assertFalse(w.has(k));
- assertEquals(undefined, w.get(k));
-})();
-
-
-// Test WeakSet clear
-(function() {
- var k = new Object();
- var w = new WeakSet();
- w.add(k);
- assertTrue(w.has(k));
- w.clear();
- assertFalse(w.has(k));
-})();
diff --git a/deps/v8/test/mjsunit/es7/object-observe-debug-event.js b/deps/v8/test/mjsunit/es7/object-observe-debug-event.js
new file mode 100644
index 0000000000..ed627642cc
--- /dev/null
+++ b/deps/v8/test/mjsunit/es7/object-observe-debug-event.js
@@ -0,0 +1,51 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+Debug = debug.Debug;
+
+var base_id = -1;
+var exception = null;
+var expected = [
+ "enqueue #1",
+ "willHandle #1",
+ "didHandle #1",
+];
+
+function assertLog(msg) {
+ print(msg);
+ assertTrue(expected.length > 0);
+ assertEquals(expected.shift(), msg);
+ if (!expected.length) {
+ Debug.setListener(null);
+ }
+}
+
+function listener(event, exec_state, event_data, data) {
+ if (event != Debug.DebugEvent.AsyncTaskEvent) return;
+ try {
+ if (base_id < 0)
+ base_id = event_data.id();
+ var id = event_data.id() - base_id + 1;
+ assertEquals("Object.observe", event_data.name());
+ assertLog(event_data.type() + " #" + id);
+ } catch (e) {
+ print(e + e.stack)
+ exception = e;
+ }
+}
+
+Debug.setListener(listener);
+
+var obj = {};
+Object.observe(obj, function(changes) {
+ print(change.type + " " + change.name + " " + change.oldValue);
+});
+
+obj.foo = 1;
+obj.zoo = 2;
+obj.foo = 3;
+
+assertNull(exception);
diff --git a/deps/v8/test/mjsunit/es7/object-observe-runtime.js b/deps/v8/test/mjsunit/es7/object-observe-runtime.js
new file mode 100644
index 0000000000..769cd1b296
--- /dev/null
+++ b/deps/v8/test/mjsunit/es7/object-observe-runtime.js
@@ -0,0 +1,18 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+// These tests are meant to ensure that that the Object.observe runtime
+// functions are hardened.
+
+var obj = {};
+%SetIsObserved(obj);
+assertThrows(function() {
+ %SetIsObserved(obj);
+});
+
+assertThrows(function() {
+ %SetIsObserved(this);
+});
diff --git a/deps/v8/test/mjsunit/es7/object-observe.js b/deps/v8/test/mjsunit/es7/object-observe.js
index 7bb579f0c1..5af205eadf 100644
--- a/deps/v8/test/mjsunit/es7/object-observe.js
+++ b/deps/v8/test/mjsunit/es7/object-observe.js
@@ -25,8 +25,8 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-proxies --harmony-collections
-// Flags: --harmony-symbols --allow-natives-syntax
+// Flags: --harmony-proxies
+// Flags: --allow-natives-syntax
var allObservers = [];
function reset() {
@@ -1234,8 +1234,9 @@ observer2.assertCallbackRecords([
// Updating length on large (slow) array
reset();
-var slow_arr = new Array(1000000000);
+var slow_arr = %NormalizeElements([]);
slow_arr[500000000] = 'hello';
+slow_arr.length = 1000000000;
Object.observe(slow_arr, observer.callback);
var spliceRecords;
function slowSpliceCallback(records) {
@@ -1685,8 +1686,10 @@ var obj = { __proto__: fun };
Object.observe(obj, observer.callback);
obj.prototype = 7;
Object.deliverChangeRecords(observer.callback);
-observer.assertNotCalled();
-
+observer.assertRecordCount(1);
+observer.assertCallbackRecords([
+ { object: obj, name: 'prototype', type: 'add' },
+]);
// Check that changes in observation status are detected in all IC states and
// in optimized code, especially in cases usually using fast elements.
diff --git a/deps/v8/test/mjsunit/fast-non-keyed.js b/deps/v8/test/mjsunit/fast-non-keyed.js
index c2f7fc7f96..6a300ab1e3 100644
--- a/deps/v8/test/mjsunit/fast-non-keyed.js
+++ b/deps/v8/test/mjsunit/fast-non-keyed.js
@@ -108,6 +108,6 @@ var obj3 = {};
AddProps3(obj3);
assertTrue(%HasFastProperties(obj3));
-var bad_name = {};
-bad_name[".foo"] = 0;
-assertFalse(%HasFastProperties(bad_name));
+var funny_name = {};
+funny_name[".foo"] = 0;
+assertTrue(%HasFastProperties(funny_name));
diff --git a/deps/v8/test/mjsunit/fast-prototype.js b/deps/v8/test/mjsunit/fast-prototype.js
index cdcc1a9ed6..98647612f6 100644
--- a/deps/v8/test/mjsunit/fast-prototype.js
+++ b/deps/v8/test/mjsunit/fast-prototype.js
@@ -50,6 +50,8 @@ function DoProtoMagic(proto, set__proto__) {
(new Sub()).__proto__ = proto;
} else {
Sub.prototype = proto;
+ // Need to instantiate Sub to mark .prototype as prototype.
+ new Sub();
}
}
@@ -72,10 +74,15 @@ function test(use_new, add_first, set__proto__, same_map_as) {
// Still fast
assertTrue(%HasFastProperties(proto));
AddProps(proto);
- // After we add all those properties it went slow mode again :-(
- assertFalse(%HasFastProperties(proto));
+ if (set__proto__) {
+ // After we add all those properties it went slow mode again :-(
+ assertFalse(%HasFastProperties(proto));
+ } else {
+ // .prototype keeps it fast.
+ assertTrue(%HasFastProperties(proto));
+ }
}
- if (same_map_as && !add_first) {
+ if (same_map_as && !add_first && set__proto__) {
assertTrue(%HaveSameMap(same_map_as, proto));
}
return proto;
diff --git a/deps/v8/test/mjsunit/global-const-var-conflicts.js b/deps/v8/test/mjsunit/global-const-var-conflicts.js
index 2fca96f9f8..3b87e3d7be 100644
--- a/deps/v8/test/mjsunit/global-const-var-conflicts.js
+++ b/deps/v8/test/mjsunit/global-const-var-conflicts.js
@@ -41,17 +41,20 @@ try { eval("var b"); } catch (e) { caught++; assertTrue(e instanceof TypeError);
assertEquals(0, b);
try { eval("var b = 1"); } catch (e) { caught++; assertTrue(e instanceof TypeError); }
assertEquals(0, b);
+assertEquals(0, caught);
eval("var c");
try { eval("const c"); } catch (e) { caught++; assertTrue(e instanceof TypeError); }
assertTrue(typeof c == 'undefined');
+assertEquals(1, caught);
try { eval("const c = 1"); } catch (e) { caught++; assertTrue(e instanceof TypeError); }
-assertEquals(1, c);
+assertEquals(undefined, c);
+assertEquals(2, caught);
eval("var d = 0");
try { eval("const d"); } catch (e) { caught++; assertTrue(e instanceof TypeError); }
-assertEquals(undefined, d);
+assertEquals(0, d);
+assertEquals(3, caught);
try { eval("const d = 1"); } catch (e) { caught++; assertTrue(e instanceof TypeError); }
-assertEquals(1, d);
-
-assertEquals(0, caught);
+assertEquals(0, d);
+assertEquals(4, caught);
diff --git a/deps/v8/test/mjsunit/harmony/array-fill.js b/deps/v8/test/mjsunit/harmony/array-fill.js
index 571233f6fa..eae18d113b 100644
--- a/deps/v8/test/mjsunit/harmony/array-fill.js
+++ b/deps/v8/test/mjsunit/harmony/array-fill.js
@@ -4,7 +4,7 @@
// Flags: --harmony-arrays
-assertEquals(1, Array.prototype.find.length);
+assertEquals(1, Array.prototype.fill.length);
assertArrayEquals([].fill(8), []);
assertArrayEquals([0, 0, 0, 0, 0].fill(), [undefined, undefined, undefined, undefined, undefined]);
@@ -22,7 +22,7 @@ assertArrayEquals([0, 0, 0, 0, 0].fill(8, -1, -3), [0, 0, 0, 0, 0]);
assertArrayEquals([0, 0, 0, 0, 0].fill(8, undefined, 4), [8, 8, 8, 8, 0]);
assertArrayEquals([ , , , , 0].fill(8, 1, 3), [, 8, 8, , 0]);
-// If the range if empty, the array is not actually modified and
+// If the range is empty, the array is not actually modified and
// should not throw, even when applied to a frozen object.
assertArrayEquals(Object.freeze([1, 2, 3]).fill(0, 0, 0), [1, 2, 3]);
diff --git a/deps/v8/test/mjsunit/harmony/arrow-functions.js b/deps/v8/test/mjsunit/harmony/arrow-functions.js
new file mode 100644
index 0000000000..22b1c94f7f
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/arrow-functions.js
@@ -0,0 +1,48 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-arrow-functions
+
+// Arrow functions are like functions, except they throw when using the
+// "new" operator on them.
+assertEquals("function", typeof (() => {}));
+assertEquals(Function.prototype, Object.getPrototypeOf(() => {}));
+assertThrows("new (() => {})", TypeError);
+
+// Check the different syntax variations
+assertEquals(1, (() => 1)());
+assertEquals(2, (a => a + 1)(1));
+assertEquals(3, (() => { return 3; })());
+assertEquals(4, (a => { return a + 3; })(1));
+assertEquals(5, ((a, b) => a + b)(1, 4));
+assertEquals(6, ((a, b) => { return a + b; })(1, 5));
+
+// The following are tests from:
+// http://wiki.ecmascript.org/doku.php?id=harmony:arrow_function_syntax
+
+// Empty arrow function returns undefined
+var empty = () => {};
+assertEquals(undefined, empty());
+
+// Single parameter case needs no parentheses around parameter list
+var identity = x => x;
+assertEquals(empty, identity(empty));
+
+// No need for parentheses even for lower-precedence expression body
+var square = x => x * x;
+assertEquals(9, square(3));
+
+// Parenthesize the body to return an object literal expression
+var key_maker = val => ({key: val});
+assertEquals(empty, key_maker(empty).key);
+
+// Statement body needs braces, must use 'return' explicitly if not void
+var evens = [0, 2, 4, 6, 8];
+assertEquals([1, 3, 5, 7, 9], evens.map(v => v + 1));
+
+var fives = [];
+[1, 2, 3, 4, 5, 6, 7, 8, 9, 10].forEach(v => {
+ if (v % 5 === 0) fives.push(v);
+});
+assertEquals([5, 10], fives);
diff --git a/deps/v8/test/mjsunit/harmony/block-conflicts.js b/deps/v8/test/mjsunit/harmony/block-conflicts.js
index 3aa9d22223..1eedb682aa 100644
--- a/deps/v8/test/mjsunit/harmony/block-conflicts.js
+++ b/deps/v8/test/mjsunit/harmony/block-conflicts.js
@@ -29,7 +29,6 @@
// Test for conflicting variable bindings.
-// TODO(ES6): properly activate extended mode
"use strict";
function CheckException(e) {
@@ -40,9 +39,18 @@ function CheckException(e) {
}
+function TestGlobal(s,e) {
+ try {
+ return eval(s + e);
+ } catch (x) {
+ return CheckException(x);
+ }
+}
+
+
function TestFunction(s,e) {
try {
- return eval("(function(){" + s + ";return " + e + "})")();
+ return eval("(function(){" + s + " return " + e + "})")();
} catch (x) {
return CheckException(x);
}
@@ -51,7 +59,7 @@ function TestFunction(s,e) {
function TestBlock(s,e) {
try {
- return eval("(function(){ if (true) { " + s + "; }; return " + e + "})")();
+ return eval("(function(){ {" + s + "} return " + e + "})")();
} catch (x) {
return CheckException(x);
}
@@ -60,76 +68,123 @@ function TestBlock(s,e) {
function TestAll(expected,s,opt_e) {
var e = "";
var msg = s;
- if (opt_e) { e = opt_e; msg += "; " + opt_e; }
- assertEquals(expected, TestFunction(s,e), "function:'" + msg + "'");
- assertEquals(expected, TestBlock(s,e), "block:'" + msg + "'");
+ if (opt_e) { e = opt_e; msg += opt_e; }
+ assertEquals(expected === 'LocalConflict' ? 'NoConflict' : expected,
+ TestGlobal(s,e), "global:'" + msg + "'");
+ assertEquals(expected === 'LocalConflict' ? 'NoConflict' : expected,
+ TestFunction(s,e), "function:'" + msg + "'");
+ assertEquals(expected === 'LocalConflict' ? 'Conflict' : expected,
+ TestBlock(s,e), "block:'" + msg + "'");
}
function TestConflict(s) {
TestAll('Conflict', s);
- TestAll('Conflict', 'eval("' + s + '")');
+ TestAll('Conflict', 'eval("' + s + '");');
}
-
function TestNoConflict(s) {
TestAll('NoConflict', s, "'NoConflict'");
- TestAll('NoConflict', 'eval("' + s + '")', "'NoConflict'");
+ TestAll('NoConflict', 'eval("' + s + '");', "'NoConflict'");
}
-var letbinds = [ "let x",
- "let x = 0",
- "let x = undefined",
- "function x() { }",
- "let x = function() {}",
- "let x, y",
- "let y, x",
- "const x = 0",
- "const x = undefined",
- "const x = function() {}",
- "const x = 2, y = 3",
- "const y = 4, x = 5",
+function TestLocalConflict(s) {
+ TestAll('LocalConflict', s, "'NoConflict'");
+ TestAll('NoConflict', 'eval("' + s + '");', "'NoConflict'");
+}
+
+var letbinds = [ "let x;",
+ "let x = 0;",
+ "let x = undefined;",
+ "let x = function() {};",
+ "let x, y;",
+ "let y, x;",
+ "const x = 0;",
+ "const x = undefined;",
+ "const x = function() {};",
+ "const x = 2, y = 3;",
+ "const y = 4, x = 5;",
];
-var varbinds = [ "var x",
- "var x = 0",
- "var x = undefined",
- "var x = function() {}",
- "var x, y",
- "var y, x",
+var varbinds = [ "var x;",
+ "var x = 0;",
+ "var x = undefined;",
+ "var x = function() {};",
+ "var x, y;",
+ "var y, x;",
];
-
+var funbind = "function x() {}";
for (var l = 0; l < letbinds.length; ++l) {
// Test conflicting let/var bindings.
for (var v = 0; v < varbinds.length; ++v) {
// Same level.
- TestConflict(letbinds[l] +'; ' + varbinds[v]);
- TestConflict(varbinds[v] +'; ' + letbinds[l]);
+ TestConflict(letbinds[l] + varbinds[v]);
+ TestConflict(varbinds[v] + letbinds[l]);
// Different level.
- TestConflict(letbinds[l] +'; {' + varbinds[v] + '; }');
- TestConflict('{ ' + varbinds[v] +'; }' + letbinds[l]);
+ TestConflict(letbinds[l] + '{' + varbinds[v] + '}');
+ TestConflict('{' + varbinds[v] +'}' + letbinds[l]);
+ TestNoConflict(varbinds[v] + '{' + letbinds[l] + '}');
+ TestNoConflict('{' + letbinds[l] + '}' + varbinds[v]);
+ // For loop.
+ TestConflict('for (' + letbinds[l] + '0;) {' + varbinds[v] + '}');
+ TestNoConflict('for (' + varbinds[v] + '0;) {' + letbinds[l] + '}');
}
// Test conflicting let/let bindings.
for (var k = 0; k < letbinds.length; ++k) {
// Same level.
- TestConflict(letbinds[l] +'; ' + letbinds[k]);
- TestConflict(letbinds[k] +'; ' + letbinds[l]);
+ TestConflict(letbinds[l] + letbinds[k]);
+ TestConflict(letbinds[k] + letbinds[l]);
// Different level.
- TestNoConflict(letbinds[l] +'; { ' + letbinds[k] + '; }');
- TestNoConflict('{ ' + letbinds[k] +'; } ' + letbinds[l]);
+ TestNoConflict(letbinds[l] + '{ ' + letbinds[k] + '}');
+ TestNoConflict('{' + letbinds[k] +'} ' + letbinds[l]);
+ // For loop.
+ TestNoConflict('for (' + letbinds[l] + '0;) {' + letbinds[k] + '}');
+ TestNoConflict('for (' + letbinds[k] + '0;) {' + letbinds[l] + '}');
}
+ // Test conflicting function/let bindings.
+ // Same level.
+ TestConflict(letbinds[l] + funbind);
+ TestConflict(funbind + letbinds[l]);
+ // Different level.
+ TestNoConflict(letbinds[l] + '{' + funbind + '}');
+ TestNoConflict('{' + funbind + '}' + letbinds[l]);
+ TestNoConflict(funbind + '{' + letbinds[l] + '}');
+ TestNoConflict('{' + letbinds[l] + '}' + funbind);
+ // For loop.
+ TestNoConflict('for (' + letbinds[l] + '0;) {' + funbind + '}');
+
// Test conflicting parameter/let bindings.
- TestConflict('(function (x) { ' + letbinds[l] + '; })()');
+ TestConflict('(function(x) {' + letbinds[l] + '})();');
+}
+
+// Test conflicting function/var bindings.
+for (var v = 0; v < varbinds.length; ++v) {
+ // Same level.
+ TestLocalConflict(varbinds[v] + funbind);
+ TestLocalConflict(funbind + varbinds[v]);
+ // Different level.
+ TestLocalConflict(funbind + '{' + varbinds[v] + '}');
+ TestLocalConflict('{' + varbinds[v] +'}' + funbind);
+ TestNoConflict(varbinds[v] + '{' + funbind + '}');
+ TestNoConflict('{' + funbind + '}' + varbinds[v]);
+ // For loop.
+ TestNoConflict('for (' + varbinds[v] + '0;) {' + funbind + '}');
}
// Test conflicting catch/var bindings.
for (var v = 0; v < varbinds.length; ++v) {
- TestConflict('try {} catch (x) { ' + varbinds[v] + '; }');
+ TestConflict('try {} catch(x) {' + varbinds[v] + '}');
}
// Test conflicting parameter/var bindings.
for (var v = 0; v < varbinds.length; ++v) {
- TestNoConflict('(function (x) { ' + varbinds[v] + '; })()');
+ TestNoConflict('(function (x) {' + varbinds[v] + '})();');
}
+
+// Test conflicting catch/function bindings.
+TestNoConflict('try {} catch(x) {' + funbind + '}');
+
+// Test conflicting parameter/function bindings.
+TestNoConflict('(function (x) {' + funbind + '})();');
diff --git a/deps/v8/test/mjsunit/harmony/block-const-assign.js b/deps/v8/test/mjsunit/harmony/block-const-assign.js
index 8297a558a4..b71729e8a2 100644
--- a/deps/v8/test/mjsunit/harmony/block-const-assign.js
+++ b/deps/v8/test/mjsunit/harmony/block-const-assign.js
@@ -30,9 +30,8 @@
// Test that we throw early syntax errors in harmony mode
// when using an immutable binding in an assigment or with
// prefix/postfix decrement/increment operators.
-// TODO(ES6): properly activate extended mode
-"use strict";
+"use strict";
// Function local const.
function constDecl0(use) {
diff --git a/deps/v8/test/mjsunit/harmony/block-early-errors.js b/deps/v8/test/mjsunit/harmony/block-early-errors.js
index 791f001af0..8ed5ea84ec 100644
--- a/deps/v8/test/mjsunit/harmony/block-early-errors.js
+++ b/deps/v8/test/mjsunit/harmony/block-early-errors.js
@@ -30,7 +30,6 @@
function CheckException(e) {
var string = e.toString();
assertInstanceof(e, SyntaxError);
- assertTrue(string.indexOf("Illegal let") >= 0);
}
function Check(str) {
@@ -49,7 +48,7 @@ function Check(str) {
}
// Check for early syntax errors when using let
-// declarations outside of extended mode.
+// declarations outside of strict mode.
Check("let x;");
Check("let x = 1;");
Check("let x, y;");
diff --git a/deps/v8/test/mjsunit/harmony/block-for.js b/deps/v8/test/mjsunit/harmony/block-for.js
index e84f0d2fee..110f1ccf45 100644
--- a/deps/v8/test/mjsunit/harmony/block-for.js
+++ b/deps/v8/test/mjsunit/harmony/block-for.js
@@ -27,7 +27,6 @@
// Flags: --harmony-scoping
-// TODO(ES6): properly activate extended mode
"use strict";
function props(x) {
@@ -93,7 +92,6 @@ assertEquals('ab', result);
// Check that there is exactly one variable without initializer
// in a for-in statement with let variables.
-// TODO(ES6): properly activate extended mode
assertThrows("function foo() { 'use strict'; for (let in {}) { } }", SyntaxError);
assertThrows("function foo() { 'use strict'; for (let x = 3 in {}) { } }", SyntaxError);
assertThrows("function foo() { 'use strict'; for (let x, y in {}) { } }", SyntaxError);
@@ -102,7 +100,7 @@ assertThrows("function foo() { 'use strict'; for (let x, y = 4 in {}) { } }", Sy
assertThrows("function foo() { 'use strict'; for (let x = 3, y = 4 in {}) { } }", SyntaxError);
-// In a normal for statement the iteration variable is not
+// In a normal for statement the iteration variable is
// freshly allocated for each iteration.
function closures1() {
let a = [];
@@ -110,7 +108,7 @@ function closures1() {
a.push(function () { return i; });
}
for (let j = 0; j < 5; ++j) {
- assertEquals(5, a[j]());
+ assertEquals(j, a[j]());
}
}
closures1();
@@ -123,13 +121,45 @@ function closures2() {
b.push(function () { return j; });
}
for (let k = 0; k < 5; ++k) {
- assertEquals(5, a[k]());
- assertEquals(15, b[k]());
+ assertEquals(k, a[k]());
+ assertEquals(k + 10, b[k]());
}
}
closures2();
+function closure_in_for_init() {
+ let a = [];
+ for (let i = 0, f = function() { return i }; i < 5; ++i) {
+ a.push(f);
+ }
+ for (let k = 0; k < 5; ++k) {
+ assertEquals(0, a[k]());
+ }
+}
+closure_in_for_init();
+
+
+function closure_in_for_cond() {
+ let a = [];
+ for (let i = 0; a.push(function () { return i; }), i < 5; ++i) { }
+ for (let k = 0; k < 5; ++k) {
+ assertEquals(k, a[k]());
+ }
+}
+closure_in_for_next();
+
+
+function closure_in_for_next() {
+ let a = [];
+ for (let i = 0; i < 5; a.push(function () { return i; }), ++i) { }
+ for (let k = 0; k < 5; ++k) {
+ assertEquals(k + 1, a[k]());
+ }
+}
+closure_in_for_next();
+
+
// In a for-in statement the iteration variable is fresh
// for earch iteration.
function closures3(x) {
diff --git a/deps/v8/test/mjsunit/harmony/block-leave.js b/deps/v8/test/mjsunit/harmony/block-leave.js
index a7f6b69475..87d35b396d 100644
--- a/deps/v8/test/mjsunit/harmony/block-leave.js
+++ b/deps/v8/test/mjsunit/harmony/block-leave.js
@@ -27,7 +27,6 @@
// Flags: --harmony-scoping
-// TODO(ES6): properly activate extended mode
"use strict";
// We want to test the context chain shape. In each of the tests cases
diff --git a/deps/v8/test/mjsunit/harmony/block-let-crankshaft.js b/deps/v8/test/mjsunit/harmony/block-let-crankshaft.js
index 5888fd24f5..e8e00b200e 100644
--- a/deps/v8/test/mjsunit/harmony/block-let-crankshaft.js
+++ b/deps/v8/test/mjsunit/harmony/block-let-crankshaft.js
@@ -27,12 +27,12 @@
// Flags: --harmony-scoping --allow-natives-syntax
-// TODO(ES6): properly activate extended mode
"use strict";
// Check that the following functions are optimizable.
var functions = [ f1, f2, f3, f4, f5, f6, f7, f8, f9, f10, f11, f12, f13, f14,
- f15, f16, f17, f18, f19, f20, f21, f22, f23 ];
+ f15, f16, f17, f18, f19, f20, f21, f22, f23, f24, f25, f26,
+ f27, f28, f29, f30, f31, f32, f33];
for (var i = 0; i < functions.length; ++i) {
var func = functions[i];
@@ -156,6 +156,184 @@ function f23() {
(function() { x; });
}
+function f24() {
+ let x = 1;
+ {
+ let x = 2;
+ {
+ let x = 3;
+ assertEquals(3, x);
+ }
+ assertEquals(2, x);
+ }
+ assertEquals(1, x);
+}
+
+function f25() {
+ {
+ let x = 2;
+ L: {
+ let x = 3;
+ assertEquals(3, x);
+ break L;
+ assertTrue(false);
+ }
+ assertEquals(2, x);
+ }
+ assertTrue(true);
+}
+
+function f26() {
+ {
+ let x = 1;
+ L: {
+ let x = 2;
+ {
+ let x = 3;
+ assertEquals(3, x);
+ break L;
+ assertTrue(false);
+ }
+ assertTrue(false);
+ }
+ assertEquals(1, x);
+ }
+}
+
+
+function f27() {
+ do {
+ let x = 4;
+ assertEquals(4,x);
+ {
+ let x = 5;
+ assertEquals(5, x);
+ continue;
+ assertTrue(false);
+ }
+ } while (false);
+}
+
+function f28() {
+ label: for (var i = 0; i < 10; ++i) {
+ let x = 'middle' + i;
+ for (var j = 0; j < 10; ++j) {
+ let x = 'inner' + j;
+ continue label;
+ }
+ }
+}
+
+function f29() {
+ // Verify that the context is correctly set in the stack frame after exiting
+ // from with.
+
+ let x = 'outer';
+ label: {
+ let x = 'inner';
+ break label;
+ }
+ f(); // The context could be restored from the stack after the call.
+ assertEquals('outer', x);
+
+ function f() {
+ assertEquals('outer', x);
+ };
+}
+
+function f30() {
+ let x = 'outer';
+ for (var i = 0; i < 10; ++i) {
+ let x = 'inner';
+ continue;
+ }
+ f();
+ assertEquals('outer', x);
+
+ function f() {
+ assertEquals('outer', x);
+ };
+}
+
+function f31() {
+ {
+ let x = 'outer';
+ label: for (var i = 0; assertEquals('outer', x), i < 10; ++i) {
+ let x = 'middle' + i;
+ {
+ let x = 'inner' + j;
+ continue label;
+ }
+ }
+ assertEquals('outer', x);
+ }
+}
+
+var c = true;
+
+function f32() {
+ {
+ let x = 'outer';
+ L: {
+ {
+ let x = 'inner';
+ if (c) {
+ break L;
+ }
+ }
+ foo();
+ }
+ }
+
+ function foo() {
+ return 'bar';
+ }
+}
+
+function f33() {
+ {
+ let x = 'outer';
+ L: {
+ {
+ let x = 'inner';
+ if (c) {
+ break L;
+ }
+ foo();
+ }
+ }
+ }
+
+ function foo() {
+ return 'bar';
+ }
+}
+
+function TestThrow() {
+ function f() {
+ let x = 'outer';
+ {
+ let x = 'inner';
+ throw x;
+ }
+ }
+ for (var i = 0; i < 5; i++) {
+ try {
+ f();
+ } catch (e) {
+ assertEquals('inner', e);
+ }
+ }
+ %OptimizeFunctionOnNextCall(f);
+ try {
+ f();
+ } catch (e) {
+ assertEquals('inner', e);
+ }
+ assertOptimized(f);
+}
+
+TestThrow();
// Test that temporal dead zone semantics for function and block scoped
// let bindings are handled by the optimizing compiler.
@@ -208,9 +386,59 @@ function TestFunctionContext(s) {
}
}
+function TestBlockLocal(s) {
+ 'use strict';
+ var func = eval("(function baz(){ { " + s + "; } })");
+ print("Testing:");
+ print(func);
+ for (var i = 0; i < 5; ++i) {
+ try {
+ func();
+ assertUnreachable();
+ } catch (e) {
+ assertInstanceof(e, ReferenceError);
+ }
+ }
+ %OptimizeFunctionOnNextCall(func);
+ try {
+ func();
+ assertUnreachable();
+ } catch (e) {
+ assertInstanceof(e, ReferenceError);
+ }
+}
+
+function TestBlockContext(s) {
+ 'use strict';
+ var func = eval("(function baz(){ { " + s + "; (function() { x; }); } })");
+ print("Testing:");
+ print(func);
+ for (var i = 0; i < 5; ++i) {
+ print(i);
+ try {
+ func();
+ assertUnreachable();
+ } catch (e) {
+ assertInstanceof(e, ReferenceError);
+ }
+ }
+ print("optimize");
+ %OptimizeFunctionOnNextCall(func);
+ try {
+ print("call");
+ func();
+ assertUnreachable();
+ } catch (e) {
+ print("catch");
+ assertInstanceof(e, ReferenceError);
+ }
+}
+
function TestAll(s) {
TestFunctionLocal(s);
TestFunctionContext(s);
+ TestBlockLocal(s);
+ TestBlockContext(s);
}
// Use before initialization in declaration statement.
@@ -229,34 +457,28 @@ TestAll('x++; let x;');
TestAll('let y = x; const x = 1;');
-function f(x, b) {
- let y = (b ? y : x) + 42;
+function f(x) {
+ let y = x + 42;
return y;
}
-function g(x, b) {
+function g(x) {
{
- let y = (b ? y : x) + 42;
+ let y = x + 42;
return y;
}
}
for (var i=0; i<10; i++) {
- f(i, false);
- g(i, false);
+ f(i);
+ g(i);
}
%OptimizeFunctionOnNextCall(f);
%OptimizeFunctionOnNextCall(g);
-try {
- f(42, true);
-} catch (e) {
- assertInstanceof(e, ReferenceError);
-}
+f(12);
+g(12);
-try {
- g(42, true);
-} catch (e) {
- assertInstanceof(e, ReferenceError);
-}
+assertTrue(%GetOptimizationStatus(f) != 2);
+assertTrue(%GetOptimizationStatus(g) != 2);
diff --git a/deps/v8/test/mjsunit/harmony/block-let-declaration.js b/deps/v8/test/mjsunit/harmony/block-let-declaration.js
index 4ddeefdbaa..44a0049a44 100644
--- a/deps/v8/test/mjsunit/harmony/block-let-declaration.js
+++ b/deps/v8/test/mjsunit/harmony/block-let-declaration.js
@@ -28,7 +28,7 @@
// Flags: --harmony-scoping
// Test let declarations in various settings.
-// TODO(ES6): properly activate extended mode
+
"use strict";
// Global
@@ -56,11 +56,11 @@ if (true) {
// an exception in eval code during parsing, before even compiling or executing
// the code. Thus the generated function is not called here.
function TestLocalThrows(str, expect) {
- assertThrows("(function(){ 'use strict'; " + str + "})", expect);
+ assertThrows("(function(arg){ 'use strict'; " + str + "})", expect);
}
function TestLocalDoesNotThrow(str) {
- assertDoesNotThrow("(function(){ 'use strict'; " + str + "})()");
+ assertDoesNotThrow("(function(arg){ 'use strict'; " + str + "})()");
}
// Test let declarations in statement positions.
@@ -108,6 +108,28 @@ TestLocalDoesNotThrow("for (;false;) var x;");
TestLocalDoesNotThrow("switch (true) { case true: var x; }");
TestLocalDoesNotThrow("switch (true) { default: var x; }");
+// Test that redeclarations of functions are only allowed in outermost scope.
+TestLocalThrows("{ let f; var f; }");
+TestLocalThrows("{ var f; let f; }");
+TestLocalThrows("{ function f() {} let f; }");
+TestLocalThrows("{ let f; function f() {} }");
+TestLocalThrows("{ function f() {} var f; }");
+TestLocalThrows("{ var f; function f() {} }");
+TestLocalThrows("{ function f() {} function f() {} }");
+TestLocalThrows("function f() {} let f;");
+TestLocalThrows("let f; function f() {}");
+TestLocalDoesNotThrow("function arg() {}");
+TestLocalDoesNotThrow("function f() {} var f;");
+TestLocalDoesNotThrow("var f; function f() {}");
+TestLocalDoesNotThrow("function f() {} function f() {}");
+
+function g(f) {
+ function f() { return 1 }
+ return f()
+}
+assertEquals(1, g(function() { return 2 }))
+
+
// Test function declarations in source element and
// sloppy statement positions.
function f() {
diff --git a/deps/v8/test/mjsunit/harmony/block-let-semantics.js b/deps/v8/test/mjsunit/harmony/block-let-semantics.js
index d14e7cd369..a37b795b0a 100644
--- a/deps/v8/test/mjsunit/harmony/block-let-semantics.js
+++ b/deps/v8/test/mjsunit/harmony/block-let-semantics.js
@@ -27,7 +27,6 @@
// Flags: --harmony-scoping
-// TODO(ES6): properly activate extended mode
"use strict";
// Test temporal dead zone semantics of let bound variables in
diff --git a/deps/v8/test/mjsunit/harmony/block-scoping.js b/deps/v8/test/mjsunit/harmony/block-scoping.js
index 31194d99fd..001d9fbfd5 100644
--- a/deps/v8/test/mjsunit/harmony/block-scoping.js
+++ b/deps/v8/test/mjsunit/harmony/block-scoping.js
@@ -28,7 +28,6 @@
// Flags: --allow-natives-syntax --harmony-scoping
// Test functionality of block scopes.
-// TODO(ES6): properly activate extended mode
"use strict";
// Hoisting of var declarations.
@@ -40,8 +39,10 @@ function f1() {
assertEquals(1, x)
assertEquals(undefined, y)
}
+for (var j = 0; j < 5; ++j) f1();
+%OptimizeFunctionOnNextCall(f1);
f1();
-
+assertTrue(%GetOptimizationStatus(f1) != 2);
// Dynamic lookup in and through block contexts.
function f2(one) {
@@ -59,8 +60,8 @@ function f2(one) {
assertEquals(6, eval('v'));
}
}
-f2(1);
+f2(1);
// Lookup in and through block contexts.
function f3(one) {
@@ -76,10 +77,13 @@ function f3(one) {
assertEquals(4, z);
assertEquals(5, u);
assertEquals(6, v);
-
}
}
+for (var j = 0; j < 5; ++j) f3(1);
+%OptimizeFunctionOnNextCall(f3);
f3(1);
+assertTrue(%GetOptimizationStatus(f3) != 2);
+
// Dynamic lookup from closure.
diff --git a/deps/v8/test/mjsunit/harmony/debug-blockscopes.js b/deps/v8/test/mjsunit/harmony/debug-blockscopes.js
index f56a306b6f..2db49427cc 100644
--- a/deps/v8/test/mjsunit/harmony/debug-blockscopes.js
+++ b/deps/v8/test/mjsunit/harmony/debug-blockscopes.js
@@ -29,7 +29,6 @@
// The functions used for testing backtraces. They are at the top to make the
// testing of source line/column easier.
-// TODO(ES6): properly activate extended mode
"use strict";
// Get the Debug object exposed from the debug context global object.
@@ -412,10 +411,12 @@ function for_loop_3() {
listener_delegate = function(exec_state) {
CheckScopeChain([debug.ScopeType.Block,
+ debug.ScopeType.Block,
debug.ScopeType.Local,
debug.ScopeType.Global], exec_state);
CheckScopeContent({x:3}, 0, exec_state);
- CheckScopeContent({}, 1, exec_state);
+ CheckScopeContent({x:3}, 1, exec_state);
+ CheckScopeContent({}, 2, exec_state);
};
for_loop_3();
EndTest();
@@ -434,11 +435,13 @@ function for_loop_4() {
listener_delegate = function(exec_state) {
CheckScopeChain([debug.ScopeType.Block,
debug.ScopeType.Block,
+ debug.ScopeType.Block,
debug.ScopeType.Local,
debug.ScopeType.Global], exec_state);
CheckScopeContent({x:5}, 0, exec_state);
CheckScopeContent({x:3}, 1, exec_state);
- CheckScopeContent({}, 2, exec_state);
+ CheckScopeContent({x:3}, 2, exec_state);
+ CheckScopeContent({}, 3, exec_state);
};
for_loop_4();
EndTest();
@@ -455,10 +458,12 @@ function for_loop_5() {
listener_delegate = function(exec_state) {
CheckScopeChain([debug.ScopeType.Block,
+ debug.ScopeType.Block,
debug.ScopeType.Local,
debug.ScopeType.Global], exec_state);
CheckScopeContent({x:3,y:5}, 0, exec_state);
- CheckScopeContent({}, 1, exec_state);
+ CheckScopeContent({x:3,y:5}, 1, exec_state);
+ CheckScopeContent({}, 2, exec_state);
};
for_loop_5();
EndTest();
diff --git a/deps/v8/test/mjsunit/harmony/debug-evaluate-blockscopes.js b/deps/v8/test/mjsunit/harmony/debug-evaluate-blockscopes.js
index d6ce8b2b6a..16885d009e 100644
--- a/deps/v8/test/mjsunit/harmony/debug-evaluate-blockscopes.js
+++ b/deps/v8/test/mjsunit/harmony/debug-evaluate-blockscopes.js
@@ -30,7 +30,6 @@
// Test debug evaluation for functions without local context, but with
// nested catch contexts.
-// TODO(ES6): properly activate extended mode
"use strict";
var x;
diff --git a/deps/v8/test/mjsunit/harmony/empty-for.js b/deps/v8/test/mjsunit/harmony/empty-for.js
new file mode 100644
index 0000000000..02211260ff
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/empty-for.js
@@ -0,0 +1,72 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are
+// met:
+//
+// * Redistributions of source code must retain the above copyright
+// notice, this list of conditions and the following disclaimer.
+// * Redistributions in binary form must reproduce the above
+// copyright notice, this list of conditions and the following
+// disclaimer in the documentation and/or other materials provided
+// with the distribution.
+// * Neither the name of Google Inc. nor the names of its
+// contributors may be used to endorse or promote products derived
+// from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+// Flags: --harmony-scoping
+
+"use strict";
+
+function for_const() {
+ for (const x = 1;;) {
+ if (x == 1) break;
+ }
+ for (const x = 1; x < 2;) {
+ if (x == 1) break;
+ }
+ for (const x = 1;; 0) {
+ if (x == 1) break;
+ }
+}
+
+for_const();
+
+function for_let() {
+ for (let x;;) {
+ if (!x) break;
+ }
+ for (let x; x < 2;) {
+ if (!x) break;
+ }
+ for (let x = 1;; x++) {
+ if (x == 2) break;
+ }
+}
+
+for_let();
+
+function for_var() {
+ for (var x;;) {
+ if (!x) break;
+ }
+ for (var x; x < 2;) {
+ if (!x) break;
+ }
+ for (var x = 1;; x++) {
+ if (x == 2) break;
+ }
+}
+
+for_var();
diff --git a/deps/v8/test/mjsunit/harmony/generators-debug-liveedit.js b/deps/v8/test/mjsunit/harmony/generators-debug-liveedit.js
new file mode 100644
index 0000000000..341ef483c5
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/generators-debug-liveedit.js
@@ -0,0 +1,119 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug --harmony-generators
+
+var Debug = debug.Debug;
+var LiveEdit = Debug.LiveEdit;
+
+unique_id = 0;
+
+var Generator = (function*(){}).constructor;
+
+function assertIteratorResult(value, done, result) {
+ assertEquals({value: value, done: done}, result);
+}
+
+function MakeGenerator() {
+ // Prevents eval script caching.
+ unique_id++;
+ return Generator('callback',
+ "/* " + unique_id + "*/\n" +
+ "yield callback();\n" +
+ "return 'Cat';\n");
+}
+
+function MakeFunction() {
+ // Prevents eval script caching.
+ unique_id++;
+ return Function('callback',
+ "/* " + unique_id + "*/\n" +
+ "callback();\n" +
+ "return 'Cat';\n");
+}
+
+// First, try MakeGenerator with no perturbations.
+(function(){
+ var generator = MakeGenerator();
+ function callback() {};
+ var iter = generator(callback);
+ assertIteratorResult(undefined, false, iter.next());
+ assertIteratorResult("Cat", true, iter.next());
+})();
+
+function patch(fun, from, to) {
+ function debug() {
+ var log = new Array();
+ var script = Debug.findScript(fun);
+ var pos = script.source.indexOf(from);
+ try {
+ LiveEdit.TestApi.ApplySingleChunkPatch(script, pos, from.length, to,
+ log);
+ } finally {
+ print("Change log: " + JSON.stringify(log) + "\n");
+ }
+ }
+ Debug.ExecuteInDebugContext(debug, false);
+}
+
+// Try to edit a MakeGenerator while it's running, then again while it's
+// stopped.
+(function(){
+ var generator = MakeGenerator();
+
+ var gen_patch_attempted = false;
+ function attempt_gen_patch() {
+ assertFalse(gen_patch_attempted);
+ gen_patch_attempted = true;
+ assertThrows(function() { patch(generator, "'Cat'", "'Capybara'") },
+ LiveEdit.Failure);
+ };
+ var iter = generator(attempt_gen_patch);
+ assertIteratorResult(undefined, false, iter.next());
+ // Patch should not succeed because there is a live generator activation on
+ // the stack.
+ assertIteratorResult("Cat", true, iter.next());
+ assertTrue(gen_patch_attempted);
+
+ // At this point one iterator is live, but closed, so the patch will succeed.
+ patch(generator, "'Cat'", "'Capybara'");
+ iter = generator(function(){});
+ assertIteratorResult(undefined, false, iter.next());
+ // Patch successful.
+ assertIteratorResult("Capybara", true, iter.next());
+
+ // Patching will fail however when a live iterator is suspended.
+ iter = generator(function(){});
+ assertIteratorResult(undefined, false, iter.next());
+ assertThrows(function() { patch(generator, "'Capybara'", "'Tapir'") },
+ LiveEdit.Failure);
+ assertIteratorResult("Capybara", true, iter.next());
+
+ // Try to patch functions with activations inside and outside generator
+ // function activations. We should succeed in the former case, but not in the
+ // latter.
+ var fun_outside = MakeFunction();
+ var fun_inside = MakeFunction();
+ var fun_patch_attempted = false;
+ var fun_patch_restarted = false;
+ function attempt_fun_patches() {
+ if (fun_patch_attempted) {
+ assertFalse(fun_patch_restarted);
+ fun_patch_restarted = true;
+ return;
+ }
+ fun_patch_attempted = true;
+ // Patching outside a generator activation must fail.
+ assertThrows(function() { patch(fun_outside, "'Cat'", "'Cobra'") },
+ LiveEdit.Failure);
+ // Patching inside a generator activation may succeed.
+ patch(fun_inside, "'Cat'", "'Koala'");
+ }
+ iter = generator(function() { return fun_inside(attempt_fun_patches) });
+ assertEquals('Cat',
+ fun_outside(function () {
+ assertIteratorResult('Koala', false, iter.next());
+ assertTrue(fun_patch_restarted);
+ }));
+})();
diff --git a/deps/v8/test/mjsunit/harmony/generators-iteration.js b/deps/v8/test/mjsunit/harmony/generators-iteration.js
index d86a20f9e7..1a793678d9 100644
--- a/deps/v8/test/mjsunit/harmony/generators-iteration.js
+++ b/deps/v8/test/mjsunit/harmony/generators-iteration.js
@@ -337,6 +337,50 @@ TestGenerator(
"foo",
[2, "1foo3", 5, "4foo6", "foofoo"]);
+// Yield with no arguments yields undefined.
+TestGenerator(
+ function* g26() { return yield yield },
+ [undefined, undefined, undefined],
+ "foo",
+ [undefined, "foo", "foo"]);
+
+// A newline causes the parser to stop looking for an argument to yield.
+TestGenerator(
+ function* g27() {
+ yield
+ 3
+ return
+ },
+ [undefined, undefined],
+ "foo",
+ [undefined, undefined]);
+
+// TODO(wingo): We should use TestGenerator for these, except that
+// currently yield* will unconditionally propagate a throw() to the
+// delegate iterator, which fails for these iterators that don't have
+// throw(). See http://code.google.com/p/v8/issues/detail?id=3484.
+(function() {
+ function* g28() {
+ yield* [1, 2, 3];
+ }
+ var iter = g28();
+ assertIteratorResult(1, false, iter.next());
+ assertIteratorResult(2, false, iter.next());
+ assertIteratorResult(3, false, iter.next());
+ assertIteratorResult(undefined, true, iter.next());
+})();
+
+(function() {
+ function* g29() {
+ yield* "abc";
+ }
+ var iter = g29();
+ assertIteratorResult("a", false, iter.next());
+ assertIteratorResult("b", false, iter.next());
+ assertIteratorResult("c", false, iter.next());
+ assertIteratorResult(undefined, true, iter.next());
+})();
+
// Generator function instances.
TestGenerator(GeneratorFunction(),
[undefined],
@@ -375,12 +419,16 @@ function TestDelegatingYield() {
function next() {
return results[i++];
}
- return { next: next }
+ var iter = { next: next };
+ var ret = {};
+ ret[Symbol.iterator] = function() { return iter; };
+ return ret;
}
function* yield_results(expected) {
return yield* results(expected);
}
- function collect_results(iter) {
+ function collect_results(iterable) {
+ var iter = iterable[Symbol.iterator]();
var ret = [];
var result;
do {
diff --git a/deps/v8/test/mjsunit/harmony/generators-parsing.js b/deps/v8/test/mjsunit/harmony/generators-parsing.js
index 2a4a68c37c..21790b0e13 100644
--- a/deps/v8/test/mjsunit/harmony/generators-parsing.js
+++ b/deps/v8/test/mjsunit/harmony/generators-parsing.js
@@ -35,6 +35,40 @@ function* g() { yield 3; yield 4; }
// Yield expressions.
function* g() { (yield 3) + (yield 4); }
+// Yield without a RHS.
+function* g() { yield; }
+function* g() { yield }
+function* g() {
+ yield
+}
+function* g() { (yield) }
+function* g() { [yield] }
+function* g() { {yield} }
+function* g() { yield, yield }
+function* g() { yield; yield }
+function* g() { (yield) ? yield : yield }
+function* g() {
+ (yield)
+ ? yield
+ : yield
+}
+
+// If yield has a RHS, it needs to start on the same line. The * in a
+// yield* counts as starting the RHS.
+function* g() {
+ yield *
+ foo
+}
+assertThrows("function* g() { yield\n* foo }", SyntaxError);
+assertEquals(undefined,
+ (function*(){
+ yield
+ 3
+ })().next().value);
+
+// A YieldExpression is not a LogicalORExpression.
+assertThrows("function* g() { yield ? yield : yield }", SyntaxError);
+
// You can have a generator in strict mode.
function* g() { "use strict"; yield 3; yield 4; }
@@ -50,14 +84,10 @@ function* g() { yield 1; return 2; yield "dead"; }
// Named generator expression.
(function* g() { yield 3; });
-// A generator without a yield is specified as causing an early error. This
-// behavior is currently unimplemented. See
-// https://bugs.ecmascript.org/show_bug.cgi?id=1283.
+// You can have a generator without a yield.
function* g() { }
-// A YieldExpression in the RHS of a YieldExpression is currently specified as
-// causing an early error. This behavior is currently unimplemented. See
-// https://bugs.ecmascript.org/show_bug.cgi?id=1283.
+// A YieldExpression is valid as the RHS of a YieldExpression.
function* g() { yield yield 1; }
function* g() { yield 3 + (yield 4); }
@@ -86,9 +116,6 @@ assertThrows("function* g() { yield: 1 }", SyntaxError)
// functions.
function* g() { function f() { yield (yield + yield (0)); } }
-// Yield needs a RHS.
-assertThrows("function* g() { yield; }", SyntaxError);
-
// Yield in a generator is not an identifier.
assertThrows("function* g() { yield = 10; }", SyntaxError);
diff --git a/deps/v8/test/mjsunit/harmony/generators-poisoned-properties.js b/deps/v8/test/mjsunit/harmony/generators-poisoned-properties.js
new file mode 100644
index 0000000000..39a583ec97
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/generators-poisoned-properties.js
@@ -0,0 +1,42 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-generators
+
+function assertIteratorResult(value, done, result) {
+ assertEquals({value: value, done: done}, result);
+}
+
+function test(f) {
+ var cdesc = Object.getOwnPropertyDescriptor(f, "caller");
+ var adesc = Object.getOwnPropertyDescriptor(f, "arguments");
+
+ assertFalse(cdesc.enumerable);
+ assertFalse(cdesc.configurable);
+
+ assertFalse(adesc.enumerable);
+ assertFalse(adesc.configurable);
+
+ assertSame(cdesc.get, cdesc.set);
+ assertSame(cdesc.get, adesc.get);
+ assertSame(cdesc.get, adesc.set);
+
+ assertTrue(cdesc.get instanceof Function);
+ assertEquals(0, cdesc.get.length);
+ assertThrows(cdesc.get, TypeError);
+
+ assertThrows(function() { return f.caller; }, TypeError);
+ assertThrows(function() { f.caller = 42; }, TypeError);
+ assertThrows(function() { return f.arguments; }, TypeError);
+ assertThrows(function() { f.arguments = 42; }, TypeError);
+}
+
+function *sloppy() { test(sloppy); }
+function *strict() { "use strict"; test(strict); }
+
+test(sloppy);
+test(strict);
+
+assertIteratorResult(undefined, true, sloppy().next());
+assertIteratorResult(undefined, true, strict().next());
diff --git a/deps/v8/test/mjsunit/harmony/generators-runtime.js b/deps/v8/test/mjsunit/harmony/generators-runtime.js
index aef063b6c8..9fb7075492 100644
--- a/deps/v8/test/mjsunit/harmony/generators-runtime.js
+++ b/deps/v8/test/mjsunit/harmony/generators-runtime.js
@@ -29,9 +29,8 @@
// Test aspects of the generator runtime.
-// FIXME(wingo): Replace this reference with a more official link.
// See:
-// http://wiki.ecmascript.org/lib/exe/fetch.php?cache=cache&media=harmony:es6_generator_object_model_3-29-13.png
+// http://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorfunction-objects
function f() { }
function* g() { yield 1; }
@@ -55,7 +54,16 @@ function TestGeneratorFunctionInstance() {
var f_desc = Object.getOwnPropertyDescriptor(f, prop);
var g_desc = Object.getOwnPropertyDescriptor(g, prop);
assertEquals(f_desc.configurable, g_desc.configurable, prop);
- assertEquals(f_desc.writable, g_desc.writable, prop);
+ if (prop === 'arguments' || prop === 'caller') {
+ // Unlike sloppy functions, which have read-only data arguments and caller
+ // properties, sloppy generators have a poison pill implemented via
+ // accessors
+ assertFalse('writable' in g_desc, prop);
+ assertTrue(g_desc.get instanceof Function, prop);
+ assertEquals(g_desc.get, g_desc.set, prop);
+ } else {
+ assertEquals(f_desc.writable, g_desc.writable, prop);
+ }
assertEquals(f_desc.enumerable, g_desc.enumerable, prop);
}
}
@@ -92,6 +100,16 @@ function TestGeneratorObjectPrototype() {
found_property_names.sort();
assertArrayEquals(expected_property_names, found_property_names);
+
+ iterator_desc = Object.getOwnPropertyDescriptor(GeneratorObjectPrototype,
+ Symbol.iterator);
+ assertTrue(iterator_desc !== undefined);
+ assertFalse(iterator_desc.writable);
+ assertFalse(iterator_desc.enumerable);
+ assertFalse(iterator_desc.configurable);
+
+ // The generator object's "iterator" function is just the identity.
+ assertSame(iterator_desc.value.call(42), 42);
}
TestGeneratorObjectPrototype();
diff --git a/deps/v8/test/mjsunit/harmony/private.js b/deps/v8/test/mjsunit/harmony/private.js
index 225799831c..4b29fd863e 100644
--- a/deps/v8/test/mjsunit/harmony/private.js
+++ b/deps/v8/test/mjsunit/harmony/private.js
@@ -25,7 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-symbols --harmony-collections
// Flags: --expose-gc --allow-natives-syntax
var symbols = []
@@ -115,8 +114,8 @@ TestToBoolean()
function TestToNumber() {
for (var i in symbols) {
- assertSame(NaN, Number(symbols[i]).valueOf())
- assertSame(NaN, symbols[i] + 0)
+ assertThrows(function() { Number(symbols[i]); }, TypeError);
+ assertThrows(function() { symbols[i] + 0; }, TypeError);
}
}
TestToNumber()
@@ -342,3 +341,18 @@ function TestGetOwnPropertySymbols() {
assertEquals(syms, [publicSymbol, publicSymbol2])
}
TestGetOwnPropertySymbols()
+
+
+function TestSealAndFreeze(freeze) {
+ var sym = %CreatePrivateSymbol("private")
+ var obj = {}
+ obj[sym] = 1
+ freeze(obj)
+ obj[sym] = 2
+ assertEquals(2, obj[sym])
+ assertTrue(delete obj[sym])
+ assertEquals(undefined, obj[sym])
+}
+TestSealAndFreeze(Object.seal)
+TestSealAndFreeze(Object.freeze)
+TestSealAndFreeze(Object.preventExtensions)
diff --git a/deps/v8/test/mjsunit/harmony/proxies-example-membrane.js b/deps/v8/test/mjsunit/harmony/proxies-example-membrane.js
index a645a6603a..7b2af722f2 100644
--- a/deps/v8/test/mjsunit/harmony/proxies-example-membrane.js
+++ b/deps/v8/test/mjsunit/harmony/proxies-example-membrane.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony
+// Flags: --harmony --harmony-proxies
// A simple no-op handler. Adapted from:
diff --git a/deps/v8/test/mjsunit/harmony/proxies-hash.js b/deps/v8/test/mjsunit/harmony/proxies-hash.js
index 789de35f6d..65d2d3c564 100644
--- a/deps/v8/test/mjsunit/harmony/proxies-hash.js
+++ b/deps/v8/test/mjsunit/harmony/proxies-hash.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-proxies --harmony-collections
+// Flags: --harmony-proxies
// Helper.
diff --git a/deps/v8/test/mjsunit/harmony/proxies-json.js b/deps/v8/test/mjsunit/harmony/proxies-json.js
index 539c5a84cb..eba10a1453 100644
--- a/deps/v8/test/mjsunit/harmony/proxies-json.js
+++ b/deps/v8/test/mjsunit/harmony/proxies-json.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony
+// Flags: --harmony-proxies
function testStringify(expected, object) {
// Test fast case that bails out to slow case.
diff --git a/deps/v8/test/mjsunit/harmony/proxies-symbols.js b/deps/v8/test/mjsunit/harmony/proxies-symbols.js
index 8920e39968..52353c036d 100644
--- a/deps/v8/test/mjsunit/harmony/proxies-symbols.js
+++ b/deps/v8/test/mjsunit/harmony/proxies-symbols.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-proxies --harmony-symbols
+// Flags: --harmony-proxies
// Helper.
diff --git a/deps/v8/test/mjsunit/harmony/proxies-with-unscopables.js b/deps/v8/test/mjsunit/harmony/proxies-with-unscopables.js
new file mode 100644
index 0000000000..b982480feb
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/proxies-with-unscopables.js
@@ -0,0 +1,153 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-unscopables
+// Flags: --harmony-proxies
+
+
+// TODO(arv): Once proxies can intercept symbols, add more tests.
+
+
+function TestBasics() {
+ var log = [];
+
+ var proxy = Proxy.create({
+ getPropertyDescriptor: function(key) {
+ log.push(key);
+ if (key === 'x') {
+ return {
+ value: 1,
+ configurable: true
+ };
+ }
+ return undefined;
+ }
+ });
+
+ var x = 'local';
+
+ with (proxy) {
+ assertEquals(1, x);
+ }
+
+ // One 'x' for HasBinding and one for GetBindingValue
+ assertEquals(['assertEquals', 'x', 'x'], log);
+}
+TestBasics();
+
+
+function TestInconsistent() {
+ var log = [];
+ var calls = 0;
+
+ var proxy = Proxy.create({
+ getPropertyDescriptor: function(key) {
+ log.push(key);
+ if (key === 'x' && calls < 1) {
+ calls++;
+ return {
+ value: 1,
+ configurable: true
+ };
+ }
+ return undefined;
+ }
+ });
+
+ var x = 'local';
+
+ with (proxy) {
+ assertEquals(void 0, x);
+ }
+
+ // One 'x' for HasBinding and one for GetBindingValue
+ assertEquals(['assertEquals', 'x', 'x'], log);
+}
+TestInconsistent();
+
+
+function TestUseProxyAsUnscopables() {
+ var x = 1;
+ var object = {
+ x: 2
+ };
+ var calls = 0;
+ var proxy = Proxy.create({
+ has: function(key) {
+ calls++;
+ assertEquals('x', key);
+ return calls === 2;
+ },
+ getPropertyDescriptor: function(key) {
+ assertUnreachable();
+ }
+ });
+
+ object[Symbol.unscopables] = proxy;
+
+ with (object) {
+ assertEquals(2, x);
+ assertEquals(1, x);
+ }
+
+ // HasBinding, HasBinding
+ assertEquals(2, calls);
+}
+TestUseProxyAsUnscopables();
+
+
+function TestThrowInHasUnscopables() {
+ var x = 1;
+ var object = {
+ x: 2
+ };
+
+ function CustomError() {}
+
+ var calls = 0;
+ var proxy = Proxy.create({
+ has: function(key) {
+ if (calls++ === 0) {
+ throw new CustomError();
+ }
+ assertUnreachable();
+ },
+ getPropertyDescriptor: function(key) {
+ assertUnreachable();
+ }
+ });
+
+ object[Symbol.unscopables] = proxy;
+
+ assertThrows(function() {
+ with (object) {
+ x;
+ }
+ }, CustomError);
+}
+TestThrowInHasUnscopables();
+
+
+var global = this;
+function TestGlobalShouldIgnoreUnscopables() {
+ global.x = 1;
+ var proxy = Proxy.create({
+ getPropertyDescriptor: function() {
+ assertUnreachable();
+ }
+ });
+ global[Symbol.unscopables] = proxy;
+
+ assertEquals(1, global.x);
+ assertEquals(1, x);
+
+ global.x = 2;
+ assertEquals(2, global.x);
+ assertEquals(2, x);
+
+ x = 3;
+ assertEquals(3, global.x);
+ assertEquals(3, x);
+}
+TestGlobalShouldIgnoreUnscopables();
diff --git a/deps/v8/test/mjsunit/harmony/proxies.js b/deps/v8/test/mjsunit/harmony/proxies.js
index 00e605f8d2..b082c06696 100644
--- a/deps/v8/test/mjsunit/harmony/proxies.js
+++ b/deps/v8/test/mjsunit/harmony/proxies.js
@@ -1807,7 +1807,7 @@ TestKeysThrow({
},
})
-TestKeysThrow([], {
+TestKeysThrow({
get getOwnPropertyNames() {
return function() { return [1, 2] }
},
diff --git a/deps/v8/test/mjsunit/harmony/regress/regress-3426.js b/deps/v8/test/mjsunit/harmony/regress/regress-3426.js
new file mode 100644
index 0000000000..c3b11a1792
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/regress/regress-3426.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-scoping
+
+assertThrows("(function() { 'use strict'; { let f; var f; } })", SyntaxError);
diff --git a/deps/v8/test/mjsunit/harmony/set-prototype-of.js b/deps/v8/test/mjsunit/harmony/set-prototype-of.js
index 02bd5e2ee6..810220d1a8 100644
--- a/deps/v8/test/mjsunit/harmony/set-prototype-of.js
+++ b/deps/v8/test/mjsunit/harmony/set-prototype-of.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-symbols
-
function getObjects() {
function func() {}
diff --git a/deps/v8/test/mjsunit/harmony/string-codepointat.js b/deps/v8/test/mjsunit/harmony/string-codepointat.js
new file mode 100644
index 0000000000..411b0f23c7
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/string-codepointat.js
@@ -0,0 +1,91 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-strings
+
+// Tests taken from:
+// https://github.com/mathiasbynens/String.prototype.codePointAt
+
+assertEquals(String.prototype.codePointAt.length, 1);
+assertEquals(String.prototype.propertyIsEnumerable("codePointAt"), false);
+
+// String that starts with a BMP symbol
+assertEquals("abc\uD834\uDF06def".codePointAt(""), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt("_"), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(-Infinity), undefined);
+assertEquals("abc\uD834\uDF06def".codePointAt(-1), undefined);
+assertEquals("abc\uD834\uDF06def".codePointAt(-0), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(0), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(3), 0x1D306);
+assertEquals("abc\uD834\uDF06def".codePointAt(4), 0xDF06);
+assertEquals("abc\uD834\uDF06def".codePointAt(5), 0x64);
+assertEquals("abc\uD834\uDF06def".codePointAt(42), undefined);
+assertEquals("abc\uD834\uDF06def".codePointAt(Infinity), undefined);
+assertEquals("abc\uD834\uDF06def".codePointAt(Infinity), undefined);
+assertEquals("abc\uD834\uDF06def".codePointAt(NaN), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(false), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(null), 0x61);
+assertEquals("abc\uD834\uDF06def".codePointAt(undefined), 0x61);
+
+// String that starts with an astral symbol
+assertEquals("\uD834\uDF06def".codePointAt(""), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt("1"), 0xDF06);
+assertEquals("\uD834\uDF06def".codePointAt("_"), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt(), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt(-1), undefined);
+assertEquals("\uD834\uDF06def".codePointAt(-0), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt(0), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt(1), 0xDF06);
+assertEquals("\uD834\uDF06def".codePointAt(42), undefined);
+assertEquals("\uD834\uDF06def".codePointAt(false), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt(null), 0x1D306);
+assertEquals("\uD834\uDF06def".codePointAt(undefined), 0x1D306);
+
+// Lone high surrogates
+assertEquals("\uD834abc".codePointAt(""), 0xD834);
+assertEquals("\uD834abc".codePointAt("_"), 0xD834);
+assertEquals("\uD834abc".codePointAt(), 0xD834);
+assertEquals("\uD834abc".codePointAt(-1), undefined);
+assertEquals("\uD834abc".codePointAt(-0), 0xD834);
+assertEquals("\uD834abc".codePointAt(0), 0xD834);
+assertEquals("\uD834abc".codePointAt(false), 0xD834);
+assertEquals("\uD834abc".codePointAt(NaN), 0xD834);
+assertEquals("\uD834abc".codePointAt(null), 0xD834);
+assertEquals("\uD834abc".codePointAt(undefined), 0xD834);
+
+// Lone low surrogates
+assertEquals("\uDF06abc".codePointAt(""), 0xDF06);
+assertEquals("\uDF06abc".codePointAt("_"), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(-1), undefined);
+assertEquals("\uDF06abc".codePointAt(-0), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(0), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(false), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(NaN), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(null), 0xDF06);
+assertEquals("\uDF06abc".codePointAt(undefined), 0xDF06);
+
+assertThrows(function() {
+ String.prototype.codePointAt.call(undefined);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.codePointAt.call(undefined, 4);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.codePointAt.call(null);
+}, TypeError);
+assertThrows(function() {
+ String.prototype.codePointAt.call(null, 4);
+}, TypeError);
+assertEquals(String.prototype.codePointAt.call(42, 0), 0x34);
+assertEquals(String.prototype.codePointAt.call(42, 1), 0x32);
+assertEquals(String.prototype.codePointAt.call({
+ toString: function() { return "abc"; }
+}, 2), 0x63);
+var tmp = 0;
+assertEquals(String.prototype.codePointAt.call({
+ toString: function() { ++tmp; return String(tmp); }
+}, 0), 0x31);
+assertEquals(tmp, 1);
diff --git a/deps/v8/test/mjsunit/harmony/string-fromcodepoint.js b/deps/v8/test/mjsunit/harmony/string-fromcodepoint.js
new file mode 100644
index 0000000000..97ecf0eec5
--- /dev/null
+++ b/deps/v8/test/mjsunit/harmony/string-fromcodepoint.js
@@ -0,0 +1,62 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-strings
+
+// Tests taken from:
+// https://github.com/mathiasbynens/String.fromCodePoint
+
+assertEquals(String.fromCodePoint.length, 1);
+assertEquals(String.propertyIsEnumerable("fromCodePoint"), false);
+
+assertEquals(String.fromCodePoint(""), "\0");
+assertEquals(String.fromCodePoint(), "");
+assertEquals(String.fromCodePoint(-0), "\0");
+assertEquals(String.fromCodePoint(0), "\0");
+assertEquals(String.fromCodePoint(0x1D306), "\uD834\uDF06");
+assertEquals(
+ String.fromCodePoint(0x1D306, 0x61, 0x1D307),
+ "\uD834\uDF06a\uD834\uDF07");
+assertEquals(String.fromCodePoint(0x61, 0x62, 0x1D307), "ab\uD834\uDF07");
+assertEquals(String.fromCodePoint(false), "\0");
+assertEquals(String.fromCodePoint(null), "\0");
+
+assertThrows(function() { String.fromCodePoint("_"); }, RangeError);
+assertThrows(function() { String.fromCodePoint("+Infinity"); }, RangeError);
+assertThrows(function() { String.fromCodePoint("-Infinity"); }, RangeError);
+assertThrows(function() { String.fromCodePoint(-1); }, RangeError);
+assertThrows(function() { String.fromCodePoint(0x10FFFF + 1); }, RangeError);
+assertThrows(function() { String.fromCodePoint(3.14); }, RangeError);
+assertThrows(function() { String.fromCodePoint(3e-2); }, RangeError);
+assertThrows(function() { String.fromCodePoint(-Infinity); }, RangeError);
+assertThrows(function() { String.fromCodePoint(+Infinity); }, RangeError);
+assertThrows(function() { String.fromCodePoint(NaN); }, RangeError);
+assertThrows(function() { String.fromCodePoint(undefined); }, RangeError);
+assertThrows(function() { String.fromCodePoint({}); }, RangeError);
+assertThrows(function() { String.fromCodePoint(/./); }, RangeError);
+assertThrows(function() { String.fromCodePoint({
+ valueOf: function() { throw Error(); } });
+}, Error);
+assertThrows(function() { String.fromCodePoint({
+ valueOf: function() { throw Error(); } });
+}, Error);
+var tmp = 0x60;
+assertEquals(String.fromCodePoint({
+ valueOf: function() { ++tmp; return tmp; }
+}), "a");
+assertEquals(tmp, 0x61);
+
+var counter = Math.pow(2, 15) * 3 / 2;
+var result = [];
+while (--counter >= 0) {
+ result.push(0); // one code unit per symbol
+}
+String.fromCodePoint.apply(null, result); // must not throw
+
+var counter = Math.pow(2, 15) * 3 / 2;
+var result = [];
+while (--counter >= 0) {
+ result.push(0xFFFF + 1); // two code units per symbol
+}
+String.fromCodePoint.apply(null, result); // must not throw
diff --git a/deps/v8/test/mjsunit/json-stringify-recursive.js b/deps/v8/test/mjsunit/json-stringify-recursive.js
index 31aa0027c5..d2788a5f03 100644
--- a/deps/v8/test/mjsunit/json-stringify-recursive.js
+++ b/deps/v8/test/mjsunit/json-stringify-recursive.js
@@ -25,6 +25,8 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+// Flags: --stack-size=100
+
var a = {};
for (i = 0; i < 10000; i++) {
var current = {};
diff --git a/deps/v8/test/mjsunit/keyed-load-dictionary-stub.js b/deps/v8/test/mjsunit/keyed-load-dictionary-stub.js
new file mode 100644
index 0000000000..733fd6d9c9
--- /dev/null
+++ b/deps/v8/test/mjsunit/keyed-load-dictionary-stub.js
@@ -0,0 +1,20 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function generate_dictionary_array() {
+ var result = [0, 1, 2, 3, 4];
+ result[256 * 1024] = 5;
+ return result;
+}
+
+function get_accessor(a, i) {
+ return a[i];
+}
+
+var array1 = generate_dictionary_array();
+get_accessor(array1, 1);
+get_accessor(array1, 2);
+get_accessor(12345, 2);
diff --git a/deps/v8/test/mjsunit/math-abs.js b/deps/v8/test/mjsunit/math-abs.js
index 09b9c88f75..b90ae0917c 100644
--- a/deps/v8/test/mjsunit/math-abs.js
+++ b/deps/v8/test/mjsunit/math-abs.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
function zero() {
var x = 0.5;
diff --git a/deps/v8/test/mjsunit/math-floor-part1.js b/deps/v8/test/mjsunit/math-floor-part1.js
index bae47dc3cf..65ae3c68e4 100644
--- a/deps/v8/test/mjsunit/math-floor-part1.js
+++ b/deps/v8/test/mjsunit/math-floor-part1.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
var test_id = 0;
diff --git a/deps/v8/test/mjsunit/math-floor-part2.js b/deps/v8/test/mjsunit/math-floor-part2.js
index ad60fba454..60045705ce 100644
--- a/deps/v8/test/mjsunit/math-floor-part2.js
+++ b/deps/v8/test/mjsunit/math-floor-part2.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
var test_id = 0;
diff --git a/deps/v8/test/mjsunit/math-floor-part3.js b/deps/v8/test/mjsunit/math-floor-part3.js
index a6d1c5e856..9225c388ba 100644
--- a/deps/v8/test/mjsunit/math-floor-part3.js
+++ b/deps/v8/test/mjsunit/math-floor-part3.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
var test_id = 0;
diff --git a/deps/v8/test/mjsunit/math-floor-part4.js b/deps/v8/test/mjsunit/math-floor-part4.js
index 58212b4c56..ade36a9c30 100644
--- a/deps/v8/test/mjsunit/math-floor-part4.js
+++ b/deps/v8/test/mjsunit/math-floor-part4.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2 --allow-natives-syntax
+// Flags: --max-semi-space-size=1 --allow-natives-syntax
var test_id = 0;
diff --git a/deps/v8/test/mjsunit/migrations.js b/deps/v8/test/mjsunit/migrations.js
new file mode 100644
index 0000000000..6a2ea64a7a
--- /dev/null
+++ b/deps/v8/test/mjsunit/migrations.js
@@ -0,0 +1,311 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-ayle license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --track-fields --expose-gc
+
+var global = Function('return this')();
+var verbose = 0;
+
+function test(ctor_desc, use_desc, migr_desc) {
+ var n = 5;
+ var objects = [];
+ var results = [];
+
+ if (verbose) {
+ print();
+ print("===========================================================");
+ print("=== " + ctor_desc.name +
+ " | " + use_desc.name + " |--> " + migr_desc.name);
+ print("===========================================================");
+ }
+
+ // Clean ICs and transitions.
+ %NotifyContextDisposed();
+ gc(); gc(); gc();
+
+
+ // create objects
+ if (verbose) {
+ print("-----------------------------");
+ print("--- construct");
+ print();
+ }
+ for (var i = 0; i < n; i++) {
+ objects[i] = ctor_desc.ctor.apply(ctor_desc, ctor_desc.args(i));
+ }
+
+ try {
+ // use them
+ if (verbose) {
+ print("-----------------------------");
+ print("--- use 1");
+ print();
+ }
+ var use = use_desc.use1;
+ for (var i = 0; i < n; i++) {
+ if (i == 3) %OptimizeFunctionOnNextCall(use);
+ results[i] = use(objects[i], i);
+ }
+
+ // trigger migrations
+ if (verbose) {
+ print("-----------------------------");
+ print("--- trigger migration");
+ print();
+ }
+ var migr = migr_desc.migr;
+ for (var i = 0; i < n; i++) {
+ if (i == 3) %OptimizeFunctionOnNextCall(migr);
+ migr(objects[i], i);
+ }
+
+ // use again
+ if (verbose) {
+ print("-----------------------------");
+ print("--- use 2");
+ print();
+ }
+ var use = use_desc.use2 !== undefined ? use_desc.use2 : use_desc.use1;
+ for (var i = 0; i < n; i++) {
+ if (i == 3) %OptimizeFunctionOnNextCall(use);
+ results[i] = use(objects[i], i);
+ if (verbose >= 2) print(results[i]);
+ }
+
+ } catch (e) {
+ if (verbose) print("--- incompatible use: " + e);
+ }
+ return results;
+}
+
+
+var ctors = [
+ {
+ name: "none-to-double",
+ ctor: function(v) { return {a: v}; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "double",
+ ctor: function(v) { var o = {}; o.a = v; return o; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "none-to-smi",
+ ctor: function(v) { return {a: v}; },
+ args: function(i) { return [i]; },
+ },
+ {
+ name: "smi",
+ ctor: function(v) { var o = {}; o.a = v; return o; },
+ args: function(i) { return [i]; },
+ },
+ {
+ name: "none-to-object",
+ ctor: function(v) { return {a: v}; },
+ args: function(i) { return ["s"]; },
+ },
+ {
+ name: "object",
+ ctor: function(v) { var o = {}; o.a = v; return o; },
+ args: function(i) { return ["s"]; },
+ },
+ {
+ name: "{a:, b:, c:}",
+ ctor: function(v1, v2, v3) { return {a: v1, b: v2, c: v3}; },
+ args: function(i) { return [1.5 + i, 1.6, 1.7]; },
+ },
+ {
+ name: "{a..h:}",
+ ctor: function(v) { var o = {}; o.h=o.g=o.f=o.e=o.d=o.c=o.b=o.a=v; return o; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "1",
+ ctor: function(v) { var o = 1; o.a = v; return o; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "f()",
+ ctor: function(v) { var o = function() { return v;}; o.a = v; return o; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "f().bind",
+ ctor: function(v) { var o = function(a,b,c) { return a+b+c; }; o = o.bind(o, v, v+1, v+2.2); return o; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "dictionary elements",
+ ctor: function(v) { var o = []; o[1] = v; o[200000] = v; return o; },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "json",
+ ctor: function(v) { var json = '{"a":' + v + ',"b":' + v + '}'; return JSON.parse(json); },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "fast accessors",
+ accessor: {
+ get: function() { return this.a_; },
+ set: function(value) {this.a_ = value; },
+ configurable: true,
+ },
+ ctor: function(v) {
+ var o = {a_:v};
+ Object.defineProperty(o, "a", this.accessor);
+ return o;
+ },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "slow accessor",
+ accessor1: { value: this.a_, configurable: true },
+ accessor2: {
+ get: function() { return this.a_; },
+ set: function(value) {this.a_ = value; },
+ configurable: true,
+ },
+ ctor: function(v) {
+ var o = {a_:v};
+ Object.defineProperty(o, "a", this.accessor1);
+ Object.defineProperty(o, "a", this.accessor2);
+ return o;
+ },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "slow",
+ proto: {},
+ ctor: function(v) {
+ var o = {__proto__: this.proto};
+ o.a = v;
+ for (var i = 0; %HasFastProperties(o); i++) o["f"+i] = v;
+ return o;
+ },
+ args: function(i) { return [1.5 + i]; },
+ },
+ {
+ name: "global",
+ ctor: function(v) { return global; },
+ args: function(i) { return [i]; },
+ },
+];
+
+
+
+var uses = [
+ {
+ name: "o.a+1.0",
+ use1: function(o, i) { return o.a + 1.0; },
+ use2: function(o, i) { return o.a + 1.1; },
+ },
+ {
+ name: "o.b+1.0",
+ use1: function(o, i) { return o.b + 1.0; },
+ use2: function(o, i) { return o.b + 1.1; },
+ },
+ {
+ name: "o[1]+1.0",
+ use1: function(o, i) { return o[1] + 1.0; },
+ use2: function(o, i) { return o[1] + 1.1; },
+ },
+ {
+ name: "o[-1]+1.0",
+ use1: function(o, i) { return o[-1] + 1.0; },
+ use2: function(o, i) { return o[-1] + 1.1; },
+ },
+ {
+ name: "()",
+ use1: function(o, i) { return o() + 1.0; },
+ use2: function(o, i) { return o() + 1.1; },
+ },
+];
+
+
+
+var migrations = [
+ {
+ name: "to smi",
+ migr: function(o, i) { if (i == 0) o.a = 1; },
+ },
+ {
+ name: "to double",
+ migr: function(o, i) { if (i == 0) o.a = 1.1; },
+ },
+ {
+ name: "to object",
+ migr: function(o, i) { if (i == 0) o.a = {}; },
+ },
+ {
+ name: "set prototype {}",
+ migr: function(o, i) { o.__proto__ = {}; },
+ },
+ {
+ name: "%FunctionSetPrototype",
+ migr: function(o, i) { %FunctionSetPrototype(o, null); },
+ },
+ {
+ name: "modify prototype",
+ migr: function(o, i) { if (i == 0) o.__proto__.__proto1__ = [,,,5,,,]; },
+ },
+ {
+ name: "freeze prototype",
+ migr: function(o, i) { if (i == 0) Object.freeze(o.__proto__); },
+ },
+ {
+ name: "delete and re-add property",
+ migr: function(o, i) { var v = o.a; delete o.a; o.a = v; },
+ },
+ {
+ name: "modify prototype",
+ migr: function(o, i) { if (i >= 0) o.__proto__ = {}; },
+ },
+ {
+ name: "set property callback",
+ migr: function(o, i) {
+ Object.defineProperty(o, "a", {
+ get: function() { return 1.5 + i; },
+ set: function(value) {},
+ configurable: true,
+ });
+ },
+ },
+ {
+ name: "observe",
+ migr: function(o, i) { Object.observe(o, function(){}); },
+ },
+ {
+ name: "%EnableAccessChecks",
+ migr: function(o, i) {
+ if (typeof (o) !== 'function') %EnableAccessChecks(o);
+ },
+ },
+ {
+ name: "%DisableAccessChecks",
+ migr: function(o, i) {
+ if ((typeof (o) !== 'function') && (o !== global)) %DisableAccessChecks(o);
+ },
+ },
+ {
+ name: "seal",
+ migr: function(o, i) { Object.seal(o); },
+ },
+ { // Must be the last in the sequence, because after the global object freeze
+ // the other modifications does not make sence.
+ name: "freeze",
+ migr: function(o, i) { Object.freeze(o); },
+ },
+];
+
+
+
+migrations.forEach(function(migr) {
+ uses.forEach(function(use) {
+ ctors.forEach(function(ctor) {
+ test(ctor, use, migr);
+ });
+ });
+});
diff --git a/deps/v8/test/mjsunit/mirror-object.js b/deps/v8/test/mjsunit/mirror-object.js
index 8bf8a2d4f8..7020338ca2 100644
--- a/deps/v8/test/mjsunit/mirror-object.js
+++ b/deps/v8/test/mjsunit/mirror-object.js
@@ -111,12 +111,14 @@ function testObjectMirror(obj, cls_name, ctor_name, hasSpecialProperties) {
// Check that the serialization contains all properties.
assertEquals(names.length, fromJSON.properties.length, 'Some properties missing in JSON');
- for (var i = 0; i < fromJSON.properties.length; i++) {
- var name = fromJSON.properties[i].name;
- if (typeof name == 'undefined') name = fromJSON.properties[i].index;
+ for (var j = 0; j < names.length; j++) {
+ var name = names[j];
+ // Serialization of symbol-named properties to JSON doesn't really
+ // work currently, as they don't get a {name: ...} entry.
+ if (typeof name === 'symbol') continue;
var found = false;
- for (var j = 0; j < names.length; j++) {
- if (names[j] == name) {
+ for (var i = 0; i < fromJSON.properties.length; i++) {
+ if (fromJSON.properties[i].name == name) {
// Check that serialized handle is correct.
assertEquals(properties[i].value().handle(), fromJSON.properties[i].ref, 'Unexpected serialized handle');
@@ -170,6 +172,9 @@ function Point(x,y) {
this.y_ = y;
}
+var object_with_symbol = {};
+object_with_symbol[Symbol.iterator] = 42;
+
// Test a number of different objects.
testObjectMirror({}, 'Object', 'Object');
testObjectMirror({'a':1,'b':2}, 'Object', 'Object');
@@ -180,6 +185,7 @@ testObjectMirror(this.__proto__, 'Object', '');
testObjectMirror([], 'Array', 'Array');
testObjectMirror([1,2], 'Array', 'Array');
testObjectMirror(Object(17), 'Number', 'Number');
+testObjectMirror(object_with_symbol, 'Object', 'Object');
// Test circular references.
o = {};
diff --git a/deps/v8/test/mjsunit/mirror-script.js b/deps/v8/test/mjsunit/mirror-script.js
index 1d64ac26bf..e545a61637 100644
--- a/deps/v8/test/mjsunit/mirror-script.js
+++ b/deps/v8/test/mjsunit/mirror-script.js
@@ -84,7 +84,7 @@ function testScriptMirror(f, file_name, file_lines, type, compilation_type,
// Test the script mirror for different functions.
testScriptMirror(function(){}, 'mirror-script.js', 98, 2, 0);
-testScriptMirror(Math.sin, 'native math.js', -1, 0, 0);
+testScriptMirror(Math.round, 'native math.js', -1, 0, 0);
testScriptMirror(eval('(function(){})'), null, 1, 2, 1, '(function(){})', 87);
testScriptMirror(eval('(function(){\n })'), null, 2, 2, 1, '(function(){\n })', 88);
diff --git a/deps/v8/test/mjsunit/mjsunit.js b/deps/v8/test/mjsunit/mjsunit.js
index 5f03774d75..0430279088 100644
--- a/deps/v8/test/mjsunit/mjsunit.js
+++ b/deps/v8/test/mjsunit/mjsunit.js
@@ -231,8 +231,16 @@ var assertUnoptimized;
return deepObjectEquals(a, b);
}
+ function checkArity(args, arity, name) {
+ if (args.length < arity) {
+ fail(PrettyPrint(arity), args.length,
+ name + " requires " + arity + " or more arguments");
+ }
+ }
assertSame = function assertSame(expected, found, name_opt) {
+ checkArity(arguments, 2, "assertSame");
+
// TODO(mstarzinger): We should think about using Harmony's egal operator
// or the function equivalent Object.is() here.
if (found === expected) {
@@ -245,6 +253,8 @@ var assertUnoptimized;
assertEquals = function assertEquals(expected, found, name_opt) {
+ checkArity(arguments, 2, "assertEquals");
+
if (!deepEquals(found, expected)) {
fail(PrettyPrint(expected), found, name_opt);
}
@@ -371,15 +381,18 @@ var assertUnoptimized;
throw new MjsUnitAssertionError(message);
};
+ var OptimizationStatusImpl = undefined;
- var OptimizationStatus;
- try {
- OptimizationStatus =
- new Function("fun", "sync", "return %GetOptimizationStatus(fun, sync);");
- } catch (e) {
- OptimizationStatus = function() {
- throw new Error("natives syntax not allowed");
+ var OptimizationStatus = function(fun, sync_opt) {
+ if (OptimizationStatusImpl === undefined) {
+ try {
+ OptimizationStatusImpl = new Function(
+ "fun", "sync", "return %GetOptimizationStatus(fun, sync);");
+ } catch (e) {
+ throw new Error("natives syntax not allowed");
+ }
}
+ return OptimizationStatusImpl(fun, sync_opt);
}
assertUnoptimized = function assertUnoptimized(fun, sync_opt, name_opt) {
diff --git a/deps/v8/test/mjsunit/mjsunit.status b/deps/v8/test/mjsunit/mjsunit.status
index 117a0e6f71..228d243643 100644
--- a/deps/v8/test/mjsunit/mjsunit.status
+++ b/deps/v8/test/mjsunit/mjsunit.status
@@ -48,6 +48,116 @@
# This test non-deterministically runs out of memory on Windows ia32.
'regress/regress-crbug-160010': [SKIP],
+ # Issue 3389: deopt_every_n_garbage_collections is unsafe
+ 'regress/regress-2653': [SKIP],
+
+ ##############################################################################
+ # TurboFan compiler failures.
+
+ # TODO(mstarzinger): An arguments object materialized in the prologue can't
+ # be accessed indirectly. Either we drop that requirement or wait for support
+ # from the deoptimizer to do that.
+ 'arguments-indirect': [PASS, NO_VARIANTS],
+
+ # TODO(mstarzinger): Sometimes the try-catch blacklist fails.
+ 'debug-references': [PASS, NO_VARIANTS],
+ 'regress/regress-263': [PASS, NO_VARIANTS],
+
+ # Some tests are over-restrictive about object layout.
+ 'array-constructor-feedback': [PASS, NO_VARIANTS],
+ 'array-feedback': [PASS, NO_VARIANTS],
+
+ # Some tests are just too slow to run for now.
+ 'big-object-literal': [PASS, NO_VARIANTS],
+ 'bit-not': [PASS, NO_VARIANTS],
+ 'json2': [PASS, NO_VARIANTS],
+ 'packed-elements': [PASS, NO_VARIANTS],
+ 'unbox-double-arrays': [PASS, NO_VARIANTS],
+ 'whitespaces': [PASS, NO_VARIANTS],
+ 'compiler/optimized-for-in': [PASS, NO_VARIANTS],
+ 'compiler/osr-assert': [PASS, NO_VARIANTS],
+ 'compiler/osr-regress-max-locals': [PASS, NO_VARIANTS],
+ 'es7/object-observe': [PASS, NO_VARIANTS],
+ 'regress/regress-2185-2': [PASS, NO_VARIANTS],
+ 'regress/regress-284': [PASS, NO_VARIANTS],
+ 'regress/string-set-char-deopt': [PASS, NO_VARIANTS],
+ 'tools/profviz': [PASS, NO_VARIANTS],
+
+ # Support for breakpoints requires special relocation info for DebugBreak.
+ 'debug-clearbreakpointgroup': [PASS, NO_VARIANTS],
+ 'debug-step-2': [PASS, NO_VARIANTS],
+ 'regress/regress-debug-deopt-while-recompile': [PASS, NO_VARIANTS],
+ 'regress/regress-opt-after-debug-deopt': [PASS, NO_VARIANTS],
+
+ # Support for %GetFrameDetails is missing and requires checkpoints.
+ 'debug-backtrace-text': [PASS, NO_VARIANTS],
+ 'debug-break-inline': [PASS, NO_VARIANTS],
+ 'debug-evaluate-arguments': [PASS, NO_VARIANTS],
+ 'debug-evaluate-bool-constructor': [PASS, NO_VARIANTS],
+ 'debug-evaluate-closure': [PASS, NO_VARIANTS],
+ 'debug-evaluate-const': [PASS, NO_VARIANTS],
+ 'debug-evaluate-locals-optimized-double': [PASS, NO_VARIANTS],
+ 'debug-evaluate-locals-optimized': [PASS, NO_VARIANTS],
+ 'debug-evaluate-locals': [PASS, NO_VARIANTS],
+ 'debug-evaluate-with-context': [PASS, NO_VARIANTS],
+ 'debug-evaluate-with': [PASS, NO_VARIANTS],
+ 'debug-liveedit-double-call': [PASS, NO_VARIANTS],
+ 'debug-liveedit-restart-frame': [PASS, NO_VARIANTS],
+ 'debug-receiver': [PASS, NO_VARIANTS],
+ 'debug-return-value': [PASS, NO_VARIANTS],
+ 'debug-scopes': [PASS, NO_VARIANTS],
+ 'debug-set-variable-value': [PASS, NO_VARIANTS],
+ 'debug-step-stub-callfunction': [PASS, NO_VARIANTS],
+ 'debug-stepin-accessor': [PASS, NO_VARIANTS],
+ 'debug-stepin-builtin': [PASS, NO_VARIANTS],
+ 'debug-stepin-constructor': [PASS, NO_VARIANTS],
+ 'debug-stepin-function-call': [PASS, NO_VARIANTS],
+ 'debug-stepnext-do-while': [PASS, NO_VARIANTS],
+ 'debug-stepout-recursive-function': [PASS, NO_VARIANTS],
+ 'debug-stepout-scope-part1': [PASS, NO_VARIANTS],
+ 'debug-stepout-scope-part2': [PASS, NO_VARIANTS],
+ 'debug-stepout-scope-part3': [PASS, NO_VARIANTS],
+ 'debug-stepout-scope-part7': [PASS, NO_VARIANTS],
+ 'debug-stepout-to-builtin': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/throw-in-constructor': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/reject-in-constructor': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/throw-with-undefined-reject': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/throw-with-throw-in-reject': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/reject-with-throw-in-reject': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/throw-uncaught-all': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/throw-uncaught-uncaught': [PASS, NO_VARIANTS],
+ 'es6/debug-promises/reject-uncaught-late': [PASS, NO_VARIANTS],
+ 'harmony/debug-blockscopes': [PASS, NO_VARIANTS],
+ 'harmony/generators-debug-scopes': [PASS, NO_VARIANTS],
+ 'regress/regress-1081309': [PASS, NO_VARIANTS],
+ 'regress/regress-1170187': [PASS, NO_VARIANTS],
+ 'regress/regress-119609': [PASS, NO_VARIANTS],
+ 'regress/regress-131994': [PASS, NO_VARIANTS],
+ 'regress/regress-269': [PASS, NO_VARIANTS],
+ 'regress/regress-325676': [PASS, NO_VARIANTS],
+ 'regress/regress-crbug-107996': [PASS, NO_VARIANTS],
+ 'regress/regress-crbug-171715': [PASS, NO_VARIANTS],
+ 'regress/regress-crbug-222893': [PASS, NO_VARIANTS],
+ 'regress/regress-crbug-259300': [PASS, NO_VARIANTS],
+ 'regress/regress-frame-details-null-receiver': [PASS, NO_VARIANTS],
+
+ # Support for ES6 generators is missing.
+ 'regress-3225': [PASS, NO_VARIANTS],
+ 'harmony/generators-debug-liveedit': [PASS, NO_VARIANTS],
+ 'harmony/generators-iteration': [PASS, NO_VARIANTS],
+ 'harmony/generators-parsing': [PASS, NO_VARIANTS],
+ 'harmony/generators-poisoned-properties': [PASS, NO_VARIANTS],
+ 'harmony/generators-relocation': [PASS, NO_VARIANTS],
+ 'harmony/regress/regress-2681': [PASS, NO_VARIANTS],
+ 'harmony/regress/regress-2691': [PASS, NO_VARIANTS],
+ 'harmony/regress/regress-3280': [PASS, NO_VARIANTS],
+
+ # Support for ES6 for-of iteration is missing.
+ 'es6/array-iterator': [PASS, NO_VARIANTS],
+ 'es6/iteration-semantics': [PASS, NO_VARIANTS],
+ 'es6/string-iterator': [PASS, NO_VARIANTS],
+ 'es6/typed-array-iterator': [PASS, NO_VARIANTS],
+
##############################################################################
# Too slow in debug mode with --stress-opt mode.
'compiler/regress-stacktrace-methods': [PASS, ['mode == debug', SKIP]],
@@ -67,14 +177,11 @@
# No need to waste time for this test.
'd8-performance-now': [PASS, NO_VARIANTS],
- ##############################################################################
- 'big-object-literal': [PASS, ['arch == arm or arch == android_arm or arch == android_arm64', SKIP]],
-
# Issue 488: this test sometimes times out.
'array-constructor': [PASS, TIMEOUT],
# Very slow on ARM and MIPS, contains no architecture dependent code.
- 'unicode-case-overoptimization': [PASS, NO_VARIANTS, ['arch == arm or arch == android_arm or arch == android_arm64 or arch == mipsel or arch == mips', TIMEOUT]],
+ 'unicode-case-overoptimization': [PASS, NO_VARIANTS, ['arch == arm or arch == android_arm or arch == android_arm64 or arch == mipsel or arch == mips64el or arch == mips', TIMEOUT]],
##############################################################################
# This test expects to reach a certain recursion depth, which may not work
@@ -84,6 +191,8 @@
##############################################################################
# Skip long running tests that time out in debug mode.
'generated-transition-stub': [PASS, ['mode == debug', SKIP]],
+ 'migrations': [SKIP],
+ 'array-functions-prototype-misc': [PASS, ['mode == debug', SKIP]],
##############################################################################
# This test sets the umask on a per-process basis and hence cannot be
@@ -94,7 +203,7 @@
# get the same random seed and would generate the same directory name. Besides
# that, it doesn't make sense to run several variants of d8-os anyways.
'd8-os': [PASS, NO_VARIANTS, ['isolates or arch == android_arm or arch == android_arm64 or arch == android_ia32', SKIP]],
- 'tools/tickprocessor': [PASS, ['arch == android_arm or arch == android_arm64 or arch == android_ia32', SKIP]],
+ 'tools/tickprocessor': [PASS, NO_VARIANTS, ['arch == android_arm or arch == android_arm64 or arch == android_ia32', SKIP]],
##############################################################################
# Long running test that reproduces memory leak and should be run manually.
@@ -117,7 +226,7 @@
# BUG(v8:2989). PASS/FAIL on linux32 because crankshaft is turned off for
# nosse2. Also for arm novfp3.
- 'regress/regress-2989': [FAIL, NO_VARIANTS, ['system == linux and arch == ia32 or arch == arm and simulator == True', PASS]],
+ 'regress/regress-2989': [FAIL, NO_VARIANTS, ['system == linux and arch == x87 or arch == arm and simulator == True', PASS]],
# Skip endain dependent test for mips due to different typed views of the same
# array buffer.
@@ -133,18 +242,66 @@
'array-feedback': [SKIP],
'array-literal-feedback': [SKIP],
'd8-performance-now': [SKIP],
+ 'debug-stepout-scope-part8': [PASS, ['arch == arm ', FAIL]],
'elements-kind': [SKIP],
+ 'elements-transition-hoisting': [SKIP],
'fast-prototype': [SKIP],
+ 'getters-on-elements': [SKIP],
+ 'harmony/block-let-crankshaft': [SKIP],
'opt-elements-kind': [SKIP],
'osr-elements-kind': [SKIP],
'regress/regress-165637': [SKIP],
'regress/regress-2249': [SKIP],
- 'debug-stepout-scope-part8': [PASS, ['arch == arm ', FAIL]],
+ # Tests taking too long
+ 'debug-stepout-scope-part8': [SKIP],
+ 'mirror-object': [SKIP],
+ 'packed-elements': [SKIP],
+ 'regress/regress-1122': [SKIP],
+ 'regress/regress-331444': [SKIP],
+ 'regress/regress-353551': [SKIP],
+ 'regress/regress-crbug-119926': [SKIP],
+ 'regress/short-circuit': [SKIP],
+ 'stack-traces-overflow': [SKIP],
+ 'unicode-test': [SKIP],
+ 'whitespaces': [SKIP],
+
+ # TODO(mstarzinger): Takes too long with TF.
+ 'array-sort': [PASS, NO_VARIANTS],
}], # 'gc_stress == True'
##############################################################################
+['no_i18n', {
+ # Don't call runtime functions that don't exist without i18n support.
+ 'runtime-gen/availablelocalesof': [SKIP],
+ 'runtime-gen/breakiteratoradopttext': [SKIP],
+ 'runtime-gen/breakiteratorbreaktype': [SKIP],
+ 'runtime-gen/breakiteratorbreaktype': [SKIP],
+ 'runtime-gen/breakiteratorcurrent': [SKIP],
+ 'runtime-gen/breakiteratorfirst': [SKIP],
+ 'runtime-gen/breakiteratornext': [SKIP],
+ 'runtime-gen/canonicalizelanguagetag': [SKIP],
+ 'runtime-gen/createbreakiterator': [SKIP],
+ 'runtime-gen/createcollator': [SKIP],
+ 'runtime-gen/getdefaulticulocale': [SKIP],
+ 'runtime-gen/getimplfrominitializedintlobject': [SKIP],
+ 'runtime-gen/getlanguagetagvariants': [SKIP],
+ 'runtime-gen/internalcompare': [SKIP],
+ 'runtime-gen/internaldateformat': [SKIP],
+ 'runtime-gen/internaldateparse': [SKIP],
+ 'runtime-gen/internalnumberformat': [SKIP],
+ 'runtime-gen/internalnumberparse': [SKIP],
+ 'runtime-gen/isinitializedintlobject': [SKIP],
+ 'runtime-gen/isinitializedintlobjectoftype': [SKIP],
+ 'runtime-gen/markasinitializedintlobjectoftype': [SKIP],
+ 'runtime-gen/stringnormalize': [SKIP],
+}],
+
+##############################################################################
['arch == arm64 or arch == android_arm64', {
+ # arm64 TF timeout.
+ 'regress/regress-1257': [PASS, TIMEOUT],
+
# Requires bigger stack size in the Genesis and if stack size is increased,
# the test requires too much time to run. However, the problem test covers
# should be platform-independent.
@@ -153,6 +310,7 @@
# Pass but take too long to run. Skip.
# Some similar tests (with fewer iterations) may be included in arm64-js
# tests.
+ 'big-object-literal': [SKIP],
'compiler/regress-arguments': [SKIP],
'compiler/regress-gvn': [SKIP],
'compiler/regress-max-locals-for-osr': [SKIP],
@@ -174,15 +332,12 @@
'regress/regress-2185-2': [PASS, TIMEOUT],
'whitespaces': [PASS, TIMEOUT, SLOW],
- # Stack manipulations in LiveEdit is not implemented for this arch.
- 'debug-liveedit-check-stack': [SKIP],
- 'debug-liveedit-stack-padding': [SKIP],
- 'debug-liveedit-restart-frame': [SKIP],
- 'debug-liveedit-double-call': [SKIP],
-
# BUG(v8:3147). It works on other architectures by accident.
'regress/regress-conditional-position': [FAIL],
+ # BUG(v8:3457).
+ 'deserialize-reference': [PASS, FAIL],
+
# Slow tests.
'array-concat': [PASS, SLOW],
'array-constructor': [PASS, SLOW],
@@ -193,7 +348,7 @@
'bit-not': [PASS, SLOW],
'compiler/alloc-number': [PASS, SLOW],
'compiler/osr-assert': [PASS, SLOW],
- 'compiler/osr-warm': [PASS, SLOW],
+ 'compiler/osr-warm': [PASS, TIMEOUT, SLOW],
'compiler/osr-with-args': [PASS, SLOW],
'debug-scopes': [PASS, SLOW],
'generated-transition-stub': [PASS, SLOW],
@@ -259,6 +414,7 @@
# Long running tests. Skipping because having them timeout takes too long on
# the buildbot.
+ 'big-object-literal': [SKIP],
'compiler/alloc-number': [SKIP],
'regress/regress-490': [SKIP],
'regress/regress-634': [SKIP],
@@ -270,12 +426,6 @@
# should be platform-independent.
'regress/regress-1132': [SKIP],
- # Stack manipulations in LiveEdit is not implemented for this arch.
- 'debug-liveedit-check-stack': [SKIP],
- 'debug-liveedit-stack-padding': [SKIP],
- 'debug-liveedit-restart-frame': [SKIP],
- 'debug-liveedit-double-call': [SKIP],
-
# Currently always deopt on minus zero
'math-floor-of-div-minus-zero': [SKIP],
@@ -321,17 +471,78 @@
# should be platform-independent.
'regress/regress-1132': [SKIP],
- # Stack manipulations in LiveEdit is not implemented for this arch.
- 'debug-liveedit-check-stack': [SKIP],
- 'debug-liveedit-stack-padding': [SKIP],
- 'debug-liveedit-restart-frame': [SKIP],
- 'debug-liveedit-double-call': [SKIP],
-
# Currently always deopt on minus zero
'math-floor-of-div-minus-zero': [SKIP],
+
+ # BUG(v8:3457).
+ 'deserialize-reference': [SKIP],
}], # 'arch == mipsel or arch == mips'
##############################################################################
+['arch == mips64el', {
+
+ # Slow tests which times out in debug mode.
+ 'try': [PASS, ['mode == debug', SKIP]],
+ 'debug-scripts-request': [PASS, ['mode == debug', SKIP]],
+ 'array-constructor': [PASS, ['mode == debug', SKIP]],
+
+ # Times out often in release mode on MIPS.
+ 'compiler/regress-stacktrace-methods': [PASS, PASS, ['mode == release', TIMEOUT]],
+ 'array-splice': [PASS, TIMEOUT],
+
+ # Long running test.
+ 'mirror-object': [PASS, TIMEOUT],
+ 'string-indexof-2': [PASS, TIMEOUT],
+
+ # BUG(3251035): Timeouts in long looping crankshaft optimization
+ # tests. Skipping because having them timeout takes too long on the
+ # buildbot.
+ 'compiler/alloc-number': [PASS, SLOW],
+ 'compiler/array-length': [PASS, SLOW],
+ 'compiler/assignment-deopt': [PASS, SLOW],
+ 'compiler/deopt-args': [PASS, SLOW],
+ 'compiler/inline-compare': [PASS, SLOW],
+ 'compiler/inline-global-access': [PASS, SLOW],
+ 'compiler/optimized-function-calls': [PASS, SLOW],
+ 'compiler/pic': [PASS, SLOW],
+ 'compiler/property-calls': [PASS, SLOW],
+ 'compiler/recursive-deopt': [PASS, SLOW],
+ 'compiler/regress-4': [PASS, SLOW],
+ 'compiler/regress-funcaller': [PASS, SLOW],
+ 'compiler/regress-rep-change': [PASS, SLOW],
+ 'compiler/regress-arguments': [PASS, SLOW],
+ 'compiler/regress-funarguments': [PASS, SLOW],
+ 'compiler/regress-3249650': [PASS, SLOW],
+ 'compiler/simple-deopt': [PASS, SLOW],
+ 'regress/regress-490': [PASS, SLOW],
+ 'regress/regress-634': [PASS, SLOW],
+ 'regress/regress-create-exception': [PASS, SLOW],
+ 'regress/regress-3218915': [PASS, SLOW],
+ 'regress/regress-3247124': [PASS, SLOW],
+
+ # Requires bigger stack size in the Genesis and if stack size is increased,
+ # the test requires too much time to run. However, the problem test covers
+ # should be platform-independent.
+ 'regress/regress-1132': [SKIP],
+
+ # Currently always deopt on minus zero
+ 'math-floor-of-div-minus-zero': [SKIP],
+
+ # BUG(v8:3457).
+ 'deserialize-reference': [SKIP],
+}], # 'arch == mips64el'
+
+['arch == mips64el and simulator_run == False', {
+ # Random failures on HW, need investigation.
+ 'debug-*': [SKIP],
+}],
+##############################################################################
+['system == windows', {
+ # BUG(v8:3435)
+ 'debug-script-breakpoints': [PASS, FAIL],
+}], # 'system == windows'
+
+##############################################################################
# Native Client uses the ARM simulator so will behave similarly to arm
# on mjsunit tests.
# TODO(bradchen): enable more tests for NaCl V8 when it stops using
@@ -346,6 +557,7 @@
'debug-liveedit-stack-padding': [SKIP],
'debug-liveedit-restart-frame': [SKIP],
'debug-liveedit-double-call': [SKIP],
+ 'harmony/generators-debug-liveedit': [SKIP],
# NaCl builds have problems with this test since Pepper_28.
# V8 Issue 2786
diff --git a/deps/v8/test/mjsunit/object-define-property.js b/deps/v8/test/mjsunit/object-define-property.js
index cbb2d211f4..4c495c6824 100644
--- a/deps/v8/test/mjsunit/object-define-property.js
+++ b/deps/v8/test/mjsunit/object-define-property.js
@@ -27,7 +27,7 @@
// Tests the object.defineProperty method - ES 15.2.3.6
-// Flags: --allow-natives-syntax --es5-readonly
+// Flags: --allow-natives-syntax
// Check that an exception is thrown when null is passed as object.
var exception = false;
@@ -467,35 +467,35 @@ try {
}
-// Test runtime calls to DefineOrRedefineDataProperty and
-// DefineOrRedefineAccessorProperty - make sure we don't
+// Test runtime calls to DefineDataPropertyUnchecked and
+// DefineAccessorPropertyUnchecked - make sure we don't
// crash.
try {
- %DefineOrRedefineAccessorProperty(0, 0, 0, 0, 0);
+ %DefineAccessorPropertyUnchecked(0, 0, 0, 0, 0);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
try {
- %DefineOrRedefineDataProperty(0, 0, 0, 0);
+ %DefineDataPropertyUnchecked(0, 0, 0, 0);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
try {
- %DefineOrRedefineDataProperty(null, null, null, null);
+ %DefineDataPropertyUnchecked(null, null, null, null);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
try {
- %DefineOrRedefineAccessorProperty(null, null, null, null, null);
+ %DefineAccessorPropertyUnchecked(null, null, null, null, null);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
try {
- %DefineOrRedefineDataProperty({}, null, null, null);
+ %DefineDataPropertyUnchecked({}, null, null, null);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
@@ -503,13 +503,13 @@ try {
// Defining properties null should fail even when we have
// other allowed values
try {
- %DefineOrRedefineAccessorProperty(null, 'foo', func, null, 0);
+ %DefineAccessorPropertyUnchecked(null, 'foo', func, null, 0);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
try {
- %DefineOrRedefineDataProperty(null, 'foo', 0, 0);
+ %DefineDataPropertyUnchecked(null, 'foo', 0, 0);
} catch (e) {
assertTrue(/illegal access/.test(e));
}
diff --git a/deps/v8/test/mjsunit/object-toprimitive.js b/deps/v8/test/mjsunit/object-toprimitive.js
index 3a67ced47e..34803ec934 100644
--- a/deps/v8/test/mjsunit/object-toprimitive.js
+++ b/deps/v8/test/mjsunit/object-toprimitive.js
@@ -102,3 +102,5 @@ trace = [];
var nt = Number(ot);
assertEquals(87, nt);
assertEquals(["gvo", "gts", "ts"], trace);
+
+assertThrows('Number(Symbol())', TypeError);
diff --git a/deps/v8/test/mjsunit/opt-elements-kind.js b/deps/v8/test/mjsunit/opt-elements-kind.js
index f26bb42067..be7303b04b 100644
--- a/deps/v8/test/mjsunit/opt-elements-kind.js
+++ b/deps/v8/test/mjsunit/opt-elements-kind.js
@@ -25,28 +25,13 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Limit the number of stress runs to reduce polymorphism it defeats some of the
// assumptions made about how elements transitions work because transition stubs
// end up going generic.
// Flags: --stress-runs=2
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
var elements_kind = {
fast_smi_only : 'fast smi only elements',
fast : 'fast elements',
@@ -100,10 +85,6 @@ function getKind(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
@@ -143,8 +124,6 @@ function convert_mixed(array, value, kind) {
}
function test1() {
- if (!support_smi_only_arrays) return;
-
// Test transition chain SMI->DOUBLE->FAST (crankshafted function will
// transition to FAST directly).
var smis = construct_smis();
diff --git a/deps/v8/test/mjsunit/osr-elements-kind.js b/deps/v8/test/mjsunit/osr-elements-kind.js
index 2ad3c43487..518b984743 100644
--- a/deps/v8/test/mjsunit/osr-elements-kind.js
+++ b/deps/v8/test/mjsunit/osr-elements-kind.js
@@ -25,28 +25,13 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Limit the number of stress runs to reduce polymorphism it defeats some of the
// assumptions made about how elements transitions work because transition stubs
// end up going generic.
// Flags: --stress-runs=2
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
var elements_kind = {
fast_smi_only : 'fast smi only elements',
fast : 'fast elements',
@@ -100,10 +85,6 @@ function getKind(obj) {
}
function assertKind(expected, obj, name_opt) {
- if (!support_smi_only_arrays &&
- expected == elements_kind.fast_smi_only) {
- expected = elements_kind.fast;
- }
assertEquals(expected, getKind(obj), name_opt);
}
@@ -113,53 +94,51 @@ function assertKind(expected, obj, name_opt) {
%NeverOptimizeFunction(convert_mixed);
for (var i = 0; i < 1000000; i++) { }
-if (support_smi_only_arrays) {
- // This code exists to eliminate the learning influence of AllocationSites
- // on the following tests.
- var __sequence = 0;
- function make_array_string() {
- this.__sequence = this.__sequence + 1;
- return "/* " + this.__sequence + " */ [0, 0, 0];"
- }
- function make_array() {
- return eval(make_array_string());
- }
+// This code exists to eliminate the learning influence of AllocationSites
+// on the following tests.
+var __sequence = 0;
+function make_array_string() {
+ this.__sequence = this.__sequence + 1;
+ return "/* " + this.__sequence + " */ [0, 0, 0];"
+}
+function make_array() {
+ return eval(make_array_string());
+}
- function construct_smis() {
- var a = make_array();
- a[0] = 0; // Send the COW array map to the steak house.
- assertKind(elements_kind.fast_smi_only, a);
- return a;
- }
- function construct_doubles() {
- var a = construct_smis();
- a[0] = 1.5;
- assertKind(elements_kind.fast_double, a);
- return a;
- }
+function construct_smis() {
+ var a = make_array();
+ a[0] = 0; // Send the COW array map to the steak house.
+ assertKind(elements_kind.fast_smi_only, a);
+ return a;
+}
+function construct_doubles() {
+ var a = construct_smis();
+ a[0] = 1.5;
+ assertKind(elements_kind.fast_double, a);
+ return a;
+}
- // Test transition chain SMI->DOUBLE->FAST (crankshafted function will
- // transition to FAST directly).
- function convert_mixed(array, value, kind) {
- array[1] = value;
- assertKind(kind, array);
- assertEquals(value, array[1]);
- }
- smis = construct_smis();
- convert_mixed(smis, 1.5, elements_kind.fast_double);
+// Test transition chain SMI->DOUBLE->FAST (crankshafted function will
+// transition to FAST directly).
+function convert_mixed(array, value, kind) {
+ array[1] = value;
+ assertKind(kind, array);
+ assertEquals(value, array[1]);
+}
+smis = construct_smis();
+convert_mixed(smis, 1.5, elements_kind.fast_double);
- doubles = construct_doubles();
- convert_mixed(doubles, "three", elements_kind.fast);
+doubles = construct_doubles();
+convert_mixed(doubles, "three", elements_kind.fast);
- convert_mixed(construct_smis(), "three", elements_kind.fast);
- convert_mixed(construct_doubles(), "three", elements_kind.fast);
+convert_mixed(construct_smis(), "three", elements_kind.fast);
+convert_mixed(construct_doubles(), "three", elements_kind.fast);
- smis = construct_smis();
- doubles = construct_doubles();
- convert_mixed(smis, 1, elements_kind.fast);
- convert_mixed(doubles, 1, elements_kind.fast);
- assertTrue(%HaveSameMap(smis, doubles));
-}
+smis = construct_smis();
+doubles = construct_doubles();
+convert_mixed(smis, 1, elements_kind.fast);
+convert_mixed(doubles, 1, elements_kind.fast);
+assertTrue(%HaveSameMap(smis, doubles));
// Throw away type information in the ICs for next stress run.
gc();
diff --git a/deps/v8/test/mjsunit/outobject-double-for-in.js b/deps/v8/test/mjsunit/outobject-double-for-in.js
new file mode 100644
index 0000000000..eb8ac940a7
--- /dev/null
+++ b/deps/v8/test/mjsunit/outobject-double-for-in.js
@@ -0,0 +1,66 @@
+// Copyright 2012 the V8 project authors. All rights reserved.
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are
+// met:
+//
+// * Redistributions of source code must retain the above copyright
+// notice, this list of conditions and the following disclaimer.
+// * Redistributions in binary form must reproduce the above
+// copyright notice, this list of conditions and the following
+// disclaimer in the documentation and/or other materials provided
+// with the distribution.
+// * Neither the name of Google Inc. nor the names of its
+// contributors may be used to endorse or promote products derived
+// from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+// Flags: --allow-natives-syntax
+
+function DoubleContainer() {
+ this.x0 = 0.5;
+ this.x1 = undefined;
+ this.x2 = undefined;
+ this.x3 = undefined;
+ this.x4 = undefined;
+ this.x5 = undefined;
+ this.x6 = undefined;
+ this.x7 = 5;
+ this.x8 = undefined;
+ this.x9 = undefined;
+ this.x10 = undefined;
+ this.x11 = undefined;
+ this.x12 = undefined;
+ this.x13 = undefined;
+ this.x14 = undefined;
+ this.x15 = undefined;
+ this.x16 = true;
+ this.y = 2.5;
+}
+
+var z = new DoubleContainer();
+
+function test_props(a) {
+ for (var i in a) {
+ assertTrue(i !== "x0" || a[i] === 0.5);
+ assertTrue(i !== "y" || a[i] === 2.5);
+ assertTrue(i !== "x12" || a[i] === undefined);
+ assertTrue(i !== "x16" || a[i] === true);
+ assertTrue(i !== "x7" || a[i] === 5);
+ }
+}
+
+test_props(z);
+test_props(z);
+%OptimizeFunctionOnNextCall(test_props);
+test_props(z);
diff --git a/deps/v8/test/mjsunit/override-read-only-property.js b/deps/v8/test/mjsunit/override-read-only-property.js
index 2876ae1f84..f8114a6601 100644
--- a/deps/v8/test/mjsunit/override-read-only-property.js
+++ b/deps/v8/test/mjsunit/override-read-only-property.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --es5_readonly
-
// According to ECMA-262, sections 8.6.2.2 and 8.6.2.3 you're not
// allowed to override read-only properties, not even if the read-only
// property is in the prototype chain.
diff --git a/deps/v8/test/mjsunit/own-symbols.js b/deps/v8/test/mjsunit/own-symbols.js
new file mode 100644
index 0000000000..588a032aa8
--- /dev/null
+++ b/deps/v8/test/mjsunit/own-symbols.js
@@ -0,0 +1,55 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+// Flags: --allow-natives-syntax
+
+var s = %CreatePrivateOwnSymbol("s");
+var s1 = %CreatePrivateOwnSymbol("s1");
+
+function TestSimple() {
+ var p = {}
+ p[s] = "moo";
+
+ var o = Object.create(p);
+
+ assertEquals(undefined, o[s]);
+ assertEquals("moo", p[s]);
+
+ o[s] = "bow-wow";
+ assertEquals("bow-wow", o[s]);
+ assertEquals("moo", p[s]);
+}
+
+TestSimple();
+
+
+function TestICs() {
+ var p = {}
+ p[s] = "moo";
+
+
+ var o = Object.create(p);
+ o[s1] = "bow-wow";
+ function checkNonOwn(o) {
+ assertEquals(undefined, o[s]);
+ assertEquals("bow-wow", o[s1]);
+ }
+
+ checkNonOwn(o);
+
+ // Test monomorphic/optimized.
+ for (var i = 0; i < 1000; i++) {
+ checkNonOwn(o);
+ }
+
+ // Test non-monomorphic.
+ for (var i = 0; i < 1000; i++) {
+ var oNew = Object.create(p);
+ oNew["s" + i] = i;
+ oNew[s1] = "bow-wow";
+ checkNonOwn(oNew);
+ }
+}
+
+TestICs();
diff --git a/deps/v8/test/mjsunit/packed-elements.js b/deps/v8/test/mjsunit/packed-elements.js
index 4a87373064..3ce92d1186 100644
--- a/deps/v8/test/mjsunit/packed-elements.js
+++ b/deps/v8/test/mjsunit/packed-elements.js
@@ -25,9 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --packed-arrays
-
-var has_packed_elements = !%HasFastHoleyElements(Array());
+// Flags: --allow-natives-syntax
function test1() {
var a = Array(8);
@@ -101,11 +99,9 @@ function test_with_optimization(f) {
for (i = 0; i < 25000; ++i) f(); // Make sure GC happens
}
-if (has_packed_elements) {
- test_with_optimization(test1);
- test_with_optimization(test2);
- test_with_optimization(test3);
- test_with_optimization(test4);
- test_with_optimization(test5);
- test_with_optimization(test6);
-}
+test_with_optimization(test1);
+test_with_optimization(test2);
+test_with_optimization(test3);
+test_with_optimization(test4);
+test_with_optimization(test5);
+test_with_optimization(test6);
diff --git a/deps/v8/test/mjsunit/polymorph-arrays.js b/deps/v8/test/mjsunit/polymorph-arrays.js
index ff0c433bd7..2bb0433214 100644
--- a/deps/v8/test/mjsunit/polymorph-arrays.js
+++ b/deps/v8/test/mjsunit/polymorph-arrays.js
@@ -37,7 +37,7 @@ function init_sparse_array(a) {
a[i] = i;
}
a[5000000] = 256;
- assertTrue(%HasDictionaryElements(a));
+ return %NormalizeElements(a);
}
function testPolymorphicLoads() {
@@ -49,7 +49,7 @@ function testPolymorphicLoads() {
var object_array = new Object;
var sparse_object_array = new Object;
var js_array = new Array(10);
- var sparse_js_array = new Array(5000001);
+ var sparse_js_array = %NormalizeElements([]);
init_array(object_array);
init_array(js_array);
@@ -67,7 +67,7 @@ function testPolymorphicLoads() {
var object_array = new Object;
var sparse_object_array = new Object;
var js_array = new Array(10);
- var sparse_js_array = new Array(5000001);
+ var sparse_js_array = %NormalizeElements([]);
init_array(object_array);
init_array(js_array);
@@ -114,7 +114,8 @@ function testPolymorphicStores() {
var object_array = new Object;
var sparse_object_array = new Object;
var js_array = new Array(10);
- var sparse_js_array = new Array(5000001);
+ var sparse_js_array = [];
+ sparse_js_array.length = 5000001;
init_array(object_array);
init_array(js_array);
@@ -132,7 +133,8 @@ function testPolymorphicStores() {
var object_array = new Object;
var sparse_object_array = new Object;
var js_array = new Array(10);
- var sparse_js_array = new Array(5000001);
+ var sparse_js_array = %NormalizeElements([]);
+ sparse_js_array.length = 5000001;
init_array(object_array);
init_array(js_array);
diff --git a/deps/v8/test/mjsunit/proto-accessor.js b/deps/v8/test/mjsunit/proto-accessor.js
index b2e7d34669..513a044023 100644
--- a/deps/v8/test/mjsunit/proto-accessor.js
+++ b/deps/v8/test/mjsunit/proto-accessor.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-symbols
-
// Fake Symbol if undefined, allowing test to run in non-Harmony mode as well.
this.Symbol = typeof Symbol != 'undefined' ? Symbol : String;
diff --git a/deps/v8/test/mjsunit/readonly.js b/deps/v8/test/mjsunit/readonly.js
index 050e256275..084e9ffe23 100644
--- a/deps/v8/test/mjsunit/readonly.js
+++ b/deps/v8/test/mjsunit/readonly.js
@@ -25,8 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --es5_readonly
-// Flags: --harmony-proxies
+// Flags: --allow-natives-syntax --harmony-proxies
// Different ways to create an object.
diff --git a/deps/v8/test/mjsunit/regress-3456.js b/deps/v8/test/mjsunit/regress-3456.js
new file mode 100644
index 0000000000..498953b807
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress-3456.js
@@ -0,0 +1,13 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --min-preparse-length 1
+
+// Arrow function parsing (commit r22366) changed the flags stored in
+// PreParserExpression, and IsValidReferenceExpression() would return
+// false for certain valid expressions. This case is the minimum amount
+// of code needed to validate that IsValidReferenceExpression() works
+// properly. If it does not, a ReferenceError is thrown during parsing.
+
+function f() { ++(this.foo) }
diff --git a/deps/v8/test/mjsunit/regress/debug-prepare-step-in.js b/deps/v8/test/mjsunit/regress/debug-prepare-step-in.js
index b8c2116400..60b47f7a5d 100644
--- a/deps/v8/test/mjsunit/regress/debug-prepare-step-in.js
+++ b/deps/v8/test/mjsunit/regress/debug-prepare-step-in.js
@@ -52,3 +52,5 @@ function g() {
}
g();
+
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/regress/regress-1170.js b/deps/v8/test/mjsunit/regress/regress-1170.js
index 8c5f6f8ab4..5d5800ee37 100644
--- a/deps/v8/test/mjsunit/regress/regress-1170.js
+++ b/deps/v8/test/mjsunit/regress/regress-1170.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --es52_globals
-
var setter_value = 0;
this.__defineSetter__("a", function(v) { setter_value = v; });
@@ -35,8 +33,9 @@ assertEquals(1, setter_value);
assertFalse("value" in Object.getOwnPropertyDescriptor(this, "a"));
eval("with({}) { eval('var a = 2') }");
-assertEquals(2, setter_value);
+assertTrue("get" in Object.getOwnPropertyDescriptor(this, "a"));
assertFalse("value" in Object.getOwnPropertyDescriptor(this, "a"));
+assertEquals(2, setter_value);
// Function declarations are treated specially to match Safari. We do
// not call setters for them.
@@ -47,10 +46,8 @@ assertTrue("value" in Object.getOwnPropertyDescriptor(this, "a"));
this.__defineSetter__("b", function(v) { setter_value = v; });
try {
eval("const b = 3");
-} catch(e) {
- assertUnreachable();
-}
-assertEquals(3, setter_value);
+} catch(e) { }
+assertEquals(2, setter_value);
try {
eval("with({}) { eval('const b = 23') }");
diff --git a/deps/v8/test/mjsunit/regress/regress-1199637.js b/deps/v8/test/mjsunit/regress/regress-1199637.js
index 8b02a6559c..397aeb8762 100644
--- a/deps/v8/test/mjsunit/regress/regress-1199637.js
+++ b/deps/v8/test/mjsunit/regress/regress-1199637.js
@@ -34,43 +34,43 @@ const NONE = 0;
const READ_ONLY = 1;
// Use DeclareGlobal...
-%SetProperty(this.__proto__, "a", 1234, NONE);
+%AddNamedProperty(this.__proto__, "a", 1234, NONE);
assertEquals(1234, a);
eval("var a = 5678;");
assertEquals(5678, a);
-%SetProperty(this.__proto__, "b", 1234, NONE);
+%AddNamedProperty(this.__proto__, "b", 1234, NONE);
assertEquals(1234, b);
eval("const b = 5678;");
assertEquals(5678, b);
-%SetProperty(this.__proto__, "c", 1234, READ_ONLY);
+%AddNamedProperty(this.__proto__, "c", 1234, READ_ONLY);
assertEquals(1234, c);
eval("var c = 5678;");
assertEquals(5678, c);
-%SetProperty(this.__proto__, "d", 1234, READ_ONLY);
+%AddNamedProperty(this.__proto__, "d", 1234, READ_ONLY);
assertEquals(1234, d);
eval("const d = 5678;");
assertEquals(5678, d);
// Use DeclareContextSlot...
-%SetProperty(this.__proto__, "x", 1234, NONE);
+%AddNamedProperty(this.__proto__, "x", 1234, NONE);
assertEquals(1234, x);
eval("with({}) { var x = 5678; }");
assertEquals(5678, x);
-%SetProperty(this.__proto__, "y", 1234, NONE);
+%AddNamedProperty(this.__proto__, "y", 1234, NONE);
assertEquals(1234, y);
eval("with({}) { const y = 5678; }");
assertEquals(5678, y);
-%SetProperty(this.__proto__, "z", 1234, READ_ONLY);
+%AddNamedProperty(this.__proto__, "z", 1234, READ_ONLY);
assertEquals(1234, z);
eval("with({}) { var z = 5678; }");
assertEquals(5678, z);
-%SetProperty(this.__proto__, "w", 1234, READ_ONLY);
+%AddNamedProperty(this.__proto__, "w", 1234, READ_ONLY);
assertEquals(1234, w);
eval("with({}) { const w = 5678; }");
assertEquals(5678, w);
diff --git a/deps/v8/test/mjsunit/regress/regress-1213575.js b/deps/v8/test/mjsunit/regress/regress-1213575.js
index f3a11dbaab..8c197bcf83 100644
--- a/deps/v8/test/mjsunit/regress/regress-1213575.js
+++ b/deps/v8/test/mjsunit/regress/regress-1213575.js
@@ -37,4 +37,4 @@ try {
assertTrue(e instanceof TypeError);
caught = true;
}
-assertFalse(caught);
+assertTrue(caught);
diff --git a/deps/v8/test/mjsunit/regress/regress-1530.js b/deps/v8/test/mjsunit/regress/regress-1530.js
index db2114450e..20d1f265c0 100644
--- a/deps/v8/test/mjsunit/regress/regress-1530.js
+++ b/deps/v8/test/mjsunit/regress/regress-1530.js
@@ -33,34 +33,52 @@ var f = function() {};
// Verify that normal assignment of 'prototype' property works properly
// and updates the internal value.
-var x = { foo: 'bar' };
-f.prototype = x;
-assertSame(f.prototype, x);
+var a = { foo: 'bar' };
+f.prototype = a;
+assertSame(f.prototype, a);
assertSame(f.prototype.foo, 'bar');
assertSame(new f().foo, 'bar');
-assertSame(Object.getPrototypeOf(new f()), x);
-assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, x);
+assertSame(Object.getPrototypeOf(new f()), a);
+assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, a);
+assertTrue(Object.getOwnPropertyDescriptor(f, 'prototype').writable);
// Verify that 'prototype' behaves like a data property when it comes to
// redefining with Object.defineProperty() and the internal value gets
// updated.
-var y = { foo: 'baz' };
-Object.defineProperty(f, 'prototype', { value: y, writable: true });
-assertSame(f.prototype, y);
+var b = { foo: 'baz' };
+Object.defineProperty(f, 'prototype', { value: b, writable: true });
+assertSame(f.prototype, b);
assertSame(f.prototype.foo, 'baz');
assertSame(new f().foo, 'baz');
-assertSame(Object.getPrototypeOf(new f()), y);
-assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, y);
+assertSame(Object.getPrototypeOf(new f()), b);
+assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, b);
+assertTrue(Object.getOwnPropertyDescriptor(f, 'prototype').writable);
// Verify that the previous redefinition didn't screw up callbacks and
// the internal value still gets updated.
-var z = { foo: 'other' };
-f.prototype = z;
-assertSame(f.prototype, z);
+var c = { foo: 'other' };
+f.prototype = c;
+assertSame(f.prototype, c);
assertSame(f.prototype.foo, 'other');
assertSame(new f().foo, 'other');
-assertSame(Object.getPrototypeOf(new f()), z);
-assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, z);
+assertSame(Object.getPrototypeOf(new f()), c);
+assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, c);
+assertTrue(Object.getOwnPropertyDescriptor(f, 'prototype').writable);
+
+// Verify that 'prototype' can be redefined to contain a different value
+// and have a different writability attribute at the same time.
+var d = { foo: 'final' };
+Object.defineProperty(f, 'prototype', { value: d, writable: false });
+assertSame(f.prototype, d);
+assertSame(f.prototype.foo, 'final');
+assertSame(new f().foo, 'final');
+assertSame(Object.getPrototypeOf(new f()), d);
+assertSame(Object.getOwnPropertyDescriptor(f, 'prototype').value, d);
+assertFalse(Object.getOwnPropertyDescriptor(f, 'prototype').writable);
+
+// Verify that non-writability of redefined 'prototype' is respected.
+assertThrows("'use strict'; f.prototype = {}");
+assertThrows("Object.defineProperty(f, 'prototype', { value: {} })");
// Verify that non-writability of other properties is respected.
assertThrows("Object.defineProperty(f, 'name', { value: {} })");
diff --git a/deps/v8/test/mjsunit/regress/regress-1708.js b/deps/v8/test/mjsunit/regress/regress-1708.js
index 48ee79c77c..ed2ddb1458 100644
--- a/deps/v8/test/mjsunit/regress/regress-1708.js
+++ b/deps/v8/test/mjsunit/regress/regress-1708.js
@@ -32,7 +32,7 @@
// sure that concurrent sweeping, which relies on similar assumptions
// as lazy sweeping works correctly.
-// Flags: --expose-gc --noincremental-marking --max-new-space-size=2
+// Flags: --expose-gc --noincremental-marking --max-semi-space-size=1
(function() {
var head = new Array(1);
diff --git a/deps/v8/test/mjsunit/regress/regress-2790.js b/deps/v8/test/mjsunit/regress/regress-2790.js
index 927f2607cc..ac79e64045 100644
--- a/deps/v8/test/mjsunit/regress/regress-2790.js
+++ b/deps/v8/test/mjsunit/regress/regress-2790.js
@@ -26,6 +26,6 @@
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// Test that we can create arrays of any size.
-for (var i = 1000; i < 1000000; i += 197) {
+for (var i = 1000; i < 1000000; i += 19703) {
new Array(i);
}
diff --git a/deps/v8/test/mjsunit/regress/regress-320532.js b/deps/v8/test/mjsunit/regress/regress-320532.js
index 6ec4b97293..0c3198f790 100644
--- a/deps/v8/test/mjsunit/regress/regress-320532.js
+++ b/deps/v8/test/mjsunit/regress/regress-320532.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Flags: --noalways-opt
// Flags: --stress-runs=8 --send-idle-notification --gc-global
diff --git a/deps/v8/test/mjsunit/regress/regress-3281.js b/deps/v8/test/mjsunit/regress/regress-3281.js
index ebb25991d8..7d42c026b6 100644
--- a/deps/v8/test/mjsunit/regress/regress-3281.js
+++ b/deps/v8/test/mjsunit/regress/regress-3281.js
@@ -2,12 +2,11 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Flags: --allow-natives-syntax --harmony-collections
-
+// Flags: --expose-natives-as=builtins
// Should not crash or raise an exception.
var s = new Set();
-var setIterator = %SetCreateIterator(s, 2);
+var setIterator = new builtins.SetIterator(s, 2);
var m = new Map();
-var mapIterator = %MapCreateIterator(m, 2);
+var mapIterator = new builtins.MapIterator(m, 2);
diff --git a/deps/v8/test/mjsunit/regress/regress-3307.js b/deps/v8/test/mjsunit/regress/regress-3307.js
new file mode 100644
index 0000000000..1fc770d20c
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3307.js
@@ -0,0 +1,24 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function p(x) {
+ this.x = x;
+}
+
+function f() {
+ var a = new p(1), b = new p(2);
+ for (var i = 0; i < 1; i++) {
+ a.x += b.x;
+ }
+ return a.x;
+}
+
+new p(0.1); // make 'x' mutable box double field in p.
+
+assertEquals(3, f());
+assertEquals(3, f());
+%OptimizeFunctionOnNextCall(f);
+assertEquals(3, f());
diff --git a/deps/v8/test/mjsunit/regress/regress-3315.js b/deps/v8/test/mjsunit/regress/regress-3315.js
new file mode 100644
index 0000000000..a1105e2848
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3315.js
@@ -0,0 +1,26 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+var indexZeroCallCount = 0;
+var indexOneCallCount = 0;
+var lengthCallCount = 0;
+var acceptList = {
+ get 0() {
+ indexZeroCallCount++;
+ return 'foo';
+ },
+ get 1() {
+ indexOneCallCount++;
+ return 'bar';
+ },
+ get length() {
+ lengthCallCount++;
+ return 1;
+ }
+};
+
+Object.observe({}, function(){}, acceptList);
+assertEquals(1, lengthCallCount);
+assertEquals(1, indexZeroCallCount);
+assertEquals(0, indexOneCallCount);
diff --git a/deps/v8/test/mjsunit/regress/regress-3334.js b/deps/v8/test/mjsunit/regress/regress-3334.js
new file mode 100644
index 0000000000..301155dbde
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3334.js
@@ -0,0 +1,13 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+function foo(){}
+Object.defineProperty(foo, "prototype", { value: 2 });
+assertEquals(2, foo.prototype);
+
+function bar(){}
+Object.defineProperty(bar, "prototype", { value: 2, writable: false });
+assertEquals(2, bar.prototype);
+assertThrows(function() { "use strict"; bar.prototype = 10; }, TypeError);
+assertEquals(false, Object.getOwnPropertyDescriptor(bar,"prototype").writable);
diff --git a/deps/v8/test/mjsunit/regress/regress-334.js b/deps/v8/test/mjsunit/regress/regress-334.js
index 37dd299cf5..c52c72aa90 100644
--- a/deps/v8/test/mjsunit/regress/regress-334.js
+++ b/deps/v8/test/mjsunit/regress/regress-334.js
@@ -37,10 +37,10 @@ function func1(){}
function func2(){}
var object = {__proto__:{}};
-%SetProperty(object, "foo", func1, DONT_ENUM | DONT_DELETE);
-%SetProperty(object, "bar", func1, DONT_ENUM | READ_ONLY);
-%SetProperty(object, "baz", func1, DONT_DELETE | READ_ONLY);
-%SetProperty(object.__proto__, "bif", func1, DONT_ENUM | DONT_DELETE);
+%AddNamedProperty(object, "foo", func1, DONT_ENUM | DONT_DELETE);
+%AddNamedProperty(object, "bar", func1, DONT_ENUM | READ_ONLY);
+%AddNamedProperty(object, "baz", func1, DONT_DELETE | READ_ONLY);
+%AddNamedProperty(object.__proto__, "bif", func1, DONT_ENUM | DONT_DELETE);
object.bif = func2;
function enumerable(obj) {
diff --git a/deps/v8/test/mjsunit/regress/regress-3359.js b/deps/v8/test/mjsunit/regress/regress-3359.js
new file mode 100644
index 0000000000..0973797e7e
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3359.js
@@ -0,0 +1,12 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function f() {
+ return 1 >> Boolean.constructor + 1;
+}
+assertEquals(1, f());
+%OptimizeFunctionOnNextCall(f);
+assertEquals(1, f());
diff --git a/deps/v8/test/mjsunit/regress/regress-3380.js b/deps/v8/test/mjsunit/regress/regress-3380.js
new file mode 100644
index 0000000000..2fae459b3b
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3380.js
@@ -0,0 +1,16 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function foo(a) {
+ return (a[0] >>> 0) > 0;
+}
+
+var a = new Uint32Array([4]);
+var b = new Uint32Array([0x80000000]);
+assertTrue(foo(a));
+assertTrue(foo(a));
+%OptimizeFunctionOnNextCall(foo);
+assertTrue(foo(b))
diff --git a/deps/v8/test/mjsunit/regress/regress-3392.js b/deps/v8/test/mjsunit/regress/regress-3392.js
new file mode 100644
index 0000000000..375f30210c
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3392.js
@@ -0,0 +1,18 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function foo() {
+ var a = {b: -1.5};
+ for (var i = 0; i < 1; i++) {
+ a.b = 1;
+ }
+ assertTrue(0 <= a.b);
+}
+
+foo();
+foo();
+%OptimizeFunctionOnNextCall(foo);
+foo();
diff --git a/deps/v8/test/mjsunit/regress/regress-3404.js b/deps/v8/test/mjsunit/regress/regress-3404.js
new file mode 100644
index 0000000000..c4d280e577
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3404.js
@@ -0,0 +1,27 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+function testError(error) {
+ // Reconfigure e.stack to be non-configurable
+ var desc1 = Object.getOwnPropertyDescriptor(error, "stack");
+ Object.defineProperty(error, "stack",
+ {get: desc1.get, set: desc1.set, configurable: false});
+
+ var desc2 = Object.getOwnPropertyDescriptor(error, "stack");
+ assertFalse(desc2.configurable);
+ assertEquals(desc1.get, desc2.get);
+ assertEquals(desc2.get, desc2.get);
+}
+
+function stackOverflow() {
+ function f() { f(); }
+ try { f() } catch (e) { return e; }
+}
+
+function referenceError() {
+ try { g() } catch (e) { return e; }
+}
+
+testError(referenceError());
+testError(stackOverflow());
diff --git a/deps/v8/test/mjsunit/regress/regress-3462.js b/deps/v8/test/mjsunit/regress/regress-3462.js
new file mode 100644
index 0000000000..5a3355920b
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3462.js
@@ -0,0 +1,48 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+
+function TestFunctionPrototypeSetter() {
+ var f = function() {};
+ var o = {__proto__: f};
+ o.prototype = 42;
+ assertEquals(42, o.prototype);
+ assertTrue(o.hasOwnProperty('prototype'));
+}
+TestFunctionPrototypeSetter();
+
+
+function TestFunctionPrototypeSetterOnValue() {
+ var f = function() {};
+ var fp = f.prototype;
+ Number.prototype.__proto__ = f;
+ var n = 42;
+ var o = {};
+ n.prototype = o;
+ assertEquals(fp, n.prototype);
+ assertEquals(fp, f.prototype);
+ assertFalse(Number.prototype.hasOwnProperty('prototype'));
+}
+TestFunctionPrototypeSetterOnValue();
+
+
+function TestArrayLengthSetter() {
+ var a = [1];
+ var o = {__proto__: a};
+ o.length = 2;
+ assertEquals(2, o.length);
+ assertEquals(1, a.length);
+ assertTrue(o.hasOwnProperty('length'));
+}
+TestArrayLengthSetter();
+
+
+function TestArrayLengthSetterOnValue() {
+ Number.prototype.__proto__ = [1];
+ var n = 42;
+ n.length = 2;
+ assertEquals(1, n.length);
+ assertFalse(Number.prototype.hasOwnProperty('length'));
+}
+TestArrayLengthSetterOnValue();
diff --git a/deps/v8/test/mjsunit/regress/regress-3476.js b/deps/v8/test/mjsunit/regress/regress-3476.js
new file mode 100644
index 0000000000..f4333dbbfc
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-3476.js
@@ -0,0 +1,24 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function MyWrapper(v) {
+ return { valueOf: function() { return v } };
+}
+
+function f() {
+ assertEquals("truex", true + "x");
+ assertEquals("truey", true + new String("y"));
+ assertEquals("truez", true + new MyWrapper("z"));
+
+ assertEquals("xtrue", "x" + true);
+ assertEquals("ytrue", new String("y") + true);
+ assertEquals("ztrue", new MyWrapper("z") + true);
+}
+
+f();
+f();
+%OptimizeFunctionOnNextCall(f);
+f();
diff --git a/deps/v8/test/mjsunit/regress/regress-370827.js b/deps/v8/test/mjsunit/regress/regress-370827.js
new file mode 100644
index 0000000000..5536d5196b
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-370827.js
@@ -0,0 +1,21 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --expose-gc --heap-stats
+
+function g(dummy, x) {
+ var start = "";
+ if (x) { start = x + " - "; }
+ start = start + "array length";
+};
+
+function f() {
+ gc();
+ g([0.1]);
+}
+
+f();
+%OptimizeFunctionOnNextCall(f);
+f();
+f();
diff --git a/deps/v8/test/mjsunit/regress/regress-373283.js b/deps/v8/test/mjsunit/regress/regress-373283.js
new file mode 100644
index 0000000000..20cee4d808
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-373283.js
@@ -0,0 +1,18 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --deopt-every-n-times=1
+
+function __f_0() {
+ var x = [];
+ x[21] = 1;
+ x[21] + 0;
+}
+
+for (var i = 0; i < 3; i++) __f_0();
+%OptimizeFunctionOnNextCall(__f_0);
+for (var i = 0; i < 10; i++) __f_0();
+%OptimizeFunctionOnNextCall(__f_0);
+__f_0();
+%GetScript("foo");
diff --git a/deps/v8/test/mjsunit/regress/regress-377290.js b/deps/v8/test/mjsunit/regress/regress-377290.js
new file mode 100644
index 0000000000..23e31e79d9
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-377290.js
@@ -0,0 +1,17 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-gc
+
+Object.prototype.__defineGetter__('constructor', function() { throw 42; });
+__v_7 = [
+ function() { [].push() },
+];
+for (var __v_6 = 0; __v_6 < 5; ++__v_6) {
+ for (var __v_8 in __v_7) {
+ print(__v_8, " -> ", __v_7[__v_8]);
+ gc();
+ try { __v_7[__v_8](); } catch (e) {};
+ }
+}
diff --git a/deps/v8/test/mjsunit/regress/regress-379770.js b/deps/v8/test/mjsunit/regress/regress-379770.js
new file mode 100644
index 0000000000..a6653c2591
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-379770.js
@@ -0,0 +1,26 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+// Flags: --allow-natives-syntax --nostress-opt
+// Flags: --nouse-osr
+
+function foo(obj) {
+ var counter = 1;
+ for (var i = 0; i < obj.length; i++) {
+ %OptimizeFunctionOnNextCall(foo, "osr");
+ }
+ counter += obj;
+ return counter;
+}
+
+function bar() {
+ var a = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12];
+ for (var i = 0; i < 100; i++ ) {
+ foo(a);
+ }
+}
+
+try {
+ bar();
+} catch (e) {
+}
diff --git a/deps/v8/test/mjsunit/regress/regress-380049.js b/deps/v8/test/mjsunit/regress/regress-380049.js
new file mode 100644
index 0000000000..a78626cc54
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-380049.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function foo(a,b,c) { return arguments; }
+var f = foo(false, null, 40);
+assertThrows(function() { %ObjectFreeze(f); });
diff --git a/deps/v8/test/mjsunit/regress/regress-380092.js b/deps/v8/test/mjsunit/regress/regress-380092.js
new file mode 100644
index 0000000000..fe6b0b7619
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-380092.js
@@ -0,0 +1,22 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function many_hoist(o, index) {
+ return o[index + 33554427];
+}
+
+var obj = {};
+many_hoist(obj, 0);
+%OptimizeFunctionOnNextCall(many_hoist);
+many_hoist(obj, 5);
+
+function constant_too_large(o, index) {
+ return o[index + 1033554433];
+}
+
+constant_too_large(obj, 0);
+%OptimizeFunctionOnNextCall(constant_too_large);
+constant_too_large(obj, 5);
diff --git a/deps/v8/test/mjsunit/regress/regress-381313.js b/deps/v8/test/mjsunit/regress/regress-381313.js
new file mode 100644
index 0000000000..d2b9d7c11d
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-381313.js
@@ -0,0 +1,42 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+var g = 0;
+
+function f(x, deopt) {
+ var a0 = x;
+ var a1 = 2 * x;
+ var a2 = 3 * x;
+ var a3 = 4 * x;
+ var a4 = 5 * x;
+ var a5 = 6 * x;
+ var a6 = 7 * x;
+ var a7 = 8 * x;
+ var a8 = 9 * x;
+ var a9 = 10 * x;
+ var a10 = 11 * x;
+ var a11 = 12 * x;
+ var a12 = 13 * x;
+ var a13 = 14 * x;
+ var a14 = 15 * x;
+ var a15 = 16 * x;
+ var a16 = 17 * x;
+ var a17 = 18 * x;
+ var a18 = 19 * x;
+ var a19 = 20 * x;
+
+ g = 1;
+
+ deopt + 0;
+
+ return a0 + a1 + a2 + a3 + a4 + a5 + a6 + a7 + a8 + a9 +
+ a10 + a11 + a12 + a13 + a14 + a15 + a16 + a17 + a18 + a19;
+}
+
+f(0.5, 0);
+f(0.5, 0);
+%OptimizeFunctionOnNextCall(f);
+print(f(0.5, ""));
diff --git a/deps/v8/test/mjsunit/regress/regress-392114.js b/deps/v8/test/mjsunit/regress/regress-392114.js
new file mode 100644
index 0000000000..e5cf1cde37
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-392114.js
@@ -0,0 +1,66 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are
+// met:
+//
+// * Redistributions of source code must retain the above copyright
+// notice, this list of conditions and the following disclaimer.
+// * Redistributions in binary form must reproduce the above
+// copyright notice, this list of conditions and the following
+// disclaimer in the documentation and/or other materials provided
+// with the distribution.
+// * Neither the name of Google Inc. nor the names of its
+// contributors may be used to endorse or promote products derived
+// from this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+// Flags: --expose-debug-as debug --allow-natives-syntax
+
+Debug = debug.Debug;
+
+function dummy(x) {
+ return x + 100;
+}
+
+function create_closure() {
+ var f = function(arg) {
+ if (arg) { %DeoptimizeFunction(f); }
+ var a = Array(10);
+ for (var i = 0; i < a.length; i++) {
+ a[i] = i;
+ }
+ }
+ return f;
+}
+
+var c = create_closure();
+c();
+
+// c CallIC state now has custom Array handler installed.
+
+// Turn on the debugger.
+Debug.setListener(function () {});
+
+var d = create_closure();
+%OptimizeFunctionOnNextCall(d);
+// Thanks to the debugger, we recreate the full code too. We deopt and run
+// it, stomping on the unexpected AllocationSite in the type vector slot.
+d(true);
+
+// CallIC in c misinterprets type vector slot contents as an AllocationSite,
+// corrupting the heap.
+c();
+
+// CallIC MISS - crash due to corruption.
+dummy();
diff --git a/deps/v8/test/mjsunit/regress/regress-99167.js b/deps/v8/test/mjsunit/regress/regress-99167.js
index 777acf4487..eac49d12b0 100644
--- a/deps/v8/test/mjsunit/regress/regress-99167.js
+++ b/deps/v8/test/mjsunit/regress/regress-99167.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --expose-gc --max-new-space-size=2
+// Flags: --expose-gc --max-semi-space-size=1
eval("function Node() { this.a = 1; this.a = 3; }");
new Node;
diff --git a/deps/v8/test/mjsunit/regress/regress-cntl-descriptors-enum.js b/deps/v8/test/mjsunit/regress/regress-cntl-descriptors-enum.js
index ee72fafc8a..fd4ac6d6c0 100644
--- a/deps/v8/test/mjsunit/regress/regress-cntl-descriptors-enum.js
+++ b/deps/v8/test/mjsunit/regress/regress-cntl-descriptors-enum.js
@@ -30,10 +30,10 @@
DontEnum = 2;
var o = {};
-%SetProperty(o, "a", 0, DontEnum);
+%AddNamedProperty(o, "a", 0, DontEnum);
var o2 = {};
-%SetProperty(o2, "a", 0, DontEnum);
+%AddNamedProperty(o2, "a", 0, DontEnum);
assertTrue(%HaveSameMap(o, o2));
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-245480.js b/deps/v8/test/mjsunit/regress/regress-crbug-245480.js
index ec8850905b..43fa6ba3b6 100644
--- a/deps/v8/test/mjsunit/regress/regress-crbug-245480.js
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-245480.js
@@ -25,25 +25,9 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax --smi-only-arrays --expose-gc
+// Flags: --allow-natives-syntax --expose-gc
// Flags: --noalways-opt
-// Test element kind of objects.
-// Since --smi-only-arrays affects builtins, its default setting at compile
-// time sticks if built with snapshot. If --smi-only-arrays is deactivated
-// by default, only a no-snapshot build actually has smi-only arrays enabled
-// in this test case. Depending on whether smi-only arrays are actually
-// enabled, this test takes the appropriate code path to check smi-only arrays.
-
-// support_smi_only_arrays = %HasFastSmiElements(new Array(1,2,3,4,5,6,7,8));
-support_smi_only_arrays = true;
-
-if (support_smi_only_arrays) {
- print("Tests include smi-only arrays.");
-} else {
- print("Tests do NOT include smi-only arrays.");
-}
-
function isHoley(obj) {
if (%HasFastHoleyElements(obj)) return true;
return false;
@@ -57,19 +41,17 @@ function assertNotHoley(obj, name_opt) {
assertEquals(false, isHoley(obj), name_opt);
}
-if (support_smi_only_arrays) {
- function create_array(arg) {
- return new Array(arg);
- }
-
- obj = create_array(0);
- assertNotHoley(obj);
- create_array(0);
- %OptimizeFunctionOnNextCall(create_array);
- obj = create_array(10);
- assertHoley(obj);
+function create_array(arg) {
+ return new Array(arg);
}
+obj = create_array(0);
+assertNotHoley(obj);
+create_array(0);
+%OptimizeFunctionOnNextCall(create_array);
+obj = create_array(10);
+assertHoley(obj);
+
// The code below would assert in debug or crash in release
function f(length) {
return new Array(length)
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-350864.js b/deps/v8/test/mjsunit/regress/regress-crbug-350864.js
index 8a793cb0a0..510834be3e 100644
--- a/deps/v8/test/mjsunit/regress/regress-crbug-350864.js
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-350864.js
@@ -25,8 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-symbols
-
var v0 = new WeakMap;
var v1 = {};
v0.set(v1, 1);
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-374838.js b/deps/v8/test/mjsunit/regress/regress-crbug-374838.js
new file mode 100644
index 0000000000..614b4d9a87
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-374838.js
@@ -0,0 +1,20 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function foo() {
+ var a = [0];
+ result = 0;
+ for (var i = 0; i < 4; i++) {
+ result += a.length;
+ a.shift();
+ }
+ return result;
+}
+
+assertEquals(1, foo());
+assertEquals(1, foo());
+%OptimizeFunctionOnNextCall(foo);
+assertEquals(1, foo());
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-380512.js b/deps/v8/test/mjsunit/regress/regress-crbug-380512.js
new file mode 100644
index 0000000000..af78ba7183
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-380512.js
@@ -0,0 +1,12 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function f() { [].lastIndexOf(42); }
+
+f();
+f();
+%OptimizeFunctionOnNextCall(f);
+f();
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-381534.js b/deps/v8/test/mjsunit/regress/regress-crbug-381534.js
new file mode 100644
index 0000000000..2aa3929677
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-381534.js
@@ -0,0 +1,40 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+var obj = {};
+
+function f(v) {
+ var v1 = -(4/3);
+ var v2 = 1;
+ var arr = new Array(+0, true, 0, -0, false, undefined, null, "0", obj, v1, -(4/3), -1.3333333333333, "str", v2, 1, false);
+ assertEquals(10, arr.lastIndexOf(-(4/3)));
+ assertEquals(9, arr.indexOf(-(4/3)));
+
+ assertEquals(10, arr.lastIndexOf(v));
+ assertEquals(9, arr.indexOf(v));
+
+ assertEquals(8, arr.lastIndexOf(obj));
+ assertEquals(8, arr.indexOf(obj));
+}
+
+function g(v, x, index) {
+ var arr = new Array({}, x-1.1, x-2, x-3.1);
+ assertEquals(index, arr.indexOf(0));
+ assertEquals(index, arr.lastIndexOf(0));
+
+ assertEquals(index, arr.indexOf(v));
+ assertEquals(index, arr.lastIndexOf(v));
+}
+
+f(-(4/3));
+f(-(4/3));
+%OptimizeFunctionOnNextCall(f);
+f(-(4/3));
+
+g(0, 2, 2);
+g(0, 3.1, 3);
+%OptimizeFunctionOnNextCall(g);
+g(0, 1.1, 1);
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-382513.js b/deps/v8/test/mjsunit/regress/regress-crbug-382513.js
new file mode 100644
index 0000000000..59d2dcac72
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-382513.js
@@ -0,0 +1,11 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function foo() { return [+0,false].indexOf(-(4/3)); }
+foo();
+foo();
+%OptimizeFunctionOnNextCall(foo);
+foo();
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-385002.js b/deps/v8/test/mjsunit/regress/regress-crbug-385002.js
new file mode 100644
index 0000000000..34713e27d4
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-385002.js
@@ -0,0 +1,15 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --stack-size=200 --allow-natives-syntax
+
+%Break(); // Schedule an interrupt that does not go away.
+
+function f() { f(); }
+assertThrows(f, RangeError);
+
+var locals = "";
+for (var i = 0; i < 1024; i++) locals += "var v" + i + ";";
+eval("function g() {" + locals + "f();}");
+assertThrows("g()", RangeError);
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-387599.js b/deps/v8/test/mjsunit/regress/regress-crbug-387599.js
new file mode 100644
index 0000000000..98750aa918
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-387599.js
@@ -0,0 +1,19 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --expose-debug-as debug
+
+Debug = debug.Debug;
+Debug.setListener(function() {});
+
+function f() {
+ for (var i = 0; i < 100; i++) {
+ %OptimizeFunctionOnNextCall(f, "osr");
+ }
+}
+
+Debug.setBreakPoint(f, 0, 0);
+f();
+f();
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-387627.js b/deps/v8/test/mjsunit/regress/regress-crbug-387627.js
new file mode 100644
index 0000000000..5c6389b5f1
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-387627.js
@@ -0,0 +1,13 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function f() {}
+%FunctionBindArguments(f, {}, undefined, 1);
+
+f();
+f();
+%OptimizeFunctionOnNextCall(f);
+f();
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-387636.js b/deps/v8/test/mjsunit/regress/regress-crbug-387636.js
new file mode 100644
index 0000000000..1e50ace45a
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-387636.js
@@ -0,0 +1,14 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function f() {
+ [].indexOf(0x40000000);
+}
+
+f();
+f();
+%OptimizeFunctionOnNextCall(f);
+f();
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-390918.js b/deps/v8/test/mjsunit/regress/regress-crbug-390918.js
new file mode 100644
index 0000000000..4c202b3a9b
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-390918.js
@@ -0,0 +1,18 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function f(scale) {
+ var arr = {a: 1.1};
+
+ for (var i = 0; i < 2; i++) {
+ arr[2 * scale] = 0;
+ }
+}
+
+f({});
+f({});
+%OptimizeFunctionOnNextCall(f);
+f(1004);
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-390925.js b/deps/v8/test/mjsunit/regress/regress-crbug-390925.js
new file mode 100644
index 0000000000..24873df17b
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-390925.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+var a = new Array();
+Object.freeze(a);
+assertThrows(function() { %LiveEditCheckAndDropActivations(a, true); });
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-393988.js b/deps/v8/test/mjsunit/regress/regress-crbug-393988.js
new file mode 100644
index 0000000000..9543e1e4c4
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-393988.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+var o = {};
+Error.captureStackTrace(o);
+Object.defineProperty(o, "stack", { value: 1 });
+assertEquals(1, o.stack);
diff --git a/deps/v8/test/mjsunit/regress/regress-crbug-401915.js b/deps/v8/test/mjsunit/regress/regress-crbug-401915.js
new file mode 100644
index 0000000000..96dce04868
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-crbug-401915.js
@@ -0,0 +1,20 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax --expose-debug-as debug
+
+Debug = debug.Debug;
+Debug.setListener(function() {});
+Debug.setBreakOnException();
+
+try {
+ try {
+ %DebugPushPromise(new Promise(function() {}));
+ } catch (e) {
+ }
+ throw new Error();
+} catch (e) {
+}
+
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/regress/regress-create-exception.js b/deps/v8/test/mjsunit/regress/regress-create-exception.js
index e0553041ac..440449cf5f 100644
--- a/deps/v8/test/mjsunit/regress/regress-create-exception.js
+++ b/deps/v8/test/mjsunit/regress/regress-create-exception.js
@@ -25,7 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --max-new-space-size=2
+// Flags: --max-semi-space-size=1
"use strict";
// Check for GC bug constructing exceptions.
diff --git a/deps/v8/test/mjsunit/regress/regress-debug-context-load.js b/deps/v8/test/mjsunit/regress/regress-debug-context-load.js
new file mode 100644
index 0000000000..0b3c275f99
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-debug-context-load.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-debug-as debug
+
+Debug = debug.Debug;
+Debug.setListener(null);
diff --git a/deps/v8/test/mjsunit/regress/regress-double-property.js b/deps/v8/test/mjsunit/regress/regress-double-property.js
new file mode 100644
index 0000000000..2ddb45b4b6
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-double-property.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+function f(a) {
+ return {0.1: a};
+}
+
+f();
diff --git a/deps/v8/test/mjsunit/regress/regress-escape-preserve-smi-representation.js b/deps/v8/test/mjsunit/regress/regress-escape-preserve-smi-representation.js
index 551147ed55..fd899d64e2 100644
--- a/deps/v8/test/mjsunit/regress/regress-escape-preserve-smi-representation.js
+++ b/deps/v8/test/mjsunit/regress/regress-escape-preserve-smi-representation.js
@@ -12,7 +12,7 @@ function deepEquals(a, b) {
if (objectClass === "RegExp") { return (a.toString() === b.toString()); }
if (objectClass === "Function") return false;
if (objectClass === "Array") {
- var elementCount = 0;
+ var elementsCount = 0;
if (a.length != b.length) { return false; }
for (var i = 0; i < a.length; i++) {
if (!deepEquals(a[i], b[i])) return false;
@@ -23,12 +23,11 @@ function deepEquals(a, b) {
function __f_1(){
- var __v_0 = [];
- for(var i=0; i<2; i++){
- var __v_1=[];
- __v_0.push([])
- deepEquals(2, __v_0.length);
- }
+ var __v_0 = [];
+ for(var i=0; i<2; i++){
+ __v_0.push([])
+ deepEquals(2, __v_0.length);
+ }
}
__f_1();
%OptimizeFunctionOnNextCall(__f_1);
diff --git a/deps/v8/test/mjsunit/regress/regress-global-freeze-const.js b/deps/v8/test/mjsunit/regress/regress-freeze-setter.js
index 0b9e1f3ebd..c5ac98667f 100644
--- a/deps/v8/test/mjsunit/regress/regress-global-freeze-const.js
+++ b/deps/v8/test/mjsunit/regress/regress-freeze-setter.js
@@ -2,6 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-__defineSetter__('x', function() { });
+Object.defineProperty(this, 'x', {set: function() { }});
Object.freeze(this);
-eval('const x = 1');
+eval('"use strict"; x = 20;');
diff --git a/deps/v8/test/mjsunit/regress/regress-function-constructor-receiver.js b/deps/v8/test/mjsunit/regress/regress-function-constructor-receiver.js
new file mode 100644
index 0000000000..f345435ade
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-function-constructor-receiver.js
@@ -0,0 +1,17 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Return the raw CallSites array.
+Error.prepareStackTrace = function (a,b) { return b; };
+
+var threw = false;
+try {
+ new Function({toString:0,valueOf:0});
+} catch (e) {
+ threw = true;
+ // Ensure that the receiver during "new Function" is the global proxy.
+ assertEquals(this, e.stack[0].getThis());
+}
+
+assertTrue(threw);
diff --git a/deps/v8/test/mjsunit/regress/regress-mask-array-length.js b/deps/v8/test/mjsunit/regress/regress-mask-array-length.js
new file mode 100644
index 0000000000..bd87e7c5db
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-mask-array-length.js
@@ -0,0 +1,10 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+var a = [];
+var o = {
+ __proto__: a
+};
+Object.preventExtensions(o);
+o.length = 'abc';
diff --git a/deps/v8/test/mjsunit/harmony/typeof.js b/deps/v8/test/mjsunit/regress/regress-regexp-nocase.js
index acde97785f..27637da091 100644
--- a/deps/v8/test/mjsunit/harmony/typeof.js
+++ b/deps/v8/test/mjsunit/regress/regress-regexp-nocase.js
@@ -1,4 +1,4 @@
-// Copyright 2011 the V8 project authors. All rights reserved.
+// Copyright 2014 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
@@ -25,11 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --harmony-typeof
+var s = "('')x\nx\uF670";
-assertFalse(typeof null == 'object')
-assertFalse(typeof null === 'object')
-assertTrue(typeof null == 'null')
-assertTrue(typeof null === 'null')
-assertEquals("null", typeof null)
-assertSame("null", typeof null)
+assertEquals(s.match(/\((').*\1\)/i), ["('')", "'"]);
diff --git a/deps/v8/test/mjsunit/regress/regress-set-flags-stress-compact.js b/deps/v8/test/mjsunit/regress/regress-set-flags-stress-compact.js
new file mode 100644
index 0000000000..5bc59a7e11
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-set-flags-stress-compact.js
@@ -0,0 +1,10 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+%SetFlags("--gc-interval=164 --stress-compaction");
+
+var a = [];
+for (var i = 0; i < 10000; i++) { a[i * 100] = 0; }
diff --git a/deps/v8/test/mjsunit/regress/regress-update-field-type-attributes.js b/deps/v8/test/mjsunit/regress/regress-update-field-type-attributes.js
new file mode 100644
index 0000000000..c23d062067
--- /dev/null
+++ b/deps/v8/test/mjsunit/regress/regress-update-field-type-attributes.js
@@ -0,0 +1,12 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+function test(){
+ function InnerClass(){}
+ var container = {field: new InnerClass()};
+ return Object.freeze(container);
+};
+
+assertTrue(Object.isFrozen(test()));
+assertTrue(Object.isFrozen(test()));
diff --git a/deps/v8/test/mjsunit/runtime-gen/apply.js b/deps/v8/test/mjsunit/runtime-gen/apply.js
new file mode 100644
index 0000000000..94c4753cb9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/apply.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = function() {};
+var _receiver = new Object();
+var _arguments = new Object();
+var _offset = 1;
+var _argc = 1;
+%Apply(arg0, _receiver, _arguments, _offset, _argc);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybuffergetbytelength.js b/deps/v8/test/mjsunit/runtime-gen/arraybuffergetbytelength.js
new file mode 100644
index 0000000000..8aff9ac073
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybuffergetbytelength.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new ArrayBuffer(8);
+%ArrayBufferGetByteLength(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybufferinitialize.js b/deps/v8/test/mjsunit/runtime-gen/arraybufferinitialize.js
new file mode 100644
index 0000000000..c4520c6a64
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybufferinitialize.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new ArrayBuffer(8);
+var _byteLength = 1.5;
+%ArrayBufferInitialize(_holder, _byteLength);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybufferisview.js b/deps/v8/test/mjsunit/runtime-gen/arraybufferisview.js
new file mode 100644
index 0000000000..46cc5ba995
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybufferisview.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%ArrayBufferIsView(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybufferneuter.js b/deps/v8/test/mjsunit/runtime-gen/arraybufferneuter.js
new file mode 100644
index 0000000000..89e9ee96b7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybufferneuter.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _array_buffer = new ArrayBuffer(8);
+%ArrayBufferNeuter(_array_buffer);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybuffersliceimpl.js b/deps/v8/test/mjsunit/runtime-gen/arraybuffersliceimpl.js
new file mode 100644
index 0000000000..cb02bb069c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybuffersliceimpl.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _source = new ArrayBuffer(8);
+var _target = new ArrayBuffer(8);
+var arg2 = 0;
+%ArrayBufferSliceImpl(_source, _target, arg2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbytelength.js b/deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbytelength.js
new file mode 100644
index 0000000000..e32ea0d4e7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbytelength.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Int32Array(2);
+%ArrayBufferViewGetByteLength(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbyteoffset.js b/deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbyteoffset.js
new file mode 100644
index 0000000000..4c64ff206d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arraybufferviewgetbyteoffset.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Int32Array(2);
+%ArrayBufferViewGetByteOffset(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/arrayconcat.js b/deps/v8/test/mjsunit/runtime-gen/arrayconcat.js
new file mode 100644
index 0000000000..09487a6073
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/arrayconcat.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = [1, 'a'];
+%ArrayConcat(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/availablelocalesof.js b/deps/v8/test/mjsunit/runtime-gen/availablelocalesof.js
new file mode 100644
index 0000000000..a59c9b077c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/availablelocalesof.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _service = "foo";
+%AvailableLocalesOf(_service);
diff --git a/deps/v8/test/mjsunit/runtime-gen/basicjsonstringify.js b/deps/v8/test/mjsunit/runtime-gen/basicjsonstringify.js
new file mode 100644
index 0000000000..55d197831e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/basicjsonstringify.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%BasicJSONStringify(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/booleanize.js b/deps/v8/test/mjsunit/runtime-gen/booleanize.js
new file mode 100644
index 0000000000..8685368e4f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/booleanize.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _value_raw = new Object();
+var _token_raw = 1;
+%Booleanize(_value_raw, _token_raw);
diff --git a/deps/v8/test/mjsunit/runtime-gen/boundfunctiongetbindings.js b/deps/v8/test/mjsunit/runtime-gen/boundfunctiongetbindings.js
new file mode 100644
index 0000000000..9221d3dd28
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/boundfunctiongetbindings.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _callable = new Object();
+%BoundFunctionGetBindings(_callable);
diff --git a/deps/v8/test/mjsunit/runtime-gen/break.js b/deps/v8/test/mjsunit/runtime-gen/break.js
new file mode 100644
index 0000000000..4b600d8e3d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/break.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%Break();
diff --git a/deps/v8/test/mjsunit/runtime-gen/breakiteratoradopttext.js b/deps/v8/test/mjsunit/runtime-gen/breakiteratoradopttext.js
new file mode 100644
index 0000000000..64b6059da3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/breakiteratoradopttext.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.v8BreakIterator());
+var _text = "foo";
+%BreakIteratorAdoptText(arg0, _text);
diff --git a/deps/v8/test/mjsunit/runtime-gen/breakiteratorbreaktype.js b/deps/v8/test/mjsunit/runtime-gen/breakiteratorbreaktype.js
new file mode 100644
index 0000000000..08cceb87f8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/breakiteratorbreaktype.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.v8BreakIterator());
+%BreakIteratorBreakType(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/breakiteratorcurrent.js b/deps/v8/test/mjsunit/runtime-gen/breakiteratorcurrent.js
new file mode 100644
index 0000000000..42000a846c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/breakiteratorcurrent.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.v8BreakIterator());
+%BreakIteratorCurrent(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/breakiteratorfirst.js b/deps/v8/test/mjsunit/runtime-gen/breakiteratorfirst.js
new file mode 100644
index 0000000000..3fad88c9e3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/breakiteratorfirst.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.v8BreakIterator());
+%BreakIteratorFirst(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/breakiteratornext.js b/deps/v8/test/mjsunit/runtime-gen/breakiteratornext.js
new file mode 100644
index 0000000000..be72ffc1d6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/breakiteratornext.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.v8BreakIterator());
+%BreakIteratorNext(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/canonicalizelanguagetag.js b/deps/v8/test/mjsunit/runtime-gen/canonicalizelanguagetag.js
new file mode 100644
index 0000000000..45df230a40
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/canonicalizelanguagetag.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _locale_id_str = "foo";
+%CanonicalizeLanguageTag(_locale_id_str);
diff --git a/deps/v8/test/mjsunit/runtime-gen/changebreakonexception.js b/deps/v8/test/mjsunit/runtime-gen/changebreakonexception.js
new file mode 100644
index 0000000000..4bc0d43d01
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/changebreakonexception.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _type_arg = 32;
+var _enable = true;
+%ChangeBreakOnException(_type_arg, _enable);
diff --git a/deps/v8/test/mjsunit/runtime-gen/charfromcode.js b/deps/v8/test/mjsunit/runtime-gen/charfromcode.js
new file mode 100644
index 0000000000..20823391da
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/charfromcode.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _code = 32;
+%CharFromCode(_code);
diff --git a/deps/v8/test/mjsunit/runtime-gen/checkexecutionstate.js b/deps/v8/test/mjsunit/runtime-gen/checkexecutionstate.js
new file mode 100644
index 0000000000..7e740c39f6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/checkexecutionstate.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+try {
+%CheckExecutionState(_break_id);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/checkisbootstrapping.js b/deps/v8/test/mjsunit/runtime-gen/checkisbootstrapping.js
new file mode 100644
index 0000000000..114b20c1c8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/checkisbootstrapping.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+try {
+%CheckIsBootstrapping();
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/clearbreakpoint.js b/deps/v8/test/mjsunit/runtime-gen/clearbreakpoint.js
new file mode 100644
index 0000000000..1c11bc8f74
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/clearbreakpoint.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_point_object_arg = new Object();
+%ClearBreakPoint(_break_point_object_arg);
diff --git a/deps/v8/test/mjsunit/runtime-gen/clearfunctiontypefeedback.js b/deps/v8/test/mjsunit/runtime-gen/clearfunctiontypefeedback.js
new file mode 100644
index 0000000000..f42b8da200
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/clearfunctiontypefeedback.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+%ClearFunctionTypeFeedback(_function);
diff --git a/deps/v8/test/mjsunit/runtime-gen/clearstepping.js b/deps/v8/test/mjsunit/runtime-gen/clearstepping.js
new file mode 100644
index 0000000000..bfab2cde0b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/clearstepping.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%ClearStepping();
diff --git a/deps/v8/test/mjsunit/runtime-gen/collectstacktrace.js b/deps/v8/test/mjsunit/runtime-gen/collectstacktrace.js
new file mode 100644
index 0000000000..bac9b6a66c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/collectstacktrace.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _error_object = new Object();
+var _caller = new Object();
+%CollectStackTrace(_error_object, _caller);
diff --git a/deps/v8/test/mjsunit/runtime-gen/compilestring.js b/deps/v8/test/mjsunit/runtime-gen/compilestring.js
new file mode 100644
index 0000000000..659afcaaef
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/compilestring.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _source = "foo";
+var arg1 = false;
+%CompileString(_source, arg1);
diff --git a/deps/v8/test/mjsunit/runtime-gen/constructdouble.js b/deps/v8/test/mjsunit/runtime-gen/constructdouble.js
new file mode 100644
index 0000000000..9ac3dee9c0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/constructdouble.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _hi = 32;
+var _lo = 32;
+%ConstructDouble(_hi, _lo);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createbreakiterator.js b/deps/v8/test/mjsunit/runtime-gen/createbreakiterator.js
new file mode 100644
index 0000000000..a8750b3399
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createbreakiterator.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = 'en-US';
+var arg1 = {type: 'string'};
+var _resolved = new Object();
+%CreateBreakIterator(arg0, arg1, _resolved);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createcollator.js b/deps/v8/test/mjsunit/runtime-gen/createcollator.js
new file mode 100644
index 0000000000..0d5b18d55d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createcollator.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _locale = "foo";
+var _options = new Object();
+var _resolved = new Object();
+%CreateCollator(_locale, _options, _resolved);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createglobalprivatesymbol.js b/deps/v8/test/mjsunit/runtime-gen/createglobalprivatesymbol.js
new file mode 100644
index 0000000000..e4968c14f3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createglobalprivatesymbol.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _name = "foo";
+%CreateGlobalPrivateSymbol(_name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createjsfunctionproxy.js b/deps/v8/test/mjsunit/runtime-gen/createjsfunctionproxy.js
new file mode 100644
index 0000000000..b4e1c31ae8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createjsfunctionproxy.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _handler = new Object();
+var arg1 = function() {};
+var _construct_trap = function() {};
+var _prototype = new Object();
+%CreateJSFunctionProxy(_handler, arg1, _construct_trap, _prototype);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createjsproxy.js b/deps/v8/test/mjsunit/runtime-gen/createjsproxy.js
new file mode 100644
index 0000000000..ecdef60223
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createjsproxy.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _handler = new Object();
+var _prototype = new Object();
+%CreateJSProxy(_handler, _prototype);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createprivateownsymbol.js b/deps/v8/test/mjsunit/runtime-gen/createprivateownsymbol.js
new file mode 100644
index 0000000000..74548287c1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createprivateownsymbol.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = "foo";
+%CreatePrivateOwnSymbol(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createprivatesymbol.js b/deps/v8/test/mjsunit/runtime-gen/createprivatesymbol.js
new file mode 100644
index 0000000000..bbd99c12b8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createprivatesymbol.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = "foo";
+%CreatePrivateSymbol(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/createsymbol.js b/deps/v8/test/mjsunit/runtime-gen/createsymbol.js
new file mode 100644
index 0000000000..8452b9c90b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/createsymbol.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = "foo";
+%CreateSymbol(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetbuffer.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetbuffer.js
new file mode 100644
index 0000000000..84bab807f3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetbuffer.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+%DataViewGetBuffer(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat32.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat32.js
new file mode 100644
index 0000000000..57f3c2a596
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat32.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetFloat32(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat64.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat64.js
new file mode 100644
index 0000000000..7f80c5b0a0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetfloat64.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetFloat64(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetint16.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetint16.js
new file mode 100644
index 0000000000..e618c1c00a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetint16.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetInt16(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetint32.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetint32.js
new file mode 100644
index 0000000000..2395a6dd9c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetint32.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetInt32(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetint8.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetint8.js
new file mode 100644
index 0000000000..fe92ed7c35
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetint8.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetInt8(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint16.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint16.js
new file mode 100644
index 0000000000..50be62b009
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint16.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetUint16(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint32.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint32.js
new file mode 100644
index 0000000000..2f85aeef8a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint32.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetUint32(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint8.js b/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint8.js
new file mode 100644
index 0000000000..6a682e1731
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewgetuint8.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _is_little_endian = true;
+%DataViewGetUint8(_holder, _offset, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewinitialize.js b/deps/v8/test/mjsunit/runtime-gen/dataviewinitialize.js
new file mode 100644
index 0000000000..167d531562
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewinitialize.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _buffer = new ArrayBuffer(8);
+var _byte_offset = 1.5;
+var _byte_length = 1.5;
+%DataViewInitialize(_holder, _buffer, _byte_offset, _byte_length);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat32.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat32.js
new file mode 100644
index 0000000000..46d00afff0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat32.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetFloat32(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat64.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat64.js
new file mode 100644
index 0000000000..c57b514dd0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetfloat64.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetFloat64(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetint16.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetint16.js
new file mode 100644
index 0000000000..1f45448f69
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetint16.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetInt16(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetint32.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetint32.js
new file mode 100644
index 0000000000..837d4f26d5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetint32.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetInt32(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetint8.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetint8.js
new file mode 100644
index 0000000000..725e658ec4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetint8.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetInt8(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint16.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint16.js
new file mode 100644
index 0000000000..d1b1a24bcd
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint16.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetUint16(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint32.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint32.js
new file mode 100644
index 0000000000..e46c8f302a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint32.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetUint32(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint8.js b/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint8.js
new file mode 100644
index 0000000000..6c36723082
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dataviewsetuint8.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new DataView(new ArrayBuffer(24));
+var _offset = 1.5;
+var _value = 1.5;
+var _is_little_endian = true;
+%DataViewSetUint8(_holder, _offset, _value, _is_little_endian);
diff --git a/deps/v8/test/mjsunit/runtime-gen/datecacheversion.js b/deps/v8/test/mjsunit/runtime-gen/datecacheversion.js
new file mode 100644
index 0000000000..ea56c73c74
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/datecacheversion.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%DateCacheVersion();
diff --git a/deps/v8/test/mjsunit/runtime-gen/datecurrenttime.js b/deps/v8/test/mjsunit/runtime-gen/datecurrenttime.js
new file mode 100644
index 0000000000..759ebd0038
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/datecurrenttime.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%DateCurrentTime();
diff --git a/deps/v8/test/mjsunit/runtime-gen/datelocaltimezone.js b/deps/v8/test/mjsunit/runtime-gen/datelocaltimezone.js
new file mode 100644
index 0000000000..bfc1a81c7f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/datelocaltimezone.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%DateLocalTimezone(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/datemakeday.js b/deps/v8/test/mjsunit/runtime-gen/datemakeday.js
new file mode 100644
index 0000000000..3d2334f51e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/datemakeday.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _year = 1;
+var _month = 1;
+%DateMakeDay(_year, _month);
diff --git a/deps/v8/test/mjsunit/runtime-gen/dateparsestring.js b/deps/v8/test/mjsunit/runtime-gen/dateparsestring.js
new file mode 100644
index 0000000000..fdf5faa7e9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/dateparsestring.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _str = "foo";
+var arg1 = new Array(8);
+%DateParseString(_str, arg1);
diff --git a/deps/v8/test/mjsunit/runtime-gen/datesetvalue.js b/deps/v8/test/mjsunit/runtime-gen/datesetvalue.js
new file mode 100644
index 0000000000..dac1a36447
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/datesetvalue.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _date = new Date();
+var _time = 1.5;
+var _is_utc = 1;
+%DateSetValue(_date, _time, _is_utc);
diff --git a/deps/v8/test/mjsunit/runtime-gen/datetoutc.js b/deps/v8/test/mjsunit/runtime-gen/datetoutc.js
new file mode 100644
index 0000000000..f46644e951
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/datetoutc.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%DateToUTC(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugasynctaskevent.js b/deps/v8/test/mjsunit/runtime-gen/debugasynctaskevent.js
new file mode 100644
index 0000000000..ceeaf13774
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugasynctaskevent.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _data = new Object();
+%DebugAsyncTaskEvent(_data);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugbreak.js b/deps/v8/test/mjsunit/runtime-gen/debugbreak.js
new file mode 100644
index 0000000000..68220dfa9b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugbreak.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%DebugBreak();
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugcallbacksupportsstepping.js b/deps/v8/test/mjsunit/runtime-gen/debugcallbacksupportsstepping.js
new file mode 100644
index 0000000000..b683be0aa4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugcallbacksupportsstepping.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _callback = new Object();
+%DebugCallbackSupportsStepping(_callback);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugconstructedby.js b/deps/v8/test/mjsunit/runtime-gen/debugconstructedby.js
new file mode 100644
index 0000000000..885034429b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugconstructedby.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _constructor = function() {};
+var _max_references = 32;
+%DebugConstructedBy(_constructor, _max_references);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugdisassembleconstructor.js b/deps/v8/test/mjsunit/runtime-gen/debugdisassembleconstructor.js
new file mode 100644
index 0000000000..c2faca4f0c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugdisassembleconstructor.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _func = function() {};
+%DebugDisassembleConstructor(_func);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugdisassemblefunction.js b/deps/v8/test/mjsunit/runtime-gen/debugdisassemblefunction.js
new file mode 100644
index 0000000000..f65886779d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugdisassemblefunction.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _func = function() {};
+%DebugDisassembleFunction(_func);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugevaluate.js b/deps/v8/test/mjsunit/runtime-gen/debugevaluate.js
new file mode 100644
index 0000000000..60e1e63fd0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugevaluate.js
@@ -0,0 +1,12 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _wrapped_id = 1;
+var _inlined_jsframe_index = 32;
+var _source = "foo";
+var _disable_break = true;
+var _context_extension = new Object();
+try {
+%DebugEvaluate(_break_id, _wrapped_id, _inlined_jsframe_index, _source, _disable_break, _context_extension);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugevaluateglobal.js b/deps/v8/test/mjsunit/runtime-gen/debugevaluateglobal.js
new file mode 100644
index 0000000000..11411d1992
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugevaluateglobal.js
@@ -0,0 +1,10 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _source = "foo";
+var _disable_break = true;
+var _context_extension = new Object();
+try {
+%DebugEvaluateGlobal(_break_id, _source, _disable_break, _context_extension);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/debuggetproperty.js b/deps/v8/test/mjsunit/runtime-gen/debuggetproperty.js
new file mode 100644
index 0000000000..90109d1dc8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debuggetproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _name = "name";
+%DebugGetProperty(_obj, _name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debuggetpropertydetails.js b/deps/v8/test/mjsunit/runtime-gen/debuggetpropertydetails.js
new file mode 100644
index 0000000000..0fe2f3104f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debuggetpropertydetails.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _name = "name";
+%DebugGetPropertyDetails(_obj, _name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debuggetprototype.js b/deps/v8/test/mjsunit/runtime-gen/debuggetprototype.js
new file mode 100644
index 0000000000..27de855b7b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debuggetprototype.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%DebugGetPrototype(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugindexedinterceptorelementvalue.js b/deps/v8/test/mjsunit/runtime-gen/debugindexedinterceptorelementvalue.js
new file mode 100644
index 0000000000..22d24eead9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugindexedinterceptorelementvalue.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _index = 32;
+try {
+%DebugIndexedInterceptorElementValue(_obj, _index);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugnamedinterceptorpropertyvalue.js b/deps/v8/test/mjsunit/runtime-gen/debugnamedinterceptorpropertyvalue.js
new file mode 100644
index 0000000000..13641d2c2b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugnamedinterceptorpropertyvalue.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _name = "name";
+try {
+%DebugNamedInterceptorPropertyValue(_obj, _name);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpoppromise.js b/deps/v8/test/mjsunit/runtime-gen/debugpoppromise.js
new file mode 100644
index 0000000000..9b81b13705
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpoppromise.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%DebugPopPromise();
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpreparestepinifstepping.js b/deps/v8/test/mjsunit/runtime-gen/debugpreparestepinifstepping.js
new file mode 100644
index 0000000000..a6061e6f98
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpreparestepinifstepping.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _callback = function() {};
+%DebugPrepareStepInIfStepping(_callback);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugprintscopes.js b/deps/v8/test/mjsunit/runtime-gen/debugprintscopes.js
new file mode 100644
index 0000000000..2f106ddb6a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugprintscopes.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%DebugPrintScopes();
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpromiseevent.js b/deps/v8/test/mjsunit/runtime-gen/debugpromiseevent.js
new file mode 100644
index 0000000000..20ae13c67a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpromiseevent.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _data = new Object();
+%DebugPromiseEvent(_data);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpromiserejectevent.js b/deps/v8/test/mjsunit/runtime-gen/debugpromiserejectevent.js
new file mode 100644
index 0000000000..4e6e633426
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpromiserejectevent.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _promise = new Object();
+var _value = new Object();
+%DebugPromiseRejectEvent(_promise, _value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpropertyattributesfromdetails.js b/deps/v8/test/mjsunit/runtime-gen/debugpropertyattributesfromdetails.js
new file mode 100644
index 0000000000..7802a35242
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpropertyattributesfromdetails.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _details = 513;
+%DebugPropertyAttributesFromDetails(_details);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpropertyindexfromdetails.js b/deps/v8/test/mjsunit/runtime-gen/debugpropertyindexfromdetails.js
new file mode 100644
index 0000000000..02edeeee24
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpropertyindexfromdetails.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _details = 513;
+%DebugPropertyIndexFromDetails(_details);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpropertytypefromdetails.js b/deps/v8/test/mjsunit/runtime-gen/debugpropertytypefromdetails.js
new file mode 100644
index 0000000000..551ff2c621
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpropertytypefromdetails.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _details = 513;
+%DebugPropertyTypeFromDetails(_details);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugpushpromise.js b/deps/v8/test/mjsunit/runtime-gen/debugpushpromise.js
new file mode 100644
index 0000000000..350a61354a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugpushpromise.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _promise = new Object();
+%DebugPushPromise(_promise);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugreferencedby.js b/deps/v8/test/mjsunit/runtime-gen/debugreferencedby.js
new file mode 100644
index 0000000000..94e1242793
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugreferencedby.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _target = new Object();
+var _instance_filter = new Object();
+var _max_references = 32;
+%DebugReferencedBy(_target, _instance_filter, _max_references);
diff --git a/deps/v8/test/mjsunit/runtime-gen/debugtrace.js b/deps/v8/test/mjsunit/runtime-gen/debugtrace.js
new file mode 100644
index 0000000000..2933ad114d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/debugtrace.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%DebugTrace();
diff --git a/deps/v8/test/mjsunit/runtime-gen/defineaccessorpropertyunchecked.js b/deps/v8/test/mjsunit/runtime-gen/defineaccessorpropertyunchecked.js
new file mode 100644
index 0000000000..c6cbb91cc7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/defineaccessorpropertyunchecked.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _name = "name";
+var arg2 = function() {};
+var arg3 = function() {};
+var arg4 = 2;
+%DefineAccessorPropertyUnchecked(_obj, _name, arg2, arg3, arg4);
diff --git a/deps/v8/test/mjsunit/runtime-gen/defineapiaccessorproperty.js b/deps/v8/test/mjsunit/runtime-gen/defineapiaccessorproperty.js
new file mode 100644
index 0000000000..856a53129e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/defineapiaccessorproperty.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _name = "name";
+var arg2 = undefined;
+var arg3 = undefined;
+var _attribute = 1;
+%DefineApiAccessorProperty(_object, _name, arg2, arg3, _attribute);
diff --git a/deps/v8/test/mjsunit/runtime-gen/definedatapropertyunchecked.js b/deps/v8/test/mjsunit/runtime-gen/definedatapropertyunchecked.js
new file mode 100644
index 0000000000..cb0f07f600
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/definedatapropertyunchecked.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _js_object = new Object();
+var _name = "name";
+var _obj_value = new Object();
+var _unchecked = 1;
+%DefineDataPropertyUnchecked(_js_object, _name, _obj_value, _unchecked);
diff --git a/deps/v8/test/mjsunit/runtime-gen/deleteproperty.js b/deps/v8/test/mjsunit/runtime-gen/deleteproperty.js
new file mode 100644
index 0000000000..66a882b1ab
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/deleteproperty.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _key = "name";
+var _strict_mode = 1;
+%DeleteProperty(_object, _key, _strict_mode);
diff --git a/deps/v8/test/mjsunit/runtime-gen/deoptimizefunction.js b/deps/v8/test/mjsunit/runtime-gen/deoptimizefunction.js
new file mode 100644
index 0000000000..ec5db2ddae
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/deoptimizefunction.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+%DeoptimizeFunction(_function);
diff --git a/deps/v8/test/mjsunit/runtime-gen/doublehi.js b/deps/v8/test/mjsunit/runtime-gen/doublehi.js
new file mode 100644
index 0000000000..ac945dcd28
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/doublehi.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%DoubleHi(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/doublelo.js b/deps/v8/test/mjsunit/runtime-gen/doublelo.js
new file mode 100644
index 0000000000..42c4c25495
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/doublelo.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%DoubleLo(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/enqueuemicrotask.js b/deps/v8/test/mjsunit/runtime-gen/enqueuemicrotask.js
new file mode 100644
index 0000000000..2f21667613
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/enqueuemicrotask.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _microtask = function() {};
+%EnqueueMicrotask(_microtask);
diff --git a/deps/v8/test/mjsunit/runtime-gen/estimatenumberofelements.js b/deps/v8/test/mjsunit/runtime-gen/estimatenumberofelements.js
new file mode 100644
index 0000000000..cf3b9b606f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/estimatenumberofelements.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _array = new Array();
+%EstimateNumberOfElements(_array);
diff --git a/deps/v8/test/mjsunit/runtime-gen/executeindebugcontext.js b/deps/v8/test/mjsunit/runtime-gen/executeindebugcontext.js
new file mode 100644
index 0000000000..18bfac9b53
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/executeindebugcontext.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+var _without_debugger = true;
+%ExecuteInDebugContext(_function, _without_debugger);
diff --git a/deps/v8/test/mjsunit/runtime-gen/finisharrayprototypesetup.js b/deps/v8/test/mjsunit/runtime-gen/finisharrayprototypesetup.js
new file mode 100644
index 0000000000..e4e8eabab4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/finisharrayprototypesetup.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _prototype = new Array();
+%FinishArrayPrototypeSetup(_prototype);
diff --git a/deps/v8/test/mjsunit/runtime-gen/fix.js b/deps/v8/test/mjsunit/runtime-gen/fix.js
new file mode 100644
index 0000000000..010d2bcb70
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/fix.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _proxy = Proxy.create({});
+%Fix(_proxy);
diff --git a/deps/v8/test/mjsunit/runtime-gen/flattenstring.js b/deps/v8/test/mjsunit/runtime-gen/flattenstring.js
new file mode 100644
index 0000000000..3f0b38d6c8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/flattenstring.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _str = "foo";
+%FlattenString(_str);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionbindarguments.js b/deps/v8/test/mjsunit/runtime-gen/functionbindarguments.js
new file mode 100644
index 0000000000..4d36716253
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionbindarguments.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _bound_function = function() {};
+var _bindee = new Object();
+var arg2 = undefined;
+var _new_length = 1.5;
+%FunctionBindArguments(_bound_function, _bindee, arg2, _new_length);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functiongetinferredname.js b/deps/v8/test/mjsunit/runtime-gen/functiongetinferredname.js
new file mode 100644
index 0000000000..8d765007cb
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functiongetinferredname.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionGetInferredName(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functiongetname.js b/deps/v8/test/mjsunit/runtime-gen/functiongetname.js
new file mode 100644
index 0000000000..ad23b11a69
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functiongetname.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionGetName(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functiongetscript.js b/deps/v8/test/mjsunit/runtime-gen/functiongetscript.js
new file mode 100644
index 0000000000..bd4364447e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functiongetscript.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+%FunctionGetScript(_fun);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functiongetscriptsourceposition.js b/deps/v8/test/mjsunit/runtime-gen/functiongetscriptsourceposition.js
new file mode 100644
index 0000000000..eb462f96f7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functiongetscriptsourceposition.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+%FunctionGetScriptSourcePosition(_fun);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functiongetsourcecode.js b/deps/v8/test/mjsunit/runtime-gen/functiongetsourcecode.js
new file mode 100644
index 0000000000..b9de88a15d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functiongetsourcecode.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionGetSourceCode(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionisapifunction.js b/deps/v8/test/mjsunit/runtime-gen/functionisapifunction.js
new file mode 100644
index 0000000000..7fb8a21e0a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionisapifunction.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionIsAPIFunction(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionisarrow.js b/deps/v8/test/mjsunit/runtime-gen/functionisarrow.js
new file mode 100644
index 0000000000..08410b49dd
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionisarrow.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = () => null;
+%FunctionIsArrow(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionisbuiltin.js b/deps/v8/test/mjsunit/runtime-gen/functionisbuiltin.js
new file mode 100644
index 0000000000..a8dd6c6a88
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionisbuiltin.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionIsBuiltin(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionisgenerator.js b/deps/v8/test/mjsunit/runtime-gen/functionisgenerator.js
new file mode 100644
index 0000000000..8be6aab2a7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionisgenerator.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionIsGenerator(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionmarknameshouldprintasanonymous.js b/deps/v8/test/mjsunit/runtime-gen/functionmarknameshouldprintasanonymous.js
new file mode 100644
index 0000000000..74f18e258c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionmarknameshouldprintasanonymous.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionMarkNameShouldPrintAsAnonymous(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionnameshouldprintasanonymous.js b/deps/v8/test/mjsunit/runtime-gen/functionnameshouldprintasanonymous.js
new file mode 100644
index 0000000000..aa5bcddc18
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionnameshouldprintasanonymous.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionNameShouldPrintAsAnonymous(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionremoveprototype.js b/deps/v8/test/mjsunit/runtime-gen/functionremoveprototype.js
new file mode 100644
index 0000000000..a7ec5f52a9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionremoveprototype.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+%FunctionRemovePrototype(_f);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionsetinstanceclassname.js b/deps/v8/test/mjsunit/runtime-gen/functionsetinstanceclassname.js
new file mode 100644
index 0000000000..6986a15b1c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionsetinstanceclassname.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+var _name = "foo";
+%FunctionSetInstanceClassName(_fun, _name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionsetlength.js b/deps/v8/test/mjsunit/runtime-gen/functionsetlength.js
new file mode 100644
index 0000000000..5582e82cf2
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionsetlength.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+var _length = 1;
+%FunctionSetLength(_fun, _length);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionsetname.js b/deps/v8/test/mjsunit/runtime-gen/functionsetname.js
new file mode 100644
index 0000000000..0d44b20317
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionsetname.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _f = function() {};
+var _name = "foo";
+%FunctionSetName(_f, _name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/functionsetprototype.js b/deps/v8/test/mjsunit/runtime-gen/functionsetprototype.js
new file mode 100644
index 0000000000..eb69ea8f5b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/functionsetprototype.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+var _value = new Object();
+%FunctionSetPrototype(_fun, _value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getallscopesdetails.js b/deps/v8/test/mjsunit/runtime-gen/getallscopesdetails.js
new file mode 100644
index 0000000000..97ad7cb538
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getallscopesdetails.js
@@ -0,0 +1,10 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _wrapped_id = 1;
+var _inlined_jsframe_index = 32;
+var _flag = true;
+try {
+%GetAllScopesDetails(_break_id, _wrapped_id, _inlined_jsframe_index, _flag);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getargumentsproperty.js b/deps/v8/test/mjsunit/runtime-gen/getargumentsproperty.js
new file mode 100644
index 0000000000..646e56be9f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getargumentsproperty.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _raw_key = new Object();
+%GetArgumentsProperty(_raw_key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getarraykeys.js b/deps/v8/test/mjsunit/runtime-gen/getarraykeys.js
new file mode 100644
index 0000000000..341faa69ec
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getarraykeys.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _array = new Object();
+var _length = 32;
+%GetArrayKeys(_array, _length);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getbreaklocations.js b/deps/v8/test/mjsunit/runtime-gen/getbreaklocations.js
new file mode 100644
index 0000000000..d31fa15c51
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getbreaklocations.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+var arg1 = 0;
+%GetBreakLocations(_fun, arg1);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getcalltrap.js b/deps/v8/test/mjsunit/runtime-gen/getcalltrap.js
new file mode 100644
index 0000000000..406af9ffd9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getcalltrap.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _proxy = Proxy.createFunction({}, function() {});
+%GetCallTrap(_proxy);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getconstructordelegate.js b/deps/v8/test/mjsunit/runtime-gen/getconstructordelegate.js
new file mode 100644
index 0000000000..6d01415667
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getconstructordelegate.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%GetConstructorDelegate(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getconstructtrap.js b/deps/v8/test/mjsunit/runtime-gen/getconstructtrap.js
new file mode 100644
index 0000000000..116d301eb3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getconstructtrap.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _proxy = Proxy.createFunction({}, function() {});
+%GetConstructTrap(_proxy);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getdataproperty.js b/deps/v8/test/mjsunit/runtime-gen/getdataproperty.js
new file mode 100644
index 0000000000..59cfba56d9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getdataproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _key = "name";
+%GetDataProperty(_object, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getdefaulticulocale.js b/deps/v8/test/mjsunit/runtime-gen/getdefaulticulocale.js
new file mode 100644
index 0000000000..920f256683
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getdefaulticulocale.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%GetDefaultICULocale();
diff --git a/deps/v8/test/mjsunit/runtime-gen/getdefaultreceiver.js b/deps/v8/test/mjsunit/runtime-gen/getdefaultreceiver.js
new file mode 100644
index 0000000000..1d5b1cb44c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getdefaultreceiver.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = function() {};
+%GetDefaultReceiver(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getframecount.js b/deps/v8/test/mjsunit/runtime-gen/getframecount.js
new file mode 100644
index 0000000000..a958efcd7f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getframecount.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+try {
+%GetFrameCount(_break_id);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getframedetails.js b/deps/v8/test/mjsunit/runtime-gen/getframedetails.js
new file mode 100644
index 0000000000..1138424845
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getframedetails.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _index = 32;
+try {
+%GetFrameDetails(_break_id, _index);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getfunctioncodepositionfromsource.js b/deps/v8/test/mjsunit/runtime-gen/getfunctioncodepositionfromsource.js
new file mode 100644
index 0000000000..473b263241
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getfunctioncodepositionfromsource.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+var _source_position = 32;
+%GetFunctionCodePositionFromSource(_function, _source_position);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getfunctiondelegate.js b/deps/v8/test/mjsunit/runtime-gen/getfunctiondelegate.js
new file mode 100644
index 0000000000..4d02ec2194
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getfunctiondelegate.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%GetFunctionDelegate(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getfunctionscopecount.js b/deps/v8/test/mjsunit/runtime-gen/getfunctionscopecount.js
new file mode 100644
index 0000000000..fb854cff42
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getfunctionscopecount.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+%GetFunctionScopeCount(_fun);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getfunctionscopedetails.js b/deps/v8/test/mjsunit/runtime-gen/getfunctionscopedetails.js
new file mode 100644
index 0000000000..c24314003a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getfunctionscopedetails.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+var _index = 32;
+%GetFunctionScopeDetails(_fun, _index);
diff --git a/deps/v8/test/mjsunit/runtime-gen/gethandler.js b/deps/v8/test/mjsunit/runtime-gen/gethandler.js
new file mode 100644
index 0000000000..ea982cbb51
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/gethandler.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _proxy = Proxy.create({});
+%GetHandler(_proxy);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getheapusage.js b/deps/v8/test/mjsunit/runtime-gen/getheapusage.js
new file mode 100644
index 0000000000..cb174b72f2
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getheapusage.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%GetHeapUsage();
diff --git a/deps/v8/test/mjsunit/runtime-gen/getimplfrominitializedintlobject.js b/deps/v8/test/mjsunit/runtime-gen/getimplfrominitializedintlobject.js
new file mode 100644
index 0000000000..899ba8859e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getimplfrominitializedintlobject.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = new Intl.NumberFormat('en-US');
+%GetImplFromInitializedIntlObject(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getindexedinterceptorelementnames.js b/deps/v8/test/mjsunit/runtime-gen/getindexedinterceptorelementnames.js
new file mode 100644
index 0000000000..8a83f0acd6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getindexedinterceptorelementnames.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%GetIndexedInterceptorElementNames(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getinterceptorinfo.js b/deps/v8/test/mjsunit/runtime-gen/getinterceptorinfo.js
new file mode 100644
index 0000000000..b33ba64916
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getinterceptorinfo.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%GetInterceptorInfo(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getlanguagetagvariants.js b/deps/v8/test/mjsunit/runtime-gen/getlanguagetagvariants.js
new file mode 100644
index 0000000000..0ecfee522c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getlanguagetagvariants.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _input = new Array();
+%GetLanguageTagVariants(_input);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getnamedinterceptorpropertynames.js b/deps/v8/test/mjsunit/runtime-gen/getnamedinterceptorpropertynames.js
new file mode 100644
index 0000000000..0dee531be6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getnamedinterceptorpropertynames.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%GetNamedInterceptorPropertyNames(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getobjectcontextnotifierperformchange.js b/deps/v8/test/mjsunit/runtime-gen/getobjectcontextnotifierperformchange.js
new file mode 100644
index 0000000000..2960acee45
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getobjectcontextnotifierperformchange.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object_info = new Object();
+%GetObjectContextNotifierPerformChange(_object_info);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectgetnotifier.js b/deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectgetnotifier.js
new file mode 100644
index 0000000000..d6a043061e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectgetnotifier.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%GetObjectContextObjectGetNotifier(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectobserve.js b/deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectobserve.js
new file mode 100644
index 0000000000..f1669e7385
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getobjectcontextobjectobserve.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%GetObjectContextObjectObserve(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getobservationstate.js b/deps/v8/test/mjsunit/runtime-gen/getobservationstate.js
new file mode 100644
index 0000000000..429cdcd91f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getobservationstate.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%GetObservationState();
diff --git a/deps/v8/test/mjsunit/runtime-gen/getoptimizationcount.js b/deps/v8/test/mjsunit/runtime-gen/getoptimizationcount.js
new file mode 100644
index 0000000000..da1ab9efcc
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getoptimizationcount.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+%GetOptimizationCount(_function);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getownelementnames.js b/deps/v8/test/mjsunit/runtime-gen/getownelementnames.js
new file mode 100644
index 0000000000..54d9a69855
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getownelementnames.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%GetOwnElementNames(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getownproperty.js b/deps/v8/test/mjsunit/runtime-gen/getownproperty.js
new file mode 100644
index 0000000000..1e5a808f71
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getownproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _name = "name";
+%GetOwnProperty(_obj, _name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getownpropertynames.js b/deps/v8/test/mjsunit/runtime-gen/getownpropertynames.js
new file mode 100644
index 0000000000..10f7f2c776
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getownpropertynames.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _filter_value = 1;
+%GetOwnPropertyNames(_obj, _filter_value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getproperty.js b/deps/v8/test/mjsunit/runtime-gen/getproperty.js
new file mode 100644
index 0000000000..569189a3aa
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _key = new Object();
+%GetProperty(_object, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getpropertynames.js b/deps/v8/test/mjsunit/runtime-gen/getpropertynames.js
new file mode 100644
index 0000000000..ad94eedc9c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getpropertynames.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%GetPropertyNames(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getpropertynamesfast.js b/deps/v8/test/mjsunit/runtime-gen/getpropertynamesfast.js
new file mode 100644
index 0000000000..c2d14cb653
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getpropertynamesfast.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _raw_object = new Object();
+%GetPropertyNamesFast(_raw_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getprototype.js b/deps/v8/test/mjsunit/runtime-gen/getprototype.js
new file mode 100644
index 0000000000..b9ef1f9912
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getprototype.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%GetPrototype(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getrootnan.js b/deps/v8/test/mjsunit/runtime-gen/getrootnan.js
new file mode 100644
index 0000000000..b6df0fd5fb
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getrootnan.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+try {
+%GetRootNaN();
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getscopecount.js b/deps/v8/test/mjsunit/runtime-gen/getscopecount.js
new file mode 100644
index 0000000000..d53bece37c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getscopecount.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _wrapped_id = 1;
+try {
+%GetScopeCount(_break_id, _wrapped_id);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getscopedetails.js b/deps/v8/test/mjsunit/runtime-gen/getscopedetails.js
new file mode 100644
index 0000000000..4ea28ac73e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getscopedetails.js
@@ -0,0 +1,10 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _wrapped_id = 1;
+var _inlined_jsframe_index = 32;
+var _index = 32;
+try {
+%GetScopeDetails(_break_id, _wrapped_id, _inlined_jsframe_index, _index);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getscript.js b/deps/v8/test/mjsunit/runtime-gen/getscript.js
new file mode 100644
index 0000000000..cae0087ccf
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getscript.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _script_name = "foo";
+%GetScript(_script_name);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getstepinpositions.js b/deps/v8/test/mjsunit/runtime-gen/getstepinpositions.js
new file mode 100644
index 0000000000..221c586ed4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getstepinpositions.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _wrapped_id = 1;
+try {
+%GetStepInPositions(_break_id, _wrapped_id);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/gettemplatefield.js b/deps/v8/test/mjsunit/runtime-gen/gettemplatefield.js
new file mode 100644
index 0000000000..16d3824b2d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/gettemplatefield.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _templ = new Object();
+var _index = 1;
+try {
+%GetTemplateField(_templ, _index);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getthreadcount.js b/deps/v8/test/mjsunit/runtime-gen/getthreadcount.js
new file mode 100644
index 0000000000..5037066a7d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getthreadcount.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+try {
+%GetThreadCount(_break_id);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getthreaddetails.js b/deps/v8/test/mjsunit/runtime-gen/getthreaddetails.js
new file mode 100644
index 0000000000..6fc0d14ce4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getthreaddetails.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _break_id = 32;
+var _index = 32;
+try {
+%GetThreadDetails(_break_id, _index);
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/getv8version.js b/deps/v8/test/mjsunit/runtime-gen/getv8version.js
new file mode 100644
index 0000000000..e311eef139
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getv8version.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%GetV8Version();
diff --git a/deps/v8/test/mjsunit/runtime-gen/getweakmapentries.js b/deps/v8/test/mjsunit/runtime-gen/getweakmapentries.js
new file mode 100644
index 0000000000..ced728d3b5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getweakmapentries.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new WeakMap();
+%GetWeakMapEntries(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/getweaksetvalues.js b/deps/v8/test/mjsunit/runtime-gen/getweaksetvalues.js
new file mode 100644
index 0000000000..650c947d07
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/getweaksetvalues.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new WeakMap();
+%GetWeakSetValues(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/globalprint.js b/deps/v8/test/mjsunit/runtime-gen/globalprint.js
new file mode 100644
index 0000000000..059f08efe2
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/globalprint.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _string = "foo";
+%GlobalPrint(_string);
diff --git a/deps/v8/test/mjsunit/runtime-gen/globalproxy.js b/deps/v8/test/mjsunit/runtime-gen/globalproxy.js
new file mode 100644
index 0000000000..80e500c887
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/globalproxy.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _global = new Object();
+%GlobalProxy(_global);
diff --git a/deps/v8/test/mjsunit/runtime-gen/haselement.js b/deps/v8/test/mjsunit/runtime-gen/haselement.js
new file mode 100644
index 0000000000..3d32ac5f00
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/haselement.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _receiver = new Object();
+var _index = 1;
+%HasElement(_receiver, _index);
diff --git a/deps/v8/test/mjsunit/runtime-gen/hasownproperty.js b/deps/v8/test/mjsunit/runtime-gen/hasownproperty.js
new file mode 100644
index 0000000000..7443bff104
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/hasownproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _key = "name";
+%HasOwnProperty(_object, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/hasproperty.js b/deps/v8/test/mjsunit/runtime-gen/hasproperty.js
new file mode 100644
index 0000000000..df4de8eb34
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/hasproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _receiver = new Object();
+var _key = "name";
+%HasProperty(_receiver, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/havesamemap.js b/deps/v8/test/mjsunit/runtime-gen/havesamemap.js
new file mode 100644
index 0000000000..b399d17cb7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/havesamemap.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj1 = new Object();
+var _obj2 = new Object();
+%HaveSameMap(_obj1, _obj2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/internalcompare.js b/deps/v8/test/mjsunit/runtime-gen/internalcompare.js
new file mode 100644
index 0000000000..95cc006f31
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/internalcompare.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.Collator('en-US'));
+var _string1 = "foo";
+var _string2 = "foo";
+%InternalCompare(arg0, _string1, _string2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/internaldateformat.js b/deps/v8/test/mjsunit/runtime-gen/internaldateformat.js
new file mode 100644
index 0000000000..933714e934
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/internaldateformat.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.DateTimeFormat('en-US'));
+var _date = new Date();
+%InternalDateFormat(arg0, _date);
diff --git a/deps/v8/test/mjsunit/runtime-gen/internaldateparse.js b/deps/v8/test/mjsunit/runtime-gen/internaldateparse.js
new file mode 100644
index 0000000000..be8c49a942
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/internaldateparse.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.DateTimeFormat('en-US'));
+var _date_string = "foo";
+%InternalDateParse(arg0, _date_string);
diff --git a/deps/v8/test/mjsunit/runtime-gen/internalnumberformat.js b/deps/v8/test/mjsunit/runtime-gen/internalnumberformat.js
new file mode 100644
index 0000000000..cd21edc247
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/internalnumberformat.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.NumberFormat('en-US'));
+var _number = new Object();
+%InternalNumberFormat(arg0, _number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/internalnumberparse.js b/deps/v8/test/mjsunit/runtime-gen/internalnumberparse.js
new file mode 100644
index 0000000000..cdbd322c4c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/internalnumberparse.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = %GetImplFromInitializedIntlObject(new Intl.NumberFormat('en-US'));
+var _number_string = "foo";
+%InternalNumberParse(arg0, _number_string);
diff --git a/deps/v8/test/mjsunit/runtime-gen/internalsetprototype.js b/deps/v8/test/mjsunit/runtime-gen/internalsetprototype.js
new file mode 100644
index 0000000000..1bc67d3826
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/internalsetprototype.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _prototype = new Object();
+%InternalSetPrototype(_obj, _prototype);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isattachedglobal.js b/deps/v8/test/mjsunit/runtime-gen/isattachedglobal.js
new file mode 100644
index 0000000000..9ead91a408
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isattachedglobal.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _global = new Object();
+%IsAttachedGlobal(_global);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isbreakonexception.js b/deps/v8/test/mjsunit/runtime-gen/isbreakonexception.js
new file mode 100644
index 0000000000..e55c7d030a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isbreakonexception.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _type_arg = 32;
+%IsBreakOnException(_type_arg);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isconcurrentrecompilationsupported.js b/deps/v8/test/mjsunit/runtime-gen/isconcurrentrecompilationsupported.js
new file mode 100644
index 0000000000..44e2917d72
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isconcurrentrecompilationsupported.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%IsConcurrentRecompilationSupported();
diff --git a/deps/v8/test/mjsunit/runtime-gen/isextensible.js b/deps/v8/test/mjsunit/runtime-gen/isextensible.js
new file mode 100644
index 0000000000..20a7c8d8a4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isextensible.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%IsExtensible(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isinitializedintlobject.js b/deps/v8/test/mjsunit/runtime-gen/isinitializedintlobject.js
new file mode 100644
index 0000000000..2816e5e27a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isinitializedintlobject.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _input = new Object();
+%IsInitializedIntlObject(_input);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isinitializedintlobjectoftype.js b/deps/v8/test/mjsunit/runtime-gen/isinitializedintlobjectoftype.js
new file mode 100644
index 0000000000..60e3850082
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isinitializedintlobjectoftype.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _input = new Object();
+var _expected_type = "foo";
+%IsInitializedIntlObjectOfType(_input, _expected_type);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isinprototypechain.js b/deps/v8/test/mjsunit/runtime-gen/isinprototypechain.js
new file mode 100644
index 0000000000..37048348d1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isinprototypechain.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _O = new Object();
+var _V = new Object();
+%IsInPrototypeChain(_O, _V);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isjsfunctionproxy.js b/deps/v8/test/mjsunit/runtime-gen/isjsfunctionproxy.js
new file mode 100644
index 0000000000..ca6ea5a916
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isjsfunctionproxy.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%IsJSFunctionProxy(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isjsglobalproxy.js b/deps/v8/test/mjsunit/runtime-gen/isjsglobalproxy.js
new file mode 100644
index 0000000000..f0de610155
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isjsglobalproxy.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%IsJSGlobalProxy(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isjsmodule.js b/deps/v8/test/mjsunit/runtime-gen/isjsmodule.js
new file mode 100644
index 0000000000..8b43a729fb
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isjsmodule.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%IsJSModule(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isjsproxy.js b/deps/v8/test/mjsunit/runtime-gen/isjsproxy.js
new file mode 100644
index 0000000000..a4d32beb16
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isjsproxy.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%IsJSProxy(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isobserved.js b/deps/v8/test/mjsunit/runtime-gen/isobserved.js
new file mode 100644
index 0000000000..f649a1b33e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isobserved.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%IsObserved(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isoptimized.js b/deps/v8/test/mjsunit/runtime-gen/isoptimized.js
new file mode 100644
index 0000000000..e1daf0da88
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isoptimized.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%IsOptimized();
diff --git a/deps/v8/test/mjsunit/runtime-gen/ispropertyenumerable.js b/deps/v8/test/mjsunit/runtime-gen/ispropertyenumerable.js
new file mode 100644
index 0000000000..575ee3468c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/ispropertyenumerable.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _key = "name";
+%IsPropertyEnumerable(_object, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/issloppymodefunction.js b/deps/v8/test/mjsunit/runtime-gen/issloppymodefunction.js
new file mode 100644
index 0000000000..a0c75b32df
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/issloppymodefunction.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = function() {};
+%IsSloppyModeFunction(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/istemplate.js b/deps/v8/test/mjsunit/runtime-gen/istemplate.js
new file mode 100644
index 0000000000..421229fe6e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/istemplate.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _arg = new Object();
+%IsTemplate(_arg);
diff --git a/deps/v8/test/mjsunit/runtime-gen/isvalidsmi.js b/deps/v8/test/mjsunit/runtime-gen/isvalidsmi.js
new file mode 100644
index 0000000000..98cf53bb2d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/isvalidsmi.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _number = 32;
+%IsValidSmi(_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/keyedgetproperty.js b/deps/v8/test/mjsunit/runtime-gen/keyedgetproperty.js
new file mode 100644
index 0000000000..cd8473c99a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/keyedgetproperty.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _receiver_obj = new Object();
+var _key_obj = new Object();
+%KeyedGetProperty(_receiver_obj, _key_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/liveeditcheckanddropactivations.js b/deps/v8/test/mjsunit/runtime-gen/liveeditcheckanddropactivations.js
new file mode 100644
index 0000000000..7247acc3a7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/liveeditcheckanddropactivations.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _shared_array = new Array();
+var _do_drop = true;
+%LiveEditCheckAndDropActivations(_shared_array, _do_drop);
diff --git a/deps/v8/test/mjsunit/runtime-gen/liveeditcomparestrings.js b/deps/v8/test/mjsunit/runtime-gen/liveeditcomparestrings.js
new file mode 100644
index 0000000000..611d78b03c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/liveeditcomparestrings.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _s1 = "foo";
+var _s2 = "foo";
+%LiveEditCompareStrings(_s1, _s2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/liveeditfunctionsetscript.js b/deps/v8/test/mjsunit/runtime-gen/liveeditfunctionsetscript.js
new file mode 100644
index 0000000000..51d61d3bc7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/liveeditfunctionsetscript.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function_object = new Object();
+var _script_object = new Object();
+%LiveEditFunctionSetScript(_function_object, _script_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/loadmutabledouble.js b/deps/v8/test/mjsunit/runtime-gen/loadmutabledouble.js
new file mode 100644
index 0000000000..1a2e7e9f90
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/loadmutabledouble.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = {foo: 1.2};
+var _index = 1;
+%LoadMutableDouble(arg0, _index);
diff --git a/deps/v8/test/mjsunit/runtime-gen/lookupaccessor.js b/deps/v8/test/mjsunit/runtime-gen/lookupaccessor.js
new file mode 100644
index 0000000000..89f40d76c9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/lookupaccessor.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _receiver = new Object();
+var _name = "name";
+var _flag = 1;
+%LookupAccessor(_receiver, _name, _flag);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapclear.js b/deps/v8/test/mjsunit/runtime-gen/mapclear.js
new file mode 100644
index 0000000000..b34e694514
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapclear.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+%MapClear(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapdelete.js b/deps/v8/test/mjsunit/runtime-gen/mapdelete.js
new file mode 100644
index 0000000000..ab78954427
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapdelete.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+var _key = new Object();
+%MapDelete(_holder, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapget.js b/deps/v8/test/mjsunit/runtime-gen/mapget.js
new file mode 100644
index 0000000000..0e996f5232
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapget.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+var _key = new Object();
+%MapGet(_holder, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapgetsize.js b/deps/v8/test/mjsunit/runtime-gen/mapgetsize.js
new file mode 100644
index 0000000000..50a06044b4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapgetsize.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+%MapGetSize(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/maphas.js b/deps/v8/test/mjsunit/runtime-gen/maphas.js
new file mode 100644
index 0000000000..2dc70c93e3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/maphas.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+var _key = new Object();
+%MapHas(_holder, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapinitialize.js b/deps/v8/test/mjsunit/runtime-gen/mapinitialize.js
new file mode 100644
index 0000000000..6240a02594
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapinitialize.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+%MapInitialize(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapiteratorinitialize.js b/deps/v8/test/mjsunit/runtime-gen/mapiteratorinitialize.js
new file mode 100644
index 0000000000..584fe18a4d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapiteratorinitialize.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map().entries();
+var _map = new Map();
+var _kind = 1;
+%MapIteratorInitialize(_holder, _map, _kind);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapiteratornext.js b/deps/v8/test/mjsunit/runtime-gen/mapiteratornext.js
new file mode 100644
index 0000000000..e155227023
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapiteratornext.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map().entries();
+var _value_array = new Array();
+%MapIteratorNext(_holder, _value_array);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mapset.js b/deps/v8/test/mjsunit/runtime-gen/mapset.js
new file mode 100644
index 0000000000..32c2080a8d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mapset.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Map();
+var _key = new Object();
+var _value = new Object();
+%MapSet(_holder, _key, _value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/markasinitializedintlobjectoftype.js b/deps/v8/test/mjsunit/runtime-gen/markasinitializedintlobjectoftype.js
new file mode 100644
index 0000000000..bd0c581c89
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/markasinitializedintlobjectoftype.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _input = new Object();
+var _type = "foo";
+var _impl = new Object();
+%MarkAsInitializedIntlObjectOfType(_input, _type, _impl);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathacos.js b/deps/v8/test/mjsunit/runtime-gen/mathacos.js
new file mode 100644
index 0000000000..fa44268389
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathacos.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathAcos(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathasin.js b/deps/v8/test/mjsunit/runtime-gen/mathasin.js
new file mode 100644
index 0000000000..0d20b3108d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathasin.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathAsin(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathatan.js b/deps/v8/test/mjsunit/runtime-gen/mathatan.js
new file mode 100644
index 0000000000..0e2708f1f2
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathatan.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathAtan(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathatan2.js b/deps/v8/test/mjsunit/runtime-gen/mathatan2.js
new file mode 100644
index 0000000000..4294797115
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathatan2.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%MathAtan2(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathexprt.js b/deps/v8/test/mjsunit/runtime-gen/mathexprt.js
new file mode 100644
index 0000000000..e4584366de
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathexprt.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathExpRT(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathfloorrt.js b/deps/v8/test/mjsunit/runtime-gen/mathfloorrt.js
new file mode 100644
index 0000000000..2ae83aab52
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathfloorrt.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathFloorRT(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathfround.js b/deps/v8/test/mjsunit/runtime-gen/mathfround.js
new file mode 100644
index 0000000000..10a92986c1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathfround.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathFround(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathlogrt.js b/deps/v8/test/mjsunit/runtime-gen/mathlogrt.js
new file mode 100644
index 0000000000..5c484cbbb1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathlogrt.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathLogRT(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/mathsqrtrt.js b/deps/v8/test/mjsunit/runtime-gen/mathsqrtrt.js
new file mode 100644
index 0000000000..e0df8d72d5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/mathsqrtrt.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%MathSqrtRT(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/maxsmi.js b/deps/v8/test/mjsunit/runtime-gen/maxsmi.js
new file mode 100644
index 0000000000..717a6544eb
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/maxsmi.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%MaxSmi();
diff --git a/deps/v8/test/mjsunit/runtime-gen/movearraycontents.js b/deps/v8/test/mjsunit/runtime-gen/movearraycontents.js
new file mode 100644
index 0000000000..41c4ee1cd3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/movearraycontents.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _from = new Array();
+var _to = new Array();
+%MoveArrayContents(_from, _to);
diff --git a/deps/v8/test/mjsunit/runtime-gen/neveroptimizefunction.js b/deps/v8/test/mjsunit/runtime-gen/neveroptimizefunction.js
new file mode 100644
index 0000000000..b03e42f1f8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/neveroptimizefunction.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+%NeverOptimizeFunction(_function);
diff --git a/deps/v8/test/mjsunit/runtime-gen/newarguments.js b/deps/v8/test/mjsunit/runtime-gen/newarguments.js
new file mode 100644
index 0000000000..908fc3af7c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/newarguments.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _callee = function() {};
+%NewArguments(_callee);
diff --git a/deps/v8/test/mjsunit/runtime-gen/newobjectfrombound.js b/deps/v8/test/mjsunit/runtime-gen/newobjectfrombound.js
new file mode 100644
index 0000000000..36f75077b6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/newobjectfrombound.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = (function() {}).bind({});
+%NewObjectFromBound(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/newstring.js b/deps/v8/test/mjsunit/runtime-gen/newstring.js
new file mode 100644
index 0000000000..24b01489e5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/newstring.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _length = 1;
+var _is_one_byte = true;
+%NewString(_length, _is_one_byte);
diff --git a/deps/v8/test/mjsunit/runtime-gen/newstringwrapper.js b/deps/v8/test/mjsunit/runtime-gen/newstringwrapper.js
new file mode 100644
index 0000000000..cf53a3af20
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/newstringwrapper.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _value = "foo";
+%NewStringWrapper(_value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/newsymbolwrapper.js b/deps/v8/test/mjsunit/runtime-gen/newsymbolwrapper.js
new file mode 100644
index 0000000000..08c0ea7e60
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/newsymbolwrapper.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _symbol = Symbol("symbol");
+%NewSymbolWrapper(_symbol);
diff --git a/deps/v8/test/mjsunit/runtime-gen/notifycontextdisposed.js b/deps/v8/test/mjsunit/runtime-gen/notifycontextdisposed.js
new file mode 100644
index 0000000000..d353fc5cea
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/notifycontextdisposed.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%NotifyContextDisposed();
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberadd.js b/deps/v8/test/mjsunit/runtime-gen/numberadd.js
new file mode 100644
index 0000000000..f85017d49d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberadd.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%NumberAdd(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberand.js b/deps/v8/test/mjsunit/runtime-gen/numberand.js
new file mode 100644
index 0000000000..9635e11bb6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberand.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberAnd(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbercompare.js b/deps/v8/test/mjsunit/runtime-gen/numbercompare.js
new file mode 100644
index 0000000000..5f7ac9363c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbercompare.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+var _uncomparable_result = new Object();
+%NumberCompare(_x, _y, _uncomparable_result);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberdiv.js b/deps/v8/test/mjsunit/runtime-gen/numberdiv.js
new file mode 100644
index 0000000000..c62d5921c7
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberdiv.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%NumberDiv(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberequals.js b/deps/v8/test/mjsunit/runtime-gen/numberequals.js
new file mode 100644
index 0000000000..3b919fc02f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberequals.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%NumberEquals(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberimul.js b/deps/v8/test/mjsunit/runtime-gen/numberimul.js
new file mode 100644
index 0000000000..f3c98bdc28
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberimul.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberImul(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbermod.js b/deps/v8/test/mjsunit/runtime-gen/numbermod.js
new file mode 100644
index 0000000000..6d5faeb2c5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbermod.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%NumberMod(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbermul.js b/deps/v8/test/mjsunit/runtime-gen/numbermul.js
new file mode 100644
index 0000000000..0bdc7c2378
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbermul.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%NumberMul(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberor.js b/deps/v8/test/mjsunit/runtime-gen/numberor.js
new file mode 100644
index 0000000000..c5ac65fc8d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberor.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberOr(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbersar.js b/deps/v8/test/mjsunit/runtime-gen/numbersar.js
new file mode 100644
index 0000000000..639270a08a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbersar.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberSar(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbershl.js b/deps/v8/test/mjsunit/runtime-gen/numbershl.js
new file mode 100644
index 0000000000..b505ff6ed8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbershl.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberShl(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbershr.js b/deps/v8/test/mjsunit/runtime-gen/numbershr.js
new file mode 100644
index 0000000000..bd1a3c4541
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbershr.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberShr(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbersub.js b/deps/v8/test/mjsunit/runtime-gen/numbersub.js
new file mode 100644
index 0000000000..5c99f872fa
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbersub.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+var _y = 1.5;
+%NumberSub(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertoexponential.js b/deps/v8/test/mjsunit/runtime-gen/numbertoexponential.js
new file mode 100644
index 0000000000..30159bb3ad
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertoexponential.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _value = 1.5;
+var _f_number = 1.5;
+%NumberToExponential(_value, _f_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertofixed.js b/deps/v8/test/mjsunit/runtime-gen/numbertofixed.js
new file mode 100644
index 0000000000..0df152541a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertofixed.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _value = 1.5;
+var _f_number = 1.5;
+%NumberToFixed(_value, _f_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertointeger.js b/deps/v8/test/mjsunit/runtime-gen/numbertointeger.js
new file mode 100644
index 0000000000..eada58f45a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertointeger.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _number = 1.5;
+%NumberToInteger(_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertointegermapminuszero.js b/deps/v8/test/mjsunit/runtime-gen/numbertointegermapminuszero.js
new file mode 100644
index 0000000000..ce32480610
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertointegermapminuszero.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _number = 1.5;
+%NumberToIntegerMapMinusZero(_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertojsint32.js b/deps/v8/test/mjsunit/runtime-gen/numbertojsint32.js
new file mode 100644
index 0000000000..77321f9c62
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertojsint32.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _number = 1.5;
+%NumberToJSInt32(_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertojsuint32.js b/deps/v8/test/mjsunit/runtime-gen/numbertojsuint32.js
new file mode 100644
index 0000000000..d4f7302fe9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertojsuint32.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _number = 32;
+%NumberToJSUint32(_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertoprecision.js b/deps/v8/test/mjsunit/runtime-gen/numbertoprecision.js
new file mode 100644
index 0000000000..6591117ec8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertoprecision.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _value = 1.5;
+var _f_number = 1.5;
+%NumberToPrecision(_value, _f_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertoradixstring.js b/deps/v8/test/mjsunit/runtime-gen/numbertoradixstring.js
new file mode 100644
index 0000000000..020aac2853
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertoradixstring.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _value = 1.5;
+var arg1 = 2;
+%NumberToRadixString(_value, arg1);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numbertostringrt.js b/deps/v8/test/mjsunit/runtime-gen/numbertostringrt.js
new file mode 100644
index 0000000000..4b2b6d93b0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numbertostringrt.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _number = 1.5;
+%NumberToStringRT(_number);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberunaryminus.js b/deps/v8/test/mjsunit/runtime-gen/numberunaryminus.js
new file mode 100644
index 0000000000..54dc49eda9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberunaryminus.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%NumberUnaryMinus(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/numberxor.js b/deps/v8/test/mjsunit/runtime-gen/numberxor.js
new file mode 100644
index 0000000000..237269803b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/numberxor.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 32;
+var _y = 32;
+%NumberXor(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/objectfreeze.js b/deps/v8/test/mjsunit/runtime-gen/objectfreeze.js
new file mode 100644
index 0000000000..cfc066c6f1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/objectfreeze.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%ObjectFreeze(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/objectwascreatedincurrentorigin.js b/deps/v8/test/mjsunit/runtime-gen/objectwascreatedincurrentorigin.js
new file mode 100644
index 0000000000..776997009c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/objectwascreatedincurrentorigin.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%ObjectWasCreatedInCurrentOrigin(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/observationweakmapcreate.js b/deps/v8/test/mjsunit/runtime-gen/observationweakmapcreate.js
new file mode 100644
index 0000000000..6c71eace41
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/observationweakmapcreate.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%ObservationWeakMapCreate();
diff --git a/deps/v8/test/mjsunit/runtime-gen/observerobjectandrecordhavesameorigin.js b/deps/v8/test/mjsunit/runtime-gen/observerobjectandrecordhavesameorigin.js
new file mode 100644
index 0000000000..6c251ecd95
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/observerobjectandrecordhavesameorigin.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _observer = function() {};
+var _object = new Object();
+var _record = new Object();
+%ObserverObjectAndRecordHaveSameOrigin(_observer, _object, _record);
diff --git a/deps/v8/test/mjsunit/runtime-gen/optimizeobjectforaddingmultipleproperties.js b/deps/v8/test/mjsunit/runtime-gen/optimizeobjectforaddingmultipleproperties.js
new file mode 100644
index 0000000000..7016e1c062
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/optimizeobjectforaddingmultipleproperties.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _properties = 1;
+%OptimizeObjectForAddingMultipleProperties(_object, _properties);
diff --git a/deps/v8/test/mjsunit/runtime-gen/ownkeys.js b/deps/v8/test/mjsunit/runtime-gen/ownkeys.js
new file mode 100644
index 0000000000..0a392422cc
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/ownkeys.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _raw_object = new Object();
+%OwnKeys(_raw_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/parsejson.js b/deps/v8/test/mjsunit/runtime-gen/parsejson.js
new file mode 100644
index 0000000000..0a038790ea
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/parsejson.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = "{}";
+%ParseJson(arg0);
diff --git a/deps/v8/test/mjsunit/runtime-gen/preventextensions.js b/deps/v8/test/mjsunit/runtime-gen/preventextensions.js
new file mode 100644
index 0000000000..8e24b75e0c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/preventextensions.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%PreventExtensions(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/pushifabsent.js b/deps/v8/test/mjsunit/runtime-gen/pushifabsent.js
new file mode 100644
index 0000000000..c998121f53
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/pushifabsent.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _array = new Array();
+var _element = new Object();
+%PushIfAbsent(_array, _element);
diff --git a/deps/v8/test/mjsunit/runtime-gen/quotejsonstring.js b/deps/v8/test/mjsunit/runtime-gen/quotejsonstring.js
new file mode 100644
index 0000000000..61ade34263
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/quotejsonstring.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _string = "foo";
+%QuoteJSONString(_string);
diff --git a/deps/v8/test/mjsunit/runtime-gen/regexpcompile.js b/deps/v8/test/mjsunit/runtime-gen/regexpcompile.js
new file mode 100644
index 0000000000..c0edfa6fcf
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/regexpcompile.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _re = /ab/g;
+var _pattern = "foo";
+var _flags = "foo";
+%RegExpCompile(_re, _pattern, _flags);
diff --git a/deps/v8/test/mjsunit/runtime-gen/regexpconstructresult.js b/deps/v8/test/mjsunit/runtime-gen/regexpconstructresult.js
new file mode 100644
index 0000000000..50d2e0d8fe
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/regexpconstructresult.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _size = 1;
+var _index = new Object();
+var _input = new Object();
+%_RegExpConstructResult(_size, _index, _input);
diff --git a/deps/v8/test/mjsunit/runtime-gen/regexpexecmultiple.js b/deps/v8/test/mjsunit/runtime-gen/regexpexecmultiple.js
new file mode 100644
index 0000000000..9db6e6d2b3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/regexpexecmultiple.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _regexp = /ab/g;
+var _subject = "foo";
+var arg2 = ['a'];
+var arg3 = ['a'];
+%RegExpExecMultiple(_regexp, _subject, arg2, arg3);
diff --git a/deps/v8/test/mjsunit/runtime-gen/regexpexecrt.js b/deps/v8/test/mjsunit/runtime-gen/regexpexecrt.js
new file mode 100644
index 0000000000..3b20191f2b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/regexpexecrt.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _regexp = /ab/g;
+var _subject = "foo";
+var _index = 1;
+var _last_match_info = new Array();
+%RegExpExecRT(_regexp, _subject, _index, _last_match_info);
diff --git a/deps/v8/test/mjsunit/runtime-gen/regexpinitializeobject.js b/deps/v8/test/mjsunit/runtime-gen/regexpinitializeobject.js
new file mode 100644
index 0000000000..fccdeeed78
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/regexpinitializeobject.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _regexp = /ab/g;
+var _source = "foo";
+var _global = new Object();
+var _ignoreCase = new Object();
+var _multiline = new Object();
+%RegExpInitializeObject(_regexp, _source, _global, _ignoreCase, _multiline);
diff --git a/deps/v8/test/mjsunit/runtime-gen/removearrayholes.js b/deps/v8/test/mjsunit/runtime-gen/removearrayholes.js
new file mode 100644
index 0000000000..971e63cab5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/removearrayholes.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+var _limit = 32;
+%RemoveArrayHoles(_object, _limit);
diff --git a/deps/v8/test/mjsunit/runtime-gen/rempio2.js b/deps/v8/test/mjsunit/runtime-gen/rempio2.js
new file mode 100644
index 0000000000..6d47bac4ac
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/rempio2.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = 1.5;
+%RemPiO2(_x);
diff --git a/deps/v8/test/mjsunit/runtime-gen/roundnumber.js b/deps/v8/test/mjsunit/runtime-gen/roundnumber.js
new file mode 100644
index 0000000000..2ec1159b2b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/roundnumber.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _input = 1.5;
+%RoundNumber(_input);
diff --git a/deps/v8/test/mjsunit/runtime-gen/runmicrotasks.js b/deps/v8/test/mjsunit/runtime-gen/runmicrotasks.js
new file mode 100644
index 0000000000..945260a8df
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/runmicrotasks.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%RunMicrotasks();
diff --git a/deps/v8/test/mjsunit/runtime-gen/runninginsimulator.js b/deps/v8/test/mjsunit/runtime-gen/runninginsimulator.js
new file mode 100644
index 0000000000..fe5678259d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/runninginsimulator.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%RunningInSimulator();
diff --git a/deps/v8/test/mjsunit/runtime-gen/setadd.js b/deps/v8/test/mjsunit/runtime-gen/setadd.js
new file mode 100644
index 0000000000..75b923fbf3
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setadd.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set();
+var _key = new Object();
+%SetAdd(_holder, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setclear.js b/deps/v8/test/mjsunit/runtime-gen/setclear.js
new file mode 100644
index 0000000000..82ef6d955b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setclear.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set();
+%SetClear(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setcode.js b/deps/v8/test/mjsunit/runtime-gen/setcode.js
new file mode 100644
index 0000000000..4e2206fbc8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setcode.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _target = function() {};
+var _source = function() {};
+%SetCode(_target, _source);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setdebugeventlistener.js b/deps/v8/test/mjsunit/runtime-gen/setdebugeventlistener.js
new file mode 100644
index 0000000000..d51b277b80
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setdebugeventlistener.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = undefined;
+var _data = new Object();
+%SetDebugEventListener(arg0, _data);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setdelete.js b/deps/v8/test/mjsunit/runtime-gen/setdelete.js
new file mode 100644
index 0000000000..80bd343d0e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setdelete.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set();
+var _key = new Object();
+%SetDelete(_holder, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setdisablebreak.js b/deps/v8/test/mjsunit/runtime-gen/setdisablebreak.js
new file mode 100644
index 0000000000..461942b60f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setdisablebreak.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _disable_break = true;
+%SetDisableBreak(_disable_break);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setflags.js b/deps/v8/test/mjsunit/runtime-gen/setflags.js
new file mode 100644
index 0000000000..70db03ee98
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setflags.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _arg = "foo";
+%SetFlags(_arg);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setfunctionbreakpoint.js b/deps/v8/test/mjsunit/runtime-gen/setfunctionbreakpoint.js
new file mode 100644
index 0000000000..010330e5a4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setfunctionbreakpoint.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _function = function() {};
+var arg1 = 218;
+var _break_point_object_arg = new Object();
+%SetFunctionBreakPoint(_function, arg1, _break_point_object_arg);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setgetsize.js b/deps/v8/test/mjsunit/runtime-gen/setgetsize.js
new file mode 100644
index 0000000000..842016bb2d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setgetsize.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set();
+%SetGetSize(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/sethas.js b/deps/v8/test/mjsunit/runtime-gen/sethas.js
new file mode 100644
index 0000000000..8cec0d8c35
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/sethas.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set();
+var _key = new Object();
+%SetHas(_holder, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setinitialize.js b/deps/v8/test/mjsunit/runtime-gen/setinitialize.js
new file mode 100644
index 0000000000..b21a089692
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setinitialize.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set();
+%SetInitialize(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setisobserved.js b/deps/v8/test/mjsunit/runtime-gen/setisobserved.js
new file mode 100644
index 0000000000..d885113ffa
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setisobserved.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%SetIsObserved(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setiteratorinitialize.js b/deps/v8/test/mjsunit/runtime-gen/setiteratorinitialize.js
new file mode 100644
index 0000000000..34769e51dc
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setiteratorinitialize.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set().values();
+var _set = new Set();
+var arg2 = 2;
+%SetIteratorInitialize(_holder, _set, arg2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setiteratornext.js b/deps/v8/test/mjsunit/runtime-gen/setiteratornext.js
new file mode 100644
index 0000000000..02b74d44da
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setiteratornext.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Set().values();
+var _value_array = new Array();
+%SetIteratorNext(_holder, _value_array);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setprototype.js b/deps/v8/test/mjsunit/runtime-gen/setprototype.js
new file mode 100644
index 0000000000..6353151f4e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setprototype.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+var _prototype = new Object();
+%SetPrototype(_obj, _prototype);
diff --git a/deps/v8/test/mjsunit/runtime-gen/setscopevariablevalue.js b/deps/v8/test/mjsunit/runtime-gen/setscopevariablevalue.js
new file mode 100644
index 0000000000..680bab52cc
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/setscopevariablevalue.js
@@ -0,0 +1,10 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _fun = function() {};
+var _wrapped_id = 1;
+var _inlined_jsframe_index = 32;
+var _index = 32;
+var _variable_name = "foo";
+var _new_value = new Object();
+%SetScopeVariableValue(_fun, _wrapped_id, _inlined_jsframe_index, _index, _variable_name, _new_value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/smilexicographiccompare.js b/deps/v8/test/mjsunit/runtime-gen/smilexicographiccompare.js
new file mode 100644
index 0000000000..d227a9ffc1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/smilexicographiccompare.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x_value = 1;
+var _y_value = 1;
+%SmiLexicographicCompare(_x_value, _y_value);
diff --git a/deps/v8/test/mjsunit/runtime-gen/sparsejoinwithseparator.js b/deps/v8/test/mjsunit/runtime-gen/sparsejoinwithseparator.js
new file mode 100644
index 0000000000..3a8e7754d4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/sparsejoinwithseparator.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _elements_array = new Array();
+var _array_length = 32;
+var _separator = "foo";
+%SparseJoinWithSeparator(_elements_array, _array_length, _separator);
diff --git a/deps/v8/test/mjsunit/runtime-gen/specialarrayfunctions.js b/deps/v8/test/mjsunit/runtime-gen/specialarrayfunctions.js
new file mode 100644
index 0000000000..5956e8422c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/specialarrayfunctions.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%SpecialArrayFunctions();
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringbuilderconcat.js b/deps/v8/test/mjsunit/runtime-gen/stringbuilderconcat.js
new file mode 100644
index 0000000000..9d7c78a3e6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringbuilderconcat.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = [1, 2, 3];
+var arg1 = 3;
+var _special = "foo";
+%StringBuilderConcat(arg0, arg1, _special);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringbuilderjoin.js b/deps/v8/test/mjsunit/runtime-gen/stringbuilderjoin.js
new file mode 100644
index 0000000000..bf990c62d6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringbuilderjoin.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var arg0 = ['a', 'b'];
+var arg1 = 4;
+var _separator = "foo";
+%StringBuilderJoin(arg0, arg1, _separator);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringcharcodeatrt.js b/deps/v8/test/mjsunit/runtime-gen/stringcharcodeatrt.js
new file mode 100644
index 0000000000..fa016ac00e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringcharcodeatrt.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+var _i = 32;
+%StringCharCodeAtRT(_subject, _i);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringequals.js b/deps/v8/test/mjsunit/runtime-gen/stringequals.js
new file mode 100644
index 0000000000..14e40eb028
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringequals.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _x = "foo";
+var _y = "foo";
+%StringEquals(_x, _y);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringindexof.js b/deps/v8/test/mjsunit/runtime-gen/stringindexof.js
new file mode 100644
index 0000000000..3c5cab31c5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringindexof.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _sub = "foo";
+var _pat = "foo";
+var _index = new Object();
+%StringIndexOf(_sub, _pat, _index);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringlastindexof.js b/deps/v8/test/mjsunit/runtime-gen/stringlastindexof.js
new file mode 100644
index 0000000000..afbc51f5a4
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringlastindexof.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _sub = "foo";
+var _pat = "foo";
+var _index = new Object();
+%StringLastIndexOf(_sub, _pat, _index);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringlocalecompare.js b/deps/v8/test/mjsunit/runtime-gen/stringlocalecompare.js
new file mode 100644
index 0000000000..b37e231183
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringlocalecompare.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _str1 = "foo";
+var _str2 = "foo";
+%StringLocaleCompare(_str1, _str2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringmatch.js b/deps/v8/test/mjsunit/runtime-gen/stringmatch.js
new file mode 100644
index 0000000000..330aeae9c0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringmatch.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+var _regexp = /ab/g;
+var arg2 = ['a', 'b'];
+%StringMatch(_subject, _regexp, arg2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringnormalize.js b/deps/v8/test/mjsunit/runtime-gen/stringnormalize.js
new file mode 100644
index 0000000000..fb408a41a5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringnormalize.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _stringValue = "foo";
+var arg1 = 2;
+%StringNormalize(_stringValue, arg1);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringparsefloat.js b/deps/v8/test/mjsunit/runtime-gen/stringparsefloat.js
new file mode 100644
index 0000000000..520a24e756
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringparsefloat.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+%StringParseFloat(_subject);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringparseint.js b/deps/v8/test/mjsunit/runtime-gen/stringparseint.js
new file mode 100644
index 0000000000..43116554eb
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringparseint.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+var _radix = 32;
+%StringParseInt(_subject, _radix);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringreplaceglobalregexpwithstring.js b/deps/v8/test/mjsunit/runtime-gen/stringreplaceglobalregexpwithstring.js
new file mode 100644
index 0000000000..ad2b6e67d9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringreplaceglobalregexpwithstring.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+var _regexp = /ab/g;
+var _replacement = "foo";
+var arg3 = ['a'];
+%StringReplaceGlobalRegExpWithString(_subject, _regexp, _replacement, arg3);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringreplaceonecharwithstring.js b/deps/v8/test/mjsunit/runtime-gen/stringreplaceonecharwithstring.js
new file mode 100644
index 0000000000..5e38a79f44
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringreplaceonecharwithstring.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+var _search = "foo";
+var _replace = "foo";
+%StringReplaceOneCharWithString(_subject, _search, _replace);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringsplit.js b/deps/v8/test/mjsunit/runtime-gen/stringsplit.js
new file mode 100644
index 0000000000..dfe683194a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringsplit.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+var _pattern = "foo";
+var _limit = 32;
+%StringSplit(_subject, _pattern, _limit);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringtoarray.js b/deps/v8/test/mjsunit/runtime-gen/stringtoarray.js
new file mode 100644
index 0000000000..6ed48a771a
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringtoarray.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _s = "foo";
+var _limit = 32;
+%StringToArray(_s, _limit);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringtolowercase.js b/deps/v8/test/mjsunit/runtime-gen/stringtolowercase.js
new file mode 100644
index 0000000000..3a7261a0e0
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringtolowercase.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _s = "foo";
+%StringToLowerCase(_s);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringtonumber.js b/deps/v8/test/mjsunit/runtime-gen/stringtonumber.js
new file mode 100644
index 0000000000..88e2e84a2e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringtonumber.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _subject = "foo";
+%StringToNumber(_subject);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringtouppercase.js b/deps/v8/test/mjsunit/runtime-gen/stringtouppercase.js
new file mode 100644
index 0000000000..b7d9731015
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringtouppercase.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _s = "foo";
+%StringToUpperCase(_s);
diff --git a/deps/v8/test/mjsunit/runtime-gen/stringtrim.js b/deps/v8/test/mjsunit/runtime-gen/stringtrim.js
new file mode 100644
index 0000000000..75d197efa9
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/stringtrim.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _string = "foo";
+var _trimLeft = true;
+var _trimRight = true;
+%StringTrim(_string, _trimLeft, _trimRight);
diff --git a/deps/v8/test/mjsunit/runtime-gen/symboldescription.js b/deps/v8/test/mjsunit/runtime-gen/symboldescription.js
new file mode 100644
index 0000000000..13360828b8
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/symboldescription.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _symbol = Symbol("symbol");
+%SymbolDescription(_symbol);
diff --git a/deps/v8/test/mjsunit/runtime-gen/symbolisprivate.js b/deps/v8/test/mjsunit/runtime-gen/symbolisprivate.js
new file mode 100644
index 0000000000..8e5343e1d5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/symbolisprivate.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _symbol = Symbol("symbol");
+%SymbolIsPrivate(_symbol);
diff --git a/deps/v8/test/mjsunit/runtime-gen/symbolregistry.js b/deps/v8/test/mjsunit/runtime-gen/symbolregistry.js
new file mode 100644
index 0000000000..71964e6eae
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/symbolregistry.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%SymbolRegistry();
diff --git a/deps/v8/test/mjsunit/runtime-gen/tobool.js b/deps/v8/test/mjsunit/runtime-gen/tobool.js
new file mode 100644
index 0000000000..ca522c8a9f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/tobool.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%ToBool(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/tofastproperties.js b/deps/v8/test/mjsunit/runtime-gen/tofastproperties.js
new file mode 100644
index 0000000000..f9c1890b1c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/tofastproperties.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%ToFastProperties(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/traceenter.js b/deps/v8/test/mjsunit/runtime-gen/traceenter.js
new file mode 100644
index 0000000000..768a0c2437
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/traceenter.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%TraceEnter();
diff --git a/deps/v8/test/mjsunit/runtime-gen/traceexit.js b/deps/v8/test/mjsunit/runtime-gen/traceexit.js
new file mode 100644
index 0000000000..378d008c90
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/traceexit.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%TraceExit(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/truncatestring.js b/deps/v8/test/mjsunit/runtime-gen/truncatestring.js
new file mode 100644
index 0000000000..64ef628e5b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/truncatestring.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _string = "seqstring";
+var _new_length = 1;
+%TruncateString(_string, _new_length);
diff --git a/deps/v8/test/mjsunit/runtime-gen/trymigrateinstance.js b/deps/v8/test/mjsunit/runtime-gen/trymigrateinstance.js
new file mode 100644
index 0000000000..b82eb741bb
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/trymigrateinstance.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _object = new Object();
+%TryMigrateInstance(_object);
diff --git a/deps/v8/test/mjsunit/runtime-gen/typedarraygetbuffer.js b/deps/v8/test/mjsunit/runtime-gen/typedarraygetbuffer.js
new file mode 100644
index 0000000000..56a805b3b2
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typedarraygetbuffer.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Int32Array(2);
+%TypedArrayGetBuffer(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/typedarraygetlength.js b/deps/v8/test/mjsunit/runtime-gen/typedarraygetlength.js
new file mode 100644
index 0000000000..8d1865f40f
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typedarraygetlength.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Int32Array(2);
+%TypedArrayGetLength(_holder);
diff --git a/deps/v8/test/mjsunit/runtime-gen/typedarrayinitialize.js b/deps/v8/test/mjsunit/runtime-gen/typedarrayinitialize.js
new file mode 100644
index 0000000000..be1e29607e
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typedarrayinitialize.js
@@ -0,0 +1,9 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Int32Array(2);
+var arg1 = 6;
+var arg2 = new ArrayBuffer(8);
+var _byte_offset_object = 1.5;
+var arg4 = 4;
+%TypedArrayInitialize(_holder, arg1, arg2, _byte_offset_object, arg4);
diff --git a/deps/v8/test/mjsunit/runtime-gen/typedarrayinitializefromarraylike.js b/deps/v8/test/mjsunit/runtime-gen/typedarrayinitializefromarraylike.js
new file mode 100644
index 0000000000..0ca7a0f7ce
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typedarrayinitializefromarraylike.js
@@ -0,0 +1,8 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _holder = new Int32Array(2);
+var arg1 = 6;
+var _source = new Object();
+var _length_obj = 1.5;
+%TypedArrayInitializeFromArrayLike(_holder, arg1, _source, _length_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/typedarraymaxsizeinheap.js b/deps/v8/test/mjsunit/runtime-gen/typedarraymaxsizeinheap.js
new file mode 100644
index 0000000000..61467bd9fa
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typedarraymaxsizeinheap.js
@@ -0,0 +1,4 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+%TypedArrayMaxSizeInHeap();
diff --git a/deps/v8/test/mjsunit/runtime-gen/typedarraysetfastcases.js b/deps/v8/test/mjsunit/runtime-gen/typedarraysetfastcases.js
new file mode 100644
index 0000000000..495212952b
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typedarraysetfastcases.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _target_obj = new Int32Array(2);
+var _source_obj = new Int32Array(2);
+var arg2 = 0;
+%TypedArraySetFastCases(_target_obj, _source_obj, arg2);
diff --git a/deps/v8/test/mjsunit/runtime-gen/typeof.js b/deps/v8/test/mjsunit/runtime-gen/typeof.js
new file mode 100644
index 0000000000..78bfa6ea2c
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/typeof.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _obj = new Object();
+%Typeof(_obj);
diff --git a/deps/v8/test/mjsunit/runtime-gen/unblockconcurrentrecompilation.js b/deps/v8/test/mjsunit/runtime-gen/unblockconcurrentrecompilation.js
new file mode 100644
index 0000000000..a08add7b28
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/unblockconcurrentrecompilation.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+try {
+%UnblockConcurrentRecompilation();
+} catch(e) {}
diff --git a/deps/v8/test/mjsunit/runtime-gen/uriescape.js b/deps/v8/test/mjsunit/runtime-gen/uriescape.js
new file mode 100644
index 0000000000..f32edc98e6
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/uriescape.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _source = "foo";
+%URIEscape(_source);
diff --git a/deps/v8/test/mjsunit/runtime-gen/uriunescape.js b/deps/v8/test/mjsunit/runtime-gen/uriunescape.js
new file mode 100644
index 0000000000..2ba812c588
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/uriunescape.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _source = "foo";
+%URIUnescape(_source);
diff --git a/deps/v8/test/mjsunit/runtime-gen/weakcollectiondelete.js b/deps/v8/test/mjsunit/runtime-gen/weakcollectiondelete.js
new file mode 100644
index 0000000000..a6fff79e19
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/weakcollectiondelete.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _weak_collection = new WeakMap();
+var _key = new Object();
+%WeakCollectionDelete(_weak_collection, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/weakcollectionget.js b/deps/v8/test/mjsunit/runtime-gen/weakcollectionget.js
new file mode 100644
index 0000000000..f248ac05a5
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/weakcollectionget.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _weak_collection = new WeakMap();
+var _key = new Object();
+%WeakCollectionGet(_weak_collection, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/weakcollectionhas.js b/deps/v8/test/mjsunit/runtime-gen/weakcollectionhas.js
new file mode 100644
index 0000000000..af600c3e8d
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/weakcollectionhas.js
@@ -0,0 +1,6 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _weak_collection = new WeakMap();
+var _key = new Object();
+%WeakCollectionHas(_weak_collection, _key);
diff --git a/deps/v8/test/mjsunit/runtime-gen/weakcollectioninitialize.js b/deps/v8/test/mjsunit/runtime-gen/weakcollectioninitialize.js
new file mode 100644
index 0000000000..97f5ce56a1
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/weakcollectioninitialize.js
@@ -0,0 +1,5 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _weak_collection = new WeakMap();
+%WeakCollectionInitialize(_weak_collection);
diff --git a/deps/v8/test/mjsunit/runtime-gen/weakcollectionset.js b/deps/v8/test/mjsunit/runtime-gen/weakcollectionset.js
new file mode 100644
index 0000000000..3479ba6031
--- /dev/null
+++ b/deps/v8/test/mjsunit/runtime-gen/weakcollectionset.js
@@ -0,0 +1,7 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// AUTO-GENERATED BY tools/generate-runtime-tests.py, DO NOT MODIFY
+// Flags: --allow-natives-syntax --harmony --harmony-proxies
+var _weak_collection = new WeakMap();
+var _key = new Object();
+var _value = new Object();
+%WeakCollectionSet(_weak_collection, _key, _value);
diff --git a/deps/v8/test/mjsunit/sin-cos.js b/deps/v8/test/mjsunit/sin-cos.js
index 02ae57ba27..71fae2056d 100644
--- a/deps/v8/test/mjsunit/sin-cos.js
+++ b/deps/v8/test/mjsunit/sin-cos.js
@@ -157,8 +157,8 @@ assertEquals(0, Math.sin("0x00000"));
assertEquals(1, Math.cos("0x00000"));
assertTrue(isNaN(Math.sin(Infinity)));
assertTrue(isNaN(Math.cos("-Infinity")));
-assertEquals("Infinity", String(Math.tan(Math.PI/2)));
-assertEquals("-Infinity", String(Math.tan(-Math.PI/2)));
+assertTrue(Math.tan(Math.PI/2) > 1e16);
+assertTrue(Math.tan(-Math.PI/2) < -1e16);
assertEquals("-Infinity", String(1/Math.sin("-0")));
// Assert that the remainder after division by pi is reasonably precise.
@@ -185,3 +185,96 @@ for (var i = -1024; i < 1024; i++) {
assertFalse(isNaN(Math.cos(1.57079632679489700)));
assertFalse(isNaN(Math.cos(-1e-100)));
assertFalse(isNaN(Math.cos(-1e-323)));
+
+// Tests for specific values expected from the fdlibm implementation.
+
+var two_32 = Math.pow(2, -32);
+var two_28 = Math.pow(2, -28);
+
+// Tests for Math.sin for |x| < pi/4
+assertEquals(Infinity, 1/Math.sin(+0.0));
+assertEquals(-Infinity, 1/Math.sin(-0.0));
+// sin(x) = x for x < 2^-27
+assertEquals(two_32, Math.sin(two_32));
+assertEquals(-two_32, Math.sin(-two_32));
+// sin(pi/8) = sqrt(sqrt(2)-1)/2^(3/4)
+assertEquals(0.3826834323650898, Math.sin(Math.PI/8));
+assertEquals(-0.3826834323650898, -Math.sin(Math.PI/8));
+
+// Tests for Math.cos for |x| < pi/4
+// cos(x) = 1 for |x| < 2^-27
+assertEquals(1, Math.cos(two_32));
+assertEquals(1, Math.cos(-two_32));
+// Test KERNELCOS for |x| < 0.3.
+// cos(pi/20) = sqrt(sqrt(2)*sqrt(sqrt(5)+5)+4)/2^(3/2)
+assertEquals(0.9876883405951378, Math.cos(Math.PI/20));
+// Test KERNELCOS for x ~= 0.78125
+assertEquals(0.7100335477927638, Math.cos(0.7812504768371582));
+assertEquals(0.7100338835660797, Math.cos(0.78125));
+// Test KERNELCOS for |x| > 0.3.
+// cos(pi/8) = sqrt(sqrt(2)+1)/2^(3/4)
+assertEquals(0.9238795325112867, Math.cos(Math.PI/8));
+// Test KERNELTAN for |x| < 0.67434.
+assertEquals(0.9238795325112867, Math.cos(-Math.PI/8));
+
+// Tests for Math.tan for |x| < pi/4
+assertEquals(Infinity, 1/Math.tan(0.0));
+assertEquals(-Infinity, 1/Math.tan(-0.0));
+// tan(x) = x for |x| < 2^-28
+assertEquals(two_32, Math.tan(two_32));
+assertEquals(-two_32, Math.tan(-two_32));
+// Test KERNELTAN for |x| > 0.67434.
+assertEquals(0.8211418015898941, Math.tan(11/16));
+assertEquals(-0.8211418015898941, Math.tan(-11/16));
+assertEquals(0.41421356237309503, Math.tan(Math.PI / 8));
+
+// Tests for Math.sin.
+assertEquals(0.479425538604203, Math.sin(0.5));
+assertEquals(-0.479425538604203, Math.sin(-0.5));
+assertEquals(1, Math.sin(Math.PI/2));
+assertEquals(-1, Math.sin(-Math.PI/2));
+// Test that Math.sin(Math.PI) != 0 since Math.PI is not exact.
+assertEquals(1.2246467991473532e-16, Math.sin(Math.PI));
+assertEquals(-7.047032979958965e-14, Math.sin(2200*Math.PI));
+// Test Math.sin for various phases.
+assertEquals(-0.7071067811865477, Math.sin(7/4 * Math.PI));
+assertEquals(0.7071067811865474, Math.sin(9/4 * Math.PI));
+assertEquals(0.7071067811865483, Math.sin(11/4 * Math.PI));
+assertEquals(-0.7071067811865479, Math.sin(13/4 * Math.PI));
+assertEquals(-3.2103381051568376e-11, Math.sin(1048576/4 * Math.PI));
+
+// Tests for Math.cos.
+assertEquals(1, Math.cos(two_28));
+// Cover different code paths in KERNELCOS.
+assertEquals(0.9689124217106447, Math.cos(0.25));
+assertEquals(0.8775825618903728, Math.cos(0.5));
+assertEquals(0.7073882691671998, Math.cos(0.785));
+// Test that Math.cos(Math.PI/2) != 0 since Math.PI is not exact.
+assertEquals(6.123233995736766e-17, Math.cos(Math.PI/2));
+// Test Math.cos for various phases.
+assertEquals(0.7071067811865474, Math.cos(7/4 * Math.PI));
+assertEquals(0.7071067811865477, Math.cos(9/4 * Math.PI));
+assertEquals(-0.7071067811865467, Math.cos(11/4 * Math.PI));
+assertEquals(-0.7071067811865471, Math.cos(13/4 * Math.PI));
+assertEquals(0.9367521275331447, Math.cos(1000000));
+assertEquals(-3.435757038074824e-12, Math.cos(1048575/2 * Math.PI));
+
+// Tests for Math.tan.
+assertEquals(two_28, Math.tan(two_28));
+// Test that Math.tan(Math.PI/2) != Infinity since Math.PI is not exact.
+assertEquals(1.633123935319537e16, Math.tan(Math.PI/2));
+// Cover different code paths in KERNELTAN (tangent and cotangent)
+assertEquals(0.5463024898437905, Math.tan(0.5));
+assertEquals(2.0000000000000027, Math.tan(1.107148717794091));
+assertEquals(-1.0000000000000004, Math.tan(7/4*Math.PI));
+assertEquals(0.9999999999999994, Math.tan(9/4*Math.PI));
+assertEquals(-6.420676210313675e-11, Math.tan(1048576/2*Math.PI));
+assertEquals(2.910566692924059e11, Math.tan(1048575/2*Math.PI));
+
+// Test Hayne-Panek reduction.
+assertEquals(0.377820109360752e0, Math.sin(Math.pow(2, 120)));
+assertEquals(-0.9258790228548379e0, Math.cos(Math.pow(2, 120)));
+assertEquals(-0.40806638884180424e0, Math.tan(Math.pow(2, 120)));
+assertEquals(-0.377820109360752e0, Math.sin(-Math.pow(2, 120)));
+assertEquals(-0.9258790228548379e0, Math.cos(-Math.pow(2, 120)));
+assertEquals(0.40806638884180424e0, Math.tan(-Math.pow(2, 120)));
diff --git a/deps/v8/test/mjsunit/stack-traces-overflow.js b/deps/v8/test/mjsunit/stack-traces-overflow.js
index 7722e93bd2..e20c6091d7 100644
--- a/deps/v8/test/mjsunit/stack-traces-overflow.js
+++ b/deps/v8/test/mjsunit/stack-traces-overflow.js
@@ -25,6 +25,8 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+// Flags: --stack-size=100
+
function rec1(a) { rec1(a+1); }
function rec2(a) { rec3(a+1); }
function rec3(a) { rec2(a+1); }
@@ -61,8 +63,8 @@ try {
function testErrorPrototype(prototype) {
var object = {};
object.__proto__ = prototype;
- object.stack = "123";
- assertEquals("123", object.stack);
+ object.stack = "123"; // Overwriting stack property fails.
+ assertEquals(prototype.stack, object.stack);
assertTrue("123" != prototype.stack);
}
@@ -106,11 +108,28 @@ try {
assertEquals(1, e.stack.split('\n').length);
}
+// A limit outside the range of integers.
+Error.stackTraceLimit = 1e12;
+try {
+ rec1(0);
+} catch (e) {
+ assertTrue(e.stack.split('\n').length > 100);
+}
+
+Error.stackTraceLimit = Infinity;
+try {
+ rec1(0);
+} catch (e) {
+ assertTrue(e.stack.split('\n').length > 100);
+}
+
Error.stackTraceLimit = "not a number";
try {
rec1(0);
} catch (e) {
assertEquals(undefined, e.stack);
+ e.stack = "abc";
+ assertEquals("abc", e.stack);
}
Error.stackTraceLimit = 3;
diff --git a/deps/v8/test/mjsunit/stack-traces.js b/deps/v8/test/mjsunit/stack-traces.js
index 46a16eb87a..f80a627b24 100644
--- a/deps/v8/test/mjsunit/stack-traces.js
+++ b/deps/v8/test/mjsunit/stack-traces.js
@@ -331,3 +331,23 @@ Error.prepareStackTrace = function() { Error.prepareStackTrace = "custom"; };
new Error().stack;
assertEquals("custom", Error.prepareStackTrace);
+
+// Check that the formatted stack trace can be set to undefined.
+error = new Error();
+error.stack = undefined;
+assertEquals(undefined, error.stack);
+
+// Check that the stack trace accessors are not forcibly set.
+var my_error = {};
+Object.freeze(my_error);
+assertThrows(function() { Error.captureStackTrace(my_error); });
+
+my_error = {};
+Object.preventExtensions(my_error);
+assertThrows(function() { Error.captureStackTrace(my_error); });
+
+var fake_error = {};
+my_error = new Error();
+var stolen_getter = Object.getOwnPropertyDescriptor(my_error, 'stack').get;
+Object.defineProperty(fake_error, 'stack', { get: stolen_getter });
+assertEquals(undefined, fake_error.stack);
diff --git a/deps/v8/test/mjsunit/tools/profviz-test.default b/deps/v8/test/mjsunit/tools/profviz-test.default
index 04185a260c..bff249d651 100644
--- a/deps/v8/test/mjsunit/tools/profviz-test.default
+++ b/deps/v8/test/mjsunit/tools/profviz-test.default
@@ -1,5 +1,5 @@
[
- "set yrange [0:24.5]",
+ "set yrange [0:25.5]",
"set xlabel \"execution time in ms\"",
"set xrange [2.4204999999999997:141.1669999999999]",
"set style fill pattern 2 bo 1",
@@ -17,7 +17,7 @@
"set object 6 rect from 57.242999999999974, 7 to 57.329716562499975, 6.766323024054983 fc rgb \"#9944CC\"",
"set object 7 rect from 58.751499999999965, 7 to 58.838216562499966, 6.766323024054983 fc rgb \"#9944CC\"",
"set object 8 rect from 60.72499999999996, 7 to 60.81171656249996, 6.766323024054983 fc rgb \"#9944CC\"",
- "set ytics out nomirror (\"execution (59.6%%)\" 12.5, \"external (0.2%%)\" 13.5, \"compile unopt (3.1%%)\" 14.5, \"recompile sync (6.7%%)\" 15.5, \"recompile async (11.6%%)\" 16.5, \"compile eval (0.0%%)\" 17.5, \"parse (10.0%%)\" 18.5, \"preparse (0.8%%)\" 19.5, \"lazy parse (2.9%%)\" 20.5, \"gc scavenge (1.7%%)\" 21.5, \"gc compaction (3.3%%)\" 22.5, \"gc context (0.0%%)\" 23.5, \"code kind color coding\" 11, \"code kind in execution\" 10, \"top 8 js stack frames\" 9, \"pause times\" 0, \"max deopt size: 9.1 kB\" 7)",
+ "set ytics out nomirror (\"execution (59.6%%)\" 12.5, \"external (0.2%%)\" 13.5, \"compile unopt (3.1%%)\" 14.5, \"recompile sync (6.6%%)\" 15.5, \"recompile async (11.6%%)\" 16.5, \"compile eval (0.0%%)\" 17.5, \"ic miss (0.0%%)\" 18.5, \"parse (9.9%%)\" 19.5, \"preparse (0.6%%)\" 20.5, \"lazy parse (2.9%%)\" 21.5, \"gc scavenge (1.6%%)\" 22.5, \"gc compaction (3.3%%)\" 23.5, \"gc context (0.0%%)\" 24.5, \"code kind color coding\" 11, \"code kind in execution\" 10, \"top 8 js stack frames\" 9, \"pause times\" 0, \"max deopt size: 9.1 kB\" 7)",
"set object 9 rect from 42.11000000000001, 12.83 to 42.28050000000001, 12.17 fc rgb \"#000000\"",
"set object 10 rect from 42.298000000000016, 12.83 to 42.30000000000002, 12.17 fc rgb \"#000000\"",
"set object 11 rect from 42.31450000000002, 12.83 to 42.62700000000002, 12.17 fc rgb \"#000000\"",
@@ -448,232 +448,232 @@
"set object 436 rect from 108.1159999999999, 16.83 to 110.07649999999991, 16.17 fc rgb \"#CC4499\"",
"set object 437 rect from 131.1424999999999, 16.83 to 133.02899999999988, 16.17 fc rgb \"#CC4499\"",
"set object 438 rect from 141.13349999999986, 16.83 to 141.1669999999999, 16.17 fc rgb \"#CC4499\"",
- "set object 439 rect from 22.2675, 18.83 to 22.3815, 18.17 fc rgb \"#00CC00\"",
- "set object 440 rect from 22.665, 18.83 to 23.1135, 18.17 fc rgb \"#00CC00\"",
- "set object 441 rect from 27.951000000000004, 18.83 to 27.972500000000004, 18.17 fc rgb \"#00CC00\"",
- "set object 442 rect from 27.993000000000002, 18.83 to 28.013500000000004, 18.17 fc rgb \"#00CC00\"",
- "set object 443 rect from 28.043000000000003, 18.83 to 28.063500000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 444 rect from 28.085000000000004, 18.83 to 28.087500000000002, 18.17 fc rgb \"#00CC00\"",
- "set object 445 rect from 28.115000000000002, 18.83 to 28.139500000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 446 rect from 28.154000000000007, 18.83 to 28.260000000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 447 rect from 28.309500000000003, 18.83 to 28.374000000000006, 18.17 fc rgb \"#00CC00\"",
- "set object 448 rect from 28.383500000000005, 18.83 to 28.385000000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 449 rect from 28.396500000000003, 18.83 to 28.445000000000007, 18.17 fc rgb \"#00CC00\"",
- "set object 450 rect from 28.459500000000006, 18.83 to 28.463000000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 451 rect from 28.489500000000007, 18.83 to 28.499000000000006, 18.17 fc rgb \"#00CC00\"",
- "set object 452 rect from 28.512500000000006, 18.83 to 28.516000000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 453 rect from 28.529500000000006, 18.83 to 28.533000000000005, 18.17 fc rgb \"#00CC00\"",
- "set object 454 rect from 28.554500000000004, 18.83 to 28.557000000000006, 18.17 fc rgb \"#00CC00\"",
- "set object 455 rect from 28.573500000000006, 18.83 to 28.579000000000008, 18.17 fc rgb \"#00CC00\"",
- "set object 456 rect from 28.59950000000001, 18.83 to 28.602000000000007, 18.17 fc rgb \"#00CC00\"",
- "set object 457 rect from 28.623500000000007, 18.83 to 28.625000000000007, 18.17 fc rgb \"#00CC00\"",
- "set object 458 rect from 28.637500000000006, 18.83 to 28.647000000000006, 18.17 fc rgb \"#00CC00\"",
- "set object 459 rect from 28.657500000000006, 18.83 to 28.669000000000008, 18.17 fc rgb \"#00CC00\"",
- "set object 460 rect from 28.682500000000005, 18.83 to 28.686000000000007, 18.17 fc rgb \"#00CC00\"",
- "set object 461 rect from 28.695500000000006, 18.83 to 28.701000000000008, 18.17 fc rgb \"#00CC00\"",
- "set object 462 rect from 28.72450000000001, 18.83 to 28.811000000000007, 18.17 fc rgb \"#00CC00\"",
- "set object 463 rect from 28.83250000000001, 18.83 to 28.907500000000006, 18.17 fc rgb \"#00CC00\"",
- "set object 464 rect from 28.97100000000001, 18.83 to 28.97450000000001, 18.17 fc rgb \"#00CC00\"",
- "set object 465 rect from 28.99600000000001, 18.83 to 28.99850000000001, 18.17 fc rgb \"#00CC00\"",
- "set object 466 rect from 29.01200000000001, 18.83 to 29.01350000000001, 18.17 fc rgb \"#00CC00\"",
- "set object 467 rect from 29.02600000000001, 18.83 to 29.056500000000007, 18.17 fc rgb \"#00CC00\"",
- "set object 468 rect from 29.06900000000001, 18.83 to 29.159500000000012, 18.17 fc rgb \"#00CC00\"",
- "set object 469 rect from 29.17100000000001, 18.83 to 29.18450000000001, 18.17 fc rgb \"#00CC00\"",
- "set object 470 rect from 29.19400000000001, 18.83 to 41.84850000000001, 18.17 fc rgb \"#00CC00\"",
- "set object 471 rect from 41.87900000000001, 18.83 to 41.88650000000001, 18.17 fc rgb \"#00CC00\"",
- "set object 472 rect from 27.972500000000004, 19.83 to 28.053000000000004, 19.17 fc rgb \"#44CC00\"",
- "set object 473 rect from 28.063500000000005, 19.83 to 28.169000000000004, 19.17 fc rgb \"#44CC00\"",
- "set object 474 rect from 28.260000000000005, 19.83 to 28.489500000000007, 19.17 fc rgb \"#44CC00\"",
- "set object 475 rect from 28.499000000000006, 19.83 to 28.761500000000005, 19.17 fc rgb \"#44CC00\"",
- "set object 476 rect from 28.78900000000001, 19.83 to 28.847500000000007, 19.17 fc rgb \"#44CC00\"",
- "set object 477 rect from 28.907500000000006, 19.83 to 29.047000000000008, 19.17 fc rgb \"#44CC00\"",
- "set object 478 rect from 29.056500000000007, 19.83 to 29.111000000000008, 19.17 fc rgb \"#44CC00\"",
- "set object 479 rect from 29.12350000000001, 19.83 to 29.21900000000001, 19.17 fc rgb \"#44CC00\"",
- "set object 480 rect from 41.82650000000001, 19.83 to 41.83500000000001, 19.17 fc rgb \"#44CC00\"",
- "set object 481 rect from 41.84850000000001, 19.83 to 41.87900000000001, 19.17 fc rgb \"#44CC00\"",
- "set object 482 rect from 16.737, 20.83 to 16.9595, 20.17 fc rgb \"#00CC44\"",
- "set object 483 rect from 17.8715, 20.83 to 18.017000000000003, 20.17 fc rgb \"#00CC44\"",
- "set object 484 rect from 18.992, 20.83 to 19.0685, 20.17 fc rgb \"#00CC44\"",
- "set object 485 rect from 20.52, 20.83 to 20.5975, 20.17 fc rgb \"#00CC44\"",
- "set object 486 rect from 21.109, 20.83 to 21.1335, 20.17 fc rgb \"#00CC44\"",
- "set object 487 rect from 21.212, 20.83 to 21.2695, 20.17 fc rgb \"#00CC44\"",
- "set object 488 rect from 21.4595, 20.83 to 21.49, 20.17 fc rgb \"#00CC44\"",
- "set object 489 rect from 21.566499999999998, 20.83 to 21.588, 20.17 fc rgb \"#00CC44\"",
- "set object 490 rect from 21.6535, 20.83 to 21.727, 20.17 fc rgb \"#00CC44\"",
- "set object 491 rect from 22.445, 20.83 to 22.4625, 20.17 fc rgb \"#00CC44\"",
- "set object 492 rect from 22.502000000000002, 20.83 to 22.5165, 20.17 fc rgb \"#00CC44\"",
- "set object 493 rect from 22.553, 20.83 to 22.5645, 20.17 fc rgb \"#00CC44\"",
- "set object 494 rect from 23.233, 20.83 to 23.336000000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 495 rect from 23.4255, 20.83 to 23.506, 20.17 fc rgb \"#00CC44\"",
- "set object 496 rect from 23.5895, 20.83 to 23.613, 20.17 fc rgb \"#00CC44\"",
- "set object 497 rect from 23.870500000000003, 20.83 to 23.907, 20.17 fc rgb \"#00CC44\"",
- "set object 498 rect from 24.393, 20.83 to 24.430500000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 499 rect from 24.470000000000002, 20.83 to 24.504500000000004, 20.17 fc rgb \"#00CC44\"",
- "set object 500 rect from 25.267500000000002, 20.83 to 25.283, 20.17 fc rgb \"#00CC44\"",
- "set object 501 rect from 25.4195, 20.83 to 25.427, 20.17 fc rgb \"#00CC44\"",
- "set object 502 rect from 25.519500000000004, 20.83 to 25.526000000000003, 20.17 fc rgb \"#00CC44\"",
- "set object 503 rect from 42.28050000000001, 20.83 to 42.298000000000016, 20.17 fc rgb \"#00CC44\"",
- "set object 504 rect from 42.62700000000002, 20.83 to 42.656500000000015, 20.17 fc rgb \"#00CC44\"",
- "set object 505 rect from 42.747000000000014, 20.83 to 42.763500000000015, 20.17 fc rgb \"#00CC44\"",
- "set object 506 rect from 42.80300000000001, 20.83 to 42.81050000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 507 rect from 42.844000000000015, 20.83 to 42.858500000000014, 20.17 fc rgb \"#00CC44\"",
- "set object 508 rect from 43.60550000000001, 20.83 to 43.62000000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 509 rect from 44.796000000000014, 20.83 to 44.81150000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 510 rect from 44.84500000000001, 20.83 to 44.87150000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 511 rect from 44.996000000000016, 20.83 to 45.00850000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 512 rect from 45.04700000000001, 20.83 to 45.06450000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 513 rect from 45.09600000000001, 20.83 to 45.107500000000016, 20.17 fc rgb \"#00CC44\"",
- "set object 514 rect from 45.14400000000002, 20.83 to 45.16150000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 515 rect from 45.32050000000002, 20.83 to 45.33700000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 516 rect from 45.38750000000002, 20.83 to 45.402000000000015, 20.17 fc rgb \"#00CC44\"",
- "set object 517 rect from 45.43250000000002, 20.83 to 45.442000000000014, 20.17 fc rgb \"#00CC44\"",
- "set object 518 rect from 45.46050000000002, 20.83 to 45.46500000000002, 20.17 fc rgb \"#00CC44\"",
- "set object 519 rect from 45.47750000000001, 20.83 to 45.48300000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 520 rect from 45.49750000000001, 20.83 to 45.55900000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 521 rect from 45.66050000000001, 20.83 to 45.70300000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 522 rect from 45.79350000000001, 20.83 to 45.81700000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 523 rect from 45.86950000000001, 20.83 to 45.92300000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 524 rect from 45.99450000000001, 20.83 to 46.060500000000005, 20.17 fc rgb \"#00CC44\"",
- "set object 525 rect from 46.18500000000001, 20.83 to 46.28150000000001, 20.17 fc rgb \"#00CC44\"",
- "set object 526 rect from 46.550000000000004, 20.83 to 46.5915, 20.17 fc rgb \"#00CC44\"",
- "set object 527 rect from 46.65500000000001, 20.83 to 46.691500000000005, 20.17 fc rgb \"#00CC44\"",
- "set object 528 rect from 46.861000000000004, 20.83 to 46.8935, 20.17 fc rgb \"#00CC44\"",
- "set object 529 rect from 47.039500000000004, 20.83 to 47.049, 20.17 fc rgb \"#00CC44\"",
- "set object 530 rect from 47.0765, 20.83 to 47.135000000000005, 20.17 fc rgb \"#00CC44\"",
- "set object 531 rect from 47.4125, 20.83 to 47.465, 20.17 fc rgb \"#00CC44\"",
- "set object 532 rect from 49.454499999999996, 20.83 to 49.467, 20.17 fc rgb \"#00CC44\"",
- "set object 533 rect from 49.6855, 20.83 to 49.726, 20.17 fc rgb \"#00CC44\"",
- "set object 534 rect from 49.799499999999995, 20.83 to 49.812999999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 535 rect from 49.841499999999996, 20.83 to 49.849999999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 536 rect from 49.894499999999994, 20.83 to 49.9695, 20.17 fc rgb \"#00CC44\"",
- "set object 537 rect from 50.083999999999996, 20.83 to 50.14149999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 538 rect from 50.29299999999999, 20.83 to 50.31249999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 539 rect from 50.36699999999999, 20.83 to 50.39849999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 540 rect from 50.520999999999994, 20.83 to 50.528499999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 541 rect from 50.54899999999999, 20.83 to 50.62049999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 542 rect from 51.27549999999999, 20.83 to 51.29099999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 543 rect from 51.52249999999999, 20.83 to 51.56899999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 544 rect from 51.87299999999998, 20.83 to 51.89049999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 545 rect from 52.115999999999985, 20.83 to 52.13449999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 546 rect from 52.286999999999985, 20.83 to 52.300499999999985, 20.17 fc rgb \"#00CC44\"",
- "set object 547 rect from 52.326999999999984, 20.83 to 52.33049999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 548 rect from 52.362999999999985, 20.83 to 52.404499999999985, 20.17 fc rgb \"#00CC44\"",
- "set object 549 rect from 54.566499999999984, 20.83 to 54.64299999999998, 20.17 fc rgb \"#00CC44\"",
- "set object 550 rect from 55.49149999999998, 20.83 to 55.53099999999998, 20.17 fc rgb \"#00CC44\"",
- "set object 551 rect from 56.64049999999998, 20.83 to 56.64999999999998, 20.17 fc rgb \"#00CC44\"",
- "set object 552 rect from 56.750999999999976, 20.83 to 56.76449999999998, 20.17 fc rgb \"#00CC44\"",
- "set object 553 rect from 57.039499999999975, 20.83 to 57.076499999999974, 20.17 fc rgb \"#00CC44\"",
- "set object 554 rect from 57.885999999999974, 20.83 to 57.893499999999975, 20.17 fc rgb \"#00CC44\"",
- "set object 555 rect from 57.97749999999997, 20.83 to 57.99099999999997, 20.17 fc rgb \"#00CC44\"",
- "set object 556 rect from 58.04499999999997, 20.83 to 58.055499999999974, 20.17 fc rgb \"#00CC44\"",
- "set object 557 rect from 58.14549999999997, 20.83 to 58.15399999999997, 20.17 fc rgb \"#00CC44\"",
- "set object 558 rect from 58.17549999999997, 20.83 to 58.18399999999997, 20.17 fc rgb \"#00CC44\"",
- "set object 559 rect from 58.40999999999997, 20.83 to 58.431499999999964, 20.17 fc rgb \"#00CC44\"",
- "set object 560 rect from 58.51699999999997, 20.83 to 58.53049999999997, 20.17 fc rgb \"#00CC44\"",
- "set object 561 rect from 58.590999999999966, 20.83 to 58.60049999999997, 20.17 fc rgb \"#00CC44\"",
- "set object 562 rect from 59.65599999999996, 20.83 to 59.669499999999964, 20.17 fc rgb \"#00CC44\"",
- "set object 563 rect from 60.05149999999996, 20.83 to 60.060999999999964, 20.17 fc rgb \"#00CC44\"",
- "set object 564 rect from 60.176999999999964, 20.83 to 60.19499999999996, 20.17 fc rgb \"#00CC44\"",
- "set object 565 rect from 60.26949999999996, 20.83 to 60.27999999999996, 20.17 fc rgb \"#00CC44\"",
- "set object 566 rect from 60.31149999999996, 20.83 to 60.34699999999996, 20.17 fc rgb \"#00CC44\"",
- "set object 567 rect from 60.471499999999956, 20.83 to 60.48399999999996, 20.17 fc rgb \"#00CC44\"",
- "set object 568 rect from 60.508499999999955, 20.83 to 60.51999999999996, 20.17 fc rgb \"#00CC44\"",
- "set object 569 rect from 60.92099999999996, 20.83 to 60.98249999999996, 20.17 fc rgb \"#00CC44\"",
- "set object 570 rect from 63.15199999999995, 20.83 to 63.228499999999954, 20.17 fc rgb \"#00CC44\"",
- "set object 571 rect from 67.34999999999994, 20.83 to 67.36349999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 572 rect from 67.40699999999995, 20.83 to 67.41249999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 573 rect from 67.45699999999994, 20.83 to 67.46599999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 574 rect from 69.11299999999994, 20.83 to 69.12949999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 575 rect from 69.19199999999995, 20.83 to 69.22649999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 576 rect from 69.30799999999994, 20.83 to 69.31949999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 577 rect from 69.34699999999995, 20.83 to 69.35749999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 578 rect from 69.38399999999996, 20.83 to 69.40549999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 579 rect from 69.45099999999994, 20.83 to 69.46349999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 580 rect from 70.31749999999994, 20.83 to 70.33949999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 581 rect from 74.41449999999995, 20.83 to 74.43899999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 582 rect from 74.52049999999994, 20.83 to 74.54499999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 583 rect from 74.59549999999994, 20.83 to 74.60899999999995, 20.17 fc rgb \"#00CC44\"",
- "set object 584 rect from 84.09999999999994, 20.83 to 84.15349999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 585 rect from 84.26099999999994, 20.83 to 84.27549999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 586 rect from 84.31099999999992, 20.83 to 84.31949999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 587 rect from 84.34199999999993, 20.83 to 84.35349999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 588 rect from 84.37299999999993, 20.83 to 84.40149999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 589 rect from 84.43999999999994, 20.83 to 84.46149999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 590 rect from 84.53049999999993, 20.83 to 84.60099999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 591 rect from 84.68049999999992, 20.83 to 84.69199999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 592 rect from 84.71649999999993, 20.83 to 84.72799999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 593 rect from 84.92199999999994, 20.83 to 84.93849999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 594 rect from 84.99799999999993, 20.83 to 85.01049999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 595 rect from 85.03599999999992, 20.83 to 85.04449999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 596 rect from 85.06199999999993, 20.83 to 85.07249999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 597 rect from 85.09499999999994, 20.83 to 85.10249999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 598 rect from 85.38399999999993, 20.83 to 85.43999999999994, 20.17 fc rgb \"#00CC44\"",
- "set object 599 rect from 85.59949999999992, 20.83 to 85.61599999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 600 rect from 85.63749999999993, 20.83 to 85.65899999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 601 rect from 85.69649999999993, 20.83 to 85.70599999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 602 rect from 85.73249999999993, 20.83 to 85.76899999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 603 rect from 85.86549999999993, 20.83 to 85.87599999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 604 rect from 85.91149999999992, 20.83 to 85.92499999999993, 20.17 fc rgb \"#00CC44\"",
- "set object 605 rect from 102.74599999999992, 20.83 to 102.80749999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 606 rect from 107.5244999999999, 20.83 to 107.57199999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 607 rect from 107.62449999999991, 20.83 to 107.6389999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 608 rect from 107.6674999999999, 20.83 to 107.6759999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 609 rect from 107.69849999999991, 20.83 to 107.70999999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 610 rect from 107.7294999999999, 20.83 to 107.7469999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 611 rect from 107.7834999999999, 20.83 to 107.79299999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 612 rect from 107.82049999999991, 20.83 to 107.8529999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 613 rect from 107.9294999999999, 20.83 to 107.94099999999992, 20.17 fc rgb \"#00CC44\"",
- "set object 614 rect from 107.9654999999999, 20.83 to 107.97599999999991, 20.17 fc rgb \"#00CC44\"",
- "set object 615 rect from 130.5489999999999, 20.83 to 130.5954999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 616 rect from 130.6469999999999, 20.83 to 130.6614999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 617 rect from 130.68999999999988, 20.83 to 130.6994999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 618 rect from 130.7219999999999, 20.83 to 130.7324999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 619 rect from 130.7519999999999, 20.83 to 130.76949999999988, 20.17 fc rgb \"#00CC44\"",
- "set object 620 rect from 130.8059999999999, 20.83 to 130.8154999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 621 rect from 130.84299999999988, 20.83 to 130.87549999999987, 20.17 fc rgb \"#00CC44\"",
- "set object 622 rect from 130.95199999999988, 20.83 to 130.9644999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 623 rect from 130.99099999999987, 20.83 to 131.00249999999988, 20.17 fc rgb \"#00CC44\"",
- "set object 624 rect from 140.86699999999988, 20.83 to 140.8814999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 625 rect from 140.9319999999999, 20.83 to 140.9574999999999, 20.17 fc rgb \"#00CC44\"",
- "set object 626 rect from 141.0299999999999, 20.83 to 141.03849999999989, 20.17 fc rgb \"#00CC44\"",
- "set object 627 rect from 55.79999999999998, 21.83 to 56.198999999999984, 21.17 fc rgb \"#0044CC\"",
- "set object 628 rect from 62.16149999999996, 21.83 to 62.548999999999964, 21.17 fc rgb \"#0044CC\"",
- "set object 629 rect from 65.56449999999995, 21.83 to 65.61699999999995, 21.17 fc rgb \"#0044CC\"",
- "set object 630 rect from 68.70599999999996, 21.83 to 68.76649999999995, 21.17 fc rgb \"#0044CC\"",
- "set object 631 rect from 72.22199999999995, 21.83 to 72.28049999999995, 21.17 fc rgb \"#0044CC\"",
- "set object 632 rect from 75.41849999999994, 21.83 to 75.46799999999995, 21.17 fc rgb \"#0044CC\"",
- "set object 633 rect from 78.16449999999993, 21.83 to 78.23649999999994, 21.17 fc rgb \"#0044CC\"",
- "set object 634 rect from 80.90399999999994, 21.83 to 80.95049999999993, 21.17 fc rgb \"#0044CC\"",
- "set object 635 rect from 83.58349999999993, 21.83 to 83.63999999999993, 21.17 fc rgb \"#0044CC\"",
- "set object 636 rect from 88.75199999999992, 21.83 to 88.82299999999992, 21.17 fc rgb \"#0044CC\"",
- "set object 637 rect from 91.90999999999991, 21.83 to 91.96649999999993, 21.17 fc rgb \"#0044CC\"",
- "set object 638 rect from 94.55599999999993, 21.83 to 94.6054999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 639 rect from 97.20749999999991, 21.83 to 97.26099999999992, 21.17 fc rgb \"#0044CC\"",
- "set object 640 rect from 99.86649999999992, 21.83 to 99.92199999999991, 21.17 fc rgb \"#0044CC\"",
- "set object 641 rect from 102.56049999999992, 21.83 to 102.61199999999991, 21.17 fc rgb \"#0044CC\"",
- "set object 642 rect from 105.88099999999991, 21.83 to 105.93349999999991, 21.17 fc rgb \"#0044CC\"",
- "set object 643 rect from 109.2659999999999, 21.83 to 109.38599999999991, 21.17 fc rgb \"#0044CC\"",
- "set object 644 rect from 109.4024999999999, 21.83 to 109.41799999999989, 21.17 fc rgb \"#0044CC\"",
- "set object 645 rect from 112.6029999999999, 21.83 to 112.6564999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 646 rect from 115.36399999999989, 21.83 to 115.4124999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 647 rect from 118.1434999999999, 21.83 to 118.19199999999991, 21.17 fc rgb \"#0044CC\"",
- "set object 648 rect from 120.9194999999999, 21.83 to 121.0104999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 649 rect from 121.0259999999999, 21.83 to 121.0314999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 650 rect from 123.77499999999989, 21.83 to 123.8254999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 651 rect from 126.55149999999989, 21.83 to 126.59899999999989, 21.17 fc rgb \"#0044CC\"",
- "set object 652 rect from 129.3344999999999, 21.83 to 129.4124999999999, 21.17 fc rgb \"#0044CC\"",
- "set object 653 rect from 129.4249999999999, 21.83 to 129.48849999999987, 21.17 fc rgb \"#0044CC\"",
- "set object 654 rect from 132.8659999999999, 21.83 to 132.92249999999987, 21.17 fc rgb \"#0044CC\"",
- "set object 655 rect from 136.14449999999988, 21.83 to 136.19799999999987, 21.17 fc rgb \"#0044CC\"",
- "set object 656 rect from 138.9289999999999, 21.83 to 138.98049999999986, 21.17 fc rgb \"#0044CC\"",
- "set object 657 rect from 2.4204999999999997, 22.83 to 3.7920000000000003, 22.17 fc rgb \"#4444CC\"",
- "set object 658 rect from 3.8075, 22.83 to 3.8129999999999997, 22.17 fc rgb \"#4444CC\"",
- "set object 659 rect from 6.2695, 22.83 to 7.373, 22.17 fc rgb \"#4444CC\"",
- "set object 660 rect from 7.3865, 22.83 to 7.3919999999999995, 22.17 fc rgb \"#4444CC\"",
- "set object 661 rect from 9.2915, 22.83 to 10.405000000000001, 22.17 fc rgb \"#4444CC\"",
- "set object 662 rect from 10.4235, 22.83 to 10.43, 22.17 fc rgb \"#4444CC\"",
- "set object 663 rect from 12.8765, 22.83 to 13.897, 22.17 fc rgb \"#4444CC\"",
- "set object 664 rect from 13.910499999999999, 22.83 to 13.915999999999999, 22.17 fc rgb \"#4444CC\"",
+ "set object 439 rect from 22.2675, 19.83 to 22.3815, 19.17 fc rgb \"#00CC00\"",
+ "set object 440 rect from 22.665, 19.83 to 23.1135, 19.17 fc rgb \"#00CC00\"",
+ "set object 441 rect from 27.951000000000004, 19.83 to 27.972500000000004, 19.17 fc rgb \"#00CC00\"",
+ "set object 442 rect from 27.993000000000002, 19.83 to 28.013500000000004, 19.17 fc rgb \"#00CC00\"",
+ "set object 443 rect from 28.043000000000003, 19.83 to 28.063500000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 444 rect from 28.085000000000004, 19.83 to 28.087500000000002, 19.17 fc rgb \"#00CC00\"",
+ "set object 445 rect from 28.115000000000002, 19.83 to 28.139500000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 446 rect from 28.154000000000007, 19.83 to 28.260000000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 447 rect from 28.309500000000003, 19.83 to 28.374000000000006, 19.17 fc rgb \"#00CC00\"",
+ "set object 448 rect from 28.383500000000005, 19.83 to 28.385000000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 449 rect from 28.396500000000003, 19.83 to 28.445000000000007, 19.17 fc rgb \"#00CC00\"",
+ "set object 450 rect from 28.459500000000006, 19.83 to 28.463000000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 451 rect from 28.489500000000007, 19.83 to 28.499000000000006, 19.17 fc rgb \"#00CC00\"",
+ "set object 452 rect from 28.512500000000006, 19.83 to 28.516000000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 453 rect from 28.529500000000006, 19.83 to 28.533000000000005, 19.17 fc rgb \"#00CC00\"",
+ "set object 454 rect from 28.554500000000004, 19.83 to 28.557000000000006, 19.17 fc rgb \"#00CC00\"",
+ "set object 455 rect from 28.573500000000006, 19.83 to 28.579000000000008, 19.17 fc rgb \"#00CC00\"",
+ "set object 456 rect from 28.59950000000001, 19.83 to 28.602000000000007, 19.17 fc rgb \"#00CC00\"",
+ "set object 457 rect from 28.623500000000007, 19.83 to 28.625000000000007, 19.17 fc rgb \"#00CC00\"",
+ "set object 458 rect from 28.637500000000006, 19.83 to 28.647000000000006, 19.17 fc rgb \"#00CC00\"",
+ "set object 459 rect from 28.657500000000006, 19.83 to 28.669000000000008, 19.17 fc rgb \"#00CC00\"",
+ "set object 460 rect from 28.682500000000005, 19.83 to 28.686000000000007, 19.17 fc rgb \"#00CC00\"",
+ "set object 461 rect from 28.695500000000006, 19.83 to 28.701000000000008, 19.17 fc rgb \"#00CC00\"",
+ "set object 462 rect from 28.72450000000001, 19.83 to 28.811000000000007, 19.17 fc rgb \"#00CC00\"",
+ "set object 463 rect from 28.83250000000001, 19.83 to 28.907500000000006, 19.17 fc rgb \"#00CC00\"",
+ "set object 464 rect from 28.97100000000001, 19.83 to 28.97450000000001, 19.17 fc rgb \"#00CC00\"",
+ "set object 465 rect from 28.99600000000001, 19.83 to 28.99850000000001, 19.17 fc rgb \"#00CC00\"",
+ "set object 466 rect from 29.01200000000001, 19.83 to 29.01350000000001, 19.17 fc rgb \"#00CC00\"",
+ "set object 467 rect from 29.02600000000001, 19.83 to 29.056500000000007, 19.17 fc rgb \"#00CC00\"",
+ "set object 468 rect from 29.06900000000001, 19.83 to 29.159500000000012, 19.17 fc rgb \"#00CC00\"",
+ "set object 469 rect from 29.17100000000001, 19.83 to 29.18450000000001, 19.17 fc rgb \"#00CC00\"",
+ "set object 470 rect from 29.19400000000001, 19.83 to 41.84850000000001, 19.17 fc rgb \"#00CC00\"",
+ "set object 471 rect from 41.87900000000001, 19.83 to 41.88650000000001, 19.17 fc rgb \"#00CC00\"",
+ "set object 472 rect from 27.972500000000004, 20.83 to 28.053000000000004, 20.17 fc rgb \"#44CC00\"",
+ "set object 473 rect from 28.063500000000005, 20.83 to 28.169000000000004, 20.17 fc rgb \"#44CC00\"",
+ "set object 474 rect from 28.260000000000005, 20.83 to 28.489500000000007, 20.17 fc rgb \"#44CC00\"",
+ "set object 475 rect from 28.499000000000006, 20.83 to 28.761500000000005, 20.17 fc rgb \"#44CC00\"",
+ "set object 476 rect from 28.78900000000001, 20.83 to 28.847500000000007, 20.17 fc rgb \"#44CC00\"",
+ "set object 477 rect from 28.907500000000006, 20.83 to 29.047000000000008, 20.17 fc rgb \"#44CC00\"",
+ "set object 478 rect from 29.056500000000007, 20.83 to 29.111000000000008, 20.17 fc rgb \"#44CC00\"",
+ "set object 479 rect from 29.12350000000001, 20.83 to 29.21900000000001, 20.17 fc rgb \"#44CC00\"",
+ "set object 480 rect from 41.82650000000001, 20.83 to 41.83500000000001, 20.17 fc rgb \"#44CC00\"",
+ "set object 481 rect from 41.84850000000001, 20.83 to 41.87900000000001, 20.17 fc rgb \"#44CC00\"",
+ "set object 482 rect from 16.737, 21.83 to 16.9595, 21.17 fc rgb \"#00CC44\"",
+ "set object 483 rect from 17.8715, 21.83 to 18.017000000000003, 21.17 fc rgb \"#00CC44\"",
+ "set object 484 rect from 18.992, 21.83 to 19.0685, 21.17 fc rgb \"#00CC44\"",
+ "set object 485 rect from 20.52, 21.83 to 20.5975, 21.17 fc rgb \"#00CC44\"",
+ "set object 486 rect from 21.109, 21.83 to 21.1335, 21.17 fc rgb \"#00CC44\"",
+ "set object 487 rect from 21.212, 21.83 to 21.2695, 21.17 fc rgb \"#00CC44\"",
+ "set object 488 rect from 21.4595, 21.83 to 21.49, 21.17 fc rgb \"#00CC44\"",
+ "set object 489 rect from 21.566499999999998, 21.83 to 21.588, 21.17 fc rgb \"#00CC44\"",
+ "set object 490 rect from 21.6535, 21.83 to 21.727, 21.17 fc rgb \"#00CC44\"",
+ "set object 491 rect from 22.445, 21.83 to 22.4625, 21.17 fc rgb \"#00CC44\"",
+ "set object 492 rect from 22.502000000000002, 21.83 to 22.5165, 21.17 fc rgb \"#00CC44\"",
+ "set object 493 rect from 22.553, 21.83 to 22.5645, 21.17 fc rgb \"#00CC44\"",
+ "set object 494 rect from 23.233, 21.83 to 23.336000000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 495 rect from 23.4255, 21.83 to 23.506, 21.17 fc rgb \"#00CC44\"",
+ "set object 496 rect from 23.5895, 21.83 to 23.613, 21.17 fc rgb \"#00CC44\"",
+ "set object 497 rect from 23.870500000000003, 21.83 to 23.907, 21.17 fc rgb \"#00CC44\"",
+ "set object 498 rect from 24.393, 21.83 to 24.430500000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 499 rect from 24.470000000000002, 21.83 to 24.504500000000004, 21.17 fc rgb \"#00CC44\"",
+ "set object 500 rect from 25.267500000000002, 21.83 to 25.283, 21.17 fc rgb \"#00CC44\"",
+ "set object 501 rect from 25.4195, 21.83 to 25.427, 21.17 fc rgb \"#00CC44\"",
+ "set object 502 rect from 25.519500000000004, 21.83 to 25.526000000000003, 21.17 fc rgb \"#00CC44\"",
+ "set object 503 rect from 42.28050000000001, 21.83 to 42.298000000000016, 21.17 fc rgb \"#00CC44\"",
+ "set object 504 rect from 42.62700000000002, 21.83 to 42.656500000000015, 21.17 fc rgb \"#00CC44\"",
+ "set object 505 rect from 42.747000000000014, 21.83 to 42.763500000000015, 21.17 fc rgb \"#00CC44\"",
+ "set object 506 rect from 42.80300000000001, 21.83 to 42.81050000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 507 rect from 42.844000000000015, 21.83 to 42.858500000000014, 21.17 fc rgb \"#00CC44\"",
+ "set object 508 rect from 43.60550000000001, 21.83 to 43.62000000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 509 rect from 44.796000000000014, 21.83 to 44.81150000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 510 rect from 44.84500000000001, 21.83 to 44.87150000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 511 rect from 44.996000000000016, 21.83 to 45.00850000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 512 rect from 45.04700000000001, 21.83 to 45.06450000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 513 rect from 45.09600000000001, 21.83 to 45.107500000000016, 21.17 fc rgb \"#00CC44\"",
+ "set object 514 rect from 45.14400000000002, 21.83 to 45.16150000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 515 rect from 45.32050000000002, 21.83 to 45.33700000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 516 rect from 45.38750000000002, 21.83 to 45.402000000000015, 21.17 fc rgb \"#00CC44\"",
+ "set object 517 rect from 45.43250000000002, 21.83 to 45.442000000000014, 21.17 fc rgb \"#00CC44\"",
+ "set object 518 rect from 45.46050000000002, 21.83 to 45.46500000000002, 21.17 fc rgb \"#00CC44\"",
+ "set object 519 rect from 45.47750000000001, 21.83 to 45.48300000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 520 rect from 45.49750000000001, 21.83 to 45.55900000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 521 rect from 45.66050000000001, 21.83 to 45.70300000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 522 rect from 45.79350000000001, 21.83 to 45.81700000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 523 rect from 45.86950000000001, 21.83 to 45.92300000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 524 rect from 45.99450000000001, 21.83 to 46.060500000000005, 21.17 fc rgb \"#00CC44\"",
+ "set object 525 rect from 46.18500000000001, 21.83 to 46.28150000000001, 21.17 fc rgb \"#00CC44\"",
+ "set object 526 rect from 46.550000000000004, 21.83 to 46.5915, 21.17 fc rgb \"#00CC44\"",
+ "set object 527 rect from 46.65500000000001, 21.83 to 46.691500000000005, 21.17 fc rgb \"#00CC44\"",
+ "set object 528 rect from 46.861000000000004, 21.83 to 46.8935, 21.17 fc rgb \"#00CC44\"",
+ "set object 529 rect from 47.039500000000004, 21.83 to 47.049, 21.17 fc rgb \"#00CC44\"",
+ "set object 530 rect from 47.0765, 21.83 to 47.135000000000005, 21.17 fc rgb \"#00CC44\"",
+ "set object 531 rect from 47.4125, 21.83 to 47.465, 21.17 fc rgb \"#00CC44\"",
+ "set object 532 rect from 49.454499999999996, 21.83 to 49.467, 21.17 fc rgb \"#00CC44\"",
+ "set object 533 rect from 49.6855, 21.83 to 49.726, 21.17 fc rgb \"#00CC44\"",
+ "set object 534 rect from 49.799499999999995, 21.83 to 49.812999999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 535 rect from 49.841499999999996, 21.83 to 49.849999999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 536 rect from 49.894499999999994, 21.83 to 49.9695, 21.17 fc rgb \"#00CC44\"",
+ "set object 537 rect from 50.083999999999996, 21.83 to 50.14149999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 538 rect from 50.29299999999999, 21.83 to 50.31249999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 539 rect from 50.36699999999999, 21.83 to 50.39849999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 540 rect from 50.520999999999994, 21.83 to 50.528499999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 541 rect from 50.54899999999999, 21.83 to 50.62049999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 542 rect from 51.27549999999999, 21.83 to 51.29099999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 543 rect from 51.52249999999999, 21.83 to 51.56899999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 544 rect from 51.87299999999998, 21.83 to 51.89049999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 545 rect from 52.115999999999985, 21.83 to 52.13449999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 546 rect from 52.286999999999985, 21.83 to 52.300499999999985, 21.17 fc rgb \"#00CC44\"",
+ "set object 547 rect from 52.326999999999984, 21.83 to 52.33049999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 548 rect from 52.362999999999985, 21.83 to 52.404499999999985, 21.17 fc rgb \"#00CC44\"",
+ "set object 549 rect from 54.566499999999984, 21.83 to 54.64299999999998, 21.17 fc rgb \"#00CC44\"",
+ "set object 550 rect from 55.49149999999998, 21.83 to 55.53099999999998, 21.17 fc rgb \"#00CC44\"",
+ "set object 551 rect from 56.64049999999998, 21.83 to 56.64999999999998, 21.17 fc rgb \"#00CC44\"",
+ "set object 552 rect from 56.750999999999976, 21.83 to 56.76449999999998, 21.17 fc rgb \"#00CC44\"",
+ "set object 553 rect from 57.039499999999975, 21.83 to 57.076499999999974, 21.17 fc rgb \"#00CC44\"",
+ "set object 554 rect from 57.885999999999974, 21.83 to 57.893499999999975, 21.17 fc rgb \"#00CC44\"",
+ "set object 555 rect from 57.97749999999997, 21.83 to 57.99099999999997, 21.17 fc rgb \"#00CC44\"",
+ "set object 556 rect from 58.04499999999997, 21.83 to 58.055499999999974, 21.17 fc rgb \"#00CC44\"",
+ "set object 557 rect from 58.14549999999997, 21.83 to 58.15399999999997, 21.17 fc rgb \"#00CC44\"",
+ "set object 558 rect from 58.17549999999997, 21.83 to 58.18399999999997, 21.17 fc rgb \"#00CC44\"",
+ "set object 559 rect from 58.40999999999997, 21.83 to 58.431499999999964, 21.17 fc rgb \"#00CC44\"",
+ "set object 560 rect from 58.51699999999997, 21.83 to 58.53049999999997, 21.17 fc rgb \"#00CC44\"",
+ "set object 561 rect from 58.590999999999966, 21.83 to 58.60049999999997, 21.17 fc rgb \"#00CC44\"",
+ "set object 562 rect from 59.65599999999996, 21.83 to 59.669499999999964, 21.17 fc rgb \"#00CC44\"",
+ "set object 563 rect from 60.05149999999996, 21.83 to 60.060999999999964, 21.17 fc rgb \"#00CC44\"",
+ "set object 564 rect from 60.176999999999964, 21.83 to 60.19499999999996, 21.17 fc rgb \"#00CC44\"",
+ "set object 565 rect from 60.26949999999996, 21.83 to 60.27999999999996, 21.17 fc rgb \"#00CC44\"",
+ "set object 566 rect from 60.31149999999996, 21.83 to 60.34699999999996, 21.17 fc rgb \"#00CC44\"",
+ "set object 567 rect from 60.471499999999956, 21.83 to 60.48399999999996, 21.17 fc rgb \"#00CC44\"",
+ "set object 568 rect from 60.508499999999955, 21.83 to 60.51999999999996, 21.17 fc rgb \"#00CC44\"",
+ "set object 569 rect from 60.92099999999996, 21.83 to 60.98249999999996, 21.17 fc rgb \"#00CC44\"",
+ "set object 570 rect from 63.15199999999995, 21.83 to 63.228499999999954, 21.17 fc rgb \"#00CC44\"",
+ "set object 571 rect from 67.34999999999994, 21.83 to 67.36349999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 572 rect from 67.40699999999995, 21.83 to 67.41249999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 573 rect from 67.45699999999994, 21.83 to 67.46599999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 574 rect from 69.11299999999994, 21.83 to 69.12949999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 575 rect from 69.19199999999995, 21.83 to 69.22649999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 576 rect from 69.30799999999994, 21.83 to 69.31949999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 577 rect from 69.34699999999995, 21.83 to 69.35749999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 578 rect from 69.38399999999996, 21.83 to 69.40549999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 579 rect from 69.45099999999994, 21.83 to 69.46349999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 580 rect from 70.31749999999994, 21.83 to 70.33949999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 581 rect from 74.41449999999995, 21.83 to 74.43899999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 582 rect from 74.52049999999994, 21.83 to 74.54499999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 583 rect from 74.59549999999994, 21.83 to 74.60899999999995, 21.17 fc rgb \"#00CC44\"",
+ "set object 584 rect from 84.09999999999994, 21.83 to 84.15349999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 585 rect from 84.26099999999994, 21.83 to 84.27549999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 586 rect from 84.31099999999992, 21.83 to 84.31949999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 587 rect from 84.34199999999993, 21.83 to 84.35349999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 588 rect from 84.37299999999993, 21.83 to 84.40149999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 589 rect from 84.43999999999994, 21.83 to 84.46149999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 590 rect from 84.53049999999993, 21.83 to 84.60099999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 591 rect from 84.68049999999992, 21.83 to 84.69199999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 592 rect from 84.71649999999993, 21.83 to 84.72799999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 593 rect from 84.92199999999994, 21.83 to 84.93849999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 594 rect from 84.99799999999993, 21.83 to 85.01049999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 595 rect from 85.03599999999992, 21.83 to 85.04449999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 596 rect from 85.06199999999993, 21.83 to 85.07249999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 597 rect from 85.09499999999994, 21.83 to 85.10249999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 598 rect from 85.38399999999993, 21.83 to 85.43999999999994, 21.17 fc rgb \"#00CC44\"",
+ "set object 599 rect from 85.59949999999992, 21.83 to 85.61599999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 600 rect from 85.63749999999993, 21.83 to 85.65899999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 601 rect from 85.69649999999993, 21.83 to 85.70599999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 602 rect from 85.73249999999993, 21.83 to 85.76899999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 603 rect from 85.86549999999993, 21.83 to 85.87599999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 604 rect from 85.91149999999992, 21.83 to 85.92499999999993, 21.17 fc rgb \"#00CC44\"",
+ "set object 605 rect from 102.74599999999992, 21.83 to 102.80749999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 606 rect from 107.5244999999999, 21.83 to 107.57199999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 607 rect from 107.62449999999991, 21.83 to 107.6389999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 608 rect from 107.6674999999999, 21.83 to 107.6759999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 609 rect from 107.69849999999991, 21.83 to 107.70999999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 610 rect from 107.7294999999999, 21.83 to 107.7469999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 611 rect from 107.7834999999999, 21.83 to 107.79299999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 612 rect from 107.82049999999991, 21.83 to 107.8529999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 613 rect from 107.9294999999999, 21.83 to 107.94099999999992, 21.17 fc rgb \"#00CC44\"",
+ "set object 614 rect from 107.9654999999999, 21.83 to 107.97599999999991, 21.17 fc rgb \"#00CC44\"",
+ "set object 615 rect from 130.5489999999999, 21.83 to 130.5954999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 616 rect from 130.6469999999999, 21.83 to 130.6614999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 617 rect from 130.68999999999988, 21.83 to 130.6994999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 618 rect from 130.7219999999999, 21.83 to 130.7324999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 619 rect from 130.7519999999999, 21.83 to 130.76949999999988, 21.17 fc rgb \"#00CC44\"",
+ "set object 620 rect from 130.8059999999999, 21.83 to 130.8154999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 621 rect from 130.84299999999988, 21.83 to 130.87549999999987, 21.17 fc rgb \"#00CC44\"",
+ "set object 622 rect from 130.95199999999988, 21.83 to 130.9644999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 623 rect from 130.99099999999987, 21.83 to 131.00249999999988, 21.17 fc rgb \"#00CC44\"",
+ "set object 624 rect from 140.86699999999988, 21.83 to 140.8814999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 625 rect from 140.9319999999999, 21.83 to 140.9574999999999, 21.17 fc rgb \"#00CC44\"",
+ "set object 626 rect from 141.0299999999999, 21.83 to 141.03849999999989, 21.17 fc rgb \"#00CC44\"",
+ "set object 627 rect from 55.79999999999998, 22.83 to 56.198999999999984, 22.17 fc rgb \"#0044CC\"",
+ "set object 628 rect from 62.16149999999996, 22.83 to 62.548999999999964, 22.17 fc rgb \"#0044CC\"",
+ "set object 629 rect from 65.56449999999995, 22.83 to 65.61699999999995, 22.17 fc rgb \"#0044CC\"",
+ "set object 630 rect from 68.70599999999996, 22.83 to 68.76649999999995, 22.17 fc rgb \"#0044CC\"",
+ "set object 631 rect from 72.22199999999995, 22.83 to 72.28049999999995, 22.17 fc rgb \"#0044CC\"",
+ "set object 632 rect from 75.41849999999994, 22.83 to 75.46799999999995, 22.17 fc rgb \"#0044CC\"",
+ "set object 633 rect from 78.16449999999993, 22.83 to 78.23649999999994, 22.17 fc rgb \"#0044CC\"",
+ "set object 634 rect from 80.90399999999994, 22.83 to 80.95049999999993, 22.17 fc rgb \"#0044CC\"",
+ "set object 635 rect from 83.58349999999993, 22.83 to 83.63999999999993, 22.17 fc rgb \"#0044CC\"",
+ "set object 636 rect from 88.75199999999992, 22.83 to 88.82299999999992, 22.17 fc rgb \"#0044CC\"",
+ "set object 637 rect from 91.90999999999991, 22.83 to 91.96649999999993, 22.17 fc rgb \"#0044CC\"",
+ "set object 638 rect from 94.55599999999993, 22.83 to 94.6054999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 639 rect from 97.20749999999991, 22.83 to 97.26099999999992, 22.17 fc rgb \"#0044CC\"",
+ "set object 640 rect from 99.86649999999992, 22.83 to 99.92199999999991, 22.17 fc rgb \"#0044CC\"",
+ "set object 641 rect from 102.56049999999992, 22.83 to 102.61199999999991, 22.17 fc rgb \"#0044CC\"",
+ "set object 642 rect from 105.88099999999991, 22.83 to 105.93349999999991, 22.17 fc rgb \"#0044CC\"",
+ "set object 643 rect from 109.2659999999999, 22.83 to 109.38599999999991, 22.17 fc rgb \"#0044CC\"",
+ "set object 644 rect from 109.4024999999999, 22.83 to 109.41799999999989, 22.17 fc rgb \"#0044CC\"",
+ "set object 645 rect from 112.6029999999999, 22.83 to 112.6564999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 646 rect from 115.36399999999989, 22.83 to 115.4124999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 647 rect from 118.1434999999999, 22.83 to 118.19199999999991, 22.17 fc rgb \"#0044CC\"",
+ "set object 648 rect from 120.9194999999999, 22.83 to 121.0104999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 649 rect from 121.0259999999999, 22.83 to 121.0314999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 650 rect from 123.77499999999989, 22.83 to 123.8254999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 651 rect from 126.55149999999989, 22.83 to 126.59899999999989, 22.17 fc rgb \"#0044CC\"",
+ "set object 652 rect from 129.3344999999999, 22.83 to 129.4124999999999, 22.17 fc rgb \"#0044CC\"",
+ "set object 653 rect from 129.4249999999999, 22.83 to 129.48849999999987, 22.17 fc rgb \"#0044CC\"",
+ "set object 654 rect from 132.8659999999999, 22.83 to 132.92249999999987, 22.17 fc rgb \"#0044CC\"",
+ "set object 655 rect from 136.14449999999988, 22.83 to 136.19799999999987, 22.17 fc rgb \"#0044CC\"",
+ "set object 656 rect from 138.9289999999999, 22.83 to 138.98049999999986, 22.17 fc rgb \"#0044CC\"",
+ "set object 657 rect from 2.4204999999999997, 23.83 to 3.7920000000000003, 23.17 fc rgb \"#4444CC\"",
+ "set object 658 rect from 3.8075, 23.83 to 3.8129999999999997, 23.17 fc rgb \"#4444CC\"",
+ "set object 659 rect from 6.2695, 23.83 to 7.373, 23.17 fc rgb \"#4444CC\"",
+ "set object 660 rect from 7.3865, 23.83 to 7.3919999999999995, 23.17 fc rgb \"#4444CC\"",
+ "set object 661 rect from 9.2915, 23.83 to 10.405000000000001, 23.17 fc rgb \"#4444CC\"",
+ "set object 662 rect from 10.4235, 23.83 to 10.43, 23.17 fc rgb \"#4444CC\"",
+ "set object 663 rect from 12.8765, 23.83 to 13.897, 23.17 fc rgb \"#4444CC\"",
+ "set object 664 rect from 13.910499999999999, 23.83 to 13.915999999999999, 23.17 fc rgb \"#4444CC\"",
"set object 665 rect from 18.803, 10.2 to 19.803, 9.8 fc rgb \"#000000\"",
"set object 666 rect from 19.8815, 10.2 to 20.8815, 9.8 fc rgb \"#000000\"",
"set object 667 rect from 20.910999999999998, 10.2 to 21.910999999999998, 9.8 fc rgb \"#000000\"",
@@ -1371,7 +1371,7 @@
"set label \"1 ms\" at 14.3305828125,1 font \"Helvetica,7'\"",
"set label \"0 ms\" at 18.204082812499998,1 font \"Helvetica,7'\"",
"set label \"0 ms\" at 85.27908281249994,1 font \"Helvetica,7'\"",
- "set y2range [0:59.54259090909095]",
+ "set y2range [0:62.076318181818216]",
"plot '-' using 1:2 axes x1y2 with impulses ls 1",
"41.88650000000001 13.935500000000008",
"3.7920000000000003 1.3375000000000004",
@@ -1563,4 +1563,4 @@
"# start: 2.4204999999999997",
"# end: 141.1669999999999",
"# objects: 1547"
-]
+] \ No newline at end of file
diff --git a/deps/v8/test/mjsunit/tools/tickprocessor-test.default b/deps/v8/test/mjsunit/tools/tickprocessor-test.default
index 702f4bcae8..3e01532ac3 100644
--- a/deps/v8/test/mjsunit/tools/tickprocessor-test.default
+++ b/deps/v8/test/mjsunit/tools/tickprocessor-test.default
@@ -1,13 +1,9 @@
Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
- [Unknown]:
- ticks total nonlib name
- 2 15.4%
-
[Shared libraries]:
ticks total nonlib name
- 3 23.1% 0.0% /lib32/libm-2.7.so
- 1 7.7% 0.0% ffffe000-fffff000
+ 3 23.1% /lib32/libm-2.7.so
+ 1 7.7% ffffe000-fffff000
[JavaScript]:
ticks total nonlib name
@@ -16,13 +12,17 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
[C++]:
ticks total nonlib name
2 15.4% 22.2% v8::internal::Runtime_Math_exp(v8::internal::Arguments)
- 1 7.7% 11.1% v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
+ 1 7.7% 11.1% v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
1 7.7% 11.1% v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)
1 7.7% 11.1% exp
- [GC]:
+ [Summary]:
ticks total nonlib name
- 0 0.0%
+ 1 7.7% 11.1% JavaScript
+ 5 38.5% 55.6% C++
+ 0 0.0% 0.0% GC
+ 4 30.8% Shared libraries
+ 2 15.4% Unaccounted
[Bottom up (heavy) profile]:
Note: percentage shows a share of a particular caller in the total
@@ -38,7 +38,7 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
2 100.0% LazyCompile: exp native math.js:41
2 100.0% Script: exp.js
- 1 7.7% v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
+ 1 7.7% v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
1 100.0% Script: exp.js
1 7.7% v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)
diff --git a/deps/v8/test/mjsunit/tools/tickprocessor-test.func-info b/deps/v8/test/mjsunit/tools/tickprocessor-test.func-info
index a66b90f4c5..c93b6ec701 100644
--- a/deps/v8/test/mjsunit/tools/tickprocessor-test.func-info
+++ b/deps/v8/test/mjsunit/tools/tickprocessor-test.func-info
@@ -11,9 +11,12 @@ Statistical profiling result from v8.log, (3 ticks, 0 unaccounted, 0 excluded).
[C++]:
ticks total nonlib name
- [GC]:
+ [Summary]:
ticks total nonlib name
- 0 0.0%
+ 3 100.0% 100.0% JavaScript
+ 0 0.0% 0.0% C++
+ 0 0.0% 0.0% GC
+ 0 0.0% Shared libraries
[Bottom up (heavy) profile]:
Note: percentage shows a share of a particular caller in the total
diff --git a/deps/v8/test/mjsunit/tools/tickprocessor-test.gc-state b/deps/v8/test/mjsunit/tools/tickprocessor-test.gc-state
index 40f90db4f7..6b1a6a3b30 100644
--- a/deps/v8/test/mjsunit/tools/tickprocessor-test.gc-state
+++ b/deps/v8/test/mjsunit/tools/tickprocessor-test.gc-state
@@ -9,9 +9,12 @@ Statistical profiling result from v8.log, (13 ticks, 0 unaccounted, 13 excluded)
[C++]:
ticks total nonlib name
- [GC]:
+ [Summary]:
ticks total nonlib name
- 0 0.0%
+ 0 0.0% 0.0% JavaScript
+ 0 0.0% 0.0% C++
+ 0 0.0% 0.0% GC
+ 0 0.0% Shared libraries
[Bottom up (heavy) profile]:
Note: percentage shows a share of a particular caller in the total
diff --git a/deps/v8/test/mjsunit/tools/tickprocessor-test.ignore-unknown b/deps/v8/test/mjsunit/tools/tickprocessor-test.ignore-unknown
index 306d646c1a..de70527f9d 100644
--- a/deps/v8/test/mjsunit/tools/tickprocessor-test.ignore-unknown
+++ b/deps/v8/test/mjsunit/tools/tickprocessor-test.ignore-unknown
@@ -2,8 +2,8 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
[Shared libraries]:
ticks total nonlib name
- 3 27.3% 0.0% /lib32/libm-2.7.so
- 1 9.1% 0.0% ffffe000-fffff000
+ 3 27.3% /lib32/libm-2.7.so
+ 1 9.1% ffffe000-fffff000
[JavaScript]:
ticks total nonlib name
@@ -12,13 +12,16 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
[C++]:
ticks total nonlib name
2 18.2% 28.6% v8::internal::Runtime_Math_exp(v8::internal::Arguments)
- 1 9.1% 14.3% v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
+ 1 9.1% 14.3% v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
1 9.1% 14.3% v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)
1 9.1% 14.3% exp
- [GC]:
+ [Summary]:
ticks total nonlib name
- 0 0.0%
+ 1 9.1% 14.3% JavaScript
+ 5 45.5% 71.4% C++
+ 0 0.0% 0.0% GC
+ 4 36.4% Shared libraries
[Bottom up (heavy) profile]:
Note: percentage shows a share of a particular caller in the total
@@ -34,7 +37,7 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
2 100.0% LazyCompile: exp native math.js:41
2 100.0% Script: exp.js
- 1 9.1% v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
+ 1 9.1% v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
1 100.0% Script: exp.js
1 9.1% v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)
diff --git a/deps/v8/test/mjsunit/tools/tickprocessor-test.separate-ic b/deps/v8/test/mjsunit/tools/tickprocessor-test.separate-ic
index 3a2041b52f..119ccbe712 100644
--- a/deps/v8/test/mjsunit/tools/tickprocessor-test.separate-ic
+++ b/deps/v8/test/mjsunit/tools/tickprocessor-test.separate-ic
@@ -1,13 +1,9 @@
Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
- [Unknown]:
- ticks total nonlib name
- 2 15.4%
-
[Shared libraries]:
ticks total nonlib name
- 3 23.1% 0.0% /lib32/libm-2.7.so
- 1 7.7% 0.0% ffffe000-fffff000
+ 3 23.1% /lib32/libm-2.7.so
+ 1 7.7% ffffe000-fffff000
[JavaScript]:
ticks total nonlib name
@@ -18,13 +14,17 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
[C++]:
ticks total nonlib name
2 15.4% 22.2% v8::internal::Runtime_Math_exp(v8::internal::Arguments)
- 1 7.7% 11.1% v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
+ 1 7.7% 11.1% v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
1 7.7% 11.1% v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)
1 7.7% 11.1% exp
- [GC]:
+ [Summary]:
ticks total nonlib name
- 0 0.0%
+ 3 23.1% 33.3% JavaScript
+ 5 38.5% 55.6% C++
+ 0 0.0% 0.0% GC
+ 4 30.8% Shared libraries
+ 2 15.4% Unaccounted
[Bottom up (heavy) profile]:
Note: percentage shows a share of a particular caller in the total
@@ -40,7 +40,7 @@ Statistical profiling result from v8.log, (13 ticks, 2 unaccounted, 0 excluded).
2 100.0% LazyCompile: exp native math.js:41
2 100.0% Script: exp.js
- 1 7.7% v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
+ 1 7.7% v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)
1 100.0% Script: exp.js
1 7.7% v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)
diff --git a/deps/v8/test/mjsunit/tools/tickprocessor.js b/deps/v8/test/mjsunit/tools/tickprocessor.js
index 626929de16..f460d349bb 100644
--- a/deps/v8/test/mjsunit/tools/tickprocessor.js
+++ b/deps/v8/test/mjsunit/tools/tickprocessor.js
@@ -25,10 +25,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// This test case is not compatible with optimization stress because the
-// generated profile will look vastly different when more is optimized.
-// Flags: --nostress-opt --noalways-opt
-
// Load implementations from <project root>/tools.
// Files: tools/splaytree.js tools/codemap.js tools/csvparser.js
// Files: tools/consarray.js tools/profile.js tools/profile_view.js
@@ -311,7 +307,7 @@ CppEntriesProviderMock.prototype.parseVmSymbols = function(
name, startAddr, endAddr, symbolAdder) {
var symbols = {
'shell':
- [['v8::internal::JSObject::LocalLookupRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)', 0x080f8800, 0x080f8d90],
+ [['v8::internal::JSObject::LookupOwnRealNamedProperty(v8::internal::String*, v8::internal::LookupResult*)', 0x080f8800, 0x080f8d90],
['v8::internal::HashTable<v8::internal::StringDictionaryShape, v8::internal::String*>::FindEntry(v8::internal::String*)', 0x080f8210, 0x080f8800],
['v8::internal::Runtime_Math_exp(v8::internal::Arguments)', 0x08123b20, 0x08123b80]],
'/lib32/libm-2.7.so':
diff --git a/deps/v8/test/mjsunit/value-wrapper-accessor.js b/deps/v8/test/mjsunit/value-wrapper-accessor.js
index f95145652c..79db407121 100644
--- a/deps/v8/test/mjsunit/value-wrapper-accessor.js
+++ b/deps/v8/test/mjsunit/value-wrapper-accessor.js
@@ -77,20 +77,14 @@ function test(object, prototype) {
%OptimizeFunctionOnNextCall(nonstrict);
result = undefined;
nonstrict(object);
- // TODO(1475): Support storing to primitive values.
- // This should return "object" once storing to primitive values is
- // supported.
- assertEquals("undefined", typeof result);
+ assertEquals("object", typeof result);
strict(object);
strict(object);
%OptimizeFunctionOnNextCall(strict);
result = undefined;
strict(object);
- // TODO(1475): Support storing to primitive values.
- // This should return "object" once storing to primitive values is
- // supported.
- assertEquals("undefined", typeof result);
+ assertEquals(object, result);
})();
}
diff --git a/deps/v8/test/mjsunit/with-readonly.js b/deps/v8/test/mjsunit/with-readonly.js
index 29982b3474..43583348e9 100644
--- a/deps/v8/test/mjsunit/with-readonly.js
+++ b/deps/v8/test/mjsunit/with-readonly.js
@@ -27,8 +27,6 @@
// Test that readonly variables are treated correctly.
-// Flags: --es5_readonly
-
// Create an object with a read-only length property in the prototype
// chain by putting the string split function in the prototype chain.
var o = {};