Commit 15f00097 by Richard Kenner

(get_run_time): Return an approximate value for NT.

From-SVN: r9019
parent d4bb0623
...@@ -931,15 +931,13 @@ int dump_time; ...@@ -931,15 +931,13 @@ int dump_time;
int int
get_run_time () get_run_time ()
{ {
#ifdef WINNT #ifndef WINNT
return 0;
#else
#ifdef USG #ifdef USG
struct tms tms; struct tms tms;
#else #else
#ifndef VMS #ifndef VMS
struct rusage rusage; struct rusage rusage;
#else /* VMS */ #else
struct struct
{ {
int proc_user_time; int proc_user_time;
...@@ -949,10 +947,16 @@ get_run_time () ...@@ -949,10 +947,16 @@ get_run_time ()
} vms_times; } vms_times;
#endif #endif
#endif #endif
#endif
if (quiet_flag) if (quiet_flag)
return 0; return 0;
#ifdef WINNT
if (clock() < 0)
return 0;
else
return (clock() * 1000);
#else /* not WINNT */
#ifdef USG #ifdef USG
times (&tms); times (&tms);
return (tms.tms_utime + tms.tms_stime) * (1000000 / HZ); return (tms.tms_utime + tms.tms_stime) * (1000000 / HZ);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment