From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10526 invoked by alias); 2 Jul 2014 20:58:54 -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 10461 invoked by uid 48); 2 Jul 2014 20:58:50 -0000 From: "dryden2 at illinois dot edu" To: gdb-prs@sourceware.org Subject: [Bug mi/17108] New: Some records are not output after rapidly attaching to inferiors Date: Wed, 02 Jul 2014 20:58:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: mi X-Bugzilla-Version: 7.7 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dryden2 at illinois dot edu 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 attachments.created 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: 2014-q3/txt/msg00006.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=17108 Bug ID: 17108 Summary: Some records are not output after rapidly attaching to inferiors Product: gdb Version: 7.7 Status: NEW Severity: normal Priority: P2 Component: mi Assignee: unassigned at sourceware dot org Reporter: dryden2 at illinois dot edu Created attachment 7676 --> https://sourceware.org/bugzilla/attachment.cgi?id=7676&action=edit GDB input/output OS: Linux 2.6.32-431.17.1.el6.x86_64 on a 12-core Intel machine. GDB version: 7.7.1 Rapidly attaching to multiple inferiors while using the machine interface, such as with a program loop or by copy-pasting the commands all at once, results in the *stopped and =library-loaded records for some inferiors to not be output. Adding a pause of about 0.1 s after the first attach seems to avoid the problem. Reproducing: I use #include #include int main(int argc, char** argv) { int i = 0; while (i != 1) { sleep(1); } } as my test program. Start twelve instances: for i in `seq 1 12`; do ( ./test & ); done Then I start GDB: gdb --quiet --nx --nw --interpreter=mi2 And paste the following all at once (with the appropriate PIDs) to GDB: 00000000-enable-pretty-printing 00000001-gdb-set target-async on 00000002-gdb-set pagination off 00000003-gdb-set non-stop on 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000004-add-inferior 00000005-target-attach --thread-group i1 PID 00000006-target-attach --thread-group i2 PID 00000007-target-attach --thread-group i3 PID 00000008-target-attach --thread-group i4 PID 00000009-target-attach --thread-group i5 PID 00000010-target-attach --thread-group i6 PID 00000011-target-attach --thread-group i7 PID 00000012-target-attach --thread-group i8 PID 00000013-target-attach --thread-group i9 PID 00000014-target-attach --thread-group i10 PID 00000015-target-attach --thread-group i11 PID 00000016-target-attach --thread-group i12 PID Actual results: See the attachment for GDB's output. The *stopped and =library-loaded records are not output for inferior i1, but are for the other inferiors. Expected results: GDB should output the records for every inferior. It seems that pausing after the first attach results in everything working as expected. -- You are receiving this mail because: You are on the CC list for the bug.