gdb, the GNU debugger (http://www.gnu.org/software/gdb/gdb.html).-g option.gdb:
> gdb prog > gdb prog pid > gdb prog core(
prog is your program name, pid is the pid of the running program)(gdb) break main (gdb) run arg1 arg2 (gdb) print /x var_name (gdb) bt (gdb) up (gdb) do