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
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Alistair Francis <alistair dot francis at wdc dot com>
- Cc: <libc-alpha at sourceware dot org>, <arnd at arndb dot de>, <adhemerval dot zanella at linaro dot org>, <fweimer at redhat dot com>, <palmer at sifive dot com>, <macro at wdc dot com>, <zongbox at gmail dot com>, <alistair23 at gmail dot com>
- Date: Mon, 12 Aug 2019 19:46:12 +0000
- Subject: Re: [RFC v4 05/24] sysdeps/clock_gettime: Use clock_gettime64 if avaliable
- Ironport-sdr: pu5Je7gOBBts9uaxpnVLV8B7UBLeCXVSFO+f9dLNpTBBytmbNwH9AYzl7/11hjc6RNeBNBgWHb NIkzljs3HwF3jZH6Vql1OEyOoDH3Ixqlrt4J0IASuWGNbZoPkTzVG0xsprShmXnnSJya/aAKPE 4e0ko6Zt2Lzak5OSA9+CVXzmsLMsk4fXV4vwaczX0MhkdtmipHpoWyUfd/PJrxFmga7CYQOyHw mLGprKFV0K/hfsXbnoezoeWN2ApV2ixUYpq3gVedXwb/W5zJ4qnVhKxR1YRF++BHPrT2TveLqD /TM=
- Ironport-sdr: nfJ2cfPtNUJXYVdYPruVmWNXCHlTXGOHk4P1B6HaKbAd/HKfktEJ15JeCLomgs81xQx05G1lep wqcgJqOvyZT0rItZiTf8UfHazL084xFEePdixdvlya5XGGKnN6WD74g1d3E9Be2fqwXC55drWj 82REwx08pLtGeEXDz1MM2EB1NTjmX5bF6EPvzLH/fGqAv7SwkxTR8mGXH/9wccmUzPdcBbqsnT e9LFQLnZ0MfdIqBhuLAgsUgDEuhR/EfcDbwF12+WZc0vpF7OIOsyweSDfCNn5qPFt9wYtBLYEB LxA=
- References: <cover.1565398513.git.alistair.francis@wdc.com> <84b269f1c4a8633e01bd623c07080143c70b785e.1565398513.git.alistair.francis@wdc.com>
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.
--
Joseph S. Myers
joseph@codesourcery.com