UPGRADE YOUR BROWSER
We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!
01-12-2017 01:45 AM
Hello,
I recently started using 2016.2 and I have a simple OpenCL kernel which has loops with constant number of iteration and reqd_work_group_size(1, 1, 1). In the latency information of the report shows 'undef' for the kernel. I realized that using math functions like 'exp' and 'atan' cause this therefore I replaced them with 'native_*' versions. Now I can observe the latency information and the kernel uses less area resources.
Can someone explain me why the latency information is not available for 'exp'?
And is there any drawback of using 'native_exp'?
Best regards
01-12-2017 08:04 AM
Below descriptions will be in the next Optimization UG that answers your question:
OpenCL Specification provides a wealth of math built-in functions. All math built-in functions with the native_ prefix are mapped to one or more native device instructions and will typically have better performance compared to the corresponding functions (without the native__ prefix). The accuracy and in some cases the input ranges of these functions is implementation-defined. In SDAccel environment these native_ built-in functions use the equivalent functions in Vivado HLS Math library, which are already optimized for Xilinx FPGAs in terms of area and performance. It’s recommended to use native_ built-in functions if the accuracy meets the application requirement.
@vemulo wrote:
Hello,
I recently started using 2016.2 and I have a simple OpenCL kernel which has loops with constant number of iteration and
reqd_work_group_size(1, 1, 1). In the latency information of the report shows 'undef' for the kernel. I realized that using math functions like 'exp' and 'atan' cause this therefore I replaced them with 'native_*' versions. Now I can observe the latency information and the kernel uses less area resources.
Can someone explain me why the latency information is not available for 'exp'?
And is there any drawback of using 'native_exp'?
Best regards
01-12-2017 08:04 AM
Below descriptions will be in the next Optimization UG that answers your question:
OpenCL Specification provides a wealth of math built-in functions. All math built-in functions with the native_ prefix are mapped to one or more native device instructions and will typically have better performance compared to the corresponding functions (without the native__ prefix). The accuracy and in some cases the input ranges of these functions is implementation-defined. In SDAccel environment these native_ built-in functions use the equivalent functions in Vivado HLS Math library, which are already optimized for Xilinx FPGAs in terms of area and performance. It’s recommended to use native_ built-in functions if the accuracy meets the application requirement.
@vemulo wrote:
Hello,
I recently started using 2016.2 and I have a simple OpenCL kernel which has loops with constant number of iteration and
reqd_work_group_size(1, 1, 1). In the latency information of the report shows 'undef' for the kernel. I realized that using math functions like 'exp' and 'atan' cause this therefore I replaced them with 'native_*' versions. Now I can observe the latency information and the kernel uses less area resources.
Can someone explain me why the latency information is not available for 'exp'?
And is there any drawback of using 'native_exp'?
Best regards
01-12-2017 11:12 AM
Thank you for the information.
07-25-2018 07:55 PM - edited 07-25-2018 07:59 PM
I want to use efr and erfc functions. but they don't work by "native_erfc(10.0)" and "native_erfcf(10.0)" and ... ? Could you please help me as well :)