-
Notifications
You must be signed in to change notification settings - Fork 403
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
util/bufpool: Do not zero newly allocated buf pool memory when init f…
…unction is present. When a buf pool allocates a new chunk of memory, the entire memory chunk is zeroed out via a call to memset. This can be quite costly, occur at inconvenient times, and end up being wasteful when buf pool users initialize their own entries. This change skips the memset when the buf pool has an init function specified. For users who want no initialization to take place in the buf pool code at all, a new ofi_bufpool_init_none() function is available to specify as the init function to use. Signed-off-by: Ben Lynam <Ben.Lynam@cornelisnetworks.com>
- Loading branch information
Showing
2 changed files
with
15 additions
and
3 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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