public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Zidlicky <Richard.Zidlicky@stud.informatik.uni-erlangen.de>
To: Richard Henderson <rth@redhat.com>
Cc: Peter.Barada@motorola.com, gcc@gcc.gnu.org
Subject: Re: ICE building glibc-2.2.5 using m68k-linux gcc-3.1
Date: Sat, 27 Jul 2002 15:18:00 -0000	[thread overview]
Message-ID: <20020727120100.A9275@linux-m68k.org> (raw)
In-Reply-To: <20020725180431.A27259@redhat.com>; from rth@redhat.com on Thu, Jul 25, 2002 at 06:04:31PM -0700

On Thu, Jul 25, 2002 at 06:04:31PM -0700, Richard Henderson wrote:
> On Thu, Jul 25, 2002 at 03:33:20PM -0400, Peter Barada wrote:
> > (gdb) call debug_rtx(set)
> > 
> > (set (strict_low_part (reg:HI 6 %d6))
> >     (reg:HI 30))
> 
> This is wrong.  The argument to STRICT_LOW_PART must always be
> a SUBREG of a REG.

I have tracked it down to following kludge which makes gen_lowpart
return a REG instead of SUBREG ins some cases:

simplify-rtx.c:simplify_subreg:2644
      int final_regno = subreg_hard_regno (gen_rtx_SUBREG (outermode, op, byte),
					   0);

      /* ??? We do allow it if the current REG is not valid for
	 its mode.  This is a kludge to work around how float/complex
	 arguments are passed on 32-bit Sparc and should be fixed.  */
      if (HARD_REGNO_MODE_OK (final_regno, outermode)
	  || ! HARD_REGNO_MODE_OK (REGNO (op), innermode))
	{
	  rtx x = gen_rtx_REG (outermode, final_regno);

	  /* Propagate original regno.  We don't have any way to specify
	     the offset inside orignal regno, so do so only for lowpart.
	     The information is used only by alias analysis that can not
	     grog partial register anyway.  */

	  if (subreg_lowpart_offset (outermode, innermode) == byte)
	    ORIGINAL_REGNO (x) = ORIGINAL_REGNO (op);
	  return x;
	}

This returns REG instead of SUBREG, is this special case still needed?

The backtrace at this point is:
#0  simplify_subreg (outermode=HImode, op=0x400dbd10, innermode=SImode, byte=2)
    at ../../gcc-3.1/gcc/simplify-rtx.c:2653
#1  0x81597c2 in simplify_gen_subreg (outermode=HImode, op=0x400dbd10, 
    innermode=SImode, byte=2) at ../../gcc-3.1/gcc/simplify-rtx.c:2724
#2  0x80b2977 in gen_lowpart_common (mode=HImode, x=0x400dbd10)
    at ../../gcc-3.1/gcc/emit-rtl.c:857
#3  0x80b2cf2 in gen_lowpart (mode=HImode, x=0x400dbd10)
    at ../../gcc-3.1/gcc/emit-rtl.c:1153
#4  0x80f9dc3 in gen_zero_extendhisi2 (operand0=0x400dbd10, 
    operand1=0x400dbdc0) at insn-emit.c:2952
#5  0x8118e4a in emit_unop_insn (icode=454, target=0x400dbd10, op0=0x400dbdc0, 
    code=ZERO_EXTEND) at ../../gcc-3.1/gcc/optabs.c:2682




Richard

      parent reply	other threads:[~2002-07-27 10:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-22 17:22 Peter Barada
2002-07-25 13:32 ` Richard Zidlicky
2002-07-25 15:45   ` Peter Barada
2002-07-26  8:50     ` Richard Henderson
2002-07-26 15:52       ` Richard Zidlicky
2002-07-27 15:18       ` Richard Zidlicky [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020727120100.A9275@linux-m68k.org \
    --to=richard.zidlicky@stud.informatik.uni-erlangen.de \
    --cc=Peter.Barada@motorola.com \
    --cc=gcc@gcc.gnu.org \
    --cc=rth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).