From: Andrew Cagney <ac131313@redhat.com>
To: Daniel Jacobowitz <drow@mvista.com>
Cc: gdb@sources.redhat.com
Subject: Re: Failures in store.exp caused by regcache
Date: Thu, 09 Jan 2003 17:48:00 -0000 [thread overview]
Message-ID: <3E1DB5ED.3060308@redhat.com> (raw)
In-Reply-To: <20030109171414.GA26304@nevyn.them.org>
> Makes sense. If this ever gets to be a problem (I'm not sure people
> won't find creative ways to make a mockery of that "never" :) we can be
> cleverer then.
Like Apple?
They, I believe, currently hold the award for the worst case senario.
Due to objective C, the code does repeated inferior function calls from
more outer frames. This causes GDB to constantly rebuild the frame
cache. Can't see anyone doing worse than that, however, yes, never say
never :-)
>> >We obviously want to preserve things like the selected frame, however.
>
>>
>> I'm actually a bit puzzled. I recently fixed a case and added a
>> testcase (store.exp) that handles stores. Look for frame_find_by_id()
>> in valops.c.
>
>
> Yes. On GCC 2.95 that test shows failures still - different
> optimization. Thanks for pointing me at your change; I see the problem
> now. You only added the flush for the lval_register case. This is an
> lval_memory, for all that it's in the frame cache. Slightly different
> problem, same general solution.
Instead of flush frames, flush dcache, flush registers. I think there
should only be a generic target_changed().
> Something to think about: theoretically, any call to write_memory can
> cause the frame cache to become out of date. For now I'll just move
> the flushing within value_assign; but long-term I think it might be
> generally worthwhile to have better information on when the cache needs
> to be flushed, so that we can do it from within functions that modify
> the target. It would mean something like a list of memory locations
> read in the process of building the frame cache. Even per frame so
> that we don't need to flush the whole thing.
A single write to a single register/memory can completly change the
entire target - consider a store to the page table base register.
> Yeah, the complexity's gross; but there's a whole class of bugs here...
This is a real case of `show us the money'. Compared to single step,
there is no money in trying to make target writes faster. There is,
however, plenty of return on being dumb - coherency problem - flush all
caches - bug fixed.
Compare the single step performance of Insight with Eclipse and Project
Builder. Eclipe is a slow, not because of GDB or MI but because Eclipse
hasn't yet focused on the important case - single step and handling that
efficiently.
> I decided "it should put you in main". That's what the comment above
> is for. It's a kind of arbitrary decision but it was the most
> consistent thing I could come up with.
M'kay.
Andrew
prev parent reply other threads:[~2003-01-09 17:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-01-08 19:05 Daniel Jacobowitz
2003-01-08 19:11 ` Andrew Cagney
2003-01-09 3:23 ` Daniel Jacobowitz
2003-01-09 16:50 ` Andrew Cagney
2003-01-09 17:14 ` Daniel Jacobowitz
2003-01-09 17:48 ` Andrew Cagney [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3E1DB5ED.3060308@redhat.com \
--to=ac131313@redhat.com \
--cc=drow@mvista.com \
--cc=gdb@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox