Re: [LAD] Has anyone ever played a plugin in realtime ... [related to:] hard realtime performance synth

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: <linux-audio-dev@...>
Date: Tuesday, February 9, 2010 - 12:04 am

On Mon, Feb 08, 2010 at 10:01:03PM +0100, Emanuel Rumpf wrote:

> Actually OpenCL seems to already be supported, (in new hardware only ?),

I am aware of Nvidia and ATI binary drivers supporting OpenCL. What I
do not see is an ability to run this using the Nouvou, the RadeonHD xorg
driver, the intel xorg driver, or as SSE optimized software only.

If OpenCL DSP code would run on my desktop using CPUs only, faster than
a reasonable C implementation using primitives would run, then I'd
suggest it is ready for people to start using without holding out for
open source driver support. I don't think that we are close enough to
say that we will be there in 6-12 months yet though. If I am mistaken
about the state of the Khronos reference implementation or the clang
implementation, I'd love to see a demo prove me wrong.

> There's also the "CT Technology" from Intel (aquired from RapidMind),

I am passingly aware of them, but as long as there is not an open
language specification, and an open implementation, I don't think they
are a real answer either.

> > however, I don't believe that the OpenCL language is as nice or easy to

Just because I don't like it as well does not mean I won't accept it as
a valid choice.

However, the examples there still look a lot more complicated that the
cuda examples. The page you posts included a fairly minimal OpenCL
example that is close to 40 lines long without showing the actual source
code for the actual OpenCL function to execute on the card.

_global__ void inc_gpu(int *a, int N)
{
int idx = blockIdx.x * blockDim.x + threadIdx.x;
if (idx < N)
a[idx] = a[idx] + 1;
} }
int main()
{
float *a;
dim3 dimBlock (blocksize);
dim3 dimGrid( ceil( N / (float)blocksize) );
cudaMalloc((void **) &a, N);
cudaMemcpy(a, someLocalSource, N*sizeof(float), cudaMemcpyHostToDevice);
inc_gpu<<>>(a, N);
cudaFree(a);
}

The __global__ says that it will be called from the host but run on the
device. Calling the function uses a modified call syntax to setup the
arrangement of hardware resources that will be used by the call, but the
number of units to use, and the block size to carve the data by. dim3 is
a cuda defined datatype.

Still, if OpenCL shows up in Mesa, and can at a minimum run on the CPU
faster than a basic C implementation, then I would certainly choose it
over Cuda for open-ness.

> I still somehow wonder, how cheap low MHz Chips can outperform my

Well, I bet a lot of software isn't wringing as much performance for
your PC as it could. When it comes to music though, exactly what low
mhz chips are beating a 2ghz Core 2 Duo or equivelent AMD? Also, how
does the cost of said low mhz device compare to the Core 2 Duo?

However, even in PCs, the trend is more cores, and either programmers
need to get better, or else we need better tools. Now, I certainly plan
to become a better programmer, but I still want better tools, and I
think it is unfair to expect everyone to get better.
_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-dev

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [LAD] Has anyone ever played a plugin in realtime ... [r..., Pedro Lopez-Cabanillas, (Fri Feb 5, 10:57 pm)
Re: [LAD] Has anyone ever played a plugin in realtime ... [r..., Joshua Boyd, (Tue Feb 9, 12:04 am)
Re: [LAD] Has anyone ever played a plugin in realtime ... [r..., Fernando Lopez-Lezcano, (Wed Feb 10, 6:33 pm)