changeset 84:19142c58cc4c

* munlockall
author Chris Cannam
date Tue, 29 Jan 2008 19:54:54 +0000
parents c60bf8995166
children 40d0c964ad24
files audioio/AudioJACKTarget.cpp
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/audioio/AudioJACKTarget.cpp	Mon Jan 28 17:43:44 2008 +0000
+++ b/audioio/AudioJACKTarget.cpp	Tue Jan 29 19:54:54 2008 +0000
@@ -243,6 +243,14 @@
     if (m_source) {
 	sourceModelReplaced();
     }
+    
+    // Mainstream JACK (though not jackdmp) calls mlockall() to lock
+    // down all memory for real-time operation.  That isn't a terribly
+    // good idea in an application like this that may have very high
+    // dynamic memory usage in other threads, as mlockall() applies
+    // across all threads.  We're far better off undoing it here and
+    // accepting the possible loss of true RT capability.
+    MUNLOCKALL();
 }
 
 AudioJACKTarget::~AudioJACKTarget()