This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug threads/20725] New: thread_list grows very large, impacting inferior performance
- From: "fweimer at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Thu, 20 Oct 2016 13:18:11 +0000
- Subject: [Bug threads/20725] New: thread_list grows very large, impacting inferior performance
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=20725
Bug ID: 20725
Summary: thread_list grows very large, impacting inferior
performance
Product: gdb
Version: 7.12
Status: NEW
Severity: normal
Priority: P2
Component: threads
Assignee: unassigned at sourceware dot org
Reporter: fweimer at redhat dot com
Target Milestone: ---
I have a test case for bug 20719 which creates and exits many threads. When
running under GDB with a conditional breakpoint which is reached continuously
but with the condition false, each iteration of the test case runs slower and
slower.
Performance is back to the expected level after running “info threads”.
I attached to GDB itself and ran this:
def thread_list_length():
n = 0
p = gdb.parse_and_eval('thread_list')
while p != 0:
n += 1
p = p['next']
return n
print(thread_list_length())
As far as I can tell, thread_list grows without bounds. Basic profiling
suggests that GDB spends a lot of time in find_thread_ptid as a result.
--
You are receiving this mail because:
You are on the CC list for the bug.