jv@mhres.mh.nl (Johan Vromans) (07/20/88)
=== THIS IS NOT A BUG IN A SOURCE === ... but I ran into a serious bug in the HP9000 C-compiler on HP9000/320 running HP-UX 5.3 when I tried to get perl 2.0 running. It seems that this version of the C-compiler does not handle the following construct correctly: (double) (d_var1 rel-op d_var2) whre rel-op is one of ==, !=, <, >, <= or >= . Either compiler errors or stack corruption can occur. I posted a more explanative article in comp.sys.hp, and sent perl modifications to Larry Wall. -- Johan
allbery@ncoast.UUCP (Brandon S. Allbery) (08/02/88)
As quoted from <2105@mhres.mh.nl> by jv@mhres.mh.nl (Johan Vromans): +--------------- | === THIS IS NOT A BUG IN A SOURCE === | | ... but I ran into a serious bug in the HP9000 C-compiler on HP9000/320 | running HP-UX 5.3 when I tried to get perl 2.0 running. | | It seems that this version of the C-compiler does not handle the following | construct correctly: | | (double) (d_var1 rel-op d_var2) | | whre rel-op is one of ==, !=, <, >, <= or >= . +--------------- Gee, that sounds familiar! Plexus Sys3 3.31 cc has either the same or a very similar bug. (To be specific, our cc seems to act as if == != < > >= <= && || ! returned some kind of special type which is automatically promoted to (int) if necessary, but never to (double) or any other type; and the "if" and "while" statements not only expect this type, but they also only cast from (int) properly if the value is 0 or 1! (Talk about screwy compilers! That last bit causes a number of programs to flatly refuse to work, although they compile fine.) Does Plexus System V cc have that bug fixed, or should we contemplate something else for ncoast? ++Brandon -- Brandon S. Allbery, uunet!marque!ncoast!allbery DELPHI: ALLBERY For comp.sources.misc send mail to ncoast!sources-misc
wunder@hp-sde.SDE.HP.COM (Walter Underwood) (08/03/88)
... but I ran into a serious bug in the HP9000 C-compiler on HP9000/320 running HP-UX 5.3 when I tried to get perl 2.0 running. Note that 5.3 is not even close to the current release. HP-UX 6.2 is out the door, or on its way out the door, or something. 5.3 was released in the spring of 1987, I think. We've done a *lot* of work on the compilers since then. People inside HP seem to have had no problem compiling Perl 2.0. Most of us are on 6.0 or 6.2. wunder
syd@dsinc.UUCP (Syd Weinstein) (08/03/88)
In article <12082@ncoast.UUCP> allbery@ncoast.UUCP (Brandon S. Allbery) writes:
:As quoted from <2105@mhres.mh.nl> by jv@mhres.mh.nl (Johan Vromans):
:| It seems that this version of the C-compiler does not handle the following
:| construct correctly:
:|
:| (double) (d_var1 rel-op d_var2)
:|
:| whre rel-op is one of ==, !=, <, >, <= or >= .
:+---------------
:
:Gee, that sounds familiar! Plexus Sys3 3.31 cc has either the same or a
:very similar bug. (To be specific, our cc seems to act as if == != < > >=
:<= && || ! returned some kind of special type which is automatically
:promoted to (int) if necessary, but never to (double) or any other type;
:and the "if" and "while" statements not only expect this type, but they also
:only cast from (int) properly if the value is 0 or 1! (Talk about screwy
:compilers!
:Does Plexus System V cc have that bug fixed, or should we contemplate
:something else for ncoast?
Perl works fine on Plexus System V, as we run it here. I guess they
fixed that problem. Actually, Plexus didnt write their own compiler,
but used the portable C compiler from AT&T. The Sys3 and Sys5 compilers
are very different. Also, green hills C does fine on Perl.
--
=====================================================================
Sydney S. Weinstein, CDP, CCP
Datacomp Systems, Inc. Voice: (215) 947-9900
{allegra,bellcore,bpa,vu-vlsi}!dsinc!syd FAX: (215) 938-0235