From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20849 invoked by alias); 5 Nov 2009 19:09:43 -0000 Received: (qmail 20841 invoked by uid 22791); 5 Nov 2009 19:09:43 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 05 Nov 2009 19:09:38 +0000 Received: (qmail 5951 invoked from network); 5 Nov 2009 19:09:36 -0000 Received: from unknown (HELO orlando) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 5 Nov 2009 19:09:36 -0000 From: Pedro Alves To: gdb-patches@sourceware.org Subject: Re: [RFA] Fix hw watchpoints in process record. Date: Thu, 05 Nov 2009 19:09:00 -0000 User-Agent: KMail/1.9.10 Cc: Michael Snyder , Hui Zhu References: <4AECE12F.3000704@vmware.com> <4AF31C1F.2000405@vmware.com> In-Reply-To: <4AF31C1F.2000405@vmware.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200911051909.40796.pedro@codesourcery.com> 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: 2009-11/txt/msg00094.txt.bz2 On Thursday 05 November 2009 18:40:31, Michael Snyder wrote: > Hui Zhu wrote: > > Hi Michael, > > > > I do some test with this patch. But sometime hb didn't work in replay mode. > > OK, thanks, I see the problem. > > Try this patch instead. > > Quick comment: this assumes the target/arch has continuable watchpoints, like x86/x86_64. You'll see this misbehave on mips, when Hui contributes the support. You're evaluating the watchpoint expression on every event --- I have a feeling it would make more sense to decouple precord from that, like all other targets are decoupled. That is, have precord check for low level watchpoint triggers --- given [addr,length,type] low level watchpoints --- when memory changes (at record_mem_entry time), instead of evaluating the whole high-level watchpoint expression. [IMO, we should mostly think of precord as just another a simulator that mostly only interfaces gdb's core through the target_ methods.] -- Pedro Alves