[gdb/testsuite] Fix gdb.base/store.exp with gcc-10
authorTom de Vries <tdevries@suse.de>
Wed, 6 May 2020 11:49:34 +0000 (13:49 +0200)
committerTom de Vries <tdevries@suse.de>
Wed, 6 May 2020 11:49:34 +0000 (13:49 +0200)
commitabf6d805a0dfa792fdf232dabd7de18d2fe20834
tree0d5322b7031dcc5b2f0859fd6b5ca9c65d455b5f
parent0fc2a808cbf5302016535367191bb8cd0900f332
[gdb/testsuite] Fix gdb.base/store.exp with gcc-10

When running gdb.base/store.exp with gcc-10 instead of gcc-9, we have:
...
 (gdb) PASS: gdb.base/store.exp: continue to wack_double
 print l^M
-$22 = <optimized out>^M
+$22 = -1^M
-(gdb) UNSUPPORTED: gdb.base/store.exp: var double l; print old l, expecting -1
-(gdb) PASS: gdb.base/store.exp: var double l; print old l, expecting -1
+print r^M
+$23 = <optimized out>^M
+(gdb) FAIL: gdb.base/store.exp: var double l; print old r, expecting -2
...

With gcc-9, there's no location info for both l and r, but with gcc-10,
there's location info for l, but not r.

The test-case only checks for location info availability of l, and then
assumes location info for r is also available.

Fix this by allowing missing location info for r.

Tested on x86_64-linux.

gdb/testsuite/ChangeLog:

2020-05-06  Tom de Vries  <tdevries@suse.de>

* gdb.base/store.exp (check_set, up_set): Allowing missing location
info for r.
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/store.exp
This page took 0.035874 seconds and 4 git commands to generate.