This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [RFC v4 05/24] sysdeps/clock_gettime: Use clock_gettime64 if avaliable
On Mon, Aug 12, 2019 at 12:46 PM Joseph Myers <joseph@codesourcery.com> wrote:
>
> On Fri, 9 Aug 2019, Alistair Francis wrote:
>
> > /* Get current value of CLOCK and store it in TP. */
> > +
> > int
> > __clock_gettime (clockid_t clock_id, struct timespec *tp)
> > {
> > - return INLINE_VSYSCALL (clock_gettime, 2, clock_id, tp);
> > +
> > +#ifdef __ASSUME_TIME64_SYSCALLS
> > + return INLINE_VSYSCALL (clock_gettime64, 2, clock_id, tp);
> > +#else
>
> This has the usual problems with missing conversions.
I was under the impression (although possibly incorrectly) that if
__ASSUME_TIME64_SYSCALLS is defined we would have a 64-bit time_t. Is
__ASSUME_TIME64_SYSCALLS going to be defined on 32-bit architectures
that are still using a 32-bit time_t?
Alistair
>
> --
> Joseph S. Myers
> joseph@codesourcery.com