MySQL 8.0.29
Source Code Documentation
psi_statement_bits.h
Go to the documentation of this file.
1/* Copyright (c) 2008, 2022, 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, version 2.0,
5 as published by the Free Software Foundation.
6
7 This program is also distributed 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 included with MySQL.
13
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License, version 2.0, for more details.
18
19 You should have received a copy of the GNU General Public License
20 along with this program; if not, write to the Free Software
21 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
22
23#ifndef COMPONENTS_SERVICES_BITS_PSI_STATEMENT_BITS_H
24#define COMPONENTS_SERVICES_BITS_PSI_STATEMENT_BITS_H
25
26#ifndef MYSQL_ABI_CHECK
27#include <stddef.h> /* size_t */
28#endif
29
31
32/**
33 @file mysql/components/services/bits/psi_statement_bits.h
34 Performance schema instrumentation interface.
35
36 @defgroup psi_abi_statement Statement Instrumentation (ABI)
37 @ingroup psi_abi
38 @{
39*/
40
41/**
42 Instrumented statement key.
43 To instrument a statement, a statement key must be obtained using @c
44 register_statement.
45 Using a zero key always disable the instrumentation.
46*/
47typedef unsigned int PSI_statement_key;
48
49/**
50 @def PSI_STATEMENT_VERSION_1
51 Performance Schema Statement Interface number for version 1.
52 This version is deprecated.
53*/
54#define PSI_STATEMENT_VERSION_1 1
55
56/**
57 @def PSI_STATEMENT_VERSION_2
58 Performance Schema Statement Interface number for version 2.
59 This version is deprecated.
60*/
61#define PSI_STATEMENT_VERSION_2 2
62
63/**
64 @def PSI_STATEMENT_VERSION_3
65 Performance Schema Statement Interface number for version 3.
66 This version is supported.
67*/
68#define PSI_STATEMENT_VERSION_3 3
69
70/**
71 @def PSI_CURRENT_STATEMENT_VERSION
72 Performance Schema Statement Interface number for the most recent version.
73 The most current version is @c PSI_STATEMENT_VERSION_3
74*/
75#define PSI_CURRENT_STATEMENT_VERSION 3
76
77/**
78 Interface for an instrumented statement.
79 This is an opaque structure.
80*/
83
84/**
85 Interface for an instrumented prepared statement.
86 This is an opaque structure.
87*/
90
91/**
92 Interface for an instrumented statement digest operation.
93 This is an opaque structure.
94*/
97
98/**
99 Interface for an instrumented stored procedure share.
100 This is an opaque structure.
101*/
102struct PSI_sp_share;
104
105/**
106 Interface for an instrumented stored program.
107 This is an opaque structure.
108*/
109struct PSI_sp_locker;
111
112/**
113 Statement instrument information.
114 @since PSI_STATEMENT_VERSION_1
115 This structure is used to register an instrumented statement.
116*/
118 /** The registered statement key. */
120 /** The name of the statement instrument to register. */
121 const char *m_name;
122 /**
123 The flags of the statement instrument to register.
124 @sa PSI_FLAG_MUTABLE
125 */
126 unsigned int m_flags;
127 /** Documentation. */
128 const char *m_documentation;
129};
131
132/* Duplicate of NAME_LEN, to avoid dependency on mysql_com.h */
133#define PSI_SCHEMA_NAME_LEN (64 * 3)
134
135/**
136 State data storage for @c get_thread_statement_locker_v1_t,
137 @c get_thread_statement_locker_v1_t.
138 This structure provide temporary storage to a statement locker.
139 The content of this structure is considered opaque,
140 the fields are only hints of what an implementation
141 of the psi interface can use.
142 This memory is provided by the instrumented code for performance reasons.
143 @sa get_thread_statement_locker_v1_t
144*/
146 /** Discarded flag. */
148 /** In prepare flag. */
150 /** Metric, no index used flag. */
151 unsigned char m_no_index_used;
152 /** Metric, no good index used flag. */
153 unsigned char m_no_good_index_used;
154 /** Internal state. */
155 unsigned int m_flags;
156 /** Instrumentation class. */
157 void *m_class;
158 /** Current thread. */
160 /** Timer start. */
161 unsigned long long m_timer_start;
162 /** THREAD CPU time start. */
163 unsigned long long m_cpu_time_start;
164 /** Internal data. */
166 /** Locked time. */
167 unsigned long long m_lock_time;
168 /** Rows sent. */
169 unsigned long long m_rows_sent;
170 /** Rows examined. */
171 unsigned long long m_rows_examined;
172 /** Metric, temporary tables created on disk. */
174 /** Metric, temporary tables created. */
175 unsigned long m_created_tmp_tables;
176 /** Metric, number of select full join. */
177 unsigned long m_select_full_join;
178 /** Metric, number of select full range join. */
180 /** Metric, number of select range. */
181 unsigned long m_select_range;
182 /** Metric, number of select range check. */
183 unsigned long m_select_range_check;
184 /** Metric, number of select scan. */
185 unsigned long m_select_scan;
186 /** Metric, number of sort merge passes. */
187 unsigned long m_sort_merge_passes;
188 /** Metric, number of sort merge. */
189 unsigned long m_sort_range;
190 /** Metric, number of sort rows. */
191 unsigned long m_sort_rows;
192 /** Metric, number of sort scans. */
193 unsigned long m_sort_scan;
194 /** Statement digest. */
196 /** Current schema name. */
198 /** Length in bytes of @c m_schema_name. */
200 /** Statement character set number. */
201 unsigned int m_cs_number;
202 /** Statement query sample. */
203 const char *m_query_sample;
204 /** Length in bytes of @c m_query_sample. */
206 /** True if @c m_query_sample was truncated. */
208
211};
213
215 /** Internal state. */
216 unsigned int m_flags;
217 /** Current thread. */
219 /** Timer start. */
220 unsigned long long m_timer_start;
221 /** Timer function. */
222 unsigned long long (*m_timer)(void);
223 /** Stored Procedure share. */
225};
227
228/**
229 Statement registration API.
230 @param category a category name
231 @param info an array of statement info to register
232 @param count the size of the info array
233*/
234typedef void (*register_statement_v1_t)(const char *category,
236 int count);
237
238/**
239 Get a statement instrumentation locker.
240 @param state data storage for the locker
241 @param key the statement instrumentation key
242 @param charset client character set
243 @param sp_share Parent stored procedure share, if any.
244 @return a statement locker, or NULL
245*/
246typedef struct PSI_statement_locker *(*get_thread_statement_locker_v1_t)(
248 const void *charset, PSI_sp_share *sp_share);
249
250/**
251 Refine a statement locker to a more specific key.
252 Note that only events declared mutable can be refined.
253 @param locker the statement locker for the current event
254 @param key the new key for the event
255 @sa PSI_FLAG_MUTABLE
256*/
257typedef struct PSI_statement_locker *(*refine_statement_v1_t)(
259
260/**
261 Start a new statement event.
262 @param locker the statement locker for this event
263 @param db the active database name for this statement
264 @param db_length the active database name length for this statement
265 @param src_file source file name
266 @param src_line source line number
267*/
268typedef void (*start_statement_v1_t)(struct PSI_statement_locker *locker,
269 const char *db, unsigned int db_length,
270 const char *src_file,
271 unsigned int src_line);
272
273/**
274 Set the statement text for a statement event.
275 Note that the statement text pointer must remain valid until end statement
276 is called.
277 @param locker the current statement locker
278 @param text the statement text
279 @param text_len the statement text length
280*/
281typedef void (*set_statement_text_v1_t)(struct PSI_statement_locker *locker,
282 const char *text,
283 unsigned int text_len);
284
285/**
286 Set a statement query id.
287 Introduced in MySQL 8.0.14
288 @param locker the statement locker
289 @param query_id the query id
290*/
291typedef void (*set_statement_query_id_t)(struct PSI_statement_locker *locker,
292 unsigned long long query_id);
293
294/**
295 Set a statement event lock time.
296 @param locker the statement locker
297 @param lock_time the locked time, in microseconds
298*/
299typedef void (*set_statement_lock_time_t)(struct PSI_statement_locker *locker,
300 unsigned long long lock_time);
301
302/**
303 Set a statement event rows sent metric.
304 @param locker the statement locker
305 @param count the number of rows sent
306*/
307typedef void (*set_statement_rows_sent_t)(struct PSI_statement_locker *locker,
308 unsigned long long count);
309
310/**
311 Set a statement event rows examined metric.
312 @param locker the statement locker
313 @param count the number of rows examined
314*/
316 struct PSI_statement_locker *locker, unsigned long long count);
317
318/**
319 Increment a statement event "created tmp disk tables" metric.
320 @param locker the statement locker
321 @param count the metric increment value
322*/
324 struct PSI_statement_locker *locker, unsigned long count);
325
326/**
327 Increment a statement event "created tmp tables" metric.
328 @param locker the statement locker
329 @param count the metric increment value
330*/
332 struct PSI_statement_locker *locker, unsigned long count);
333
334/**
335 Increment a statement event "select full join" metric.
336 @param locker the statement locker
337 @param count the metric increment value
338*/
340 struct PSI_statement_locker *locker, unsigned long count);
341
342/**
343 Increment a statement event "select full range join" metric.
344 @param locker the statement locker
345 @param count the metric increment value
346*/
348 struct PSI_statement_locker *locker, unsigned long count);
349
350/**
351 Increment a statement event "select range join" metric.
352 @param locker the statement locker
353 @param count the metric increment value
354*/
356 struct PSI_statement_locker *locker, unsigned long count);
357
358/**
359 Increment a statement event "select range check" metric.
360 @param locker the statement locker
361 @param count the metric increment value
362*/
364 struct PSI_statement_locker *locker, unsigned long count);
365
366/**
367 Increment a statement event "select scan" metric.
368 @param locker the statement locker
369 @param count the metric increment value
370*/
372 unsigned long count);
373
374/**
375 Increment a statement event "sort merge passes" metric.
376 @param locker the statement locker
377 @param count the metric increment value
378*/
380 struct PSI_statement_locker *locker, unsigned long count);
381
382/**
383 Increment a statement event "sort range" metric.
384 @param locker the statement locker
385 @param count the metric increment value
386*/
388 unsigned long count);
389
390/**
391 Increment a statement event "sort rows" metric.
392 @param locker the statement locker
393 @param count the metric increment value
394*/
395typedef void (*inc_statement_sort_rows_t)(struct PSI_statement_locker *locker,
396 unsigned long count);
397
398/**
399 Increment a statement event "sort scan" metric.
400 @param locker the statement locker
401 @param count the metric increment value
402*/
403typedef void (*inc_statement_sort_scan_t)(struct PSI_statement_locker *locker,
404 unsigned long count);
405
406/**
407 Set a statement event "no index used" metric.
408 @param locker the statement locker
409*/
411 struct PSI_statement_locker *locker);
412
413/**
414 Set a statement event "no good index used" metric.
415 @param locker the statement locker
416*/
418 struct PSI_statement_locker *locker);
419
420/**
421 Set a statement EXECUTION_ENGINE attribute.
422 @param locker the statement locker
423 @param secondary True for SECONDARY, false for PRIMARY.
424*/
426 struct PSI_statement_locker *locker, bool secondary);
427
428/**
429 End a statement event.
430 @param locker the statement locker
431 @param stmt_da the statement diagnostics area.
432 @sa Diagnostics_area
433*/
434typedef void (*end_statement_v1_t)(struct PSI_statement_locker *locker,
435 void *stmt_da);
436
437/**
438 Get a prepare statement.
439 @param identity Prepared statement identity, typically a memory address.
440 @param stmt_id Prepared statement identifier.
441 @param locker A statement locker for the running thread.
442 @param stmt_name Prepared statement name.
443 @param stmt_name_length Prepared statement name length.
444 @param sql_text Query text.
445 @param sql_text_length Query text length.
446*/
447typedef PSI_prepared_stmt *(*create_prepared_stmt_v1_t)(
448 void *identity, unsigned int stmt_id, PSI_statement_locker *locker,
449 const char *stmt_name, size_t stmt_name_length, const char *sql_text,
450 size_t sql_text_length);
451
452/**
453 destroy a prepare statement.
454 @param prepared_stmt prepared statement.
455*/
456typedef void (*destroy_prepared_stmt_v1_t)(PSI_prepared_stmt *prepared_stmt);
457
458/**
459 reprepare a prepare statement.
460 @param prepared_stmt prepared statement.
461*/
462typedef void (*reprepare_prepared_stmt_v1_t)(PSI_prepared_stmt *prepared_stmt);
463
464/**
465 Record a prepare statement instrumentation execute event.
466 @param locker a statement locker for the running thread.
467 @param prepared_stmt prepared statement.
468*/
470 PSI_prepared_stmt *prepared_stmt);
471
472/**
473 Set the statement text for a prepared statment event.
474 @param prepared_stmt prepared statement.
475 @param text the prepared statement text
476 @param text_len the prepared statement text length
477*/
478typedef void (*set_prepared_stmt_text_v1_t)(PSI_prepared_stmt *prepared_stmt,
479 const char *text,
480 unsigned int text_len);
481
482/**
483 Set a prepared statement EXECUTION_ENGINE attribute.
484 @param prepared_stmt prepared statement.
485 @param secondary True for SECONDARY, false for PRIMARY.
486*/
488 PSI_prepared_stmt *prepared_stmt, bool secondary);
489
490/**
491 Get a digest locker for the current statement.
492 @param locker a statement locker for the running thread
493*/
494typedef struct PSI_digest_locker *(*digest_start_v1_t)(
495 struct PSI_statement_locker *locker);
496
497/**
498 Add a computed digest to the current digest instrumentation.
499 @param locker a digest locker for the current statement
500 @param digest the computed digest
501*/
502typedef void (*digest_end_v1_t)(struct PSI_digest_locker *locker,
503 const struct sql_digest_storage *digest);
504
505/**
506 Acquire a sp share instrumentation.
507 @param object_type type of stored program
508 @param schema_name schema name of stored program
509 @param schema_name_length length of schema_name
510 @param object_name object name of stored program
511 @param object_name_length length of object_name
512 @return a stored program share instrumentation, or NULL
513*/
514typedef struct PSI_sp_share *(*get_sp_share_v1_t)(
515 unsigned int object_type, const char *schema_name,
516 unsigned int schema_name_length, const char *object_name,
517 unsigned int object_name_length);
518
519/**
520 Release a stored program share.
521 @param share the stored program share to release
522*/
523typedef void (*release_sp_share_v1_t)(struct PSI_sp_share *share);
524
525typedef PSI_sp_locker *(*start_sp_v1_t)(struct PSI_sp_locker_state_v1 *state,
526 struct PSI_sp_share *sp_share);
527
528typedef void (*end_sp_v1_t)(struct PSI_sp_locker *locker);
529
530typedef void (*drop_sp_v1_t)(unsigned int object_type, const char *schema_name,
531 unsigned int schema_name_length,
532 const char *object_name,
533 unsigned int object_name_length);
534
538
539/** @} (end of group psi_abi_statement) */
540
541#endif /* COMPONENTS_SERVICES_BITS_PSI_STATEMENT_BITS_H */
struct PSI_digest_locker PSI_digest_locker
Definition: psi_statement_bits.h:96
unsigned int PSI_statement_key
Instrumented statement key.
Definition: psi_statement_bits.h:47
void(* destroy_prepared_stmt_v1_t)(PSI_prepared_stmt *prepared_stmt)
destroy a prepare statement.
Definition: psi_statement_bits.h:456
void(* inc_statement_sort_merge_passes_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "sort merge passes" metric.
Definition: psi_statement_bits.h:379
void(* inc_statement_sort_rows_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "sort rows" metric.
Definition: psi_statement_bits.h:395
void(* inc_statement_select_full_range_join_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "select full range join" metric.
Definition: psi_statement_bits.h:347
void(* set_statement_text_v1_t)(struct PSI_statement_locker *locker, const char *text, unsigned int text_len)
Set the statement text for a statement event.
Definition: psi_statement_bits.h:281
void(* inc_statement_select_range_check_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "select range check" metric.
Definition: psi_statement_bits.h:363
void(* inc_statement_select_scan_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "select scan" metric.
Definition: psi_statement_bits.h:371
void(* set_prepared_stmt_secondary_engine_v3_t)(PSI_prepared_stmt *prepared_stmt, bool secondary)
Set a prepared statement EXECUTION_ENGINE attribute.
Definition: psi_statement_bits.h:487
void(* register_statement_v1_t)(const char *category, struct PSI_statement_info_v1 *info, int count)
Statement registration API.
Definition: psi_statement_bits.h:234
void(* reprepare_prepared_stmt_v1_t)(PSI_prepared_stmt *prepared_stmt)
reprepare a prepare statement.
Definition: psi_statement_bits.h:462
void(* inc_statement_sort_scan_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "sort scan" metric.
Definition: psi_statement_bits.h:403
void(* execute_prepared_stmt_v1_t)(PSI_statement_locker *locker, PSI_prepared_stmt *prepared_stmt)
Record a prepare statement instrumentation execute event.
Definition: psi_statement_bits.h:469
void(* set_statement_no_index_used_t)(struct PSI_statement_locker *locker)
Set a statement event "no index used" metric.
Definition: psi_statement_bits.h:410
struct PSI_prepared_stmt PSI_prepared_stmt
Definition: psi_statement_bits.h:89
void(* inc_statement_sort_range_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "sort range" metric.
Definition: psi_statement_bits.h:387
void(* start_statement_v1_t)(struct PSI_statement_locker *locker, const char *db, unsigned int db_length, const char *src_file, unsigned int src_line)
Start a new statement event.
Definition: psi_statement_bits.h:268
struct PSI_sp_locker PSI_sp_locker
Definition: psi_statement_bits.h:110
void(* release_sp_share_v1_t)(struct PSI_sp_share *share)
Release a stored program share.
Definition: psi_statement_bits.h:523
void(* set_statement_query_id_t)(struct PSI_statement_locker *locker, unsigned long long query_id)
Set a statement query id.
Definition: psi_statement_bits.h:291
void(* set_statement_secondary_engine_v3_t)(struct PSI_statement_locker *locker, bool secondary)
Set a statement EXECUTION_ENGINE attribute.
Definition: psi_statement_bits.h:425
void(* drop_sp_v1_t)(unsigned int object_type, const char *schema_name, unsigned int schema_name_length, const char *object_name, unsigned int object_name_length)
Definition: psi_statement_bits.h:530
void(* set_statement_rows_examined_t)(struct PSI_statement_locker *locker, unsigned long long count)
Set a statement event rows examined metric.
Definition: psi_statement_bits.h:315
void(* set_statement_no_good_index_used_t)(struct PSI_statement_locker *locker)
Set a statement event "no good index used" metric.
Definition: psi_statement_bits.h:417
#define PSI_SCHEMA_NAME_LEN
Definition: psi_statement_bits.h:133
struct PSI_sp_share PSI_sp_share
Definition: psi_statement_bits.h:103
void(* digest_end_v1_t)(struct PSI_digest_locker *locker, const struct sql_digest_storage *digest)
Add a computed digest to the current digest instrumentation.
Definition: psi_statement_bits.h:502
void(* inc_statement_select_range_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "select range join" metric.
Definition: psi_statement_bits.h:355
void(* set_prepared_stmt_text_v1_t)(PSI_prepared_stmt *prepared_stmt, const char *text, unsigned int text_len)
Set the statement text for a prepared statment event.
Definition: psi_statement_bits.h:478
void(* end_sp_v1_t)(struct PSI_sp_locker *locker)
Definition: psi_statement_bits.h:528
void(* inc_statement_select_full_join_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "select full join" metric.
Definition: psi_statement_bits.h:339
void(* end_statement_v1_t)(struct PSI_statement_locker *locker, void *stmt_da)
End a statement event.
Definition: psi_statement_bits.h:434
void(* set_statement_lock_time_t)(struct PSI_statement_locker *locker, unsigned long long lock_time)
Set a statement event lock time.
Definition: psi_statement_bits.h:299
void(* set_statement_rows_sent_t)(struct PSI_statement_locker *locker, unsigned long long count)
Set a statement event rows sent metric.
Definition: psi_statement_bits.h:307
struct PSI_statement_locker PSI_statement_locker
Definition: psi_statement_bits.h:82
void(* inc_statement_created_tmp_disk_tables_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "created tmp disk tables" metric.
Definition: psi_statement_bits.h:323
void(* inc_statement_created_tmp_tables_t)(struct PSI_statement_locker *locker, unsigned long count)
Increment a statement event "created tmp tables" metric.
Definition: psi_statement_bits.h:331
struct PSI_thread PSI_thread
Definition: psi_thread_bits.h:81
static int count
Definition: myisam_ftdump.cc:42
Log info(cout, "NOTE")
const std::string charset("charset")
static const char * category
Definition: sha2_password.cc:168
Performance schema instrumentation interface.
required string key
Definition: replication_asynchronous_connection_failover.proto:59
Definition: psi_statement_bits.h:214
unsigned long long m_timer_start
Timer start.
Definition: psi_statement_bits.h:220
PSI_sp_share * m_sp_share
Stored Procedure share.
Definition: psi_statement_bits.h:224
unsigned long long(* m_timer)(void)
Timer function.
Definition: psi_statement_bits.h:222
unsigned int m_flags
Internal state.
Definition: psi_statement_bits.h:216
struct PSI_thread * m_thread
Current thread.
Definition: psi_statement_bits.h:218
Statement instrument information.
Definition: psi_statement_bits.h:117
const char * m_name
The name of the statement instrument to register.
Definition: psi_statement_bits.h:121
PSI_statement_key m_key
The registered statement key.
Definition: psi_statement_bits.h:119
const char * m_documentation
Documentation.
Definition: psi_statement_bits.h:128
unsigned int m_flags
The flags of the statement instrument to register.
Definition: psi_statement_bits.h:126
State data storage for get_thread_statement_locker_v1_t, get_thread_statement_locker_v1_t.
Definition: psi_statement_bits.h:145
unsigned long m_sort_range
Metric, number of sort merge.
Definition: psi_statement_bits.h:189
PSI_sp_share * m_parent_sp_share
Definition: psi_statement_bits.h:209
unsigned long m_created_tmp_disk_tables
Metric, temporary tables created on disk.
Definition: psi_statement_bits.h:173
const struct sql_digest_storage * m_digest
Statement digest.
Definition: psi_statement_bits.h:195
bool m_query_sample_truncated
True if m_query_sample was truncated.
Definition: psi_statement_bits.h:207
unsigned int m_schema_name_length
Length in bytes of m_schema_name.
Definition: psi_statement_bits.h:199
bool m_discarded
Discarded flag.
Definition: psi_statement_bits.h:147
unsigned long m_sort_rows
Metric, number of sort rows.
Definition: psi_statement_bits.h:191
unsigned int m_cs_number
Statement character set number.
Definition: psi_statement_bits.h:201
unsigned long long m_cpu_time_start
THREAD CPU time start.
Definition: psi_statement_bits.h:163
unsigned char m_no_good_index_used
Metric, no good index used flag.
Definition: psi_statement_bits.h:153
unsigned long long m_lock_time
Locked time.
Definition: psi_statement_bits.h:167
unsigned long m_sort_scan
Metric, number of sort scans.
Definition: psi_statement_bits.h:193
char m_schema_name[PSI_SCHEMA_NAME_LEN]
Current schema name.
Definition: psi_statement_bits.h:197
unsigned long long m_rows_examined
Rows examined.
Definition: psi_statement_bits.h:171
void * m_class
Instrumentation class.
Definition: psi_statement_bits.h:157
PSI_prepared_stmt * m_parent_prepared_stmt
Definition: psi_statement_bits.h:210
unsigned long m_sort_merge_passes
Metric, number of sort merge passes.
Definition: psi_statement_bits.h:187
void * m_statement
Internal data.
Definition: psi_statement_bits.h:165
unsigned long m_select_full_join
Metric, number of select full join.
Definition: psi_statement_bits.h:177
unsigned long m_select_range
Metric, number of select range.
Definition: psi_statement_bits.h:181
bool m_in_prepare
In prepare flag.
Definition: psi_statement_bits.h:149
unsigned long long m_timer_start
Timer start.
Definition: psi_statement_bits.h:161
const char * m_query_sample
Statement query sample.
Definition: psi_statement_bits.h:203
struct PSI_thread * m_thread
Current thread.
Definition: psi_statement_bits.h:159
unsigned long m_created_tmp_tables
Metric, temporary tables created.
Definition: psi_statement_bits.h:175
unsigned long m_select_full_range_join
Metric, number of select full range join.
Definition: psi_statement_bits.h:179
unsigned long long m_rows_sent
Rows sent.
Definition: psi_statement_bits.h:169
unsigned int m_flags
Internal state.
Definition: psi_statement_bits.h:155
unsigned int m_query_sample_length
Length in bytes of m_query_sample.
Definition: psi_statement_bits.h:205
unsigned long m_select_scan
Metric, number of select scan.
Definition: psi_statement_bits.h:185
unsigned long m_select_range_check
Metric, number of select range check.
Definition: psi_statement_bits.h:183
unsigned char m_no_index_used
Metric, no index used flag.
Definition: psi_statement_bits.h:151
Structure to store token count/array for a statement on which digest is to be calculated.
Definition: sql_digest.h:97