Qifan Chen has posted comments on this change. ( http://gerrit.cloudera.org:8080/17894 )
Change subject: IMPALA-10950: Update expr-benchmark.cc ...................................................................... Patch Set 4: (8 comments) Looks good to me. Just have some minor comments. http://gerrit.cloudera.org:8080/#/c/17894/4//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/17894/4//COMMIT_MSG@19 PS4, Line 19: be nit. remove? http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc File be/src/benchmarks/expr-benchmark.cc: http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@51 PS4, Line 51: struct TestData { May need to add some description on this struct. TestData may be named as ExprTestData to make it clear. http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@52 PS4, Line 52: RuntimeState* state; : FragmentState* fragment_state; : ScalarExpr* expr; : ScalarExprEvaluator* eval; Should define a constructor to init these data members. http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@81 PS4, Line 81: // Assumes this is a constant query. nit. May add comment: *test_data contains valid TestData in which expr is already opened. http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@84 PS4, Line 84: test_data_ I wonder if there is even a need to have this vector. http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@87 PS4, Line 87: query_ctx.client_request.stmt = query; : query_ctx.client_request.query_options = query_options_; : query_ctx.client_request.query_options.disable_codegen = !codegen_; : query_ctx.client_request.query_options.enable_expr_rewrites = false; : query_ctx.__set_session(session_state_); nit. May use TQueryCtx cstr to populate query_ctx. http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@96 PS4, Line 96: test->state Better to prepare these arguments first and then call the construct with them. The code will look better. ExprTestData test(state, fragment, expr, eval); http://gerrit.cloudera.org:8080/#/c/17894/4/be/src/benchmarks/expr-benchmark.cc@710 PS4, Line 710: 193 I wonder why the numbers in 10%ile, 50%ile and 90%ile column are larger in codegen version than the non-codegen version. -- To view, visit http://gerrit.cloudera.org:8080/17894 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I5b17434d85e32a58622bffb64a697b062a8bf43f Gerrit-Change-Number: 17894 Gerrit-PatchSet: 4 Gerrit-Owner: Riza Suminto <[email protected]> Gerrit-Reviewer: Bikramjeet Vig <[email protected]> Gerrit-Reviewer: Gabor Kaszab <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Qifan Chen <[email protected]> Gerrit-Reviewer: Riza Suminto <[email protected]> Gerrit-Comment-Date: Wed, 06 Oct 2021 18:16:30 +0000 Gerrit-HasComments: Yes
