Conference paper

R∗ optimizer validation and performance evaluation for local queries

Download paper


Few database query optimizer models have been validated against actual performance This paper presents the methodology and results of a thorough validation of the optimizer and evaluation of the performance of the experimental distributed relational database management system R∗, which inherited and extended to a distributed environment the optimization algorithms of System R Optimizer estimated costs and actual R∗ resources consumed were written to database tables using new SQL commands, permitting automated control from SQL application programs of test data collection and reduction A number of tests were run over a wide variety of dynamically-created test databases, SQL queries, and system parameters The results for single-table access, sorting, and local 2-table joins are reported here The tests confirmed the accuracy of the majority of the I/O cost model, the significant contnbution of CPU cost to total cost, and the need to model CPU cost in more detail than was done in System R The R∗ optimizer now retains cost components separately and estimates the number of CPU instructions, including those for applying different kinds of predicates The sensitivity of I/O cost to buffer space motivated the development of more detailed models of buffer utilization unclustered index scans and nested-loop joins often benefit from pages remaining in the buffers, whereas concurrent scans of the data pages and the index pages for multiple tables during joins compete for buffer share Without an mdex on the join column of the inner table, the optimizer correctly avoids the nested-loop jom, confirming the need for merge-scan joins When the jom column of the inner is indexed, the optimizer overestimates the cost of the nested-loop jom, whose actual performance is very sensitive to three parameters that are extremely difficult to estimate (1) the join (result) cardinality, (2) the outer table's cardinality, and (3) the number of buffer pages available to store the inner table Suggestions are given for improved database statistics, prefetch and page replacement strategies for the buffer manager, and the use of temporary mdexes and Bloom filters (hashed semijoins) to reduce access of unneeded data.


15 Jun 1986