VSTHost - Hermann Seibs Hauptseite
VSTHost - Hermann Seibs Hauptseite
VSTHost - Hermann Seibs Hauptseite
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
can load at least Windows 98 (Windows 95 doesn’t require a floating-point coprocessor, which<br />
<strong>VSTHost</strong> absolutely needs). In case of a multiprocessor machine, however, this lack of interest for its<br />
environment is a bit out of place, since it would mean that <strong>VSTHost</strong> only uses one processor. Since the<br />
rise of the Core Duo and Athlon64 X2, this isn’t a good idea any more; a steadily increasing number<br />
of machines have multiprocessor cores, and it’s not really fine if <strong>VSTHost</strong> uses only one half (or less,<br />
in case of a quad core machine) of the available processing power.<br />
Since V1.43, <strong>VSTHost</strong> can use as many processors as there are in the machine (up to 32, which is a<br />
hard-coded 32-bit Windows limit; the x64 version can use 64 cores). If there’s only one processor, the<br />
overhead is minimal (2 additional “if” statements in the audio processing thread). If there are more,<br />
it’s considerable, but it pays off in the end.<br />
Technical explanation<br />
If you just want to make music, damnit!, you can safely ignore these paragraphs, although they might<br />
help you to get the maximum performance from <strong>VSTHost</strong> if a certain configuration simply doesn’t<br />
work the way you thought it should.<br />
<strong>VSTHost</strong> starts as many processing threads as there are processors available. While processing audio,<br />
it determines how many possible thread start points are possible, and then triggers as many threads as<br />
possible and necessary to go to work on them. Each thread finds the same set of thread start points; the<br />
first thread going to work on a start point blocks this path for the other threads, which go on searching<br />
for thread start points to process. This continues until all threads come to the conclusion that there are<br />
no more thread start points to process.<br />
Thread Start Points<br />
What is a “thread start point”? Hmm… well, <strong>VSTHost</strong> can only parallelize audio processing of<br />
independent PlugIns. If a PlugIn’s input is dependent on another PlugIn’s output, they have to be<br />
processed sequentially. Consider a simple setup:<br />
Audio In PlugIn A<br />
Audio Out<br />
Here, nothing can be run in parallel. Everything has to be done in a strict order. <strong>VSTHost</strong> doesn’t even<br />
bother to trigger a thread running on a second processor, as there is only one thread start point –<br />
PlugIn A. Now, let’s assume that PlugIn A is a VSTi, and you want to run its output through a delay<br />
effect:<br />
Audio In PlugIn A<br />
PlugIn B Audio Out<br />
Everything still has to be done in a strict order, PlugIn a remains the only thread start point. In such a<br />
configuration, there’s absolutely no performance gain from a multiprocessor machine.<br />
A slightly more complex setup would be this:<br />
Audio In PlugIn A<br />
Audio Out<br />
PlugIn B<br />
Here, <strong>VSTHost</strong> can run the two PlugIns in parallel; it just to wait with the final audio output until both<br />
PlugIns contributed their outputs. PlugIn A and PlugIn B are thread start points.<br />
Let’s progress to an even more complex example:<br />
24