http://codereview.chromium.org/6688062/diff/1/test/mjsunit/math-sqrt.js
File test/mjsunit/math-sqrt.js (right):

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/math-sqrt.js#newcode33
test/mjsunit/math-sqrt.js:33: // Math.pow(-0, 0.5) must be zero, but
Math.sqrt(-0) is -0.
Done.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mjsunit.js
File test/mjsunit/mjsunit.js (right):

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mjsunit.js#newcode44
test/mjsunit/mjsunit.js:44: function MJSToString(value) {
Renamed to MjsUnitToString.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mjsunit.js#newcode82
test/mjsunit/mjsunit.js:82: var start;
And it doesn't have to be.
I added the second case for message for cases where the type of actual
differs from expected, but with MjsUnitToString, it doesn't matter as
much, since it prints strings with quotes around (so we don't get two
different values that turns to the same string when showing).

I'll try to make it simpler.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mul-exhaustive.js
File test/mjsunit/mul-exhaustive.js (right):

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mul-exhaustive.js#newcode33
test/mjsunit/mul-exhaustive.js:33: // Test multiplication where both
operands are variables.
Done.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mul-exhaustive.js#newcode43
test/mjsunit/mul-exhaustive.js:43: // Test multiplication where either
or both operands are constant.
Done.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mul-exhaustive.js#newcode46
test/mjsunit/mul-exhaustive.js:46: var xs = String(x);
Done.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mul-exhaustive.js#newcode53
test/mjsunit/mul-exhaustive.js:53: function fs(a, x, y, xs, ys) {
Much better, yes.
I'm a little afraid of using eval if we want the code to be optimized.
It will cause context allocated arguments.
I'll add a wrapper for Function to make it more readable.

http://codereview.chromium.org/6688062/diff/1/test/mjsunit/mul-exhaustive.js#newcode55
test/mjsunit/mul-exhaustive.js:55: for (var i = 0; i < 1000; i++)
assertEquals(a, xcyv(y));
If anything, I should check which constant is necessary to make it
optimize with --opt-eagerly.
The problem is that this test runs rather long, so if I increase it to
10000, it does optimize more anonymous functions (using --always-opt and
--opt-eagerly), but not all of them anyway. If I go to 100000, it starts
to take several minutes. I'll use 10000 for now, but suggestions are
welcome.

http://codereview.chromium.org/6688062/

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to