Intel:OpenCL™ コード実行時に下記のような警告が表示されます。対策を教えてください。

OpenCL Arria

<メッセージ>
WARNING: [acl_a10soc0] NOT using DMA to transfer xxxxx bytes from host to device because of lack of alignment host ptr (0x25d4c) and/or dev offset (0x10400) is not aligned to 64 bytes ===========


カテゴリ:OpenCL™
ツール:インテル® FPGA SDK for OpenCL™
デバイス:Arria® 10


イメージが格納されているバッファ(src)が 64バイトのアラインメントが取れていないために、DMA が使用できずに CPU による逐次コピーとなっているという Warning です。

OpenCL の Best Practice Guide の「Allocate Aligned Memory」の項にメモリ・アライメントの方法が記載されています。
https://www.altera.com/documentation/mwh1391807516407.html#mwh1391807499818

また、sobel フィルタのサンプル・コード中で alignedMalloc を使用しているので、こちらも参照してください。
https://www.altera.com/support/support-resources/design-examples/design-software/opencl/sobel-filter.html


Experienced FAE
Free consultation is available.

From specific product specifications to parts selection, the Company FAE will answer your technical concerns free of charge. Please feel free to contact us.