<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/jemalloc.git, branch dev</title>
<subtitle>github.com: jemalloc/jemalloc
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/'/>
<entry>
<title>Allow overriding `LG_PAGE`</title>
<updated>2023-05-17T20:55:38+00:00</updated>
<author>
<name>Kevin Svetlitski</name>
<email>svetlitski@meta.com</email>
</author>
<published>2023-05-15T17:39:15+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=4e6f1e920814eafb4ca165a861e9c886022b35e3'/>
<id>4e6f1e920814eafb4ca165a861e9c886022b35e3</id>
<content type='text'>
This is useful for our internal builds where we override the
configuration in the header files generated by autoconf.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is useful for our internal builds where we override the
configuration in the header files generated by autoconf.
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove dead stores detected by static analysis</title>
<updated>2023-05-12T03:27:49+00:00</updated>
<author>
<name>Kevin Svetlitski</name>
<email>svetlitski@meta.com</email>
</author>
<published>2023-04-26T21:10:41+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=3e2ba7a6510be583edb316372f8cfff35f2f25d5'/>
<id>3e2ba7a6510be583edb316372f8cfff35f2f25d5</id>
<content type='text'>
None of these are harmful, and they are almost certainly optimized
away by the compiler. The motivation for fixing them anyway is that
we'd like to enable static analysis as part of CI, and the first step
towards that is resolving the warnings it produces at present.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
None of these are harmful, and they are almost certainly optimized
away by the compiler. The motivation for fixing them anyway is that
we'd like to enable static analysis as part of CI, and the first step
towards that is resolving the warnings it produces at present.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix possible `NULL` pointer dereference from `mallctl("prof.prefix", ...)`</title>
<updated>2023-05-11T21:47:50+00:00</updated>
<author>
<name>Kevin Svetlitski</name>
<email>svetlitski@meta.com</email>
</author>
<published>2023-05-11T21:20:30+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=0288126d9cc0d061766e37cbbaabaa78aff3aff5'/>
<id>0288126d9cc0d061766e37cbbaabaa78aff3aff5</id>
<content type='text'>
Static analysis flagged this issue. Here is a minimal program which
causes a segfault within Jemalloc:
```
#include &lt;jemalloc/jemalloc.h&gt;

const char *malloc_conf = "prof:true";

int main() {
  mallctl("prof.prefix", NULL, NULL, NULL, 0);
}
```

Fixed by checking if `prefix` is `NULL`.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Static analysis flagged this issue. Here is a minimal program which
causes a segfault within Jemalloc:
```
#include &lt;jemalloc/jemalloc.h&gt;

const char *malloc_conf = "prof:true";

int main() {
  mallctl("prof.prefix", NULL, NULL, NULL, 0);
}
```

Fixed by checking if `prefix` is `NULL`.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add the prof_sys_thread_name feature in the prof_recent unit test.</title>
<updated>2023-05-11T16:10:57+00:00</updated>
<author>
<name>Qi Wang</name>
<email>interwq@gwu.edu</email>
</author>
<published>2023-05-10T23:32:51+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=d4a2b8bab10980d4677d43560f27ac9ef66cde45'/>
<id>d4a2b8bab10980d4677d43560f27ac9ef66cde45</id>
<content type='text'>
This tests the combination of the prof_recent and thread_name features.
Verified that it catches the issue being fixed in this PR.

Also explicitly set thread name in test/unit/prof_recent.  This fixes the name
testing when no default thread name is set (e.g. FreeBSD).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This tests the combination of the prof_recent and thread_name features.
Verified that it catches the issue being fixed in this PR.

