| 44 | } |
| 45 | |
| 46 | MemoryPool::~MemoryPool() { |
| 47 | if (mr_) { |
| 48 | ibv_dereg_mr(mr_); |
| 49 | } |
| 50 | if (pool_) { |
| 51 | free(pool_); |
| 52 | } |
| 53 | } |
| 54 | |
| 55 | int MemoryPool::allocate(size_t size, size_t n, SimpleAllocationCallback callback) { |
| 56 | size_t required_blocks = (size + block_size_ - 1) / block_size_; // round up |
nothing calls this directly
no outgoing calls
no test coverage detected