From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11865 invoked by alias); 4 Mar 2010 07:55:32 -0000 Received: (qmail 11855 invoked by uid 22791); 4 Mar 2010 07:55:31 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from fencepost.gnu.org (HELO fencepost.gnu.org) (140.186.70.10) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 04 Mar 2010 07:55:28 +0000 Received: from eliz by fencepost.gnu.org with local (Exim 4.69) (envelope-from ) id 1Nn5u2-0006TS-0i; Thu, 04 Mar 2010 02:55:26 -0500 From: Eli Zaretskii To: Pedro Alves CC: gdb-patches@sourceware.org In-reply-to: <201003040350.34417.pedro@codesourcery.com> (message from Pedro Alves on Thu, 4 Mar 2010 03:50:34 +0000) Subject: Re: Somewhat sanitize watchpoints with conditions on local expressions Reply-to: Eli Zaretskii References: <201003040350.34417.pedro@codesourcery.com> Message-Id: Date: Thu, 04 Mar 2010 07:55:00 -0000 X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2010-03/txt/msg00163.txt.bz2 > From: Pedro Alves > Date: Thu, 4 Mar 2010 03:50:34 +0000 > > The patch below that implements what sounded least > surprising to me (evaluate condition in correct frame > if possible, and warn if not possible, without trying > and doing undefined things), and adds tests > for this, and other variants involving global > expressions, and local conditions. > > > Comments? I like it. One question: > +static int > +is_watchpoint (struct breakpoint *bpt) > +{ > + return (is_hardware_watchpoint (bpt) > + || bpt->type == bp_watchpoint); > +} Does this catch read and access watchpoints? Should it? Thanks.