diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-04-05 03:57:32 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-04-05 05:14:05 +0400 |
commit | af59ee340f8859bdcd5f09c54bcb48776adf0c0a (patch) | |
tree | 710718e1336b37d007adfd24f5aaec9b83277fbb /source | |
parent | 321c35ec6ccc91057329af9e5a139715ddc38486 (diff) |
Mempool: remove BLI_MEMPOOL_SYSMALLOC, MEM_* allocs are more efficient now
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/customdata.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/pbvh_bmesh.c | 6 | ||||
-rw-r--r-- | source/blender/blenlib/BLI_linklist_stack.h | 2 | ||||
-rw-r--r-- | source/blender/blenlib/BLI_mempool.h | 4 | ||||
-rw-r--r-- | source/blender/blenlib/intern/BLI_ghash.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/BLI_mempool.c | 56 | ||||
-rw-r--r-- | source/blender/blenlib/intern/edgehash.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_edgeloop.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_log.c | 4 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_mesh.c | 10 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_operators.c | 12 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_walkers.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_connect_pair.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_hull.c | 6 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_beautify.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_edgenet.c | 4 | ||||
-rw-r--r-- | source/blender/imbuf/intern/moviecache.c | 4 |
17 files changed, 46 insertions, 76 deletions
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c index a628504268a..41eb2f5982e 100644 --- a/source/blender/blenkernel/intern/customdata.c +++ b/source/blender/blenkernel/intern/customdata.c @@ -2408,7 +2408,7 @@ void CustomData_bmesh_init_pool(CustomData *data, int totelem, const char htype) /* If there are no layers, no pool is needed just yet */ if (data->totlayer) { - data->pool = BLI_mempool_create(data->totsize, totelem, chunksize, BLI_MEMPOOL_SYSMALLOC); + data->pool = BLI_mempool_create(data->totsize, totelem, chunksize, BLI_MEMPOOL_NOP); } } diff --git a/source/blender/blenkernel/intern/pbvh_bmesh.c b/source/blender/blenkernel/intern/pbvh_bmesh.c index bb3561d38a6..0bdd786f23e 100644 --- a/source/blender/blenkernel/intern/pbvh_bmesh.c +++ b/source/blender/blenkernel/intern/pbvh_bmesh.c @@ -1189,8 +1189,7 @@ bool BKE_pbvh_bmesh_update_topology(PBVH *bvh, PBVHTopologyUpdateMode mode, if (mode & PBVH_Collapse) { EdgeQueue q; - BLI_mempool *queue_pool = BLI_mempool_create(sizeof(BMVert *[2]), - 128, 128, 0); + BLI_mempool *queue_pool = BLI_mempool_create(sizeof(BMVert *[2]), 128, 128, BLI_MEMPOOL_NOP); EdgeQueueContext eq_ctx = {&q, queue_pool, bvh->bm, cd_vert_mask_offset}; short_edge_queue_create(&eq_ctx, bvh, center, radius); @@ -1203,8 +1202,7 @@ bool BKE_pbvh_bmesh_update_topology(PBVH *bvh, PBVHTopologyUpdateMode mode, if (mode & PBVH_Subdivide) { EdgeQueue q; - BLI_mempool *queue_pool = BLI_mempool_create(sizeof(BMVert *[2]), - 128, 128, 0); + BLI_mempool *queue_pool = BLI_mempool_create(sizeof(BMVert *[2]), 128, 128, BLI_MEMPOOL_NOP); EdgeQueueContext eq_ctx = {&q, queue_pool, bvh->bm, cd_vert_mask_offset}; long_edge_queue_create(&eq_ctx, bvh, center, radius); diff --git a/source/blender/blenlib/BLI_linklist_stack.h b/source/blender/blenlib/BLI_linklist_stack.h index ef78fb9a305..c2aefc3f283 100644 --- a/source/blender/blenlib/BLI_linklist_stack.h +++ b/source/blender/blenlib/BLI_linklist_stack.h @@ -56,7 +56,7 @@ #define BLI_LINKSTACK_INIT(var) { \ var = NULL; \ - _##var##_pool = BLI_mempool_create(sizeof(LinkNode), 1, 64, 0); \ + _##var##_pool = BLI_mempool_create(sizeof(LinkNode), 1, 64, BLI_MEMPOOL_NOP); \ } (void)0 #define BLI_LINKSTACK_SIZE(var) \ diff --git a/source/blender/blenlib/BLI_mempool.h b/source/blender/blenlib/BLI_mempool.h index 3fab77f2cb2..25694f4445b 100644 --- a/source/blender/blenlib/BLI_mempool.h +++ b/source/blender/blenlib/BLI_mempool.h @@ -81,8 +81,8 @@ typedef struct BLI_mempool_iter { /* flag */ enum { - BLI_MEMPOOL_SYSMALLOC = (1 << 0), - BLI_MEMPOOL_ALLOW_ITER = (1 << 1) + BLI_MEMPOOL_NOP = 0, + BLI_MEMPOOL_ALLOW_ITER = (1 << 0), }; void BLI_mempool_iternew(BLI_mempool *pool, BLI_mempool_iter *iter) ATTR_NONNULL(); diff --git a/source/blender/blenlib/intern/BLI_ghash.c b/source/blender/blenlib/intern/BLI_ghash.c index f3ebddddc8c..169b98da267 100644 --- a/source/blender/blenlib/intern/BLI_ghash.c +++ b/source/blender/blenlib/intern/BLI_ghash.c @@ -191,7 +191,7 @@ static GHash *ghash_new(GHashHashFP hashfp, GHashCmpFP cmpfp, const char *info, } gh->buckets = MEM_callocN(gh->nbuckets * sizeof(*gh->buckets), "buckets"); - gh->entrypool = BLI_mempool_create(entry_size, 64, 64, 0); + gh->entrypool = BLI_mempool_create(entry_size, 64, 64, BLI_MEMPOOL_NOP); return gh; } diff --git a/source/blender/blenlib/intern/BLI_mempool.c b/source/blender/blenlib/intern/BLI_mempool.c index 04a1b75fcda..e4cff4caae5 100644 --- a/source/blender/blenlib/intern/BLI_mempool.c +++ b/source/blender/blenlib/intern/BLI_mempool.c @@ -140,21 +140,10 @@ static BLI_mempool_chunk *mempool_chunk_alloc(BLI_mempool *pool) { BLI_mempool_chunk *mpchunk; #ifdef USE_DATA_PTR - if (pool->flag & BLI_MEMPOOL_SYSMALLOC) { - mpchunk = malloc(sizeof(BLI_mempool_chunk)); - CHUNK_DATA(mpchunk) = malloc((size_t)pool->csize); - } - else { - mpchunk = MEM_mallocN(sizeof(BLI_mempool_chunk), "BLI_Mempool Chunk"); - CHUNK_DATA(mpchunk) = MEM_mallocN((size_t)pool->csize, "BLI Mempool Chunk Data"); - } + mpchunk = MEM_mallocN(sizeof(BLI_mempool_chunk), "BLI_Mempool Chunk"); + CHUNK_DATA(mpchunk) = MEM_mallocN((size_t)pool->csize, "BLI Mempool Chunk Data"); #else - if (pool->flag & BLI_MEMPOOL_SYSMALLOC) { - mpchunk = malloc(sizeof(BLI_mempool_chunk) + (size_t)pool->csize); - } - else { - mpchunk = MEM_mallocN(sizeof(BLI_mempool_chunk) + (size_t)pool->csize, "BLI_Mempool Chunk"); - } + mpchunk = MEM_mallocN(sizeof(BLI_mempool_chunk) + (size_t)pool->csize, "BLI_Mempool Chunk"); #endif return mpchunk; @@ -219,29 +208,22 @@ static BLI_freenode *mempool_chunk_add(BLI_mempool *pool, BLI_mempool_chunk *mpc return curnode; } -static void mempool_chunk_free(BLI_mempool_chunk *mpchunk, const unsigned int flag) +static void mempool_chunk_free(BLI_mempool_chunk *mpchunk) { - if (flag & BLI_MEMPOOL_SYSMALLOC) { -#ifdef USE_DATA_PTR - free(CHUNK_DATA(mpchunk)); -#endif - free(mpchunk); - } - else { + #ifdef USE_DATA_PTR - MEM_freeN(CHUNK_DATA(mpchunk)); + MEM_freeN(CHUNK_DATA(mpchunk)); #endif - MEM_freeN(mpchunk); - } + MEM_freeN(mpchunk); } -static void mempool_chunk_free_all(BLI_mempool_chunk *mpchunk, const unsigned int flag) +static void mempool_chunk_free_all(BLI_mempool_chunk *mpchunk) { BLI_mempool_chunk *mpchunk_next; for (; mpchunk; mpchunk = mpchunk_next) { mpchunk_next = mpchunk->next; - mempool_chunk_free(mpchunk, flag); + mempool_chunk_free(mpchunk); } } @@ -253,12 +235,7 @@ BLI_mempool *BLI_mempool_create(unsigned int esize, unsigned int totelem, unsigned int i, maxchunks; /* allocate the pool structure */ - if (flag & BLI_MEMPOOL_SYSMALLOC) { - pool = malloc(sizeof(BLI_mempool)); - } - else { - pool = MEM_mallocN(sizeof(BLI_mempool), "memory pool"); - } + pool = MEM_mallocN(sizeof(BLI_mempool), "memory pool"); /* set the elem size */ if (esize < (int)MEMPOOL_ELEM_SIZE_MIN) { @@ -387,7 +364,7 @@ void BLI_mempool_free(BLI_mempool *pool, void *addr) BLI_mempool_chunk *first; first = pool->chunks; - mempool_chunk_free_all(first->next, pool->flag); + mempool_chunk_free_all(first->next); first->next = NULL; #ifdef USE_TOTALLOC @@ -602,7 +579,7 @@ void BLI_mempool_clear_ex(BLI_mempool *pool, const int totelem_reserve) do { mpchunk_next = mpchunk->next; - mempool_chunk_free(mpchunk, pool->flag); + mempool_chunk_free(mpchunk); } while ((mpchunk = mpchunk_next)); } @@ -635,18 +612,13 @@ void BLI_mempool_clear(BLI_mempool *pool) */ void BLI_mempool_destroy(BLI_mempool *pool) { - mempool_chunk_free_all(pool->chunks, pool->flag); + mempool_chunk_free_all(pool->chunks); #ifdef WITH_MEM_VALGRIND VALGRIND_DESTROY_MEMPOOL(pool); #endif - if (pool->flag & BLI_MEMPOOL_SYSMALLOC) { - free(pool); - } - else { - MEM_freeN(pool); - } + MEM_freeN(pool); } #ifndef NDEBUG diff --git a/source/blender/blenlib/intern/edgehash.c b/source/blender/blenlib/intern/edgehash.c index c12efbd80f6..c191d8b5b55 100644 --- a/source/blender/blenlib/intern/edgehash.c +++ b/source/blender/blenlib/intern/edgehash.c @@ -190,7 +190,7 @@ static EdgeHash *edgehash_new(const char *info, } eh->buckets = MEM_callocN(eh->nbuckets * sizeof(*eh->buckets), "eh buckets"); - eh->epool = BLI_mempool_create(entry_size, 512, 512, BLI_MEMPOOL_SYSMALLOC); + eh->epool = BLI_mempool_create(entry_size, 512, 512, BLI_MEMPOOL_NOP); return eh; } diff --git a/source/blender/bmesh/intern/bmesh_edgeloop.c b/source/blender/bmesh/intern/bmesh_edgeloop.c index 4c91f22759b..bedb9c56af6 100644 --- a/source/blender/bmesh/intern/bmesh_edgeloop.c +++ b/source/blender/bmesh/intern/bmesh_edgeloop.c @@ -298,7 +298,7 @@ bool BM_mesh_edgeloops_find_path(BMesh *bm, ListBase *r_eloops, BMVert *v_match[2] = {NULL, NULL}; ListBase lb_src = {NULL, NULL}; ListBase lb_dst = {NULL, NULL}; - BLI_mempool *vs_pool = BLI_mempool_create(sizeof(struct VertStep), 1, 512, 0); + BLI_mempool *vs_pool = BLI_mempool_create(sizeof(struct VertStep), 1, 512, BLI_MEMPOOL_NOP); /* edge args are dummy */ vs_add(vs_pool, &lb_src, v_src, v_src->e, 1); diff --git a/source/blender/bmesh/intern/bmesh_log.c b/source/blender/bmesh/intern/bmesh_log.c index dc8e85bc606..372252db8fe 100644 --- a/source/blender/bmesh/intern/bmesh_log.c +++ b/source/blender/bmesh/intern/bmesh_log.c @@ -373,8 +373,8 @@ static BMLogEntry *bm_log_entry_create(void) entry->added_faces = BLI_ghash_ptr_new(__func__); entry->modified_verts = BLI_ghash_ptr_new(__func__); - entry->pool_verts = BLI_mempool_create(sizeof(BMLogVert), 1, 64, 0); - entry->pool_faces = BLI_mempool_create(sizeof(BMLogFace), 1, 64, 0); + entry->pool_verts = BLI_mempool_create(sizeof(BMLogVert), 1, 64, BLI_MEMPOOL_NOP); + entry->pool_faces = BLI_mempool_create(sizeof(BMLogFace), 1, 64, BLI_MEMPOOL_NOP); return entry; } diff --git a/source/blender/bmesh/intern/bmesh_mesh.c b/source/blender/bmesh/intern/bmesh_mesh.c index 66326a47743..ec01f13414e 100644 --- a/source/blender/bmesh/intern/bmesh_mesh.c +++ b/source/blender/bmesh/intern/bmesh_mesh.c @@ -52,12 +52,12 @@ static void bm_mempool_init(BMesh *bm, const BMAllocTemplate *allocsize) bm->epool = BLI_mempool_create(sizeof(BMEdge), allocsize->totedge, bm_mesh_chunksize_default.totedge, BLI_MEMPOOL_ALLOW_ITER); bm->lpool = BLI_mempool_create(sizeof(BMLoop), allocsize->totloop, - bm_mesh_chunksize_default.totloop, 0); + bm_mesh_chunksize_default.totloop, BLI_MEMPOOL_NOP); bm->fpool = BLI_mempool_create(sizeof(BMFace), allocsize->totface, bm_mesh_chunksize_default.totface, BLI_MEMPOOL_ALLOW_ITER); #ifdef USE_BMESH_HOLES - bm->looplistpool = BLI_mempool_create(sizeof(BMLoopList), 512, 512, 0); + bm->looplistpool = BLI_mempool_create(sizeof(BMLoopList), 512, 512, BLI_MEMPOOL_NOP); #endif } @@ -67,9 +67,9 @@ void BM_mesh_elem_toolflags_ensure(BMesh *bm) return; } - bm->vtoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer), max_ii(512, bm->totvert), 512, 0); - bm->etoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer), max_ii(512, bm->totedge), 512, 0); - bm->ftoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer), max_ii(512, bm->totface), 512, 0); + bm->vtoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer), max_ii(512, bm->totvert), 512, BLI_MEMPOOL_NOP); + bm->etoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer), max_ii(512, bm->totedge), 512, BLI_MEMPOOL_NOP); + bm->ftoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer), max_ii(512, bm->totface), 512, BLI_MEMPOOL_NOP); #pragma omp parallel sections if (bm->totvert + bm->totedge + bm->totface >= BM_OMP_LIMIT) { diff --git a/source/blender/bmesh/intern/bmesh_operators.c b/source/blender/bmesh/intern/bmesh_operators.c index 577e6144e9b..ec94602e8e2 100644 --- a/source/blender/bmesh/intern/bmesh_operators.c +++ b/source/blender/bmesh/intern/bmesh_operators.c @@ -1167,9 +1167,9 @@ static void bmo_flag_layer_alloc(BMesh *bm) bm->totflags++; - bm->vtoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer) * bm->totflags, max_ii(512, bm->totvert), 512, 0); - bm->etoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer) * bm->totflags, max_ii(512, bm->totedge), 512, 0); - bm->ftoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer) * bm->totflags, max_ii(512, bm->totface), 512, 0); + bm->vtoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer) * bm->totflags, max_ii(512, bm->totvert), 512, BLI_MEMPOOL_NOP); + bm->etoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer) * bm->totflags, max_ii(512, bm->totedge), 512, BLI_MEMPOOL_NOP); + bm->ftoolflagpool = BLI_mempool_create(sizeof(BMFlagLayer) * bm->totflags, max_ii(512, bm->totface), 512, BLI_MEMPOOL_NOP); #pragma omp parallel sections if (bm->totvert + bm->totedge + bm->totface >= BM_OMP_LIMIT) { @@ -1248,9 +1248,9 @@ static void bmo_flag_layer_free(BMesh *bm) /* de-increment the totflags first.. */ bm->totflags--; - bm->vtoolflagpool = BLI_mempool_create(new_totflags_size, bm->totvert, 512, 0); - bm->etoolflagpool = BLI_mempool_create(new_totflags_size, bm->totedge, 512, 0); - bm->ftoolflagpool = BLI_mempool_create(new_totflags_size, bm->totface, 512, 0); + bm->vtoolflagpool = BLI_mempool_create(new_totflags_size, bm->totvert, 512, BLI_MEMPOOL_NOP); + bm->etoolflagpool = BLI_mempool_create(new_totflags_size, bm->totedge, 512, BLI_MEMPOOL_NOP); + bm->ftoolflagpool = BLI_mempool_create(new_totflags_size, bm->totface, 512, BLI_MEMPOOL_NOP); #pragma omp parallel sections if (bm->totvert + bm->totedge + bm->totface >= BM_OMP_LIMIT) { diff --git a/source/blender/bmesh/intern/bmesh_walkers.c b/source/blender/bmesh/intern/bmesh_walkers.c index acb97d328cc..72b4c5d6623 100644 --- a/source/blender/bmesh/intern/bmesh_walkers.c +++ b/source/blender/bmesh/intern/bmesh_walkers.c @@ -115,7 +115,7 @@ void BMW_init(BMWalker *walker, BMesh *bm, int type, BLI_assert(mask_face == 0 || (walker->valid_mask & BM_FACE)); } - walker->worklist = BLI_mempool_create(walker->structsize, 100, 100, BLI_MEMPOOL_SYSMALLOC); + walker->worklist = BLI_mempool_create(walker->structsize, 128, 128, BLI_MEMPOOL_NOP); BLI_listbase_clear(&walker->states); } diff --git a/source/blender/bmesh/operators/bmo_connect_pair.c b/source/blender/bmesh/operators/bmo_connect_pair.c index b3d78f40b6f..7f23744d61e 100644 --- a/source/blender/bmesh/operators/bmo_connect_pair.c +++ b/source/blender/bmesh/operators/bmo_connect_pair.c @@ -387,7 +387,7 @@ void bmo_connect_vert_pair_exec(BMesh *bm, BMOperator *op) /* setup context */ { BLI_listbase_clear(&pc.state_lb); - pc.link_pool = BLI_mempool_create(sizeof(PathLink), 1, 512, BLI_MEMPOOL_SYSMALLOC); + pc.link_pool = BLI_mempool_create(sizeof(PathLink), 1, 512, BLI_MEMPOOL_NOP); } /* calculate matrix */ diff --git a/source/blender/bmesh/operators/bmo_hull.c b/source/blender/bmesh/operators/bmo_hull.c index 0a86a84d55b..c0aea34ec35 100644 --- a/source/blender/bmesh/operators/bmo_hull.c +++ b/source/blender/bmesh/operators/bmo_hull.c @@ -213,8 +213,8 @@ static HullFinalEdges *hull_final_edges(GSet *hull_triangles) final_edges = MEM_callocN(sizeof(HullFinalEdges), "HullFinalEdges"); final_edges->edges = BLI_ghash_ptr_new("final edges ghash"); - final_edges->base_pool = BLI_mempool_create(sizeof(ListBase), 128, 128, 0); - final_edges->link_pool = BLI_mempool_create(sizeof(LinkData), 128, 128, 0); + final_edges->base_pool = BLI_mempool_create(sizeof(ListBase), 128, 128, BLI_MEMPOOL_NOP); + final_edges->link_pool = BLI_mempool_create(sizeof(LinkData), 128, 128, BLI_MEMPOOL_NOP); GSET_ITER (iter, hull_triangles) { LinkData *link; @@ -574,7 +574,7 @@ void bmo_convex_hull_exec(BMesh *bm, BMOperator *op) BMO_elem_flag_enable(bm, ele, HULL_FLAG_INTERIOR_ELE); } - hull_pool = BLI_mempool_create(sizeof(HullTriangle), 128, 128, 0); + hull_pool = BLI_mempool_create(sizeof(HullTriangle), 128, 128, BLI_MEMPOOL_NOP); hull_triangles = BLI_gset_ptr_new("hull_triangles"); hull_from_bullet(bm, op, hull_triangles, hull_pool); diff --git a/source/blender/bmesh/tools/bmesh_beautify.c b/source/blender/bmesh/tools/bmesh_beautify.c index 4b5c8789227..cbe704dbf19 100644 --- a/source/blender/bmesh/tools/bmesh_beautify.c +++ b/source/blender/bmesh/tools/bmesh_beautify.c @@ -385,7 +385,7 @@ void BM_mesh_beautify_fill(BMesh *bm, BMEdge **edge_array, const int edge_array_ HeapNode **eheap_table; /* edge index aligned table pointing to the eheap */ GSet **edge_state_arr = MEM_callocN((size_t)edge_array_len * sizeof(GSet *), __func__); - BLI_mempool *edge_state_pool = BLI_mempool_create(sizeof(EdRotState), 512, 512, BLI_MEMPOOL_SYSMALLOC); + BLI_mempool *edge_state_pool = BLI_mempool_create(sizeof(EdRotState), 512, 512, BLI_MEMPOOL_NOP); int i; #ifdef DEBUG_TIME diff --git a/source/blender/bmesh/tools/bmesh_edgenet.c b/source/blender/bmesh/tools/bmesh_edgenet.c index 37a748c238e..576d604c1cb 100644 --- a/source/blender/bmesh/tools/bmesh_edgenet.c +++ b/source/blender/bmesh/tools/bmesh_edgenet.c @@ -443,8 +443,8 @@ void BM_mesh_edgenet(BMesh *bm, const bool use_edge_tag, const bool use_new_face_tag) { VertNetInfo *vnet_info = MEM_callocN(sizeof(*vnet_info) * (size_t)bm->totvert, __func__); - BLI_mempool *edge_queue_pool = BLI_mempool_create(sizeof(LinkNode), 1, 512, 0); - BLI_mempool *path_pool = BLI_mempool_create(sizeof(LinkNode), 1, 512, 0); + BLI_mempool *edge_queue_pool = BLI_mempool_create(sizeof(LinkNode), 1, 512, BLI_MEMPOOL_NOP); + BLI_mempool *path_pool = BLI_mempool_create(sizeof(LinkNode), 1, 512, BLI_MEMPOOL_NOP); LinkNode *edge_queue = NULL; BMEdge *e; diff --git a/source/blender/imbuf/intern/moviecache.c b/source/blender/imbuf/intern/moviecache.c index 6b2251eb24a..87043a5581a 100644 --- a/source/blender/imbuf/intern/moviecache.c +++ b/source/blender/imbuf/intern/moviecache.c @@ -306,8 +306,8 @@ MovieCache *IMB_moviecache_create(const char *name, int keysize, GHashHashFP has BLI_strncpy(cache->name, name, sizeof(cache->name)); - cache->keys_pool = BLI_mempool_create(sizeof(MovieCacheKey), 64, 64, 0); - cache->items_pool = BLI_mempool_create(sizeof(MovieCacheItem), 64, 64, 0); + cache->keys_pool = BLI_mempool_create(sizeof(MovieCacheKey), 64, 64, BLI_MEMPOOL_NOP); + cache->items_pool = BLI_mempool_create(sizeof(MovieCacheItem), 64, 64, BLI_MEMPOOL_NOP); cache->userkeys_pool = BLI_mempool_create(keysize, 64, 64, 0); cache->hash = BLI_ghash_new(moviecache_hashhash, moviecache_hashcmp, "MovieClip ImBuf cache hash"); |