about summary refs log tree commit diff
path: root/sysdeps/sparc/sparc64
diff options
context:
space:
mode:
authorRichard Henderson <rth@twiddle.net>2014-06-25 13:58:59 -0700
committerRichard Henderson <rth@twiddle.net>2014-07-03 08:38:30 -0700
commit86e1a7ff92df1589a3a0e0dd44ef2d861e307620 (patch)
tree4d4d60aeed7a88a42ac04f5e0867fc76b832d84f /sysdeps/sparc/sparc64
parent428dd03f5a7291d19f0c45fc314da9356ee22d63 (diff)
downloadglibc-86e1a7ff92df1589a3a0e0dd44ef2d861e307620.tar.gz
glibc-86e1a7ff92df1589a3a0e0dd44ef2d861e307620.tar.xz
glibc-86e1a7ff92df1589a3a0e0dd44ef2d861e307620.zip
Unify hp-timing implementations
Provide an hp-timing-common.h for ports to use.
Diffstat (limited to 'sysdeps/sparc/sparc64')
-rw-r--r--sysdeps/sparc/sparc64/hp-timing.h19
1 files changed, 1 insertions, 18 deletions
diff --git a/sysdeps/sparc/sparc64/hp-timing.h b/sysdeps/sparc/sparc64/hp-timing.h
index 521f64ec43..ea3ba9b780 100644
--- a/sysdeps/sparc/sparc64/hp-timing.h
+++ b/sysdeps/sparc/sparc64/hp-timing.h
@@ -20,10 +20,6 @@
 #ifndef _HP_TIMING_H
 #define _HP_TIMING_H	1
 
-#include <string.h>
-#include <sys/param.h>
-#include <_itoa.h>
-
 #define HP_TIMING_AVAIL		(1)
 #define HP_TIMING_INLINE	(1)
 
@@ -31,19 +27,6 @@ typedef unsigned long int hp_timing_t;
 
 #define HP_TIMING_NOW(Var) __asm__ __volatile__ ("rd %%tick, %0" : "=r" (Var))
 
-#define HP_TIMING_DIFF(Diff, Start, End)	(Diff) = ((End) - (Start))
-
-#define HP_TIMING_ACCUM_NT(Sum, Diff)	(Sum) += (Diff)
-
-#define HP_TIMING_PRINT(Buf, Len, Val) \
-  do {									      \
-    char __buf[20];							      \
-    char *__cp = _itoa (Val, __buf + sizeof (__buf), 10, 0);		      \
-    int __len = (Len);							      \
-    char *__dest = (Buf);						      \
-    while (__len-- > 0 && __cp < __buf + sizeof (__buf))		      \
-      *__dest++ = *__cp++;						      \
-    memcpy (__dest, " clock cycles", MIN (__len, sizeof (" clock cycles")));  \
-  } while (0)
+#include <hp-timing-common.h>
 
 #endif	/* hp-timing.h */