This is the mail archive of the
insight@sourceware.org
mailing list for the Insight project.
Re: [PATCH 2/2] Notice architecture changes even when the register window is not open.
- From: Keith Seitz <keiths at redhat dot com>
- To: Andrew Burgess <aburgess at broadcom dot com>
- Cc: insight at sourceware dot org
- Date: Thu, 05 Sep 2013 12:00:07 -0700
- Subject: Re: [PATCH 2/2] Notice architecture changes even when the register window is not open.
- Authentication-results: sourceware.org; auth=none
- References: <5228941F dot 8080601 at broadcom dot com> <522894D1 dot 3030209 at broadcom dot com>
On 09/05/2013 07:27 AM, Andrew Burgess wrote:
I think this a bad situation to be in as, the reg-cache would ideally
be hidden from the user of "gdb_reginfo", and secondly, we only
really need to update the reg-cache once per architecture change, not
many times, which could happen if many users are all trying to keep
the reg-cache upto date.
Ouch. I believe at the time, this was never considered. I'm not even
sure if it was possible. Nonetheless, it clearly *is* possible now, so
thank you for tracking this down.
BTW, what architecture are you using to trigger this bug?
Anyway, let me know what you think, all feedback welcome.
One little comment below.
Index: ./gdb/gdbtk/library/interface.tcl
===================================================================
RCS file: /cvs/src/src/gdb/gdbtk/library/interface.tcl,v
retrieving revision 1.60
diff -u -p -r1.60 interface.tcl
--- ./gdb/gdbtk/library/interface.tcl 9 Oct 2009 01:23:55 -0000 1.60
+++ ./gdb/gdbtk/library/interface.tcl 5 Sep 2013 14:19:53 -0000
@@ -1815,6 +1815,9 @@ proc initialize_gdbtk {} {
# The architecture changed. Inform the UI.
proc gdbtk_tcl_architecture_changed {} {
set e [ArchChangedEvent \#auto]
+ # First perform global actions as a result of the architecture change.
+ gdb_reg_arch_changed $e
+ # Now dispatch to all the other even handlers.
typo ("even[t] handlers")
GDBEventHandler::dispatch $e
delete object $e
}
Okay with that change.
Keith