Failed assertion: "pageind >= map_bias"

Jason Evans jasone at canonware.com
Thu Dec 10 09:42:55 PST 2015


On Dec 9, 2015, at 6:19 PM, Eduardo Silva <edsiper at gmail.com> wrote:
> I am facing a segfault when using Jemalloc, it happens with Jemalloc 3.x and 4.0.4. If I use the default system memory allocator (Linux) there is no issues (valgrind cannot find any corruption).
> 
> Would you please advice any step to determinate if the problem it's on my code or on jemalloc it self ?
> ---
> <jemalloc>: /home/edsiper/coding/monkey/deps/jemalloc/include/jemalloc/internal/arena.h:575: Failed assertion: "pageind >= map_bias"
> 
> [...]
> #9  je_free (ptr=0x7fffdc000910) at /home/edsiper/coding/monkey/deps/jemalloc/src/jemalloc.c:1839
> [...]
> ---


You're trying to pass a pointer to free() that is within the chunk header.  Given that the pointer is 0x7fffdc000910, your program is probably doing something very wrong (e.g. corrupting a pointer, or trying to free memory that came from another allocator), because jemalloc will never provide memory to the application with such alignment (i.e. an interior pointer to the first page of a chunk).

Jason



More information about the jemalloc-discuss mailing list