This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug gdb/21051] New: nat/x86-linux-dregs.c:146: internal-error: void x86_linux_update_debug_registers(lwp_info*): Assertion `lwp_is_stopped (lwp)' failed.


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

            Bug ID: 21051
           Summary: nat/x86-linux-dregs.c:146: internal-error: void
                    x86_linux_update_debug_registers(lwp_info*): Assertion
                    `lwp_is_stopped (lwp)' failed.
           Product: gdb
           Version: HEAD
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: gdb
          Assignee: unassigned at sourceware dot org
          Reporter: ian at iankelling dot org
  Target Milestone: ---

I'm on debian testing, updated as of about 1-6-2017.

Tested on gdb 7.12-4, and also 7.12.50.20170114-git.

Error occurs when debugging emacs. I'm using emacs from commit e27203276 (Jan 7
2017), I assume it would happen with other versions of emacs, the bug probably
has nothing to do with emacs.

$ uname -a
Linux treetowl 4.8.0-2-amd64 #1 SMP Debian 4.8.11-1 (2016-12-02) x86_64
GNU/Linux

$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/6/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 6.2.1-5'
--with-bugurl=file:///usr/share/doc/gcc-6/README.Bugs
--enable-languages=c,ada,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr
--program-suffix=-6 --program-prefix=x86_64-linux-gnu- --enable-shared
--enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix --libdir=/usr/lib --enable-nls --with-sysroot=/
--enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes
--with-default-libstdcxx-abi=new --enable-gnu-unique-object
--disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie
--with-system-zlib --disable-browser-plugin --enable-java-awt=gtk
--enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-6-amd64/jre
--enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-6-amd64
--with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-6-amd64
--with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar
--enable-objc-gc=auto --enable-multiarch --with-arch-32=i686 --with-abi=m64
--with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic
--enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu
--target=x86_64-linux-gnu
Thread model: posix
gcc version 6.2.1 20161124 (Debian 6.2.1-5)



bash-4.4$ ./gdb/gdb -data-directory=./gdb/data-directory -ex="set
follow-fork-mode child" -ex=r -ex=quit --args emacsclient -nc
GNU gdb (GDB) 7.12.50.20170114-git
Copyright (C) 2017 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 "x86_64-pc-linux-gnu".
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 emacsclient...done.
Starting program: /usr/local/bin/emacsclient -nc
/usr/local/bin/emacsclient: can't find socket; have you started the server?
To start the server in Emacs, type "M-x server-start".
[New process 15874]
process 15874 is executing new program: /usr/local/bin/emacs-26.0.50
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".

Warning: due to a long standing Gtk+ bug
http://bugzilla.gnome.org/show_bug.cgi?id=85715
Emacs might crash when run in daemon mode and the X11 connection is
unexpectedly lost.
Using an Emacs configured with --with-x-toolkit=lucid does not have this
problem.
[New process 15877]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffe7346700 (LWP 15878)]
[New process 15879]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
nat/x86-linux-dregs.c:146: internal-error: void
x86_linux_update_debug_registers(lwp_info*): Assertion `lwp_is_stopped (lwp)'
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/>.

nat/x86-linux-dregs.c:146: internal-error: void
x86_linux_update_debug_registers(lwp_info*): Assertion `lwp_is_stopped (lwp)'
failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Create a core file of GDB? (y or n) y
Aborted (core dumped)
bash-4.4$ Error: server did not start correctly
Error: Could not start the Emacs daemon



Trace from the core file (too big to attach according to 10M limit stated on
this form).

(gdb) bt
#0  0x00007f2bee6ddfdf in raise () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007f2bee6df40a in abort () from /lib/x86_64-linux-gnu/libc.so.6
#2  0x000055c2652f0496 in dump_core () at utils.c:479
#3  0x000055c2652f293a in internal_vproblem(internal_problem *, const char *,
int, const char *, typedef __va_list_tag __va_list_tag *) (
    problem=problem@entry=0x55c265989540 <internal_error_problem>,
file=<optimized out>, line=<optimized out>, fmt=<optimized out>, 
    ap=ap@entry=0x7ffe284193a8) at utils.c:690
#4  0x000055c2652f2a0b in internal_verror (file=<optimized out>,
line=<optimized out>, fmt=<optimized out>, ap=ap@entry=0x7ffe284193a8) at
utils.c:716
#5  0x000055c2652077b2 in internal_error (file=file@entry=0x55c265495878
"nat/x86-linux-dregs.c", line=line@entry=146, fmt=<optimized out>)
    at common/errors.c:55
#6  0x000055c2650d23e0 in x86_linux_update_debug_registers (lwp=0x55c2677ddaa0)
at nat/x86-linux-dregs.c:146
#7  0x000055c2650c3085 in detach_one_lwp (lp=lp@entry=0x55c2677ddaa0,
signo_p=signo_p@entry=0x0) at linux-nat.c:1439
#8  0x000055c2650c336f in detach_callback (lp=0x55c2677ddaa0, data=<optimized
out>) at linux-nat.c:1497
#9  0x000055c2650c5989 in iterate_over_lwps (filter=...,
callback=callback@entry=0x55c2650c3330 <detach_callback(lwp_info*, void*)>,
data=data@entry=0x0)
    at linux-nat.c:992
#10 0x000055c2650c5ed9 in linux_nat_detach (ops=0x55c265bf83c0, args=0x0,
from_tty=0) at linux-nat.c:1519
#11 0x000055c2650cbf0f in thread_db_detach (ops=<optimized out>, args=0x0,
from_tty=0) at linux-thread-db.c:1100
#12 0x000055c26524eaa0 in handle_vfork_child_exec_or_exit (exec=exec@entry=1)
at infrun.c:976
#13 0x000055c26524f7af in handle_inferior_event_1 (ecs=0x7ffe28419820) at
infrun.c:5321
#14 handle_inferior_event (ecs=ecs@entry=0x7ffe28419820) at infrun.c:5411
#15 0x000055c265251608 in fetch_inferior_event (client_data=<optimized out>) at
infrun.c:3959
#16 0x000055c26520e63d in gdb_wait_for_event (block=block@entry=0) at
event-loop.c:859
#17 0x000055c26520e777 in gdb_do_one_event () at event-loop.c:322
#18 0x000055c26520e8c6 in gdb_do_one_event () at event-loop.c:353
#19 0x000055c2652e9d4c in wait_sync_command_done () at top.c:570
#20 0x000055c2652e9fb6 in maybe_wait_sync_command_done (was_sync=0) at
top.c:587
#21 execute_command (p=<optimized out>, p@entry=0x7ffe2841aad1 "r",
from_tty=from_tty@entry=1) at top.c:676
#22 0x000055c265264b28 in catch_command_errors (command=0x55c2652e9d90
<execute_command(char*, int)>, arg=0x7ffe2841aad1 "r", from_tty=1) at
main.c:376
#23 0x000055c265265722 in captured_main_1 (context=<optimized out>) at
main.c:1119
#24 captured_main (data=<optimized out>) at main.c:1140
#25 gdb_main (args=<optimized out>) at main.c:1158
#26 0x000055c265078ae8 in main (argc=<optimized out>, argv=<optimized out>) at
gdb.c:32

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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]