From b4087e0e44bba5c4ddbfdb541d50c6c55abed338 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Sun, 29 Jul 2007 12:37:35 -0700 Subject: Statetrace: Make statetrace patch amd64 executables for true single stepping after system calls. Because of peculiarities in how system calls are returned from, single stepping executes some system calls and the instruction following them in a single step. Statetrace now patches the executable image when it detects a system call to force "correct" behavior, aka the appearance of stepping one instruction every single time. --HG-- extra : convert_revision : ac6243a2e00ff98f827b005efd27b4dc5be4f774 --- util/statetrace/arch/tracechild_amd64.hh | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'util/statetrace/arch/tracechild_amd64.hh') diff --git a/util/statetrace/arch/tracechild_amd64.hh b/util/statetrace/arch/tracechild_amd64.hh index 36974e56d..e7457f677 100644 --- a/util/statetrace/arch/tracechild_amd64.hh +++ b/util/statetrace/arch/tracechild_amd64.hh @@ -68,6 +68,8 @@ class AMD64TraceChild : public TraceChild user_regs_struct oldregs; bool regDiffSinceUpdate[numregs]; + uint64_t findSyscall(); + protected: bool update(int pid); @@ -101,6 +103,8 @@ class AMD64TraceChild : public TraceChild std::ostream & outputStartState(std::ostream & output); char * printReg(int num); + + bool step(); }; #endif -- cgit v1.2.3