Performance Optimization of SQL Computing for Column-oriented Database

Author
TanZhongTao
Advisor
ZhouChunGuang
School
Jilin University
Major
Software Engineering
Classification
TP311.138SQ Database system: sub- system name
Degree
Master's thesis
Year
2009
Downloads
165
Citations
1

Request the full text

Abstract

The development of database with independent intellectual property is an important step for our information industry. There is urgent requirement of it not only in traditional field such as national defense and e-government,but also requirements that operating complex statistical analysis efficiently in some applied field such as statistical audit management, network monitoring analysis, historical analysis of the financial telecom.The GBase 8a is a homemade and analytic database with independent intellectual property,which is developed independently by nanda general company.GBase 8a is a Column-oriented database,but it uses a large number of technology of data management in in-memory database at the same time. In this paper, concentrating its focus on the characteristics of Column-Stores, we introduce optimization and the realization of performance based on the way of Column-Stores in detail.With the increasing scale of data, the demand of data analysis is more and more.Simply looking at a record has no significance, but to all the data from a statistical analysis of all that the performance of the database has a higher demand. Therefore, homemade analytic databases need to continuously improve the system performance to meet the needs of users, to improve their market competitiveness.Column-Stores is a new type of database storage,which has a essentially different with Row-Stores.In the type of Row-Stores, each table corresponds to a database page chains and each page of a database that contains one or more lines of database records. Database records of each field are stored in the order of pages in the database.There are some problems such as redundant I/O of disk, generating data debris of disk and low storage utilization in the Row-oriented database. The type of Column-Stores stores the data in the way of column. Compared with Row-Stores, it fractionizes the area of each page of storage. in data page it is no longer stored all the columns of one or more records but separate column of one or more data records. Column-Stores solves the problems such as redundant I/O of disk, generating data debris of disk and low storage utilization which happen in the Row-oriented database effectively.The clock frequency of CPU has been complying with Moore’s Law(doubling about every 3 years). What’s more,CPU has used a series of useful new technologies such as CPU pipelining, Cache technology, technical instruction prefetch, branch processing, out-of-order implementation,which speed up the speed of processing further. And now the superscalar CPU supports more pipelines at the same time in order to achieve an internal parallel processing, which impels the speed of processing to a new heights. And how to make rational use of these new features, new technologies have a very important significance. Compiler optimization can take advantage of new technologies to improve efficiency in the implementation code by using the ways of array of mergers, both within and outside the circle of exchange, the cycle integration and block.In this paper, the performance optimization of database is different from the common performance optimization.It optimizes the performance of database by using the characteristics of Column-Stores and modern CPU.It It aimes at the optimization of high-volume data and complex operation of function.This article focuses on the column-per-one-time and vector-per-one-time , which are based on the performance optimization of Column-oriented database and this is an incremental process.The column-per-one-time has improved performance compared to the traditional Volcano iterator model.The style of computing of Volcano iterator model is tuple-per-one-time.It results in a large number of useless operations.There is dependence on both frontal and posterior data,which leads to a lot of pipeline slots.It can’t make good use of data prefetching techniques because of Row-Stores.And the instruction is depended with each other so that more pipelining can be used perfectly. The column-per-one-time operates data of all of one column at a time,so that useless operations only appear at the edges of each columns and even can be ignored in the case of large amount of data. Pipeline slots disappear and data prefetching techniques can be made good use of.What’s more,more pipelining can be carried out at the same time.The authors put forward vector-per-one-time based on column-per-one-time,which can speed up the SQL computation ulteriorly.. Although the column-per-one-time can improve the performance of database systems in a large extent,it need to write the intermediate results of all of one column(if cache can’t contain) to the main memory,which may cause capacity miss(one kind of cache miss).But vector-per-one-time can solve this problem effectively. The so-called vector-per-one-time’s object of each operation is neither a record nor a whole column,but a vector. which is a block of the entire data of one column and the size of vector block accords to the size of the cache.So the intermediate results of a vector block can be left in the cache and don’t need to write to the main memory.CPU can find them from the cache when they are needed by next operation,which avoids a lot of spending of I/O between main memory and cache. Selection vector is used in vector-per-one-time.In fact,it just is a array which records the position of source data after filtering.Then the selection vector and source data will be passed to the functions at the same time. At the same time, vector-per-one-time introduce two new technologies:the elimination of branches and Predefining of compound computing, which are still in their experimental stage and are achieved in static way, needing to achieve the purpose of dynamic realization. Finally, we carry out the TPC-H benchmark.Here our main TPC-H is on the first sql statement,because it only involves one table and dosen’t contain join operation.So it can be the most accurate reflection of the optimization work we have done. We contrast the test results of MySQL 5.0,column-per-one-time and vector-per-one-time in different SCALE and analyze the promotion of performance in detail.Besides,we give the relation between the promotion of performance and size of data. All evidence has proved that our work is quite effectual.After a large number of experiments, results show that the effect of optimization is quite obvious when it aims at the characteristics of Column-Stores and modern CPU. However, the development of CPU is rapid and the new features and new technologies continue to emerge.So we will continue to optimizer our database with the characteristics of modern CPU. Due to time constraints,the performance optimization involved in this paper is achieved in the premise that all data is in the scope of main memory. The case that data beyond the main memory is the emphases of our next work. Then we will complete this task together with our colleagues who take charge of the module of storage management.

