public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Bernd Schmidt <bernds@codesourcery.com>
To: Andrew Pinski <pinskia@gmail.com>
Cc: GCC Mailing List <gcc@gcc.gnu.org>,  Richard Henderson <rth@redhat.com>
Subject: Re: Fwd: C6X fails to build in FSF mainline
Date: Mon, 22 Aug 2011 18:04:00 -0000	[thread overview]
Message-ID: <4E5299AA.2010408@codesourcery.com> (raw)
In-Reply-To: <CA+=Sn1k-SFi_wJ5QgGvEeaZrhgTwiGCAmzi+PoLWJFX2E4ZH=A@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 882 bytes --]

On 08/18/11 03:45, Andrew Pinski wrote:
> Forwarding this to the gcc list.  Also Adding RTH to the CC since he
> helped Bernd to get the dwarf2 parts working correctly.

>  You probably know this already.  The c6x-elf target fails to build
>  libgcc with the current FSF mainline sources:
> 
>  gcc/libgcc2.c: In function ‘__gnu_mulsc3’:
>  gcc/libgcc2.c:1928:1: internal compiler error: in scan_trace, at
> dwarf2cfi.c:2433
>  Please submit a full bug report,

Thanks Richard for fixing this (I've been on vacation).

There are some testsuite failures at -O3 in another part of dwarf2cfi,
which are caused by computed_jump_p returning 0 for the
indirect_jump_shadow pattern. There isn't really a sensible way to
represent this pattern in RTL, but we can take advantage of the fact
that computed_jump_p returns true for constants. I committed the
following patch.


Bernd

[-- Attachment #2: compjmp.diff --]
[-- Type: text/plain, Size: 1047 bytes --]

Index: gcc/ChangeLog
===================================================================
--- gcc/ChangeLog	(revision 177967)
+++ gcc/ChangeLog	(working copy)
@@ -1,3 +1,8 @@
+2011-08-22  Bernd Schmidt  <bernds@codesourcery.com>
+
+	* config/c6x/c6x.md (indirect_jump_shadow): Tweak representation
+	to make computed_jump_p return true.
+
 2011-08-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
 
 	* configure.ac (GCC_PICFLAG_FOR_TARGET): Call it.
Index: gcc/config/c6x/c6x.md
===================================================================
--- gcc/config/c6x/c6x.md	(revision 177952)
+++ gcc/config/c6x/c6x.md	(working copy)
@@ -1427,8 +1427,10 @@ (define_insn "real_ret"
    (set_attr "cross" "y,n")
    (set_attr "dest_regfile" "b")])
 
+;; computed_jump_p returns true if it finds a constant; so use one in the
+;; unspec.
 (define_insn "indirect_jump_shadow"
-  [(set (pc) (unspec [(pc)] UNSPEC_JUMP_SHADOW))]
+  [(set (pc) (unspec [(const_int 1)] UNSPEC_JUMP_SHADOW))]
   ""
   ";; indirect jump occurs"
   [(set_attr "type" "shadow")])

      parent reply	other threads:[~2011-08-22 18:04 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <m3zkj9o8o3.fsf@redhat.com>
2011-08-18  1:46 ` Andrew Pinski
2011-08-18 15:16   ` Richard Henderson
2011-08-18 17:16     ` Richard Henderson
2011-08-22 18:04   ` Bernd Schmidt [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=4E5299AA.2010408@codesourcery.com \
    --to=bernds@codesourcery.com \
    --cc=gcc@gcc.gnu.org \
    --cc=pinskia@gmail.com \
    --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).