From: eric@burdvax.UUCP (Eric Marshall)
Subject: Re: CPU Timer on VADS Needed
Date: Mon, 28-Jul-86 10:35:14 EDT [thread overview]
Date: Mon Jul 28 10:35:14 1986
Message-ID: <2590@burdvax.UUCP> (raw)
In-Reply-To: 12222213850.15.BRYAN@su-sierra.arpa
I couldn't reach Bryan@SU-SIERRA.ARPA, so I'm posting
it here. See 'man times' for more information. Hope this helps.
----- 8< ----- 8< ----- 8< ----- 8< ----- 8< ----- 8< ----- 8< ----- 8< -----
package cpu_timer is
function cpu return duration;
end cpu_timer;
-------------------------------------------------------------------
with system;
use system;
package body cpu_timer is
function cpu return duration is
type time_record is record
user_time,
system_time,
children_user_time,
children_system_time : integer;
end record;
answer : time_record;
procedure times( param : address );
pragma interface( c, times );
begin
times( answer'address );
return duration( duration( answer.user_time ) / duration( 60.0 ) );
----------------------------
|
|
----- put the expression to meet your
requirements regarding what CPU
time is, ie. ( user_time +
system_time +
children_user_time +
children_system_time )
end cpu;
end cpu_timer;
prev parent reply other threads:[~1986-07-28 14:35 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1986-07-13 1:05 CPU Timer on VADS Needed Bryan
1986-07-28 14:35 ` Eric Marshall [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox