[Ksummit-discuss] [CORE TOPIC] Dealing with 2038

Andy Lutomirski luto at amacapital.net
Sat May 10 00:19:40 UTC 2014


Here's a suggestion.  I don't know whether it's at all practical.
What if we added a mode in which all structs passed into and out of
the kernel use the 64-bit variant *even for 32-bit code*?  Think of it
as the opposite of x32.

This has a big benefit: there's no whole new ABI to maintain.  The
downside is that every single use of unsigned long on the uapi side
will have to change to __u64, etc.  This might be doable
automatically.  Another downside is that some structs may be laid out
differently in the 32-bit C ABI as compared to the 64-bit C ABI, even
given the same primitive type sizes.

Pointers would be tricky.  Hmm.  Could we get gcc and clang to add
__attribute__((64_bit_layout)) if needed?

--Andy


More information about the Ksummit-discuss mailing list