diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2019-05-21 01:54:03 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2019-05-22 14:29:04 +0300 |
commit | 21dc2816d6bb0a2a85e3a208830b629eb916ded0 (patch) | |
tree | 046dce1d360db51f00c6f293cd3454dcf4945622 /source/blender/draw/intern/draw_instance_data.c | |
parent | 657165db94f14150416c2ee2221eeeafa32603f3 (diff) |
BLI_memblock: Refactor for faster iteration and allocation
Remove the clear allocation flag as it has little impact since there should
be very few allocation per redraw.
Make BLI_memblock_alloc and BLI_memblock_iterstep much more cache efficient
removing them almost entirely from performance profiles.
Diffstat (limited to 'source/blender/draw/intern/draw_instance_data.c')
-rw-r--r-- | source/blender/draw/intern/draw_instance_data.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/draw/intern/draw_instance_data.c b/source/blender/draw/intern/draw_instance_data.c index b88ad936c28..e7a41ee3e43 100644 --- a/source/blender/draw/intern/draw_instance_data.c +++ b/source/blender/draw/intern/draw_instance_data.c @@ -284,9 +284,9 @@ DRWInstanceDataList *DRW_instance_data_list_create(void) { DRWInstanceDataList *idatalist = MEM_callocN(sizeof(DRWInstanceDataList), "DRWInstanceDataList"); - idatalist->pool_batching = BLI_memblock_create(sizeof(GPUBatch), true); - idatalist->pool_instancing = BLI_memblock_create(sizeof(GPUBatch), true); - idatalist->pool_buffers = BLI_memblock_create(sizeof(DRWTempBufferHandle), true); + idatalist->pool_batching = BLI_memblock_create(sizeof(GPUBatch)); + idatalist->pool_instancing = BLI_memblock_create(sizeof(GPUBatch)); + idatalist->pool_buffers = BLI_memblock_create(sizeof(DRWTempBufferHandle)); BLI_addtail(&g_idatalists, idatalist); |