From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111c93,1177a02b35e507b5 X-Google-Attributes: gid111c93,public From: "C.Simmendinger" Subject: Re: gcc/egcs C optimization Date: 1998/11/06 Message-ID: <3642E8D8.6ED1849F@theo1.physik.uni-stuttgart.de>#1/1 X-Deja-AN: 409004583 Content-Transfer-Encoding: 7bit References: <363F3118.7A28BB64@nist.gov> <3640478F.4F2C8020@theo.physik.uni-stuttgart.de> <71t89b$221$5@newnews.nl.uu.net> Content-Type: text/plain; charset=us-ascii Organization: InterNetNews at News.BelWue.DE (Stuttgart, Germany) Mime-Version: 1.0 Reply-To: chrisi@theo1.physik.uni-stuttgart.de Newsgroups: comp.os.linux.alpha Toon Moene wrote: > "C.Simmendinger" wrote: > > The cause is not exactly known - it is related to the way complex numbers are > treated in the "middle-end" of the compiler, i.e. as a (real, imag) pair. On > 64-bit hosts (Alpha, MIPS-4000 and higher, UltraSPARC, etc.) a COMPLEX number > is a 2x32 bits entity, which (for optimisation purposes) sometimes is treated > as a single 64 bit quantity. When storing/retrieving this from memory that's > not a problem - however, when trying to stuff a COMPLEX number in a 64 bit > register, you're asking for trouble. > > The corollary of this is that for DOUBLE COMPLEX, this shouldn't be an issue. > Unfortunately, although I haven't seen evidence of the contrary, I cannot > proof this. > Thx ! Sounds reasonable. Moreover it seems to work ;-) Haven't tested performance yet, but will do so. Uhm, btw. ... I have a *request* concerning egcs. Think i'm speaking for a vast majority. Most fortran code these days is used on fast numbercrunchers i.e. alpha and above (cray, nec, whatever) (one reason for fortran is that it can be easily vectorized) Now to my request/suggestion: The compilers on those machines all are able to convert single-> double and the same for complex with some compiler flag. Unfortunately egcs lacks this ? Of coz you might argue that i'm just a lazy boy, but if you are dealing with some 10k lines of fortran code this becomes real work, since you also need to change constants plus all conversions kind=1->kind=2 ... This flag might then also turn off -femulate-complex ? Uhm, btw, this is just something on the wishlist ;-) Christian