On 16/12/2015 16:32, Christian Brabandt wrote:
Hi Mike!
For me it seems to be caused by patch 7.3.1141:
changeset:   4789:10673b3531eb
tag:         v7.3.1141
user:        Bram Moolenaar <[email protected]>
date:        Fri Jun 07 19:17:14 2013 +0200
files:       src/os_win32.c src/os_win32.h src/version.c
description:
updated for version 7.3.1141
Problem:    Win32: Check for available memory is not reliable and adds
             overhead.
Solution:   Remove mch_avail_mem(). (Mike Williams)

Yeah, I saw that and got a sinking feeling. Double checked and got a working build at the time and double checked. It did not fail for me originally which is why it now feels very sensitive to memory layout in any particular build. It may have been operator error.

While I don't know, if it is sensible to remove mch_avail_mem() on
windows, I believe this only triggers the bug, because when
HAVE_AVAIL_MEM is not set, vim internally sets the 'maxmem' and
'maxmemtot' options to much lower values and I think, high values of
those options just hide the bug.

That is possible - memory allocation pattern changes. Comparing any malloc logs would show more info. Something to investigate.

(a little bit later), yes, If I run vim 7.4.972 and
:set maxmem=1048575 maxmemtot=1048575
(old values since above patch was 2048 for maxmem and 5120 for
maxmemtot, before that patch, 1048575 was used) the corruption does not
occur.

This is probably the reason, the bug does not manifest itself on Linux
since there those options are a lot higher by default.

Hmm, no real reason why for modern Windows OS there should be any difference. Are the lower numbers to cope with older Win95 machines that are unlikely to have as much memory available at all? Should the value for Windows vary on the host OS?

So now we need to figure out, what is actually going wrong ;)

Mem allocator logs and binary chop maxmem values? ;) back at ya!

Mike
--
Mary had a little lamb... with mint jelly.

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui