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

Issue 1512023002: [turbofan] Change TruncateFloat32ToUint64 to TryTruncateFloat32ToUint64. (Closed)

Created:
5 years ago by ahaas
Modified:
5 years ago
Reviewers:
titzer, v8-arm-ports, v8-mips-ports, paul.l...
CC:
v8-ppc-ports_googlegroups.com, v8-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[turbofan] Change TruncateFloat32ToUint64 to TryTruncateFloat32ToUint64. TryTruncateFloat32ToUint64 converts a float32 to a uint64. Additionally it provides an optional second return value which indicates whether the conversion succeeded (i.e. float32 value was within uint64 range) or not. I implemented the new operator on x64, arm64, and mips64. @v8-ppc-ports, can you please take care of the ppc64 implementation of the second output? Additionally I fixed a bug on x64 and mips64 in the implementation of TryTruncateFloat64ToUint64. Cases where the input value was between -1 and 0 were handled incorrectly. R=titzer@chromium.org, v8-arm-ports@googlegroups.com, v8-mips-ports@googlegroups.com Committed: https://crrev.com/97161a29eda804ea17ba127e78ddaecee0a259a9 Cr-Commit-Position: refs/heads/master@{#32796}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Fixed an unrelated test which broke because of additional test values. #

Patch Set 3 : Adjustments to the changed codebase. #

Patch Set 4 : Added better mips64 code. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+264 lines, -76 lines) Patch
M src/compiler/arm64/code-generator-arm64.cc View 1 2 1 chunk +5 lines, -0 lines 0 comments Download
M src/compiler/arm64/instruction-selector-arm64.cc View 1 2 1 chunk +14 lines, -2 lines 0 comments Download
M src/compiler/instruction-selector.cc View 1 2 3 chunks +4 lines, -3 lines 0 comments Download
M src/compiler/machine-operator.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/compiler/machine-operator.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/compiler/mips64/code-generator-mips64.cc View 1 2 1 chunk +3 lines, -1 line 0 comments Download
M src/compiler/mips64/instruction-selector-mips64.cc View 1 2 1 chunk +13 lines, -2 lines 0 comments Download
M src/compiler/opcodes.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/compiler/ppc/instruction-selector-ppc.cc View 1 2 1 chunk +5 lines, -1 line 0 comments Download
M src/compiler/raw-machine-assembler.h View 1 2 1 chunk +6 lines, -1 line 0 comments Download
M src/compiler/typer.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/compiler/verifier.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/compiler/x64/code-generator-x64.cc View 1 2 4 chunks +31 lines, -7 lines 0 comments Download
M src/compiler/x64/instruction-selector-x64.cc View 1 2 1 chunk +12 lines, -2 lines 0 comments Download
M src/mips64/macro-assembler-mips64.h View 1 chunk +4 lines, -2 lines 0 comments Download
M src/mips64/macro-assembler-mips64.cc View 1 2 3 6 chunks +34 lines, -13 lines 0 comments Download
M test/cctest/compiler/test-representation-change.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M test/cctest/compiler/test-run-machops.cc View 1 2 2 chunks +23 lines, -1 line 0 comments Download
M test/cctest/compiler/value-helper.h View 2 chunks +104 lines, -35 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 12 (3 generated)
ahaas
5 years ago (2015-12-09 17:07:49 UTC) #1
ahaas
https://codereview.chromium.org/1512023002/diff/1/src/mips64/macro-assembler-mips64.cc File src/mips64/macro-assembler-mips64.cc (right): https://codereview.chromium.org/1512023002/diff/1/src/mips64/macro-assembler-mips64.cc#newcode1783 src/mips64/macro-assembler-mips64.cc:1783: BranchF(&fail, &fail, lt, scratch, kDoubleRegZero); @v8-mips-ports: originally I wanted ...
5 years ago (2015-12-09 17:10:01 UTC) #2
paul.l...
https://codereview.chromium.org/1512023002/diff/1/src/mips64/macro-assembler-mips64.cc File src/mips64/macro-assembler-mips64.cc (right): https://codereview.chromium.org/1512023002/diff/1/src/mips64/macro-assembler-mips64.cc#newcode1783 src/mips64/macro-assembler-mips64.cc:1783: BranchF(&fail, &fail, lt, scratch, kDoubleRegZero); On 2015/12/09 17:10:01, ahaas ...
5 years ago (2015-12-10 06:51:57 UTC) #4
balazs.kilvady
We created a MIPS64 fix, PTAL: https://codereview.chromium.org/1510493012/ or we can land it as a followup ...
5 years ago (2015-12-10 15:20:15 UTC) #5
ahaas
On 2015/12/10 at 15:20:15, balazs.kilvady wrote: > We created a MIPS64 fix, PTAL: https://codereview.chromium.org/1510493012/ or ...
5 years ago (2015-12-10 15:31:42 UTC) #6
titzer
On 2015/12/10 15:31:42, ahaas wrote: > On 2015/12/10 at 15:20:15, balazs.kilvady wrote: > > We ...
5 years ago (2015-12-11 12:43:26 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1512023002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1512023002/60001
5 years ago (2015-12-11 12:47:35 UTC) #9
commit-bot: I haz the power
Committed patchset #4 (id:60001)
5 years ago (2015-12-11 14:07:04 UTC) #10
commit-bot: I haz the power
5 years ago (2015-12-11 14:07:24 UTC) #12
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/97161a29eda804ea17ba127e78ddaecee0a259a9
Cr-Commit-Position: refs/heads/master@{#32796}

Powered by Google App Engine
This is Rietveld 408576698