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

Re: [a-devel] AGNULA/DeMuDi 1.1.1 and 2.6.x kernel



Hi, 

oops, was not much verbose indeed. thanks for the debuild option
Junichi. it should be better now, but seems like you knew it
already Jack. the segfault occurs when calling pthread_cancel in
jackd/engine.c:

--
        /* JOQ: We need to cancel the watchdog thread and wait for it
         * to terminate.  For some reason, with the 2.6 kernel this
         * causes a segfault in pthread_cancel().  I don't know why,
         * but 2.4 works OK.
         */
        VERBOSE (engine, "stopping watchdog thread\n");
        pthread_cancel (engine->watchdog_thread);
        pthread_join (engine->watchdog_thread, NULL);
--

looking on the web, it seems Tilmann found a workaround for a
similar problem occuring on transcode:

2003-11-26 Tilmann Bitterberg <transcode at tibit.org>

  * filter/extsub/subtitle_buffer.c  filter/extsub/filter_extsub.c
  import/clone.c import/packets.c src/decoder.c src/frame_threads.c
  src/transcode.c configure.in:
  Introduced a new define BROKEN_PTHREADS which replaces the fixups
  formerly only dependent on __APPLE__. This might cure the problems
  with a 2.6 kernel.

in import/clone.c:
--
-    // cancel the thread
-    if (thread) {
:      pthread_cancel(thread);
-#ifdef BROKEN_PTHREADS // Used to be MacOSX specific; kernel 2.6 as well?
-      pthread_cond_signal(&buffer_fill_cv);
-#endif
-      pthread_join(thread, &status);
-      thread = (pthread_t)0;
-    }
--

the debug again, with jack-audio-connection-kit recompiled : 

$ ulimit -c unlimited

$ jackd -d alsa
jackd 0.98.1
Copyright 2001-2003 Paul Davis and others.
jackd comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details

JACK compiled with System V SHM support
loading driver ..
creating alsa driver ...
hw:0|hw:0|1024|2|48000|0|0|nomon|swmeter|-|32bit
control device hw:0
configuring for 48000Hz, period = 1024 frames, buffer = 2 periods
Couldn't open hw:0 for 32bit samples trying 24bit instead
Couldn't open hw:0 for 24bit samples trying 16bit instead
Couldn't open hw:0 for 32bit samples trying 24bit instead
Couldn't open hw:0 for 24bit samples trying 16bit instead
jack main caught signal 2
Segmentation fault (core dumped)

$ gdb `which jackd` core*
GNU gdb 6.1-debian
Copyright 2004 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 "i386-linux"...Using host libthread_db
library "/lib/tls/libthread_db.so.1".

Core was generated by `jackd -d alsa'.
Program terminated with signal 11, Segmentation fault.

warning: current_sos: Can't read pathname for load map:
Input/output error

Reading symbols from /usr/lib/libjack-0.80.0.so.0...done.
Loaded symbols for /usr/lib/libjack-0.80.0.so.0
Reading symbols from /lib/libcap.so.1...done.
Loaded symbols for /lib/libcap.so.1
Reading symbols from /lib/libreadline.so.4...done.
Loaded symbols for /lib/libreadline.so.4
Reading symbols from /lib/tls/libm.so.6...done.
Loaded symbols for /lib/tls/libm.so.6
Reading symbols from /lib/tls/libpthread.so.0...done.
[Thread debugging using libthread_db enabled]
Loaded symbols for /lib/tls/libpthread.so.0
Reading symbols from /lib/tls/libdl.so.2...done.
Loaded symbols for /lib/tls/libdl.so.2
Reading symbols from /lib/tls/libc.so.6...done.
Loaded symbols for /lib/tls/libc.so.6
Reading symbols from /lib/libncurses.so.5...done.
Loaded symbols for /lib/libncurses.so.5
Reading symbols from /lib/ld-linux.so.2...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /usr/lib/libasound.so.2...done.
Loaded symbols for /usr/lib/libasound.so.2
Reading symbols from /lib/libgcc_s.so.1...done.
Loaded symbols for /lib/libgcc_s.so.1
#0  0x4008dd4c in pthread_cancel () from /lib/tls/libpthread.so.0
(gdb) thread apply all bt

Thread 2 (process 20730):
#0  0x401a8a57 in _Unwind_Find_FDE () from /lib/tls/libc.so.6
#1  0x0000000b in ?? ()
#2  0x00000000 in ?? ()
#3  0xffffe53c in ?? ()
#4  0x40a1f33c in ?? ()
#5  0x40098114 in ?? ()
#6  0x0000000b in ?? ()
#7  0xffffe530 in ?? ()
#8  0x00000000 in ?? ()
#9  0x00000001 in ?? ()
#10 0x400980b4 in ?? ()
#11 0x00000008 in ?? ()
#12 0x00000003 in ?? ()
#13 0xffffe46c in ?? ()
#14 0x00000000 in ?? ()
#15 0x4008c694 in pthread_mutex_lock () from
/lib/tls/libpthread.so.0
#16 0x4137f8b4 in ?? () from /lib/libgcc_s.so.1
#17 0x00000008 in ?? ()
#18 0x40a1f454 in ?? ()
#19 0x4008c694 in pthread_mutex_lock () from
/lib/tls/libpthread.so.0
#20 0x4137b162 in __frame_state_for () from /lib/libgcc_s.so.1
#21 0x00000000 in ?? ()
#22 0x00000000 in ?? ()
#23 0x00000000 in ?? ()
#24 0x00000000 in ?? ()
#25 0x00000000 in ?? ()
#26 0x40a1f694 in ?? ()
#27 0xffffe440 in __kernel_sigreturn ()

Thread 1 (process 20729):
#0  0x4008dd4c in pthread_cancel () from /lib/tls/libpthread.so.0
#1  0x0804fc2f in jack_engine_delete (engine=0x8068ac0) at
engine.c:2483
#2  0x0804ae6e in jack_main (driver_desc=0x8063790,
driver_params=0x0) at jackd.c:207
#3  0x0804b846 in main (argc=3, argv=0xbffff8b4) at jackd.c:561
#0  0x4008dd4c in pthread_cancel () from /lib/tls/libpthread.so.0


ciao, piem


On Fri, Jul 02, 2004 at 07:54:42PM +0900, Junichi Uekawa wrote:
> Hi,
> 
> > Hmm.  Looks like the Debian binaries are stripped.  Drat!
> 
> It should be possible to obtain a non-stripped library package with
> 
> Download the source:
> apt-get source jack-audio-connection-kit
> 
> Satisfy the build-dependency:
>   apt-get build-dep jack-audio-connection-kit
> 
> enter the directory and build a non-stripped libjack: 
>   debuild -e DEB_BUILD_OPTIONS=nostrip,noopt 
> (maybe you need to install devscripts)
> 
> 
> 
> 
> Could you try with installing the resulting binary?
> 
> 
> regards,
> 	junichi
> 
> 
> -- 
> To UNSUBSCRIBE, email to debian-multimedia-REQUEST@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
> 
> 



Reply to: