Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* Question on process record feature
@ 2017-10-08  9:00 张雨姗(ZHANG Yushan)-11310380
  2017-10-08  9:23 ` Jan Kratochvil
  0 siblings, 1 reply; 3+ messages in thread
From: 张雨姗(ZHANG Yushan)-11310380 @ 2017-10-08  9:00 UTC (permalink / raw)
  To: gdb

[-- Attachment #1: Type: text/plain, Size: 1934 bytes --]

This is the first time using this mailing-list, I don't know if the mail I sent on Oct 6 was successful or not because I didn't see it in the online archive. If you receive the former one, just ignore this, thank you.
==============

Hi all,

Recently I'm doing some readings on reverse debugging and am very glad to know this is already a feature in GDB. I'm playing with the process record feature after GDB 7.0 release. Within this tutorial (https://sourceware.org/gdb/wiki/ProcessRecord?highlight=%28OngoingWork%29), the following should work:

(gdb) break _start
(gdb) run
(gdb) record

(gdb) break main
(gdb) break foo
(gdb) break bar
(gdb) continue
(gdb) continue
Continuing.

Breakpoint 2, main ()
    at /data/home/msnyder/cvs/localhost/dumpload/gdb/testsuite/gdb.reverse/break-reverse.c:34
34        xyz = 0;      /* break in main */
(gdb) continue
Continuing.

Breakpoint 3, foo ()
    at /data/home/msnyder/cvs/localhost/dumpload/gdb/testsuite/gdb.reverse/break-reverse.c:28
28        xyz = 1; /* break in foo */
(gdb) continue
Continuing.
......


But actually what happens to me is the program stops after the first "continue" command, but should stop at the "main" breakpoint.(see attach) From the information given I know there is something wrong but cannot locate the problem to the OS or the GDB itself. Could anyone help me to understand this problem? What works for me is to start "record" commands after entering the main function.

My machine is Ubuntu 16.04.3 server amd64 with GDB 7.11.1.
I appreciate any possible help.


Thanks,
Yushan

-------------------------------------------------------------------
Yushan Zhang (Undergraduate)
Student, Class of 2018
Dept. of Computer Science and Engineering
Southern University of Science and Technology (SUSTech, a.k.a SUSTC)
1088 Xueyuan Rd., Nanshan District, Shenzhen, China  518055
Email: zhangys3@mail.sustc.edu.cn

[-- Attachment #2: stops-incorrect result.png --]
[-- Type: application/octet-stream, Size: 49506 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-10-08 14:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-08  9:00 Question on process record feature 张雨姗(ZHANG Yushan)-11310380
2017-10-08  9:23 ` Jan Kratochvil
2017-10-08 14:18   ` 张雨姗(ZHANG Yushan)-11310380

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox