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

Issue 11478043: Improve integer division on IA32 and X64 (Closed)

Created:
8 years ago by yuqiang.xian%intel.com
Modified:
8 years ago
Reviewers:
Yang
CC:
v8-dev
Visibility:
Public.

Description

Improve integer division on IA32 and X64 If the divisor is a Power-of-2 constant, we could use shifts instead of the expensive idiv instructions, which also loose the register constraints. Committed: https://code.google.com/p/v8/source/detail?r=13178

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+100 lines, -2 lines) Patch
M src/hydrogen-instructions.h View 1 chunk +10 lines, -0 lines 0 comments Download
M src/ia32/lithium-codegen-ia32.cc View 2 chunks +38 lines, -1 line 1 comment Download
M src/ia32/lithium-ia32.cc View 1 chunk +7 lines, -0 lines 0 comments Download
M src/x64/lithium-codegen-x64.cc View 2 chunks +38 lines, -1 line 1 comment Download
M src/x64/lithium-x64.cc View 1 chunk +7 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
yuqiang.xian%intel.com
8 years ago (2012-12-10 07:33:16 UTC) #1
Yang
LGTM if comments are addressed. https://codereview.chromium.org/11478043/diff/1/src/ia32/lithium-codegen-ia32.cc File src/ia32/lithium-codegen-ia32.cc (right): https://codereview.chromium.org/11478043/diff/1/src/ia32/lithium-codegen-ia32.cc#newcode1229 src/ia32/lithium-codegen-ia32.cc:1229: if (test_value != 0) ...
8 years ago (2012-12-10 09:47:28 UTC) #2
yuqiang.xian%intel.com
Yang, thanks for the review. But I think the "test_value != 0" test does exclude ...
8 years ago (2012-12-10 10:26:01 UTC) #3
Yang
8 years ago (2012-12-10 10:27:28 UTC) #4
On 2012/12/10 10:26:01, yuqiang.xian%intel.com wrote:
> Yang, thanks for the review. But I think the "test_value != 0" test does
exclude
> the cases where the divisor is -1 or 1, doesn't it?

Ah. My mistake. I'll land it then.

Powered by Google App Engine
This is Rietveld 408576698