lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]



About the capabilities of OpenCL, we simply need to know more.

The best I've seen is the slides here: http://www.khronos.org/opencl/

About the iteration, yes, basically as you wrote. Except it will be better to just give the iteration loop contents so that the framework can utilize parallelism.

run_on_cuda( matrix, function(x,y)
-- some big fat (or slim) equation in pure Lua for dealing with (x,y)
end )

Please don't shoot the idea down; I will need to test this once I get a Cuda capable machine. Even if you shoot it down, I'll still do it! ;D
-asko



On Tue, 9 Dec 2008 23:54:21 -0800
 "Wesley Smith" <wesley.hoke@gmail.com> wrote:
One scenario is meteorological data analysis, where non-linear operations are run for huge data matrices. In this case, we would be able to define the operations as Lua codelets, and run them parallel on the data. I guess only Lua of the current scripting languages (and Forth) would be small enough to effectively fit in on the CUDA/OpenCL. Even there, some limitations s.a. no
recursive calls may be too much. But we'll see.

Are you suggesting running Lua instructions in OpenCL? like:

-- begin codelet
for i=1, 10000 do
for j=1, 10000 do
-- some big fat equation in pure lua that runs in OpenCL
end
end
-- end codelet


What about making some form of OpenCL flavored shader as in GLSL or Cg shaders? Basically some C codelet that is dynamically compiled and run in OpenCL. I haven't read the docs in a while, but from what I remember from a presentation this summer, code can be dynamically
compiled and executed.

wes