From 5fc48cd78f0c50e889d1c1f3b8f812058db71ecd Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sat, 21 Apr 2001 07:55:01 +0000 Subject: Update. 2001-04-21 Ulrich Drepper * elf/dl-support.c: Include cpuclock-init.h. Use CPUCLOCK_VARDEF and CPUCLOCK_INIT if defined. * sysdeps/generic/dl-sysdep.c: Likewise. * sysdeps/generic/cpuclock-init.h: New file. * sysdeps/unix/i386/i586/cpuclock-init.h: New file. * sysdeps/unix/i386/i586/Versions: New file. * sysdeps/unix/i386/i586/clock_settime.c: New file. * sysdeps/unix/i386/i586/clock_gettime.c: Handle thread CPU clock separately by calling __pthread_clock_gettime if this function is available. Subtract offset from tsc value before computing time value. --- linuxthreads/internals.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'linuxthreads/internals.h') diff --git a/linuxthreads/internals.h b/linuxthreads/internals.h index 998f778..fbe0ea3 100644 --- a/linuxthreads/internals.h +++ b/linuxthreads/internals.h @@ -33,6 +33,7 @@ extern int __compare_and_swap (long int *p, long int oldval, long int newval); #include "pt-machine.h" #include "semaphore.h" #include "../linuxthreads_db/thread_dbP.h" +#include #ifndef THREAD_GETMEM # define THREAD_GETMEM(descr, member) descr->member @@ -179,6 +180,9 @@ struct _pthread_descr_struct { struct __res_state *p_resp; /* Pointer to resolver state */ struct __res_state p_res; /* per-thread resolver state */ int p_inheritsched; /* copied from the thread attribute */ +#ifdef CPUCLOCK_VARDEF + CPUCLOCK_VARDEF (p_cpuclock_offset); /* Initial CPU clock for thread. */ +#endif /* New elements must be added at the end. */ } __attribute__ ((aligned(32))); /* We need to align the structure so that doubles are aligned properly. This is 8 -- cgit v1.1