Deleted Added
full compact
kern_synch.c (91066) kern_synch.c (92666)
1/*-
2 * Copyright (c) 1982, 1986, 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 22 unchanged lines hidden (view full) ---

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)kern_synch.c 8.9 (Berkeley) 5/19/95
1/*-
2 * Copyright (c) 1982, 1986, 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 22 unchanged lines hidden (view full) ---

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)kern_synch.c 8.9 (Berkeley) 5/19/95
39 * $FreeBSD: head/sys/kern/kern_synch.c 91066 2002-02-22 13:32:01Z phk $
39 * $FreeBSD: head/sys/kern/kern_synch.c 92666 2002-03-19 11:02:06Z peter $
40 */
41
42#include "opt_ddb.h"
43#include "opt_ktrace.h"
44
45#include <sys/param.h>
46#include <sys/systm.h>
47#include <sys/condvar.h>

--- 825 unchanged lines hidden (view full) ---

873 case SRUN:
874 if ((p->p_flag & P_NOLOAD) != 0)
875 goto nextproc;
876 /* FALLTHROUGH */
877 case SIDL:
878 nrun++;
879 }
880nextproc:
40 */
41
42#include "opt_ddb.h"
43#include "opt_ktrace.h"
44
45#include <sys/param.h>
46#include <sys/systm.h>
47#include <sys/condvar.h>

--- 825 unchanged lines hidden (view full) ---

873 case SRUN:
874 if ((p->p_flag & P_NOLOAD) != 0)
875 goto nextproc;
876 /* FALLTHROUGH */
877 case SIDL:
878 nrun++;
879 }
880nextproc:
881 continue;
881 }
882 }
883 sx_sunlock(&allproc_lock);
884 for (i = 0; i < 3; i++)
885 avg->ldavg[i] = (cexp[i] * avg->ldavg[i] +
886 nrun * FSCALE * (FSCALE - cexp[i])) >> FSHIFT;
887
888 /*

--- 78 unchanged lines hidden ---
882 }
883 }
884 sx_sunlock(&allproc_lock);
885 for (i = 0; i < 3; i++)
886 avg->ldavg[i] = (cexp[i] * avg->ldavg[i] +
887 nrun * FSCALE * (FSCALE - cexp[i])) >> FSHIFT;
888
889 /*

--- 78 unchanged lines hidden ---