From: Paul Davis Date: Thu, 3 Jun 2010 21:28:02 +0000 (+0000) Subject: add DEBUG::ProcessThreads as a debug tag for parallelization (probably to be renamed) X-Git-Tag: 3.0-alpha5~1981 X-Git-Url: https://git.carlh.net/gitweb/?a=commitdiff_plain;h=4d828729cdcc9fe391ffc3ef973a490da0dcebbb;p=ardour.git add DEBUG::ProcessThreads as a debug tag for parallelization (probably to be renamed) git-svn-id: svn://localhost/ardour2/branches/3.0@7229 d708f5d6-7413-0410-9779-e7cbd77b26cf --- diff --git a/libs/ardour/ardour/debug.h b/libs/ardour/ardour/debug.h index 1cd8854fea..43fb468b7a 100644 --- a/libs/ardour/ardour/debug.h +++ b/libs/ardour/ardour/debug.h @@ -35,6 +35,7 @@ namespace PBD { extern uint64_t Configuration; extern uint64_t Latency; extern uint64_t Processors; + extern uint64_t ProcessThreads; extern uint64_t Graph; extern uint64_t Destruction; extern uint64_t MTC; diff --git a/libs/ardour/debug.cc b/libs/ardour/debug.cc index 419579b977..7ddb6ddcc8 100644 --- a/libs/ardour/debug.cc +++ b/libs/ardour/debug.cc @@ -32,6 +32,7 @@ uint64_t PBD::DEBUG::SnapBBT = PBD::new_debug_bit ("snapbbt"); uint64_t PBD::DEBUG::Configuration = PBD::new_debug_bit ("configuration"); uint64_t PBD::DEBUG::Latency = PBD::new_debug_bit ("latency"); uint64_t PBD::DEBUG::Processors = PBD::new_debug_bit ("processors"); +uint64_t PBD::DEBUG::ProcessThreads = PBD::new_debug_bit ("processthreads"); uint64_t PBD::DEBUG::Graph = PBD::new_debug_bit ("graph"); uint64_t PBD::DEBUG::Destruction = PBD::new_debug_bit ("destruction"); uint64_t PBD::DEBUG::MTC = PBD::new_debug_bit ("mtc"); diff --git a/libs/ardour/graph.cc b/libs/ardour/graph.cc index 3c5fcc64f0..bd4a5fab31 100644 --- a/libs/ardour/graph.cc +++ b/libs/ardour/graph.cc @@ -17,6 +17,9 @@ */ +#include "pbd/compose.h" + +#include "ardour/debug.h" #include "ardour/graph.h" #include "ardour/types.h" #include "ardour/session.h" @@ -39,6 +42,7 @@ #include using namespace ARDOUR; +using namespace PBD; static unsigned int hardware_concurrency() { @@ -76,7 +80,7 @@ Graph::Graph( Session & session ) _graph_empty = true; int num_cpu = hardware_concurrency(); - printf( "found %d cpus\n", num_cpu ); + DEBUG_TRACE (DEBUG::ProcessThreads, string_compose ("Using %1 CPUs via %1 threads\n", num_cpu)); _thread_list.push_back( Glib::Thread::create( sigc::mem_fun( *this, &Graph::main_thread ), 100000, true, true, Glib::THREAD_PRIORITY_NORMAL ) ); for (int i=1; iname())); + if (_process_silent) retval = route->silent_roll (_process_nframes, _process_start_frame, _process_end_frame, _process_can_record, _process_rec_monitors_input, need_butler); else if (_process_noroll)