On 19/01/13 15:38, Janne Grunau wrote: > On 2013-01-19 14:29:27 +0100, Luca Barbato wrote: >> Between yesterday and today I started playing and integrating some known >> memory allocators that provide a mean to have a realigned malloc. >> >> Here some numbers from an h264 + ac3 in mkv file >> >> ./avconv_normal >> bench: utime=140.790s maxrss=30508kB >> ./avconv_tlsf >> bench: utime=140.026s maxrss=46428kB >> ./avconv_jemalloc >> bench: utime=137.821s maxrss=56532kB > > 2% faster with ~90% more memory used. > > I think we should deprecate av_realloc() and use realloc or > av_fast_malloc() depending on whether the memory needs to be aligned or > not.
That would give you a slow down + an increase in the memory usage. Is possible to tune better both tlsf and jemalloc. tlsf had been modified to align always to 32 byte in a quite rough way, without the change it was aligning to 16 bytes and wasn't using more memory. I can try to check if an align-always dlmalloc performs better. lu _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel