public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed
@ 2023-11-12 14:32 141242068 at smail dot nju.edu.cn
  2023-11-12 14:34 ` [Bug c/112495] " 141242068 at smail dot nju.edu.cn
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: 141242068 at smail dot nju.edu.cn @ 2023-11-12 14:32 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 112495
           Summary: GCC: 14: internal compiler error: verify_gimple failed
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: 141242068 at smail dot nju.edu.cn
  Target Milestone: ---

Compiler Explorer: https://gcc.godbolt.org/z/7sM17Pfbb

When compile this program with `gcc-14 -O1`, gcc ICEs:
```
typedef struct { int v; } T1;
typedef struct { T1 v[32]; } T2;

T1 s;
T1 f1() { return s; }

void f2(__seg_gs T2 *p, int n) {
  for (int i = 0; i < n; ++i) p->v[i] = f1();
}
```

Interestingly, if replacing the call of `f1`() by `s` (manual inline f1), this
crash disappears.

The crash output:
```
<source>: In function 'f2':
<source>:7:6: error: mismatching comparison operand types
    7 | void f2(__seg_gs T2 *p, int n) {
      |      ^~
<address-space-2> struct T2 *
struct T1 *
_22 = p_6(D) >= _21;
<source>:7:6: error: mismatching comparison operand types
<address-space-2> struct T2 *
struct T1 *
_27 = _26 <= &s;
during GIMPLE pass: vect
<source>:7:6: internal compiler error: verify_gimple failed
0x238b15e internal_error(char const*, ...)
        ???:0
0x117b6c9 verify_gimple_in_cfg(function*, bool, bool)
        ???:0
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
Compiler returned: 1
```

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

* [Bug c/112495] GCC: 14: internal compiler error: verify_gimple failed
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
@ 2023-11-12 14:34 ` 141242068 at smail dot nju.edu.cn
  2023-11-12 16:13 ` [Bug tree-optimization/112495] [11/12/13/14 Regression] internal compiler error: verify_gimple failed with named address space (__seg_gs ) pinskia at gcc dot gnu.org
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: 141242068 at smail dot nju.edu.cn @ 2023-11-12 14:34 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #1 from wierton <141242068 at smail dot nju.edu.cn> ---
Correction: It should be -O3.

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

* [Bug tree-optimization/112495] [11/12/13/14 Regression] internal compiler error: verify_gimple failed with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
  2023-11-12 14:34 ` [Bug c/112495] " 141242068 at smail dot nju.edu.cn
@ 2023-11-12 16:13 ` pinskia at gcc dot gnu.org
  2023-11-12 16:16 ` pinskia at gcc dot gnu.org
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2023-11-12 16:13 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |11.5

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

* [Bug tree-optimization/112495] [11/12/13/14 Regression] internal compiler error: verify_gimple failed with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
  2023-11-12 14:34 ` [Bug c/112495] " 141242068 at smail dot nju.edu.cn
  2023-11-12 16:13 ` [Bug tree-optimization/112495] [11/12/13/14 Regression] internal compiler error: verify_gimple failed with named address space (__seg_gs ) pinskia at gcc dot gnu.org
@ 2023-11-12 16:16 ` pinskia at gcc dot gnu.org
  2023-11-13  9:18 ` [Bug tree-optimization/112495] [11/12/13/14 Regression] ICE: verify_gimple failed (after vectorizer) " rguenth at gcc dot gnu.org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2023-11-12 16:16 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2023-11-12
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |NEW

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.

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

* [Bug tree-optimization/112495] [11/12/13/14 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (2 preceding siblings ...)
  2023-11-12 16:16 ` pinskia at gcc dot gnu.org
@ 2023-11-13  9:18 ` rguenth at gcc dot gnu.org
  2023-11-13 14:01 ` cvs-commit at gcc dot gnu.org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-11-13  9:18 UTC (permalink / raw)
  To: gcc-bugs

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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |wrong-code
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |rguenth at gcc dot gnu.org

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
We are creating a runtime alias test between &s and p, which, dependent on
addr_space_subset_p is either not required (address spaces disjunct) or
requires a conversion to the superset.

The defensive fix is to not support runtime alias checks for DRs involving
different address spaces.

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

* [Bug tree-optimization/112495] [11/12/13/14 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (3 preceding siblings ...)
  2023-11-13  9:18 ` [Bug tree-optimization/112495] [11/12/13/14 Regression] ICE: verify_gimple failed (after vectorizer) " rguenth at gcc dot gnu.org
@ 2023-11-13 14:01 ` cvs-commit at gcc dot gnu.org
  2023-11-13 14:10 ` [Bug tree-optimization/112495] [11/12/13 " rguenth at gcc dot gnu.org
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-11-13 14:01 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:0f593c0521caab8cfac53514b1a5e7d0d0dd1932

commit r14-5393-g0f593c0521caab8cfac53514b1a5e7d0d0dd1932
Author: Richard Biener <rguenther@suse.de>
Date:   Mon Nov 13 10:20:37 2023 +0100

    tree-optimization/112495 - alias versioning and address spaces

    We are not correctly handling differing address spaces in dependence
    analysis runtime alias check generation so refuse to do that.

            PR tree-optimization/112495
            * tree-data-ref.cc (runtime_alias_check_p): Reject checks
            between different address spaces.

            * gcc.target/i386/pr112495.c: New testcase.

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

* [Bug tree-optimization/112495] [11/12/13 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (4 preceding siblings ...)
  2023-11-13 14:01 ` cvs-commit at gcc dot gnu.org
@ 2023-11-13 14:10 ` rguenth at gcc dot gnu.org
  2024-02-06 13:20 ` cvs-commit at gcc dot gnu.org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-11-13 14:10 UTC (permalink / raw)
  To: gcc-bugs

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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|needs-bisection             |
           Priority|P3                          |P2
            Summary|[11/12/13/14 Regression]    |[11/12/13 Regression] ICE:
                   |ICE: verify_gimple failed   |verify_gimple failed (after
                   |(after vectorizer) with     |vectorizer) with named
                   |named address space         |address space (__seg_gs )
                   |(__seg_gs )                 |
      Known to work|                            |14.0

--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed on trunk sofar, not sure if worth backporting.

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

* [Bug tree-optimization/112495] [11/12/13 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (5 preceding siblings ...)
  2023-11-13 14:10 ` [Bug tree-optimization/112495] [11/12/13 " rguenth at gcc dot gnu.org
@ 2024-02-06 13:20 ` cvs-commit at gcc dot gnu.org
  2024-05-17 11:12 ` [Bug tree-optimization/112495] [11/12 " cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-02-06 13:20 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-13 branch has been updated by Richard Biener
<rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:e22e3ee80f6b83d1f7a7d92be3c3d3f16e56fa17

commit r13-8289-ge22e3ee80f6b83d1f7a7d92be3c3d3f16e56fa17
Author: Richard Biener <rguenther@suse.de>
Date:   Mon Nov 13 10:20:37 2023 +0100

    tree-optimization/112495 - alias versioning and address spaces

    We are not correctly handling differing address spaces in dependence
    analysis runtime alias check generation so refuse to do that.

            PR tree-optimization/112495
            * tree-data-ref.cc (runtime_alias_check_p): Reject checks
            between different address spaces.

            * gcc.target/i386/pr112495.c: New testcase.

    (cherry picked from commit 0f593c0521caab8cfac53514b1a5e7d0d0dd1932)

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

* [Bug tree-optimization/112495] [11/12 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (6 preceding siblings ...)
  2024-02-06 13:20 ` cvs-commit at gcc dot gnu.org
@ 2024-05-17 11:12 ` cvs-commit at gcc dot gnu.org
  2024-06-21  9:22 ` [Bug tree-optimization/112495] [11 " cvs-commit at gcc dot gnu.org
  2024-06-21  9:37 ` rguenth at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-05-17 11:12 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #7 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Richard Biener
<rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:dbb5273996259b04350a1e3d35e633c51fc9310f

commit r12-10455-gdbb5273996259b04350a1e3d35e633c51fc9310f
Author: Richard Biener <rguenther@suse.de>
Date:   Mon Nov 13 10:20:37 2023 +0100

    tree-optimization/112495 - alias versioning and address spaces

    We are not correctly handling differing address spaces in dependence
    analysis runtime alias check generation so refuse to do that.

            PR tree-optimization/112495
            * tree-data-ref.cc (runtime_alias_check_p): Reject checks
            between different address spaces.

            * gcc.target/i386/pr112495.c: New testcase.

    (cherry picked from commit 0f593c0521caab8cfac53514b1a5e7d0d0dd1932)

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

* [Bug tree-optimization/112495] [11 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (7 preceding siblings ...)
  2024-05-17 11:12 ` [Bug tree-optimization/112495] [11/12 " cvs-commit at gcc dot gnu.org
@ 2024-06-21  9:22 ` cvs-commit at gcc dot gnu.org
  2024-06-21  9:37 ` rguenth at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-06-21  9:22 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #8 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Richard Biener
<rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:20fe647365a922c6dd7a7f283abb99b5588476e8

commit r11-11525-g20fe647365a922c6dd7a7f283abb99b5588476e8
Author: Richard Biener <rguenther@suse.de>
Date:   Mon Nov 13 10:20:37 2023 +0100

    tree-optimization/112495 - alias versioning and address spaces

    We are not correctly handling differing address spaces in dependence
    analysis runtime alias check generation so refuse to do that.

            PR tree-optimization/112495
            * tree-data-ref.c (runtime_alias_check_p): Reject checks
            between different address spaces.

            * gcc.target/i386/pr112495.c: New testcase.

    (cherry picked from commit 0f593c0521caab8cfac53514b1a5e7d0d0dd1932)

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

* [Bug tree-optimization/112495] [11 Regression] ICE: verify_gimple failed (after vectorizer) with named address space (__seg_gs )
  2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
                   ` (8 preceding siblings ...)
  2024-06-21  9:22 ` [Bug tree-optimization/112495] [11 " cvs-commit at gcc dot gnu.org
@ 2024-06-21  9:37 ` rguenth at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-06-21  9:37 UTC (permalink / raw)
  To: gcc-bugs

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

Richard Biener <rguenth at gcc dot gnu.org> changed:

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

--- Comment #9 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed.

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

end of thread, other threads:[~2024-06-21  9:37 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-12 14:32 [Bug c/112495] New: GCC: 14: internal compiler error: verify_gimple failed 141242068 at smail dot nju.edu.cn
2023-11-12 14:34 ` [Bug c/112495] " 141242068 at smail dot nju.edu.cn
2023-11-12 16:13 ` [Bug tree-optimization/112495] [11/12/13/14 Regression] internal compiler error: verify_gimple failed with named address space (__seg_gs ) pinskia at gcc dot gnu.org
2023-11-12 16:16 ` pinskia at gcc dot gnu.org
2023-11-13  9:18 ` [Bug tree-optimization/112495] [11/12/13/14 Regression] ICE: verify_gimple failed (after vectorizer) " rguenth at gcc dot gnu.org
2023-11-13 14:01 ` cvs-commit at gcc dot gnu.org
2023-11-13 14:10 ` [Bug tree-optimization/112495] [11/12/13 " rguenth at gcc dot gnu.org
2024-02-06 13:20 ` cvs-commit at gcc dot gnu.org
2024-05-17 11:12 ` [Bug tree-optimization/112495] [11/12 " cvs-commit at gcc dot gnu.org
2024-06-21  9:22 ` [Bug tree-optimization/112495] [11 " cvs-commit at gcc dot gnu.org
2024-06-21  9:37 ` rguenth 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).