From:	CRDGW2::CRDGW2::MRGATE::"SMTP::CRVAX.SRI.COM::RELAY-INFO-VAX" 30-NOV-1989 12:07
To:	MRGATE::"ARISIA::EVERHART"
Subj:	PerfMeter V2.0 for DECWindows/VMS, Part 5 of 5 Parts

Received: From CRASH.CS.UMASS.EDU by GIZMO.SRI.COM with TCP; Thu, 30 NOV 89 06:35:11 PDT
Received: from vax3.cs.umass.edu by crash.cs.umass.edu (5.61/Ultrix2.0-B)
	id AA08109; Thu, 30 Nov 89 09:31:56 -0500
Message-Id: <8911301431.AA08109@crash.cs.umass.edu>
Date: Thu, 30 Nov 89 09:30 EST
From: "From the screen of Deneva...  30-Nov-1989 0929" <HELLER@cs.umass.EDU>
Subject: PerfMeter V2.0 for DECWindows/VMS, Part 5 of 5 Parts
To: info-vax@kl.sri.COM
X-Vms-To: coins::in%"info-vax@kl.sri.com"

$ File_is="MAKEFILE."
$ Check_Sum_is=338846279
$ Copy SYS$Input VMS_SHAR_DUMMY.DUMMY
X#
X# Make file for PerfMeter stuff
X#
X
X!CFLAGS = /nolist/debug/noopt/obj=$(MMS$TARGET_NAME).OBJ ! /define=DEBUGGING
X
X!LDFLAGS = /debug/trace
X
XDECWOPTIONS  = DECWSHARLIBRARIES.OPT
X
XUCONST = Perf_Meter_const.dat
X
XUCONST_H = Perf_Meter_const.h
X
XUCONST_UIL = Perf_Meter_const.uil
X
XCPUDEF_H = cpudef.h
X
XPERF_METER_OBJS = Perf_Meter.obj
X
XPERF_METER_SRCS  = Perf_Meter.c
X
XPERF_METER_UIL  = Perf_Meter.uil
X
XPERF_METER_UID  = Perf_Meter.uid
X
XPERF_METER_EXE  = Perf_Meter.exe
X
XKIT_A = PFM020.A
X
XKIT_B = PFM020.B
X
XKIT_A_FILES = pfm020.release_notes, kitinstal.com, $(PERF_METER_UID), -
X	      $(PERF_METER_OBJS), $(DECWOPTIONS), perf_meter.hlp, -
X	      pfm_startup.com
X
XKIT_B_FILES = $(UCONST), $(PERF_METER_SRCS), -
X	      $(PERF_METER_UIL), Makefile., $(UCONST_H), -
X	      $(UCONST_UIL), $(CPUDEF_H)
X
XPOST_KIT_FILES =  pfm020.release_notes, kitinstal.com, -
X		  $(DECWOPTIONS), perf_meter.hlp, pfm_startup.com, -
X		  $(KIT_B_FILES)
X
XPOST_KIT = PFM020_vsh.
X
XUIL = UIL
X
XUILFLAGS = /NOLIST /OUTPUT=$(MMS$TARGET_NAME).UID
X
X.SUFFIXES .UID .UIL
X
X.UIL.UID
X	@ define uil$include decw$include:
X	$(UIL) $(UILFLAGS) $(MMS$SOURCE)
X
X.HLP.HLB
X	IF "''F$SEARCH("$(MMS$TARGET)")'" .EQS. "" -
X	    THEN $(LIBR)/CREATE=(KEY:32)/HELP $(MMS$TARGET)
X	$(LIBR) ($LIBRFLAGS) $(MMS$TARGET) $(MMS$SOURCE)
X
XPerf_Meter. : $(PERF_METER_EXE) $(PERF_METER_UID) 
X	@ copy nl: Perf_Meter.
X	@ purge
X
X$(PERF_METER_EXE) : $(PERF_METER_OBJS) $(DECWOPTIONS)
X	link/exe=$(PERF_METER_EXE) $(PERF_METER_OBJS),$(DECWOPTIONS)/opt/notrace, -
X	    sys$system:sys.stb/selective $(LDFLAGS)
X
XPerf_Meter.obj : Perf_Meter.c $(UCONST_H) $(CPUDEF_H)
X
X
X$(UCONST_H) : $(UCONST)
X	@ puc == "$rcf$util:parse-uil-constants.exe"
X	puc $(UCONST) $(UCONST_H) C
X	
X$(PERF_METER_UID) : $(PERF_METER_UIL) $(UCONST_UIL)
X
X$(UCONST_UIL) : $(UCONST)
X	@ puc == "$rcf$util:parse-uil-constants.exe"
X	puc $(UCONST) $(UCONST_UIL) UIL
X
X! kit and source save sets
X
XKits. : Perf_Meter. $(KIT_A) $(KIT_B) $(POST_KIT)01
X	@ copy nl: kits.
X	@ purge
X
X$(KIT_A) : $(KIT_A_FILES)
X	@ purge $(KIT_A_FILES)
X	backup $(KIT_A_FILES) $(KIT_A)/save/inter/group=0/blo=2048
X	@ purge $(KIT_A)
X
X$(KIT_B) : $(KIT_B_FILES)
X	@ purge $(KIT_B_FILES)
X	backup $(KIT_B_FILES) $(KIT_B)/save/inter/group=0/blo=2048
X	@ purge $(KIT_B)
X
X$(POST_KIT)01 : $(POST_KIT_FILES)
X	@ purge $(POST_KIT_FILES)
X	@rcf$util:vms_shar 'f$edit("$(POST_KIT_FILES)","COLLAPSE")  $(POST_KIT)
X	@ purge $(POST_KIT)*
$ GoSub Convert_File
$ File_is="PERF_METER_CONST.H"
$ Check_Sum_is=271216249
$ Copy SYS$Input VMS_SHAR_DUMMY.DUMMY
X/* main windows */
X
X#define PFM_MAIN_WINDOW 1 
X
X/* Menu bar */
X
X#define PFM_MENU_BAR 2 
X
X/* FIle menu */
X
X#define PFM_EXIT_BUTTON 3 
X
X/* output windows */
X
X#define PFM_CPU_GRAPH 4 
X#define PFM_STATE_GRAPH 5 
X#define PFM_DEVICE_0_IOCOUNT_NAME 6 
X#define PFM_DEVICE_0_IOCOUNT_TOTAL 7 
X#define PFM_DEVICE_0_IOCOUNT_DELTA 8 
X#define PFM_DEVICE_1_IOCOUNT_NAME 9 
X#define PFM_DEVICE_1_IOCOUNT_TOTAL 10 
X#define PFM_DEVICE_1_IOCOUNT_DELTA 11 
X#define PFM_DEVICE_2_IOCOUNT_NAME 12 
X#define PFM_DEVICE_2_IOCOUNT_TOTAL 13 
X#define PFM_DEVICE_2_IOCOUNT_DELTA 14 
X#define PFM_DEVICE_3_IOCOUNT_NAME 15 
X#define PFM_DEVICE_3_IOCOUNT_TOTAL 16 
X#define PFM_DEVICE_3_IOCOUNT_DELTA 17 
X#define PFM_PAGEFAULTS_TOTAL 18 
X#define PFM_PAGEFAULTS_DELTA 19 
X#define PFM_PAGEIO_TOTAL 20 
X#define PFM_PAGEIO_DELTA 21 
X#define PFM_FREEPAGES_TOTAL 22 
X#define PFM_FREEPAGES_DELTA 23 
X#define PFM_MODPAGES_TOTAL 24 
X#define PFM_MODPAGES_DELTA 25 
X
X
X/* max widget - must come last */
X
X#define MAX_WIDGET 26 
$ GoSub Convert_File
$ File_is="PERF_METER_CONST.UIL"
$ Check_Sum_is=52909920
$ Copy SYS$Input VMS_SHAR_DUMMY.DUMMY
X/* main windows */
X
XVALUE PFM_MAIN_WINDOW	: 1; 
X
X/* Menu bar */
X
XVALUE PFM_MENU_BAR	: 2; 
X
X/* FIle menu */
X
XVALUE PFM_EXIT_BUTTON	: 3; 
X
X/* output windows */
X
XVALUE PFM_CPU_GRAPH	: 4; 
XVALUE PFM_STATE_GRAPH	: 5; 
XVALUE PFM_DEVICE_0_IOCOUNT_NAME	: 6; 
XVALUE PFM_DEVICE_0_IOCOUNT_TOTAL	: 7; 
XVALUE PFM_DEVICE_0_IOCOUNT_DELTA	: 8; 
XVALUE PFM_DEVICE_1_IOCOUNT_NAME	: 9; 
XVALUE PFM_DEVICE_1_IOCOUNT_TOTAL	: 10; 
XVALUE PFM_DEVICE_1_IOCOUNT_DELTA	: 11; 
XVALUE PFM_DEVICE_2_IOCOUNT_NAME	: 12; 
XVALUE PFM_DEVICE_2_IOCOUNT_TOTAL	: 13; 
XVALUE PFM_DEVICE_2_IOCOUNT_DELTA	: 14; 
XVALUE PFM_DEVICE_3_IOCOUNT_NAME	: 15; 
XVALUE PFM_DEVICE_3_IOCOUNT_TOTAL	: 16; 
XVALUE PFM_DEVICE_3_IOCOUNT_DELTA	: 17; 
XVALUE PFM_PAGEFAULTS_TOTAL	: 18; 
XVALUE PFM_PAGEFAULTS_DELTA	: 19; 
XVALUE PFM_PAGEIO_TOTAL	: 20; 
XVALUE PFM_PAGEIO_DELTA	: 21; 
XVALUE PFM_FREEPAGES_TOTAL	: 22; 
XVALUE PFM_FREEPAGES_DELTA	: 23; 
XVALUE PFM_MODPAGES_TOTAL	: 24; 
XVALUE PFM_MODPAGES_DELTA	: 25; 
X
X
X/* max widget - must come last */
X
XVALUE MAX_WIDGET	: 26; 
$ GoSub Convert_File
$ File_is="CPUDEF.H"
$ Check_Sum_is=677962690
$ Copy SYS$Input VMS_SHAR_DUMMY.DUMMY
X/* -*-c-mode-*- */
X#define	CPU$C_RESERVED	0
X#define	CPU$C_INIT	1
X#define	CPU$C_RUN	2
X#define	CPU$C_STOPPING	3
X#define	CPU$C_STOPPED	4
X#define	CPU$C_TIMOUT	5
X#define	CPU$C_BOOT_REJECTED	6
X#define	CPU$C_BOOTED	7
X#define	CPU$M_INV_TBS	1
X#define	CPU$M_INV_TBA	2
X#define	CPU$M_TBACK	4
X#define	CPU$M_BUGCHK	8
X#define	CPU$M_BUGCHKACK	16
X#define	CPU$M_RECALSCHD	32
X#define	CPU$M_UPDASTLVL	64
X#define	CPU$M_UPDTODR	128
X#define	CPU$M_WORK_FQP	256
X#define	CPU$M_QLOST	512
X#define	CPU$M_RESCHED	1024
X#define	CPU$M_VIRTCONS	2048
X#define	CPU$M_IOPOST	4096
X#define	CPU$M_CPUFILL_1	268435455
X#define	CPU$M_CPUSPEC1	268435456
X#define	CPU$M_CPUSPEC2	536870912
X#define	CPU$M_CPUSPEC3	1073741824
X#define	CPU$M_CPUSPEC4	-2147483648
X#define	CPU$M_XNNFILL_1	268435455
X#define	CPU$M_XNNSPEC1	268435456
X#define	CPU$M_XNNSPEC2	536870912
X#define	CPU$M_XNNSPEC3	1073741824
X#define	CPU$M_XNNSPEC4	-2147483648
X#define	CPU$M_XSSFILL_1	268435455
X#define	CPU$M_XSSSPEC1	268435456
X#define	CPU$M_XSSSPEC2	536870912
X#define	CPU$M_XSSSPEC3	1073741824
X#define	CPU$M_XSSSPEC4	-2147483648
X#define	CPU$M_XCCFILL_1	268435455
X#define	CPU$M_XCCSPEC1	268435456
X#define	CPU$M_XCCSPEC2	536870912
X#define	CPU$M_XCCSPEC3	1073741824
X#define	CPU$M_XCCSPEC4	-2147483648
X#define	CPU$M_X60FILL_1	268435455
X#define	CPU$M_X60SPEC1	268435456
X#define	CPU$M_X60SPEC2	536870912
X#define	CPU$M_X60SPEC3	1073741824
X#define	CPU$M_X60SPEC4	-2147483648
X#define	CPU$C_MAX_CPUS	32
X#define	CPU$C_8NN_CPUS	2
X#define	CPU$C_8PS_CPUS	4
X#define	CPU$C_8SS_CPUS	16
X#define	CPU$C_9CC_CPUS	16
X#define	CPU$C_9RR_CPUS	16
X#define	CPU$C_60_CPUS	32
X#define	CPU$K_PAGE0_LENGTH	120
X#define	CPU$C_PAGE0_LENGTH	120
X#define	CPU$K_NUM_SWIQS	6
X#define	CPU$K_LENGTH	828
X#define	CPU$C_LENGTH	828
X#define	CPU$C_PAGECNT	2
X#define	CPU$C_STACK	2048
X#define	CPU$S_CPUDEF_PAGE0	512
X#define	CPU$T_CPUDEF_PAGE0	0
Xtypedef struct cpu {
X	unsigned char *cpu$l_curpcb;
X	unsigned char *cpu$l_realstack;
X	short int cpu$w_size;
X	unsigned char cpu$b_type;
X	unsigned char cpu$subtype;
X	unsigned char cpu$b_busywait;
X	unsigned char cpu$b_state;
X	unsigned char cpu$b_cpumtx;
X	unsigned char cpu$b_cur;
X	unsigned char *cpu$l_intstk;
X#define	CPU$R_WORK_REQ_OVERLAY	20
X	long int cpu$l_work_req;
X#define	CPU$V_INV_TBS	0
X#define	CPU$V_INV_TBA	1
X#define	CPU$V_TBACK	2
X#define	CPU$V_BUGCHK	3
X#define	CPU$V_BUGCHKACK	4
X#define	CPU$V_RECALSCHD	5
X#define	CPU$V_UPDASTLVL	6
X#define	CPU$V_UPDTODR	7
X#define	CPU$V_WORK_FQP	8
X#define	CPU$V_QLOST	9
X#define	CPU$V_RESCHED	10
X#define	CPU$V_VIRTCONS	11
X#define	CPU$V_IOPOST	12
X#define	CPU$R_CPUSPEC_OVERLAY	20
X#define	CPU$S_CPUFILL_1	28
X#define	CPU$V_CPUFILL_1	0
X#define	CPU$V_CPUSPEC1	28
X#define	CPU$V_CPUSPEC2	29
X#define	CPU$V_CPUSPEC3	30
X#define	CPU$V_CPUSPEC4	31
X#define	CPU$S_XNNFILL_1	28
X#define	CPU$V_XNNFILL_1	0
X#define	CPU$V_XNNSPEC1	28
X#define	CPU$V_XNNSPEC2	29
X#define	CPU$V_XNNSPEC3	30
X#define	CPU$V_XNNSPEC4	31
X#define	CPU$S_XSSFILL_1	28
X#define	CPU$V_XSSFILL_1	0
X#define	CPU$V_XSSSPEC1	28
X#define	CPU$V_XSSSPEC2	29
X#define	CPU$V_XSSSPEC3	30
X#define	CPU$V_XSSSPEC4	31
X#define	CPU$S_XCCFILL_1	28
X#define	CPU$V_XCCFILL_1	0
X#define	CPU$V_XCCSPEC1	28
X#define	CPU$V_XCCSPEC2	29
X#define	CPU$V_XCCSPEC3	30
X#define	CPU$V_XCCSPEC4	31
X#define	CPU$S_X60FILL_1	28
X#define	CPU$V_X60FILL_1	0
X#define	CPU$V_X60SPEC1	28
X#define	CPU$V_X60SPEC2	29
X#define	CPU$V_X60SPEC3	30
X#define	CPU$V_X60SPEC4	31
X	long int cpu$l_percpuva;
X	long int cpu$l_saved_ap;
X	long int cpu$l_haltpc;
X	long int cpu$l_haltpsl;
X	long int cpu$l_saved_isp;
X	long int cpu$l_pcbb;
X	long int cpu$l_scbb;
X	long int cpu$l_sisr;
X	long int cpu$l_p0br;
X	long int cpu$l_p0lr;
X	long int cpu$l_p1br;
X	long int cpu$l_p1lr;
X	long int cpu$l_bugcode;
X#define	CPU$S_CPUDATA	32
X	union {
X	    unsigned char cpu$b_cpudata[CPU$S_CPUDATA];
X#define cpu$l_sid cpu_data.cpu$l_xxx_sid
X	    struct {
X		long int cpu$l_xxx_sid;
X		long int cpu_filler[7];
X		} cpu_data;
X	    struct {
X		long int cpu$l_8nn_sid;
X		long int cpu$l_8nn_revr2;
X		long int cpu$l_8nn_spare;
X		long int cpu$l_8nn_info;
X		long int cpu$l_8nn_spare1;
X		long int cpu$l_8nn_spare2;
X		long int cpu$l_8nn_spare3;
X		long int cpu$l_8nn_spare4;
X		} cpu_8nn_data;
X	    struct {
X		long int cpu$l_8ss_sid;
X		short int cpu$w_8ss_bootcnt;
X		short int cpu$w_8ss_ipintr;
X		long int cpu$l_8ss_biwindow;
X		long int cpu$l_8ss_mpb;
X		long int cpu$l_8ss_spare1;
X		long int cpu$l_8ss_spare2;
X		long int cpu$l_8ss_spare3;
X		long int cpu$l_8ss_spare4;
X		} cpu_8ss_data;
X	    struct {
X		long int cpu$l_9cc_sid;
X		long int cpu$l_9cc_nodespace;
X		long int cpu$l_9cc_mpb;
X		long int cpu$l_9cc_xsid;
X		long int cpu$l_9cc_spare1;
X		long int cpu$l_9cc_spare2;
X		long int cpu$l_9cc_spare3;
X		long int cpu$l_9cc_spare4;
X		} cpu_9cc_data;
X	    struct {
X		long int cpu$l_9rr_sid;
X		long int cpu$l_9rr_nodespace;
X		long int cpu$l_9rr_mpb;
X		long int cpu$l_9rr_xsid;
X		long int cpu$l_9rr_spare1;
X		long int cpu$l_9rr_spare2;
X		long int cpu$l_9rr_spare3;
X		long int cpu$l_9rr_spare4;
X		} cpu_9rr_data;
X	    struct {
X		long int cpu$l_60_sid;
X		long int cpu$l_60_nodespace;
X		long int cpu$l_60_mpb;
X		long int cpu$l_60_xsid;
X		long int cpu$l_60_spare1;
X		long int cpu$l_60_spare2;
X		long int cpu$l_60_spare3;
X		long int cpu$l_60_spare4;
X		} cpu_60_data;
X	    } cpu_data;
X	long int cpu$l_mchk_mask;
X	long int cpu$l_mchk_sp;
X	long int cpu$l_p0pt_page;
X	unsigned char cpu_fill2[392];
X#define	CPU$S_SWIQFL	48
X	long int cpu$q_swiqfl[12];
X	long int cpu$l_psfl;
X	long int cpu$l_psbl;
X#define	CPU$S_WORK_FQFL	8
X	long int cpu$q_work_fqfl[2];
X#define	CPU$S_WORK_IFQ	8
X#define cpu$q_work_ifq cpu$w_work_fdfl
X	long int cpu$l_qlost_fqfl;
X	long int cpu$l_qlost_fqbl;
X	short int cpu$w_qlost_size;
X	unsigned char cpu$b_qlost_type;
X	unsigned char cpu$b_qlost_flck;
X	long int cpu$l_qlost_fpc;
X	long int cpu$l_qlost_fr3;
X	long int cpu$l_qlost_fr4;
X#define	CPU$S_BOOT_TIME	8
X	long int cpu$q_boot_time[2];
X#define	CPU$S_CPUID_MASK	8
X	long int cpu$q_cpuid_mask[2];
X#define	cpu$l_cpuid_mask cpu$q_cpuid_mask[0]
X	long int cpu$l_phy_cpuid;
X	long int cpu$l_capability;
X	long int cpu$l_tenusec;
X	long int cpu$l_ubdelay;
X#define	CPU$S_KERNEL	7
X	long int cpu$l_kernel[CPU$S_KERNEL];
X	long int cpu$l_nullcpu;
X#define	CPU$S_UKERNEL	7
X	short int cpu$w_ukernel[CPU$S_UKERNEL];
X	short int cpu$w_unullcpu;
X	short int cpu$w_clkutics;
X	short int cpu$w_hardaff;
X	long int cpu$l_rank_vec;
X	long int cpu$l_ipl_vec;
X#define	CPU$S_IPL_ARRAY	32
X	long int cpu$l_ipl_array[CPU$S_IPL_ARRAY];
X	long int cpu$l_tpointer;
X	short int cpu$w_sanity_timer;
X	short int cpu$w_sanity_ticks;
X	} $CPU;
$ GoSub Convert_File

