|
[intrinsics] Kill the %_IsMinusZero intrinsic.
By now only the default %TypedArray%.prototype.sort compare function
and the JS implementation of SameValueZero were still using the odd
%_IsMinusZero intrinsic, whose semantics both included a number check
(actually HeapNumber test) plus testing if the heap number stores the
special -0 value. In both cases we already know that we deal with
number so we can reduce it to a simple number test for -0, which can
be expressed via dividing 1 by that value and checking the sign of
the result. In case of the compare function, we can be even smarter
and work with the reciprocal values in case x and y are equal to 0
(although long term we should probably rewrite the fast case for
the typed array sorting function in C++ anyway, which will be way,
way faster than our handwritten callback-style, type-feedback
polluted JS implementation).
R=yangguo@chromium.org
Committed: https://crrev.com/00f7d1f5f82139a041e6cf57294f67670169074e
Cr-Commit-Position: refs/heads/master@{#33833}
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+16 lines, -790 lines) |
Patch |
|
M |
src/compiler/js-intrinsic-lowering.h
|
View
|
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/js-intrinsic-lowering.cc
|
View
|
|
2 chunks |
+0 lines, -26 lines |
0 comments
|
Download
|
|
M |
src/compiler/typer.cc
|
View
|
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
M |
src/crankshaft/arm/lithium-arm.h
|
View
|
|
2 chunks |
+0 lines, -17 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/arm/lithium-arm.cc
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/arm/lithium-codegen-arm.cc
|
View
|
|
1 chunk |
+0 lines, -27 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/arm64/lithium-arm64.h
|
View
|
|
2 chunks |
+0 lines, -17 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/arm64/lithium-arm64.cc
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/arm64/lithium-codegen-arm64.cc
|
View
|
|
1 chunk |
+0 lines, -18 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/hydrogen.h
|
View
|
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
M |
src/crankshaft/hydrogen.cc
|
View
|
|
1 chunk |
+0 lines, -9 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/hydrogen-instructions.h
|
View
|
|
2 chunks |
+0 lines, -22 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/hydrogen-instructions.cc
|
View
|
|
2 chunks |
+0 lines, -26 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/hydrogen-range-analysis.cc
|
View
|
|
1 chunk |
+0 lines, -6 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/ia32/lithium-codegen-ia32.cc
|
View
|
|
1 chunk |
+0 lines, -28 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/ia32/lithium-ia32.h
|
View
|
|
2 chunks |
+0 lines, -17 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/ia32/lithium-ia32.cc
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/mips/lithium-codegen-mips.cc
|
View
|
|
1 chunk |
+0 lines, -26 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/mips/lithium-mips.h
|
View
|
|
2 chunks |
+0 lines, -17 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/mips/lithium-mips.cc
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/mips64/lithium-codegen-mips64.cc
|
View
|
|
1 chunk |
+0 lines, -29 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/mips64/lithium-mips64.h
|
View
|
|
2 chunks |
+0 lines, -17 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/mips64/lithium-mips64.cc
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/ppc/lithium-codegen-ppc.cc
|
View
|
|
1 chunk |
+0 lines, -21 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/ppc/lithium-ppc.h
|
View
|
|
2 chunks |
+0 lines, -17 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/ppc/lithium-ppc.cc
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/x64/lithium-codegen-x64.cc
|
View
|
|
1 chunk |
+0 lines, -27 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/x64/lithium-x64.h
|
View
|
|
2 chunks |
+0 lines, -15 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/x64/lithium-x64.cc
|
View
|
|
1 chunk |
+0 lines, -7 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/x87/lithium-codegen-x87.cc
|
View
|
|
1 chunk |
+0 lines, -23 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/x87/lithium-x87.h
|
View
|
|
2 chunks |
+0 lines, -13 lines |
0 comments
|
Download
|
|
M |
src/crankshaft/x87/lithium-x87.cc
|
View
|
|
1 chunk |
+0 lines, -7 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/arm/full-codegen-arm.cc
|
View
|
|
1 chunk |
+0 lines, -26 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/arm64/full-codegen-arm64.cc
|
View
|
|
1 chunk |
+0 lines, -27 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/full-codegen.h
|
View
|
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/ia32/full-codegen-ia32.cc
|
View
|
|
1 chunk |
+0 lines, -27 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/mips/full-codegen-mips.cc
|
View
|
|
1 chunk |
+0 lines, -30 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/mips64/full-codegen-mips64.cc
|
View
|
|
1 chunk |
+0 lines, -30 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/ppc/full-codegen-ppc.cc
|
View
|
|
1 chunk |
+0 lines, -22 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/x64/full-codegen-x64.cc
|
View
|
|
1 chunk |
+0 lines, -27 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/x87/full-codegen-x87.cc
|
View
|
|
1 chunk |
+0 lines, -27 lines |
0 comments
|
Download
|
|
M |
src/js/runtime.js
|
View
|
|
2 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
|
M |
src/js/typedarray.js
|
View
|
|
1 chunk |
+11 lines, -13 lines |
0 comments
|
Download
|
|
M |
src/ppc/macro-assembler-ppc.h
|
View
|
|
1 chunk |
+0 lines, -2 lines |
0 comments
|
Download
|
|
M |
src/ppc/macro-assembler-ppc.cc
|
View
|
|
1 chunk |
+0 lines, -19 lines |
0 comments
|
Download
|
|
M |
src/runtime/runtime.h
|
View
|
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
M |
src/runtime/runtime-maths.cc
|
View
|
|
1 chunk |
+0 lines, -10 lines |
0 comments
|
Download
|
|
M |
test/cctest/compiler/test-run-intrinsics.cc
|
View
|
|
1 chunk |
+0 lines, -12 lines |
0 comments
|
Download
|
|
M |
test/mjsunit/compiler/minus-zero.js
|
View
|
|
2 chunks |
+2 lines, -26 lines |
0 comments
|
Download
|
|
M |
test/mjsunit/constant-fold-control-instructions.js
|
View
|
|
1 chunk |
+0 lines, -4 lines |
0 comments
|
Download
|
Total messages: 8 (2 generated)
|