public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/98264] New: ice during linear_loads_p
@ 2020-12-13 21:38 dcb314 at hotmail dot com
  2020-12-13 21:43 ` [Bug middle-end/98264] " dcb314 at hotmail dot com
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 21:38 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 98264
           Summary: ice during linear_loads_p
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dcb314 at hotmail dot com
  Target Milestone: ---

For C testsuite file ./gcc.target/i386/avx-vaddsubpd-1.c

$ /home/dcb/gcc/results.20201213/bin/gcc -c -march=bdver2 -O3
./gcc.target/i386/avx-vaddsubpd-1.c
during GIMPLE pass: slp
In file included from ./gcc.target/i386/sse3-addsubpd.c:13,
                 from ./gcc.target/i386/avx-vaddsubpd-1.c:8:
./gcc.target/i386/avx-check.h: In function ‘do_test’:
./gcc.target/i386/avx-check.h:10:1: internal compiler error: Segmentation fault
   10 | do_test (void)
      | ^~~~~~~
0xcf2e49 crash_signal(int)
        ../../trunk.git/gcc/toplev.c:327
0xfd3f47 vec<unsigned int, va_heap, vl_embed>::operator[](unsigned int)
        ../../trunk.git/gcc/vec.h:890
0xfd3f47 vec<unsigned int, va_heap, vl_ptr>::operator[](unsigned int)
        ../../trunk.git/gcc/vec.h:1461
0xfd3f47 linear_loads_p(hash_map<_slp_tree*, std::pair<_complex_perm_kinds,
vec<unsigned int, va_heap, vl_ptr> >,
simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
_slp_tree*)

The gcc compiler seems fine at hash 97b56dece7413839
and broken at 3cc4e183f12e9626

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
@ 2020-12-13 21:43 ` dcb314 at hotmail dot com
  2020-12-13 21:56 ` dcb314 at hotmail dot com
                   ` (10 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 21:43 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #1 from David Binderman <dcb314 at hotmail dot com> ---
Trying a git bisect now. First step hash
54f75d8fb3f54541e37432329581a362e6aab94e

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
  2020-12-13 21:43 ` [Bug middle-end/98264] " dcb314 at hotmail dot com
@ 2020-12-13 21:56 ` dcb314 at hotmail dot com
  2020-12-13 22:07 ` dcb314 at hotmail dot com
                   ` (9 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 21:56 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from David Binderman <dcb314 at hotmail dot com> ---
Seems ok. Try 1751a78ecafb1d16d4a843dd22e739b8fd1cfede

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
  2020-12-13 21:43 ` [Bug middle-end/98264] " dcb314 at hotmail dot com
  2020-12-13 21:56 ` dcb314 at hotmail dot com
@ 2020-12-13 22:07 ` dcb314 at hotmail dot com
  2020-12-13 22:18 ` dcb314 at hotmail dot com
                   ` (8 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 22:07 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from David Binderman <dcb314 at hotmail dot com> ---
Seems ok. Trying 10bbba9145700e2c.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (2 preceding siblings ...)
  2020-12-13 22:07 ` dcb314 at hotmail dot com
@ 2020-12-13 22:18 ` dcb314 at hotmail dot com
  2020-12-13 22:25 ` dcb314 at hotmail dot com
                   ` (7 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 22:18 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from David Binderman <dcb314 at hotmail dot com> ---
10bbba9145700e2c won't build ;-<

git bisect skip says 3ed472af6bc9f83b7a8ac553b282f659a0bf53f7. Try that.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (3 preceding siblings ...)
  2020-12-13 22:18 ` dcb314 at hotmail dot com
@ 2020-12-13 22:25 ` dcb314 at hotmail dot com
  2020-12-13 22:36 ` dcb314 at hotmail dot com
                   ` (6 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 22:25 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #5 from David Binderman <dcb314 at hotmail dot com> ---
Looks bad. Trying 501f470267445e03

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (4 preceding siblings ...)
  2020-12-13 22:25 ` dcb314 at hotmail dot com
@ 2020-12-13 22:36 ` dcb314 at hotmail dot com
  2020-12-14  8:45 ` tnfchris at gcc dot gnu.org
                   ` (5 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: dcb314 at hotmail dot com @ 2020-12-13 22:36 UTC (permalink / raw)
  To: gcc-bugs

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

David Binderman <dcb314 at hotmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |tamar.christina at arm dot com

--- Comment #6 from David Binderman <dcb314 at hotmail dot com> ---
Looks good. So range is [501f470267445e03..3ed472af6bc9f83b].
Both of those have author  Tamar Christina <tamar.christina@arm.com>
I am no expert at git bisect, so over to Tamar for further advice.

I used a configure line of

./trunk.git/configure --prefix=/home/dcb/gcc/results.$HASH \
        --disable-bootstrap \
        --disable-multilib \
        --disable-werror \
        --with-pkgversion=$HASH \
        --enable-checking=release \
        --enable-languages=c

with

sed 's/-O2/-O0/' < Makefile > Makefile.tmp
diff Makefile Makefile.tmp
mv Makefile.tmp Makefile

Any news of anything faster would be appreciated.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (5 preceding siblings ...)
  2020-12-13 22:36 ` dcb314 at hotmail dot com
@ 2020-12-14  8:45 ` tnfchris at gcc dot gnu.org
  2020-12-14  8:45 ` [Bug middle-end/98264] [11 Regression] " tnfchris at gcc dot gnu.org
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2020-12-14  8:45 UTC (permalink / raw)
  To: gcc-bugs

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

Tamar Christina <tnfchris at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|tamar.christina at arm dot com     |tnfchris at gcc dot gnu.org
   Last reconfirmed|                            |2020-12-14
           Assignee|unassigned at gcc dot gnu.org      |tnfchris at gcc dot gnu.org

--- Comment #7 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
confirmed, testing patch.

Curiously this tests runs with `-O2 -mavx -mfpmath=sse` for me locally which
passes but I can reproduce it using the reported flags.

> Any news of anything faster would be appreciated.

You don't have to rebuild the whole thing at every step just the C compiler
since this is a C test.

So once you build it once you can go into the build dir (since you're doing a
non-bootstrap build) and do `make cc1 -C gcc -j <num>` . Which should take just
seconds.

If you're doing a bootstrapped build you should just build the last stage.

You can then run the testcase using the `xgcc` command you see in the log (you
don't need the install).

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] [11 Regression] ice during linear_loads_p
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (6 preceding siblings ...)
  2020-12-14  8:45 ` tnfchris at gcc dot gnu.org
@ 2020-12-14  8:45 ` tnfchris at gcc dot gnu.org
  2020-12-14  9:14 ` [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b marxin at gcc dot gnu.org
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2020-12-14  8:45 UTC (permalink / raw)
  To: gcc-bugs

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

Tamar Christina <tnfchris at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|unknown                     |11.0
            Summary|ice during linear_loads_p   |[11 Regression] ice during
                   |                            |linear_loads_p
   Target Milestone|---                         |11.0

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (7 preceding siblings ...)
  2020-12-14  8:45 ` [Bug middle-end/98264] [11 Regression] " tnfchris at gcc dot gnu.org
@ 2020-12-14  9:14 ` marxin at gcc dot gnu.org
  2020-12-14  9:24 ` marxin at gcc dot gnu.org
                   ` (2 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: marxin at gcc dot gnu.org @ 2020-12-14  9:14 UTC (permalink / raw)
  To: gcc-bugs

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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P1
            Summary|[11 Regression] ice during  |[11 Regression] ice during
                   |linear_loads_p              |linear_loads_p since
                   |                            |r11-5969-g3ed472af6bc9f83b
     Ever confirmed|0                           |1
                 CC|                            |marxin at gcc dot gnu.org
             Status|UNCONFIRMED                 |NEW

--- Comment #8 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r11-5969-g3ed472af6bc9f83b, it fails due to a Invalid read:

$ valgrind --trace-children=yes gcc
/home/marxin/Programming/gcc/gcc/testsuite/gcc.target/i386/avx-vaddsubpd-1.c -c
-c -march=bdver2 -O3 -c
...
==15595== Invalid read of size 4
==15595==    at 0x109B3DB: operator[] (vec.h:890)
==15595==    by 0x109B3DB: operator[] (vec.h:1461)
==15595==    by 0x109B3DB: linear_loads_p(hash_map<_slp_tree*,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> >,
simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
_slp_tree*) (tree-vect-slp-patterns.c:255)
==15595==    by 0x109B63A: complex_add_pattern::matches(_complex_operation,
hash_map<_slp_tree*, std::pair<_complex_perm_kinds, vec<unsigned int, va_heap,
vl_ptr> >, simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
vec<_slp_tree*, va_heap, vl_ptr>*) (tree-vect-slp-patterns.c:678)
==15595==    by 0x109B6C9: complex_add_pattern::recognize(hash_map<_slp_tree*,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> >,
simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
_slp_tree**) (tree-vect-slp-patterns.c:697)
==15595==    by 0x108FEEC: vect_match_slp_patterns_2(_slp_tree**, vec_info*,
hash_map<_slp_tree*, std::pair<_complex_perm_kinds, vec<unsigned int, va_heap,
vl_ptr> >, simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
hash_set<_slp_tree*, false, default_hash_traits<_slp_tree*> >*)
(tree-vect-slp.c:2257)
==15595==    by 0x108FEB1: vect_match_slp_patterns_2(_slp_tree**, vec_info*,
hash_map<_slp_tree*, std::pair<_complex_perm_kinds, vec<unsigned int, va_heap,
vl_ptr> >, simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
hash_set<_slp_tree*, false, default_hash_traits<_slp_tree*> >*)
(tree-vect-slp.c:2252)
==15595==    by 0x108FEB1: vect_match_slp_patterns_2(_slp_tree**, vec_info*,
hash_map<_slp_tree*, std::pair<_complex_perm_kinds, vec<unsigned int, va_heap,
vl_ptr> >, simple_hashmap_traits<default_hash_traits<_slp_tree*>,
std::pair<_complex_perm_kinds, vec<unsigned int, va_heap, vl_ptr> > > >*,
hash_set<_slp_tree*, false, default_hash_traits<_slp_tree*> >*)
(tree-vect-slp.c:2252)
==15595==    by 0x1090277: vect_match_slp_patterns (tree-vect-slp.c:2290)
==15595==    by 0x1090277: vect_analyze_slp(vec_info*, unsigned int)
(tree-vect-slp.c:2743)
==15595==    by 0x10974B2: vect_slp_analyze_bb_1 (tree-vect-slp.c:4507)
==15595==    by 0x10974B2: vect_slp_region (tree-vect-slp.c:4619)
==15595==    by 0x10974B2: vect_slp_bbs(vec<basic_block_def*, va_heap, vl_ptr>)
(tree-vect-slp.c:4767)
==15595==    by 0x1098F54: vect_slp_function(function*) (tree-vect-slp.c:4853)
==15595==    by 0x109C362: (anonymous
namespace)::pass_slp_vectorize::execute(function*) (tree-vectorizer.c:1449)
==15595==    by 0xD1F357: execute_one_pass(opt_pass*) (passes.c:2567)
==15595==    by 0xD1FCFF: execute_pass_list_1(opt_pass*) (passes.c:2656)
==15595==  Address 0x4 is not stack'd, malloc'd or (recently) free'd
==15595== 
during GIMPLE pass: slp
In file included from
/home/marxin/Programming/gcc/gcc/testsuite/gcc.target/i386/sse3-addsubpd.c:13,
                 from
/home/marxin/Programming/gcc/gcc/testsuite/gcc.target/i386/avx-vaddsubpd-1.c:8:
/home/marxin/Programming/gcc/gcc/testsuite/gcc.target/i386/avx-check.h: In
function ‘do_test’:
/home/marxin/Programming/gcc/gcc/testsuite/gcc.target/i386/avx-check.h:10:1:
internal compiler error: Segmentation fault
   10 | do_test (void)
      | ^~~~~~~
0x4fff151 __libc_start_main
        ???:0

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (8 preceding siblings ...)
  2020-12-14  9:14 ` [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b marxin at gcc dot gnu.org
@ 2020-12-14  9:24 ` marxin at gcc dot gnu.org
  2020-12-14 15:21 ` cvs-commit at gcc dot gnu.org
  2020-12-14 15:22 ` tnfchris at gcc dot gnu.org
  11 siblings, 0 replies; 13+ messages in thread
From: marxin at gcc dot gnu.org @ 2020-12-14  9:24 UTC (permalink / raw)
  To: gcc-bugs

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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Blocks|                            |26163

--- Comment #9 from Martin Liška <marxin at gcc dot gnu.org> ---
Apparently, it's blocking couple of SPEC benchmarks:

-Ofast -march=znver2 -g -flto=128:

warning: 416.gamess(peak; CE) benchmark build failed!
warning: 465.tonto(peak; CE) benchmark build failed!
warning: 483.xalancbmk(peak; CE) benchmark build failed!


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26163
[Bug 26163] [meta-bug] missed optimization in SPEC (2k17, 2k and 2k6 and 95)

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (9 preceding siblings ...)
  2020-12-14  9:24 ` marxin at gcc dot gnu.org
@ 2020-12-14 15:21 ` cvs-commit at gcc dot gnu.org
  2020-12-14 15:22 ` tnfchris at gcc dot gnu.org
  11 siblings, 0 replies; 13+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2020-12-14 15:21 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Tamar Christina <tnfchris@gcc.gnu.org>:

https://gcc.gnu.org/g:159b0bd9ce263dfb791eff5133b0ca0207201c84

commit r11-5993-g159b0bd9ce263dfb791eff5133b0ca0207201c84
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Mon Dec 14 15:20:05 2020 +0000

    middle-end: Exclude TOP permute from blend considerations

    Similarly to UNKNOWN permutes, TOP needs to be excluded from being
considered
    for blends because it produces no permute to check.

    gcc/ChangeLog:

            PR middle-end/98264
            * tree-vect-slp-patterns.c (linear_loads_p): Exclude TOP permute.

    gcc/testsuite/ChangeLog:

            PR middle-end/98264
            * gcc.target/i386/pr98264.c: New test.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b
  2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
                   ` (10 preceding siblings ...)
  2020-12-14 15:21 ` cvs-commit at gcc dot gnu.org
@ 2020-12-14 15:22 ` tnfchris at gcc dot gnu.org
  11 siblings, 0 replies; 13+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2020-12-14 15:22 UTC (permalink / raw)
  To: gcc-bugs

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

Tamar Christina <tnfchris at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #11 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
This should be fixed now.

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2020-12-14 15:22 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-13 21:38 [Bug c/98264] New: ice during linear_loads_p dcb314 at hotmail dot com
2020-12-13 21:43 ` [Bug middle-end/98264] " dcb314 at hotmail dot com
2020-12-13 21:56 ` dcb314 at hotmail dot com
2020-12-13 22:07 ` dcb314 at hotmail dot com
2020-12-13 22:18 ` dcb314 at hotmail dot com
2020-12-13 22:25 ` dcb314 at hotmail dot com
2020-12-13 22:36 ` dcb314 at hotmail dot com
2020-12-14  8:45 ` tnfchris at gcc dot gnu.org
2020-12-14  8:45 ` [Bug middle-end/98264] [11 Regression] " tnfchris at gcc dot gnu.org
2020-12-14  9:14 ` [Bug middle-end/98264] [11 Regression] ice during linear_loads_p since r11-5969-g3ed472af6bc9f83b marxin at gcc dot gnu.org
2020-12-14  9:24 ` marxin at gcc dot gnu.org
2020-12-14 15:21 ` cvs-commit at gcc dot gnu.org
2020-12-14 15:22 ` tnfchris at gcc dot gnu.org

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).