From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12761 invoked by alias); 5 Jun 2007 11:06:31 -0000 Received: (qmail 12753 invoked by uid 22791); 5 Jun 2007 11:06:30 -0000 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 05 Jun 2007 11:06:28 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id E752F982E4 for ; Tue, 5 Jun 2007 11:06:25 +0000 (GMT) Received: from caradoc.them.org (dsl093-172-095.pit1.dsl.speakeasy.net [66.93.172.95]) by nan.false.org (Postfix) with ESMTP id B9DF3982CE for ; Tue, 5 Jun 2007 11:06:25 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.67) (envelope-from ) id 1HvWrE-0000wD-Pq; Tue, 05 Jun 2007 07:05:48 -0400 Date: Tue, 05 Jun 2007 11:06:00 -0000 From: Daniel Jacobowitz To: Bogdan Slusarczyk Cc: gdb@sourceware.org Subject: Re: How to set memory value from gdb? (MI) Message-ID: <20070605110548.GA3591@caradoc.them.org> Mail-Followup-To: Bogdan Slusarczyk , gdb@sourceware.org References: <4664278C.1010404@op.pl> <20070604152501.GA6855@caradoc.them.org> <46650ADF.2010507@op.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <46650ADF.2010507@op.pl> User-Agent: Mutt/1.5.15 (2007-04-09) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-06/txt/msg00040.txt.bz2 On Tue, Jun 05, 2007 at 09:03:59AM +0200, Bogdan Slusarczyk wrote: > On Mon, Jun 04, 2007 at 04:54:04PM +0200, Bogdan Slusarczyk wrote: > >> Hi, can anybody tell me how to set memory value from gdb? Suppose I want to > >> set bool variable using memory, I tryied '-var-create - * > >> *0x0289add0-0x0289add1' and next: '-var-assign var1 1' but I got: 'Left > >> operand of assignment is not an lvalue' How can I do it properly? > >> > > > > Try *(short *)0x0289add0. I believe the "TBD" marker in the manual > > means the syntax it describes doesn't exist yet. We should decide if > > we want it, or get rid of the documentation for it. > Is there any possibility to set memory bit by bit? Suppose I want to set some > larger area than short or long, can I do this using gdb? You probably could, but it is easier to just send multiple commands. And no, there are no single bit operations. > PS. What does "TBD" mean? I don't know, but I would guess "to be done" or "to be determined". -- Daniel Jacobowitz CodeSourcery