This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v3 7/7] y2038: linux: Provide ___gettimeofday64 implementation
- From: Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- To: Joseph Myers <joseph at codesourcery dot com>
- Cc: Lukasz Majewski <lukma at denx dot de>, Paul Eggert <eggert at cs dot ucla dot edu>, Alistair Francis <alistair23 at gmail dot com>, Alistair Francis <alistair dot francis at wdc dot com>, GNU C Library <libc-alpha at sourceware dot org>, Siddhesh Poyarekar <siddhesh at gotplt dot org>, Florian Weimer <fweimer at redhat dot com>, Florian Weimer <fw at deneb dot enyo dot de>, Zack Weinberg <zackw at panix dot com>, Carlos O'Donell <carlos at redhat dot com>, Andreas Schwab <schwab at suse dot de>
- Date: Fri, 7 Feb 2020 09:54:12 -0300
- Subject: Re: [PATCH v3 7/7] y2038: linux: Provide ___gettimeofday64 implementation
- References: <20200129125914.11221-1-lukma@denx.de> <20200129125914.11221-7-lukma@denx.de> <1bfd0cce-e889-7fce-fe7b-d565ca1a1806@linaro.org> <20200205010552.6f0bac91@jawa> <02c823c7-bda4-191a-7825-4727184ae2d7@linaro.org> <20200205175837.1e80e17e@jawa> <ea8f9f38-5d86-e753-ce29-9c9e7cf2e662@linaro.org> <alpine.DEB.2.21.2002062137070.22384@digraph.polyomino.org.uk>
On 06/02/2020 18:41, Joseph Myers wrote:
> On Wed, 5 Feb 2020, Adhemerval Zanella wrote:
>
>> Although marked obsolescent by POSIX, we can't really removed since a
>> program might require to build against a specific POSIX version
>> (_POSIX_C_SOURCE).
>>
>> Once POSIX does remove the symbol, we can remove its definition from
>> default visibility (usually by setting the latest POSIX as default
>> version) and add __attribute_deprecated__.
>
> I don't see that being appropriate for a very long time.
>
> Some symbols marked obsolescent by POSIX are genuinely out of use for a
> very long time, or genuinely have serious deficiencies, and may be
> candidates for obsoleting in various ways in glibc. Some, such as
> gettimeofday are in very widespread use and pose no particular problems -
> so when it's not in current POSIX, I expect we should still declare it for
> __USE_MISC, without a deprecation attribute. (And some symbols are marked
> obsolescent by POSIX because of issues specifying them portably, but are
> very relevant for less-portable code - vfork and getcontext, for example.)
>
I see this as a possible option, I agree that for 'gettimeofday' due its
extensive usage I don't see much gain in setting it as deprecated in near
future.