Thread: Avisynth 2.6 MT
View Single Post
Old 14th August 2009, 02:14   #15  |  Link
SEt
Registered User
 
Join Date: Aug 2007
Posts: 374
No, the behavior is intended - i don't like plan C and would rather disable it. In case of memory starvation this "memory leak" can be quite unpleasant and more dangerous than memory fragmentation that it tries to prevent.

Let's see what can happen after we give bigger buffer than required (and usually it'll be 2..4+x bigger):
1) Big buffer won't be required in future - we are wasting memory, bad.
2) Big buffer will be required before allocated smaller frame is freed - we'll likely have to allocate another big buffer, wasting memory again, bad.
3) Big buffer will be required after smaller frame is freed, but before another smaller frame uses it - good, but i'd say unlikely.

Last edited by SEt; 14th August 2009 at 02:40.
SEt is offline   Reply With Quote