From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 86393 invoked by alias); 14 Mar 2015 15:58:13 -0000 Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org Received: (qmail 86346 invoked by uid 48); 14 Mar 2015 15:58:12 -0000 From: "palves at redhat dot com" To: gdb-prs@sourceware.org Subject: [Bug threads/18127] New: threads spawned by infcall end up stuck in "running" state Date: Sun, 15 Mar 2015 07:56:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: threads X-Bugzilla-Version: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: palves at redhat dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-q1/txt/msg00431.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=18127 Bug ID: 18127 Summary: threads spawned by infcall end up stuck in "running" state Product: gdb Version: HEAD Status: NEW Severity: normal Priority: P2 Component: threads Assignee: unassigned at sourceware dot org Reporter: palves at redhat dot com Ref: https://sourceware.org/ml/gdb/2015-03/msg00033.html Calling a function that spawns new threads results in the new threads getting stuck in "running" state. On GNU/Linux, and a trivial program that has: ~~~ void start_thread (void) { pthread_t thread; pthread_create (&thread, NULL, thread_function, NULL); } ~~~ calling that from GDB results in: (gdb) p start_thread () [New Thread 0x7ffff7fc1700 (LWP 9903)] $1 = void (gdb) info threads Id Target Id Frame 2 Thread 0x7ffff7fc1700 (LWP 9903) "start-thread-in" (running) * 1 Thread 0x7ffff7fc2740 (LWP 9899) "start-thread-in" main () at start-thread-infcall.c:35 -- You are receiving this mail because: You are on the CC list for the bug.