Thanks a lot Marcin, change the locale solve the problem. 


Em domingo, 30 de outubro de 2016 23:59:42 UTC-2, Marcin Copik escreveu:
>
> Marcos,
>
> is it possible that your locale settings are set to use language where 
> decimal mark in a floating point number is a comma, not a point? I've found 
> a bug in JavaCL where those settings have been affecting the kernel and 
> each floating point hardcoded in kernel has lost its decimal part. My 
> suspicion is that this problem has been caused by how strings are handled 
> in Java.
> The easiest way to solve it is to change your system settings. On most of 
> Linux distributions, it should be sufficient to change LC_NUMERIC in locale 
> to standard corresponding to a country where decimal point is used in 
> floating point numbers, e.g. en_US.UTF-8.
>
> I have submitted a bug, but unfortunately it is still not fixed:
> https://github.com/nativelibs4java/JavaCL/issues/22
>
> Best regards,
> Marcin
>
> niedz., 30.10.2016 o 23:58 użytkownik Marcos Paulo Rocha <
> [email protected] <javascript:>> napisał:
>
>> Hi, 
>> I'm new to JavaCL and I was trying to write an application and I noticed 
>> a strange behavior using floating points like 0,5 and 1,5. When I multiply 
>> some value to these numbers or set them to an array or variable, the 
>> decimal part is gone.
>> Modifying the VectorAdd example in the javacl-demos project to put this 
>> kind of number in every position of the output buffer, it results in the 
>> same error. Setting these values to a variable and print them inside the 
>> kernel, results in the same error too.
>> I runned this code in a GeForce GTX 750 Ti with OpenCL 1.2.
>> I'm adding some screenshots to illustrate this behavior.
>> Any ideas on how to solve this problem 
>>
>>
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "NativeLibs4Java" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"NativeLibs4Java" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to