From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12169 invoked by alias); 9 Jun 2006 13:51:21 -0000 Received: (qmail 12149 invoked by uid 22791); 9 Jun 2006 13:51:19 -0000 X-Spam-Check-By: sourceware.org Received: from hudson.netezza.com (HELO mail2.netezza.com) (12.148.248.137) by sourceware.org (qpsmtpd/0.31) with SMTP; Fri, 09 Jun 2006 13:50:23 +0000 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: RE: Instrcutions that must not be stepped. Date: Fri, 09 Jun 2006 14:12:00 -0000 Message-ID: <4D87F853B8020F4888896B1507DC0F090268F0@mail2.netezza.com> From: "John Yates" To: "Daniel Jacobowitz" , "PAUL GILLIAM" Cc: Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-06/txt/msg00062.txt.bz2 Daniel Jacobowitz writes: > Nope. You'd have to add one. And, you'd have to be able to tell > whether you were in the middle of a GDB-automated step or a user stepi; > stepping multiple instructions when the user asked for one is probably > just confusing. To whom or what? I would be quite happy if gdb did the right thing and output a message to the effect that an atomic sequence was indeed treated as atomic. That is the count of instructions stepped changed by one for any number of failed attempts and then one final successful execution of the entire atomic sequence. > Reading the instruction before stepping is going to slow down single > stepping. Is there some other way we can handle this? The overhead could be ameliorated by having the status returned from a completed single step include an optional assertion that if gdb were to step again without altering the pc or the contents of memory at the address referenced by the pc then that step would initiate an atomic sequence. With this mechanism the first attempt to single step after a period of non-single stepped execution would need to check the first instruction; after that the process would be self sustaining without any addition gdb initiated instruction inspection. Admitted this mechanism does not absolve the greater gestalt of gdb + stub + single step break handle from needing to retrieve and inspect instructions. But it may push it to a point where the overhead becomes acceptable. /john