~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/innobase/include/thr0loc.h

  • Committer: lbieber
  • Date: 2010-10-01 12:16:18 UTC
  • mfrom: (1802.1.1 fix-bug-651256)
  • Revision ID: lbieber@orisndriz08-20101001121618-uqcboygpjwbiglem
Merge Vijay - fix bug 651256 - Remove --help-extended

Show diffs side-by-side

added added

removed removed

Lines of Context:
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
 
/**************************************************//**
20
 
@file include/thr0loc.h
21
 
The thread local storage
22
 
 
23
 
Created 10/5/1995 Heikki Tuuri
24
 
*******************************************************/
25
 
 
26
 
/* This module implements storage private to each thread,
27
 
a capability useful in some situations like storing the
28
 
OS handle to the current thread, or its priority. */
29
 
 
30
 
#ifndef thr0loc_h
31
 
#define thr0loc_h
32
 
 
33
 
#include "univ.i"
34
 
#include "os0thread.h"
35
 
 
36
 
/****************************************************************//**
37
 
Initializes the thread local storage module. */
38
 
UNIV_INTERN
39
 
void
40
 
thr_local_init(void);
41
 
/*================*/
42
 
 /****************************************************************//**
43
 
Close the thread local storage module. */
44
 
UNIV_INTERN
45
 
void
46
 
thr_local_close(void);
47
 
/*=================*/
48
 
/*******************************************************************//**
49
 
Creates a local storage struct for the calling new thread. */
50
 
UNIV_INTERN
51
 
void
52
 
thr_local_create(void);
53
 
/*==================*/
54
 
/*******************************************************************//**
55
 
Frees the local storage struct for the specified thread. */
56
 
UNIV_INTERN
57
 
void
58
 
thr_local_free(
59
 
/*===========*/
60
 
        os_thread_id_t  id);    /*!< in: thread id */
61
 
/*******************************************************************//**
62
 
Gets the slot number in the thread table of a thread.
63
 
@return slot number */
64
 
UNIV_INTERN
65
 
ulint
66
 
thr_local_get_slot_no(
67
 
/*==================*/
68
 
        os_thread_id_t  id);    /*!< in: thread id of the thread */
69
 
/*******************************************************************//**
70
 
Sets in the local storage the slot number in the thread table of a thread. */
71
 
UNIV_INTERN
72
 
void
73
 
thr_local_set_slot_no(
74
 
/*==================*/
75
 
        os_thread_id_t  id,     /*!< in: thread id of the thread */
76
 
        ulint           slot_no);/*!< in: slot number */
77
 
/*******************************************************************//**
78
 
Returns pointer to the 'in_ibuf' field within the current thread local
79
 
storage.
80
 
@return pointer to the in_ibuf field */
81
 
UNIV_INTERN
82
 
ibool*
83
 
thr_local_get_in_ibuf_field(void);
84
 
/*=============================*/
85
 
 
86
 
#ifndef UNIV_NONINL
87
 
#include "thr0loc.ic"
88
 
#endif
89
 
 
90
 
#endif