disable current in-place growth code path for now

pull/87/head
Daniel Micay 2019-04-09 19:15:43 -04:00
parent d5c1bca915
commit d5c00b4d0d
1 changed files with 19 additions and 16 deletions

View File

@ -1386,6 +1386,8 @@ EXPORT void *h_realloc(void *old, size_t size) {
return old; return old;
} }
static const bool vma_merging_reliable = false;
if (vma_merging_reliable) {
// in-place growth // in-place growth
void *guard_end = (char *)old + old_size + old_guard_size; void *guard_end = (char *)old + old_size + old_guard_size;
size_t extra = size - old_size; size_t extra = size - old_size;
@ -1405,6 +1407,7 @@ EXPORT void *h_realloc(void *old, size_t size) {
return old; return old;
} }
} }
}
size_t copy_size = min(size, old_size); size_t copy_size = min(size, old_size);
if (copy_size >= MREMAP_MOVE_THRESHOLD) { if (copy_size >= MREMAP_MOVE_THRESHOLD) {