MCPcopy Create free account
hub / github.com/VCVRack/Rack / Engine_stepWorker

Function Engine_stepWorker

src/engine/Engine.cpp:326–349  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

324
325
326static void Engine_stepWorker(Engine* that, int threadId) {
327 Engine::Internal* internal = that->internal;
328
329 // int threadCount = internal->threadCount;
330 int modulesLen = internal->modules.size();
331
332 // Build ProcessArgs
333 Module::ProcessArgs processArgs;
334 processArgs.sampleRate = internal->sampleRate;
335 processArgs.sampleTime = internal->sampleTime;
336 processArgs.frame = internal->frame;
337
338 // Step each module
339 while (true) {
340 // Choose next module
341 // First-come-first serve module-to-thread allocation algorithm
342 int i = internal->workerModuleIndex++;
343 if (i >= modulesLen)
344 break;
345
346 Module* module = internal->modules[i];
347 module->doProcess(processArgs);
348 }
349}
350
351
352static void Engine_stepFrameCables(Engine* that) {

Callers 2

Engine_stepFrameFunction · 0.85
runMethod · 0.85

Calls 2

doProcessMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected