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

Issue 2760213003: [turbofan] Slightly improve truncations for CheckBounds. (Closed)

Created:
3 years, 9 months ago by Benedikt Meurer
Modified:
3 years, 9 months ago
Reviewers:
Jarin
CC:
v8-reviews_googlegroups.com
Target Ref:
refs/heads/master
Project:
v8
Visibility:
Public.

Description

[turbofan] Slightly improve truncations for CheckBounds. For CheckBounds(index,length) we know that the length must be in Unsigned31 range. Thus there's no observable difference for index values in the range [-2^31,-1] and the range [2^31,2^32-1], both are considered out-of-bounds; also it's safe to truncate -0 to 0 wrt. CheckBounds. Thus we can safely pass Word32 truncation if the index is in Integral32 \/ MinusZero. Usually this generates the same code, but some index computations can benefit from the Word32 truncation and avoid going to double because the result would be outside the valid Signed32 or Unsigned32 ranges. R=jarin@chromium.org BUG=v8:5267 Review-Url: https://codereview.chromium.org/2760213003 Cr-Commit-Position: refs/heads/master@{#43969} Committed: https://chromium.googlesource.com/v8/v8/+/17d932c06b40d1e6617ebbd6cc8d1e8f411f9750

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -6 lines) Patch
M src/compiler/simplified-lowering.cc View 1 chunk +11 lines, -5 lines 0 comments Download
M src/compiler/types.h View 1 chunk +2 lines, -1 line 0 comments Download

Dependent Patchsets:

Messages

Total messages: 11 (7 generated)
Benedikt Meurer
3 years, 9 months ago (2017-03-21 06:40:55 UTC) #1
Jarin
lgtm
3 years, 9 months ago (2017-03-21 08:48:29 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2760213003/1
3 years, 9 months ago (2017-03-21 10:10:34 UTC) #8
commit-bot: I haz the power
3 years, 9 months ago (2017-03-21 10:11:57 UTC) #11
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://chromium.googlesource.com/v8/v8/+/17d932c06b40d1e6617ebbd6cc8d1e8f411...

Powered by Google App Engine
This is Rietveld 408576698