diff options
author | Nils-Christian Kempke <nils-christian.kempke@intel.com> | 2022-05-31 16:43:45 +0200 |
---|---|---|
committer | Nils-Christian Kempke <nils-christian.kempke@intel.com> | 2022-05-31 16:44:56 +0200 |
commit | 0df017fbca3070682ffa62a3b302a30e028adfb6 (patch) | |
tree | 2e960e5330a7d30d28226a9cc989d03c415046cf /gdb/sh-netbsd-nat.c | |
parent | a60ead5ded5f9fc548018637d4810cb5f313ad8c (diff) | |
download | gdb-0df017fbca3070682ffa62a3b302a30e028adfb6.zip gdb-0df017fbca3070682ffa62a3b302a30e028adfb6.tar.gz gdb-0df017fbca3070682ffa62a3b302a30e028adfb6.tar.bz2 |
gdb, testsuite, fortran: fixup mixed-lang-stack for Intel/LLVM compilers
When value-printing a pointer within GDB by default GDB will look for
defined symbols residing at the address of the pointer. For the given
test the Intel/LLVM compiler stacks both display a symbol associated
with a printed pointer while the gnu stack does not. This leads to
failures in the test when running the test with CC_FOR_TARGET='clang'
CXX_FOR_TARGET='clang' F90_FOR_TARGET='flang'"
(gdb) b 37
(gdb) r
(gdb) f 6
(gdb) info args
a = 1
b = 2
c = 3
d = 4 + 5i
f = 0x419ed0 "abcdef"
g = 0x4041a0 <.BSS4>
or CC_FOR_TARGET='icx' CXX_FOR_TARGET='icpx' F90_FOR_TARGET='ifx'"
(gdb) b 37
(gdb) r
(gdb) f 6
(gdb) info args
a = 1
b = 2
c = 3
d = 4 + 5i
f = 0x52eee0 "abcdef"
g = 0x4ca210 <mixed_func_1a_$OBJ>
For the compiled binary the Intel/LLVM compilers both decide to move the
local variable g into the .bss section of their executable. The gnu
stack will keep the variable locally on the stack and not define a
symbol for it.
Since the behavior for Intel/LLVM is actually expected I adapted the
testcase at this point to be a bit more allowing for other outputs.
I added the optional "<SYMBOLNAME>" to the regex testing for g.
The given changes reduce the test fails for Intel/LLVM stack by 4 each.
Diffstat (limited to 'gdb/sh-netbsd-nat.c')
0 files changed, 0 insertions, 0 deletions