Youwei Wang has posted comments on this change. Change subject: IMPALA-2809: Improve ByteSwap with builtin function or SSSE3 or AVX2. ......................................................................
Patch Set 38: (12 comments) http://gerrit.cloudera.org:8080/#/c/3081/38/be/src/util/bit-util-test.cc File be/src/util/bit-util-test.cc: Line 99: void TestByteswapSimdUnit(const int64_t CpuFlag) { > name formatting Done Line 192: if (LIKELY(CpuInfo::IsSupported(CpuInfo::SSSE3))) { > remove likely, this is not performance-critical Done Line 203: TestByteswapSimdUnit(CpuInfo::SSSE3); > we already did this above Done Line 211: for (int i = 0; i <= 32; ++i) { > single line Done http://gerrit.cloudera.org:8080/#/c/3081/38/be/src/util/bit-util.cc File be/src/util/bit-util.cc: Line 19: // ByteSwapScalarLoop is only used in bit-util.cc, so put it in this anonymous > make it static instead? or get remove the extra level of indentation. Done Line 25: for (int i = 0; i < len; ++i) { > single line Done Line 135: // This constant is concluded from the definition of _mm_set_epi8; > included? Hi Marcel. Since this constant is figured out by the definition of _mm_set_epi8, so I guess using the word "conclude" here may be a proper choice. Thank you. Line 144: _mm_loadu_si128(reinterpret_cast<const __m128i*>(src)), mask128i)); > indent 4 spaces (and elsewhere) Done Line 149: inline void SimdByteSwap::ByteSwapAVX2_Unit(uint8_t* dst, const uint8_t* src) { > should this be called ByteSwap256 or something like that? i had no idea wha Done http://gerrit.cloudera.org:8080/#/c/3081/38/be/src/util/bit-util.h File be/src/util/bit-util.h: Line 244: // Declaration for the namespace of SIMD byteswap utilities > we don't use that elsewhere. make it a class with static functions instead. Done Line 246: // Extra type declarations > i don't understand this comment Done Line 249: // Declaration for scalar utility functions > don't prefix the comment for a declaration with 'Declaration for'. also, th Done -- To view, visit http://gerrit.cloudera.org:8080/3081 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I392ed5a8d5683f30f161282c228c1aedd7b648c1 Gerrit-PatchSet: 38 Gerrit-Project: Impala Gerrit-Branch: cdh5-trunk Gerrit-Owner: Youwei Wang <[email protected]> Gerrit-Reviewer: Alex Behm <[email protected]> Gerrit-Reviewer: Jim Apple <[email protected]> Gerrit-Reviewer: Marcel Kornacker <[email protected]> Gerrit-Reviewer: Mostafa Mokhtar <[email protected]> Gerrit-Reviewer: Tim Armstrong <[email protected]> Gerrit-Reviewer: Youwei Wang <[email protected]> Gerrit-HasComments: Yes
