[patch, libgfortran] Some more transformational intrinsic speedups

Tobias Schlüter Tobias.Schlueter@physik.uni-muenchen.de
Tue Apr 8 14:30:00 GMT 2008


Dominique Dhumieres wrote:
>> Here's the revised patch, which should fix the issues that Dominique
>> discovered (also the warnings, by casting the pointer to unsigned long
>> int before masking it off).  Regression-tested on i686-pc-linux-gnu.
> ...
>> +#define GFC_UNALIGNED_2(x) (((unsigned long int)(x)) & \
>> +			    (__alignof__(GFC_INTEGER_2) - 1))
> ...
> 
> Although I did not applied the new patch, I wonder if the use of "unsigned 
> long" for pointers is really platform independent (32 vs. 64 bit). Is not 
> there a better choice among the zillion variants of parameters/macros 
> defined at configure time (I tried to find the type of __alignof__(*), but 
> did not succeed)?

Without looking at the details of Thomas' patch I think intptr_t is the 
right type, i.e. an integer type that is defined to always be wide 
enough to contain a pointer.

- Tobi

-- 
Tobias Schlüter
Am Coulombwall 1, Zi. 326
85748 Garching b. München
Tel.: +49/89/289-14139



More information about the Fortran mailing list