implement register_host_memory and unregister_host_memory for supa - #8537
frozenleaves wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6eb8d8ca00
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| def register_host_memory(self, address, num_bytes): | ||
| result = int(torch.supa.supart().supaHostRegister(address, num_bytes, 0)) |
There was a problem hiding this comment.
Add tests and documentation for the SUPA memory hooks
This adds externally observable SUPA host-memory registration without the required tests or documentation: tests/unit/v1/pin_memory/test_pin_memory.py covers only the CUDA runtime calls, while docs/code-docs/source/memory.rst still describes native device registration as CUDA-only. Consequently, an incorrect SUPA API name, signature, or error path can ship without coverage, and SUPA users are not told that native allocations can now support accelerator DMA. Add SUPA contract coverage and update the native registration documentation with this feature.
AGENTS.md reference: AGENTS.md:L23-L26
Useful? React with 👍 / 👎.
| def random(self): | ||
| return torch.random | ||
|
|
||
| def register_host_memory(self, address, num_bytes): |
There was a problem hiding this comment.
This is a non-merge commit, but its commit message has no Signed-off-by trailer, so it violates the repository's mandatory DCO requirement and is liable to be rejected by the corresponding CI check. Recreate the commit with --signoff using the configured Git identity.
AGENTS.md reference: AGENTS.md:L6-L10
Useful? React with 👍 / 👎.
|
Hi @frozenleaves needs sign-off DCO, thanks! |
Signed-off-by: frozenleaves <914814442@qq.com>
6eb8d8c to
c979791
Compare
implement register_host_memory and unregister_host_memory for supa #8283