Lines Matching refs:old_size

775 static int zend_mm_chunk_truncate(zend_mm_heap *heap, void *addr, size_t old_size, size_t new_size)  argument
780 return heap->storage->handlers.chunk_truncate(heap->storage, addr, old_size, new_size);
787 zend_mm_munmap((char*)addr + new_size, old_size - new_size);
794 static int zend_mm_chunk_extend(zend_mm_heap *heap, void *addr, size_t old_size, size_t new_size) argument
799 return heap->storage->handlers.chunk_extend(heap->storage, addr, old_size, new_size);
807 void *ptr = mremap(addr, old_size, new_size, 0);
815 return (zend_mm_mmap_fixed((char*)addr + old_size, new_size - old_size) != NULL);
1466 size_t old_size; local
1472old_size = zend_mm_get_huge_block_size(heap, ptr ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY…
1490 if (new_size == old_size) {
1497 } else if (new_size < old_size) {
1499 if (zend_mm_chunk_truncate(heap, ptr, old_size, new_size)) {
1501 heap->real_size -= old_size - new_size;
1504 heap->size -= old_size - new_size;
1515 if (UNEXPECTED(new_size - old_size > heap->limit - heap->real_size)) {
1516 if (zend_mm_gc(heap) && new_size - old_size <= heap->limit - heap->real_size) {
1529 if (zend_mm_chunk_extend(heap, ptr, old_size, new_size)) {
1531 heap->real_size += new_size - old_size;
1535 heap->size += new_size - old_size;
1548 …return zend_mm_realloc_slow(heap, ptr, size, MIN(old_size, copy_size) ZEND_FILE_LINE_RELAY_CC ZEND…
1554 size_t old_size; local
1583 old_size = bin_data_size[old_bin_num];
1586 if (size <= old_size) {
1606 copy_size = use_copy_size ? MIN(old_size, copy_size) : old_size;
1631 old_size = ZEND_MM_LRUN_PAGES(info) * ZEND_MM_PAGE_SIZE;
1634 if (new_size == old_size) {
1644 } else if (new_size < old_size) {
1647 int rest_pages_count = (int)((old_size - new_size) / ZEND_MM_PAGE_SIZE);
1666 int old_pages_count = (int)(old_size / ZEND_MM_PAGE_SIZE);
1673 size_t size = heap->size + (new_size - old_size);
1700 copy_size = MIN(old_size, copy_size);
2820 size_t old_size = 0; local
2823 old_size = Z_LVAL_P(old_size_zv);
2826 if (new_size > old_size) {
2827 tracked_check_limit(heap, new_size - old_size);
2837 heap->size += new_size - old_size;