mirror of
https://github.com/netsurf-browser/netsurf
synced 2025-01-01 16:54:30 +03:00
Replace custom itempool functions with malloc/free as clib handles these more efficiently than our pools.
This commit is contained in:
parent
f38b72a583
commit
2b6a416970
@ -51,10 +51,10 @@ void *ami_memory_clear_alloc(size_t size, UBYTE value);
|
||||
#define ami_memory_itempool_alloc(p,s) ItemPoolAlloc(p)
|
||||
#define ami_memory_itempool_free(p,i,s) ItemPoolFree(p,i)
|
||||
#else
|
||||
#define ami_memory_itempool_create(s) CreatePool(MEMF_ANY, 20 * s, s)
|
||||
#define ami_memory_itempool_delete(p) DeletePool(p)
|
||||
#define ami_memory_itempool_alloc(p,s) AllocPooled(p, s)
|
||||
#define ami_memory_itempool_free(p,i,s) FreePooled(p,i,s)
|
||||
#define ami_memory_itempool_create(s) (NULL)
|
||||
#define ami_memory_itempool_delete(p) ((void)0)
|
||||
#define ami_memory_itempool_alloc(p,s) malloc(s)
|
||||
#define ami_memory_itempool_free(p,i,s) free(p)
|
||||
#endif
|
||||
|
||||
/* clib2 slab allocator */
|
||||
|
Loading…
Reference in New Issue
Block a user