History log of /freebsd-9.3-release/usr.sbin/kgmon/kgmon.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 267654 19-Jun-2014 gjb

Copy stable/9 to releng/9.3 as part of the 9.3-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 242166 26-Oct-2012 eadler

MFC r241848:
Check the return error of set[e][ug]id. While this can never fail in the
current version of FreeBSD, this isn't guarenteed by the API.
Custom security modules, or future implementations of the setuid and
setgid may fail.

Approved by: cperciva (implicit)


# 225736 22-Sep-2011 kensmith

Copy head to stable/9 as part of 9.0-RELEASE release cycle.

Approved by: re (implicit)


# 160022 29-Jun-2006 delphij

Correct a typo


# 134505 30-Aug-2004 marcel

Improve 64-bit cleanliness: make sure to use long format specifiers for
long arguments. This is WARNS=2 clean now.


# 133249 07-Aug-2004 imp

Per letter dated July 22, 1999 remove 3rd clause of Berkeley derived software
(with permission of addtional copyright holders where appropriate)


# 100904 30-Jul-2002 jake

Fix int/size_t mismatch for sysctl arguments. Try not to introduce more
unsorting.

Reviewed by: bde (unsorted version)


# 99800 11-Jul-2002 alfred

de-__P()


# 91009 21-Feb-2002 bde

Reserved one of the spare fields in struct gmon to record the history
counter type, as threatened in rev.1.8 (the density doesn't need to
be recorded since it can be derived from other fields). This doesn't
affect binary compatibility, but new utilities won't be able to depend
on the contents of this field because libc/gmon/gmon.c was broken --
it wrote garbage to the spare fields.

Added a history counter type field to struct gmonparam. This breaks
binary compatibility a little, since kgmon wanted to read the whole
struct. Fixed kgmon to only depend on reading the critical earlier
parts of the struct. This should also fix 6+ year old breakage of
binary compatibility when the profrate field was added.

Only initialize the new field in struct gmon for now, so that the
compatibility code for this (in kgmon) gets tested. The compatibility
code has to guesstimate the value. The new field in struct gmonparam
is for the kernel to initialize so that kgmon doesn't have to guess.


# 50479 27-Aug-1999 peter

$Id$ -> $FreeBSD$


# 29736 23-Sep-1997 charnier

Use err(3). Add usage() and prototypes.


# 24428 31-Mar-1997 imp

compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.


# 13107 29-Dec-1995 bde

Implemented non-statistical kernel profiling. This is based on
looking at a high resolution clock for each of the following events:
function call, function return, interrupt entry, interrupt exit,
and interesting branches. The differences between the times of
these events are added at appropriate places in a ordinary histogram
(as if very fast statistical profiling sampled the pc at those
places) so that ordinary gprof can be used to analyze the times.

gmon.h:
Histogram counters need to be 4 bytes for microsecond resolutions.
They will need to be larger for the 586 clock.
The comments were vax-centric and wrong even on vaxes. Does anyone
disagree?

gprof4.c:
The standard gprof should support counters of all integral sizes
and the size of the counter should be in the gmon header. This
hack will do until then. (Use gprof4 -u to examine the results
of non-statistical profiling.)

config/*:
Non-statistical profiling is configured with `config -pp'.
`config -p' still gives ordinary profiling.

kgmon/*:
Non-statistical profiling is enabled with `kgmon -B'. `kgmon -b'
still enables ordinary profiling (and distables non-statistical
profiling) if non-statistical profiling is configured.


# 11937 30-Oct-1995 phk

<sys/user.h> -> <sys/time.h>

Spotted by: bde


# 11914 29-Oct-1995 phk

#include <sys/user.h>


# 8857 30-May-1995 rgrimes

Remove trailing whitespace.


# 3041 23-Sep-1994 wollman

Get rid of _PATH_UNIX completely; use getbootfile(3) instead.

DANGER WILL ROBINSON!
_PATH_UNIX is currently defined as the literal string "don't use this".
I am of two minds about this myself, but wanted to get something into the
tree as quickly as possible.


# 1554 26-May-1994 rgrimes

This commit was generated by cvs2svn to compensate for changes in r1553,
which included commits to RCS files with non-trunk default branches.


# 1553 26-May-1994 rgrimes

BSD 4.4 Lite usr.sbin Sources