This is the mail archive of the insight@sourceware.cygnus.com mailing list for the Insight project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Disassembly Window


Fernando, and Steven,

I am of two minds about this.  

I agree that being able to inspect memory on the board before the
program has been loaded is a good idea.  But I wonder if the source
window is the correct place to do this.  You really want to be able to
point at any region of memory disassembly that.  However, you may not
have references to that code anywhere in your sources.  So it seems
like overloading the source windows methods for finding what it is
going to display is not the best way to do it.  

Also, the memory display in the Source window is routine based or file
based, for disassembly, it wants to do a whole function.  So in cases
where you don't know when a function begins & ends, its display
paradigm doesn't really work.

Better would be to have two modes for the Memory window, one that
displays raw memory, and one that displays the given region of memory
as disassembly.  This is a more natural interface, since you just go to the
memory window and type in the address where your ROM code, or
whatever, resides, and you can see it.  You can also easily control
how much gets displayed by how far you open the window.

Actually, there are really three useful states for the Memory window,
raw memory, view as disassembly, and view as an array of some given
type.

These other two modes have been on my TODO list for a while now, but I
haven't had time to get around to them.  This is a bit more work
(though just to hack in the disassembly display here is not that bad.
But I think it is a better solution in the long term.  What do you
think?

And I echo Fernando, if you want to try your hand at this Steven, I
will help you get started.  Insight is not that hard to work on, but
it is much less well documented than it should be, mostly just
comments in the code, sadly enough.  Another item on the TODO list...

Jim

 > I have exactly the same problem.  I am connecting to a hardware emulator
 > and the code is already there (I may not even have the source code at
 > all).
 > 
 > But it should be an option (as opposed to always on).  
 > 
 > Jim, It would be nice if we could add it, don't you think?
 > 
 > Fernando
 > 
 > P.S.: Steven, are you volunteering? ;-)
 > 
 > 
 > 
 > Steven Johnson wrote:
 > > 
 > > Regarding the Code Display Window,
 > > 
 > > Is Insight supposed to show disassembly of the current PC in the main
 > > code window before any code is loaded? Is there a way to enable this?
 > > This may not make sense to some people, but for an embedded target like
 > > mine, just because I havent explicitly loaded a program does not mean
 > > the disassembly is not interesting, in fact its exactly the opposite.
 > > 
 > > Regards,
 > > Steven Johnson
 > 
 > -- 
 > Fernando Nasser
 > Red Hat, Inc. - Toronto                 E-Mail:  fnasser@redhat.com
 > 2323 Yonge Street, Suite #300           Tel:  416-482-2661 ext. 311
 > Toronto, Ontario   M4P 2C9              Fax:  416-482-6299
 > 

-- 
++==++==++==++==++==++==++==++==++==++==++==++==++==++==++==++==++==++==++
Jim Ingham                                              jingham@cygnus.com
Cygnus Solutions, a Red Hat Company                      

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]