unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Adhemerval Zanella <adhemerval.zanella@linaro.org>
To: libc-alpha@sourceware.org
Subject: Re: Accelerating Y2038 glibc fixes
Date: Thu, 18 Jul 2019 15:53:28 -0300	[thread overview]
Message-ID: <d0b001c8-cc18-f79f-d1b8-e2aeb3d07fc5@linaro.org> (raw)
In-Reply-To: <20190717181811.5902cd5e@jawa>


[-- Attachment #1.1: Type: text/plain, Size: 4286 bytes --]



On 17/07/2019 13:18, Lukasz Majewski wrote:
> Hi Florian,
> 
>> * Wolfgang Denk:
>>
>>> Dear Florian,
>>>
>>> In message <875zo0911b.fsf@oldenburg2.str.redhat.com> you wrote:  
>>>> * Arnd Bergmann:
>>>>  
>>>>> b) Those that already need support for 64-bit time_t because
>>>>>     they are deploying new 32-bit binaries that are expected to
>>>>> run beyond 2038, while not caring at all about compatibility
>>>>>     with existing binaries that are already known to be broken
>>>>>     for this purpose.  
>>>>
>>>> There is also c), new 32-bit architectures which need 64-bit time_t
>>>> support today due to kernel limitations.  Whether those binaries
>>>> need to run for two years or twenty does not matter to them.
>>>>
>>>> I have reviewed patches for the c) case, but that doesn't seem to
>>>> be work that interests Wolfgang.  
>>>
>>> Correct - our situation is Arnd's case b).
>>>
>>> But my understanding is that for c) glibc has to modify the generic
>>> syscalls wrapper (like clock_gettime/nanosleep/settime, etc.), and
>>> for b) we also need to do that first.  But currently we are stuck at
>>> the point where the __ASSUME_TIME64_SYSCALLS flag is not accepted /
>>> pulled.
>>>
>>> So b) and c) align in development...  
>>
>> Can you do without __ASSUME_TIME64_SYSCALLS?  Most other __ASSUME_*
>> macros are an optimization, and if your interest is b),
>> __ASSUME_TIME64_SYSCALLS will not be the default for glibc
>> distribution builds anyway because defining it would negatively
>> impact host kernel compatibility.  It's not just about containers in
>> the fashionable sense, but simple build chroots are problematic as
>> well in this context.
>>
>> Or have you received different guidance that __ASSUME_TIME64_SYSCALLS
>> markup is absolutely required for the initial contribution?
> 
> The __ASSUME_TIME64_SYSCALLS was discussed with Joseph and Stepan (both
> CC'ed) for a long time on the libc-alpha mailing list. The discussion
> can be found here [1] (last link is the newest one).
> 
> 
> 
> As fair as I understood from the previous discussion, adding
> __ASSUME_TIME64_SYSCALLS is a first step to add Y2038 support (or 64 bit
> time support to 32 bit archs in general).
> 
> The latest patch (v8) with semantics explanation of
> __ASSUME_TIME64_SYSCALLS: [2]
>  
> Note:
> 
> [1] Evolution of __ASSUME_TIME64_SYSCALLS up till v7:
> 
> https://patchwork.ozlabs.org/patch/1092579/
> https://patchwork.ozlabs.org/patch/1096343/
> https://patchwork.ozlabs.org/patch/1096349/
> https://patchwork.ozlabs.org/patch/1097132/
> https://patchwork.ozlabs.org/patch/1100097/
> https://patchwork.ozlabs.org/patch/1107125/
> https://patchwork.ozlabs.org/patch/1114061/
> https://patchwork.ozlabs.org/patch/1117100/
> 
> [2] - https://patchwork.ozlabs.org/patch/1117100/

More and more I see that a possible disruption in a release due to a 
possible ABI change should be a net gain over time by moving to a better
alternative.  The off64 migration required a lot of efforts and its 
issues still hit us in a way or another (BZ#23960), especially because 
off64 is *not* default for 32-bit builds neither on new 32-bits ports 
(on glibc side). Even now, from BZ#23960 comments, it seems that 
distributions still do not use LFS for some packages builds, it required 
Linux to force us to move forward.

So what about to not add a user-selected way to set the time_t size
(as off_t) and just enable time64_t support and sets is as default for 
build with a minimum kernel of v5.1 (if I recall correctly as being the 
one that added time64 support)? 

It will move all time32 support as compat symbols for the required ABI, 
without an option to select it through a build flag. Newer ports will
just have the expected symbol names, no tinkering needed.

And yes, it will mostly break stuff once people start to build distributions 
with these options. However, it will save us time to figure out all the bits
and joints required at cost of an initially high cost of adaptation plus
the all required code complexity and testing to support the multiple 
permutation possible.

I also wish we could also move forward with off_t and set LFS as default
as well.


  


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2019-07-18 18:53 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-12  7:21 Accelerating Y2038 glibc fixes Wolfgang Denk
2019-07-16  9:32 ` Wolfgang Denk
2019-07-16 11:50 ` Siddhesh Poyarekar
2019-07-16 12:40   ` Wolfgang Denk
2019-07-16 12:44 ` Florian Weimer
2019-07-16 14:52   ` Wolfgang Denk
2019-07-16 15:09     ` Florian Weimer
2019-07-16 15:19       ` Andrew Pinski
2019-07-17 14:15     ` Arnd Bergmann
2019-07-17 14:41       ` Florian Weimer
2019-07-17 16:00         ` Wolfgang Denk
2019-07-17 16:04           ` Florian Weimer
2019-07-17 16:18             ` Lukasz Majewski
2019-07-18 18:53               ` Adhemerval Zanella [this message]
2019-07-18 19:13                 ` Florian Weimer
2019-07-18 20:31                   ` Adhemerval Zanella
2019-07-18 21:20                     ` Florian Weimer
2019-07-18 22:32                     ` Paul Eggert
2019-07-19  7:21                       ` Andreas Schwab
2019-07-19  3:06                     ` Rich Felker
2019-07-19 17:44                       ` Adhemerval Zanella
2019-07-19 19:03                         ` Alistair Francis
2019-07-25 20:40                 ` Joseph Myers
2019-07-29 17:47                   ` Adhemerval Zanella
2019-07-29 19:58                     ` Joseph Myers
2019-07-29 21:00                       ` Adhemerval Zanella
2019-07-29 21:08                         ` Joseph Myers
2019-07-29 23:12                           ` Paul Eggert
2019-07-29 23:30                             ` Joseph Myers
2019-07-17 17:50       ` Rich Felker
2019-07-17 21:57         ` Lukasz Majewski
2019-07-17 22:37           ` Rich Felker
2019-07-18  7:20             ` Lukasz Majewski
2019-07-18 13:35               ` Rich Felker
2019-07-18 14:47           ` Rich Felker
2019-07-18 14:49             ` Florian Weimer
2019-07-18 15:46               ` Rich Felker
2019-07-18 16:43                 ` Adhemerval Zanella
2019-07-20  4:43             ` Rich Felker
2019-07-25 19:54 ` Joseph Myers
2019-07-26 10:39   ` Lukasz Majewski
2019-07-29 18:55     ` Zack Weinberg
2019-07-29 20:12       ` Joseph Myers
2019-07-30 11:02         ` Lukasz Majewski
2019-07-30 12:24           ` Joseph Myers
2019-07-30 14:04       ` Lukasz Majewski
2019-08-09  7:25         ` Lukasz Majewski
     [not found]           ` <CAKCAbMhOMQ9yTFpy+OQkDvZPPFf_fFn6oSxjvLTaUwC4jpPRag@mail.gmail.com>
2019-08-09 12:32             ` Fwd: " Zack Weinberg
2019-07-30 19:58       ` Joseph Myers
2019-07-30 20:28         ` Florian Weimer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/libc/involved.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d0b001c8-cc18-f79f-d1b8-e2aeb3d07fc5@linaro.org \
    --to=adhemerval.zanella@linaro.org \
    --cc=libc-alpha@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).