writefile: optimize undo memory use

Slop-space on Linux wasted ~20% of memory for undo storage.
This commit is contained in:
Campbell Barton 2016-07-08 14:32:29 +10:00
parent a92fc348f4
commit a02915c0f3
1 changed files with 3 additions and 3 deletions

View File

@ -191,9 +191,9 @@
/* ********* my write, buffered writing with minimum size chunks ************ */
#define MYWRITE_BUFFER_SIZE 100000
#define MYWRITE_MAX_CHUNK 32768
/* Use optimal allocation since blocks of this size are kept in memory for undo. */
#define MYWRITE_BUFFER_SIZE (MEM_SIZE_OPTIMAL(1 << 17)) /* 128kb */
#define MYWRITE_MAX_CHUNK (MEM_SIZE_OPTIMAL(1 << 15)) /* ~32kb */
/** \name Small API to handle compression.