public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "qianchao9 at huawei dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/94266] New: aarch64:ICE during GIMPLE pass: forwprop
Date: Mon, 23 Mar 2020 03:55:13 +0000	[thread overview]
Message-ID: <bug-94266-4@http.gcc.gnu.org/bugzilla/> (raw)

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94266

            Bug ID: 94266
           Summary: aarch64:ICE during GIMPLE pass: forwprop
           Product: gcc
           Version: 10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: qianchao9 at huawei dot com
  Target Milestone: ---
            Target: aarch64

hello
I find an ICE when testing GCC10.0 on aarch64 with -march=armv8.2-a+sve
-msve-vector-bits=256 -ftree-loop-vectorize -O2:

Simple test case
---
#include <stdarg.h>
#define N 16
int out[N];
int a[2*N] =
{0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31};

/* Outer-loop vectorization.  */
__attribute__ ((noinline)) void 
foo () 
{
  int i, j;
  int res;
  for (i = 0; i < N; i++)
    {
      res = 1000;

      for (j = 0; j < N; j++) 
        res = res - a[i+j];

      out[i] = res;
    }
}

int main ()
{
  foo ();
  return 0;
}
---
GCC version:
gcc version 10.0.1 20200309 (experimental) (GCC)

Runcommand:
gcc new_test.c -march=armv8.2-a+sve -msve-vector-bits=256 -ftree-loop-vectorize
-O2 -S -o new_test.s

Result:
during GIMPLE pass: forwprop
pr_xxx.c: In function ‘foo’:
pr_xxx.c:10:1: internal compiler error: in maybe_canonicalize_mem_ref_addr, at
gimple-fold.c:4899
   10 | foo ()
      | ^~~
0x97dd5b maybe_canonicalize_mem_ref_addr
        ../../gcc/gimple-fold.c:4899
0x988d97 fold_stmt_1
        ../../gcc/gimple-fold.c:4972
0x98cfa3 fold_stmt_inplace(gimple_stmt_iterator*)
        ../../gcc/gimple-fold.c:5328
0xde455f forward_propagate_addr_expr_1
        ../../gcc/tree-ssa-forwprop.c:878
0xde6513 forward_propagate_addr_expr
        ../../gcc/tree-ssa-forwprop.c:998
0xdea427 execute
        ../../gcc/tree-ssa-forwprop.c:2715

             reply	other threads:[~2020-03-23  3:55 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-23  3:55 qianchao9 at huawei dot com [this message]
2020-03-23  7:38 ` [Bug tree-optimization/94266] " rguenth at gcc dot gnu.org
2020-03-23  7:59 ` rguenth at gcc dot gnu.org
2020-03-23  9:36 ` qianchao9 at huawei dot com
2020-03-23  9:39 ` cvs-commit at gcc dot gnu.org
2020-03-23  9:40 ` rguenth at gcc dot gnu.org

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=bug-94266-4@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /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).