#257 - Add external memory region bindings - #263
Conversation
|
| Filename | Overview |
|---|---|
| src/engine.cpp | Validates external bindings and integrates borrowed allocations into common memory-region setup while retaining caller ownership. |
| src/engines/dpdk/daqiri_dpdk_engine.cpp | Validates both reorder regions against one CUDA device and context and activates that context around CUDA operations. |
| src/engines/ibverbs/daqiri_ibverbs_engine.cpp | Applies matching CUDA device/context checks and context guards to ibverbs reorder setup, processing, and cleanup. |
| src/common.cpp | Adds binding-aware initialization overloads and computes engine-adjusted memory-region requirements. |
| python/daqiri_common_pybind.cpp | Exposes external-memory bindings and requirement queries to Python while preserving GIL release during initialization. |
Reviews (6): Last reviewed commit: "#257 - Add external memory region bindin..." | Re-trigger Greptile
|
Validation gap from the benchmark pass: the existing loopback runs still only exercise DAQIRI-owned memory. They build and run cleanly, but they do not call Since this PR adds a new public C++/Python API plus engine registration behavior for external regions, I think it needs a minimal direct smoke path before merge. A small C++ example or benchmark flag would be enough: parse the software-loopback config, query requirements, |
dleshchev
left a comment
There was a problem hiding this comment.
see comment above, otherwise good to merge
cfcc506 to
d9cc1ab
Compare
Signed-off-by: Cliff Burdick <cburdick@nvidia.com>
a8019ba to
03d996e
Compare
|
General comment: Tested this PR out locally on my setup with an MPS application, it was functional and performant. No other concerns at this time. |
| Bindings may cover only some regions; DAQIRI allocates the rest. Bound memory is borrowed, so its | ||
| allocation and CUDA context must remain alive until `shutdown()` completes. DAQIRI deregisters it | ||
| from the NIC but never frees, unpins, or unmaps it. Direct TCP/UDP sockets reject bindings because | ||
| their configured regions are not packet pools. DPDK also rejects externally bound `huge` regions: |
There was a problem hiding this comment.
We have successfully used a combination of rte_extmem_register(), rte_dev_dma_map(), and mlock() to use externally allocated memory with DPDK.
No description provided.