Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Linux threads, pthreads, sigsuspend segfaults... help!
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
chatgris
Guru
Guru


Joined: 14 Oct 2002
Posts: 383
Location: Canada

PostPosted: Fri Jul 11, 2003 6:15 am    Post subject: Linux threads, pthreads, sigsuspend segfaults... help! Reply with quote

OK, for some reason I am getting segfaults in sigsuspend on a dual processor machine with a multi-threaded program, using lpthread.

Now, I am very sure that this segfault has something to do with the libraries, and not me. I have looked around and heard about pthreads and linux threads, and am wondering which one is installed by default with gentoo, and how to possibly try the other one?


just in case anyone has run into this problem before, here is my gdb core output. This occured from apr, however I got the same error locking a mutex with my program another time from a non-apr backtrace. (this has happenned twice so far)

Code:

Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...
(gdb) core core.15812
Core was generated by `./listmngr ./workingdir/'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /usr/lib/libapr-0.so.0...done.
Loaded symbols for /usr/lib/libapr-0.so.0
Reading symbols from /lib/libdl.so.2...done.
Loaded symbols for /lib/libdl.so.2
Reading symbols from /lib/libpthread.so.0...done.
Loaded symbols for /lib/libpthread.so.0
Reading symbols from /lib/libm.so.6...done.
Loaded symbols for /lib/libm.so.6
Reading symbols from /lib/libc.so.6...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from /lib/ld-linux.so.2...done.
Loaded symbols for /lib/ld-linux.so.2
#0  0x40044447 in pthread_handle_sigrestart () from /lib/libpthread.so.0
(gdb) backtrace
#0  0x40044447 in pthread_handle_sigrestart () from /lib/libpthread.so.0
#1  <signal handler called>
#2  0x400d8bf9 in sigsuspend () from /lib/libc.so.6
#3  0x40044838 in __pthread_wait_for_restart_signal () from /lib/libpthread.so.0
#4  0x40046070 in __pthread_alt_lock () from /lib/libpthread.so.0
#5  0x40043037 in pthread_mutex_lock () from /lib/libpthread.so.0
#6  0x40031082 in apr_thread_mutex_lock (mutex=0x8069cf0) at thread_mutex.c:152
#7  0x40033234 in apr_pool_destroy (pool=0x8069cf4) at apr_pools.c:766
#8  0x0805cf73 in scan_list_queue (list_pool=0x40c00530) at scan_list_queue.c:249
#9  0x080561c7 in load_list (thread_data=0x40c00568) at load_list.c:78
#10 0x40042160 in pthread_start_thread () from /lib/libpthread.so.0

_________________
Open your mind. Open your source.

Due credit for avatar from http://www.aikida.net
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum