[Bug gdb/18869] internal-error: inline_frame_this_id: Assertion `frame_id_p (*this_id)' failed.

martin.behringer at siemens dot com sourceware-bugzilla@sourceware.org
Thu Dec 19 11:53:00 GMT 2019


https://sourceware.org/bugzilla/show_bug.cgi?id=18869

Martin Behringer <martin.behringer at siemens dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |martin.behringer at siemens dot co
                   |                            |m

--- Comment #10 from Martin Behringer <martin.behringer at siemens dot com> ---
We have the same issue when debugging a bare metal embedded ARM Cortex-A53
target with GDB 8.3.1. Code is compiled by gcc 9.2 with optimization -O2.

I was able to strip it down to a reduced plain c example with just a few lines
of code that can be executed in qemu emulator running on Windows10.


Steps to reproduce:
===================
- Build the code contained in reduced_c_example.zip by adapting/executing
build.bat

- start qemu:
qemu-4.1.0\bin\qemu-system-aarch64.exe -machine virt -cpu cortex-a53 -m 256M -s
-S

- start gdb: 
aarch64-elf-gdb.exe test.elf

- connect to emulator, load code, set breakpoint and do backtrace:
D:\tmp\a53test> ..\aarch64_gcc_elf_9.2.0\bin\aarch64-elf-gdb.exe test.elf
GNU gdb (GDB) 8.3.1
Copyright (C) 2019 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "--host=x86_64-w64-mingw32 --target=aarch64-elf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from test.elf...
(gdb) target remote :1234
Remote debugging using :1234
warning: Selected architecture aarch64:ilp32 is not compatible with reported
target architecture aarch64
0x0000000000000000 in ?? ()
(gdb) load
Loading section .init, size 0x34 lma 0x400000
Loading section .text, size 0x548 lma 0x40000000
Loading section .fini, size 0x34 lma 0x40000548
Loading section .rodata, size 0x2c lma 0x4000057c
Loading section .eh_frame, size 0x4 lma 0x400005a8
Loading section .init_array, size 0x4 lma 0x400105ac
Loading section .fini_array, size 0x4 lma 0x400105b0
Loading section .data, size 0x428 lma 0x40100000
Start address 0x40000138, load size 2576
Transfer rate: 34 KB/sec, 322 bytes/write.
(gdb) b gdb_bt_crash_function
Breakpoint 1 at 0x400001e0: file test_main.c, line 33.
(gdb) c
Continuing.

Breakpoint 1, gdb_bt_crash_function () at test_main.c:33
33        return 42;
(gdb) bt
#0  gdb_bt_crash_function () at test_main.c:33
#1  0x0000000040000220 in intermediate_function () at test.c:19
#2  intermediate_function () at test.c:6
../../../gdb-8.3.1/gdb/inline-frame.c:156: internal-error: void
inline_frame_this_id(frame_info*, void**, frame_id*): Assertion `frame_id_p
(*this_id)' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) y

This is a bug, please report it.  For instructions, see:
<http://www.gnu.org/software/gdb/bugs/>.

../../../gdb-8.3.1/gdb/inline-frame.c:156: internal-error: void
inline_frame_this_id(frame_info*, void**, frame_id*): Assertion `frame_id_p
(*this_id)' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Create a core file of GDB? (y or n) y

---------------------------------------------------------------------
Version information:
====================
D:\tmp\a53test> ..\aarch64_gcc_elf_9.2.0\bin\aarch64-elf-gdb.exe --version      
GNU gdb (GDB) 8.3.1                                                             
Copyright (C) 2019 Free Software Foundation, Inc.                               
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>   
This is free software: you are free to change and redistribute it.              
There is NO WARRANTY, to the extent permitted by law.                           

D:\tmp\a53test> ..\aarch64_gcc_elf_9.2.0\bin\aarch64-elf-gcc.exe -v
Using built-in specs.
COLLECT_GCC=..\aarch64_gcc_elf_9.2.0\bin\aarch64-elf-gcc.exe
COLLECT_LTO_WRAPPER=d:/tmp/aarch64_gcc_elf_9.2.0/bin/../libexec/gcc/aarch64-elf/9.2.0/lto-wrapper.exe
Target: aarch64-elf
Configured with: ../../gcc-9.2.0//configure --host=x86_64-w64-mingw32
--build=x86_64-w64-mingw32
--prefix=/build/aarch64-elf_9.2.0/cross-gcc/aarch64-elf --target=aarch64-elf
--disable-nls --enable-multilib --with-multilib-list=lp64,ilp32
--enable-languages=c,c++ --disable-decimal-float
--with-sysroot=/build/aarch64-elf_9.2.0/cross-gcc/aarch64-elf --without-headers
--disable-shared --disable-threads --disable-lto --disable-libmudflap
--disable-libssp --disable-libgomp --disable-libffi --disable-libstdcxx-pch
--disable-win32-registry --with-host-libstdcxx='-static-libgcc
-Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --with-newlib --with-gcc --with-gnu-as
--with-gnu-ld --with-gmp=/build/aarch64-elf_9.2.0/host
--with-mpfr=/build/aarch64-elf_9.2.0/host
--with-mpc=/build/aarch64-elf_9.2.0/host
--with-isl=/build/aarch64-elf_9.2.0/host
--with-zstd=/build/aarch64-elf_9.2.0/host : (reconfigured)
../../gcc-9.2.0//configure --host=x86_64-w64-mingw32 --build=x86_64-w64-mingw32
--enable-languages=c,c++ --enable-multilib --with-multilib-list=lp64,ilp32
--disable-lto --disable-libmudflap --disable-libssp --disable-libgomp
--disable-libffi --with-newlib --with-gcc --with-gnu-ld --with-gnu-as
--with-stabs --disable-shared --disable-threads --disable-win32-registry
--disable-nls --disable-libstdcxx-pch --with-host-libstdcxx='-static-libgcc
-Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --target=aarch64-elf
--prefix=/build/aarch64-elf_9.2.0/cross-gcc/aarch64-elf
--with-gmp=/build/aarch64-elf_9.2.0/host
--with-mpfr=/build/aarch64-elf_9.2.0/host
--with-mpc=/build/aarch64-elf_9.2.0/host
--with-isl=/build/aarch64-elf_9.2.0/host
--with-zstd=/build/aarch64-elf_9.2.0/host
--with-sysroot=/build/aarch64-elf_9.2.0/cross-gcc/aarch64-elf
Thread model: single
gcc version 9.2.0 (GCC)

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Gdb-prs mailing list