History log of /freebsd-current/contrib/jemalloc/src/extent.c
Revision Date Author Comments
# b62ae614 18-Dec-2020 Marcin Wojtas <mw@FreeBSD.org>

Fix abort in jemalloc extent coalescing.

Fix error in extent_try_coalesce_impl(), which could cause abort
to happen when trying to coalesce extents backwards. The error could
happen because of how extent_before_get() function works. This function
gets address of previous extent, by subtracting page size from current
extent address. If current extent is located at PAGE_SIZE offset, this
address resolved to 0x0000. An assertion in rtree_leaf_elm_lookup
then caused the running program to abort.

This problem was discovered when trying to build world on 32-bit
machines with ASLR and PIE enabled. The problem was encountered
on armv7 and i386 machines, but most likely other 32-bit
architectures are affected as well.

While this patch fixes one problem with buildworld on 32-bit platforms
with ASLR, the build still fails, however it happens much later
and due to lack of memory.

The change is aligned with accepted fix in the upstream Jemalloc
repository (https://github.com/jemalloc/jemalloc/pull/1973).
As it doesn't apply on top of Jemalloc tree, its updated version
was eventually merged: https://github.com/jemalloc/jemalloc/pull/2003

PR: 249937
Submitted by: Dawid Gorecki <dgr@semihalf.com>
Obtained from: Semihalf
Sponsored by: Stormshield
Differential Revision: https://reviews.freebsd.org/D27025


# c5ad8142 23-Apr-2020 Eric van Gyzen <vangyzen@FreeBSD.org>

Update jemalloc to version 5.2.1

Revert r354606 to restore r354605.

Apply one line from jemalloc commit d01b425e5d1e1 in hash_x86_128()
to fix the build with gcc, which only allows a fallthrough attribute
to appear before a case or default label.

Submitted by: jasone in r354605
Discussed with: jasone
Reviewed by: bdrewery
MFC after: never, due to gcc 4.2.1
Relnotes: yes
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D24522


# f2cb2907 10-Nov-2019 Jason Evans <jasone@FreeBSD.org>

Revert r354605: Update jemalloc to version 5.2.1.

Compilation fails for non-llvm-based platforms.


# e1c167d0 10-Nov-2019 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to version 5.2.1.


# d5aef6d6 14-Nov-2018 Edward Tomasz Napierala <trasz@FreeBSD.org>

Pick 57553c3b1a5592dc4c03f3c6831d9b794e523865 from upstream:

Avoid touching all pages in extent_recycle for debug build.

We may have a large number of pages with *zero set (since they are populated on
demand). Only check the first page to avoid paging in all of them.

This makes it easy to compare performance with and without 'retain:true'.

Discussed with: jasone
Obtained from: Qi Wang <interwq at gwu dot edu>
MFC after: 2 weeks
Sponsored by: DARPA, AFRL


# 0ef50b4e 10-May-2018 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to version 5.1.0.


# 8b2f5aaf 03-Jul-2017 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to 5.0.1.


# b7eaed25 15-Jun-2017 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to 5.0.0.


# 8244f2aa 01-Mar-2017 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to 4.5.0.


# 7fa7f12f 04-Dec-2016 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to 4.4.0.


# df0d881d 29-Feb-2016 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to 4.1.0.

Add missing Symbol.map entry for __aligned_alloc.

Add weak-->strong symbol binding for
{malloc_stats_print,mallctl,mallctlnametomib,mallctlbymib} -->
{__malloc_stats_print,__mallctl,__mallctlnametomib,__mallctlbymib}. These
bindings complete the set necessary to allow applications to replace all
malloc-related symbols.


# d0e79aa3 17-Aug-2015 Jason Evans <jasone@FreeBSD.org>

Update jemalloc to version 4.0.0.


# a4bd5210 17-Apr-2012 Jason Evans <jasone@FreeBSD.org>

Import jemalloc 9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa (dev branch,
prior to 3.0.0 release) as contrib/jemalloc, and integrate it into libc.
The code being imported by this commit diverged from
lib/libc/stdlib/malloc.c in March 2010, which means that a portion of
the jemalloc 1.0.0 ChangeLog entries are relevant, as are the entries
for all subsequent releases.