This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] y2038: Introduce __ASSUME_TIME64_SYSCALLS define
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Lukasz Majewski <lukma at denx dot de>
- Cc: <libc-alpha at sourceware dot org>, Stepan Golosunov <stepan at golosunov dot pp dot ru>, Arnd Bergmann <arnd at arndb dot de>, Paul Eggert <eggert at cs dot ucla dot edu>
- Date: Thu, 9 May 2019 15:58:38 +0000
- Subject: Re: [PATCH] y2038: Introduce __ASSUME_TIME64_SYSCALLS define
- References: <20190414220841.20243-1-lukma@denx.de> <20190508155608.24791-1-lukma@denx.de>
On Wed, 8 May 2019, Lukasz Majewski wrote:
> For x32 this flag is explicitly undefined as this architecture has
> 64 bit registers but only 32 bit longs and pointers. Moreover, it uses
> syscalls from x86_64.
The first sentence there is not an accurate description of the reason for
undefining this for x32; other ILP32 configurations with 64-bit registers
don't have this peculiarity. "Moreover, it uses syscalls from x86_64."
isn't a good description either; x86_64 has three syscall tables (for
32-bit compat, x32 and the normal LP64 syscall interface).
> + Linux kernel, as of version 5.1, provides following set of syscalls,
> + which accept data based on struct timespec and timeval with 64 bit
> + tv_sec:
Do any of these actually use timeval? I thought the idea was that the new
syscalls for 64-bit time would all use timespec, with it being the
responsibility of libc to handle conversions to and from timeval as needed
(e.g. for gettimeofday with _TIME_BITS=64).
--
Joseph S. Myers
joseph@codesourcery.com