You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bug#18558561: Replace Cost_estimate with a double when estimating join cost
The member variable prefix_cost of class POSITION is made a double.
Since partial plans and complete plans are compared with a cost represented
as a double, it makes sense to store this as a double too.
The member variable prefix_record_count of class POSITION is renamed to
prefix_rowcount for more consistent naming.
The function set_prefix_costs() is renamed to set_prefix_cost().
A new function set_prefix_join_cost() that calculates the cost of a prefix
plan has been added.
The above change of type has made it possible to eliminate the arguments
record_count and read_time that were currently shipped to some functions
of class Optimize_table_order: consider_plan(),
best_extension_by_limited_search(), eq_ref_extension_by_limited_search()
and advance_sj_state(). These functions use member variables from
POSITION instead.
A new const property has_sj has been added to class Optimize_table_order,
so it does not have to be calculated more than once.
In JOIN::setup_materialized_table(), the cost of a semi-join
materialization is correctly calculated, to keep a correct cost for a
final plan.
0 commit comments