mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Revert MDEV-14517 Cleanup for Item::with_subselect
Added back variable 'with_subquery' to Item class as a bit field. This made the code shorter, faster (removed some virtual methods, less code to create an initialized item etc) and made many Item's 7 bytes smaller. This is the last set of my patches the decreases the size of Item. Some examples from gdb: sizeof(Item): 144 -> 120 sizeof(Item_func) 208 -> 184 sizeof(Item_sum_max) 368 -> 344
This commit is contained in:
committed by
Sergei Golubchik
parent
ae39f4f6d6
commit
189d03dac5
@ -2015,10 +2015,10 @@ JOIN::optimize_inner()
|
||||
if (optimize_constant_subqueries())
|
||||
DBUG_RETURN(1);
|
||||
|
||||
if (conds && conds->with_subquery())
|
||||
if (conds && conds->has_subquery())
|
||||
(void) conds->walk(&Item::cleanup_is_expensive_cache_processor,
|
||||
0, (void *) 0);
|
||||
if (having && having->with_subquery())
|
||||
if (having && having->has_subquery())
|
||||
(void) having->walk(&Item::cleanup_is_expensive_cache_processor,
|
||||
0, (void *) 0);
|
||||
|
||||
@ -13833,7 +13833,7 @@ bool JOIN_TAB::pfs_batch_update(JOIN *join)
|
||||
|
||||
return join->join_tab + join->table_count - 1 == this && // 1
|
||||
type != JT_EQ_REF && type != JT_CONST && type != JT_SYSTEM && // 2
|
||||
(!select_cond || !select_cond->with_subquery()); // 3
|
||||
(!select_cond || !select_cond->has_subquery()); // 3
|
||||
}
|
||||
|
||||
|
||||
@ -14414,7 +14414,7 @@ remove_const(JOIN *join,ORDER *first_order, COND *cond,
|
||||
*simple_order=0; // Must do a temp table to sort
|
||||
else if (!(order_tables & not_const_tables))
|
||||
{
|
||||
if (order->item[0]->with_subquery())
|
||||
if (order->item[0]->has_subquery())
|
||||
{
|
||||
/*
|
||||
Delay the evaluation of constant ORDER and/or GROUP expressions that
|
||||
|
Reference in New Issue
Block a user