summaryrefslogtreecommitdiffstats
path: root/man1/memusage.1
diff options
context:
space:
mode:
Diffstat (limited to 'man1/memusage.1')
-rw-r--r--man1/memusage.158
1 files changed, 29 insertions, 29 deletions
diff --git a/man1/memusage.1 b/man1/memusage.1
index b6793f6e8..5c1a630e4 100644
--- a/man1/memusage.1
+++ b/man1/memusage.1
@@ -18,25 +18,25 @@ It preloads the
library into the caller's environment (via the
.B LD_PRELOAD
environment variable; see
-.BR ld.so (8)).
+.MR ld.so 8 ).
The
.B libmemusage.so
library traces memory allocation by intercepting calls to
-.BR malloc (3),
-.BR calloc (3),
-.BR free (3),
+.MR malloc 3 ,
+.MR calloc 3 ,
+.MR free 3 ,
and
-.BR realloc (3);
+.MR realloc 3 ;
optionally, calls to
-.BR mmap (2),
-.BR mremap (2),
+.MR mmap 2 ,
+.MR mremap 2 ,
and
-.BR munmap (2)
+.MR munmap 2
can also be intercepted.
.P
.B memusage
can output the collected data in textual form, or it can use
-.BR memusagestat (1)
+.MR memusagestat 1
(see the
.B \-p
option, below)
@@ -50,34 +50,34 @@ contains three fields:
.TP
\fBheap total\fR
Sum of \fIsize\fR arguments of all
-.BR malloc (3)
+.MR malloc 3
calls,
products of arguments (\fInmemb\fR*\fIsize\fR) of all
-.BR calloc (3)
+.MR calloc 3
calls,
and sum of \fIlength\fR arguments of all
-.BR mmap (2)
+.MR mmap 2
calls.
In the case of
-.BR realloc (3)
+.MR realloc 3
and
-.BR mremap (2),
+.MR mremap 2 ,
if the new size of an allocation is larger than the previous size,
the sum of all such differences (new size minus old size) is added.
.TP
.B "heap peak"
Maximum of all \fIsize\fR arguments of
-.BR malloc (3),
+.MR malloc 3 ,
all products of \fInmemb\fR*\fIsize\fR of
-.BR calloc (3),
+.MR calloc 3 ,
all \fIsize\fR arguments of
-.BR realloc (3),
+.MR realloc 3 ,
.I length
arguments of
-.BR mmap (2),
+.MR mmap 2 ,
and
\fInew_size\fR arguments of
-.BR mremap (2).
+.MR mremap 2 .
.TP
.B "stack peak"
Before the first call to any monitored function,
@@ -91,22 +91,22 @@ Immediately following this summary line, a table shows the number calls,
total memory allocated or deallocated,
and number of failed calls for each intercepted function.
For
-.BR realloc (3)
+.MR realloc 3
and
-.BR mremap (2),
+.MR mremap 2 ,
the additional field "nomove" shows reallocations that
changed the address of a block,
and the additional "dec" field shows reallocations that
decreased the size of the block.
For
-.BR realloc (3),
+.MR realloc 3 ,
the additional field "free" shows reallocations that
caused a block to be freed (i.e., the reallocated size was 0).
.P
The "realloc/total memory" of the table output by
.B memusage
does not reflect cases where
-.BR realloc (3)
+.MR realloc 3
is used to reallocate a block of memory
to have a smaller size than previously.
This can cause sum of all "total memory" cells (excluding "free")
@@ -142,10 +142,10 @@ sampling of stack pointer value.
.TP
.B \-m\fR,\ \fB\-\-mmap
Also trace
-.BR mmap (2),
-.BR mremap (2),
+.MR mmap 2 ,
+.MR mremap 2 ,
and
-.BR munmap (2).
+.MR munmap 2 .
.TP
.B \-?\fR,\ \fB\-\-help
Print help and exit.
@@ -257,6 +257,6 @@ main(int argc, char *argv[])
}
.EE
.SH SEE ALSO
-.BR memusagestat (1),
-.BR mtrace (1),
-.BR ld.so (8)
+.MR memusagestat 1 ,
+.MR mtrace 1 ,
+.MR ld.so 8