MDEV-9750: Quick memory exhaustion with 'extended_keys=on' ...
(Variant #2) Do not produce SEL_ARG graphs that would yield huge numbers of ranges. Introduce a concept of SEL_ARG graph's "weight". If we are about to produce a graph whose "weight" exceeds the limit, remove the parts of SEL_ARG graph that represent the biggest key parts. Do so until the graph's is within the limit. Variant #2: Don't call enforce_sel_arg_weight_limit() for sub-graphs, as this has complicated semantics if the subgraph has shared sub-sub-graphs. Instead, do pruning it only after we've constructed the entire SEL_ARG graph.
Showing
This diff is collapsed.
Please register or sign in to comment