From: Philippe Strauss <philou@ph...> - 2008-08-23 22:49:49
Hello the savonet team & users,
I'm working on a modified simple_client.ml, in which I would like to test filtering and
various dsp processing, later.
For now, the thing is working well: only 2 underrun in several hours of listening.
But I would like to improve it:
- add a way to monitor the activity of the GC while it's running
- add simple log message in case mlock fails
You can find the source here: http://philou.ch/caml
You'll see both aforementioned attempts commented out.
The try ... with make the program exit, without any failure, before entering the infinite loop.
The attempt at launching a really basic thread for printing GC stats gives a bus error (I'm
on OSX 10.5.4):
Starting program: /Users/philou/mysrc/blackjack
Reading symbols for shared libraries +++.............................................................................. done
(EE) jack_client_new: deprecated
(II) Sample rate: 44100 Hz
(II) Sample size: 32 bits
(II) Frame size: 1024 samples
(II) Jack server is running with realtime scheduling
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000010
[Switching to process 9896 thread 0x2f07]
0x00018399 in caml_thread_leave_blocking_section ()
Most probably it interact in a way that I can't understand with the poller thread.
I've looked at the jack_stub.c source, especially the poller thing, without understanding
much of it if any at all.
Thank to anyone looking at my source code :-)
Hi Philippe !
Le Sunday 24 August 2008 00:49:36 Philippe Strauss, vous avez écrit :
> Most probably it interact in a way that I can't understand with the poller
> thread. I've looked at the jack_stub.c source, especially the poller thing,
> without understanding much of it if any at all.
> Thank to anyone looking at my source code :-)
Well, as we told you we had some issues with ocaml-jack. It seems that you've
hit a bug in the memory handling between the C bindings and the Caml GC.
The good point with your code is that it is reproductible, so it's much more
easy to fix.
We are currently discussing it, I hope we'll find the mistake soon..