cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

afo
Adept I

From OpenCL to CAL... Documentation/Examples?

Are there some documentation/examples about OpenCL kernels viewed/used as CAL kernels?

Hi all,

I would like to overcome the OpenCL limitations for multiGPU, so I am migrating to CAL. The OpenCL kernels can be compiled to IL format with the Kernel Stream Analyzer, but I can't find documentation about the parameter passing mechanism.

I would like to use the OpenCl kernels as CAL kernels, but I can't find how to pass the CAL equivalent parameters. In OpenCL I used to pass cl_mem pointers; so how could I do the same in CAL using the opencl kernels as CAL kernels? Any insight about this will be really appreciate.

thanks in advance for your help and collaboration

best regards,

Alfonso

0 Likes
14 Replies

This information is not documented as it is currently not a supported path.
0 Likes

Micah,

Thanks for the answer, so we have:

HD5970 multiGPU via OpenCL: unsupported

Using OpenCL kernels as CAL kernels: unsupported

So, my only way to get HD5970 multigpu should be to rewrite my OpenCL kernels as CAL kernels and pass parameters as is documented for CAL kernels...

this is not funny...

 

0 Likes

You can get the IL generated by the OpenCL compiler by setting GPU_DUMP_DEVICE_KERNEL=1. You theoretically should be able to use this with a CAL application.

0 Likes

Hi Micah,

One more thing about using OpenCL kernels as CAL kernels: In AMD Compute Abstraction Layer (CAL) document rev2.03 (december 2010), on section 2.2.3 "High Level Kernel Languajes" (page 2-10) it states:

"... For example, developers can use OpenCL to develop their kernels, then generate the equivalent AMD IL using offline tools provided by AMD. The generated AMD IL kernel then can be passed to the CAL compiler, with any required modifications, for generating the binary image"

This sounds like what I want to do; Am I missing something? (besides the fact that multiGPU on dual core boards is not supported).

By the way, two related questions:

1) Is multiGPU supported in single core boards? (i.e. 4xHD5870 works without performance penalties in OpenCL and/or CAL)

2) Will multiGPU be supported in HD6990 or it will work in single GPU mode as HD5970?

Thanks in advance for any insight about these issues.

best regards,

Alfonso

0 Likes
zeland
Journeyman III

Is multiGPU supported in single core boards?

AS far as I known

 the only way to get it work on linux is to set USE_GPU_SYNC_OBJECTS=1 and this is not documented and not recomended feature. SO  multiGPU is not solved at all. we have only workaround.

In case do not set   USE_GPU_SYNC_OBJECTS=1 we have penalty for multiGPU using.

And there are no information about this issue in documentation also.

0 Likes

Afo,
MultiGPU on the dual chip devices is not supported yet by the Stream SDK.
See the driver compatibility chart here.
http://developer.amd.com/gpu/A...verCompatibility.aspx

Some developers are experimenting with environment variables or at the CAL level, but until the SDK officially supports the feature, it is not guaranteed to work.
0 Likes

Again, thanks for the answer Micah,

But then...

Is it possible to use both GPUs and more than one HD5970 in any programming model? (opencl, cal, other)?

regards,

Alfonso

0 Likes

afo: do you try use GPU_USE_SYNC_OBJECTS? some people report that 5970 work under linux.

0 Likes

Hi nou,

Yes, I was one of them.(http://forums.amd.com/devforum/messageview.cfm?catid=390&threadid=143851&enterthread=y)

But I would like to use the second HD5970; in OpenCL two parallel instances work with decent performance, launching a third one drops performance, so I am switching to CAL because other people say that can run 4xHD5970 without loss in performance, but I would like use my opencl kernels as cal kernels and not to rewrite them.

regards,

Alfonso

0 Likes

Afo,
The only problems with MultiGPU that I am aware of are the boards with two chips on the same device. These boards are setup differently and require quite a lot of changes to get them to work correctly.

As for that section of the documentation. I'm not 100% sure why it is there, as we don't document what modifications are required, but I'll follow up next week to see what we can do about it.
0 Likes

Afo,
There is still debate on how to proceed with this path, so I can't give out any information on this at this time.
0 Likes

Hi Micah,

Thanks for the followup, In the meantime I am porting my kernels to CAL/IL. The learning curve is somewhat step, but I can overcome it.

best regards,

Alfonso

0 Likes

afo,
There are several open source projects that attempt to make coding CAL and IL easier. While these are not supported by AMD, people have used them succesfully. An example would be CAL++ It can be found here: http://sourceforge.net/projects/calpp/
0 Likes

Thanks, I will take a look.

best regards,

Alfonso

0 Likes