|
|
1.1 ! root 1: /* vmmeter.h 6.1 7/29/83 */ ! 2: ! 3: /* ! 4: * Virtual memory related instrumentation ! 5: */ ! 6: struct vmmeter ! 7: { ! 8: #define v_first v_swtch ! 9: unsigned v_swtch; /* context switches */ ! 10: unsigned v_trap; /* calls to trap */ ! 11: unsigned v_syscall; /* calls to syscall() */ ! 12: unsigned v_intr; /* device interrupts */ ! 13: unsigned v_pdma; /* pseudo-dma interrupts */ ! 14: unsigned v_pswpin; /* pages swapped in */ ! 15: unsigned v_pswpout; /* pages swapped out */ ! 16: unsigned v_pgin; /* pageins */ ! 17: unsigned v_pgout; /* pageouts */ ! 18: unsigned v_pgpgin; /* pages paged in */ ! 19: unsigned v_pgpgout; /* pages paged out */ ! 20: unsigned v_intrans; /* intransit blocking page faults */ ! 21: unsigned v_pgrec; /* total page reclaims */ ! 22: unsigned v_xsfrec; /* found in free list rather than on swapdev */ ! 23: unsigned v_xifrec; /* found in free list rather than in filsys */ ! 24: unsigned v_exfod; /* pages filled on demand from executables */ ! 25: unsigned v_zfod; /* pages zero filled on demand */ ! 26: unsigned v_vrfod; /* fills of pages mapped by vread() */ ! 27: unsigned v_nexfod; /* number of exfod's created */ ! 28: unsigned v_nzfod; /* number of zfod's created */ ! 29: unsigned v_nvrfod; /* number of vrfod's created */ ! 30: unsigned v_pgfrec; /* page reclaims from free list */ ! 31: unsigned v_faults; /* total faults taken */ ! 32: unsigned v_scan; /* scans in page out daemon */ ! 33: unsigned v_rev; /* revolutions of the hand */ ! 34: unsigned v_seqfree; /* pages taken from sequential programs */ ! 35: unsigned v_dfree; /* pages freed by daemon */ ! 36: unsigned v_fastpgrec; /* fast reclaims in locore */ ! 37: #define v_last v_fastpgrec ! 38: unsigned v_swpin; /* swapins */ ! 39: unsigned v_swpout; /* swapouts */ ! 40: }; ! 41: #ifdef KERNEL ! 42: struct vmmeter cnt, rate, sum; ! 43: #endif ! 44: ! 45: /* systemwide totals computed every five seconds */ ! 46: struct vmtotal ! 47: { ! 48: short t_rq; /* length of the run queue */ ! 49: short t_dw; /* jobs in ``disk wait'' (neg priority) */ ! 50: short t_pw; /* jobs in page wait */ ! 51: short t_sl; /* jobs sleeping in core */ ! 52: short t_sw; /* swapped out runnable/short block jobs */ ! 53: int t_vm; /* total virtual memory */ ! 54: int t_avm; /* active virtual memory */ ! 55: short t_rm; /* total real memory in use */ ! 56: short t_arm; /* active real memory */ ! 57: int t_vmtxt; /* virtual memory used by text */ ! 58: int t_avmtxt; /* active virtual memory used by text */ ! 59: short t_rmtxt; /* real memory used by text */ ! 60: short t_armtxt; /* active real memory used by text */ ! 61: short t_free; /* free memory pages */ ! 62: }; ! 63: #ifdef KERNEL ! 64: struct vmtotal total; ! 65: #endif ! 66: ! 67: /* ! 68: * Optional instrumentation. ! 69: */ ! 70: #ifdef PGINPROF ! 71: ! 72: #define NDMON 128 ! 73: #define NSMON 128 ! 74: ! 75: #define DRES 20 ! 76: #define SRES 5 ! 77: ! 78: #define PMONMIN 20 ! 79: #define PRES 50 ! 80: #define NPMON 64 ! 81: ! 82: #define RMONMIN 130 ! 83: #define RRES 5 ! 84: #define NRMON 64 ! 85: ! 86: /* data and stack size distribution counters */ ! 87: unsigned int dmon[NDMON+1]; ! 88: unsigned int smon[NSMON+1]; ! 89: ! 90: /* page in time distribution counters */ ! 91: unsigned int pmon[NPMON+2]; ! 92: ! 93: /* reclaim time distribution counters */ ! 94: unsigned int rmon[NRMON+2]; ! 95: ! 96: int pmonmin; ! 97: int pres; ! 98: int rmonmin; ! 99: int rres; ! 100: ! 101: unsigned rectime; /* accumulator for reclaim times */ ! 102: unsigned pgintime; /* accumulator for page in times */ ! 103: #endif
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.