summaryrefslogtreecommitdiff
path: root/mysql-test/lib/My/Debugger.pm
Commit message (Collapse)AuthorAgeFilesLines
* MDEV-29348 rpl.rpl_rewrt_db test fails with [gdb,manual-gdb] with wrong parsingAnel Husakovic2022-11-281-1/+1
| | | | | Reviewer: <serg@mariadb.com> Closes PR #2244
* MDEV-28931 Debugger.pm readability fixAleksey Midenkov2022-07-181-38/+51
| | | | | | | | | | | | | | | | | setup_boot_args(), setup_client_args(), setup_args() traversing datastructures on each invocation. Even if performance is not important to perl script (though it definitely saves some CO2), this nonetheless provokes some code-reading questions. Reading and debugging such code is not convenient. The better way is to prepare all the data in advance in an easily readable form as well as do the validation step before any further processing. Use mtr_report() instead of die() like the other code does. TODO: do_args() does even more data processing magic. Prepare that data according the above strategy in advance in pre_setup() if possible.
* MDEV-26949 --debug-gdb installs redundant signal handlersMarko Mäkelä2021-11-011-1/+2
| | | | | | | | | | | | | | | | | | | | There is a server startup option --gdb a.k.a. --debug-gdb that requests signals to be set for more convenient debugging. Most notably, SIGINT (ctrl-c) will not be ignored, and you will be able to interrupt the execution of the server while GDB is attached to it. When we are debugging, the signal handlers that would normally display a terse stack trace are useless. When we are debugging with rr, the signal handlers may interfere with a SIGKILL that could be sent to the process by the environment, and ruin the rr replay trace, due to a Linux kernel bug https://lkml.org/lkml/2021/10/31/311 To be able to diagnose bugs in kill+restart tests, we may really need both a trace before the SIGKILL and a trace of the failure after a subsequent server startup. So, we had better avoid hitting the problem by simply not installing those signal handlers.
* mtr: --gdb mode, also quote ";", not only " "Sergei Golubchik2021-05-111-1/+1
|
* mtr --gdb='commands' and restartsSergei Golubchik2021-05-081-1/+1
| | | | | if mysqld is restarted during a test, the debugger script should be reused or overwritten, but not appended to the existing file
* fix mtr --client-gdb to workSergei Golubchik2021-05-081-1/+1
| | | | mysqltest has no --gdb option
* Added missed ' -- ' between the end of the lldb command options and the ↵Dmitry Shulga2021-03-221-1/+1
| | | | beginning of the arguments.
* mtr --gdb: fix for --rr and for a warningSergei Golubchik2021-03-011-1/+2
| | | | | | | use _RR_TRACE_DIR=dir instead of -o dir, as the former can store multiple traces in dir (if, e.g., the test restarts mysqld) suppress uninitialized warning when $exe is undefined (--manual-XXX)
* mtr fixes for old (5.10.1) perlSergei Golubchik2021-02-221-4/+5
|
* support for mtr --valgdbSergei Golubchik2021-02-221-3/+20
| | | | | | add a new "debugger" to mtr, that runs the executable under valgrind in gdb. valgrind pid is auto-detected, but the delay (sleep) and vgdb path are hard-coded for now
* unify mtr handling of debuggersSergei Golubchik2021-02-221-0/+247
"debugger" is anything that wraps execution of a target binary (mysqld or mysqltest). Currently the list includes: gdb, ddd, dbx, lldb, valgrind, strace, ktrace, rr, devenv, windbg, vsjitdebugger. for every debugger xxx, mtr will recognize four options: --xxx, --boot-xxx, --manual-xxx, --client-xxx. They all support an optional "=string" argument. String being a semicolon-separated list of commands (e.g. for gdb) or one (not semicolon-separated) command line of options (e.g. for valgrind). Or both (e.g. --gdb='-quiet -nh;info files' In embedded both --xxx and --client-xxx work. Functionality changed/removed: * --rr-args is gone * --rr-dir is gone * --manual-debug is gone * --debugger={devenv|vc|windbg|vc_express|vsjitdebugger} is gone * --strace-option is gone * --stracer={strace|ktrace} is gone * --valgrind only enables it for the server, not for everything * --valgrind-all is gone * --valgrind-mysqltest is gone * --valgrind-mysqld is gone * --valgrind-options is gone * --valgrind-option is gone * --valgrind-path is gone * --callgrind is gone * one cannot combine --valgrind --gdb anymore * valgrind report doesn't add a fake test line to the output * vc and vcexpress on windows are no longer supported