* Re: performance / f2c bug
[not found] <199606142246.PAA00752@koala.azstarnet.com>
@ 1996-06-15 16:50 ` Harald Koenig
0 siblings, 0 replies; 2+ messages in thread
From: Harald Koenig @ 1996-06-15 16:50 UTC (permalink / raw)
> Did you use "cc -std1"? Otherwise, you get tons of float->double and vice
> versa converstions.
of course I did not. I just browsed the man page for "-std1" but couldn't
find any pointer to this behaviour. anyway, this makes a big differece
giving the same performace with DEC-cc (using f2c) now like with DEC-f77:
f77 1030.31user 2.09system 17:14.05elapsed 99%CPU
f90 1113.64user 2.24system 18:37.76elapsed 99%CPU
cc 1318.54user 6.93system 22:07.94elapsed 99%CPU
gcc 1548.95user 8.06system 25:57.20elapsed 99%CPU
cc -std1 1090.82user 6.01system 18:17.73elapsed 99%CPU
where is this switch for gcc?
Harald
--
All SCSI disks will from now on ___ _____
be required to send an email notice 0--,| /OOOOOOO\
24 hours prior to complete hardware failure! <_/ / /OOOOOOOOOOO\
\ \/OOOOOOOOOOOOOOO\
\ OOOOOOOOOOOOOOOOO|//
Harald Koenig, \/\/\/\/\/\/\/\/\/
Inst.f.Theoret.Astrophysik // / \\ \
koenig@tat.physik.uni-tuebingen.de ^^^^^ ^^^^^
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: performance / f2c bug
@ 1996-06-15 23:33 David Mosberger-Tang
0 siblings, 0 replies; 2+ messages in thread
From: David Mosberger-Tang @ 1996-06-15 23:33 UTC (permalink / raw)
>>>>> On Sat, 15 Jun 1996 18:50:52 +0200 (MET DST), koenig@tat.physik.uni-tuebingen.de (Harald Koenig) said:
>> Did you use "cc -std1"? Otherwise, you get tons of float->double
>> and vice versa converstions.
Harald> of course I did not. I just browsed the man page for
Harald> "-std1" but couldn't find any pointer to this
Harald> behaviour. anyway, this makes a big differece giving the
Harald> same performace with DEC-cc (using f2c) now like with
Harald> DEC-f77:
Harald> where is this switch for gcc?
gcc has the inverse switch: -traditional. gcc by default operates in
ANSI mode, cc in K&R mode. Back in the old days (umh, is it really
_that_ long?? ;-), C folks where to lazy to declare prototypes. As a
result, the compilers had to be conservative and always pass arguments
in the widest possible form (floats as doubles, char, short, and int
as long). Similarly, all expression evaluation was done in the widest
type (long & double, again). In other words, "float" used to make
sense only for the purpose of saving memory.
Maybe DEC can be convinced that the time has come to make -std1 the
default?
In case of doubt, objdump -S will tell it all... ;-)
--david
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1996-06-15 23:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-06-15 23:33 performance / f2c bug David Mosberger-Tang
[not found] <199606142246.PAA00752@koala.azstarnet.com>
1996-06-15 16:50 ` Harald Koenig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox