MIPS M/120: what's the nlist symbol for cpu time?

William J. Earl wje at orac
Thu Jul 6 04:53:45 AEST 1989


In article <397 at indri.primate.wisc.edu>, bin at 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".)



More information about the Comp.unix.wizards mailing list