This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

how to enable vector intrinsic functions in fortran frontend


Hi,

The IBM XL Fortran compiler (XL Fortran V11.1 for Linux) defines vector 
data types ( 
http://publib.boulder.ibm.com/infocenter/lnxpcomp/v9v111/topic/com.ibm.xlf111.linux.doc/xlflr/vectordatatype.htm#vectordatatype 
), in order to enable PowerPC VMX intrinsic procedures in Fortran 
(http://publib.boulder.ibm.com/infocenter/lnxpcomp/v9v111/topic/com.ibm.xlf111.linux.doc/xlflr/vmxintrinsics.htm#vmxintrinsics). 
We are now going to port the same feature to gfortran. In addition we 
would like to enable the vector intrinsics on SPU too. But there are still 
a couple of questions need to be clarified.

Since PowerPC Vector type can be composed of different scalar types, some 
of which, like pixel type doesn't exist in Fortran. XLF defines pixel type 
in compiler frontend, but restricts its usage only as part of a vector 
type. Our proposal is to have a facility in Fortran frontend to add 
backend-specific data types, and construct vector and it's special scalar 
types/kinds in PowerPC/SPU backend. Does this sound reasonable?

As to the intrinsic functions, the target specific builtin functions (e.g. 
__builtin_altivec_...) have been initialized in 
gfc_init_builtin_functions. The question is how could these functions be 
mapped to Fortran frontend, with names recognizable by the fortran 
program?

Any opinion on this will be appreciated... 

Thanks!
Sa


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]