Skip to content

doc: fix inaccessible links to MMD functions #128

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 10, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/buffers.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ The whole enqueue process is as follows:
2. The `l_mem_transfer_buffer_explicitly` function creates a pointer to pointer mapping between the source and destination buffer, copies the memories, and uses one of the following MMD functions to copy one byte from each pointer:

* [`copy_hostmem_to_hostmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1680-L1694) - Uses `memcpy` system calls.
* [`copy_hostmem_to_globalmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1696-L1716) - Calls the MMD function [`aocl_mmd_write`](https://gitlab.devtools.intel.com/OPAE/opencl-bsp/-/blob/master/agilex_f_dk/source/host/ccip_mmd.cpp#L870-879).
* [`copy_globalmem_to_hostmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1718-L1739) - Calls the MMD function [`aocl_mmd_read`](https://gitlab.devtools.intel.com/OPAE/opencl-bsp/-/blob/master/agilex_f_dk/source/host/ccip_mmd.cpp#L870-879).
* [`copy_globalmem_to_globalmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1763-L1873) - If the source and destination are on the same device, then runtime directly calls the MMD function [`aocl_mmd_copy`](https://gitlab.devtools.intel.com/OPAE/opencl-bsp/-/blob/master/agilex_f_dk/source/host/ccip_mmd.cpp#L881-891). Otherwise, it uses both [`aocl_mmd_read`](https://gitlab.devtools.intel.com/OPAE/opencl-bsp/-/blob/master/agilex_f_dk/source/host/ccip_mmd.cpp#L870-879) and [`aocl_mmd_write`](https://gitlab.devtools.intel.com/OPAE/opencl-bsp/-/blob/master/agilex_f_dk/source/host/ccip_mmd.cpp#L870-879) functions to copy from the source device to host and then from the host to the destination device. All operations are blocking. The runtime keeps calling MMD's `yield` (sleep function) function until read and write operations are completed.
* [`copy_hostmem_to_globalmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1696-L1716) - Calls the MMD function [`aocl_mmd_write`](https://github.com/intel/fpga-runtime-for-opencl/blob/eed67743e5204ecd425f71418507af65909521b1/include/MMD/aocl_mmd.h#L347-L352).
* [`copy_globalmem_to_hostmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1718-L1739) - Calls the MMD function [`aocl_mmd_read`](https://github.com/intel/fpga-runtime-for-opencl/blob/eed67743e5204ecd425f71418507af65909521b1/include/MMD/aocl_mmd.h#L341-L346).
* [`copy_globalmem_to_globalmem`](https://github.com/intel/fpga-runtime-for-opencl/blob/fc99b92704a466f7dc4d84bd45d465d64d03dbb0/src/acl_hal_mmd.cpp#L1763-L1873) - If the source and destination are on the same device, then runtime directly calls the MMD function [`aocl_mmd_copy`](https://github.com/intel/fpga-runtime-for-opencl/blob/eed67743e5204ecd425f71418507af65909521b1/include/MMD/aocl_mmd.h#L353-L357). Otherwise, it uses both [`aocl_mmd_read`](https://github.com/intel/fpga-runtime-for-opencl/blob/eed67743e5204ecd425f71418507af65909521b1/include/MMD/aocl_mmd.h#L341-L346) and [`aocl_mmd_write`](https://github.com/intel/fpga-runtime-for-opencl/blob/eed67743e5204ecd425f71418507af65909521b1/include/MMD/aocl_mmd.h#L347-L352) functions to copy from the source device to host and then from the host to the destination device. All operations are blocking. The runtime keeps calling MMD's `yield` (sleep function) function until read and write operations are completed.

### `clSetKernelArg`: What if the `clEnqueueWriteBuffer` function is not called?

Expand Down