This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug gdb/19061] New: gdb-7.10 hangs/spins-on-cpu when debugging any program on Alpha
- From: "klausman-glibc at schwarzvogel dot de" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Sat, 03 Oct 2015 15:13:39 +0000
- Subject: [Bug gdb/19061] New: gdb-7.10 hangs/spins-on-cpu when debugging any program on Alpha
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=19061
Bug ID: 19061
Summary: gdb-7.10 hangs/spins-on-cpu when debugging any program
on Alpha
Product: gdb
Version: 7.10
Status: NEW
Severity: normal
Priority: P2
Component: gdb
Assignee: unassigned at sourceware dot org
Reporter: klausman-glibc at schwarzvogel dot de
Target Milestone: ---
7.9.1 works fine:
$ gdb /bin/ls
GNU gdb (Gentoo 7.9.1 vanilla) 7.9.1
[...]
This GDB was configured as "alpha-unknown-linux-gnu".
Reading symbols from /bin/ls...(no debugging symbols found)...done.
(gdb) run
Starting program: /bin/ls
4405_alpha-sysctl-uac.patch gcc-4.6.3.tbz2 secfix.patch
[...]
[Inferior 1 (process 27877) exited normally]
(gdb) quit
7.10:
gdb-7.10 $ gdb/gdb /bin/ls
GNU gdb (7.10-vanilla) 7.10
This GDB was configured as "alpha-unknown-linux-gnu".
Reading symbols from /bin/ls...(no debugging symbols found)...done.
(gdb) run
Starting program: /bin/ls
[gdb hangs here, eating close to 100% of one CPU. straceing it yields nothing
immediately obvious.]
So I bisected this from the tagged gdb-7.xy-release commits, using the example
above as a test case. I found was this commit to be the first bad one:
faf09f0119da40d9b408021ad5665a906e00ee59 is the first bad commit
commit faf09f0119da40d9b408021ad5665a906e00ee59
Author: Pedro Alves <palves@redhat.com>
Date: Wed Mar 4 20:41:16 2015 +0000
Linux native: Use TRAP_BRKPT/TRAP_HWBPT
This patch adjusts the native Linux target backend to tell the core
whether a trap was caused by a breakpoint.
It teaches the target to get that information out of the si_code of
the SIGTRAP siginfo.
Tested on x86-64 Fedora 20, s390 RHEL 7, and PPC64 Fedora 18. An
earlier version was tested on ARM Fedora 21.
gdb/ChangeLog:
2015-03-04 Pedro Alves <palves@redhat.com>
* linux-nat.c (save_sigtrap): Check for breakpoints before
checking watchpoints.
(status_callback) [USE_SIGTRAP_SIGINFO]: Don't check whether a
breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
(check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]: Decide whether
a breakpoint triggered based on the SIGTRAP's siginfo.si_code.
(linux_nat_stopped_by_sw_breakpoint)
(linux_nat_supports_stopped_by_sw_breakpoint)
(linux_nat_stopped_by_hw_breakpoint)
(linux_nat_supports_stopped_by_hw_breakpoint): New functions.
(linux_nat_wait_1): Don't re-increment the PC if relying on
SIGTRAP's siginfo->si_code.
(linux_nat_add_target): Install new target methods.
* linux-thread-db.c (check_event): Don't account for breakpoint PC
offset if the target already adjusted the PC.
* nat/linux-ptrace.h (USE_SIGTRAP_SIGINFO): New.
(GDB_ARCH_TRAP_BRKPT): New.
(TRAP_HWBKPT): Define if not already defined.
:040000 040000 5623811c697afc352ad61c2090773eacf8b4fbbc
206b4d6974c8a35cbada87c5c9555e8558a798e4 M gdb
I am unsure how to dig out the actual problem from this, but I can provide
access to an Alpha machine if need be.
--
You are receiving this mail because:
You are on the CC list for the bug.