Subject: Re: [u]intptr_t definition for various ports
To: Jaromir Dolecek <jdolecek@netbsd.org>
From: Jason R Thorpe <thorpej@wasabisystems.com>
List: tech-kern
Date: 11/03/2002 12:58:04
On Sun, Nov 03, 2002 at 09:23:37PM +0100, Jaromir Dolecek wrote:
> I noticed the other day that intptr_t is defined as 'int' for some
> archs (sh3, arm, mips) and as 'long' elsewhere (i386, alpha). Is
> there any reason to not use 'long' as intptr_t for ~everything ?
> Well, with exception of special things like N32 for mips.
Changing types like this causes much pain -- because you have to update
the compiler, lint, etc. It amounts to a "flag day", even though it
doesn't actually cause any compatibility problem at the ABI level (it's
a case where the API changes but the ABI remains the same).
Since there is no NEED to change these types, best just to leave these
alone.
BTW, intptr_t is 32-bit (int) on MIPS N32 ... but register_t is 64-bit
(long long).
--
-- Jason R. Thorpe <thorpej@wasabisystems.com>