🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #53299

Serious GCC 2.0 bugs

#53299
From: Richard Kenner
Date: Wed, 26 Feb 1992 01:32
45 lines
2056 bytes
We have recently been made aware of two serious GCC 2.0 bugs.  The
first causes comparison failures when bootstrapping on the Sparc
(usually in cccp.o).  This bug was caused by a missed optimization
that very rarely was not missed.  Whether it was missed or not
depended on the address of something.  The stage1 and stage2 compilers
differered on whether they did the optimization or not.  This bug does
not cause any incorrect code to be generated or the compiler to abort, but
will cause bootstrap failures.  The patch to cse.c below fixes
this problem.

There is another bug that can cause the compiler to get a SIGSEGV when
compiling an empty function.  The fix to global-alloc.c below corrects
that problem.

*** cse.c.feb26	Wed Feb 26 05:42:03 1992
--- cse.c	Wed Feb 26 05:46:18 1992
*************** fold_rtx (x, insn)
*** 4734,4737 ****
--- 4734,4745 ----
        break;
  
+     case 'o':
+       /* (lo_sum (high X) X) is simply X.  */
+       if (code == LO_SUM && const_arg0 != 0
+ 	  && GET_CODE (const_arg0) == HIGH
+ 	  && rtx_equal_p (XEXP (const_arg0, 0), const_arg1))
+ 	return const_arg1;
+       break;
+ 
      case '3':
*** global-alloc.c.old	Mon Feb 17 21:16:59 1992
--- global-alloc.c	Tue Feb 25 21:43:17 1992
*************** global_alloc (file)
*** 543,547 ****
    if (n_basic_blocks > 0)
  #endif
!     reload (basic_block_head[0], 1, file);
  }
  
--- 543,547 ----
    if (n_basic_blocks > 0)
  #endif
!     reload (get_insns (), 1, file);
  }
  
Technical Details
Message-ID: <9202261132.AA11776@vlsi1.ultra.nyu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!vlsi1.ultra.nyu.edu!kenner

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,474cd29e423bce05,start
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1992-02-26 04:16:35 PST
Newsgroups: gnu.gcc.help
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!vlsi1.ultra.nyu.edu!kenner
From: kenner@vlsi1.ultra.nyu.edu (Richard Kenner)
Subject: Serious GCC 2.0 bugs
Message-ID: <9202261132.AA11776@vlsi1.ultra.nyu.edu>
Sender: daemon@cis.ohio-state.edu
Organization: GNUs Not Usenet
Distribution: gnu
Date: Wed, 26 Feb 1992 01:32:46 GMT
Lines: 45