Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

hardikp/cpp-mempool

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

cpp-mempool

C++ header-only mempool library

Examples

#include <mempool.h>

int main(int argc, char** argv) {
  unsigned capacity = 1024;
  MemPool<int> pool(capacity);

  for (auto i = 0u; i < capacity * 2; i++) {
    int *location = pool.allocate();
  }
}

Notes

  • MemPool is not thread-safe. If you're trying to use a single memory pool from multiple threads, it can create race conditions.

Releases

Packages

Used by

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.