* Add OptionThreadingAlways

This commit is contained in:
Chris Cannam
2007-11-26 11:50:29 +00:00
parent 48d640f696
commit 065cc29e5c
3 changed files with 40 additions and 17 deletions

View File

@@ -119,16 +119,19 @@ RubberBandStretcher::Impl::Impl(RubberBandStretcher *stretcher,
if (m_channels > 1) {
if (!m_realtime &&
!(m_options & OptionThreadingNone) &&
Thread::threadingAvailable() &&
system_is_multiprocessor()) {
m_threaded = true;
m_threaded = true;
if (m_debugLevel > 0) {
cerr << "Going multithreaded..." << endl;
}
if (m_realtime) {
m_threaded = false;
} else if (m_options & OptionThreadingNever) {
m_threaded = false;
} else if (!(m_options & OptionThreadingAlways) &&
!system_is_multiprocessor()) {
m_threaded = false;
}
if (m_threaded && m_debugLevel > 0) {
cerr << "Going multithreaded..." << endl;
}
}