1. 03 Sep, 2018 2 commits
  2. 31 Aug, 2018 1 commit
  3. 30 Aug, 2018 1 commit
    • Monty's avatar
      MDEV-16682 Assertion `(buff[7] & 7) == HEAD_PAGE' failed · 42f09ada
      Monty authored
      Problem was that SQL level tried to read a record with rnd_pos()
      that was already deleted by the same statement.
      In the case where the page for the record had been deleted, this
      caused an assert.
      Fixed by extending the assert to also handle empty pages and
      return HA_ERR_RECORD_DELETED for reads to deleted pages.
      42f09ada
  4. 29 Aug, 2018 1 commit
  5. 28 Aug, 2018 1 commit
  6. 27 Aug, 2018 2 commits
  7. 25 Aug, 2018 3 commits
  8. 24 Aug, 2018 3 commits
  9. 23 Aug, 2018 2 commits
  10. 22 Aug, 2018 1 commit
    • Daniel Black's avatar
      item_cmp_type: simplier for a faster codepath · 064ba8cc
      Daniel Black authored
      The common case for this function is that both types are the same.
      
      The Item_result defination from include/mysql.h.pp is the following enum
         enum Item_result
         {
           STRING_RESULT=0, REAL_RESULT, INT_RESULT, ROW_RESULT, DECIMAL_RESULT,
           TIME_RESULT
         };
      
      The compilers aren't quite smart enough to optimize to this shortcut so
      this makes it quicker.
      
      Before the change:
      
      0000000000012730 <item_cmp_type(Item_result, Item_result)>:
         12730:       89 f0                   mov    %esi,%eax
         12732:       09 f8                   or     %edi,%eax
         12734:       74 4c                   je     12782 <item_cmp_type(Item_result, Item_result)+0x52>
         12736:       83 ff 02                cmp    $0x2,%edi
         12739:       75 0a                   jne    12745 <item_cmp_type(Item_result, Item_result)+0x15>
         1273b:       b8 02 00 00 00          mov    $0x2,%eax
         12740:       83 fe 02                cmp    $0x2,%esi
         12743:       74 3c                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         12745:       83 ff 03                cmp    $0x3,%edi
         12748:       b8 03 00 00 00          mov    $0x3,%eax
         1274d:       74 32                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         1274f:       83 fe 03                cmp    $0x3,%esi
         12752:       74 2d                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         12754:       83 ff 05                cmp    $0x5,%edi
         12757:       b8 05 00 00 00          mov    $0x5,%eax
         1275c:       74 23                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         1275e:       83 fe 05                cmp    $0x5,%esi
         12761:       74 1e                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         12763:       83 ff 04                cmp    $0x4,%edi
         12766:       74 05                   je     1276d <item_cmp_type(Item_result, Item_result)+0x3d>
         12768:       83 ff 02                cmp    $0x2,%edi
         1276b:       75 0f                   jne    1277c <item_cmp_type(Item_result, Item_result)+0x4c>
         1276d:       b8 04 00 00 00          mov    $0x4,%eax
         12772:       83 fe 02                cmp    $0x2,%esi
         12775:       74 0a                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         12777:       83 fe 04                cmp    $0x4,%esi
         1277a:       74 05                   je     12781 <item_cmp_type(Item_result, Item_result)+0x51>
         1277c:       b8 01 00 00 00          mov    $0x1,%eax
         12781:       c3                      retq
         12782:       31 c0                   xor    %eax,%eax
         12784:       c3                      retq
      
      After, noting the short cut and the beginning of the function:
      
      0000000000012730 <item_cmp_type(Item_result, Item_result)>:
         12730:       39 f7                   cmp    %esi,%edi
         12732:       75 03                   jne    12737 <item_cmp_type(Item_result, Item_result)+0x7>
         12734:       89 f8                   mov    %edi,%eax
         12736:       c3                      retq
         12737:       83 ff 03                cmp    $0x3,%edi
         1273a:       b8 03 00 00 00          mov    $0x3,%eax
         1273f:       74 32                   je     12773 <item_cmp_type(Item_result, Item_result)+0x43>
         12741:       83 fe 03                cmp    $0x3,%esi
         12744:       74 2d                   je     12773 <item_cmp_type(Item_result, Item_result)+0x43>
         12746:       83 ff 05                cmp    $0x5,%edi
         12749:       b8 05 00 00 00          mov    $0x5,%eax
         1274e:       74 23                   je     12773 <item_cmp_type(Item_result, Item_result)+0x43>
         12750:       83 fe 05                cmp    $0x5,%esi
         12753:       74 1e                   je     12773 <item_cmp_type(Item_result, Item_result)+0x43>
         12755:       83 ff 04                cmp    $0x4,%edi
         12758:       74 05                   je     1275f <item_cmp_type(Item_result, Item_result)+0x2f>
         1275a:       83 ff 02                cmp    $0x2,%edi
         1275d:       75 0f                   jne    1276e <item_cmp_type(Item_result, Item_result)+0x3e>
         1275f:       b8 04 00 00 00          mov    $0x4,%eax
         12764:       83 fe 02                cmp    $0x2,%esi
         12767:       74 0a                   je     12773 <item_cmp_type(Item_result, Item_result)+0x43>
         12769:       83 fe 04                cmp    $0x4,%esi
         1276c:       74 05                   je     12773 <item_cmp_type(Item_result, Item_result)+0x43>
         1276e:       b8 01 00 00 00          mov    $0x1,%eax
         12773:       c3                      retq
      Signed-off-by: default avatarDaniel Black <daniel@linux.vnet.ibm.com>
      064ba8cc
  11. 20 Aug, 2018 1 commit
  12. 15 Aug, 2018 3 commits
    • Oleksandr Byelkin's avatar
      Merge branch '5.5' into 10.0 · bcc677bb
      Oleksandr Byelkin authored
      bcc677bb
    • Sergei Petrunia's avatar
      MDEV-6439: Server crashes in Explain_union::print_explain with explain in slow log, tis620 charset · b62ac161
      Sergei Petrunia authored
      Item_subselect::is_expensive() used to return FALSE (Inexpensive) whenever
      it saw that one of SELECTs in the Subquery's UNION is degenerate. It
      ignored the fact that other parts of the UNION might not be inexpensive,
      including the case where pther parts of the UNION have no query plan yet.
      
      For a subquery in form col >= ANY (SELECT 'foo' UNION SELECT 'bar')
      this would cause the query to be considered inexpensive when there is
      no query plan for the second part of the UNION, which in turn would
      cause the SELECT 'foo' to compute and free itself while still inside
      JOIN::optimize for that SELECT (See MDEV comment for full description).
      b62ac161
    • Oleksandr Byelkin's avatar
      MDEV-15475: Assertion `!table || (!table->read_set ||... · 1b797e9e
      Oleksandr Byelkin authored
      MDEV-15475: Assertion `!table || (!table->read_set || bitmap_is_set(table->read_set, field_index))' failed on EXPLAIN EXTENDED with constant table and view
      
      Print constant ISNULL value independent.
      Fix of printing of view FRM and CREATE VIEW output
      1b797e9e
  13. 13 Aug, 2018 1 commit
  14. 11 Aug, 2018 1 commit
  15. 07 Aug, 2018 1 commit
  16. 06 Aug, 2018 1 commit
  17. 03 Aug, 2018 3 commits
  18. 01 Aug, 2018 3 commits
    • Daniel Bartholomew's avatar
      bump the VERSION · 90b66c16
      Daniel Bartholomew authored
      90b66c16
    • Marko Mäkelä's avatar
      MDEV-16865 InnoDB fts_query() ignores KILL · a7f84f09
      Marko Mäkelä authored
      The functions fts_ast_visit() and fts_query() inside
      InnoDB FULLTEXT INDEX query processing are not checking
      for THD::killed (trx_is_interrupted()), like anything
      that potentially takes a long time should do.
      
      This is a port of the following change from MySQL 5.7.23,
      with a completely rewritten test case.
      
      commit c58c6f8f66ddd0357ecd0c99646aa6bf1dae49c8
      Author: Aakanksha Verma <aakanksha.verma@oracle.com>
      Date:   Fri May 4 15:53:13 2018 +0530
      
      Bug #27155294 MAX_EXECUTION_TIME NOT INTERUPTED WITH FULLTEXT SEARCH USING MECAB
      a7f84f09
    • Marko Mäkelä's avatar
      Fix function pointer type mismatch · b3e95086
      Marko Mäkelä authored
      b3e95086
  19. 31 Jul, 2018 2 commits
  20. 30 Jul, 2018 7 commits
    • Marko Mäkelä's avatar
      MDEV-16855 Fix fts_sync_synchronization in InnoDB · e52315a4
      Marko Mäkelä authored
      This is a backport of the following fix from MySQL 5.7.23.
      Some code refactoring has been omitted, and the test case has
      been adapted to MariaDB.
      
      commit 7a689acaa65e9d602575f7aa53fe36a64a07460f
      Author: Krzysztof Kapuścik <krzysztof.kapuscik@oracle.com>
      Date:   Tue Mar 13 12:34:03 2018 +0100
      
      Bug#27082268 Invalid FTS sync synchronization
      
      The fix closes two issues:
      Bug #27082268 - INNODB: FAILING ASSERTION: SYM_NODE->TABLE != NULL DURING FTS SYNC
      Bug #27095935 - DEADLOCK BETWEEN FTS_DROP_INDEX AND FTS_OPTIMIZE_SYNC_TABLE
      
      Both issues were related to a FTS cache sync being done during
      operations that perfomed DDL actions on internal FTS tables
      (ALTER TABLE, TRUNCATE). In some cases the FTS tables and/or
      internal cache structures could get removed while still being
      used to perform FTS synchronization leading to crashes. In other
      the sync operations could not get finishes as it was waiting for
      dict lock which was taken by thread waiting for the background
      sync to be finished.
      
      The changes done includes:
      - Stopping background operations during ALTER TABLE and TRUNCATE.
      - Removal of unused code in FTS.
      - Cleanup of FTS sync related code to make it more readable and
      easier to maintain.
      
      RB#18262
      e52315a4
    • Marko Mäkelä's avatar
      Apply the 5.6.40 security fixes to XtraDB · 5ed2da95
      Marko Mäkelä authored
      We did not merge Percona XtraDB 5.6.40-84.0 yet.
      The changes in it are mostly cosmetic, except for
      2 bug fixes from Oracle MySQL 5.6.40, which could
      be security bugs.
      
      This was achieved by taking the applicable parts
      of an earlier InnoDB commit to XtraDB:
      
      git diff 15ec8c2f{~,} storage/innobase|
      sed -e s+/innobase/+/xtradb/+|patch -p1
      5ed2da95
    • Marko Mäkelä's avatar
      Merge 5.5 into 10.0 · 7c773abd
      Marko Mäkelä authored
      7c773abd
    • Karthik Kamath's avatar
      No commit message · a49ec980
      Karthik Kamath authored
      No commit message
      a49ec980
    • Marko Mäkelä's avatar
      Merge InnoDB MySQL 5.6.41 to 10.0 · 4c21c367
      Marko Mäkelä authored
      4c21c367
    • Sachin Agarwal's avatar
      Bug #27326796 - MYSQL CRASH WITH INNODB ASSERTION FAILURE IN FILE PARS0PARS.CC · 29ddc6e9
      Sachin Agarwal authored
      Problem:
      As part of bug #24938374 fix, dict_operation_lock was not taken by
      fts_optimize_thread while syncing fts cache.
      Due to this change, alter query is able to update SYS_TABLE rows
      simultaneously. Now when fts_optimizer_thread goes open index table,
      It doesn't open index table if the record corresponding to that table is
      set to REC_INFO_DELETED_FLAG in SYS_TABLES and hits an assert.
      
      Fix:
      If fts sync is already in progress, Alter query would wait for sync to
      complete before renaming table.
      
      RB: #19604
      Reviewed by : Jimmy.Yang@oracle.com
      29ddc6e9
    • Marko Mäkelä's avatar
      Merge 5.5 into 10.0 · 91181b22
      Marko Mäkelä authored
      91181b22