yikf commented on PR #8116:
URL: 
https://github.com/apache/incubator-gluten/pull/8116#issuecomment-2513672757

   > Do you have a specific query example?
   
   TPC-DS Q5 is a reuse-exchange example, see: 
https://github.com/apache/incubator-gluten/issues/7807
   
   After reuse, ColumnarSubqueryBroadcastExec's buildKeys and exchange's 
buildKeys may not be the same reference, and in our internal case, even the 
names referenced by alias are different because of alias. 
   
   In Spark, the transform of relation is [always carried out in 
BroadcastExchangeExec](https://github.com/apache/spark/blob/master/sql/core/src/main/scala/org/apache/spark/sql/execution/exchange/BroadcastExchangeExec.scala#L193),
 so this problem does not exist. we can save the buildKeys of 
BroadcastExchangeExec. this way, in the subsequent transform, we can do the 
relation transform like spark would have done in BroadcastExchangeExec, in 
which case the references are always the same, and then we can take the desired 
index value from the buildKeys output.


-- 
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]

Reply via email to