I have a couple of questions regarding core dumps. I have gdb on Windows, using Cygwin.
What is the location of core dump file? Is it a.exe.stackdump file? (This is the only file that generated after crash) I read on other forums that the core dump file is named "core". But I don't see any file with name "core".
What is the command for opening and understanding core dump file?
You need to configure Cygwin to produce core dumps by including
error_start=x:\path\to\dumper.exe 
in your CYGWIN environment variable (see here in section "dumper" for more information). If you didn't do this, you will only get a stacktrace -- which may also help you in diagnosing the problem, though.
Start gdb as follows to attach it to a core dump file:
gdb myexecutable --core=mycorefile 
You can now use the usual gdb commands to print a stacktrace, examine the values of variables, and so on.
a.exe.stackdump files by default. You need to configure it to create cores as well (Martin's answer covers that).If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With