cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
huojianyu
Observer
Observer
301 Views
Registered: ‎09-08-2019

How to speed up data copying from GPU to heap

Hi experts,

I'm testing GPU performance of ZU5EV and I use DRM as GPU input/output buffer.

I found that copying data from DRM to heap(about 0.14GB/s) is much slower than copying data from heap to DRM(2.02GB/s).  The test code is attached.

My question is why data copying from DRM is so slow and how can I speed up it?

Thanks.

0 Kudos
1 Reply
kawazome
Adventurer
Adventurer
222 Views
Registered: ‎04-02-2014

For arm64 architectures, the Xilinx DRM Driver sets vm_page_prot to "Write Combine" when mmap() the GEM buffer.

If vm_page_prot is set to "Write Combine", the CPU data cache will not be used. As a result, access to the buffer is slower (but sequential write to the buffer is faster).

Unfortunately, the Xilinx DRM Driver needs to be modified to speed up buffer access.

This fix is not easy. I look forward to Xilinx's future support.

0 Kudos