Hi- I wanna take a look into the role of "enqueueMigrateMemObjects" during map/unmap buffer.
So, I comment out "Send the buffer down to the Alveo card" section like below.
// Send the buffers down to the Alveo card
et.add("Memory object migration enqueue");
cl::Event event_sp;
// q.enqueueMigrateMemObjects({a_buf, b_buf}, 0, NULL, &event_sp);
// clWaitForEvents(1, (const cl_event *)&event_sp);
Then, compile and run. It works well because the kernel is executed and the results are valid except that the "Memory object migration enqueue" is decreased.
xooxit@user:~/document/Get_Moving_With_Alveo/build$ ./03_buffer_map
-- Example 3: Allocate and Map Contiguous Buffers --
Loading alveo_examples.xclbin to program the Alveo board
Running kernel test with XRT-allocated contiguous buffers
OCL-mapped contiguous buffer example complete!
--------------- Key execution times ---------------
OpenCL Initialization : 202.436 ms
Allocate contiguous OpenCL buffers : 42.738 ms
Set kernel arguments : 0.010 ms
Map buffers to userspace pointers : 0.449 ms
Populating buffer inputs : 25.182 ms
Software VADD run : 18.837 ms
Memory object migration enqueue : 0.001 ms
OCL Enqueue task : 0.067 ms
Wait for kernel to complete : 100.938 ms
Read back computation results : 2.558 ms
xooxit@user:~/document/Get_Moving_With_Alveo/build$
My question is that
when map/unmap scheme is used as data transfer between host memory and alveo memory, is it NECESSARY to use enqueueMigrateMemObjects for data transfer?
If does or it is helpful, WHAT is the effect of enqueueMigrateMemObjects during map and unmap buffer?
Hi- I wanna take a look into the role of "enqueueMigrateMemObjects" during map/unmap buffer.
So, I comment out "Send the buffer down to the Alveo card" section like below.
Then, compile and run. It works well because the kernel is executed and the results are valid except that the "Memory object migration enqueue" is decreased.
My question is that