alamb opened a new pull request #1047:
URL: https://github.com/apache/arrow-datafusion/pull/1047


   # Which issue does this PR close?
   Closes https://github.com/apache/arrow-datafusion/issues/419
   
    # Rationale for this change
   Prior to this PR, trying to evaluate `BinaryExprs` more than a few level 
deep (e.g. something like `a + a + a + a + a + a + a + a ...`) would result in 
a stack overflow
   
   For example the test included  fails like this with `tree_depth` of 10 (in 
debug builds)
   
   ```
   thread 'physical_plan::expressions::binary::tests::relatively_deeply_nested' 
has overflowed its stack
   fatal runtime error: stack overflow
   error: test failed, to rerun pass '-p datafusion --lib'
   
   Caused by:
     process didn't exit successfully: 
`/Users/alamb/Software/arrow-datafusion/target/debug/deps/datafusion-68280be86fef135e
 deeply` (signal: 6, SIGABRT: process abort signal)
   ```
   
   # What changes are included in this PR?
   1. Break the `BinaryExpr::evaluate` into a few smaller functions
   2. Remove special case workaround added for #910 
   
   # Are there any user-facing changes?
   Not really other than avoiding stack overflows while evaluating queries in 
debug builds
   
   # Technical Backstory


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


Reply via email to