float3 doesn't allowed, why ? kernel build with float3 fails

"
:123:79: error: unknown type name ‘float3’
float best, float spike_thresh,__global uint4* result_flag,__local float3* tmp){

"

Same kernel compiled by ATI SDK w/o any problems.

Why float3 not allowed for NV kernels in OpenCL?

"
:123:79: error: unknown type name ‘float3’
float best, float spike_thresh,__global uint4* result_flag,__local float3* tmp){

"

Same kernel compiled by ATI SDK w/o any problems.

Why float3 not allowed for NV kernels in OpenCL?

And when I replace float3 by float4 I getthis error log:

Building Program (clBuildProgram):main kernels: not OK code -42
ptxas application ptx input, line 918; fatal : Parsing error near ‘,’: syntax error
ptxas fatal : Ptx assembly aborted due to errors
error : Ptx compilation failed: gpu=‘sm_11’, device code=‘cuModuleLoadDataEx_4’
: Considering profile ‘compute_11’ for gpu=‘sm_11’ in ‘cuModuleLoadDataEx_4’
: Retrieving binary for ‘cuModuleLoadDataEx_4’, for gpu=‘sm_11’, usage mode=’ ’
: Considering profile ‘compute_11’ for gpu=‘sm_11’ in ‘cuModuleLoadDataEx_4’
: Control flags for ‘cuModuleLoadDataEx_4’ disable search path
: Ptx binary found for ‘cuModuleLoadDataEx_4’, architecture=‘compute_11’
: Ptx compilation for ‘cuModuleLoadDataEx_4’, for gpu=‘sm_11’, ocg options=’ ’

How I can know what line in my OpenCL file caused this failure?
And in general, can NV’s OpenCL version use anything but float* as local memory pointer type?

And when I replace float3 by float4 I getthis error log:

Building Program (clBuildProgram):main kernels: not OK code -42
ptxas application ptx input, line 918; fatal : Parsing error near ‘,’: syntax error
ptxas fatal : Ptx assembly aborted due to errors
error : Ptx compilation failed: gpu=‘sm_11’, device code=‘cuModuleLoadDataEx_4’
: Considering profile ‘compute_11’ for gpu=‘sm_11’ in ‘cuModuleLoadDataEx_4’
: Retrieving binary for ‘cuModuleLoadDataEx_4’, for gpu=‘sm_11’, usage mode=’ ’
: Considering profile ‘compute_11’ for gpu=‘sm_11’ in ‘cuModuleLoadDataEx_4’
: Control flags for ‘cuModuleLoadDataEx_4’ disable search path
: Ptx binary found for ‘cuModuleLoadDataEx_4’, architecture=‘compute_11’
: Ptx compilation for ‘cuModuleLoadDataEx_4’, for gpu=‘sm_11’, ocg options=’ ’

How I can know what line in my OpenCL file caused this failure?
And in general, can NV’s OpenCL version use anything but float* as local memory pointer type?

OpenCL 1.0 does not allow float3. ATI might support it by chance. OpenCL 1.1 should support float3.
Also, it says line 918 is causing your fatal error and it should be a syntax error.

OpenCL 1.0 does not allow float3. ATI might support it by chance. OpenCL 1.1 should support float3.
Also, it says line 918 is causing your fatal error and it should be a syntax error.

Well, I changed to float4*, that surely supported by OpenCL 1.0, then I got that PTX error.

But look, I didn’t write PTX code, I write OpenCL code, compiler generates PTX code.

OpenCL compiler doesn’t complain, it just produces code that PTX compiler treats as invalid.

BTW, line 918 of CL file is: tmp=(float4)0.0f;

where tmp is float4 type. And this line even not in recently added kernel after that problem begun.

Well, I changed to float4*, that surely supported by OpenCL 1.0, then I got that PTX error.

But look, I didn’t write PTX code, I write OpenCL code, compiler generates PTX code.

OpenCL compiler doesn’t complain, it just produces code that PTX compiler treats as invalid.

BTW, line 918 of CL file is: tmp=(float4)0.0f;

where tmp is float4 type. And this line even not in recently added kernel after that problem begun.

I don’t think that is valid syntax according to section 6.16 pf the OpenCL 1.0 specification. To initialize a float4 like that you would have to write either of

tmp = (float4)(0.0f);

tmp = (float4)(0.0f, 0.0f, 0.0f, 0.0f);

I don’t think that is valid syntax according to section 6.16 pf the OpenCL 1.0 specification. To initialize a float4 like that you would have to write either of

tmp = (float4)(0.0f);

tmp = (float4)(0.0f, 0.0f, 0.0f, 0.0f);

Actually it’s correct syntax. (float4)(0.0f) and (float4)0.f just the same.

Point was that I can’t say what line in OpenCL CL file contains error statement cause line number in PTX code was given.

Well, after many trials I made my code working on NV GPU too.

The reason was not float4 local array.

True reason (the problem disappeared when those lines were disabled) in sampler/images usage.

I can’t make use of that code on ATI too (but it compiles well there, app crashed on execution stage).

I described problem here: image used as cached array

Maybe some insights from NV community, please?

Actually it’s correct syntax. (float4)(0.0f) and (float4)0.f just the same.

Point was that I can’t say what line in OpenCL CL file contains error statement cause line number in PTX code was given.

Well, after many trials I made my code working on NV GPU too.

The reason was not float4 local array.

True reason (the problem disappeared when those lines were disabled) in sampler/images usage.

I can’t make use of that code on ATI too (but it compiles well there, app crashed on execution stage).

I described problem here: image used as cached array

Maybe some insights from NV community, please?