You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/03/30 19:20:19 UTC

[GitHub] [arrow-datafusion] Dandandan edited a comment on pull request #2124: JIT-compille DataFusion expression with column name

Dandandan edited a comment on pull request #2124:
URL: https://github.com/apache/arrow-datafusion/pull/2124#issuecomment-1083532239


   > I'm a bit confused here. Do you mean https://github.com/jorgecarleitao/arrow2/issues/627 chaining expressions and avoid repeated array allocation through Jit?
   
   The goal in that issue is similar yes, but here I suggest using generated code instead of reusing arrays.
   
   The idea is that we can compile the entire loop.
   The compiled expression `a + b` would roughly compile to something like the following pseudo code:
   
   ```
   i = 0
   while i < length {
       *item = *a + *b;
   
       a += size_a;
       b += size_b;
       item += size_item;
   }
   ```
   
   Here item is the pointer to items in the target array and a / b  are pointing to items in arrays a and b.
   In this case we only need to allocate one target array, instead of intermediate arrays.


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org