[gmpi] Re: 3.10 - Audio I/O

[...]
> Here is a case why a host may choose to do non-in-place (copy to) 
> processing in a plug:
> 
> Imagine that there is a branch in the graph, for instance, a send. The 
> host is going to have to create a new buffer to send down the branch, 
> while it keeps the in-place buffer on the "main." Now imagine that the 
> first item on the branch is a GMPI plugin. The host can create the new 
> buffer, but let the plugin copy to it. This is quite possibly faster and 
> definitely no slower than copying the buffer first and then passing it 
> to an only-in-place plugin.
> 
> I agree that the VST version with 2 process calls is redundant. I think 
> that we should pass two buffer references, an input and an output, but 
> allow them to refer to the same buffer (in-place) or different buffers 
> (copy-to). It is very important for performance reasons to allow 
> in-place processing, and I think that there are enough optimizations 
> possible to make copy-to worthwhile.

I think there is a reason for the 2 process calls in VST; for the case
where the two buffers are not the same the compiler can optimize
when it knows they don't overlap, as in the C restrict keyword:

process1(float *buf, size_t len);
process2(float *restrict in, float *restrict out, size_t len);

I'm not sure whether the performance of using process2() in every
case is worse then process1(). It may be more demanding on the
cache since for typical serial processing you'll need two buffers
instead of one.

--ms





----------------------------------------------------------------------
Generalized Music Plugin Interface (GMPI) public discussion list
Participation in this list is contingent upon your abiding by the
following rules:  Please stay on topic.  You are responsible for your own
words.  Please respect your fellow subscribers.  Please do not
redistribute anyone else's words without their permission.

Archive: http://www.freelists.org/archives/gmpi
Email gmpi-request@xxxxxxxxxxxxx w/ subject "unsubscribe" to unsubscribe

Other related posts: