Michael Ho has posted comments on this change. Change subject: IMPALA-3629: Codegen TransferScratchTuples() in hdfs-parquet-scanner ......................................................................
Patch Set 3: (4 comments) http://gerrit.cloudera.org:8080/#/c/3774/3/be/src/exec/hdfs-parquet-scanner-ir.cc File be/src/exec/hdfs-parquet-scanner-ir.cc: PS3, Line 44: if (tuple_size == 0) { Given that if (tuple_size == 0) { ...} is handling an entire scratch patch in one shot, it seems that we won't be benefiting a lot from it by eliminating the if statement. The gain we get may be offset by the codegen time to optimize/compile this function at runtime. I would suggest cross-compiling the while loop below only. PS3, Line 61: while (scratch_tuple != scratch_tuple_end) { Can we factor the while loop (or the loop body only) out as a separate function and cross-compile it only ? http://gerrit.cloudera.org:8080/#/c/3774/3/be/src/exec/hdfs-parquet-scanner.cc File be/src/exec/hdfs-parquet-scanner.cc: PS3, Line 388: if (!node->runtime_state()->GetCodegen(&codegen).ok()) { : return Status("Failed to get codegen"); : } RETURN_IF_ERROR(node->runtime_state()->GetCodegen(&codegen)); PS3, Line 408: llvm::ConstantInt::get( : llvm::Type::getInt32Ty(codegen->context()), tuple_byte_size) codegen->GetIntConstant(sizeof(tuple_byte_size), tuple_byte_size) ? -- To view, visit http://gerrit.cloudera.org:8080/3774 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ic327e437c7cd2b3f92cdb11c1e907bfee2d44ee8 Gerrit-PatchSet: 3 Gerrit-Project: Impala Gerrit-Branch: cdh5-trunk Gerrit-Owner: Thomas Tauber-Marshall <[email protected]> Gerrit-Reviewer: Michael Ho <[email protected]> Gerrit-Reviewer: Thomas Tauber-Marshall <[email protected]> Gerrit-Reviewer: Tim Armstrong <[email protected]> Gerrit-HasComments: Yes
