Skip to content

一种应对频繁申请/释放内存的内存池

Notifications You must be signed in to change notification settings

Yidasvc/YidaMempool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

YidaMempool

一种应对频繁申请/释放内存的内存池 参考NGINX内存池

  1. 创建内存池

Yida_mempool_t* mempool = create_mempool(总可用字节数);

  1. 在内存池中申请内存

void* ptr = mempool_alloc(线程池, 申请字节数);

  1. 释放空间

mempool_free(线程池, 指针ptr);

About

一种应对频繁申请/释放内存的内存池

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages