Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/8196 )
Change subject: IMPALA-4236: Codegen CopyRows() for select nodes ...................................................................... Patch Set 3: Code-Review+1 (4 comments) I'll give Michael Ho a chance to at least skim this and decide if we wants to take a look. http://gerrit.cloudera.org:8080/#/c/8196/3/be/src/exec/select-node.cc File be/src/exec/select-node.cc: http://gerrit.cloudera.org:8080/#/c/8196/3/be/src/exec/select-node.cc@113 PS3, Line 113: copy_rows_success I did another pass over the code and realised this doesn't really mean "success", it really means that no more rows should be added to the output batch. So I think we need to rename this. http://gerrit.cloudera.org:8080/#/c/8196/3/be/src/exec/select-node.cc@126 PS3, Line 126: if (child_eos_) { The control flow here is confusing to me. It took me a while to figure out that !copy_rows_success implies that child_row_idx_ == child_row_batch_->num_rows(). I think that's what the comment below is trying to say. Can you add a DCHECK here to clarify and enforce it, e.g. DCHECK_EQ(child_row_idx_, child_row_batch_->num_rows()); http://gerrit.cloudera.org:8080/#/c/8196/3/tests/query_test/test_codegen.py File tests/query_test/test_codegen.py: http://gerrit.cloudera.org:8080/#/c/8196/3/tests/query_test/test_codegen.py@46 PS3, Line 46: codegned missing an e http://gerrit.cloudera.org:8080/#/c/8196/3/tests/query_test/test_codegen.py@51 PS3, Line 51: assert len(exec_options) This is a matter of taste but generally we prefer being explcit about the comparison versus zero. assert len(exec_options) > 0 -- To view, visit http://gerrit.cloudera.org:8080/8196 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ie0d496d004418468e16b6f564f90f45ebbf87c1e Gerrit-Change-Number: 8196 Gerrit-PatchSet: 3 Gerrit-Owner: Bikramjeet Vig <[email protected]> Gerrit-Reviewer: Bikramjeet Vig <[email protected]> Gerrit-Reviewer: Michael Ho <[email protected]> Gerrit-Reviewer: Tim Armstrong <[email protected]> Gerrit-Comment-Date: Tue, 03 Oct 2017 23:15:02 +0000 Gerrit-HasComments: Yes
