This is the mail archive of the insight@sources.redhat.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: [RFA] more 64-bit patches


On Monday 29 October 2001 12:15 pm, Keith Seitz wrote:
> On Mon, 29 Oct 2001, Martin M. Hunt wrote:
> > On Monday 29 October 2001 11:55 am, Keith Seitz wrote:
> > > On Mon, 29 Oct 2001, Martin M. Hunt wrote:
> > >
> > > Only one or two questions:
> > > > 	* library/srcbar.itcl: Remove lable width for address
> > > >         box.  This allows it to expand for 64-bit addresses.
> > >
> > > How does this affect the look of things before we're running?
> >
> > They look the same except that the label could change if the length of
> > the address changed.  For example, from 0xFFFFFFC to 0x10000000.  I
> > haven't actually tried that because it almost never happens in practice.
> > I assume the address box would resize and that would resize the menubar.
>
> As long as they look the same when we start up. Not that its shrunk to
> nothing until we start the inferior.

Well, it is very small, of course.  Only way around that is to set some 
limits.  Perhaps we should force either 32 or 64-bit displays?   To do that, 
we just change the following in srcbar.itcl:

 # This holds the text that is shown in the address label.
  public variable address {} {
    if {[string length $address] > 10} {
      # 64-bit address plus "0x"
      set width 18
    } else {
      # 32-bit address plus "0x"
      set width 10
    }
    $Tool itemconfigure addr -text $address -font src-font -width $width
  }

So if you start insight with no inferior, the address width will be 10.  Then 
if you load a 64-bit binary, it will expand to 18.  OK?

-- 
Martin Hunt
GDB Engineer
Red Hat, Inc.


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