From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by sourceware.org (Postfix) with ESMTPS id DC25F3857C4D for ; Thu, 20 Aug 2020 21:24:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org DC25F3857C4D IronPort-SDR: RCcg926lfpRzcGMfzJF6hZGlhR/Matq2t+Trn5wL1u7KJanG8FDJ/JX8Hr8uaU6g9Gd6IiwES5 bkNoqrY7CYQw== X-IronPort-AV: E=McAfee;i="6000,8403,9719"; a="154682918" X-IronPort-AV: E=Sophos;i="5.76,334,1592895600"; d="scan'208";a="154682918" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Aug 2020 14:24:47 -0700 IronPort-SDR: WQ2ONQ9rKC3W2IYacIet8n3azmYDlNAXFXoavsScVfxpe5ZQd/P76FpcK5JB3fYT7heQGwEfOo omUZ3t1GMGTQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.76,334,1592895600"; d="scan'208";a="311244318" Received: from irvmail001.ir.intel.com ([163.33.26.43]) by orsmga002.jf.intel.com with ESMTP; 20 Aug 2020 14:24:46 -0700 Received: from ulvlx001.iul.intel.com (ulvlx001.iul.intel.com [172.28.207.17]) by irvmail001.ir.intel.com (8.14.3/8.13.6/MailSET/Hub) with ESMTP id 07KLOisD005736; Thu, 20 Aug 2020 22:24:44 +0100 Received: from ulvlx001.iul.intel.com (localhost [127.0.0.1]) by ulvlx001.iul.intel.com with ESMTP id 07KLOic7022851; Thu, 20 Aug 2020 23:24:44 +0200 Received: (from taktemur@localhost) by ulvlx001.iul.intel.com with LOCAL id 07KLOi3B022810; Thu, 20 Aug 2020 23:24:44 +0200 From: Tankut Baris Aktemur To: gdb-patches@sourceware.org Subject: [PATCH v2 0/2] Breakpoint conditions at locations with differing contexts Date: Thu, 20 Aug 2020 23:24:37 +0200 Message-Id: X-Mailer: git-send-email 1.7.0.7 In-Reply-To: X-Spam-Status: No, score=-13.6 required=5.0 tests=BAYES_00, KAM_DMARC_NONE, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Aug 2020 21:24:50 -0000 Hi, This is a follow-up of https://sourceware.org/pipermail/gdb-patches/2020-July/170984.html which is a short series about conditional breakpoints where the condition may be invalid at some breakpoint locations because of their context. Currently, GDB does not allow defining a condition if it's not valid at all locations. This series aims at bringing more flexibility: the locations at which the condition expression is invalid are disabled automatically. Patch 1/2 is the same as in v1. Patch 2/2 was previously an RFC. Andrew Burgess commented on it at https://sourceware.org/pipermail/gdb-patches/2020-August/171012.html In v2, I extend Patch 2/2 with the '-force-condition' flag for the break command, add test cases and more documentation. It is no longer an RFC. Regards. Baris Tankut Baris Aktemur (2): gdb/breakpoint: disable a bp location if condition is invalid at that location gdb/breakpoint: add flags to 'condition' and 'break' commands to force condition gdb/ada-lang.c | 2 +- gdb/breakpoint.c | 249 ++++++++++++++---- gdb/breakpoint.h | 12 +- gdb/doc/gdb.texinfo | 50 ++++ gdb/guile/scm-breakpoint.c | 2 +- gdb/linespec.c | 18 +- gdb/python/py-breakpoint.c | 2 +- .../condbreak-multi-context-included.c | 18 ++ .../gdb.base/condbreak-multi-context.c | 51 ++++ .../gdb.base/condbreak-multi-context.exp | 240 +++++++++++++++++ gdb/testsuite/gdb.linespec/cpcompletion.exp | 12 +- gdb/testsuite/gdb.linespec/explicit.exp | 1 + gdb/testsuite/lib/completion-support.exp | 2 +- 13 files changed, 592 insertions(+), 67 deletions(-) create mode 100644 gdb/testsuite/gdb.base/condbreak-multi-context-included.c create mode 100644 gdb/testsuite/gdb.base/condbreak-multi-context.c create mode 100644 gdb/testsuite/gdb.base/condbreak-multi-context.exp -- 2.17.1