Commit Graph

9 Commits

Author SHA1 Message Date
abrown
347a3b2582 Copy over from libkern:
> Prevent recursive invocation of mcount() while in kernel by setting profiling
> state to BUSY while in mcount(). This allows profiling to work when mcount()
> calls a profiled routine (for example, udiv on the SPARC).
1996-06-29 14:32:58 +00:00
cgd
0396d19a02 use p->hashfraction when doing non-time-critical calculations, rather than
using HASHFRACTION directly.  in time-critical calculations, if HASHFRACTION
is a power of two, check that p->hashfraction == HASHFRACTION and if so do
the calculation with the compiled-in value so that the compiler can optimize
out (potentially) expensive divisions.  if p->hashfraction != HASHFRACTION,
actually do the division.  This has the result that on machines with slow
division, the division can be optimized out of the common case, but that
if HASHFRACTION changes from the compiled-in value (for whatever reason),
profiling will still work.  Changes suggested by Chris Torek.
1996-06-12 04:15:34 +00:00
cgd
88fce69ea9 s/KERNEL/_KERNEL/ to match libkern version. 1996-06-12 04:03:33 +00:00
jtc
5c13daa56e Add support for PROFDIR environment variable 1995-11-21 22:23:47 +00:00
cgd
3ddd2ef5ab kill a gratuitous cast of lowpc to an int 1995-11-04 00:11:40 +00:00
cgd
693e99f736 clean up Ids 1995-02-27 12:54:33 +00:00
cgd
ae9172d6cd specify man pages the new way. 1994-12-22 09:57:51 +00:00
cgd
41006bd47b rcsids. also, avoid floating point when picking scale value. doesn't
cost much, only done once.
1994-05-14 06:31:10 +00:00
cgd
da60d30fb3 user-land profiling code. 1994-05-14 06:02:57 +00:00