MySQL 8.0.39
Source Code Documentation
debug_lock_order.h
Go to the documentation of this file.
1/* Copyright (c) 2014, 2024, Oracle and/or its affiliates.
2
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; version 2 of the License.
6
7 This program is designed to work with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have either included with
13 the program or referenced in the documentation.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
23
24#ifndef DEBUG_LOCK_ORDER_H
25#define DEBUG_LOCK_ORDER_H
26
27#include "my_sys.h"
28
29struct PSI_bootstrap;
30
32 const char *m_name;
33 const char *m_operation;
35};
36
40 char *m_to_name;
45 char *m_comment;
46};
47
48#define LO_FLAG_TRACE 1 << 0
49#define LO_FLAG_DEBUG 1 << 1
50#define LO_FLAG_LOOP 1 << 2
51#define LO_FLAG_IGNORED 1 << 3
52#define LO_FLAG_BIND 1 << 4
53#define LO_FLAG_UNFAIR 1 << 5
54/* Micro arcs, generated from macro declarations. */
55#define LO_FLAG_MICRO 1 << 6
56
59 char *m_out_dir;
73};
74
76
77int LO_init(
78 struct LO_global_param *param, PSI_thread_bootstrap **thread_bootstrap,
79 PSI_mutex_bootstrap **mutex_bootstrap,
80 PSI_rwlock_bootstrap **rwlock_bootstrap,
81 PSI_cond_bootstrap **cond_bootstrap, PSI_file_bootstrap **file_bootstrap,
82 PSI_socket_bootstrap **socket_bootstrap,
83 PSI_table_bootstrap **table_bootstrap, PSI_mdl_bootstrap **mdl_bootstrap,
84 PSI_idle_bootstrap **idle_bootstrap, PSI_stage_bootstrap **stage_bootstrap,
85 PSI_statement_bootstrap **statement_bootstrap,
86 PSI_transaction_bootstrap **transaction_bootstrap,
87 PSI_memory_bootstrap **memory_bootstrap);
88
89void LO_activate();
90
91class LO_graph;
94
95void LO_dump();
96
97void LO_cleanup();
98
99/*
100 Helper for the performance schema.
101*/
103
104#endif
Definition: debug_lock_order.cc:1998
int LO_init(struct LO_global_param *param, PSI_thread_bootstrap **thread_bootstrap, PSI_mutex_bootstrap **mutex_bootstrap, PSI_rwlock_bootstrap **rwlock_bootstrap, PSI_cond_bootstrap **cond_bootstrap, PSI_file_bootstrap **file_bootstrap, PSI_socket_bootstrap **socket_bootstrap, PSI_table_bootstrap **table_bootstrap, PSI_mdl_bootstrap **mdl_bootstrap, PSI_idle_bootstrap **idle_bootstrap, PSI_stage_bootstrap **stage_bootstrap, PSI_statement_bootstrap **statement_bootstrap, PSI_transaction_bootstrap **transaction_bootstrap, PSI_memory_bootstrap **memory_bootstrap)
Definition: debug_lock_order.cc:8001
PSI_thread * LO_get_chain_thread(PSI_thread *psi)
Definition: debug_lock_order.cc:8242
void LO_add_node_properties(LO_graph *g, const LO_node_properties *node)
Definition: debug_lock_order.cc:8154
void LO_cleanup()
Definition: debug_lock_order.cc:8194
void LO_activate()
Definition: debug_lock_order.cc:8190
void LO_add_authorised_arc(LO_graph *g, const LO_authorised_arc *arc)
Definition: debug_lock_order.cc:8150
LO_global_param lo_param
Definition: debug_lock_order.cc:7997
void LO_dump()
Definition: debug_lock_order.cc:8192
struct PSI_thread PSI_thread
Definition: psi_thread_bits.h:82
Common header for many mysys elements.
Definition: debug_lock_order.h:37
char * m_from_state
Definition: debug_lock_order.h:39
char * m_to_name
Definition: debug_lock_order.h:40
int m_flags
Definition: debug_lock_order.h:43
char * m_to_operation
Definition: debug_lock_order.h:42
char * m_from_name
Definition: debug_lock_order.h:38
char * m_comment
Definition: debug_lock_order.h:45
char * m_constraint
Definition: debug_lock_order.h:44
bool m_op_recursive
Definition: debug_lock_order.h:41
Definition: debug_lock_order.h:57
bool m_trace_missing_key
Definition: debug_lock_order.h:71
bool m_debug_loop
Definition: debug_lock_order.h:64
char * m_dependencies_1
Definition: debug_lock_order.h:60
bool m_debug_missing_key
Definition: debug_lock_order.h:72
bool m_trace_missing_arc
Definition: debug_lock_order.h:65
bool m_trace_bad_unlock
Definition: debug_lock_order.h:69
bool m_debug_missing_unlock
Definition: debug_lock_order.h:68
bool m_debug_bad_unlock
Definition: debug_lock_order.h:70
bool m_trace_loop
Definition: debug_lock_order.h:63
bool m_trace_missing_unlock
Definition: debug_lock_order.h:67
bool m_print_txt
Definition: debug_lock_order.h:62
bool m_debug_missing_arc
Definition: debug_lock_order.h:66
bool m_enabled
Definition: debug_lock_order.h:58
char * m_out_dir
Definition: debug_lock_order.h:59
char * m_dependencies_2
Definition: debug_lock_order.h:61
Definition: debug_lock_order.h:31
const char * m_operation
Definition: debug_lock_order.h:33
const char * m_name
Definition: debug_lock_order.h:32
int m_flags
Definition: debug_lock_order.h:34
Entry point for the performance schema interface.
Definition: psi_cond.h:46
Entry point for the performance schema interface.
Definition: psi_file.h:66
Entry point for the performance schema interface.
Definition: psi_idle.h:60
Entry point for the performance schema interface.
Definition: psi_mdl.h:68
Entry point for the performance schema interface.
Definition: psi_memory.h:85
Entry point for the performance schema interface.
Definition: psi_mutex.h:46
Entry point for the performance schema interface.
Definition: psi_rwlock.h:53
Entry point for the performance schema interface.
Definition: psi_socket.h:52
Entry point for the performance schema interface.
Definition: psi_stage.h:46
Entry point for the performance schema interface.
Definition: psi_statement.h:46
Entry point for the performance schema interface.
Definition: psi_table.h:60
Entry point for the performance schema interface.
Definition: psi_thread.h:102
Entry point for the performance schema interface.
Definition: psi_transaction.h:60