Bug 40936

Summary: Disable hardware watchpoint locks up machine.
Product: [Retired] Red Hat Linux Reporter: hjl
Component: gdbAssignee: Trond Eivind Glomsrxd <teg>
Status: CLOSED WORKSFORME QA Contact: Aaron Brown <abrown>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-05-16 21:30:31 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description hjl 2001-05-16 17:45:19 UTC
When I disable a hardware watchpoint,  my SMP machine will lockup hard
when I start another gdb session.

Comment 1 Trond Eivind Glomsrxd 2001-05-16 18:09:13 UTC
Could you give an example? (and please try the new gdb version (5.0rh-9 or
higher) at http://people.redhat.com/teg/gdb/ )

Comment 2 hjl 2001-05-16 21:13:55 UTC
The new gdb does the same.

# cat gdb.c
int x = 0;

foo ()
{
  x = 1;
}

bar ()
{
  x = 2;
}

main ()
{
  foo ();
  bar ();
}

# gcc -g gdb.c 
# gdb a.out
(gdb) watch x
(gdb) r
Starting program: /home/hjl/tmp/a.out 
Hardware watchpoint 1: x
Hardware watchpoint 1: x
Hardware watchpoint 1: x

Old value = 0
New value = 1
foo () at gdb.c:6
6       }
(gdb) c
Continuing.
Hardware watchpoint 1: x

Old value = 1
New value = 2
bar () at gdb.c:11
11      }(gdb) c
Continuing.

Program exited with code 01.
(gdb) dis 1
(gdb) r
Starting program: /home/hjl/tmp/a.out 

My SMP machine locks up at this point. It works fine on UP machine. It may be
a kernel bug. Can you try that on your SMP machine?



Comment 3 Trond Eivind Glomsrxd 2001-05-16 21:30:25 UTC
Doesn't happen on my machine... I'll try another later.

Comment 4 Trond Eivind Glomsrxd 2001-05-16 21:45:01 UTC
I've tried it on another SMP machine, this time with our standard kernel: It
doesn't crash there either...