Also explicitly set thread name in test/unit/prof_recent.  This fixes the name
testing when no default thread name is set (e.g. FreeBSD).
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix the prof thread_name reference in prof_recent dump.</title>
<updated>2023-05-11T16:10:57+00:00</updated>
<author>
<name>Qi Wang</name>
<email>interwq@gwu.edu</email>
</author>
<published>2023-05-10T20:20:40+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=94ace05832209543bde81d0a5f0e2a9660243abd'/>
<id>94ace05832209543bde81d0a5f0e2a9660243abd</id>
<content type='text'>
As pointed out in #2434, the thread_name in prof_tdata_t was changed in #2407.
This also requires an update for the prof_recent dump, specifically the emitter
expects a "char **" which is fixed in this commit.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As pointed out in #2434, the thread_name in prof_tdata_t was changed in #2407.
This also requires an update for the prof_recent dump, specifically the emitter
expects a "char **" which is fixed in this commit.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add config detection for JEMALLOC_HAVE_PTHREAD_SET_NAME_NP.</title>
<updated>2023-05-11T16:10:57+00:00</updated>
<author>
<name>Qi Wang</name>
<email>interwq@gwu.edu</email>
</author>
<published>2023-05-10T23:20:14+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=6ea8a7e928c86f7976c5e1356a22292509f8705b'/>
<id>6ea8a7e928c86f7976c5e1356a22292509f8705b</id>
<content type='text'>
and use it on the background thread name setting.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
and use it on the background thread name setting.
</pre>
</div>
</content>
</entry>
<entry>
<title>If ptr present check if alloc_ctx.edata == NULL</title>
<updated>2023-05-11T00:18:22+00:00</updated>
<author>
<name>auxten</name>
<email>auxten@users.noreply.github.com</email>
</author>
<published>2023-05-03T14:34:30+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=5bac384970a8224daee0b07475950a5291fc37d3'/>
<id>5bac384970a8224daee0b07475950a5291fc37d3</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Make arenas_lookup_ctl triable</title>
<updated>2023-05-11T00:18:22+00:00</updated>
<author>
<name>auxten</name>
<email>auxten@users.noreply.github.com</email>
</author>
<published>2023-05-03T05:25:12+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=019cccc293f96c9f7886373d816aab061f65f7de'/>
<id>019cccc293f96c9f7886373d816aab061f65f7de</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix possible `NULL` pointer dereference in `VERIFY_READ`</title>
<updated>2023-05-09T17:57:09+00:00</updated>
<author>
<name>Kevin Svetlitski</name>
<email>svetlitski@meta.com</email>
</author>
<published>2023-05-09T01:18:39+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=dc0a184f8d349546af6a051eb87be47715eacff3'/>
<id>dc0a184f8d349546af6a051eb87be47715eacff3</id>
<content type='text'>
Static analysis flagged this. Fixed by simply checking `oldlenp`
before dereferencing it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Static analysis flagged this. Fixed by simply checking `oldlenp`
before dereferencing it.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix segfault in `extent_try_coalesce_impl`</title>
<updated>2023-05-09T17:55:44+00:00</updated>
<author>
<name>Kevin Svetlitski</name>
<email>svetlitski@meta.com</email>
</author>
<published>2023-05-09T16:37:01+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/jemalloc.git/commit/?id=12311fe6c37720225a3e8b5798e7051d153d29c1'/>
<id>12311fe6c37720225a3e8b5798e7051d153d29c1</id>
<content type='text'>
Static analysis flagged this. `extent_record` was passing `NULL` as the
value for `coalesced` to `extent_try_coalesce`, which in turn passes
that argument to `extent_try_coalesce_impl`, where it is written to
without checking if it is `NULL`. I can confirm from reviewing the
fleetwide coredump data that this was in fact being hit in production.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Static analysis flagged this. `extent_record` was passing `NULL` as the
value for `coalesced` to `extent_try_coalesce`, which in turn passes
that argument to `extent_try_coalesce_impl`, where it is written to
without checking if it is `NULL`. I can confirm from reviewing the
fleetwide coredump data that this was in fact being hit in production.
</pre>
</div>
</content>
</entry>
</feed>
