[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Debug differences between 386 and x86_64.



I have a favorite trick for debugging daemon processes: put a "sleep(300)" right before the section of code I want to debug, start the daemon, when it hits the sleep I find the process, and attach the debugger to it.

Under the 386 kernel, the debugger breaks into the sleep() call, and the "finish" gdb command immediately terminates the sleep(); then I proceed to debug the code.

When I try this trick on Opteron, I find that the "finish" command does not immediately terminate. The process seems to continue to sleep for the prescribed amount of time. Obviously, this slows things down. Is there a trick that I can do to immediately terminate the sleep syscall on Opteron?

Attachment: pgp00065.pgp
Description: PGP signature


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]