Article View: gnu.gcc.bug
Article #2767gcc -O bug under NeXT 1.0 compiling rn PL 40
From: Eric P. Scott
Date: Fri, 15 Dec 1989 21:34
Date: Fri, 15 Dec 1989 21:34
44 lines
1954 bytes
1954 bytes
I'm copying this here "for the record" at the request of a
comp.sys.next reader. The problem occurs with the gcc
distributed with NeXT Software Release 1.0. No applicability to
the current FSF version is inferred.
-=EPS=-
-------
From: eps@toaster.SFSU.EDU (Eric P. Scott)
Newsgroups: comp.sys.next
Subject: % interp buffer overflow when compiling rn PL 40 under 1.0 a gcc bug
Summary: Compile intrp.c separately with cc -c -bsd (no -O)
Message-ID: <192@toaster.SFSU.EDU>
Date: 15 Dec 89 14:45:52 GMT
Reply-To: eps@cs.SFSU.EDU (Eric P. Scott)
Organization: San Francisco State University
Lines: 27
When this machine was upgraded from 0.9 to 1.0 we recompiled all
the local software. rn patchlevel 40 started generating
"% interp buffer overflow!" aborts when attempting to follow up
to articles. The problem has been traced to the gcc optimizer:
*** intrp.c Fri Nov 21 14:26:45 1986
834 i = metabit; /* maybe get into register */
835 if (s == dest) {
836 while (*dest) {
837 if (--destsize <= 0)
838 abort_interp();
839 *dest++ |= i;
^^ this increment lost in optimization
840 }
841 }
842 else {
843 while (*s) {
844 if (--destsize <= 0)
845 abort_interp();
846 *dest++ = *s++ | i;
847 }
848 }
Compiling intrp.c without -O "works" ok.
-=EPS=-
Technical Details
Message-ID:
<193@toaster.SFSU.EDU>Path:
arc1-ca.pugleaf.net!utzoo!telly!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!ucsd!ucbvax!ziploc!epsReferences:
<192@toaster.SFSU.EDU>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!telly!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!ucsd!ucbvax!ziploc!eps From: eps@toaster.SFSU.EDU (Eric P. Scott) Newsgroups: gnu.gcc.bug Subject: gcc -O bug under NeXT 1.0 compiling rn PL 40 Summary: originally posted to comp.sys.next, here by request Message-ID: <193@toaster.SFSU.EDU> Date: 15 Dec 89 21:34:28 GMT References: <192@toaster.SFSU.EDU> Reply-To: eps@cs.SFSU.EDU (Eric P. Scott) Followup-To: comp.sys.next Organization: San Francisco State University Lines: 44