diff options
author | Luis Machado <luis.machado@linaro.org> | 2021-04-01 17:00:43 -0300 |
---|---|---|
committer | Luis Machado <luis.machado@linaro.org> | 2021-04-27 20:42:07 -0300 |
commit | b9f90c72ee69a31100a7b1b4106f192dde75debf (patch) | |
tree | a631f7f6cfa087618bfa73126e24e59db68f63ce /test-driver | |
parent | 4b62a30d5b4dcb24e73c1369d8c0da3dc10a4146 (diff) | |
download | gdb-b9f90c72ee69a31100a7b1b4106f192dde75debf.zip gdb-b9f90c72ee69a31100a7b1b4106f192dde75debf.tar.gz gdb-b9f90c72ee69a31100a7b1b4106f192dde75debf.tar.bz2 |
Fix timeout with maint print objfiles
I'm seeing timeouts from gdb.rust/traits.exp when we attempt to print
things with "maint print objfiles".
This happens for two reasons:
1 - GDB does not explicitly split each entry into its own line, but rather
relies on the terminal's width to insert line breaks.
2 - When running the GDB testsuite, such width may be unlimited, which will
prevent GDB from inserting any line breaks.
As a result, the output may be too lengthy and will come in big lines. Tweak
the support library to match the patterns line-by-line, which gives us more
time to match things. Also fix GDB's output to print one entry per line,
regardless of the terminal width.
A similar approach was used in another testcase using the same command (commit
eaeaf44cfdc9a4096a0dd52fa0606f29d4bfd48e). With the new line breaks, we don't
need a particular pattern, so clean up that test as well.
gdb/ChangeLog:
2021-04-27 Luis Machado <luis.machado@linaro.org>
* psymtab.c (psymbol_functions::dump): Output newline.
* symmisc.c (dump_objfile): Likewise.
gdb/testsuite/ChangeLog:
2021-04-27 Luis Machado <luis.machado@linaro.org>
* gdb.base/maint.exp: Drop a pattern that is not needed.
* lib/gdb.exp (readnow): Match line-by-line.
Diffstat (limited to 'test-driver')
0 files changed, 0 insertions, 0 deletions