Support doorbell batching for one-sided operations#78
Closed
arajni3 wants to merge 24 commits intojonhoo:mainfrom
Closed
Support doorbell batching for one-sided operations#78arajni3 wants to merge 24 commits intojonhoo:mainfrom
arajni3 wants to merge 24 commits intojonhoo:mainfrom
Conversation
added 23 commits
September 23, 2025 15:15
xmakro
reviewed
Oct 14, 2025
| } | ||
|
|
||
| /// Make a convenient `MemorySlicer`, useful for buffer pools that need to own `MemoryRegions`. | ||
| pub fn mk_slicer(&self) -> MemorySlicer { |
Collaborator
There was a problem hiding this comment.
why is this needed? it seems unrelated to the doorbell batching, so would be good to make a different PR and discuss there
ibverbs/src/lib.rs
Outdated
| pub fn post_one_sided_batch_single_type( | ||
| &mut self, | ||
| is_read: bool, | ||
| wrids_imms: &mut [(u64, Option<u32>)], |
Collaborator
There was a problem hiding this comment.
it would be good to simplify this function interface and avoid having two functions. could we instead introduce something like this:
struct SendWR<L: usize> {
pub is_read: bool, // we should use a proper enum here instead,
pub wr_id: u64,
pub imm_data: Option<u32>,
pub locals: SmallVec::<[LocalMemorySlice; L]>,
pub remote: RemoteMemorySlice,
};
then a single post function that accepts &[SendWR] might be enough for this use case and also the use case in #72
ibverbs/src/lib.rs
Outdated
|
|
||
| /// The doorbell batching API(s) will process only up to these many work requests at a time | ||
| /// to prevent inefficient dynamic heap allocations. | ||
| pub const DOORBELL_BATCH_LIMIT: usize = 32; |
Collaborator
There was a problem hiding this comment.
instead of specifying this as a constant, could we make this a template argument to the post(&[SendWR]) function so that the user has control over it. we can default to 32
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
To avoid a dynamic allocation, we use a local array parameterized by a constant batch limit size.