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

Issue 390443005: Lower bitmanip intrinsics, assuming absence of BMI/SSE4.2 for now. (Closed)

Created:
6 years, 5 months ago by jvoung (off chromium)
Modified:
6 years, 5 months ago
Reviewers:
Jim Stichnoth, wala
CC:
native-client-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Visibility:
Public.

Description

Lower bitmanip intrinsics, assuming absence of BMI/SSE4.2 for now. We'll need the fallbacks in any case. However, once we've decided on how to specify the CPU features of the user machine we can use the nicer LZCNT/TZCNT/POPCNT as well. Adds cmov, bsf, and bsr instructions. Calls a popcount helper function for machines without SSE4.2. Not handling bswap yet (which can also take i16 params). BUG= https://code.google.com/p/nativeclient/issues/detail?id=3882 R=stichnot@chromium.org, wala@chromium.org Committed: https://gerrit.chromium.org/gerrit/gitweb?p=native_client/pnacl-subzero.git;a=commit;h=e4da26f

Patch Set 1 #

Patch Set 2 : add crosstest #

Patch Set 3 : stuff #

Total comments: 21

Patch Set 4 : review part (a) #

Patch Set 5 : use Unary #

Patch Set 6 : try to merge the two #

Total comments: 6

Patch Set 7 : format #

Patch Set 8 : review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+676 lines, -72 lines) Patch
M crosstest/runtests.sh View 1 2 chunks +8 lines, -0 lines 0 comments Download
A crosstest/test_bitmanip.h View 1 2 1 chunk +24 lines, -0 lines 0 comments Download
A crosstest/test_bitmanip.cpp View 1 2 3 1 chunk +40 lines, -0 lines 0 comments Download
A crosstest/test_bitmanip.def View 1 2 1 chunk +42 lines, -0 lines 0 comments Download
A crosstest/test_bitmanip_intrin.ll View 1 2 1 chunk +46 lines, -0 lines 0 comments Download
A crosstest/test_bitmanip_main.cpp View 1 2 3 1 chunk +110 lines, -0 lines 0 comments Download
M src/IceInstX8632.h View 1 2 3 4 9 chunks +59 lines, -33 lines 0 comments Download
M src/IceInstX8632.cpp View 1 2 3 4 9 chunks +66 lines, -26 lines 0 comments Download
M src/IceTargetLoweringX8632.h View 1 2 3 4 5 6 3 chunks +14 lines, -3 lines 0 comments Download
M src/IceTargetLoweringX8632.cpp View 1 2 3 4 5 6 7 6 chunks +132 lines, -8 lines 0 comments Download
M tests_lit/llvm2ice_tests/nacl-other-intrinsics.ll View 1 2 3 3 chunks +135 lines, -2 lines 0 comments Download

Messages

Total messages: 9 (0 generated)
jvoung (off chromium)
6 years, 5 months ago (2014-07-14 21:49:19 UTC) #1
Jim Stichnoth
Initial pass, still need to look at the lit test. https://codereview.chromium.org/390443005/diff/100001/crosstest/test_bitmanip.cpp File crosstest/test_bitmanip.cpp (right): https://codereview.chromium.org/390443005/diff/100001/crosstest/test_bitmanip.cpp#newcode1 ...
6 years, 5 months ago (2014-07-14 23:20:45 UTC) #2
wala
https://codereview.chromium.org/390443005/diff/100001/crosstest/test_bitmanip.cpp File crosstest/test_bitmanip.cpp (right): https://codereview.chromium.org/390443005/diff/100001/crosstest/test_bitmanip.cpp#newcode11 crosstest/test_bitmanip.cpp:11: // cross-testing. This uses a wrapper around the GCC ...
6 years, 5 months ago (2014-07-15 00:16:32 UTC) #3
Jim Stichnoth
https://codereview.chromium.org/390443005/diff/100001/src/IceInstX8632.h File src/IceInstX8632.h (right): https://codereview.chromium.org/390443005/diff/100001/src/IceInstX8632.h#newcode557 src/IceInstX8632.h:557: class InstX8632BitScan : public InstX8632 { On 2014/07/15 00:16:31, ...
6 years, 5 months ago (2014-07-15 17:15:02 UTC) #4
jvoung (off chromium)
Thanks! https://codereview.chromium.org/390443005/diff/100001/crosstest/test_bitmanip.cpp File crosstest/test_bitmanip.cpp (right): https://codereview.chromium.org/390443005/diff/100001/crosstest/test_bitmanip.cpp#newcode1 crosstest/test_bitmanip.cpp:1: //===- subzero/crosstest/test_bitmanip.cpp - Implementation for tests --===// On ...
6 years, 5 months ago (2014-07-15 21:30:23 UTC) #5
wala
lgtm
6 years, 5 months ago (2014-07-15 21:51:14 UTC) #6
Jim Stichnoth
LGTM with a couple nits. https://codereview.chromium.org/390443005/diff/160001/src/IceTargetLoweringX8632.cpp File src/IceTargetLoweringX8632.cpp (right): https://codereview.chromium.org/390443005/diff/160001/src/IceTargetLoweringX8632.cpp#newcode2117 src/IceTargetLoweringX8632.cpp:2117: InstCall *Call = makeHelperCall(Val->getType() ...
6 years, 5 months ago (2014-07-15 22:08:10 UTC) #7
jvoung (off chromium)
https://codereview.chromium.org/390443005/diff/160001/src/IceTargetLoweringX8632.cpp File src/IceTargetLoweringX8632.cpp (right): https://codereview.chromium.org/390443005/diff/160001/src/IceTargetLoweringX8632.cpp#newcode2117 src/IceTargetLoweringX8632.cpp:2117: InstCall *Call = makeHelperCall(Val->getType() == IceType_i32 ? On 2014/07/15 ...
6 years, 5 months ago (2014-07-15 23:10:33 UTC) #8
jvoung (off chromium)
6 years, 5 months ago (2014-07-16 00:52:45 UTC) #9
Message was sent while issue was closed.
Committed patchset #8 manually as re4da26f (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698