From: Someone Unknown <someone_lists@bk.ru>
To: community@altlinux.ru
Subject: Re: [Comm] утечка памяти
Date: Mon, 14 Jul 2003 15:48:35 +0400
Message-ID: <200307141548.35136.someone_lists@bk.ru> (raw)
In-Reply-To: <200307141542.36318.maxman@yourline.ru>
В сообщении от 14 Июль 2003 12:42 Ткаченко Максим написал(a):
> Чем можно проверить утечку памяти?
Смотря насколько глубоко она запрятана... 8)
Сначала - libefence, libdmalloc.
Потом malloc debugger, не помню как называется, находится гуглем.
Потом пишем свою обертку вокруг malloc, и пользуясь ей пытаемся узнать, в
каком месте течет.
Если не помогает - значит, текут системные/библиотечные вызовы (opendir,
например, если ему забыли сделать closedir, отъедает аж 4 кило памяти).
В этом случае пишем свой менеджер памяти. 8) При инициализации отъедаем
сколько сможем, а потом в обертке malloc'а раздаем память кусочками. Расход
памяти получается только на системные вызовы. В этом случае отследить, где
течет, становится проще некуда.
--
Regards,
Someone
next prev parent reply other threads:[~2003-07-14 11:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-14 8:42 Ткаченко Максим
2003-07-14 11:48 ` Someone Unknown [this message]
2003-07-14 11:50 ` Egor S. Orlov
2003-07-15 1:25 ` Ткаченко Максим
2003-07-16 6:52 ` Someone Unknown
2003-07-14 14:56 ` A.L. Klyutchenya
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200307141548.35136.someone_lists@bk.ru \
--to=someone_lists@bk.ru \
--cc=community@altlinux.ru \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
ALT Linux Community general discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
public-inbox-index community
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.community
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git