Jim Apple has posted comments on this change. Change subject: IMPALA-4433: Fix undefined NDV calculations ......................................................................
Patch Set 2: (4 comments) http://gerrit.cloudera.org:8080/#/c/5004/1//COMMIT_MSG Commit Message: Line 10: argument is 0. This patch handles that 0 case, which can depend on the > Might be good to mention that varies depending on the architecture. Done http://gerrit.cloudera.org:8080/#/c/5004/1/be/src/exprs/aggregate-functions-ir.cc File be/src/exprs/aggregate-functions-ir.cc: Line 1175: // Use the lower bits to index into the number of streams and then find the first 1 bit > Same comment as the other place - I think we can remove this branch. Done http://gerrit.cloudera.org:8080/#/c/5004/1/be/src/udf_samples/hyperloglog-uda.cc File be/src/udf_samples/hyperloglog-uda.cc: Line 75: // Use the lower bits to index into the number of streams and then find the first 1 bit > Let's remove this branch while we're at it. It doesn't make sense to me why Done PS1, Line 81: (sizeof(hash_value) * CHAR_BIT - HLL_PRECISION)); : dst->ptr[idx] = ::max(dst->ptr[idx], first_one_bit); > Can't we use the builtin you It's in Impala proper, while it seems like the non-test files in this directory carefully avoid using anything from Impala proper. -- To view, visit http://gerrit.cloudera.org:8080/5004 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I8460bc3f7e510ce07b8673387c9440accc432abe Gerrit-PatchSet: 2 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Jim Apple <[email protected]> Gerrit-Reviewer: Amos Bird <[email protected]> Gerrit-Reviewer: Jim Apple <[email protected]> Gerrit-Reviewer: Tim Armstrong <[email protected]> Gerrit-HasComments: Yes
