🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #51838

Re: C compiler to use coprocessor capabilities on Sparcs

#51838
From: Casper H.S. Dik
Date: Mon, 22 Mar 1993 11:49
27 lines
1906 bytes
msz@astro.Princeton.EDU (Michal Szymanski) writes:


>Is there a C compiler available in public domain (possibly gcc with some
>options) which could use full capabilities of the coprocessor of 
>SUn Sparcstations. I have found the cc-compiled numerical programs to
>run much slower than their equivalents written in Fortran and compiled
>with "-cg89" or "-fast" option of the "f77". It seems to me that this is
>a matter of the way they use coprocessor.

At this point, Sun's C compiler has floating point performance that
is much better than gcc. I'm not sure what the problem is that you're
having, but it could be that the Fortran compiler is inlining certain
functions (sin, cos, tan) etc, whereas the C compiler does not.
In that case you can try the inline libm templates.

Your guess about ``how they use the Co-processor'' is most certainly
incorrect. On the SPARC platform compilers always generate floating
point instructions because all SPARC platforms support
the same floating point instructions. Most platforms have and use the FPU
for those instructions, but in any case it shouldn't matter which compiler
you're using.

Before you depart on more guess work, I suggest that you compare the
assembler output of both compilers and work from there.

Casper
Technical Details
Message-ID: <1993Mar22.114948.8553@fwi.uva.nl>
Path: arc1-ca.pugleaf.net!sparky!uunet!mcsun!sun4nl!fwi.uva.nl!casper
References: <1993Mar16.111754.12874@Princeton.EDU>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,ec5e906038492113
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1993-03-22 18:34:37 PST
Newsgroups: gnu.gcc.help
Path: arc1-ca.pugleaf.net!sparky!uunet!mcsun!sun4nl!fwi.uva.nl!casper
From: casper@fwi.uva.nl (Casper H.S. Dik)
Subject: Re: C compiler to use coprocessor capabilities on Sparcs
Message-ID: <1993Mar22.114948.8553@fwi.uva.nl>
Sender: news@fwi.uva.nl
Nntp-Posting-Host: adam.fwi.uva.nl
Organization: FWI, University of Amsterdam
References: <1993Mar16.111754.12874@Princeton.EDU>
Date: Mon, 22 Mar 1993 11:49:48 GMT
Lines: 27