Deleted Added
full compact
vm_meter.c (40794) vm_meter.c (42957)
1/*
2 * Copyright (c) 1982, 1986, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)vm_meter.c 8.4 (Berkeley) 1/4/94
1/*
2 * Copyright (c) 1982, 1986, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)vm_meter.c 8.4 (Berkeley) 1/4/94
34 * $Id: vm_meter.c,v 1.26 1998/08/24 08:39:37 dfr Exp $
34 * $Id: vm_meter.c,v 1.27 1998/10/31 17:21:31 peter Exp $
35 */
36
37#include <sys/param.h>
38#include <sys/proc.h>
39#include <sys/systm.h>
40#include <sys/kernel.h>
41#include <sys/resource.h>
42#include <sys/vmmeter.h>

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

190 totalp->t_pw++;
191 }
192 /*
193 * Calculate object memory usage statistics.
194 */
195 for (object = TAILQ_FIRST(&vm_object_list);
196 object != NULL;
197 object = TAILQ_NEXT(object, object_list)) {
35 */
36
37#include <sys/param.h>
38#include <sys/proc.h>
39#include <sys/systm.h>
40#include <sys/kernel.h>
41#include <sys/resource.h>
42#include <sys/vmmeter.h>

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

190 totalp->t_pw++;
191 }
192 /*
193 * Calculate object memory usage statistics.
194 */
195 for (object = TAILQ_FIRST(&vm_object_list);
196 object != NULL;
197 object = TAILQ_NEXT(object, object_list)) {
198 /*
199 * devices, like /dev/mem, will badly skew our totals
200 */
201 if (object->type == OBJT_DEVICE)
202 continue;
198 totalp->t_vm += object->size;
199 totalp->t_rm += object->resident_page_count;
200 if (object->flags & OBJ_ACTIVE) {
201 totalp->t_avm += object->size;
202 totalp->t_arm += object->resident_page_count;
203 }
204 if (object->shadow_count > 1) {
205 /* shared object */

--- 114 unchanged lines hidden ---
203 totalp->t_vm += object->size;
204 totalp->t_rm += object->resident_page_count;
205 if (object->flags & OBJ_ACTIVE) {
206 totalp->t_avm += object->size;
207 totalp->t_arm += object->resident_page_count;
208 }
209 if (object->shadow_count > 1) {
210 /* shared object */

--- 114 unchanged lines hidden ---