Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(104)

Issue 7604028: Fix three bugs with handling negative zero in the optimizing compiler. (Closed)

Created:
9 years, 4 months ago by fschneider
Modified:
9 years, 4 months ago
CC:
v8-dev
Visibility:
Public.

Description

Fix three bugs with handling negative zero in the optimizing compiler. * Bug fix for range analysis (contributed by Andy Wingo). Ranges of double values have to include negative zero. Original code review: http://codereview.chromium.org/7514040/ * Fix a bug in optimized Math.round on ARM. When emitting minus-zero checks we previously return a wrong result because of incorrect register assignment. * Fix performance problem in IA32 and x64. Refine the checks for minus zero and avoid unnecessary deoptimizations on Math.floor. * Improve mjsunit test for Math.round to make sure we also get the optimized version of the code for each test case. Committed: http://code.google.com/p/v8/source/detail?r=8877

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : added missing line to mjsunit test #

Total comments: 4

Patch Set 4 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+90 lines, -38 lines) Patch
M src/arm/lithium-codegen-arm.cc View 1 2 3 4 chunks +13 lines, -14 lines 0 comments Download
M src/hydrogen-instructions.cc View 1 chunk +4 lines, -13 lines 0 comments Download
M src/ia32/lithium-codegen-ia32.cc View 2 chunks +14 lines, -3 lines 0 comments Download
M src/x64/lithium-codegen-x64.cc View 2 chunks +11 lines, -4 lines 0 comments Download
M test/mjsunit/math-floor.js View 2 chunks +27 lines, -0 lines 0 comments Download
M test/mjsunit/math-round.js View 1 2 3 chunks +21 lines, -4 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
fschneider
9 years, 4 months ago (2011-08-10 09:31:08 UTC) #1
Kevin Millikin (Chromium)
LGTM. http://codereview.chromium.org/7604028/diff/6002/src/arm/lithium-codegen-arm.cc File src/arm/lithium-codegen-arm.cc (right): http://codereview.chromium.org/7604028/diff/6002/src/arm/lithium-codegen-arm.cc#newcode3017 src/arm/lithium-codegen-arm.cc:3017: Register scratch2 = scratch0(); It doesn't really make ...
9 years, 4 months ago (2011-08-10 12:03:51 UTC) #2
fschneider
9 years, 4 months ago (2011-08-10 12:33:16 UTC) #3
http://codereview.chromium.org/7604028/diff/6002/src/arm/lithium-codegen-arm.cc
File src/arm/lithium-codegen-arm.cc (right):

http://codereview.chromium.org/7604028/diff/6002/src/arm/lithium-codegen-arm....
src/arm/lithium-codegen-arm.cc:3017: Register scratch2 = scratch0();
On 2011/08/10 12:03:53, Kevin Millikin wrote:
> It doesn't really make sense to have scratch2 when there is no scratch1 (and
> have it be an alias for scratch0!).  Maybe call it scratch?

Done.

http://codereview.chromium.org/7604028/diff/6002/src/ia32/lithium-codegen-ia3...
File src/ia32/lithium-codegen-ia32.cc (right):

http://codereview.chromium.org/7604028/diff/6002/src/ia32/lithium-codegen-ia3...
src/ia32/lithium-codegen-ia32.cc:2770: __ movmskpd(output_reg, input_reg);
On 2011/08/10 12:03:53, Kevin Millikin wrote:
> Gesundheit.

Danke!

Powered by Google App Engine
This is Rietveld 408576698