aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/_mutex.h
diff options
context:
space:
mode:
authorKip Macy <kmacy@FreeBSD.org>2006-11-11 03:18:07 +0000
committerKip Macy <kmacy@FreeBSD.org>2006-11-11 03:18:07 +0000
commit7c0435b93397740dfc0a916712ce03421b08d08a (patch)
treef43d5c4ecffd369fdc72c9807d30ffd296fd76f6 /sys/sys/_mutex.h
parent1cede0c9bd09db0c031c28ab29cdac914c5a1354 (diff)
downloadsrc-7c0435b93397740dfc0a916712ce03421b08d08a.tar.gz
src-7c0435b93397740dfc0a916712ce03421b08d08a.zip
MUTEX_PROFILING has been generalized to LOCK_PROFILING. We now profile
wait (time waited to acquire) and hold times for *all* kernel locks. If the architecture has a system synchronized TSC, the profiling code will use that - thereby minimizing profiling overhead. Large chunks of profiling code have been moved out of line, the overhead measured on the T1 for when it is compiled in but not enabled is < 1%. Approved by: scottl (standing in for mentor rwatson) Reviewed by: des and jhb
Notes
Notes: svn path=/head/; revision=164159
Diffstat (limited to 'sys/sys/_mutex.h')
-rw-r--r--sys/sys/_mutex.h19
1 files changed, 0 insertions, 19 deletions
diff --git a/sys/sys/_mutex.h b/sys/sys/_mutex.h
index 9b24459456bd..f80603268757 100644
--- a/sys/sys/_mutex.h
+++ b/sys/sys/_mutex.h
@@ -38,25 +38,6 @@ struct mtx {
struct lock_object mtx_object; /* Common lock properties. */
volatile uintptr_t mtx_lock; /* Owner and flags. */
volatile u_int mtx_recurse; /* Number of recursive holds. */
-
-#ifdef MUTEX_PROFILING
- /*
- * This does not result in variant structure sizes because
- * MUTEX_PROFILING is in opt_global.h
- */
- u_int64_t mtx_acqtime;
- const char *mtx_filename;
- int mtx_lineno;
- /*
- * Fields relating to measuring contention on mutexes.
- * holding must be accessed atomically since it's
- * modified by threads that don't yet hold the mutex.
- * locking is only modified and referenced while
- * the mutex is held.
- */
- u_int mtx_contest_holding;
- u_int mtx_contest_locking;
-#endif
};
#endif /* !_SYS__MUTEX_H_ */