Question about 64-bit code safety
Philip Prindeville
philipp_subx at redfish-solutions.com
Tue Sep 6 22:57:47 PDT 2005
Dave Airlie wrote:
>>and noted two things... (1) it varies from what's in the X.org CVS tree,
>>and (2) it ignores the value of __WORDSIZE...
>>
>>Should it instead read:
>>
>>#if defined(__linux__) && (__WORDSIZE==32)
>>
>>instead? Or am I missing something?
>>
>>
>
>The DRM needs to be imported into the X.org tree, it hasn't been yet,
>I'm unsure of the exact procedure I think we wait until 7.0rc1 is
>ready to go perhaps? Mesa also needs to be imported with the 32/64 bit
>fixes.. I've no idea what FreeBSD does , hence didn't touch their code
>(I've little enough clue how Linux does it, people with a clue sent me
>patches.. :-)...
>
>So yes a handle is now 32-bits on Linux no matter what we run it on..
>
>Dave.
>
>
>
Right, but with the above tweak, it will only be defined as an "int"
if the wordsize is 32. If the wordsize is 64, then the above condition
will be untrue, and it will fall into the "unsigned long" case instead
(which on 64-bit Linux is the correct size).
-Philip
More information about the xorg
mailing list