Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!versatc!mips!wje@orac From: wje@orac (William J. Earl) Newsgroups: comp.unix.wizards Subject: Re: MIPS M/120: what's the nlist symbol for cpu time? Message-ID: <22761@orac.mips.COM> Date: 5 Jul 89 18:53:45 GMT References: <397@indri.primate.wisc.edu> Sender: wje@mips.COM Reply-To: wje@orac (William J. Earl) Organization: MIPS Computer Systems Inc. Lines: 12 In-reply-to: bin@primate.wisc.edu (Brain in Neutral) In article <397@indri.primate.wisc.edu>, bin@primate (Brain in Neutral) writes: > > On a VAX, you can nlist "_cp_time" to get the info necessary to grab > cpu time state info from a running system. What's the symbol for > doing this on a MIPS M/120 (running RISC/os 4.0)? Do you use "sysinfo" > and calculate the offset of the cpu field within a struct sysinfo? Yes, use the "cpu" field of "sysinfo" in place of the "_cp_time" array. Note, however, that the number and numeric order of the CPU states is different in RISC/os 4.0 than in 4.3 BSD. (There five states in RISC/os, namely, in order, "idle", "user", "system", "wait", and "sxbrk".)