mirror of
https://sourceware.org/git/glibc.git
synced 2025-12-24 17:51:17 +03:00
Update.
2001-04-21 Ulrich Drepper <drepper@redhat.com> * 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.
This commit is contained in:
@@ -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 <cpuclock-init.h>
|
||||
|
||||
#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
|
||||
|
||||
Reference in New Issue
Block a user