home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / sys / sgi / 13320 < prev    next >
Encoding:
Internet Message Format  |  1992-09-07  |  1.4 KB

  1. Path: sparky!uunet!pmafire!news.dell.com!swrinde!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!ucbvax!cgl!cgl.ucsf.edu!gregc
  2. From: gregc@socrates.ucsf.edu (Greg Couch%CGL)
  3. Newsgroups: comp.sys.sgi
  4. Subject: Re: 3.10 Based C++/Fortran 77
  5. Message-ID: <gregc.715642054@cgl.ucsf.edu>
  6. Date: 4 Sep 92 21:27:34 GMT
  7. References: <32258@adm.brl.mil> <p5aa664@twilight.wpd.sgi.com> <1992Sep2.171736.10178@spatial.com> <pdcguvk@twilight.wpd.sgi.com>
  8. Sender: news@cgl.ucsf.edu (USENET News System)
  9. Organization: UCSF Computer Graphics Lab
  10. Lines: 26
  11.  
  12. wsj@triton.wpd.sgi.com (Bill Johnson) writes:
  13.  
  14. >In general, you'll find the 3.10 compilers to be significantly more reliable
  15. >than the 2.20 compilers.  There is no easy way to run both simultaneously.
  16. >Mixing and matching 2.20 pieces with 3.10 pieces will not work, in general.
  17.  
  18. We have found the 3.10 optimizer (-O, -O2) to be less reliable than the
  19. 2.20 optimizer.  In particular, watch out for loops where the increment is
  20. done somewhere within the loop.  For example (bug already filed with customer
  21. support),
  22.  
  23.     result = 0;
  24.     len = strlen(s);
  25.     while (len > 0)
  26.         if (s[--len] == '*')
  27.             result = 1;
  28.     return result;
  29.  
  30. returns 1 even when the string doesn't have an asterix in it.
  31.  
  32. Unfortunately, we have inherited 10's of thousands of lines of code, that used
  33. to work, with the above idiom scattered everywhere.  And rather than examine
  34. each line, we now compile it -O1 with the consequential slower performance.
  35.  
  36.     - Greg Couch
  37.     gregc@cgl.ucsf.edu
  38.