aboutsummaryrefslogtreecommitdiff
path: root/gdb/sparc-linux-nat.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@efficios.com>2020-05-25 11:15:01 -0400
committerSimon Marchi <simon.marchi@polymtl.ca>2020-05-25 11:40:36 -0400
commit6cf66e763aec5b2c3d99063d9cc6f7b96b4b9dc9 (patch)
tree6644814d5868f77d83073ed6656bcdf7f032a7e1 /gdb/sparc-linux-nat.c
parent75d04512401cbc9cd2d9835e77b90ac3ad1de7d8 (diff)
downloadbinutils-6cf66e763aec5b2c3d99063d9cc6f7b96b4b9dc9.zip
binutils-6cf66e763aec5b2c3d99063d9cc6f7b96b4b9dc9.tar.gz
binutils-6cf66e763aec5b2c3d99063d9cc6f7b96b4b9dc9.tar.bz2
gdb/testsuite: add inferior arguments test
Add a test for verifying different methods of passing arguments to the inferior: the start, starti and run commands, as well as `set args`. All these methods work naturally when using the unix or native-extended-gdbserver target boards. Since those are non-stub boards, GDB runs new inferiors and therefore pass arguments to them. With target boards where GDB connects to a stub, for example with native-gdbserver, they don't really make sense. The inferior process is already started when GDB connects. However, the "run" method is still tested with stub targets, because the gdb_run_cmd procedure is adapted for stub targets. Instead of issuing the `run` command, it spawns whatever program is supposed to bring up the stub (gdbserver, for example) using gdb_reload and makes GDB connect to it. So this allows us to exercise argument passing through the gdbserver command line, when testing with the native-gdbserver board. Note that there is already a gdb.base/args.exp, but this tests specifically the --args switch of GDB. Perhaps it could be integrated in this new test, as a new "method". gdb/testsuite/ChangeLog: * lib/gdb.exp (gdb_run_cmd): Return success or failure. * gdb.base/inferior-args.exp: New file. * gdb.base/inferior-args.c: New file. Change-Id: Ib61ea6220a47f9f67aed2960dcacd240cb57af70
Diffstat (limited to 'gdb/sparc-linux-nat.c')
0 files changed, 0 insertions, 0 deletions