summaryrefslogtreecommitdiff
path: root/storage/innobase
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2018-11-19 11:42:14 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2018-11-19 11:42:14 +0200
commitff88e4bb8ae1bd8e903c403a598e7d2c5d2bbcaf (patch)
tree2bd187db488299164e566df1dfb048e27c5e1197 /storage/innobase
parentcb5bca721b47cfb344146d5d104263da752661eb (diff)
downloadmariadb-git-ff88e4bb8ae1bd8e903c403a598e7d2c5d2bbcaf.tar.gz
Remove many redundant #include from InnoDB
Diffstat (limited to 'storage/innobase')
-rw-r--r--storage/innobase/btr/btr0btr.cc3
-rw-r--r--storage/innobase/buf/buf0buf.cc4
-rw-r--r--storage/innobase/buf/buf0dblwr.cc1
-rw-r--r--storage/innobase/buf/buf0flu.cc4
-rw-r--r--storage/innobase/buf/buf0lru.cc1
-rw-r--r--storage/innobase/buf/buf0rea.cc2
-rw-r--r--storage/innobase/data/data0data.cc2
-rw-r--r--storage/innobase/data/data0type.cc2
-rw-r--r--storage/innobase/dict/dict0boot.cc2
-rw-r--r--storage/innobase/dict/dict0crea.cc4
-rw-r--r--storage/innobase/dict/dict0defrag_bg.cc5
-rw-r--r--storage/innobase/dict/dict0dict.cc2
-rw-r--r--storage/innobase/dict/dict0load.cc3
-rw-r--r--storage/innobase/dict/dict0stats.cc3
-rw-r--r--storage/innobase/dict/dict0stats_bg.cc1
-rw-r--r--storage/innobase/fil/fil0crypt.cc1
-rw-r--r--storage/innobase/fil/fil0fil.cc4
-rw-r--r--storage/innobase/fil/fil0pagecompress.cc1
-rw-r--r--storage/innobase/fsp/fsp0file.cc5
-rw-r--r--storage/innobase/fsp/fsp0fsp.cc3
-rw-r--r--storage/innobase/fsp/fsp0space.cc3
-rw-r--r--storage/innobase/fsp/fsp0sysspace.cc3
-rw-r--r--storage/innobase/fts/fts0ast.cc2
-rw-r--r--storage/innobase/fts/fts0fts.cc3
-rw-r--r--storage/innobase/fts/fts0opt.cc2
-rw-r--r--storage/innobase/fts/fts0que.cc3
-rw-r--r--storage/innobase/ha/ha0storage.cc1
-rw-r--r--storage/innobase/handler/ha_innodb.cc2
-rw-r--r--storage/innobase/handler/handler0alter.cc4
-rw-r--r--storage/innobase/handler/i_s.cc5
-rw-r--r--storage/innobase/ibuf/ibuf0ibuf.cc3
-rw-r--r--storage/innobase/include/btr0bulk.h1
-rw-r--r--storage/innobase/include/buf0buf.ic2
-rw-r--r--storage/innobase/include/dict0crea.h3
-rw-r--r--storage/innobase/include/dict0dict.h2
-rw-r--r--storage/innobase/include/dict0load.h2
-rw-r--r--storage/innobase/include/dict0mem.h1
-rw-r--r--storage/innobase/include/fsp0file.h5
-rw-r--r--storage/innobase/include/fsp0fsp.h1
-rw-r--r--storage/innobase/include/fsp0space.h2
-rw-r--r--storage/innobase/include/fsp0sysspace.h1
-rw-r--r--storage/innobase/include/fts0ast.h1
-rw-r--r--storage/innobase/include/fts0fts.h2
-rw-r--r--storage/innobase/include/fts0plugin.h2
-rw-r--r--storage/innobase/include/fts0types.ic3
-rw-r--r--storage/innobase/include/gis0type.h3
-rw-r--r--storage/innobase/include/log0recv.h2
-rw-r--r--storage/innobase/include/mem0mem.ic2
-rw-r--r--storage/innobase/include/page0types.h1
-rw-r--r--storage/innobase/include/rem0cmp.h7
-rw-r--r--storage/innobase/include/rem0cmp.ic1
-rw-r--r--storage/innobase/include/row0mysql.h16
-rw-r--r--storage/innobase/include/row0trunc.h1
-rw-r--r--storage/innobase/include/trx0purge.h2
-rw-r--r--storage/innobase/include/trx0trx.h8
-rw-r--r--storage/innobase/include/trx0types.h2
-rw-r--r--storage/innobase/include/ut0mutex.h4
-rw-r--r--storage/innobase/include/ut0new.h4
-rw-r--r--storage/innobase/include/ut0vec.ic2
-rw-r--r--storage/innobase/lock/lock0lock.cc8
-rw-r--r--storage/innobase/lock/lock0prdt.cc9
-rw-r--r--storage/innobase/lock/lock0wait.cc2
-rw-r--r--storage/innobase/log/log0log.cc2
-rw-r--r--storage/innobase/log/log0recv.cc4
-rw-r--r--storage/innobase/mem/mem0mem.cc2
-rw-r--r--storage/innobase/mtr/mtr0mtr.cc1
-rw-r--r--storage/innobase/os/os0event.cc2
-rw-r--r--storage/innobase/os/os0file.cc8
-rw-r--r--storage/innobase/os/os0proc.cc7
-rw-r--r--storage/innobase/os/os0thread.cc8
-rw-r--r--storage/innobase/page/page0cur.cc2
-rw-r--r--storage/innobase/pars/pars0opt.cc1
-rw-r--r--storage/innobase/pars/pars0pars.cc3
-rw-r--r--storage/innobase/que/que0que.cc5
-rw-r--r--storage/innobase/rem/rem0cmp.cc11
-rw-r--r--storage/innobase/rem/rem0rec.cc8
-rw-r--r--storage/innobase/row/row0ftsort.cc7
-rw-r--r--storage/innobase/row/row0import.cc4
-rw-r--r--storage/innobase/row/row0ins.cc6
-rw-r--r--storage/innobase/row/row0log.cc1
-rw-r--r--storage/innobase/row/row0merge.cc4
-rw-r--r--storage/innobase/row/row0mysql.cc4
-rw-r--r--storage/innobase/row/row0quiesce.cc3
-rw-r--r--storage/innobase/row/row0row.cc2
-rw-r--r--storage/innobase/row/row0sel.cc2
-rw-r--r--storage/innobase/row/row0trunc.cc2
-rw-r--r--storage/innobase/row/row0umod.cc2
-rw-r--r--storage/innobase/row/row0undo.cc2
-rw-r--r--storage/innobase/row/row0upd.cc2
-rw-r--r--storage/innobase/row/row0vers.cc2
-rw-r--r--storage/innobase/srv/srv0conc.cc4
-rw-r--r--storage/innobase/srv/srv0srv.cc3
-rw-r--r--storage/innobase/srv/srv0start.cc4
-rw-r--r--storage/innobase/sync/sync0arr.cc6
-rw-r--r--storage/innobase/sync/sync0debug.cc3
-rw-r--r--storage/innobase/sync/sync0rw.cc9
-rw-r--r--storage/innobase/trx/trx0i_s.cc9
-rw-r--r--storage/innobase/trx/trx0purge.cc3
-rw-r--r--storage/innobase/trx/trx0rec.cc1
-rw-r--r--storage/innobase/trx/trx0roll.cc6
-rw-r--r--storage/innobase/trx/trx0rseg.cc1
-rw-r--r--storage/innobase/trx/trx0sys.cc3
-rw-r--r--storage/innobase/trx/trx0trx.cc4
-rw-r--r--storage/innobase/trx/trx0undo.cc3
-rw-r--r--storage/innobase/ut/ut0dbg.cc3
-rw-r--r--storage/innobase/ut/ut0new.cc2
-rw-r--r--storage/innobase/ut/ut0rbt.cc3
107 files changed, 47 insertions, 313 deletions
diff --git a/storage/innobase/btr/btr0btr.cc b/storage/innobase/btr/btr0btr.cc
index 696d493e078..d06568535e6 100644
--- a/storage/innobase/btr/btr0btr.cc
+++ b/storage/innobase/btr/btr0btr.cc
@@ -26,9 +26,7 @@ Created 6/2/1994 Heikki Tuuri
*******************************************************/
#include "btr0btr.h"
-#include "ha_prototypes.h"
-#include "fsp0sysspace.h"
#include "page0page.h"
#include "page0zip.h"
#include "gis0rtree.h"
@@ -43,7 +41,6 @@ Created 6/2/1994 Heikki Tuuri
#include "trx0trx.h"
#include "srv0mon.h"
#include "gis0geo.h"
-#include "ut0new.h"
#include "dict0boot.h"
#include "row0sel.h" /* row_search_max_autoinc() */
diff --git a/storage/innobase/buf/buf0buf.cc b/storage/innobase/buf/buf0buf.cc
index be70a723232..2f6eb080958 100644
--- a/storage/innobase/buf/buf0buf.cc
+++ b/storage/innobase/buf/buf0buf.cc
@@ -47,7 +47,6 @@ Created 11/5/1995 Heikki Tuuri
#include "btr0btr.h"
#include "fil0fil.h"
#include "fil0crypt.h"
-#include "fsp0sysspace.h"
#include "buf0buddy.h"
#include "lock0lock.h"
#include "sync0rw.h"
@@ -62,12 +61,10 @@ Created 11/5/1995 Heikki Tuuri
#include "dict0dict.h"
#include "log0recv.h"
#include "srv0mon.h"
-#include "fsp0sysspace.h"
#endif /* !UNIV_INNOCHECKSUM */
#include "page0zip.h"
#include "sync0sync.h"
#include "buf0dump.h"
-#include "ut0new.h"
#include <new>
#include <map>
#include <sstream>
@@ -75,7 +72,6 @@ Created 11/5/1995 Heikki Tuuri
#include "fil0pagecompress.h"
#include "fsp0pagecompress.h"
#endif
-#include "ha_prototypes.h"
#include "ut0byte.h"
#include <new>
diff --git a/storage/innobase/buf/buf0dblwr.cc b/storage/innobase/buf/buf0dblwr.cc
index bed24fd7704..f7b31eefa41 100644
--- a/storage/innobase/buf/buf0dblwr.cc
+++ b/storage/innobase/buf/buf0dblwr.cc
@@ -24,7 +24,6 @@ Doublwrite buffer module
Created 2011/12/19
*******************************************************/
-#include "ha_prototypes.h"
#include "buf0dblwr.h"
#include "buf0buf.h"
#include "buf0checksum.h"
diff --git a/storage/innobase/buf/buf0flu.cc b/storage/innobase/buf/buf0flu.cc
index a73b841b627..a84a79669a7 100644
--- a/storage/innobase/buf/buf0flu.cc
+++ b/storage/innobase/buf/buf0flu.cc
@@ -25,9 +25,8 @@ The database buffer buf_pool flush algorithm
Created 11/11/1995 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
+#include "univ.i"
#include <mysql/service_thd_wait.h>
-#include <my_dbug.h>
#include <sql_class.h>
#include "buf0flu.h"
@@ -47,7 +46,6 @@ Created 11/11/1995 Heikki Tuuri
#include "os0file.h"
#include "trx0sys.h"
#include "srv0mon.h"
-#include "fsp0sysspace.h"
#include "ut0stage.h"
#include "fil0pagecompress.h"
#ifdef UNIV_LINUX
diff --git a/storage/innobase/buf/buf0lru.cc b/storage/innobase/buf/buf0lru.cc
index 331f6d4a3f2..9218ea1b141 100644
--- a/storage/innobase/buf/buf0lru.cc
+++ b/storage/innobase/buf/buf0lru.cc
@@ -44,7 +44,6 @@ Created 11/5/1995 Heikki Tuuri
#include "log0recv.h"
#include "srv0srv.h"
#include "srv0mon.h"
-#include "lock0lock.h"
/** The number of blocks from the LRU_old pointer onward, including
the block pointed to, must be buf_pool->LRU_old_ratio/BUF_LRU_OLD_RATIO_DIV
diff --git a/storage/innobase/buf/buf0rea.cc b/storage/innobase/buf/buf0rea.cc
index 3d5a319a820..372b1c5e0a0 100644
--- a/storage/innobase/buf/buf0rea.cc
+++ b/storage/innobase/buf/buf0rea.cc
@@ -24,7 +24,7 @@ The database buffer read
Created 11/5/1995 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
+#include "univ.i"
#include <mysql/service_thd_wait.h>
#include "buf0rea.h"
diff --git a/storage/innobase/data/data0data.cc b/storage/innobase/data/data0data.cc
index 7fb0eae611c..cd5a8024db1 100644
--- a/storage/innobase/data/data0data.cc
+++ b/storage/innobase/data/data0data.cc
@@ -24,8 +24,6 @@ SQL data field and tuple
Created 5/30/1994 Heikki Tuuri
*************************************************************************/
-#include "ha_prototypes.h"
-
#include "data0data.h"
#include "rem0rec.h"
#include "rem0cmp.h"
diff --git a/storage/innobase/data/data0type.cc b/storage/innobase/data/data0type.cc
index 54cdfa35803..02e79ab6983 100644
--- a/storage/innobase/data/data0type.cc
+++ b/storage/innobase/data/data0type.cc
@@ -24,8 +24,6 @@ Data types
Created 1/16/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "data0type.h"
/* At the database startup we store the default-charset collation number of
diff --git a/storage/innobase/dict/dict0boot.cc b/storage/innobase/dict/dict0boot.cc
index ec53591c323..43c64c86aec 100644
--- a/storage/innobase/dict/dict0boot.cc
+++ b/storage/innobase/dict/dict0boot.cc
@@ -24,8 +24,6 @@ Data dictionary creation and booting
Created 4/18/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "dict0boot.h"
#include "dict0crea.h"
#include "btr0btr.h"
diff --git a/storage/innobase/dict/dict0crea.cc b/storage/innobase/dict/dict0crea.cc
index 758a45de943..d66762a011e 100644
--- a/storage/innobase/dict/dict0crea.cc
+++ b/storage/innobase/dict/dict0crea.cc
@@ -24,8 +24,6 @@ Database object creation
Created 1/8/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "dict0crea.h"
#include "btr0pcur.h"
#include "btr0btr.h"
@@ -42,8 +40,6 @@ Created 1/8/1996 Heikki Tuuri
#include "ut0vec.h"
#include "dict0priv.h"
#include "fts0priv.h"
-#include "fsp0space.h"
-#include "fsp0sysspace.h"
#include "srv0start.h"
/*****************************************************************//**
diff --git a/storage/innobase/dict/dict0defrag_bg.cc b/storage/innobase/dict/dict0defrag_bg.cc
index 69038d4cb77..6347a239812 100644
--- a/storage/innobase/dict/dict0defrag_bg.cc
+++ b/storage/innobase/dict/dict0defrag_bg.cc
@@ -27,11 +27,8 @@ Created 25/08/2016 Jan Lindström
#include "dict0stats.h"
#include "dict0stats_bg.h"
#include "dict0defrag_bg.h"
-#include "row0mysql.h"
+#include "btr0btr.h"
#include "srv0start.h"
-#include "ut0new.h"
-
-#include <vector>
static ib_mutex_t defrag_pool_mutex;
diff --git a/storage/innobase/dict/dict0dict.cc b/storage/innobase/dict/dict0dict.cc
index 436612c195f..914c9946977 100644
--- a/storage/innobase/dict/dict0dict.cc
+++ b/storage/innobase/dict/dict0dict.cc
@@ -60,7 +60,6 @@ ib_warn_row_too_big(const dict_table_t* table);
#include "dict0mem.h"
#include "dict0priv.h"
#include "dict0stats.h"
-#include "fsp0sysspace.h"
#include "fts0fts.h"
#include "fts0types.h"
#include "lock0lock.h"
@@ -81,7 +80,6 @@ ib_warn_row_too_big(const dict_table_t* table);
#include "srv0start.h"
#include "sync0sync.h"
#include "trx0undo.h"
-#include "ut0new.h"
#include <vector>
#include <algorithm>
diff --git a/storage/innobase/dict/dict0load.cc b/storage/innobase/dict/dict0load.cc
index 77415d30643..2fe34886df2 100644
--- a/storage/innobase/dict/dict0load.cc
+++ b/storage/innobase/dict/dict0load.cc
@@ -25,8 +25,6 @@ from dictionary tables
Created 4/24/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "dict0load.h"
#include "mysql_version.h"
@@ -39,7 +37,6 @@ Created 4/24/1996 Heikki Tuuri
#include "dict0priv.h"
#include "dict0stats.h"
#include "fsp0file.h"
-#include "fsp0sysspace.h"
#include "fts0priv.h"
#include "mach0data.h"
#include "page0page.h"
diff --git a/storage/innobase/dict/dict0stats.cc b/storage/innobase/dict/dict0stats.cc
index 2719c7e7222..7f3930ba18b 100644
--- a/storage/innobase/dict/dict0stats.cc
+++ b/storage/innobase/dict/dict0stats.cc
@@ -25,7 +25,6 @@ Created Jan 06, 2010 Vasil Dimov
*******************************************************/
#include "univ.i"
-
#include "ut0ut.h"
#include "ut0rnd.h"
#include "dyn0buf.h"
@@ -33,8 +32,6 @@ Created Jan 06, 2010 Vasil Dimov
#include "trx0trx.h"
#include "pars0pars.h"
#include "dict0stats.h"
-#include "ha_prototypes.h"
-#include "ut0new.h"
#include <mysql_com.h>
#include "btr0btr.h"
diff --git a/storage/innobase/dict/dict0stats_bg.cc b/storage/innobase/dict/dict0stats_bg.cc
index 423558f70c8..55bcafddc70 100644
--- a/storage/innobase/dict/dict0stats_bg.cc
+++ b/storage/innobase/dict/dict0stats_bg.cc
@@ -30,7 +30,6 @@ Created Apr 25, 2012 Vasil Dimov
#include "dict0defrag_bg.h"
#include "row0mysql.h"
#include "srv0start.h"
-#include "ut0new.h"
#include "fil0fil.h"
#ifdef WITH_WSREP
# include "mysql/service_wsrep.h"
diff --git a/storage/innobase/fil/fil0crypt.cc b/storage/innobase/fil/fil0crypt.cc
index 6c32531a07e..77760d7159a 100644
--- a/storage/innobase/fil/fil0crypt.cc
+++ b/storage/innobase/fil/fil0crypt.cc
@@ -39,7 +39,6 @@ Modified Jan Lindström jan.lindstrom@mariadb.com
#include "btr0scrub.h"
#include "fsp0fsp.h"
#include "fil0pagecompress.h"
-#include "ha_prototypes.h" // IB_LOG_
#include <my_crypt.h>
/** Mutex for keys */
diff --git a/storage/innobase/fil/fil0fil.cc b/storage/innobase/fil/fil0fil.cc
index 38ad8caf137..6c5ae70a2cc 100644
--- a/storage/innobase/fil/fil0fil.cc
+++ b/storage/innobase/fil/fil0fil.cc
@@ -33,10 +33,7 @@ Created 10/25/1995 Heikki Tuuri
#include "dict0boot.h"
#include "dict0dict.h"
#include "fsp0file.h"
-#include "fsp0file.h"
#include "fsp0fsp.h"
-#include "fsp0space.h"
-#include "fsp0sysspace.h"
#include "hash0hash.h"
#include "log0log.h"
#include "log0recv.h"
@@ -49,7 +46,6 @@ Created 10/25/1995 Heikki Tuuri
#include "row0trunc.h"
#include "srv0start.h"
#include "trx0purge.h"
-#include "ut0new.h"
#include "buf0lru.h"
#include "ibuf0ibuf.h"
#include "os0event.h"
diff --git a/storage/innobase/fil/fil0pagecompress.cc b/storage/innobase/fil/fil0pagecompress.cc
index 491de512156..1c734f39f15 100644
--- a/storage/innobase/fil/fil0pagecompress.cc
+++ b/storage/innobase/fil/fil0pagecompress.cc
@@ -47,7 +47,6 @@ Updated 14/02/2015
#include "page0zip.h"
#include "trx0sys.h"
#include "row0mysql.h"
-#include "ha_prototypes.h" // IB_LOG_
#include "buf0lru.h"
#include "ibuf0ibuf.h"
#include "sync0sync.h"
diff --git a/storage/innobase/fsp/fsp0file.cc b/storage/innobase/fsp/fsp0file.cc
index 6e9f307ebc8..4a8874d0fa5 100644
--- a/storage/innobase/fsp/fsp0file.cc
+++ b/storage/innobase/fsp/fsp0file.cc
@@ -24,16 +24,11 @@ Tablespace data file implementation
Created 2013-7-26 by Kevin Lewis
*******************************************************/
-#include "ha_prototypes.h"
-
#include "fil0fil.h"
#include "fsp0types.h"
-#include "fsp0sysspace.h"
#include "os0file.h"
#include "page0page.h"
#include "srv0start.h"
-#include "ut0new.h"
-#include "fil0crypt.h"
/** Initialize the name, size and order of this datafile
@param[in] name tablespace name, will be copied
diff --git a/storage/innobase/fsp/fsp0fsp.cc b/storage/innobase/fsp/fsp0fsp.cc
index 7bf31504119..11c5c65d861 100644
--- a/storage/innobase/fsp/fsp0fsp.cc
+++ b/storage/innobase/fsp/fsp0fsp.cc
@@ -24,8 +24,6 @@ File space management
Created 11/29/1995 Heikki Tuuri
***********************************************************************/
-#include "ha_prototypes.h"
-
#include "fsp0fsp.h"
#include "buf0buf.h"
#include "fil0fil.h"
@@ -41,7 +39,6 @@ Created 11/29/1995 Heikki Tuuri
#include "btr0sea.h"
#include "dict0boot.h"
#include "log0log.h"
-#include "fsp0sysspace.h"
#include "dict0mem.h"
#include "fsp0types.h"
diff --git a/storage/innobase/fsp/fsp0space.cc b/storage/innobase/fsp/fsp0space.cc
index 9ca2786b935..df234f7274e 100644
--- a/storage/innobase/fsp/fsp0space.cc
+++ b/storage/innobase/fsp/fsp0space.cc
@@ -24,9 +24,6 @@ Shared tablespace implementation.
Created 2012-11-16 by Sunny Bains as srv/srv0space.cc
*******************************************************/
-#include "ha_prototypes.h"
-
-#include "fsp0space.h"
#include "fsp0sysspace.h"
#include "fsp0fsp.h"
#include "os0file.h"
diff --git a/storage/innobase/fsp/fsp0sysspace.cc b/storage/innobase/fsp/fsp0sysspace.cc
index e9f04cbd6c5..baf864bc1c3 100644
--- a/storage/innobase/fsp/fsp0sysspace.cc
+++ b/storage/innobase/fsp/fsp0sysspace.cc
@@ -24,8 +24,6 @@ Created 2012-11-16 by Sunny Bains as srv/srv0space.cc
Refactored 2013-7-26 by Kevin Lewis
*******************************************************/
-#include "ha_prototypes.h"
-
#include "fsp0sysspace.h"
#include "srv0start.h"
#include "trx0sys.h"
@@ -33,7 +31,6 @@ Refactored 2013-7-26 by Kevin Lewis
#include "mem0mem.h"
#include "os0file.h"
#include "row0mysql.h"
-#include "ut0new.h"
/** The server header file is included to access opt_initialize global variable.
If server passes the option for create/open DB to SE, we should remove such
diff --git a/storage/innobase/fts/fts0ast.cc b/storage/innobase/fts/fts0ast.cc
index d6695cec5be..9a5eb2b49bb 100644
--- a/storage/innobase/fts/fts0ast.cc
+++ b/storage/innobase/fts/fts0ast.cc
@@ -24,8 +24,6 @@ Full Text Search parser helper file.
Created 2007/3/16 Sunny Bains.
***********************************************************************/
-#include "ha_prototypes.h"
-
#include "fts0ast.h"
#include "fts0pars.h"
#include "fts0fts.h"
diff --git a/storage/innobase/fts/fts0fts.cc b/storage/innobase/fts/fts0fts.cc
index aadd0e7a554..7d6dd75ced8 100644
--- a/storage/innobase/fts/fts0fts.cc
+++ b/storage/innobase/fts/fts0fts.cc
@@ -22,8 +22,6 @@ this program; if not, write to the Free Software Foundation, Inc.,
Full Text Search interface
***********************************************************************/
-#include "ha_prototypes.h"
-
#include "trx0roll.h"
#include "row0mysql.h"
#include "row0upd.h"
@@ -40,7 +38,6 @@ Full Text Search interface
#include "dict0stats.h"
#include "btr0pcur.h"
#include "sync0sync.h"
-#include "ut0new.h"
static const ulint FTS_MAX_ID_LEN = 32;
diff --git a/storage/innobase/fts/fts0opt.cc b/storage/innobase/fts/fts0opt.cc
index 9adfb16c438..a87e7091c1a 100644
--- a/storage/innobase/fts/fts0opt.cc
+++ b/storage/innobase/fts/fts0opt.cc
@@ -26,8 +26,6 @@ Completed 2011/7/10 Sunny and Jimmy Yang
***********************************************************************/
-#include "ha_prototypes.h"
-
#include "fts0fts.h"
#include "row0sel.h"
#include "que0types.h"
diff --git a/storage/innobase/fts/fts0que.cc b/storage/innobase/fts/fts0que.cc
index f4f10b7f016..2396a376853 100644
--- a/storage/innobase/fts/fts0que.cc
+++ b/storage/innobase/fts/fts0que.cc
@@ -25,8 +25,6 @@ Created 2007/03/27 Sunny Bains
Completed 2011/7/10 Sunny and Jimmy Yang
*******************************************************/
-#include "ha_prototypes.h"
-
#include "dict0dict.h"
#include "ut0rbt.h"
#include "row0sel.h"
@@ -36,7 +34,6 @@ Completed 2011/7/10 Sunny and Jimmy Yang
#include "fts0pars.h"
#include "fts0types.h"
#include "fts0plugin.h"
-#include "ut0new.h"
#include <iomanip>
#include <vector>
diff --git a/storage/innobase/ha/ha0storage.cc b/storage/innobase/ha/ha0storage.cc
index cde4cc04cb7..a6960675adc 100644
--- a/storage/innobase/ha/ha0storage.cc
+++ b/storage/innobase/ha/ha0storage.cc
@@ -25,7 +25,6 @@ its own storage, avoiding duplicates.
Created September 22, 2007 Vasil Dimov
*******************************************************/
-#include "ha_prototypes.h"
#include "ha0storage.h"
#include "hash0hash.h"
#include "mem0mem.h"
diff --git a/storage/innobase/handler/ha_innodb.cc b/storage/innobase/handler/ha_innodb.cc
index 0b7bc5f16af..e6c57b015a0 100644
--- a/storage/innobase/handler/ha_innodb.cc
+++ b/storage/innobase/handler/ha_innodb.cc
@@ -78,8 +78,6 @@ this program; if not, write to the Free Software Foundation, Inc.,
#include "dict0stats_bg.h"
#include "fil0fil.h"
#include "fsp0fsp.h"
-#include "fsp0space.h"
-#include "fsp0sysspace.h"
#include "fts0fts.h"
#include "fts0plugin.h"
#include "fts0priv.h"
diff --git a/storage/innobase/handler/handler0alter.cc b/storage/innobase/handler/handler0alter.cc
index 7a4d4221e09..632b5dd5a5a 100644
--- a/storage/innobase/handler/handler0alter.cc
+++ b/storage/innobase/handler/handler0alter.cc
@@ -23,7 +23,7 @@ Smart ALTER TABLE
*******************************************************/
/* Include necessary SQL headers */
-#include "ha_prototypes.h"
+#include "univ.i"
#include <debug_sync.h>
#include <log.h>
#include <sql_lex.h>
@@ -38,7 +38,6 @@ Smart ALTER TABLE
#include "dict0priv.h"
#include "dict0stats.h"
#include "dict0stats_bg.h"
-#include "fsp0sysspace.h"
#include "log0log.h"
#include "rem0types.h"
#include "row0log.h"
@@ -52,7 +51,6 @@ Smart ALTER TABLE
#include "pars0pars.h"
#include "row0sel.h"
#include "ha_innodb.h"
-#include "ut0new.h"
#include "ut0stage.h"
static const char *MSG_UNSUPPORTED_ALTER_ONLINE_ON_VIRTUAL_COLUMN=
diff --git a/storage/innobase/handler/i_s.cc b/storage/innobase/handler/i_s.cc
index 064e0e88113..3e5fca6541a 100644
--- a/storage/innobase/handler/i_s.cc
+++ b/storage/innobase/handler/i_s.cc
@@ -25,10 +25,9 @@ Created July 18, 2007 Vasil Dimov
Modified Dec 29, 2014 Jan Lindström (Added sys_semaphore_waits)
*******************************************************/
-#include "ha_prototypes.h"
+#include "univ.i"
#include <mysql_version.h>
#include <field.h>
-#include "univ.i"
#include <sql_acl.h>
#include <sql_show.h>
@@ -58,8 +57,6 @@ Modified Dec 29, 2014 Jan Lindström (Added sys_semaphore_waits)
#include "sync0arr.h"
#include "fil0fil.h"
#include "fil0crypt.h"
-#include "fsp0sysspace.h"
-#include "ut0new.h"
#include "dict0crea.h"
/** structure associates a name string with a file page type and/or buffer
diff --git a/storage/innobase/ibuf/ibuf0ibuf.cc b/storage/innobase/ibuf/ibuf0ibuf.cc
index b45333eba5a..1fd7f7a2241 100644
--- a/storage/innobase/ibuf/ibuf0ibuf.cc
+++ b/storage/innobase/ibuf/ibuf0ibuf.cc
@@ -24,8 +24,6 @@ Insert buffer
Created 7/19/1997 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "ibuf0ibuf.h"
#include "sync0sync.h"
#include "btr0sea.h"
@@ -58,7 +56,6 @@ my_bool srv_ibuf_disable_background_merge;
#include "log0recv.h"
#include "que0que.h"
#include "srv0start.h" /* srv_shutdown_state */
-#include "fsp0sysspace.h"
#include "rem0cmp.h"
/* STRUCTURE OF AN INSERT BUFFER RECORD
diff --git a/storage/innobase/include/btr0bulk.h b/storage/innobase/include/btr0bulk.h
index edf34bd5ae4..a63ab9ded0d 100644
--- a/storage/innobase/include/btr0bulk.h
+++ b/storage/innobase/include/btr0bulk.h
@@ -28,7 +28,6 @@ Created 03/11/2014 Shaohua Wang
#include "dict0dict.h"
#include "page0cur.h"
-#include "ut0new.h"
#include <vector>
diff --git a/storage/innobase/include/buf0buf.ic b/storage/innobase/include/buf0buf.ic
index da7bff31821..91c602f71b0 100644
--- a/storage/innobase/include/buf0buf.ic
+++ b/storage/innobase/include/buf0buf.ic
@@ -35,9 +35,7 @@ Created 11/5/1995 Heikki Tuuri
#include "buf0flu.h"
#include "buf0lru.h"
#include "buf0rea.h"
-#include "sync0debug.h"
#include "fsp0types.h"
-#include "ut0new.h"
/** A chunk of buffers. The buffer pool is allocated in chunks. */
struct buf_chunk_t{
diff --git a/storage/innobase/include/dict0crea.h b/storage/innobase/include/dict0crea.h
index 5d149f24921..c57a63652a2 100644
--- a/storage/innobase/include/dict0crea.h
+++ b/storage/innobase/include/dict0crea.h
@@ -1,7 +1,7 @@
/*****************************************************************************
Copyright (c) 1996, 2016, Oracle and/or its affiliates. All Rights Reserved.
-Copyright (c) 2017, MariaDB Corporation.
+Copyright (c) 2017, 2018, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -34,7 +34,6 @@ Created 1/8/1996 Heikki Tuuri
#include "row0types.h"
#include "mtr0mtr.h"
#include "fil0crypt.h"
-#include "fsp0space.h"
/*********************************************************************//**
Creates a table create graph.
diff --git a/storage/innobase/include/dict0dict.h b/storage/innobase/include/dict0dict.h
index bb4e15ea329..44aff739d93 100644
--- a/storage/innobase/include/dict0dict.h
+++ b/storage/innobase/include/dict0dict.h
@@ -34,7 +34,6 @@ Created 1/8/1996 Heikki Tuuri
#include "dict0mem.h"
#include "dict0types.h"
#include "fsp0fsp.h"
-#include "fsp0sysspace.h"
#include "hash0hash.h"
#include "mem0mem.h"
#include "rem0types.h"
@@ -42,7 +41,6 @@ Created 1/8/1996 Heikki Tuuri
#include "trx0types.h"
#include "ut0byte.h"
#include "ut0mem.h"
-#include "ut0new.h"
#include "ut0rnd.h"
#include <deque>
#include "fsp0fsp.h"
diff --git a/storage/innobase/include/dict0load.h b/storage/innobase/include/dict0load.h
index 9ba42007568..b35add02d9d 100644
--- a/storage/innobase/include/dict0load.h
+++ b/storage/innobase/include/dict0load.h
@@ -28,13 +28,11 @@ Created 4/24/1996 Heikki Tuuri
#ifndef dict0load_h
#define dict0load_h
-#include "univ.i"
#include "dict0types.h"
#include "trx0types.h"
#include "ut0byte.h"
#include "mem0mem.h"
#include "btr0types.h"
-#include "ut0new.h"
#include <deque>
diff --git a/storage/innobase/include/dict0mem.h b/storage/innobase/include/dict0mem.h
index fc120149c5f..671018d20e9 100644
--- a/storage/innobase/include/dict0mem.h
+++ b/storage/innobase/include/dict0mem.h
@@ -47,7 +47,6 @@ Created 1/8/1996 Heikki Tuuri
#include "buf0buf.h"
#include "gis0type.h"
#include "os0once.h"
-#include "ut0new.h"
#include "fil0fil.h"
#include <my_crypt.h>
#include "fil0crypt.h"
diff --git a/storage/innobase/include/fsp0file.h b/storage/innobase/include/fsp0file.h
index 68e9f687fcd..9bc7b4bf9c9 100644
--- a/storage/innobase/include/fsp0file.h
+++ b/storage/innobase/include/fsp0file.h
@@ -27,12 +27,9 @@ Created 2013-7-26 by Kevin Lewis
#ifndef fsp0file_h
#define fsp0file_h
-#include "ha_prototypes.h"
-#include "log0log.h"
#include "mem0mem.h"
#include "os0file.h"
-#include "fil0crypt.h"
-#include <vector>
+#include "fil0fil.h"
/** Types of raw partitions in innodb_data_file_path */
enum device_t {
diff --git a/storage/innobase/include/fsp0fsp.h b/storage/innobase/include/fsp0fsp.h
index 3e4c0368b00..af60383b0ca 100644
--- a/storage/innobase/include/fsp0fsp.h
+++ b/storage/innobase/include/fsp0fsp.h
@@ -33,7 +33,6 @@ Created 12/18/1995 Heikki Tuuri
#ifndef UNIV_INNOCHECKSUM
-#include "fsp0space.h"
#include "fut0lst.h"
#include "mtr0mtr.h"
#include "page0types.h"
diff --git a/storage/innobase/include/fsp0space.h b/storage/innobase/include/fsp0space.h
index 9f869fda158..88e5bb583de 100644
--- a/storage/innobase/include/fsp0space.h
+++ b/storage/innobase/include/fsp0space.h
@@ -27,11 +27,9 @@ Created 2013-7-26 by Kevin Lewis
#ifndef fsp0space_h
#define fsp0space_h
-#include "univ.i"
#include "fsp0file.h"
#include "fsp0fsp.h"
#include "fsp0types.h"
-#include "ut0new.h"
#include <vector>
diff --git a/storage/innobase/include/fsp0sysspace.h b/storage/innobase/include/fsp0sysspace.h
index efbd4fc3f24..a60891c5515 100644
--- a/storage/innobase/include/fsp0sysspace.h
+++ b/storage/innobase/include/fsp0sysspace.h
@@ -26,7 +26,6 @@ Created 2013-7-26 by Kevin Lewis
#ifndef fsp0sysspace_h
#define fsp0sysspace_h
-#include "univ.i"
#include "fsp0space.h"
/** If the last data file is auto-extended, we add this many pages to it
diff --git a/storage/innobase/include/fts0ast.h b/storage/innobase/include/fts0ast.h
index 2a2b25c36bd..0b55d458036 100644
--- a/storage/innobase/include/fts0ast.h
+++ b/storage/innobase/include/fts0ast.h
@@ -27,7 +27,6 @@ Created 2007/03/16/03 Sunny Bains
#ifndef INNOBASE_FST0AST_H
#define INNOBASE_FST0AST_H
-#include "ha_prototypes.h"
#include "mem0mem.h"
#ifdef UNIV_PFS_MEMORY
diff --git a/storage/innobase/include/fts0fts.h b/storage/innobase/include/fts0fts.h
index 11749c991f0..ce628438cb0 100644
--- a/storage/innobase/include/fts0fts.h
+++ b/storage/innobase/include/fts0fts.h
@@ -27,8 +27,6 @@ Created 2011/09/02 Sunny Bains
#ifndef fts0fts_h
#define fts0fts_h
-#include "ha_prototypes.h"
-
#include "data0type.h"
#include "data0types.h"
#include "dict0types.h"
diff --git a/storage/innobase/include/fts0plugin.h b/storage/innobase/include/fts0plugin.h
index 9bc9b6b9dd7..1e822ec3415 100644
--- a/storage/innobase/include/fts0plugin.h
+++ b/storage/innobase/include/fts0plugin.h
@@ -26,7 +26,7 @@ Created 2013/06/04 Shaohua Wang
#ifndef INNOBASE_FTS0PLUGIN_H
#define INNOBASE_FTS0PLUGIN_H
-#include "ha_prototypes.h"
+#include "univ.i"
extern struct st_mysql_ftparser fts_default_parser;
diff --git a/storage/innobase/include/fts0types.ic b/storage/innobase/include/fts0types.ic
index a8712751412..18bc87213fc 100644
--- a/storage/innobase/include/fts0types.ic
+++ b/storage/innobase/include/fts0types.ic
@@ -27,9 +27,6 @@ Created 2007-03-27 Sunny Bains
#ifndef INNOBASE_FTS0TYPES_IC
#define INNOBASE_FTS0TYPES_IC
-#include "rem0cmp.h"
-#include "ha_prototypes.h"
-
/******************************************************************//**
Duplicate a string.
@return < 0 if n1 < n2, 0 if n1 == n2, > 0 if n1 > n2 */
diff --git a/storage/innobase/include/gis0type.h b/storage/innobase/include/gis0type.h
index 14c098f9608..887b06f3613 100644
--- a/storage/innobase/include/gis0type.h
+++ b/storage/innobase/include/gis0type.h
@@ -26,8 +26,6 @@ Created 2013/03/27 Jimmy Yang
#ifndef gis0type_h
#define gis0type_h
-#include "univ.i"
-
#include "buf0buf.h"
#include "data0type.h"
#include "data0types.h"
@@ -41,7 +39,6 @@ Created 2013/03/27 Jimmy Yang
#include "ut0wqueue.h"
#include "que0types.h"
#include "gis0geo.h"
-#include "ut0new.h"
#include <vector>
#include <list>
diff --git a/storage/innobase/include/log0recv.h b/storage/innobase/include/log0recv.h
index d3c891c9cba..267f8f6778d 100644
--- a/storage/innobase/include/log0recv.h
+++ b/storage/innobase/include/log0recv.h
@@ -27,13 +27,11 @@ Created 9/20/1997 Heikki Tuuri
#ifndef log0recv_h
#define log0recv_h
-#include "univ.i"
#include "ut0byte.h"
#include "buf0types.h"
#include "hash0hash.h"
#include "log0log.h"
#include "mtr0types.h"
-#include "ut0new.h"
#include <list>
#include <vector>
diff --git a/storage/innobase/include/mem0mem.ic b/storage/innobase/include/mem0mem.ic
index 4d76f07694d..42dda9e0bb9 100644
--- a/storage/innobase/include/mem0mem.ic
+++ b/storage/innobase/include/mem0mem.ic
@@ -24,8 +24,6 @@ The memory management
Created 6/8/1994 Heikki Tuuri
*************************************************************************/
-#include "ut0new.h"
-
#ifdef UNIV_DEBUG
# define mem_heap_create_block(heap, n, type, file_name, line) \
mem_heap_create_block_func(heap, n, file_name, line, type)
diff --git a/storage/innobase/include/page0types.h b/storage/innobase/include/page0types.h
index fe56468c454..53a03466dde 100644
--- a/storage/innobase/include/page0types.h
+++ b/storage/innobase/include/page0types.h
@@ -29,7 +29,6 @@ Created 2/2/1994 Heikki Tuuri
#include "univ.i"
#include "dict0types.h"
#include "mtr0types.h"
-#include "ut0new.h"
#include <map>
diff --git a/storage/innobase/include/rem0cmp.h b/storage/innobase/include/rem0cmp.h
index 216e3a7655b..899624a003e 100644
--- a/storage/innobase/include/rem0cmp.h
+++ b/storage/innobase/include/rem0cmp.h
@@ -27,12 +27,11 @@ Created 7/1/1994 Heikki Tuuri
#ifndef rem0cmp_h
#define rem0cmp_h
-#include "ha_prototypes.h"
#include "data0data.h"
#include "data0type.h"
-#include "dict0dict.h"
-#include "rem0rec.h"
-#include <my_sys.h>
+#include "dict0types.h"
+#include "rem0types.h"
+#include "page0types.h"
/*************************************************************//**
Returns TRUE if two columns are equal for comparison purposes.
diff --git a/storage/innobase/include/rem0cmp.ic b/storage/innobase/include/rem0cmp.ic
index bf913b93bfb..290c1455f27 100644
--- a/storage/innobase/include/rem0cmp.ic
+++ b/storage/innobase/include/rem0cmp.ic
@@ -24,6 +24,7 @@ Created 7/1/1994 Heikki Tuuri
************************************************************************/
#include <mysql_com.h>
+#include <my_sys.h>
/** Compare two data fields.
@param[in] dfield1 data field; must have type field set
diff --git a/storage/innobase/include/row0mysql.h b/storage/innobase/include/row0mysql.h
index a16fd30c6ea..f3fdf5b4c42 100644
--- a/storage/innobase/include/row0mysql.h
+++ b/storage/innobase/include/row0mysql.h
@@ -28,21 +28,19 @@ Created 9/17/2000 Heikki Tuuri
#ifndef row0mysql_h
#define row0mysql_h
-#include "ha_prototypes.h"
-#include "sql_list.h"
-#include "sql_cmd.h"
-
#include "data0data.h"
#include "que0types.h"
#include "dict0types.h"
#include "trx0types.h"
#include "row0types.h"
-#include "btr0pcur.h"
-#include "trx0types.h"
-#include "fil0crypt.h"
+#include "btr0types.h"
+#include "lock0types.h"
+#include "fil0fil.h"
+#include "fts0fts.h"
+#include "gis0type.h"
-// Forward declaration
-struct SysIndexCallback;
+#include "sql_list.h"
+#include "sql_cmd.h"
extern ibool row_rollback_on_timeout;
diff --git a/storage/innobase/include/row0trunc.h b/storage/innobase/include/row0trunc.h
index 4d6bdee225c..5915596a389 100644
--- a/storage/innobase/include/row0trunc.h
+++ b/storage/innobase/include/row0trunc.h
@@ -31,7 +31,6 @@ Created 2013-04-25 Krunal Bauskar
#include "dict0boot.h"
#include "fil0fil.h"
#include "srv0start.h"
-#include "ut0new.h"
#include <vector>
diff --git a/storage/innobase/include/trx0purge.h b/storage/innobase/include/trx0purge.h
index 8d31a50f028..5aae3a530f7 100644
--- a/storage/innobase/include/trx0purge.h
+++ b/storage/innobase/include/trx0purge.h
@@ -36,6 +36,8 @@ Created 3/26/1996 Heikki Tuuri
#include "fil0fil.h"
#include "read0types.h"
+#include <queue>
+
/** A dummy undo record used as a return value when we have a whole undo log
which needs no purge */
extern trx_undo_rec_t trx_purge_dummy_rec;
diff --git a/storage/innobase/include/trx0trx.h b/storage/innobase/include/trx0trx.h
index 917222477b1..440f4101c5c 100644
--- a/storage/innobase/include/trx0trx.h
+++ b/storage/innobase/include/trx0trx.h
@@ -27,21 +27,19 @@ Created 3/26/1996 Heikki Tuuri
#ifndef trx0trx_h
#define trx0trx_h
-#include <set>
-
-#include "ha_prototypes.h"
-
#include "dict0types.h"
#include "trx0types.h"
#include "lock0types.h"
-#include "log0log.h"
#include "que0types.h"
#include "mem0mem.h"
#include "trx0xa.h"
#include "ut0vec.h"
#include "fts0fts.h"
+#include <vector>
+#include <set>
+
// Forward declaration
struct mtr_t;
diff --git a/storage/innobase/include/trx0types.h b/storage/innobase/include/trx0types.h
index b42871bef31..de26de44193 100644
--- a/storage/innobase/include/trx0types.h
+++ b/storage/innobase/include/trx0types.h
@@ -29,10 +29,8 @@ Created 3/26/1996 Heikki Tuuri
#include "ut0byte.h"
#include "ut0mutex.h"
-#include "ut0new.h"
#include <set>
-#include <queue>
#include <vector>
//#include <unordered_set>
diff --git a/storage/innobase/include/ut0mutex.h b/storage/innobase/include/ut0mutex.h
index dc387dadbdc..3dbd7919a2f 100644
--- a/storage/innobase/include/ut0mutex.h
+++ b/storage/innobase/include/ut0mutex.h
@@ -29,12 +29,8 @@ Created 2012-03-24 Sunny Bains.
#ifndef ut0mutex_h
#define ut0mutex_h
-extern uint srv_spin_wait_delay;
-extern ulong srv_n_spin_wait_rounds;
-
#include "sync0policy.h"
#include "ib0mutex.h"
-#include <set>
/** Create a typedef using the MutexType<PolicyType>
@param[in] M Mutex type
diff --git a/storage/innobase/include/ut0new.h b/storage/innobase/include/ut0new.h
index 955e7b026c7..86fcbd59418 100644
--- a/storage/innobase/include/ut0new.h
+++ b/storage/innobase/include/ut0new.h
@@ -1,7 +1,7 @@
/*****************************************************************************
Copyright (c) 2014, 2015, Oracle and/or its affiliates. All Rights Reserved.
-Copyright (c) 2017, MariaDB Corporation.
+Copyright (c) 2017, 2018, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -136,8 +136,6 @@ InnoDB:
#include "mysql/psi/psi_memory.h" /* PSI_memory_key, PSI_memory_info */
-#include "univ.i"
-
#include "os0proc.h" /* os_mem_alloc_large() */
#include "os0thread.h" /* os_thread_sleep() */
#include "ut0ut.h" /* ut_strcmp_functor, ut_basename_noext() */
diff --git a/storage/innobase/include/ut0vec.ic b/storage/innobase/include/ut0vec.ic
index 17f4df579b6..bf774c84683 100644
--- a/storage/innobase/include/ut0vec.ic
+++ b/storage/innobase/include/ut0vec.ic
@@ -23,8 +23,6 @@ A vector of pointers to data items
Created 4/6/2006 Osku Salerma
************************************************************************/
-#include "ut0new.h"
-
#define IB_VEC_OFFSET(v, i) (vec->sizeof_value * i)
/********************************************************************
diff --git a/storage/innobase/lock/lock0lock.cc b/storage/innobase/lock/lock0lock.cc
index a9cc8ab1901..c2a0494a5d7 100644
--- a/storage/innobase/lock/lock0lock.cc
+++ b/storage/innobase/lock/lock0lock.cc
@@ -26,8 +26,7 @@ Created 5/7/1996 Heikki Tuuri
#define LOCK_MODULE_IMPLEMENTATION
-
-#include "ha_prototypes.h"
+#include "univ.i"
#include <mysql/service_thd_error_context.h>
#include <sql_class.h>
@@ -37,11 +36,8 @@ Created 5/7/1996 Heikki Tuuri
#include "dict0mem.h"
#include "trx0purge.h"
#include "trx0sys.h"
-#include "srv0mon.h"
#include "ut0vec.h"
-#include "btr0btr.h"
-#include "dict0boot.h"
-#include "ut0new.h"
+#include "btr0cur.h"
#include "row0sel.h"
#include "row0mysql.h"
#include "row0vers.h"
diff --git a/storage/innobase/lock/lock0prdt.cc b/storage/innobase/lock/lock0prdt.cc
index 5843508741d..a179b0719cf 100644
--- a/storage/innobase/lock/lock0prdt.cc
+++ b/storage/innobase/lock/lock0prdt.cc
@@ -29,17 +29,8 @@ Created 9/7/2013 Jimmy Yang
#include "lock0lock.h"
#include "lock0priv.h"
#include "lock0prdt.h"
-#include "ha_prototypes.h"
-#include "trx0purge.h"
#include "dict0mem.h"
-#include "dict0boot.h"
-#include "trx0sys.h"
-#include "srv0mon.h"
-#include "ut0vec.h"
-#include "btr0btr.h"
-#include "dict0boot.h"
#include "que0que.h"
-#include <set>
/*********************************************************************//**
Get a minimum bounding box from a Predicate
diff --git a/storage/innobase/lock/lock0wait.cc b/storage/innobase/lock/lock0wait.cc
index d6c812e1af0..055c67bacc3 100644
--- a/storage/innobase/lock/lock0wait.cc
+++ b/storage/innobase/lock/lock0wait.cc
@@ -26,7 +26,7 @@ Created 25/5/2010 Sunny Bains
#define LOCK_MODULE_IMPLEMENTATION
-#include "ha_prototypes.h"
+#include "univ.i"
#include <mysql/service_thd_wait.h>
#include <mysql/service_wsrep.h>
diff --git a/storage/innobase/log/log0log.cc b/storage/innobase/log/log0log.cc
index 8fa8662ca31..4a789382004 100644
--- a/storage/innobase/log/log0log.cc
+++ b/storage/innobase/log/log0log.cc
@@ -31,7 +31,7 @@ Database log
Created 12/9/1995 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
+#include "univ.i"
#include <debug_sync.h>
#include <my_service_manager.h>
diff --git a/storage/innobase/log/log0recv.cc b/storage/innobase/log/log0recv.cc
index 42623aa9655..f8e9a64f9d4 100644
--- a/storage/innobase/log/log0recv.cc
+++ b/storage/innobase/log/log0recv.cc
@@ -25,7 +25,7 @@ Recovery
Created 9/20/1997 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
+#include "univ.i"
#include <vector>
#include <map>
@@ -52,8 +52,6 @@ Created 9/20/1997 Heikki Tuuri
#include "trx0undo.h"
#include "trx0rec.h"
#include "fil0fil.h"
-#include "fsp0sysspace.h"
-#include "ut0new.h"
#include "row0trunc.h"
#include "buf0rea.h"
#include "srv0srv.h"
diff --git a/storage/innobase/mem/mem0mem.cc b/storage/innobase/mem/mem0mem.cc
index c101980d543..b4f1dd0602f 100644
--- a/storage/innobase/mem/mem0mem.cc
+++ b/storage/innobase/mem/mem0mem.cc
@@ -24,8 +24,6 @@ The memory management
Created 6/9/1994 Heikki Tuuri
*************************************************************************/
-#include "ha_prototypes.h"
-
#include "mem0mem.h"
#include "buf0buf.h"
#include "srv0srv.h"
diff --git a/storage/innobase/mtr/mtr0mtr.cc b/storage/innobase/mtr/mtr0mtr.cc
index 9367d537424..dafa41e7a9c 100644
--- a/storage/innobase/mtr/mtr0mtr.cc
+++ b/storage/innobase/mtr/mtr0mtr.cc
@@ -28,7 +28,6 @@ Created 11/26/1995 Heikki Tuuri
#include "buf0buf.h"
#include "buf0flu.h"
-#include "fsp0sysspace.h"
#include "page0types.h"
#include "mtr0log.h"
#include "log0log.h"
diff --git a/storage/innobase/os/os0event.cc b/storage/innobase/os/os0event.cc
index b687af3e21c..71b86df24a4 100644
--- a/storage/innobase/os/os0event.cc
+++ b/storage/innobase/os/os0event.cc
@@ -25,8 +25,6 @@ Created 2012-09-23 Sunny Bains
#include "os0event.h"
#include "ut0mutex.h"
-#include "ha_prototypes.h"
-#include "ut0new.h"
#ifdef _WIN32
#include <windows.h>
diff --git a/storage/innobase/os/os0file.cc b/storage/innobase/os/os0file.cc
index 4d71eaf552b..26cc70e6e41 100644
--- a/storage/innobase/os/os0file.cc
+++ b/storage/innobase/os/os0file.cc
@@ -34,11 +34,8 @@ Created 10/21/1995 Heikki Tuuri
*******************************************************/
#ifndef UNIV_INNOCHECKSUM
-
-#include "ha_prototypes.h"
-#include "sql_const.h"
-
#include "os0file.h"
+#include "sql_const.h"
#ifdef UNIV_LINUX
#include <sys/types.h>
@@ -48,9 +45,6 @@ Created 10/21/1995 Heikki Tuuri
#include "srv0srv.h"
#include "srv0start.h"
#include "fil0fil.h"
-#include "fil0crypt.h"
-#include "fsp0fsp.h"
-#include "fil0pagecompress.h"
#include "srv0srv.h"
#ifdef HAVE_LINUX_UNISTD_H
#include "unistd.h"
diff --git a/storage/innobase/os/os0proc.cc b/storage/innobase/os/os0proc.cc
index 22966690ab0..1a6da03a402 100644
--- a/storage/innobase/os/os0proc.cc
+++ b/storage/innobase/os/os0proc.cc
@@ -24,12 +24,7 @@ process control primitives
Created 9/30/1995 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
-#include "os0proc.h"
-#include "srv0srv.h"
-#include "ut0mem.h"
-#include "ut0byte.h"
+#include "univ.i"
/* FreeBSD for example has only MAP_ANON, Linux has MAP_ANONYMOUS and
MAP_ANON but MAP_ANON is marked as deprecated */
diff --git a/storage/innobase/os/os0thread.cc b/storage/innobase/os/os0thread.cc
index 3986c4f4c44..e0d96276b55 100644
--- a/storage/innobase/os/os0thread.cc
+++ b/storage/innobase/os/os0thread.cc
@@ -1,7 +1,7 @@
/*****************************************************************************
Copyright (c) 1995, 2016, Oracle and/or its affiliates. All Rights Reserved.
-Copyright (c) 2017, MariaDB Corporation.
+Copyright (c) 2017, 2018, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -24,13 +24,9 @@ The interface to the operating system thread control primitives
Created 9/8/1995 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
+#include "univ.i"
#include "os0thread.h"
-#include "ut0new.h"
#include "srv0srv.h"
-#include "os0event.h"
-#include <map>
/** Number of threads active. */
ulint os_thread_count;
diff --git a/storage/innobase/page/page0cur.cc b/storage/innobase/page/page0cur.cc
index 6bdb7f56842..2327d11f1fa 100644
--- a/storage/innobase/page/page0cur.cc
+++ b/storage/innobase/page/page0cur.cc
@@ -25,8 +25,6 @@ The page cursor
Created 10/4/1994 Heikki Tuuri
*************************************************************************/
-#include "ha_prototypes.h"
-
#include "page0cur.h"
#include "page0zip.h"
#include "btr0btr.h"
diff --git a/storage/innobase/pars/pars0opt.cc b/storage/innobase/pars/pars0opt.cc
index f08037d15aa..934cd80fd14 100644
--- a/storage/innobase/pars/pars0opt.cc
+++ b/storage/innobase/pars/pars0opt.cc
@@ -33,7 +33,6 @@ Created 12/21/1997 Heikki Tuuri
#include "que0que.h"
#include "pars0grm.h"
#include "pars0pars.h"
-#include "lock0lock.h"
#define OPT_EQUAL 1 /* comparison by = */
#define OPT_COMPARISON 2 /* comparison by <, >, <=, or >= */
diff --git a/storage/innobase/pars/pars0pars.cc b/storage/innobase/pars/pars0pars.cc
index 56ca037f247..d7447810912 100644
--- a/storage/innobase/pars/pars0pars.cc
+++ b/storage/innobase/pars/pars0pars.cc
@@ -26,8 +26,6 @@ Created 11/19/1996 Heikki Tuuri
/* Historical note: Innobase executed its first SQL string (CREATE TABLE)
on 1/27/1998 */
-#include "ha_prototypes.h"
-
#include "pars0pars.h"
#include "row0sel.h"
#include "row0ins.h"
@@ -42,7 +40,6 @@ on 1/27/1998 */
#include "data0type.h"
#include "trx0trx.h"
#include "trx0roll.h"
-#include "lock0lock.h"
#include "eval0eval.h"
/* Global variable used while parsing a single procedure or query : the code is
diff --git a/storage/innobase/que/que0que.cc b/storage/innobase/que/que0que.cc
index 99d8c70a2c0..05964403543 100644
--- a/storage/innobase/que/que0que.cc
+++ b/storage/innobase/que/que0que.cc
@@ -24,8 +24,6 @@ Query graph
Created 5/27/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "que0que.h"
#include "trx0trx.h"
#include "trx0roll.h"
@@ -37,9 +35,6 @@ Created 5/27/1996 Heikki Tuuri
#include "dict0crea.h"
#include "log0log.h"
#include "eval0proc.h"
-#include "lock0lock.h"
-#include "eval0eval.h"
-#include "pars0types.h"
#define QUE_MAX_LOOPS_WITHOUT_CHECK 16
diff --git a/storage/innobase/rem/rem0cmp.cc b/storage/innobase/rem/rem0cmp.cc
index 0e2bc9b30de..62581bbac38 100644
--- a/storage/innobase/rem/rem0cmp.cc
+++ b/storage/innobase/rem/rem0cmp.cc
@@ -23,17 +23,10 @@ Comparison services for records
Created 7/1/1994 Heikki Tuuri
************************************************************************/
-#include "ha_prototypes.h"
-
#include "rem0cmp.h"
+#include "rem0rec.h"
+#include "dict0mem.h"
#include "handler0alter.h"
-#include "srv0srv.h"
-
-#include <gstream.h>
-#include <spatial.h>
-#include <gis0geo.h>
-#include <page0cur.h>
-#include <algorithm>
/* ALPHABETICAL ORDER
==================
diff --git a/storage/innobase/rem/rem0rec.cc b/storage/innobase/rem/rem0rec.cc
index 562dc53e9f8..35b0235b8ec 100644
--- a/storage/innobase/rem/rem0rec.cc
+++ b/storage/innobase/rem/rem0rec.cc
@@ -26,15 +26,9 @@ Created 5/30/1994 Heikki Tuuri
#include "rem0rec.h"
#include "page0page.h"
-#include "mtr0mtr.h"
#include "mtr0log.h"
#include "fts0fts.h"
-#ifdef WITH_WSREP
-#include <ha_prototypes.h>
-#endif /* WITH_WSREP */
-#include "gis0geo.h"
#include "trx0sys.h"
-#include "mach0data.h"
/* PHYSICAL RECORD (OLD STYLE)
===========================
@@ -2201,6 +2195,8 @@ rec_offs_make_nth_extern(
rec_offs_base(offsets)[1 + n] |= REC_OFFS_EXTERNAL;
}
#ifdef WITH_WSREP
+# include "ha_prototypes.h"
+
int
wsrep_rec_get_foreign_key(
byte *buf, /* out: extracted key */
diff --git a/storage/innobase/row/row0ftsort.cc b/storage/innobase/row/row0ftsort.cc
index 507b7c25ed4..810b5387aec 100644
--- a/storage/innobase/row/row0ftsort.cc
+++ b/storage/innobase/row/row0ftsort.cc
@@ -24,16 +24,11 @@ Create Full Text Index with (parallel) merge sort
Created 10/13/2010 Jimmy Yang
*******************************************************/
-#include "ha_prototypes.h"
-
-#include "dict0dict.h"
-#include "row0merge.h"
-#include "pars0pars.h"
#include "row0ftsort.h"
+#include "dict0dict.h"
#include "row0merge.h"
#include "row0row.h"
#include "btr0cur.h"
-#include "btr0bulk.h"
#include "fts0plugin.h"
#include "log0crypt.h"
diff --git a/storage/innobase/row/row0import.cc b/storage/innobase/row/row0import.cc
index 71520dd1b84..66807ced2c1 100644
--- a/storage/innobase/row/row0import.cc
+++ b/storage/innobase/row/row0import.cc
@@ -24,11 +24,8 @@ Import a tablespace to a running instance.
Created 2012-02-08 by Sunny Bains.
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0import.h"
#include "btr0pcur.h"
-#include "btr0sea.h"
#include "que0que.h"
#include "dict0boot.h"
#include "ibuf0ibuf.h"
@@ -39,7 +36,6 @@ Created 2012-02-08 by Sunny Bains.
#include "srv0start.h"
#include "row0quiesce.h"
#include "fil0pagecompress.h"
-#include "ut0new.h"
#ifdef HAVE_LZO
#include "lzo/lzo1x.h"
#endif
diff --git a/storage/innobase/row/row0ins.cc b/storage/innobase/row/row0ins.cc
index 3362e5302b1..2db545973a3 100644
--- a/storage/innobase/row/row0ins.cc
+++ b/storage/innobase/row/row0ins.cc
@@ -24,11 +24,8 @@ Insert into a table
Created 4/20/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0ins.h"
#include "dict0dict.h"
-#include "dict0boot.h"
#include "trx0rec.h"
#include "trx0undo.h"
#include "btr0btr.h"
@@ -38,7 +35,6 @@ Created 4/20/1996 Heikki Tuuri
#include "que0que.h"
#include "row0upd.h"
#include "row0sel.h"
-#include "row0row.h"
#include "row0log.h"
#include "rem0cmp.h"
#include "lock0lock.h"
@@ -48,8 +44,6 @@ Created 4/20/1996 Heikki Tuuri
#include "buf0lru.h"
#include "fts0fts.h"
#include "fts0types.h"
-#include "m_string.h"
-#include "gis0geo.h"
/*************************************************************************
IMPORTANT NOTE: Any operation that generates redo MUST check that there
diff --git a/storage/innobase/row/row0log.cc b/storage/innobase/row/row0log.cc
index 7e6760da372..16a71fbe896 100644
--- a/storage/innobase/row/row0log.cc
+++ b/storage/innobase/row/row0log.cc
@@ -35,7 +35,6 @@ Created 2011-05-26 Marko Makela
#include "que0que.h"
#include "srv0mon.h"
#include "handler0alter.h"
-#include "ut0new.h"
#include "ut0stage.h"
#include "trx0rec.h"
diff --git a/storage/innobase/row/row0merge.cc b/storage/innobase/row/row0merge.cc
index 953f3070a11..f623cfb6df4 100644
--- a/storage/innobase/row/row0merge.cc
+++ b/storage/innobase/row/row0merge.cc
@@ -30,8 +30,6 @@ Completed by Sunny Bains and Marko Makela
#include <math.h>
-#include "ha_prototypes.h"
-
#include "row0merge.h"
#include "row0ext.h"
#include "row0log.h"
@@ -49,8 +47,6 @@ Completed by Sunny Bains and Marko Makela
#include "row0vers.h"
#include "handler0alter.h"
#include "btr0bulk.h"
-#include "fsp0sysspace.h"
-#include "ut0new.h"
#include "ut0stage.h"
#include "fil0crypt.h"
diff --git a/storage/innobase/row/row0mysql.cc b/storage/innobase/row/row0mysql.cc
index 4b20d378473..b098617afda 100644
--- a/storage/innobase/row/row0mysql.cc
+++ b/storage/innobase/row/row0mysql.cc
@@ -25,7 +25,7 @@ Contains also create table and other data dictionary operations.
Created 9/17/2000 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
+#include "univ.i"
#include <debug_sync.h>
#include <gstream.h>
#include <spatial.h>
@@ -46,7 +46,6 @@ Created 9/17/2000 Heikki Tuuri
#include "fil0fil.h"
#include "fil0crypt.h"
#include "fsp0file.h"
-#include "fsp0sysspace.h"
#include "fts0fts.h"
#include "fts0types.h"
#include "ibuf0ibuf.h"
@@ -68,7 +67,6 @@ Created 9/17/2000 Heikki Tuuri
#include "srv0start.h"
#include "row0ext.h"
#include "srv0start.h"
-#include "ut0new.h"
#include <algorithm>
#include <deque>
diff --git a/storage/innobase/row/row0quiesce.cc b/storage/innobase/row/row0quiesce.cc
index de71c786fd8..865780c3df5 100644
--- a/storage/innobase/row/row0quiesce.cc
+++ b/storage/innobase/row/row0quiesce.cc
@@ -24,14 +24,11 @@ Quiesce a tablespace.
Created 2012-02-08 by Sunny Bains.
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0quiesce.h"
#include "row0mysql.h"
#include "ibuf0ibuf.h"
#include "srv0start.h"
#include "trx0purge.h"
-#include "fsp0sysspace.h"
#ifdef HAVE_MY_AES_H
#include <my_aes.h>
diff --git a/storage/innobase/row/row0row.cc b/storage/innobase/row/row0row.cc
index 4c88130334e..a01238fd21a 100644
--- a/storage/innobase/row/row0row.cc
+++ b/storage/innobase/row/row0row.cc
@@ -24,8 +24,6 @@ General row routines
Created 4/20/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0row.h"
#include "data0type.h"
#include "dict0dict.h"
diff --git a/storage/innobase/row/row0sel.cc b/storage/innobase/row/row0sel.cc
index 5d142c24490..e27b1b9df77 100644
--- a/storage/innobase/row/row0sel.cc
+++ b/storage/innobase/row/row0sel.cc
@@ -54,9 +54,7 @@ Created 12/19/1997 Heikki Tuuri
#include "read0read.h"
#include "buf0lru.h"
#include "srv0srv.h"
-#include "ha_prototypes.h"
#include "srv0mon.h"
-#include "ut0new.h"
/* Maximum number of rows to prefetch; MySQL interface has another parameter */
#define SEL_MAX_N_PREFETCH 16
diff --git a/storage/innobase/row/row0trunc.cc b/storage/innobase/row/row0trunc.cc
index c6c752a92b8..c326a9468a0 100644
--- a/storage/innobase/row/row0trunc.cc
+++ b/storage/innobase/row/row0trunc.cc
@@ -26,13 +26,13 @@ Created 2013-04-12 Sunny Bains
#include "row0mysql.h"
#include "pars0pars.h"
+#include "btr0pcur.h"
#include "dict0crea.h"
#include "dict0boot.h"
#include "dict0stats.h"
#include "dict0stats_bg.h"
#include "lock0lock.h"
#include "fts0fts.h"
-#include "fsp0sysspace.h"
#include "srv0start.h"
#include "row0trunc.h"
#include "os0file.h"
diff --git a/storage/innobase/row/row0umod.cc b/storage/innobase/row/row0umod.cc
index 3b87c3ae1b7..4ed4e74fce3 100644
--- a/storage/innobase/row/row0umod.cc
+++ b/storage/innobase/row/row0umod.cc
@@ -24,8 +24,6 @@ Undo modify of a row
Created 2/27/1997 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0umod.h"
#include "dict0dict.h"
#include "dict0stats.h"
diff --git a/storage/innobase/row/row0undo.cc b/storage/innobase/row/row0undo.cc
index 9f5d05f8f9f..3f960235f3e 100644
--- a/storage/innobase/row/row0undo.cc
+++ b/storage/innobase/row/row0undo.cc
@@ -24,8 +24,6 @@ Row undo
Created 1/8/1997 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0undo.h"
#include "fsp0fsp.h"
#include "mach0data.h"
diff --git a/storage/innobase/row/row0upd.cc b/storage/innobase/row/row0upd.cc
index 28658428e98..ccb18cb843b 100644
--- a/storage/innobase/row/row0upd.cc
+++ b/storage/innobase/row/row0upd.cc
@@ -24,8 +24,6 @@ Update of a row
Created 12/27/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0upd.h"
#include "dict0dict.h"
#include "dict0mem.h"
diff --git a/storage/innobase/row/row0vers.cc b/storage/innobase/row/row0vers.cc
index 811654fdef8..30aa44dcb33 100644
--- a/storage/innobase/row/row0vers.cc
+++ b/storage/innobase/row/row0vers.cc
@@ -24,8 +24,6 @@ Row versions
Created 2/6/1997 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "row0vers.h"
#include "dict0dict.h"
#include "dict0boot.h"
diff --git a/storage/innobase/srv/srv0conc.cc b/storage/innobase/srv/srv0conc.cc
index a1ffa8986a8..9e2aa7d7af4 100644
--- a/storage/innobase/srv/srv0conc.cc
+++ b/storage/innobase/srv/srv0conc.cc
@@ -38,13 +38,11 @@ InnoDB concurrency manager
Created 2011/04/18 Sunny Bains
*******************************************************/
-#include "ha_prototypes.h"
-#include <mysql/service_thd_wait.h>
-
#include "srv0srv.h"
#include "trx0trx.h"
#include "row0mysql.h"
#include "dict0dict.h"
+#include <mysql/service_thd_wait.h>
#include <mysql/service_wsrep.h>
/** Number of times a thread is allowed to enter InnoDB within the same
diff --git a/storage/innobase/srv/srv0srv.cc b/storage/innobase/srv/srv0srv.cc
index 0aebdb1cfd3..08d201511da 100644
--- a/storage/innobase/srv/srv0srv.cc
+++ b/storage/innobase/srv/srv0srv.cc
@@ -46,14 +46,11 @@ Created 10/8/1995 Heikki Tuuri
// #include "mysql/psi/mysql_stage.h"
// #include "mysql/psi/psi.h"
-#include "ha_prototypes.h"
-
#include "btr0sea.h"
#include "buf0flu.h"
#include "buf0lru.h"
#include "dict0boot.h"
#include "dict0load.h"
-#include "fsp0sysspace.h"
#include "ibuf0ibuf.h"
#include "lock0lock.h"
#include "log0recv.h"
diff --git a/storage/innobase/srv/srv0start.cc b/storage/innobase/srv/srv0start.cc
index 5cb3f6572c0..8719d26d5f3 100644
--- a/storage/innobase/srv/srv0start.cc
+++ b/storage/innobase/srv/srv0start.cc
@@ -41,8 +41,6 @@ Created 2/16/1996 Heikki Tuuri
#include "my_global.h"
-#include "ha_prototypes.h"
-
#include "mysqld.h"
#include "mysql/psi/mysql_stage.h"
#include "mysql/psi/psi.h"
@@ -76,7 +74,6 @@ Created 2/16/1996 Heikki Tuuri
#include "srv0start.h"
#include "srv0srv.h"
#include "btr0defragment.h"
-#include "fsp0sysspace.h"
#include "row0trunc.h"
#include "mysql/service_wsrep.h" /* wsrep_recovery */
#include "trx0rseg.h"
@@ -107,7 +104,6 @@ Created 2/16/1996 Heikki Tuuri
#include "zlib.h"
#include "ut0crc32.h"
#include "btr0scrub.h"
-#include "ut0new.h"
/** Log sequence number immediately after startup */
lsn_t srv_start_lsn;
diff --git a/storage/innobase/sync/sync0arr.cc b/storage/innobase/sync/sync0arr.cc
index f1589e1f3a7..183aa09dc2b 100644
--- a/storage/innobase/sync/sync0arr.cc
+++ b/storage/innobase/sync/sync0arr.cc
@@ -31,7 +31,6 @@ The wait array used in synchronization primitives
Created 9/5/1995 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
#include "sync0arr.h"
#include <mysqld_error.h>
#include <mysql/plugin.h>
@@ -46,13 +45,8 @@ Created 9/5/1995 Heikki Tuuri
#include <sql_plugin.h>
#include <innodb_priv.h>
-#include "sync0sync.h"
#include "lock0lock.h"
#include "sync0rw.h"
-#include "sync0debug.h"
-#include "os0event.h"
-#include "os0file.h"
-#include "srv0srv.h"
/*
WAIT ARRAY
diff --git a/storage/innobase/sync/sync0debug.cc b/storage/innobase/sync/sync0debug.cc
index d41d52b2f7d..deb081a6819 100644
--- a/storage/innobase/sync/sync0debug.cc
+++ b/storage/innobase/sync/sync0debug.cc
@@ -32,11 +32,8 @@ Created 2012-08-21 Sunny Bains
#include "sync0sync.h"
#include "sync0debug.h"
-
-#include "ut0new.h"
#include "srv0start.h"
-#include <map>
#include <vector>
#include <string>
#include <algorithm>
diff --git a/storage/innobase/sync/sync0rw.cc b/storage/innobase/sync/sync0rw.cc
index 22d94af0a6c..31a8234dea7 100644
--- a/storage/innobase/sync/sync0rw.cc
+++ b/storage/innobase/sync/sync0rw.cc
@@ -32,15 +32,6 @@ Created 9/11/1995 Heikki Tuuri
*******************************************************/
#include "sync0rw.h"
-#include "ha_prototypes.h"
-
-#include "os0thread.h"
-#include "mem0mem.h"
-#include "srv0srv.h"
-#include "os0event.h"
-#include "srv0mon.h"
-#include "sync0debug.h"
-#include "ha_prototypes.h"
#include "my_cpu.h"
#include <my_sys.h>
diff --git a/storage/innobase/trx/trx0i_s.cc b/storage/innobase/trx/trx0i_s.cc
index 363b61b0cfe..374c7b12db1 100644
--- a/storage/innobase/trx/trx0i_s.cc
+++ b/storage/innobase/trx/trx0i_s.cc
@@ -36,9 +36,7 @@ Created July 17, 2007 Vasil Dimov
From the symptoms, this is related to bug#46587 in the MySQL bug DB.
*/
-#include "ha_prototypes.h"
-#include <sql_class.h>
-
+#include "trx0i_s.h"
#include "buf0buf.h"
#include "dict0dict.h"
#include "ha0storage.h"
@@ -52,10 +50,9 @@ Created July 17, 2007 Vasil Dimov
#include "srv0srv.h"
#include "sync0rw.h"
#include "sync0sync.h"
-#include "trx0i_s.h"
#include "trx0sys.h"
-#include "trx0trx.h"
-#include "ut0mem.h"
+
+#include <sql_class.h>
/** Initial number of rows in the table cache */
#define TABLE_CACHE_INITIAL_ROWSNUM 1024
diff --git a/storage/innobase/trx/trx0purge.cc b/storage/innobase/trx/trx0purge.cc
index c20001c8df0..c4f272acf07 100644
--- a/storage/innobase/trx/trx0purge.cc
+++ b/storage/innobase/trx/trx0purge.cc
@@ -24,8 +24,6 @@ Purge old versions
Created 3/26/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "trx0purge.h"
#include "fsp0fsp.h"
#include "fut0fut.h"
@@ -37,7 +35,6 @@ Created 3/26/1996 Heikki Tuuri
#include "row0purge.h"
#include "row0upd.h"
#include "srv0mon.h"
-#include "fsp0sysspace.h"
#include "srv0srv.h"
#include "srv0start.h"
#include "sync0sync.h"
diff --git a/storage/innobase/trx/trx0rec.cc b/storage/innobase/trx/trx0rec.cc
index 9c0008831a8..e700d5e0f58 100644
--- a/storage/innobase/trx/trx0rec.cc
+++ b/storage/innobase/trx/trx0rec.cc
@@ -38,7 +38,6 @@ Created 3/26/1996 Heikki Tuuri
#include "trx0purge.h"
#include "trx0rseg.h"
#include "row0row.h"
-#include "fsp0sysspace.h"
#include "row0mysql.h"
/*=========== UNDO LOG RECORD CREATION AND DECODING ====================*/
diff --git a/storage/innobase/trx/trx0roll.cc b/storage/innobase/trx/trx0roll.cc
index 2c14c9d895a..0e277c67453 100644
--- a/storage/innobase/trx/trx0roll.cc
+++ b/storage/innobase/trx/trx0roll.cc
@@ -24,12 +24,9 @@ Transaction rollback
Created 3/26/1996 Heikki Tuuri
*******************************************************/
-#include "my_config.h"
-#include <my_service_manager.h>
-
-#include "ha_prototypes.h"
#include "trx0roll.h"
+#include <my_service_manager.h>
#include <mysql/service_wsrep.h>
#include "fsp0fsp.h"
@@ -47,7 +44,6 @@ Created 3/26/1996 Heikki Tuuri
#include "trx0sys.h"
#include "trx0trx.h"
#include "trx0undo.h"
-#include "ha_prototypes.h"
/** This many pages must be undone before a truncate is tried within
rollback */
diff --git a/storage/innobase/trx/trx0rseg.cc b/storage/innobase/trx/trx0rseg.cc
index 1c2d708ed4b..3d5320cdd15 100644
--- a/storage/innobase/trx/trx0rseg.cc
+++ b/storage/innobase/trx/trx0rseg.cc
@@ -30,7 +30,6 @@ Created 3/26/1996 Heikki Tuuri
#include "srv0srv.h"
#include "trx0purge.h"
#include "srv0mon.h"
-#include "fsp0sysspace.h"
#include <algorithm>
diff --git a/storage/innobase/trx/trx0sys.cc b/storage/innobase/trx/trx0sys.cc
index e2e42dc6569..f4c043a3ca9 100644
--- a/storage/innobase/trx/trx0sys.cc
+++ b/storage/innobase/trx/trx0sys.cc
@@ -24,8 +24,6 @@ Transaction system
Created 3/26/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "mysqld.h"
#include "trx0sys.h"
#include "sql_error.h"
@@ -43,7 +41,6 @@ Created 3/26/1996 Heikki Tuuri
#include "log0recv.h"
#include "os0file.h"
#include "read0read.h"
-#include "fsp0sysspace.h"
#include <mysql/service_wsrep.h>
diff --git a/storage/innobase/trx/trx0trx.cc b/storage/innobase/trx/trx0trx.cc
index 4aba7a64ed8..b56cb9609ab 100644
--- a/storage/innobase/trx/trx0trx.cc
+++ b/storage/innobase/trx/trx0trx.cc
@@ -24,8 +24,6 @@ The transaction
Created 3/26/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "trx0trx.h"
#ifdef WITH_WSREP
@@ -42,7 +40,6 @@ Created 3/26/1996 Heikki Tuuri
#include "read0read.h"
#include "srv0mon.h"
#include "srv0srv.h"
-#include "fsp0sysspace.h"
#include "srv0start.h"
#include "trx0purge.h"
#include "trx0rec.h"
@@ -50,7 +47,6 @@ Created 3/26/1996 Heikki Tuuri
#include "trx0rseg.h"
#include "trx0undo.h"
#include "trx0xa.h"
-#include "ut0new.h"
#include "ut0pool.h"
#include "ut0vec.h"
diff --git a/storage/innobase/trx/trx0undo.cc b/storage/innobase/trx/trx0undo.cc
index 33a38b915be..98db4bf4e9e 100644
--- a/storage/innobase/trx/trx0undo.cc
+++ b/storage/innobase/trx/trx0undo.cc
@@ -24,8 +24,6 @@ Transaction undo log
Created 3/26/1996 Heikki Tuuri
*******************************************************/
-#include "ha_prototypes.h"
-
#include "trx0undo.h"
#include "fsp0fsp.h"
#include "mach0data.h"
@@ -36,7 +34,6 @@ Created 3/26/1996 Heikki Tuuri
#include "trx0purge.h"
#include "trx0rec.h"
#include "trx0rseg.h"
-#include "trx0trx.h"
/* How should the old versions in the history list be managed?
----------------------------------------------------------
diff --git a/storage/innobase/ut/ut0dbg.cc b/storage/innobase/ut/ut0dbg.cc
index 7df189ac560..56a2eb80337 100644
--- a/storage/innobase/ut/ut0dbg.cc
+++ b/storage/innobase/ut/ut0dbg.cc
@@ -24,8 +24,7 @@ Debug utilities for Innobase.
Created 1/30/1994 Heikki Tuuri
**********************************************************************/
-#include "ha_prototypes.h"
-
+#include "univ.i"
#include "ut0dbg.h"
/*************************************************************//**
diff --git a/storage/innobase/ut/ut0new.cc b/storage/innobase/ut/ut0new.cc
index 052db2fe7bd..8aad921278c 100644
--- a/storage/innobase/ut/ut0new.cc
+++ b/storage/innobase/ut/ut0new.cc
@@ -25,8 +25,6 @@ Created May 26, 2014 Vasil Dimov
#include "univ.i"
-#include "ut0new.h"
-
/** Maximum number of retries to allocate memory. */
const size_t alloc_max_retries = 60;
diff --git a/storage/innobase/ut/ut0rbt.cc b/storage/innobase/ut/ut0rbt.cc
index cb8e4f2df20..0da924fed43 100644
--- a/storage/innobase/ut/ut0rbt.cc
+++ b/storage/innobase/ut/ut0rbt.cc
@@ -23,9 +23,6 @@ Red-Black tree implementation
Created 2007-03-20 Sunny Bains
***********************************************************************/
-#include "univ.i"
-
-#include "ut0new.h"
#include "ut0rbt.h"
/**********************************************************************//**