This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

src/gdb ChangeLog tui/tui-regs.c


CVSROOT:	/cvs/src
Module name:	src
Changes by:	palves@sourceware.org	2013-09-05 11:50:48

Modified files:
	gdb            : ChangeLog 
	gdb/tui        : tui-regs.c 

Log message:
	[TUI] Rewrite register-changed decision bits.
	
	I stumbled on the TUI's register-changed decision code before (used to
	decided whether the register should be highlighted in the register
	window), for it is trying to compare all the different possible states
	and contents or previous/current register contents, and as such may
	need updating whenever the value machinery changes to have more state.
	It's just much simpler and more future proof to compare the
	previous/current printable representation instead.
	
	The bit in tui_register_format that returns early if the register has
	no name gets a bit in the way of the new prototype (what to return in
	that case? NULL, empty string, etc.?).  Fortunately, that check isn't
	really necessary.  All the callers will have already skipped unnamed
	registers.
	
	gdb/
	2013-09-05  Pedro Alves  <palves@redhat.com>
	
	* tui/tui-regs.c (tui_register_format): Don't look at the
	register's name here.  Return string representing register
	value instead of storing it in the data element.
	(tui_get_register): Compare register string representations
	instead of register value states and contents.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/ChangeLog.diff?cvsroot=src&r1=1.15974&r2=1.15975
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/tui/tui-regs.c.diff?cvsroot=src&r1=1.51&r2=1.52


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