]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/testsuite/ChangeLog
gdb/testsuite: Allow for failure to read some memory addresses
authorAndrew Burgess <andrew.burgess@embecosm.com>
Fri, 2 Feb 2018 15:51:31 +0000 (15:51 +0000)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Mon, 9 Jul 2018 14:08:20 +0000 (15:08 +0100)
commitc8ad9b9a31aa3e6039567fc1f152dd454c946d5f
treed2970c48399f5d9081bcdf0f806194612b6758aa
parent8fd32c1ce66c66b02b2eb506a038cfc615aad1cb
gdb/testsuite: Allow for failure to read some memory addresses

In the gdb.base/examine-backward.exp test script, we check to see if
address zero is readable, and then read memory first forward from
address zero, and then backward from address zero.

The problem is, being able to read address zero does not guarantee
that you'll be able to read from the other end of the address space,
and the test probably shouldn't assume that is the case.

This patch updates the test script so that even if address zero is
known non-readable, we still run the tests, the tests in question are
mostly about, can GDB calculate the correct address to read from, we
can confirm this even if the final read ultimately fails.  We also no
longer assume that if address zero is readable, then the other end of
the address space will be readable.

One further change is that, when we examined the memory at address
zero, the regexp used to match the address expected that the zero
address would have two '0' digits as the least significant digits.  As
GDB strips leading zeros from addresses this was causing the test to
fail.  I've reduced the zero address to a single 0 digit.

gdb/testsuite/ChangeLog:

* gdb.base/examine-backward.exp: Still run tests around address
0x0, even if address 0x0 is not readable.  Update the pattern for
matching address 0x0 in expected output.
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/examine-backward.exp