Lines Matching refs:lp

255 DPCPU_DEFINE_STATIC(struct lock_prof_cpu, lp);
256 #define LP_CPU_SELF (DPCPU_PTR(lp))
257 #define LP_CPU(cpu) (DPCPU_ID_PTR((cpu), lp))
371 lock_prof_output(struct lock_prof *lp, struct sbuf *sb) in lock_prof_output() argument
375 for (p = lp->file; p != NULL && strncmp(p, "../", 3) == 0; p += 3); in lock_prof_output()
378 lp->cnt_max / 1000, lp->cnt_wait_max / 1000, lp->cnt_tot / 1000, in lock_prof_output()
379 lp->cnt_wait / 1000, lp->cnt_cur, in lock_prof_output()
380 lp->cnt_cur == 0 ? (uintmax_t)0 : in lock_prof_output()
381 lp->cnt_tot / (lp->cnt_cur * 1000), in lock_prof_output()
382 lp->cnt_cur == 0 ? (uintmax_t)0 : in lock_prof_output()
383 lp->cnt_wait / (lp->cnt_cur * 1000), in lock_prof_output()
384 (uintmax_t)0, lp->cnt_contest_locking, in lock_prof_output()
385 p, lp->line, lp->class->lc_name, lp->name); in lock_prof_output()
431 struct lock_prof lp = {}; in lock_prof_type_stats() local
435 lock_prof_sum(l, &lp, i, spin, t); in lock_prof_type_stats()
436 lock_prof_output(&lp, sb); in lock_prof_type_stats()
521 struct lock_prof *lp; in lock_profile_lookup() local
533 SLIST_FOREACH(lp, head, link) { in lock_profile_lookup()
534 if (lp->line == line && lp->file == p && in lock_profile_lookup()
535 lp->name == lo->lo_name) in lock_profile_lookup()
536 return (lp); in lock_profile_lookup()
538 lp = SLIST_FIRST(&type->lpt_lpalloc); in lock_profile_lookup()
539 if (lp == NULL) { in lock_profile_lookup()
541 return (lp); in lock_profile_lookup()
544 lp->file = p; in lock_profile_lookup()
545 lp->line = line; in lock_profile_lookup()
546 lp->class = LOCK_CLASS(lo); in lock_profile_lookup()
547 lp->name = lo->lo_name; in lock_profile_lookup()
548 SLIST_INSERT_HEAD(&type->lpt_hash[hash], lp, link); in lock_profile_lookup()
549 return (lp); in lock_profile_lookup()
659 struct lock_prof *lp; in lock_profile_release_lock() local
692 lp = lock_profile_lookup(lo, spin, l->lpo_file, l->lpo_line); in lock_profile_release_lock()
693 if (lp == NULL) in lock_profile_release_lock()
704 if (holdtime > lp->cnt_max) in lock_profile_release_lock()
705 lp->cnt_max = holdtime; in lock_profile_release_lock()
706 if (l->lpo_waittime > lp->cnt_wait_max) in lock_profile_release_lock()
707 lp->cnt_wait_max = l->lpo_waittime; in lock_profile_release_lock()
708 lp->cnt_tot += holdtime; in lock_profile_release_lock()
709 lp->cnt_wait += l->lpo_waittime; in lock_profile_release_lock()
710 lp->cnt_contest_locking += l->lpo_contest_locking; in lock_profile_release_lock()
711 lp->cnt_cur += l->lpo_cnt; in lock_profile_release_lock()