jinchengchenghh commented on code in PR #8931:
URL: https://github.com/apache/gluten/pull/8931#discussion_r3021846275
##########
cpp/velox/substrait/SubstraitToVeloxPlan.cc:
##########
@@ -393,6 +396,43 @@ core::PlanNodePtr
SubstraitToVeloxPlanConverter::toVeloxPlan(const ::substrait::
rightNode,
getJoinOutputType(leftNode, rightNode, joinType));
+ } else if (
+ sJoin.has_advanced_extension() &&
+ SubstraitParser::configSetInOptimization(sJoin.advanced_extension(),
"isBHJ=")) {
+ std::string hashTableId = sJoin.hashtableid();
+
+ std::shared_ptr<core::OpaqueHashTable> opaqueSharedHashTable = nullptr;
+ bool joinHasNullKeys = false;
+
+ try {
+ auto hashTableBuilder =
ObjectStore::retrieve<gluten::HashTableBuilder>(getJoin(hashTableId));
+ joinHasNullKeys = hashTableBuilder->joinHasNullKeys();
+ auto originalShared = hashTableBuilder->hashTable();
+ opaqueSharedHashTable = std::shared_ptr<core::OpaqueHashTable>(
+ originalShared,
reinterpret_cast<core::OpaqueHashTable*>(originalShared.get()));
+
+ LOG(INFO) << "Successfully retrieved and aliased HashTable for reuse.
ID: " << hashTableId;
+ } catch (const std::exception& e) {
+ LOG(WARNING)
Review Comment:
I meet this exception, is not normal or should throw exception? If normal,
can we have other way to handle the logic instead of catch exception?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]