summaryrefslogtreecommitdiff
path: root/libiberty/getruntime.c
diff options
context:
space:
mode:
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>1999-02-02 23:05:16 +0000
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>1999-02-02 23:05:16 +0000
commit89e305f91dc8f05a84e08a734460dcc4ff1e19a7 (patch)
treec28698afc4fc5a6f1c16183fbbeedd10855eb73d /libiberty/getruntime.c
parentaf434f26181166bd09adee68286d8cafd90a7e27 (diff)
downloadgcc-89e305f91dc8f05a84e08a734460dcc4ff1e19a7.tar.gz
* clock.c (HZ): Define in terms of (ISO C) CLOCKS_PER_SEC on
platforms that don't have HZ. * getruntime.c (HZ): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@24993 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty/getruntime.c')
-rw-r--r--libiberty/getruntime.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/libiberty/getruntime.c b/libiberty/getruntime.c
index 86162225901..74f4dd5b307 100644
--- a/libiberty/getruntime.c
+++ b/libiberty/getruntime.c
@@ -1,5 +1,5 @@
/* Return time used so far, in microseconds.
- Copyright (C) 1994 Free Software Foundation, Inc.
+ Copyright (C) 1994, 1999 Free Software Foundation, Inc.
This file is part of the libiberty library.
Libiberty is free software; you can redistribute it and/or
@@ -47,6 +47,10 @@ Boston, MA 02111-1307, USA. */
#define CLOCKS_PER_SEC 1
#endif
+#if defined (HAVE_TIMES) && ! defined (HZ)
+#define HZ CLOCKS_PER_SEC
+#endif
+
long
get_run_time ()
{