90 likes | 182 Vues
Dive into the world of Multi Query Optimization (MQO) algorithms with this comprehensive recap covering AND-OR DAG of query sets, greedy heuristics, subset sum problems, and more. Learn about choosing the best shared nodes to cache efficiently and the trade-offs of greedy algorithms. Explore the advantages of subset sum algorithms and how they expand the search space for maximizing benefits within a fixed cache size. Discover the intricacies of scheduling nodes in MQO plans using DAG structures.
E N D
Extensions to Multi Query Optimization Amit Gupta IIT Bombay
Recap of MQO • AND-OR DAG of the set of Queries • Transformation • Greedy Algorithm • Choose highest benefit shared node to be cached
MQO for Fixed Cache Size • Greedy heuristic • Choose shared node with highest benefit/Size to be cached • Disadvantage of Greedy • less search space
Problem Definition • Given set of shared nodes S = ( s, s,..) and cache size C. • Choose subset P from S, such that • size(p) <= C , where p P • benefit of caching P is maximized.
Subset sum Problem • Given set S = ( s, s,..) and C, • choose the subset P from S such that • p <= C , where p P and • p is maximized.
Subset sum Algorithm • Given set S = ( s, s,..) • Exponential Algorithm • Search Space: Power set of S. • Approximation Algo • Given as error constant • Search Space: Trimmed Power Set of S. • Approximation Ratio =
MQO for fixed Size Cache • Given • S = { set of shared nodes} • C = Cache Size • Error constant • Search Space of trimmed Power set of S. • Trimming procedure
MQO cont. • Advantage of Subset sum Algorithm • More Search space • can be changed
Scheduling in MQO nodes to be cached Plan DAG