Description of problem: Using pstack to sample the stack of running processes, I see some of the lines are truncated. The full line is printed when using gdb to sample the stack. For example, pstack gives "QEventDispatcherGlib::processEvents (this=0x97c8948, flags=" gdb gives "QEventDispatcherGlib::processEvents (this=0x97c8948, flags={i = 36}) at kernel/qeventdispatcher_glib.cpp:32" The "at blah/blah.cpp:XX" part is always missing for pstack, not sure whether that is by design or not. At first I thought that the incomplete arguments were due to the curly braces, but I see some lines in pstack with curly braces intact. Version-Release number of selected component (if applicable): $ rpm -q gdb gdb-6.8-29.fc10.i386 Note: I actually use a patched version of pstack, so that debug symbols are always read: $ diff /usr/bin/pstack /home/henshaw/bin/mystack 32,36c32,37 < if $GDB -nx --quiet --batch --readnever > /dev/null 2>&1; then < readnever=--readnever < else < readnever= < fi --- > #if $GDB -nx --quiet --batch --readnever > /dev/null 2>&1; then > # readnever=--readnever > #else > # readnever= > #fi > readnever= How reproducible: Compare pstack and gdb backtrace, possibly for process with curly braces in function arguments.
Created attachment 341436 [details] pstack of kded4 with truncated lines
Created attachment 341437 [details] similar gdb bt of kded4 without truncated lines
Thanks, fixed by: * Mon Apr 27 2009 Jan Kratochvil <jan.kratochvil> - 6.8.50.20090302-22 - Fix pstack/gstack cutting very long lines (BZ 497849). http://cvs.fedora.redhat.com/viewvc/rpms/gdb/devel/gdb-6.3-gstack-20050411.patch?r1=1.4&r2=1.5&view=patch That -readnever should be removed one day, just the Archer branch archer-tromey-delayed-symfile is currently not fast enough.