[lttng-dev] memory usage depending on number and size of subbuffers
Sébastien Barthélémy
barthelemy at crans.org
Wed Apr 16 12:22:42 EDT 2014
Hi all,
LTTng uses more memory than I expected. On the simple experiment below one
can see that the "cached" memory increases by
subbuf_size*num_cpu*(num_subbuf+1)
That's not a big deal, but I did not expect the "+1".
Does somebody know where it comes from?
-- Regards, Sebastien
12M == 2M*2*(2+1)
24M == 4M*2*(2+1)
20M == 2M*2*(4+1)
40M == 4M*2*(4+1)
# grep processor /proc/cpuinfo
processor : 0
processor : 1
# lttng create
Session auto-20140416-180246 created.
Traces will be written in /root/lttng-traces/auto-20140416-180246
# free -m
total used free shared buffers cached
Mem: 1002 670 332 0 22 250
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng enable-channel channel0 --num-subbuf 2 --subbuf-size 2M -u
UST channel channel0 enabled for session auto-20140416-180246
# free -m
total used free shared buffers cached
Mem: 1002 682 320 0 22 262
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng destroy
Session auto-20140416-180246 destroyed
# lttng create
Session auto-20140416-180317 created.
Traces will be written in /root/lttng-traces/auto-20140416-180317
# free -m
total used free shared buffers cached
Mem: 1002 670 332 0 22 250
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng enable-channel channel0 --num-subbuf 2 --subbuf-size 4M -u
UST channel channel0 enabled for session auto-20140416-180317
# free -m
total used free shared buffers cached
Mem: 1002 694 307 0 22 274
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng destroy
Session auto-20140416-180317 destroyed
# lttng create
Session auto-20140416-180339 created.
Traces will be written in /root/lttng-traces/auto-20140416-180339
# free -m
total used free shared buffers cached
Mem: 1002 670 332 0 22 250
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng enable-channel channel0 --num-subbuf 4 --subbuf-size 2M -u
UST channel channel0 enabled for session auto-20140416-180339
# free -m
total used free shared buffers cached
Mem: 1002 690 311 0 22 270
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng destroy
Session auto-20140416-180339 destroyed
# lttng create
Session auto-20140416-180406 created.
Traces will be written in /root/lttng-traces/auto-20140416-180406
# free -m
total used free shared buffers cached
Mem: 1002 670 332 0 22 250
-/+ buffers/cache: 397 605
Swap: 0 0 0
# lttng enable-channel channel0 --num-subbuf 4 --subbuf-size 4M -u
UST channel channel0 enabled for session auto-20140416-180406
# free -m
total used free shared buffers cached
Mem: 1002 710 292 0 22 290
-/+ buffers/cache: 397 605
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140416/761ac1f5/attachment.html>
More information about the lttng-dev
mailing list