Commit graph

43 commits

Author SHA1 Message Date
Michal ?iha?
2424b5aa9c Escape dashes in man page
there are two dashes in man page which were forgotten to be escaped.
Attached patch fixes it.
2010-01-02 15:53:04 +01:00
Matt Mackall
38e0c8ef3a Drop obsolete capture script 2010-03-29 16:19:21 -05:00
Matt Mackall
d7fd0ae5f7 Added tag 0.9 for changeset 708dd2e1b91a 2009-11-11 11:03:21 -06:00
lethargo
548d59833d add smem man page
A while back Matthew Miller asked about a man page for smem.  Here is a proposed start of one.
2009-07-15 17:16:34 -05:00
Matt Mackall
5b9a248b9a Fix _ucache some more 2009-07-06 15:20:41 -05:00
Matt Mackall
af11718112 Fix references to _ucache and _gcache 2009-07-06 15:20:05 -05:00
Matt Mackall
6af3327b3d tar source: use usernames and groupnames from tarfile if available 2009-06-23 17:01:12 -05:00
Matt Mackall
95e4829829 Fix some tar header issues for smemcap 2009-06-08 15:15:37 -05:00
Matt Mackall
b3140a9a3d Make system memory reporting more robust
- totalmem should return kB when provided manually
- firmware size never goes below zero
- add comments
- calculate kernel portion of cached by subtracting mapped rather than
  anonymous
- get rid of sum() bits for silly column totals
2009-05-27 18:12:00 -05:00
Matt Mackall
365655364f add smemcap tool 2009-05-22 17:31:54 -05:00
Matt Mackall
3f0ffa8368 be less picky about tar directories 2009-05-22 17:29:51 -05:00
Tim Bird
b78ae87d6b Kernel version >= 2.6.27 check
Jeff Schroeder wrote:
> Awesome tool! I learned about this from the LWN article and
> immediately (stupidly) tried it out on a centos 5 host. Here is a
> patch to add a kernel version check.

This is a nice fix, but the version check should be done against
the proc data being used (which is not necessarily that of the
local kernel).  This required moving kernel_version_check to
after where the src data is read.
2009-05-22 12:41:07 -05:00
Ademar de Souza Reis Jr.
8f77f323fa Fix broken -n option
[ademar@optimus smem]$ ./smem -n
Traceback (most recent call last):
  File "./smem", line 624, in <module>
  ...
2009-05-21 11:46:37 -03:00
???
04b9f552f4 [PATCH] invalid "-K" value cause smem ended with IndexError exception
I do "smem -w -K a.txt -R 2048M" and got following error:
zhichyu@w-shpd-zcyu:~/sftw4ubuntu$ smem-0.1/smem -w -K a.txt -R 2048M
size: 'a.txt': No such file
Traceback (most recent call last):
  File "smem-0.1/smem", line 607, in <module>
    showsystem()
  File "smem-0.1/smem", line 361, in showsystem
    k = kernelsize()
  File "smem-0.1/smem", line 77, in kernelsize
    d = os.popen("size %s" % options.kernel).readlines()[1]
IndexError: list index out of range

The root cause is that os.popen("size a.txt") returns only one line.
If the user provides an invalid kernel image file path, I think it's
better to assume the image size is zero than raise an exception.
2009-05-14 22:22:44 -05:00
???
4865bf2967 [PATCH] physical memory size computing error
There are two minor bugs on physical memory size computing:
(1) fromunits() returns wrong value for "2001844kB", which consists of
more than one digits.
(2) memory()['memtotal'] is in kB. If "--realmem" is not provided at
CLI, totalmem() returns number in MB and the "firmware/hardware"
amount will be minus. totalmem() needs to always return value in kB.

Here is how to test this patch:
(1) Do "smem -w" , the "firmware/hardware" amount should not be minus.
(2) Do "smem -w -R 2001844kB" (change 2001844kB per your PC, note to
keep it in kB unit) , the "firmware/hardware" amount should not be
minus.

Here's a patch to fix these issues.
2009-05-14 22:08:38 -05:00
Jeff Schroeder
52848c0efb Kernel version >= 2.6.27 check
Awesome tool! I learned about this from the LWN article and
immediately (stupidly) tried it out on a centos 5 host. Here is a
patch to add a kernel version check.
2009-04-30 20:04:20 -05:00
Matt Mackall
aab32ae9de Add GPLv2+ license and copyright notice 2009-04-30 11:57:52 -05:00
Matt Mackall
91a412f622 Added tag 0.1 for changeset f168a8d93ec6 2009-04-07 15:17:19 -07:00
Matt Mackall
8adb875a88 catch keyboard interrupts 0.1 2009-04-07 15:14:11 -07:00
Matt Mackall
cd9a831067 Add x labels to bar chart 2009-04-07 15:10:28 -07:00
Matt Mackall
49fe263577 allow -c list, fix bar colors 2009-04-07 14:59:41 -07:00
Matt Mackall
983598c5b0 fix-ups for system view 2009-04-07 11:19:47 -07:00
Matt Mackall
90f16294c7 Add -w system reporting mode 2009-04-07 01:46:22 -07:00
Matt Mackall
88cd5c32e6 Add basic bar chart support 2009-04-07 00:24:39 -07:00
Matt Mackall
37546c5021 break pie chart into separate function 2009-04-06 23:19:46 -07:00
Matt Mackall
a7879677dd add column help 2009-04-06 23:11:36 -07:00
Matt Mackall
589c0de53f change count to pids in map view 2009-04-06 22:50:44 -07:00
Matt Mackall
000c1e0689 Add reading from alternate directory and tarball and example capture script 2009-04-06 22:48:01 -07:00
Matt Mackall
a7aa17b484 remove apss and friends, improve avgpss, add pids 2009-04-06 22:00:51 -07:00
Matt Mackall
8bb4790020 Basic pie chart support 2009-04-05 16:23:34 -05:00
Matt Mackall
40b49768d6 Abstract proc interface 2009-04-04 16:33:00 -05:00
Matt Mackall
d3d4c72f1f Kill empty listings when using -M 2009-04-03 16:50:19 -05:00
Matt Mackall
37261bad86 Add filtering, and vss, avgpss, avguss, and avgrss for maps 2009-04-03 16:34:04 -05:00
Matt Mackall
75829efd67 Add map counts 2009-04-02 02:07:17 -05:00
Matt Mackall
4aacfb5a99 Add VSS, ARSS, AUSS, and APSS. 2009-04-01 21:25:13 -05:00
Matt Mackall
705ba5f79c Add totalmem, --realmem, fromunits, and percentage output 2009-04-01 18:56:37 -05:00
Matt Mackall
7a4509a3c5 Add kernel thread filtering, unit display 2009-03-27 23:39:53 -05:00
Matt Mackall
9448f7cb2e Add user view 2009-03-27 20:43:35 -05:00
Matt Mackall
09d7939030 Get maps view working 2009-03-27 13:10:36 -05:00
Matt Mackall
f411af9d30 Add some command line options 2009-03-26 17:14:49 -05:00
Matt Mackall
fdbec65a91 Add column and header logic 2009-01-30 12:27:06 -06:00
Matt Mackall
3e4d9a1305 Get rid of regexp bits 2009-01-29 18:21:50 -06:00
Matt Mackall
86cfff0bea Start tracking 2009-01-28 14:13:13 -06:00