help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GDB - create buffer to show information about CPU registers


From: Stefan Monnier
Subject: Re: GDB - create buffer to show information about CPU registers
Date: Wed, 25 Jan 2017 00:16:06 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

> My currently biggest issue with my setup is, that to get some
> information from a register, I have to print its content with gdb (from
> inside Emacs), put that into the mate-calculator to find which bits are
> set and which are not and finally open up the datasheet of the CPU and
> look up the meaning of each bit.

I don't have a ready-made solution for you, but note that GDB
is scriptable.  If you look at Emacs's src/.gdbinit file
(http://git.savannah.gnu.org/cgit/emacs.git/tree/src/.gdbinit)
you can see what we do to help ourselves debug Emacs's C code.

Note how you can use C-like operations in it, so you could code up some
.gdbinit file for yourself where you write some handy commands that
print the state of your devices's registers in a meaningful manner.

Note that this is a "GDB-only" solution (the only Emacs part of it is
that you got the info in an Emacs discussion group, and that the sample
file provided came from Emacs's source code).


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]