Andrew Wong has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/13721 )
Change subject: KUDU-2847: Optimize iteration over selection vector in SerializeRowBlock ...................................................................... KUDU-2847: Optimize iteration over selection vector in SerializeRowBlock This improves the performance of serializing RowBlocks to the wire by amortizing the cost of iterating over the set bits of the selection bitmap. Instead of using the bitmap once per column, we convert the bitmap to a list of set indices up front, and then use those indices for conversion. This changes the benchmarks to report cycles/cell instead of raw times, making it easier to see the effects of column count or sparsity. Benchmark results: column count 3 and row select rate 1: 5.12520529 -> 5.44280228 cycles/cell column count 3 and row select rate 0.8: 12.74473127 -> 7.04588262 cycles/cell column count 3 and row select rate 0.5: 23.98607461 -> 7.51201477 cycles/cell column count 3 and row select rate 0.2: 40.66053179 -> 8.30233998 cycles/cell column count 30 and row select rate 1: 15.43040511 -> 15.97765642 cycles/cell column count 30 and row select rate 0.8: 23.7480557 -> 17.84433817 cycles/cell column count 30 and row select rate 0.5: 40.08323337 -> 17.67888749 cycles/cell column count 30 and row select rate 0.2: 48.62210244 -> 16.56884988 cycles/cell column count 300 and row select rate 1: 18.9223316 -> 20.90426976 cycles/cell column count 300 and row select rate 0.8: 27.50793008 -> 21.92481189 cycles/cell column count 300 and row select rate 0.5: 40.34367716 -> 21.32180024 cycles/cell column count 300 and row select rate 0.2: 52.7446843 -> 20.92634437 cycles/cell Patch co-authored by Zhang Yao. Change-Id: I19917d1875c46fd4cf98ef8a471b0340a76161e7 Reviewed-on: http://gerrit.cloudera.org:8080/13721 Tested-by: Kudu Jenkins Reviewed-by: Andrew Wong <[email protected]> --- M src/kudu/common/rowblock-test.cc M src/kudu/common/rowblock.cc M src/kudu/common/rowblock.h M src/kudu/common/wire_protocol-test.cc M src/kudu/common/wire_protocol.cc 5 files changed, 107 insertions(+), 53 deletions(-) Approvals: Kudu Jenkins: Verified Andrew Wong: Looks good to me, approved -- To view, visit http://gerrit.cloudera.org:8080/13721 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: I19917d1875c46fd4cf98ef8a471b0340a76161e7 Gerrit-Change-Number: 13721 Gerrit-PatchSet: 10 Gerrit-Owner: ZhangYao <[email protected]> Gerrit-Reviewer: Andrew Wong <[email protected]> Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Reviewer: Tidy Bot (241) Gerrit-Reviewer: Todd Lipcon <[email protected]> Gerrit-Reviewer: Yao Xu <[email protected]> Gerrit-Reviewer: ZhangYao <[email protected]>
