OpenCL* for CPU
Ask questions and share information on Intel® SDK for OpenCL™ Applications and OpenCL™ implementations for Intel® CPU.
Announcements
This forum covers OpenCL* for CPU only. OpenCL* for GPU questions can be asked in the GPU Compute Software forum. Intel® FPGA SDK for OpenCL™ questions can be ask in the FPGA Intel® High Level Design forum.
1718 Discussions

kernel with pipe parameter: compilation error

ZVere
Beginner
657 Views

Hello,

I tried compiling the following kernel with the last version of OpenCL SDK:

__kernel void pipe_producer (__write_only pipe float rng_pipe)

{

}

And got the following errors:

1:3:30: error: expected parameter declarator
1:3:43: error: expected ')'
1:3:29: note: to match this '('
Compilation failed

Can you tell why ?

Regards,

Z.V

0 Kudos
1 Solution
Robert_I_Intel
Employee
657 Views

Hi Zvi,

Pipes are an OpenCL 2.0 feature. Please add the following flag to your build options: -cl-std=CL2.0

 

Using build options: -cl-std=CL2.0
OpenCL Intel(R) Graphics device was found!
Device name: Intel(R) Iris(TM) Graphics 6100
Device version: OpenCL 2.0 
Device vendor: Intel(R) Corporation
Device profile: FULL_PROFILE
fcl build 1 succeeded.
fcl build 2 succeeded.
bcl build succeeded.

pipe_producer info:
 Maximum work-group size: 256
 Compiler work-group size: (0, 0, 0)
 Local memory size: 0
 Preferred multiple of work-group size: 32
 Minimum amount of private memory: 0

Build succeeded!

 

View solution in original post

0 Kudos
2 Replies
Robert_I_Intel
Employee
658 Views

Hi Zvi,

Pipes are an OpenCL 2.0 feature. Please add the following flag to your build options: -cl-std=CL2.0

 

Using build options: -cl-std=CL2.0
OpenCL Intel(R) Graphics device was found!
Device name: Intel(R) Iris(TM) Graphics 6100
Device version: OpenCL 2.0 
Device vendor: Intel(R) Corporation
Device profile: FULL_PROFILE
fcl build 1 succeeded.
fcl build 2 succeeded.
bcl build succeeded.

pipe_producer info:
 Maximum work-group size: 256
 Compiler work-group size: (0, 0, 0)
 Local memory size: 0
 Preferred multiple of work-group size: 32
 Minimum amount of private memory: 0

Build succeeded!

 

0 Kudos
ZVere
Beginner
657 Views

Hi Robert,

Thank you for your help.

Regards,

Z.V

0 Kudos
Reply