MySQL 8.0.31
Source Code Documentation
btr0types.h
Go to the documentation of this file.
1/*****************************************************************************
2
3Copyright (c) 1996, 2022, Oracle and/or its affiliates.
4
5This program is free software; you can redistribute it and/or modify it under
6the terms of the GNU General Public License, version 2.0, as published by the
7Free Software Foundation.
8
9This program is also distributed with certain software (including but not
10limited to OpenSSL) that is licensed under separate terms, as designated in a
11particular file or component or in included license documentation. The authors
12of MySQL hereby grant you an additional permission to link the program and
13your derivative works with the separately licensed software that they have
14included with MySQL.
15
16This program is distributed in the hope that it will be useful, but WITHOUT
17ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
18FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
19for more details.
20
21You should have received a copy of the GNU General Public License along with
22this program; if not, write to the Free Software Foundation, Inc.,
2351 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24
25*****************************************************************************/
26
27/** @file include/btr0types.h
28 The index tree general types
29
30 Created 2/17/1996 Heikki Tuuri
31 *************************************************************************/
32
33#ifndef btr0types_h
34#define btr0types_h
35
36#include "univ.i"
37
38#include "page0size.h"
39#include "page0types.h"
40#include "rem0types.h"
41#include "sync0rw.h"
42#include "ut0rnd.h"
43
44/** Persistent cursor */
45struct btr_pcur_t;
46/** B-tree cursor */
47struct btr_cur_t;
48/** B-tree search information for the adaptive hash index */
49struct btr_search_t;
50
51/** Is search system enabled.
52Search system is protected by array of latches. */
53extern bool btr_search_enabled;
54
55/** Number of adaptive hash index partition. */
56extern ulong btr_ahi_parts;
57
58/** Structure to facilitate fast modulo for number of adaptive hash index
59partition. */
61
62/** The size of a reference to data stored on a different page.
63The reference is stored at the end of the prefix of the field
64in the index record. */
66
67/** If the data don't exceed the size, the data are stored locally. */
70
71#endif
bool btr_search_enabled
Is search system enabled.
Definition: btr0sea.cc:59
ut::fast_modulo_t btr_ahi_parts_fast_modulo
Structure to facilitate fast modulo for number of adaptive hash index partition.
constexpr uint32_t BTR_EXTERN_FIELD_REF_SIZE
The size of a reference to data stored on a different page.
Definition: btr0types.h:65
ulong btr_ahi_parts
Number of adaptive hash index partition.
Definition: btr0sea.cc:62
constexpr uint32_t BTR_EXTERN_LOCAL_STORED_MAX_SIZE
If the data don't exceed the size, the data are stored locally.
Definition: btr0types.h:68
Allows to execute x % mod for a specified mod in a fast way, without using a slow operation of divisi...
Definition: ut0math.h:144
A class describing a page size.
constexpr size_t FIELD_REF_SIZE
Definition: page0size.h:38
Index page routines.
Record manager global types.
The tree cursor: the definition appears here only for the compiler to know struct size!
Definition: btr0cur.h:667
Definition: btr0pcur.h:98
The search info struct in an index.
Definition: btr0sea.h:250
The read-write lock (for threads, not for database transactions)
Version control for database, common definitions, and include files.
Random numbers and hashing.