🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.bug
Article #2219

Bug in GCC 1.33 on VAX running 4.3 BSD

#2219
From: Michael I. Bushnell
Date: Sat, 04 Feb 1989 00:25
34 lines
1912 bytes
All the following is for a VAX running 4.3 BSD.

When compiling gdb 3.1 with gcc 1.33, I ran into a gcc bug in the file
printcmd.c as follows:

gcc -gg -O -I. -c printcmd.c
gcc: Program cc1 got fatal signal 10.

When tracing this down, I found that cc1 stopped in cse.c inside
equiv_constant().

It seems the code that does equiv-constanting for subreg RTX's assumes
that a SUBREG rtx always has a REG as the first arg.  According to the
internals document, a MEM can occur between the combine pass and the
reload pass.  Cse happens before combine, but I guess the manual was
wrong, as the rtx being equiv-constanted was a SUBREG with first
argument MEM.

I added a check in equiv_constant to not do the equivalencing (it
can't hurt not to) for subregs with first arg non-REG.

I'm not sure if the bug is that someone built one of these funny
SUBREG rtx's too early, or that all the assumptions that the first arg
is a REG were not removed from the code correctly.

Anyway, if RMS (or whoever decides to look into this further) wants,
I'll provide the rtl dumps of the relevant function that caused the
problem to occur.

  Michael I. Bushnell       \     This above all; to thine own self be true
         GIG!                \    And it must follow, as the night the day,
mike@turing.cs..unm.edu      /\   Thou canst not be false to any man.
  Hmmmm..............       /  \  Farewell:  my blessing season this in thee!
Technical Details
Message-ID: <2263@unmvax.unm.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!unmvax!turing.cs.unm.edu!mike

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!unmvax!turing.cs.unm.edu!mike
From: mike@turing.cs.unm.edu (Michael I. Bushnell)
Newsgroups: gnu.gcc.bug
Subject: Bug in GCC 1.33 on VAX running 4.3 BSD
Message-ID: <2263@unmvax.unm.edu>
Date: 4 Feb 89 00:25:46 GMT
Sender: news@unmvax.unm.edu
Reply-To: mike@turing.cs.unm.edu (Michael I. Bushnell)
Organization: University of No Money, Albuquerque, New Mexico
Lines: 34