From: Eric Valette <eric.valette@free.fr>
To: Linus Torvalds <torvalds@osdl.org>, wli@holomorphy.com
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Inconsistancies in /proc (status vs statm) leading to wrong documentation (proc.txt)
Date: Sat, 09 Oct 2004 11:54:31 +0200 [thread overview]
Message-ID: <4167B557.8080202@free.fr> (raw)
Hi,
I'm currently trying use mlockall for a soft RT application and was
concerned by the memory usage of my (big) RT process. So I stated to
look at /proc/<PID>/status and /proc/<PID>/statm and then to the
documentation of statm (Documentation/filesystem/proc.txt) because
unexplained values are rather useless.
The doc currently says :
-------------------------------------------------------------------------
Field Content
size total program size (pages) (same as VmSize in status)
resident size of memory portions (pages) (same as VmRSS in status)
shared number of pages that are shared (i.e. backed by a file)
trs number of pages that are 'code' (not including libs; broken,
includes data segment)
lrs number of pages of library (always 0 on 2.6)
drs number of pages of data/stack (including libs; broken,
includes library text)
dt number of dirty pages (always 0 on 2.6)
---------------------------------------------------------------------------
But when I did cat /proc/<pid>/status and /proc/<pid>/statm the result
where rather different (and not only due to size units). Looking at
/usr/src/linux/fs/proc/task_mmu.c It is not surpising.
May I suggest :
- To use consistent memory size units between status and statm,
- To have VmSize and statm return the same global memory size,
- To eventually display mm->reserved_vm in status and put a word about
it in the doc,
Of course I can send a patch but I would rather let you decide the way
you want to go...
Thanks,
--
__
/ ` Eric Valette
/-- __ o _. 6 rue Paul Le Flem
(___, / (_(_(__ 35740 Pace
Tel: +33 (0)2 99 85 26 76 Fax: +33 (0)2 99 85 26 76
E-mail: eric.valette@free.fr
next reply other threads:[~2004-10-09 9:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-09 9:54 Eric Valette [this message]
-- strict thread matches above, loose matches on Subject: below --
2004-10-09 13:49 Inconsistancies in /proc (status vs statm) leading to wrong documentation (proc.txt) Albert Cahalan
2004-10-09 14:08 ` Eric Valette
2004-10-09 16:31 ` Albert Cahalan
2004-10-09 16:46 ` Eric Valette
2004-10-09 16:59 ` Albert Cahalan
2004-10-09 17:46 ` Eric Valette
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=4167B557.8080202@free.fr \
--to=eric.valette@free.fr \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.org \
--cc=wli@holomorphy.com \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox