Messages in this thread | | | Date | Fri, 25 Apr 2008 12:03:12 -0700 (PDT) | From | Linus Torvalds <> | Subject | Re: [PATCH 01/24] types: create <asm-generic/int-*.h> |
| |
On Fri, 25 Apr 2008, Matthew Wilcox wrote: > > So ... given all this, why do we define s64 to be 'long' on some > architectures and 'long long' on others?
Historical reasons, mainly. Once we start using one type for things like loff_t, it ends up getting encoded in user header files, and we're then basically forced to continue to use that particular type. Some of them end literally being embedded in the compiler itself (ie __builtin_size_t etc end up being known by compiler built-ins).
But yes, we could probably try to standardize the internal kernel s64/u64 types that don't end up spreading anywhere else.
Of course, part of the worry is probably that people thought that maybe "long long" would some day be 128-bit on a 64-bit architecture.
Linus
| |