On Wed, Dec 18, 2002 at 12:44:46 +0100, David Olofson wrote: > > I think the host needs to own it because only the host knows when > > it can be free'd again. > > No, that would be senders, not hosts, I think. (Remember that > connected plugins send *directly* to each other's queues. The host > doesn't know what's going on.) > > That said, the memory management definitely has to go through a host > service of some kind.
OK, I thought that the host was responsible for mashalling the queues. The plugin must eb responsible for allocating the space, yes (unless it originates form the host, eg. host sequenced data). The 'thing' that consumes the data needs to free it. > > Data blocks that will be need in an RT context (eg. bulk parameter > > pasing) can be allocated ahead of time. > > How? A plugin can't know what it will send until it's in process() - > and then it's too late... Well if its always sending 256 floats as a parameter it know its going to be 256*sizeof(float) vytes long, so it can preallocate a buffer that bit. I guess the problem is that it doesn't know when to reallocate a new one. This is definatly a difficult problem. In the simple example case of a UI sending a block of floats to the DSP code, its not a problem, because the UI part is running non-RT anyway. - Steve
