peter-toth commented on issue #9375:
URL: https://github.com/apache/datafusion/issues/9375#issuecomment-2470000115

   This is the stacktrace with a release build. Looks like we forgot to 
annotate `get_type` with recursive.
   The last annotated method is `TreeNode::rewrite` in frame #179 so the last 
check for >128KB stack remained was there. But then each `get_type` eats up 704 
bytes...
   ```
   (lldb) thread backtrace
   * thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = 
EXC_BAD_ACCESS (code=2, address=0x1064ffe40)
     * frame #0: sp=0x00000001064ffea0 fp=0x0000000106500150 
pc=0x0000000101d1d4cc 
datafusion-cli`_$LT$datafusion_expr..expr..Expr$u20$as$u20$datafusion_expr..expr_schema..ExprSchemable$GT$::get_type::hd93d0d7d195d9517
       frame #1: sp=0x00000001064ffea0 fp=0x0000000106500150 
pc=0x0000000101d1d810 
datafusion-cli`_$LT$datafusion_expr..expr..Expr$u20$as$u20$datafusion_expr..expr_schema..ExprSchemable$GT$::get_type::hd93d0d7d195d9517
 + 836
       frame #2: sp=0x0000000106500160 fp=0x0000000106500410 
pc=0x0000000101d1d810 
datafusion-cli`_$LT$datafusion_expr..expr..Expr$u20$as$u20$datafusion_expr..expr_schema..ExprSchemable$GT$::get_type::hd93d0d7d195d9517
 + 836
   
   ...
   
       frame #175: sp=0x000000010651dd20 fp=0x000000010651dfd0 
pc=0x0000000101d1d810 
datafusion-cli`_$LT$datafusion_expr..expr..Expr$u20$as$u20$datafusion_expr..expr_schema..ExprSchemable$GT$::get_type::hd93d0d7d195d9517
 + 836
       frame #176: sp=0x000000010651dfe0 fp=0x000000010651e290 
pc=0x0000000101d1d810 
datafusion-cli`_$LT$datafusion_expr..expr..Expr$u20$as$u20$datafusion_expr..expr_schema..ExprSchemable$GT$::get_type::hd93d0d7d195d9517
 + 836
       frame #177: sp=0x000000010651e2a0 fp=0x000000010651e790 
pc=0x00000001013fe568 
datafusion-cli`datafusion_optimizer::analyzer::type_coercion::TypeCoercionRewriter::coerce_binary_op::ha0b41d96e2a388be
 + 80
       frame #178: sp=0x000000010651e7a0 fp=0x0000000106520780 
pc=0x00000001013ff8a0 
datafusion-cli`_$LT$datafusion_optimizer..analyzer..type_coercion..TypeCoercionRewriter$u20$as$u20$datafusion_common..tree_node..TreeNodeRewriter$GT$::f_up::hf15debdf22e96478
 + 3704
       frame #179: sp=0x0000000106520790 fp=0x0000000106520ce0 
pc=0x00000001010ed6a0 
datafusion-cli`datafusion_common::tree_node::TreeNode::rewrite::h5b31f9ce53898b08
 + 864
       frame #180: sp=0x0000000106520cf0 fp=0x0000000106520fd0 
pc=0x00000001013ebc60 
datafusion-cli`datafusion_expr::tree_node::transform_box::h94edc72df1434b7e + 68
       frame #181: sp=0x0000000106520fe0 fp=0x0000000106521920 
pc=0x00000001010c8390 
datafusion-cli`datafusion_expr::tree_node::_$LT$impl$u20$datafusion_common..tree_node..TreeNode$u20$for$u20$datafusion_expr..expr..Expr$GT$::map_children::hc6cf396dc1ddffb4
 + 732
       frame #182: sp=0x0000000106521930 fp=0x0000000106521e80 
pc=0x00000001010ed498 
datafusion-cli`datafusion_common::tree_node::TreeNode::rewrite::h5b31f9ce53898b08
 + 344
       frame #183: sp=0x0000000106521e90 fp=0x0000000106522170 
pc=0x00000001013ebc60 
datafusion-cli`datafusion_expr::tree_node::transform_box::h94edc72df1434b7e + 68
       frame #184: sp=0x0000000106522180 fp=0x0000000106522ac0 
pc=0x00000001010c8390 
datafusion-cli`datafusion_expr::tree_node::_$LT$impl$u20$datafusion_common..tree_node..TreeNode$u20$for$u20$datafusion_expr..expr..Expr$GT$::map_children::hc6cf396dc1ddffb4
 + 732
       frame #185: sp=0x0000000106522ad0 fp=0x0000000106523020 
pc=0x00000001010ed498 
datafusion-cli`datafusion_common::tree_node::TreeNode::rewrite::h5b31f9ce53898b08
 + 344
       frame #186: sp=0x0000000106523030 fp=0x0000000106523310 
pc=0x00000001013ebc60 
datafusion-cli`datafusion_expr::tree_node::transform_box::h94edc72df1434b7e + 68
   ```


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