From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id gvBKJ7vg72duliYAWB0awg (envelope-from ) for ; Fri, 04 Apr 2025 09:38:03 -0400 Authentication-Results: simark.ca; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=lyK9Ae9f; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 918381E0C3; Fri, 4 Apr 2025 09:38:03 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=4.0.1 Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 2BFE61E05C for ; Fri, 4 Apr 2025 09:38:02 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id B0A393839DC2 for ; Fri, 4 Apr 2025 13:38:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B0A393839DC2 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=lyK9Ae9f Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.12]) by sourceware.org (Postfix) with ESMTPS id 76AB83845868 for ; Fri, 4 Apr 2025 13:37:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 76AB83845868 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=intel.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 76AB83845868 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=198.175.65.12 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1743773832; cv=none; b=LrsaRf4Z5QQASXe61dk90GI+3KhiI6NzHUyQntDSz65z4TgK627O3pz1Xw01TFnQlhVXQ0Duqi9fnv9aKCjgPNt+7bZQgJ/V2WLU2yEfp0EkZjOZreyBHXTvO/GpWy44StWBDuxGbFLKwASMOr+kwlVebM3KOU8rbNkhdmye11A= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1743773832; c=relaxed/simple; bh=PRUiWR503EYSfhgwTlFjN8NHBLMtZwwd7qphG4NxTjQ=; h=DKIM-Signature:From:To:Subject:Date:Message-Id:MIME-Version; b=CDxv+GCDnSmGx6mX9Zd7L1swZ2RHh/2N5xaRU/FySWRx+PsznwUXXlbx9JoD1Q8L67rHN8bb+1n7VWL6RNoIW8dgM9TdYDKQj0rmOnx/vELCmHUYKzQSbTpLwJSQ9lpQ+Vk9ydadilsZDhDxeGL8SSDid3hFU4EKPs9/3xXuEUw= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 76AB83845868 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1743773833; x=1775309833; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=PRUiWR503EYSfhgwTlFjN8NHBLMtZwwd7qphG4NxTjQ=; b=lyK9Ae9fWc0Um6fQ2qM5FcL5qSvYO8NI4WuZzwLRhkdSxAZdKHEQmU2B lXkhQXW5FuHAL2mu5S1Wb7hQUkr6tXcZRlj1qtvnBJxtKecIXpRBkhQhT M5bz2S+Q3jA++i+tSRB4FfUZw7x50PsV6iREnoFm0jDX6wf0ADfd6w/1h h4xidwATf3AE0egjaSFDdy+nFfmvVLHA85Cu7fJzdF/uh9tonCzdcqQvI OiWGaqXG+N9rjVEwPl0WZX+gybClhRPEYbpKhjqdpxay8ce/wfDNZPUtV cHV1NUwKtTXdGYJaAqI8390v9g6ChjapAZE+cmYos5QqBaUJe0FzOKF9Q w==; X-CSE-ConnectionGUID: C09jl3m5T4W8yur3YxgLrg== X-CSE-MsgGUID: +e7Ev9CSTtm8gaRL+D/nVA== X-IronPort-AV: E=McAfee;i="6700,10204,11394"; a="56583641" X-IronPort-AV: E=Sophos;i="6.15,188,1739865600"; d="scan'208";a="56583641" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by orvoesa104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Apr 2025 06:37:12 -0700 X-CSE-ConnectionGUID: 5gdhNb5LRC63+TnI3BhaVg== X-CSE-MsgGUID: uQI4fqBZTM+g/rFJPnTRmA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.15,188,1739865600"; d="scan'208";a="158285539" Received: from gkldtt-dev-004.igk.intel.com (HELO localhost) ([10.123.221.202]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Apr 2025 06:37:10 -0700 From: Tankut Baris Aktemur To: gdb-patches@sourceware.org Cc: guinevere@redhat.com, eliz@gnu.org Subject: [PATCH v3 0/2] Option to show stopped threads only Date: Fri, 4 Apr 2025 15:36:44 +0200 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org Hi, This is v3 of https://inbox.sourceware.org/gdb-patches/cover.1680686220.git.tankut.baris.aktemur@intel.com/ V2 is available at https://inbox.sourceware.org/gdb-patches/cover.1742320783.git.tankut.baris.aktemur@intel.com/ As a comment, Eli had expressed his view that when "info threads" is given a single thread ID, the "-stopped" flag could be ignored. I didn't implement this yet but can gladly do that if that's the general preference. As a review, Guinevere expressed her opinion that she prefers the submitted behavior. Revision 3 makes the following changes: * Address Guinevere's comment. That is, add new test cases that cover passing a single thread id, in one case a stopped thread, in another a running thread; and test passing two thread ids. * Add a trivial "print 42" to synchronize the GDB prompt. I received an email notification from the Linaro CI for v2 that there was a test failure. Although I could not reproduce locally, I believe it was caused because of the buffer contents in non-stop mode, which is hopefully fixed now. * Rebase to the current master branch. Regards, Baris Tankut Baris Aktemur (2): gdb: pass info_threads_opts to print_thread_info_1 gdb: add a '-stopped' option to "info threads" gdb/NEWS | 5 + gdb/doc/gdb.texinfo | 6 +- gdb/testsuite/gdb.base/options.exp | 11 +- .../gdb.threads/info-threads-stopped.c | 78 +++++++++++++ .../gdb.threads/info-threads-stopped.exp | 107 ++++++++++++++++++ gdb/thread.c | 86 ++++++++------ 6 files changed, 256 insertions(+), 37 deletions(-) create mode 100644 gdb/testsuite/gdb.threads/info-threads-stopped.c create mode 100644 gdb/testsuite/gdb.threads/info-threads-stopped.exp -- 2.34.1 Intel Deutschland GmbH Registered Address: Am Campeon 10, 85579 Neubiberg, Germany Tel: +49 89 99 8853-0, www.intel.de Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon Silva Chairperson of the Supervisory Board: Nicole Lau Registered Office: Munich Commercial Register: Amtsgericht Muenchen HRB 186928