Proceedings of the Institute for System Programming of the RAS
RUS  ENG    JOURNALS   PEOPLE   ORGANISATIONS   CONFERENCES   SEMINARS   VIDEO LIBRARY   PACKAGE AMSBIB  
General information
Latest issue
Archive

Search papers
Search references

RSS
Latest issue
Current issues
Archive issues
What is RSS



Proceedings of ISP RAS:
Year:
Volume:
Issue:
Page:
Find






Personal entry:
Login:
Password:
Save password
Enter
Forgotten password?
Register


Proceedings of the Institute for System Programming of the RAS, 2016, Volume 28, Issue 4, Pages 217–240
DOI: https://doi.org/10.15514/ISPRAS-2016-28(4)-13
(Mi tisp62)
 

This article is cited in 5 scientific papers (total in 5 papers)

Dynamic compilation of expressions in SQL queries for PostgreSQL

E. Yu. Sharygina, R. A. Buchatskiya, L. V. Skvortsovb, R. A. Zhuykova, D. M. Melnika

a Institute for System Programming of the Russian Academy of Sciences
b Lomonosov Moscow State University, CMC Department
Full-text PDF (635 kB) Citations (5)
References:
Abstract: In recent years, as performance and capacity of main and external memory grow, performance of database management systems (DBMSes) on certain kinds of queries is more determined by raw CPU speed. Currently, PostgreSQL uses the interpreter to execute SQL queries. This yields an overhead caused by indirect calls to handler functions and runtime checks, which could be avoided if the query were compiled into native code "on-the-fly", i.e. just-in-time (JIT) compiled: at run time the specific table structure is known as well as data types and built-in functions used in the query as well as the query itself. This is especially important for complex queries, performance of which is CPU-bound. We've developed a PostgreSQL extension that implements SQL query JIT compilation using LLVM compiler infrastructure. In this paper we show how to implement JIT compilation to speed up sequential scan operator (SeqScan) as well as expressions in WHERE clauses. We describe some important optimizations that are possible only with dynamic compilation, such as precomputing tuple attributes offsets only for attributes used by the query. We also discuss the maintainability of our extension, i.e. the automation for translating PostgreSQL backend functions into LLVM IR, using the same source code both for our JIT compiler and the existing interpreter. Currently, with LLVM JIT we achieve up to 5x speedup on synthetic tests as compared to original PostgreSQL interpreter.
Keywords: PostgreSQL, LLVM, dynamic compilation, just-in-time compilation, database management system engines, query languages.
Bibliographic databases:
Document Type: Article
Language: Russian
Citation: E. Yu. Sharygin, R. A. Buchatskiy, L. V. Skvortsov, R. A. Zhuykov, D. M. Melnik, “Dynamic compilation of expressions in SQL queries for PostgreSQL”, Proceedings of ISP RAS, 28:4 (2016), 217–240
Citation in format AMSBIB
\Bibitem{ShaBucSkv16}
\by E.~Yu.~Sharygin, R.~A.~Buchatskiy, L.~V.~Skvortsov, R.~A.~Zhuykov, D.~M.~Melnik
\paper Dynamic compilation of expressions in SQL queries for PostgreSQL
\jour Proceedings of ISP RAS
\yr 2016
\vol 28
\issue 4
\pages 217--240
\mathnet{http://mi.mathnet.ru/tisp62}
\crossref{https://doi.org/10.15514/ISPRAS-2016-28(4)-13}
\elib{https://elibrary.ru/item.asp?id=27174148}
Linking options:
  • https://www.mathnet.ru/eng/tisp62
  • https://www.mathnet.ru/eng/tisp/v28/i4/p217
  • This publication is cited in the following 5 articles:
    Citing articles in Google Scholar: Russian citations, English citations
    Related articles in Google Scholar: Russian articles, English articles
    Proceedings of the Institute for System Programming of the RAS
    Statistics & downloads:
    Abstract page:218
    Full-text PDF :256
    References:37
     
      Contact us:
     Terms of Use  Registration to the website  Logotypes © Steklov Mathematical Institute RAS, 2024