ci_schedstate
if ((++ci->ci_schedstate.spc_schedticks & 0x3f) == 0 &&
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0 ||
if (ci->ci_schedstate.spc_flags & SPCF_NOINTR) {
(current_ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0) {
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0)
sc->sc_cpu[0]->ci_schedstate.spc_cp_time,
sc->sc_cpu[1]->ci_schedstate.spc_cp_time,
if ((newci->ci_schedstate.spc_flags & SPCF_NOINTR) != 0)
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0)
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0)
if ((++cpuinfo.ci_schedstate.spc_schedticks & 7) == 0) {
if ((++cpuinfo.ci_schedstate.spc_schedticks & 7) == 0) {
if ((++cpuinfo.ci_schedstate.spc_schedticks & 7) == 0 && schedhz != 0) {
if ((int)(--ci->ci_schedstate.spc_schedticks) <= 0) {
ci->ci_schedstate.spc_schedticks = statscheddiv;
sc->sc_wasonline = !(ci->ci_schedstate.spc_flags & SPCF_OFFLINE);
if ((ici->ci_schedstate.spc_flags & SPCF_NOINTR) != 0) {
if ((nci->ci_schedstate.spc_flags & SPCF_NOINTR) != 0) {
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0) {
if ((newci->ci_schedstate.spc_flags & SPCF_NOINTR) != 0) {
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) == 0) {
if ((lci->ci_schedstate.spc_flags & SPCF_NOINTR) != 0) {
if ((ci->ci_schedstate.spc_flags &
ci->ci_schedstate.spc_lastmod = time_second;
curcpu()->ci_schedstate.spc_flags |= SPCF_RUNNING;
kl->l_schedflags = l->l_cpu->ci_schedstate.spc_flags;
cp_time[i] += ci->ci_schedstate.spc_cp_time[i];
if ((int)(--ci->ci_schedstate.spc_schedticks) <= 0) {
ci->ci_schedstate.spc_schedticks = hardscheddiv;
if ((--ci->ci_schedstate.spc_ticks) <= 0)
struct schedstate_percpu *spc = &ci->ci_schedstate;
if ((ci->ci_schedstate.spc_flags & SPCF_OFFLINE) != 0)
if ((ci->ci_schedstate.spc_flags & SPCF_NOINTR) != 0)
cs->cs_lastmod = (int32_t)ci->ci_schedstate.spc_lastmod;
(ci->ci_schedstate.spc_lastmod >> 32);
spc = &ci->ci_schedstate;
mspc = &target_ci->ci_schedstate;
mspc = &mci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
if ((ci2->ci_schedstate.spc_flags & SPCF_OFFLINE) != 0)
if (ci2->ci_schedstate.spc_psid != spc->spc_psid)
return (ci->ci_schedstate.spc_flags & wanted) == wanted;
const int ci1_flags = ci1->ci_schedstate.spc_flags;
const int ci2_flags = ci2->ci_schedstate.spc_flags;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
if ((ci2->ci_schedstate.spc_flags & SPCF_NOINTR) != 0)
spc = &ci->ci_schedstate;
KASSERT(l->l_mutex == l->l_cpu->ci_schedstate.spc_lwplock);
lwp_unlock_to(l, ci->ci_schedstate.spc_lwplock);
lwp_unlock_to(l, l->l_cpu->ci_schedstate.spc_lwplock);
tspc = &tci->ci_schedstate;
l->l_mutex = l->l_cpu->ci_schedstate.spc_lwplock;
KASSERT(l2->l_mutex == l2->l_cpu->ci_schedstate.spc_lwplock);
ki->p_schedflags = l->l_cpu->ci_schedstate.spc_flags;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
KASSERT(lwp_locked(l, l->l_cpu->ci_schedstate.spc_mutex));
spc = &l->l_cpu->ci_schedstate;
spc = &ci->ci_schedstate;
KASSERT(lwp_locked(l, ci->ci_schedstate.spc_mutex));
const struct schedstate_percpu *spc = &ci->ci_schedstate;
struct schedstate_percpu *spc = &curcpu()->ci_schedstate;
bestspc = &bestci->ci_schedstate;
curspc = &curci->ci_schedstate;
spc = &ci->ci_schedstate;
curlwp->l_cpu->ci_schedstate.spc_maxpriority) {
curspc = &curci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
tspc = &tci->ci_schedstate;
spc = &ci->ci_schedstate;
tspc = &tci->ci_schedstate;
spc = &ci->ci_schedstate;
tspc = &inner->ci_schedstate;
tspc = &ci->ci_schedstate;
tspc = &tci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
KASSERT(lwp_locked(l, l->l_cpu->ci_schedstate.spc_lwplock));
KASSERT(lwp_locked(l, l->l_cpu->ci_schedstate.spc_lwplock));
KASSERT(mutex_owned(curcpu()->ci_schedstate.spc_mutex));
spc = &ci->ci_schedstate;
KASSERT(l->l_mutex != l->l_cpu->ci_schedstate.spc_mutex);
KASSERT(lwp_locked(l, l->l_cpu->ci_schedstate.spc_lwplock));
KASSERT(lwp_locked(l, l->l_cpu->ci_schedstate.spc_lwplock));
oldlock = lwp_setlock(l, l->l_cpu->ci_schedstate.spc_mutex);
l->l_cpu->ci_schedstate.spc_lwplock);
struct schedstate_percpu *spc = &ci->ci_schedstate;
struct schedstate_percpu *spc = &l->l_cpu->ci_schedstate;
struct schedstate_percpu *spc = &ci->ci_schedstate;
ci->ci_schedstate.spc_flags |=
ci->ci_schedstate.spc_flags &=
ci->ci_schedstate.spc_flags &=
ci3->ci_schedstate.spc_flags |= SPCF_CORE1ST;
if ((ci->ci_schedstate.spc_flags & SPCF_CORE1ST) == 0) {
if ((ci2->ci_schedstate.spc_flags &
if ((ci3->ci_schedstate.spc_flags & SPCF_PACKAGE1ST) != 0) {
ci3->ci_schedstate.spc_flags |= SPCF_PACKAGE1ST;
if ((ci2->ci_schedstate.spc_flags & SPCF_PACKAGE1ST)
ci->ci_schedstate.spc_flags |= SPCF_1STCLASS;
if ((ci->ci_schedstate.spc_flags & SPCF_CORE1ST) != 0) {
ci->ci_schedstate.spc_flags |= SPCF_1STCLASS;
spc = &ci->ci_schedstate;
spc = &ci->ci_schedstate;
ci->ci_schedstate.spc_flags |= SPCF_OFFLINE;
if ((ci->ci_schedstate.spc_flags & SPCF_RUNNING) == 0)
spc = &ci->ci_schedstate;
ispc = &ici->ci_schedstate;
ispc = &ici->ci_schedstate;
curcpu()->ci_schedstate.spc_cp_time[CP_USER],
curcpu()->ci_schedstate.spc_cp_time[CP_NICE],
curcpu()->ci_schedstate.spc_cp_time[CP_SYS] /*+ [CP_INTR]*/,
curcpu()->ci_schedstate.spc_cp_time[CP_IDLE]);
CPUNAME->ci_schedstate.spc_cp_time[CP_USER],
CPUNAME->ci_schedstate.spc_cp_time[CP_NICE],
CPUNAME->ci_schedstate.spc_cp_time[CP_SYS],
CPUNAME->ci_schedstate.spc_cp_time[CP_IDLE]);
idle = curcpu()->ci_schedstate.spc_cp_time[CP_IDLE];
ci->ci_schedstate.spc_mutex =
ci->ci_schedstate.spc_flags = SPCF_RUNNING;
l->l_mutex = rcpu->rcpu_ci->ci_schedstate.spc_mutex;
KASSERT(l->l_mutex == l->l_cpu->ci_schedstate.spc_mutex);
mutex_spin_enter(ci->ci_schedstate.spc_mutex);
mutex_spin_exit(ci->ci_schedstate.spc_mutex);
struct schedstate_percpu *spc1 = &ci1->ci_schedstate;
struct schedstate_percpu *spc2 = &ci2->ci_schedstate;