Todd Lipcon has posted comments on this change. ( http://gerrit.cloudera.org:8080/14745 )
Change subject: Import Impala's blocked based BloomFilter ...................................................................... Patch Set 5: (7 comments) http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc File src/kudu/util/block_bloom_filter.cc: http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@33 PS5, Line 33: DEFINE_bool(disable_blockbloomfilter_avx2, false, should this be marked hidden or experimental? http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@52 PS5, Line 52: "Close() should have been called before the object is destroyed."; a bit of a strange API, but I guess we are borrowing this from Impala http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@64 PS5, Line 64: DCHECK(log_num_buckets_ <= 32) << "Bloom filter too large. log_space_bytes: " should this be either a CHECK or a return of InvalidArgument? seems like a DCHECK could result in continuing on with incorrect results or out-of-bounds access etc http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@138 PS5, Line 138: ATTRIBUTE_NO_SANITIZE_INTEGER why do we not want to sanitize this and the above? it seems like overflow would be a bug? http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@178 PS5, Line 178: if (has_avx2()) { do all of our supported compiler toolchains support function multiversioning? https://lwn.net/Articles/691932/ Perhaps this is a slightly more performant way of doing this vs branching, though could be added in a TODO. http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@187 PS5, Line 187: int ret_code = posix_memalign(ptr, 64, bytes); > Why is this alignment required? I'll take my answer in the form of a code c I think we have a constant somewhere (maybe port.h) for CACHELINE_SIZE or something which we could use in place of 64 http://gerrit.cloudera.org:8080/#/c/14745/5/src/kudu/util/block_bloom_filter.cc@192 PS5, Line 192: DCHECK(ptr != nullptr); > DCHECK_NE(ptr, nullptr) is preferred (clearer log message on a crash). or free(DCHECK_NOTNULL(ptr)) -- To view, visit http://gerrit.cloudera.org:8080/14745 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I89c54a051c5093cf5fb81481a47a0a6677d7d906 Gerrit-Change-Number: 14745 Gerrit-PatchSet: 5 Gerrit-Owner: Bankim Bhavsar <[email protected]> Gerrit-Reviewer: Adar Dembo <[email protected]> Gerrit-Reviewer: Alexey Serbin <[email protected]> Gerrit-Reviewer: Andrew Wong <[email protected]> Gerrit-Reviewer: Bankim Bhavsar <[email protected]> Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Reviewer: Thomas Tauber-Marshall <[email protected]> Gerrit-Reviewer: Tidy Bot (241) Gerrit-Reviewer: Tim Armstrong <[email protected]> Gerrit-Reviewer: Todd Lipcon <[email protected]> Gerrit-Comment-Date: Wed, 27 Nov 2019 23:00:01 +0000 Gerrit-HasComments: Yes
