]> git.ipfire.org Git - thirdparty/haproxy.git/commit
DEBUG: sink: add name hint for memory area used by memory-backed sinks
authorAurelien DARRAGON <adarragon@haproxy.com>
Mon, 20 May 2024 13:16:10 +0000 (15:16 +0200)
committerAurelien DARRAGON <adarragon@haproxy.com>
Tue, 21 May 2024 15:55:09 +0000 (17:55 +0200)
commit6c5869f8461a0be2b4839690f446a3aaa6e34006
treec15a921c24ae2d61a4face3c1cdd4544a531ee24
parent6de0da1b54295fdac46e16b5e7707b2199b305f9
DEBUG: sink: add name hint for memory area used by memory-backed sinks

Thanks to ("MINOR: tools: add vma_set_name() helper"), set a name hint
for user created memory-backed sinks (ring sections without backing-file)
so that they can be easily indentified in /proc/<pid>/maps.

Depending on malloc() implementation, such memory areas will normally be
merged on the heap under MMAP_THRESHOLD (128 kB by default) and will
have a dedicated memory area once the threshold is exceeded. As such, when
large enough, they will appear like this in /proc/<pid>/maps:

7b8e8ac00000-7b8e8bf13000 rw-p 00000000 00:00 0                          [anon:ring:myring]
src/sink.c