On 01.02.20 13:44, Andreas Beckmann wrote: > On Wed, 29 Jan 2020 19:51:22 +0100 =?utf-8?q?Tim_R=C3=BChsen?= > The manpage (dated Feb 25 2002) says: > > RESTRICTIONS > pstack currently works only on Linux, only on an x86 machine > running 32 bit ELF binaries (64 bit not supported). Also, > for symbolic information, you need to use a GNU compiler to > generate your program, and you can't strip symbols from the > binaries. For thread information to be dumped, you have to > use the debug-aware version of the LinuxThreads libpthread.so > library. (To check, run nm(1) on your pthreads library, and > make sure that the symbol "__pthread_threads_debug" is > defined.) Threads are not supported with the newer NPTL > libpthread.so library. > > So the pstack tool is probably useless on modern systems.
I believe the man page and the top comment within pstack.c are is wrong. The source code explicitly supports 64bit ELF, you can build it for amd64, it does some work, but fails on 'crawl...'. The man page of ptrace() gives no obvious hint why it may fail on amd64 and not on x86 here. Regards, Tim
signature.asc
Description: OpenPGP digital signature