Drizzled Public API Documentation

fsp0fsp.h
Go to the documentation of this file.
1 /*****************************************************************************
2 
3 Copyright (C) 1995, 2009, Innobase Oy. All Rights Reserved.
4 
5 This program is free software; you can redistribute it and/or modify it under
6 the terms of the GNU General Public License as published by the Free Software
7 Foundation; version 2 of the License.
8 
9 This program is distributed in the hope that it will be useful, but WITHOUT
10 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12 
13 You should have received a copy of the GNU General Public License along with
14 this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
15 St, Fifth Floor, Boston, MA 02110-1301 USA
16 
17 *****************************************************************************/
18 
19 /**************************************************/
26 #pragma once
27 #ifndef fsp0fsp_h
28 #define fsp0fsp_h
29 
30 #include "univ.i"
31 
32 #include "mtr0mtr.h"
33 #include "fut0lst.h"
34 #include "ut0byte.h"
35 #include "page0types.h"
36 #include "fsp0types.h"
37 
38 /**********************************************************************/
40 UNIV_INTERN
41 void
42 fsp_init(void);
43 /*==========*/
44 /**********************************************************************/
50 UNIV_INTERN
51 ulint
53 /*===========================*/
54 /**********************************************************************/
60 UNIV_INTERN
61 ulint
63 /*================================*/
64 /**********************************************************************/
67 UNIV_INTERN
68 ulint
70 /*=============*/
71  page_t* page);
72 /**********************************************************************/
75 UNIV_INTERN
76 ulint
78 /*====================*/
79  const page_t* page);
80 /**********************************************************************/
83 UNIV_INTERN
84 ulint
86 /*=================*/
87  const page_t* page);
88 /**********************************************************************/
91 UNIV_INTERN
92 ulint
94 /*====================*/
95  const page_t* page);
96 /**********************************************************************/
100 UNIV_INTERN
101 void
103 /*===================*/
104  page_t* page,
105  ulint space_id,
106  ulint flags);
108 /**********************************************************************/
111 UNIV_INTERN
112 void
114 /*============*/
115  ulint space,
116  ulint size,
117  mtr_t* mtr);
118 /**********************************************************************/
120 UNIV_INTERN
121 void
123 /*================*/
124  ulint space,
125  ulint size_inc,
126  mtr_t* mtr);
127 /**********************************************************************/
131 UNIV_INTERN
134 /*========*/
135  ulint space,
136  ulint page,
140  ulint byte_offset,
142  mtr_t* mtr);
143 /**********************************************************************/
147 UNIV_INTERN
150 /*================*/
151  ulint space,
152  ulint page,
156  ulint byte_offset,
158  ibool has_done_reservation,
164  mtr_t* mtr);
165 /**********************************************************************/
169 UNIV_INTERN
170 ulint
172 /*==================*/
173  fseg_header_t* header,
174  ulint* used,
175  mtr_t* mtr);
176 /**********************************************************************/
181 UNIV_INTERN
182 ulint
184 /*=================*/
185  fseg_header_t* seg_header,
186  ulint hint,
187  byte direction,
192  mtr_t* mtr);
193 /**********************************************************************/
198 UNIV_INTERN
199 ulint
201 /*=========================*/
202  fseg_header_t* seg_header,
203  ulint hint,
204  byte direction,
209  ibool has_done_reservation,
214  mtr_t* mtr);
215 /**********************************************************************/
241 UNIV_INTERN
242 ibool
244 /*=====================*/
245  ulint* n_reserved,
248  ulint space,
249  ulint n_ext,
250  ulint alloc_type,
251  mtr_t* mtr);
252 /**********************************************************************/
258 UNIV_INTERN
259 ullint
261 /*====================================*/
262  ulint space);
263 /**********************************************************************/
265 UNIV_INTERN
266 void
268 /*===========*/
269  fseg_header_t* seg_header,
270  ulint space,
271  ulint page,
272  mtr_t* mtr);
273 /**********************************************************************/
279 UNIV_INTERN
280 ibool
282 /*===========*/
283  fseg_header_t* header,
287  mtr_t* mtr);
288 /**********************************************************************/
292 UNIV_INTERN
293 ibool
295 /*======================*/
296  fseg_header_t* header,
298  mtr_t* mtr);
299 /***********************************************************************/
302 UNIV_INLINE
303 ibool
305 /*===========*/
306  ulint zip_size,
308  ulint page_no);
309 /***********************************************************/
312 UNIV_INTERN
313 byte*
315 /*=====================*/
316  byte* ptr,
317  byte* end_ptr,
318  buf_block_t* block);
319 /*******************************************************************/
322 UNIV_INTERN
323 ibool
325 /*=========*/
326  ulint space);
327 /*******************************************************************/
329 UNIV_INTERN
330 void
331 fsp_print(
332 /*======*/
333  ulint space);
334 #ifdef UNIV_DEBUG
335 /*******************************************************************/
338 UNIV_INTERN
339 ibool
340 fseg_validate(
341 /*==========*/
342  fseg_header_t* header,
343  mtr_t* mtr);
344 #endif /* UNIV_DEBUG */
345 #ifdef UNIV_BTR_PRINT
346 /*******************************************************************/
348 UNIV_INTERN
349 void
350 fseg_print(
351 /*=======*/
352  fseg_header_t* header,
353  mtr_t* mtr);
354 #endif /* UNIV_BTR_PRINT */
355 
356 #ifndef UNIV_NONINL
357 #include "fsp0fsp.ic"
358 #endif
359 
360 #endif
UNIV_INLINE ibool fsp_descr_page(ulint zip_size, ulint page_no)
UNIV_INTERN void fsp_init(void)
Definition: fsp0fsp.cc:914
UNIV_INTERN ibool fsp_validate(ulint space)
Definition: fsp0fsp.cc:3920
UNIV_INTERN ulint fseg_alloc_free_page_general(fseg_header_t *seg_header, ulint hint, byte direction, ibool has_done_reservation, mtr_t *mtr)
Definition: fsp0fsp.cc:2802
UNIV_INTERN ulint fsp_header_get_free_limit(void)
Definition: fsp0fsp.cc:1102
UNIV_INTERN ulint fseg_n_reserved_pages(fseg_header_t *header, ulint *used, mtr_t *mtr)
Definition: fsp0fsp.cc:2401
UNIV_INTERN ulint fsp_header_get_tablespace_size(void)
Definition: fsp0fsp.cc:1134
UNIV_INTERN ulint fseg_alloc_free_page(fseg_header_t *seg_header, ulint hint, byte direction, mtr_t *mtr)
Definition: fsp0fsp.cc:2873
UNIV_INTERN void fseg_free_page(fseg_header_t *seg_header, ulint space, ulint page, mtr_t *mtr)
Definition: fsp0fsp.cc:3403
UNIV_INTERN void fsp_header_inc_size(ulint space, ulint size_inc, mtr_t *mtr)
Definition: fsp0fsp.cc:1070
UNIV_INTERN byte * fsp_parse_init_file_page(byte *ptr, byte *end_ptr, buf_block_t *block)
Definition: fsp0fsp.cc:895
UNIV_INTERN ibool fsp_reserve_free_extents(ulint *n_reserved, ulint space, ulint n_ext, ulint alloc_type, mtr_t *mtr)
Definition: fsp0fsp.cc:2955
UNIV_INTERN ulint fsp_get_size_low(page_t *page)
Definition: fsp0fsp.cc:343
UNIV_INTERN ullint fsp_get_available_space_in_free_extents(ulint space)
Definition: fsp0fsp.cc:3071
UNIV_INTERN ulint fsp_header_get_space_id(const page_t *page)
Definition: fsp0fsp.cc:1014
UNIV_INTERN ulint fsp_header_get_flags(const page_t *page)
Definition: fsp0fsp.cc:1042
UNIV_INTERN buf_block_t * fseg_create(ulint space, ulint page, ulint byte_offset, mtr_t *mtr)
Definition: fsp0fsp.cc:2351
UNIV_INTERN void fsp_print(ulint space)
Definition: fsp0fsp.cc:4172
UNIV_INTERN void fsp_header_init_fields(page_t *page, ulint space_id, ulint flags)
Definition: fsp0fsp.cc:926
byte page_t
Definition: page0types.h:37
UNIV_INTERN ulint fsp_header_get_zip_size(const page_t *page)
Definition: fsp0fsp.cc:1056
UNIV_INTERN buf_block_t * fseg_create_general(ulint space, ulint page, ulint byte_offset, ibool has_done_reservation, mtr_t *mtr)
Definition: fsp0fsp.cc:2218
UNIV_INTERN void fsp_header_init(ulint space, ulint size, mtr_t *mtr)
Definition: fsp0fsp.cc:951
UNIV_INTERN ibool fseg_free_step_not_header(fseg_header_t *header, mtr_t *mtr)
Definition: fsp0fsp.cc:3599
UNIV_INTERN ibool fseg_free_step(fseg_header_t *header, mtr_t *mtr)
Definition: fsp0fsp.cc:3512