Re: Memmove causing program crashes, giving SIGTRAP in GDB(?)

Eliot Moss via Cygwin <[email protected]>
Newsgroups gmane.os.cygwin
Message-ID <[email protected]>
On 2/26/2026 6:02 AM, KENNON J CONRAD via Cygwin wrote:

> Thanks for checking and sharing your thoughts.  This is what I would expect, so at least I'm not crazy :)
> I really need to see the values of the registers in memmove, hopefully it's just a matter of continuing to learn gdb.

The command is "info registers", of "info r" for short.  You can also print an
individual register using (say) "print $rax" (prefix the register name by $)
or "info r rax".  If you're stepping, you can set up a *layout* that shows all
the register values as you step along.

You also might consider using a reverse debugging tool like the "undo" debugger.
They track enough information to allow them to (effectively) execute backwards
from a point.  Not sure if any work under cygwin, though.

By the way, I got the commands for printing individual registers with a simple
web search :-) ...

HTH -- Eliot Moss

-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.