Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MDEV-34900: Fix stage names for profiling #3594

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions sql/mysqld.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9526,6 +9526,7 @@ PSI_stage_info stage_master_has_sent_all_binlog_to_slave= { 0, "Master has sent
PSI_stage_info stage_opening_tables= { 0, "Opening tables", 0};
PSI_stage_info stage_optimizing= { 0, "Optimizing", 0};
PSI_stage_info stage_preparing= { 0, "Preparing", 0};
PSI_stage_info stage_prepare_for_executing = { 0, "Preparing for execution", 0};
PSI_stage_info stage_purging_old_relay_logs= { 0, "Purging old relay logs", 0};
PSI_stage_info stage_query_end= { 0, "Query end", 0};
PSI_stage_info stage_starting_cleanup= { 0, "Starting cleanup", 0};
Expand Down
1 change: 1 addition & 0 deletions sql/mysqld.h
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,7 @@ extern PSI_stage_info stage_master_has_sent_all_binlog_to_slave;
extern PSI_stage_info stage_opening_tables;
extern PSI_stage_info stage_optimizing;
extern PSI_stage_info stage_preparing;
extern PSI_stage_info stage_prepare_for_executing;
extern PSI_stage_info stage_purging_old_relay_logs;
extern PSI_stage_info stage_query_end;
extern PSI_stage_info stage_starting_cleanup;
Expand Down
5 changes: 3 additions & 2 deletions sql/sql_select.cc
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
@{
*/


#ifdef USE_PRAGMA_IMPLEMENTATION
#pragma implementation // gcc: Class implementation
#endif
Expand Down Expand Up @@ -4843,7 +4844,7 @@ int JOIN::exec_inner()
DBUG_ENTER("JOIN::exec_inner");
DBUG_ASSERT(optimization_state == JOIN::OPTIMIZATION_DONE);

THD_STAGE_INFO(thd, stage_executing);
THD_STAGE_INFO(thd, stage_prepare_for_executing);

/*
Enable LIMIT ROWS EXAMINED during query execution if:
Expand Down Expand Up @@ -5035,7 +5036,7 @@ int JOIN::exec_inner()
DBUG_RETURN(error);
}

THD_STAGE_INFO(thd, stage_sending_data);
THD_STAGE_INFO(thd, stage_executing);
DBUG_PRINT("info", ("%s", thd->proc_info));
result->send_result_set_metadata(
procedure ? procedure_fields_list : *fields,
Expand Down