From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18213 invoked by alias); 17 May 2002 17:29:43 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 18188 invoked from network); 17 May 2002 17:29:41 -0000 Received: from unknown (HELO localhost.redhat.com) (216.138.202.10) by sources.redhat.com with SMTP; 17 May 2002 17:29:41 -0000 Received: from cygnus.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 94DF33E98; Fri, 17 May 2002 13:29:50 -0400 (EDT) Message-ID: <3CE53E0E.8030805@cygnus.com> Date: Fri, 17 May 2002 10:29:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0rc1) Gecko/20020429 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Nick Clifton Cc: gdb-patches@sources.redhat.com Subject: Re: Add support for target switches in simulator References: <200205161624.RAA15198@cam-mail2.cambridge.arm.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-05/txt/msg00724.txt.bz2 > I have not worked out how this feature would be accessed from >> > GDB. My guess is that the switches could be added to the >> > arguments passed via sim_open(), but how would a GDB user tell >> > GDB to add these switches ? > > >> Richard Earnshaw writes: > > >> Hmm, I thought there was already a way to tell the simulator what >> amount of memory to use. I've an approved patch for: (gdb) target sim -m Nick suggested some tweaks that I didn't get back to :-/ > So did I, but looking through the GDB sources I do not see a place > where it is used. It isn't. The interface is marked obsolete. Instead sim-common simulators use: (gdb) sim memory-size ... >> Couldn't a similar method be employed. > > > That method is specific to setting the memory size - it uses a > simulator/debugger interface call specifically set up for the > purpose. I looked for the function - sim_size() - and found it being > used by the run program but not by GDB. I am puzzled. > > Anyway the point here is that setting the memory size appears to be a > specific API function and I want a generic method to set any kind of > target specific option. Andrew