Table of contents

Summary 4-7 Chapter 1 Introduction 7-10 1.1 Background and significance 7 1.2 content and objectives 7-8 1.3 of this article the main work and organizational structure 8-10 Chapter 2 Research and technical basis 10-20 2.1 column store databases 10-13 2.1.1 column storage concept 10-11 2.1.2 column stored in the main features 11-13 2.2 CPU Features 13-20 2.2.1 pipelining 13-14 2.2.2 Out-of-order execution 14 2.2.3 branch processing 14-15 2.2.4 caching technology 15-16 2.2.5 superscalar CPU 16-17 2.2.6 compiler optimizations 17-20 Chapter 3 bulk op 20-31 3.1 batch computing concept 20 3.2 batch operations features 20-29 3.2.1 resolution process overhead 21-25 3.2.2 on a modern CPU features of utilization 25-29 3.3 Conclusion 29-31 Chapter 4 vectorization operator 31-49 4.1 vector operations concept 31 4.2 vector computing the basic principles of 31 4.3 vector computing performance advantage 31-34 4.3.1 vectorization and batch operations flowchart 32-34 4.3.2 block size on the vectorization operator 34 4.4 Feasibility 34-39 4.5 process and the extent of 39-46 4.5.1 Selection vector 39-41 4.5.2 a single function of vector computing 41-44 4.5.3 on multiple functions to achieve a vectorization operator 44-45 4.5.4 operating in the entire resolution process to achieve a vectorization operator 45-46 4.6 some useful technology 46-49 4.6.1 to eliminate branch technology 46-47 4.6.2 Mixed Operation predefined 47-49 Chapter 5 Performance comparison test 49-54 5.1 Experimental environment and 49-50 5.1.1 hardware environment 49 5.1.2 database environment 49-50 5.1.3 test method 50 5.2 test results and analysis 50-54 Chapter 6 Summary and Outlook 54-56 6.1 summarize 54-55 6.2 future work 55-56 References 56-58 thank 58-59 Summary 59-61 Abstract 61-63

Related dissertations

  1. Implement and Optimization Research of GIS Network Analysis Algorithms for Large Amounts of Data
  2. Based on the Hibernate object persistence layer design and performance improvements
    HengDongMei ·Hohai University ·2006 ·Master's thesis
  3. Research on the Improvement of the Performance Appraisal System for the Dispatching Labors of Changsha Mobile Communication Company
    SuHang ·Hunan University ·2013 ·Master's thesis
  4. Research on Performance Management of the Credit Cooperation in Shandongacounty
  5. Design and Implementation of High Speed Data Recorder Based on FPGA
  6. The Design and Implementation of a Delivery and Scheduling System for Video Files
  7. Research on the Technologies of Internet Traffic Localiztion
    YuJiang ·Jilin University ·2013 ·Master's thesis
  8. An Efficient Hardware Architecture Design of Texture Mapping Unit
    ZhaoGuoYu ·Tianjin University ·2012 ·Master's thesis
  9. The Research of Data Warehouse Performance Optimization Technology Based on the Coupling Index and Materialized View
    MaYingYing ·Hunan University ·2013 ·Master's thesis
  10. Research and Implementation of Data Reusing Strategy in Column-store Data Warehouse
    ZhouJiaoLing ·Donghua University ·2014 ·Master's thesis
  11. Research on Key Technologies for the Client of Distributed File System
  12. Design and Implementation of Online Examination System of Shanghai Television Video University
    LiZuo ·Dalian University of Technology ·2013 ·Master's thesis
  13. Uncertain Construction and Optimization of Reverse Logistics System
    ZhangLing ·Zhejiang University ·2014 ·Doctoral dissertation
  14. Research on Digital Rights Management Based on Risk
    CuiNingNing ·Beijing Jiaotong University ·2014 ·Master's thesis
  15. Research on Parallel Computing Technology in Loudi Region Analysis of Soil and Water Loss in the Processing of Application
    WangXiuLin ·Hunan University ·2013 ·Master's thesis
  16. Research of Protocol Adaption and Cache Management of Cloud Storage Gateway
  17. Evaluate the Performance of Storage System by Mathematical Modeling Methods
    DiaoYing ·Harbin Engineering University ·2013 ·Doctoral dissertation
  18. Research and Design of Storage Organization and Index on Main Memory Database
    LiuZheYi ·Hunan University ·2013 ·Master's thesis
  19. Research and Implementation of Memory Optimization Based on Parallel Computing Engine Spark
    FengLin ·Tsinghua University ·2013 ·Master's thesis
  20. Energy-Efficient Management for Memory System Based on Access Patterns of Applications
    ZhangTieFei ·Zhejiang University ·2013 ·Doctoral dissertation