1. 04 Dec, 2009 1 commit
  2. 03 Dec, 2009 2 commits
  3. 02 Dec, 2009 5 commits
  4. 01 Dec, 2009 6 commits
    • Evgeny Potemkin's avatar
      Bug#33546: Slowdown on re-evaluation of constant expressions. · 987e1466
      Evgeny Potemkin authored
            
      Constant expressions in WHERE/HAVING/ON clauses aren't cached and evaluated
      for each row. This causes slowdown of query execution especially if constant
      UDF/SP function are used.
            
      Now WHERE/HAVING/ON expressions are analyzed in the top-bottom direction with
      help of the compile function. When analyzer meets a constant item it
      sets a flag for the tree transformer to cache the item and doesn't allow tree
      walker to go deeper. Thus, the topmost item of a constant expression if
      cached. This is done after all other optimizations were applied to
      WHERE/HAVING/ON expressions
            
      A helper function called cache_const_exprs is added to the JOIN class.
      It calls compile method with caching analyzer and transformer on WHERE,
      HAVING, ON expressions if they're present.
      The cache_const_expr_analyzer and cache_const_expr_transformer functions are
      added to the Item class. The first one check if the item can be cached and
      the second caches it if so.
      A new Item_cache_datetime class is derived from the Item_cache class.
      It caches both int and string values of the underlying item independently to
      avoid DATETIME aware int-to-string conversion. Thus it completely relies on
      the ability of the underlying item to correctly convert DATETIME value from
      int to string and vice versa.
      
      
      mysql-test/r/func_like.result:
        A test case result is corrected after fixing bug#33546.
      mysql-test/r/func_time.result:
        A test case result is corrected after fixing bug#33546.
      mysql-test/r/select.result:
        Added a test case for the bug#33546.
      mysql-test/r/subselect.result:
        A test case result is corrected after fixing bug#33546.
      mysql-test/r/udf.result:
        Added a test case for the bug#33546.
      mysql-test/t/select.test:
        Added a test case for the bug#33546.
      mysql-test/t/udf.test:
        Added a test case for the bug#33546.
      sql/item.cc:
        Bug#33546: Slowdown on re-evaluation of constant expressions.
        The cache_const_expr_analyzer and cache_const_expr_transformer functions are
        added to the Item class. The first one check if the item can be cached and
        the second caches it if so.
        Item_cache_datetime class implementation is added.
      sql/item.h:
        Bug#33546: Slowdown on re-evaluation of constant expressions.
        Item_ref and Item_cache classes now returns basic_const_item
        from underlying item.
        The cache_const_expr_analyzer and cache_const_expr_transformer functions are
        added to the Item class.
      sql/sql_select.cc:
        Bug#33546: Slowdown on re-evaluation of constant expressions.
                
        A helper function called cache_const_exprs is added to the JOIN class.
        It calls compile method with caching analyzer and transformer on WHERE,
        HAVING, ON expressions if they're present.
      sql/sql_select.h:
        Bug#33546: Slowdown on re-evaluation of constant expressions.
        A helper function called cache_const_exprs is added to the JOIN class.
      987e1466
    • Evgeny Potemkin's avatar
      Auto-merged fix for the bug#34384. · 9e5d1bb6
      Evgeny Potemkin authored
      9e5d1bb6
    • Andrei Elkin's avatar
      Manual resolving for the following files · 0eda4846
      Andrei Elkin authored
      Text conflict in mysql-test/collections/default.experimental
      Text conflict in mysql-test/r/show_check.result
      Text conflict in mysql-test/r/sp-code.result
      Text conflict in mysql-test/suite/binlog/r/binlog_tmp_table.result
      Text conflict in mysql-test/suite/rpl/t/disabled.def
      Text conflict in mysql-test/t/show_check.test
      Text conflict in mysys/my_delete.c
      Text conflict in sql/item.h
      Text conflict in sql/item_cmpfunc.h
      Text conflict in sql/log.cc
      Text conflict in sql/mysqld.cc
      Text conflict in sql/repl_failsafe.cc
      Text conflict in sql/slave.cc
      Text conflict in sql/sql_parse.cc
      Text conflict in sql/sql_table.cc
      Text conflict in sql/sql_yacc.yy
      Text conflict in storage/myisam/ha_myisam.cc
      
      Corrected results for
       stm_auto_increment_bug33029.reject      2009-12-01
      		20:01:49.000000000 +0300
             <andrei> @@ -42,9 +42,6 @@
             <andrei>  RETURN i;
             <andrei>  END//
             <andrei>  CALL p1();
             <andrei> -Warnings:
             <andrei> -Note   1592    Statement may not be safe to log in statement
      		format.
             <andrei> -Note   1592    Statement may not be safe to log in statement
      		format.
      
      There should be indeed no Note present because there is in fact autoincrement 
      top-level query in sp() that triggers inserting in yet another auto-inc table.
      (todo: alert DaoGang to improve the test).
      0eda4846
    • Alexander Nozdrin's avatar
      A patch for Bug#48915 (After having switched off the ipv6 support in OS, · 273454b9
      Alexander Nozdrin authored
      mysqld crashed in network_init()).
      
      The problem was that current_thd was not ready at that point in mysqld life,
      so ER() macro could not be used.
      
      The fix is to use ER_DEFAULT() macro, which is intented for such cases.
      273454b9
    • Mattias Jonsson's avatar
      merge · ad366845
      Mattias Jonsson authored
      ad366845
    • Marc Alff's avatar
      WL#2360 Performance schema · f2d67abb
      Marc Alff authored
      Part 1: Instrumentation interface
      f2d67abb
  5. 30 Nov, 2009 3 commits
  6. 28 Nov, 2009 1 commit
  7. 27 Nov, 2009 3 commits
  8. 30 Nov, 2009 1 commit
    • Tor Didriksen's avatar
      backport of: · aa70ca71
      Tor Didriksen authored
              ------------------------------------------------------------
              revno: 2617.81.1
              revision-id: tor.didriksen@sun.com-20090924061133-qo02zotz3yypmfpk
              parent: davi.arnaut@sun.com-20090923203724-tvz7x8dauzp686v7
              committer: Tor Didriksen <tor.didriksen@sun.com>
              branch nick: 6.0-codebase-bf-opt
              timestamp: Thu 2009-09-24 08:11:33 +0200
              message:
                Bug#47511 Segmentation fault during cleanup in sql_union (events_bugs.test)
                
      
      
      sql/sql_lex.h:
        Ensure that fields used during cleanup() are always initialized by constructors.
      aa70ca71
  9. 29 Nov, 2009 1 commit
  10. 27 Nov, 2009 4 commits
  11. 26 Nov, 2009 3 commits
  12. 25 Nov, 2009 4 commits
  13. 26 Nov, 2009 1 commit
  14. 25 Nov, 2009 5 commits
    • Alexander Nozdrin's avatar
      Manual merge/pull from mysql-next-mr. · 52c66b56
      Alexander Nozdrin authored
      Conflicts:
        - sql/sql_insert.cc
      52c66b56
    • Alexey Botchkov's avatar
      Bug#48878 "Embedded" tests fail due to an unknown variable "shared-memory-base-name" · 204c5ab9
      Alexey Botchkov authored
          the 'shared-memory-base-name' was added to the [client] section of the my.cnf file.
          That option isn't supported by the mysqltest_embedded.
      
      per-file comments:
        mysql-test/lib/My/ConfigFactory.pm
      204c5ab9
    • Alexander Nozdrin's avatar
      Backport of WL#798 (MySQL IPv6 support) from 6.0. · 7eb84da8
      Alexander Nozdrin authored
      The following 6.0 revisions were analyzed:
        - sp1r-brian@zim.(none)-20071228102738-21894
        - sp1r-brian@zim.(none)-20071228121841-56447
        - sp1r-brian@zim.(none)-20071228205403-56423
        - sp1r-brian@zim.(none)-20071228221139-55341
        - sp1r-brian@zim.(none)-20071228233443-55352
        - sp1r-brian@zim.(none)-20071229094527-61763
        - sp1r-brian@zim.(none)-20071230203739-61746
        - sp1r-brian@zim.(none)-20080102213805-61741
        - sp1r-brian@zim.(none)-20080103201041-61746
        - sp1r-brian@zim.(none)-20080104234927-59875
        - sp1r-brian@zim.(none)-20080105005827-59874
        - sp1r-brian@zim.(none)-20080105012020-59865
        - sp1r-brian@zim.(none)-20080106003858-59857
        - sp1r-brian@zim.(none)-20080123195552-31680
        - sp1r-brian@zim.(none)-20080124201848-29999
        - sp1r-brian@zim.(none)-20080129075144-36991
        - sp1r-cbell/Chuck@mysql_cab_desk.-20080215041806-21954
        - sp1r-vvaintroub@wva.-20080212124547-06272
        - sp1r-dfischer/mysqldev@mysql.com/production.mysql.com-20071223184258-15140
        - sp1r-brian@zim.(none)-20080206122216-35774
        - sp1r-baker@bk-internal.mysql.com-20080209005622-35947
        - sp1r-baker@bk-internal.mysql.com-20080224215608-24613
        - sp1r-baker@bk-internal.mysql.com-20080307170710-63543
        - sp1r-baker@bk-internal.mysql.com-20080312233205-13069
        - sp1r-Reggie@core.-20080402175211-28643
        - kpettersson@mysql.com-20080901101150-4ne74r8v0492vv42
        - alik@sun.com-20090805173811-9fzt0ymcp9tsvn7k
        - alik@sun.com-20090805173937-fcv1fdveodq5x9gb
        - alik@sun.com-20090805175009-g1od16i3t1xkw2qr
        - kostja@sun.com-20090805200643-j9i4fy7ii8ijho5c
        - alik@sun.com-20090807195303-j4fb5m4l1dgdahwo
        - alik@sun.com-20090808114848-3rkzr9kifrijzaqy
        - alik@sun.com-20090810041739-ugmx34h34uid8mox
        - alik@sun.com-20090810105306-rf43rfyzzblsy5e7
        - alik@sun.com-20090810123113-ccdjwai68b5woqdm
        - alik@sun.com-20090811080423-gb7pibec1znaydzy
        - alik@sun.com-20090811082130-5uckar1vx3kdsw7g
        - alik@sun.com-20090812202051-uqkfwwxxcjvo5ean
      
      The following bugfixes are also backported within this patch:
        - Bug#34292: netdb.h missing in hostname.cc
        - Bug#39153: Failing to lookup a host name can lead to crash
          in current IPv6 implementation
        - Bug#38247: Server does not resolve connecting ip's
        - Bug#43006: main.skip_name_resolve fails on Windows in PB2
        - Bug#45606: ACL requires IPv4-mapped addresses to be used
        - Bug#45584: Host name cache does not work as a cache
      7eb84da8
    • Alexander Nozdrin's avatar
      Auto-merge from mysql-next-mr-runtime. · 027a2fff
      Alexander Nozdrin authored
      027a2fff
    • Mattias Jonsson's avatar
      merge · 72a26125
      Mattias Jonsson authored
      72a26125