Tarantool development patches archive
 help / color / mirror / Atom feed
From: Kirill Yukhin <kyukhin@tarantool.org>
To: v.shpilevoy@tarantool.org
Cc: tarantool-patches@freelists.org, Kirill Yukhin <kyukhin@tarantool.org>
Subject: [tarantool-patches] [PATCH 0/2] sql: replace KeyInfo w/ key_def in SQL front-end
Date: Tue,  8 May 2018 10:56:05 +0300	[thread overview]
Message-ID: <cover.1525765048.git.kyukhin@tarantool.org> (raw)

Branch: https://github.com/tarantool/tarantool/issues/3235
Issue: https://github.com/tarantool/tarantool/tree/kyukhin/gh-3235-remove-keyinfo

This patch-set was originally aimed to move sort order column from
SQL front-end legacy structures to Tarantool's core structures.
So, first patch introduces this new field to key_part/key_def
structures.
After half of work was done, I've realized, that KeyInfo structure
is completely redundant and might be superseded by Tarantool's
key_def structure. Second patch is doing that.
It should be mentioned, that KeyInfo memory management was based
on reference counting and many memory copies were avoided. Right
not, key_def is always duplicated. This will be fixed in future,
since this is obvious performance issue.

Kirill Yukhin (2):
  sql: introduce sort order to key_part/key_part_def
  sql: replace KeyInfo with key_def

 src/box/key_def.cc            |  28 +++-
 src/box/key_def.h             |  16 +-
 src/box/schema.cc             |  30 ++--
 src/box/sql.c                 |  28 +++-
 src/box/sql/analyze.c         |   6 +-
 src/box/sql/build.c           | 114 ++++++-------
 src/box/sql/delete.c          |   6 +-
 src/box/sql/expr.c            |  61 ++++---
 src/box/sql/fkey.c            |   2 +-
 src/box/sql/insert.c          |  15 +-
 src/box/sql/parse.y           |  10 +-
 src/box/sql/pragma.c          |  11 +-
 src/box/sql/select.c          | 381 ++++++++++++++++++------------------------
 src/box/sql/sqliteInt.h       |  70 ++++----
 src/box/sql/tarantoolInt.h    |   5 +-
 src/box/sql/update.c          |   6 +-
 src/box/sql/vdbe.c            |  80 +++++----
 src/box/sql/vdbe.h            |  35 ++--
 src/box/sql/vdbeInt.h         |  13 +-
 src/box/sql/vdbeapi.c         | 183 --------------------
 src/box/sql/vdbeaux.c         | 247 ++++++++++-----------------
 src/box/sql/vdbemem.c         |  14 +-
 src/box/sql/vdbesort.c        |  54 +++---
 src/box/sql/where.c           |  32 ++--
 src/box/sql/wherecode.c       |  12 +-
 src/box/tuple.c               |   9 +
 src/box/tuple.h               |   9 +
 test/sql-tap/index1.test.lua  |   2 +
 test/sql-tap/index4.test.lua  |   1 +
 test/sql-tap/selectA.test.lua |   1 +
 30 files changed, 631 insertions(+), 850 deletions(-)

-- 
2.16.2

             reply	other threads:[~2018-05-08  7:56 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-08  7:56 Kirill Yukhin [this message]
2018-05-08  7:56 ` [tarantool-patches] [PATCH 1/2] sql: introduce sort order to key_part/key_part_def Kirill Yukhin
2018-05-08 16:02   ` [tarantool-patches] " Vladislav Shpilevoy
2018-05-10 13:01     ` Kirill Yukhin
2018-05-08  7:56 ` [tarantool-patches] [PATCH] sql: use collation pointers instead of names Kirill Yukhin
2018-04-17 18:06   ` [tarantool-patches] " Vladislav Shpilevoy
2018-04-18  5:42     ` Kirill Yukhin
2018-05-08  7:59   ` Kirill Yukhin
2018-05-08  7:56 ` [tarantool-patches] [PATCH 2/2] sql: replace KeyInfo with key_def Kirill Yukhin
2018-05-08 16:02   ` [tarantool-patches] " Vladislav Shpilevoy
2018-05-10 12:59     ` Kirill Yukhin
2018-05-11 11:22       ` Vladislav Shpilevoy
2018-05-11 12:56         ` Kirill Yukhin
2018-05-11 19:05           ` Vladislav Shpilevoy
2018-05-14 11:40             ` Kirill Yukhin
  -- strict thread matches above, loose matches on Subject: below --
2018-04-13  8:05 [tarantool-patches] [PATCH] sql: use collation pointers instead of names Kirill Yukhin
2018-04-16 13:43 ` [tarantool-patches] " Vladislav Shpilevoy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cover.1525765048.git.kyukhin@tarantool.org \
    --to=kyukhin@tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --cc=v.shpilevoy@tarantool.org \
    --subject='Re: [tarantool-patches] [PATCH 0/2] sql: replace KeyInfo w/ key_def in SQL front-end' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox