Forum Discussion
Altera_Forum
Honored Contributor
9 years agoSpeed up data-transfer between Host and Device
Is there a way to speed up the data transfer between Host(ARM) and Device(CYCLONE V)? I need to load an uchar array of the size 672 x 2993 to the FPGA -> compute on this array -> get results fr...
Altera_Forum
Honored Contributor
9 years agoLooking at this again actually, I would say there is likely an issue where you set your data
*src_ptr = *img.data; You are dereferencing your pointers (the asterisks) which means you are not actually setting the pointer but rather accessing the value at that pointer. (I don't remember the behaviour of this exactly... but I believe this will just access the first value in the array?). Try without the asterisks. If that doesn't work, try using `memcpy` to copy the values from img.data to src_ptr directly... I believe this is only shared physical memory at this point and I'm not sure how well the implementation handles virtual memory address space on the host side, maybe there is a problem unmapping `src_ptr` from a different location? (this last bit is speculation though and I don't know enough to say for sure)