From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eggs.gnu.org (eggs.gnu.org [209.51.188.92]) by sourceware.org (Postfix) with ESMTPS id B132D3858D39 for ; Thu, 3 Mar 2022 08:35:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B132D3858D39 Received: from [2001:470:142:3::e] (port=46522 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nPgwB-0006zn-67 for gdb@sourceware.org; Thu, 03 Mar 2022 03:35:51 -0500 Received: from ip5f5a8abe.dynamic.kabel-deutschland.de ([95.90.138.190]:53461 helo=[192.168.111.41]) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nPgwA-0007IX-P5 for gdb@sourceware.org; Thu, 03 Mar 2022 03:35:50 -0500 Message-ID: <8a90c905-f238-0e14-ef7b-21c0eac58948@gnu.org> Date: Thu, 3 Mar 2022 09:35:48 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.6.1 Content-Language: en-US To: gdb discussion list From: Simon Sobisch Subject: GDB/MI - Possible missing stop-reason on attach or misleading documentation Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 03 Mar 2022 08:35:54 -0000 When attaching to a running progress (that currently "waits" in `getchar()`, but that likely doesn't matter) in async mode the following records are returned: =thread-group-started,id="i1",pid="12345" =thread-created,id="1",group-id="i1" =library-loaded,id=... many entries ~"0x00007fa0a626b7e0 in __read_nocancel () from /usr/lib64/libc.so.6\n" *stopped,frame={addr="0x00007fa0a626b7e0",func="__read_nocancel",args=[],from="/usr/lib64/libc.so.6",arch="i386:x86-64"},thread-id="1",stopped-threads="all",core="1" My understanding from https://sourceware.org/gdb//onlinedocs/gdb/GDB_002fMI-Async-Records.html was that the reason field is _always_ returned. Questions: * Did I look at the right place of the docs? * Are all fields listed there should always be filled? If not I highly suggest to add a note about that. * Can the reason field be added in the attach case? I _guess_ that would be either "location-reached" or "breakpoint-hit". Simon