Bug 109645 - [14 Regression] ICE in instantiate_decl, at cp/pt.cc:27097 since r14-283-g95d4c0d2e6318a
Summary: [14 Regression] ICE in instantiate_decl, at cp/pt.cc:27097 since r14-283-g95d...
Status: RESOLVED DUPLICATE of bug 109658
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 14.0
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-27 09:25 UTC by David Binderman
Modified: 2023-05-05 01:09 UTC (History)
4 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2023-04-28 00:00:00


Attachments
gzipped C++ source code (546.20 KB, application/gzip)
2023-04-27 09:25 UTC, David Binderman
Details
gzipped C++ source code (174.28 KB, application/gzip)
2023-04-27 09:51 UTC, David Binderman
Details
C++ source code (2.30 KB, text/plain)
2023-04-27 19:14 UTC, David Binderman
Details
Further reduced version of David's reproducer (195 bytes, text/plain)
2023-04-28 05:58 UTC, Sam James
Details

Note You need to log in before you can comment on or make changes to this bug.
Description David Binderman 2023-04-27 09:25:20 UTC
Created attachment 54937 [details]
gzipped C++ source code

The attached C++ code, does this with recent gcc trunk:

$ ../results.20230426.asan.ubsan/bin/gcc -c -w -march=znver1 bug910.cc
$ ../results.20230427.asan.ubsan/bin/gcc -c -w -march=znver1 bug910.cc 2>&1 | fgrep internal
/home/dcb36/rpmbuild/BUILD/media-downloader-2.9.0/src/engines/../utils/threads.hpp:55:79: internal compiler error: in instantiate_decl, at cp/pt.cc:27097
$ ../results.20230426.asan.ubsan/bin/gcc -v 2>&1 | fgrep exp
gcc version 14.0.0 20230426 (experimental) (5fce06b868ec0d4f) 
$ ../results.20230427.asan.ubsan/bin/gcc -v 2>&1 | fgrep exp
gcc version 14.0.0 20230427 (experimental) (d94ca762f6e0e4f1) 
$ git log 5fce06b868ec0d4f..d94ca762f6e0e4f1 | grep -c "^commit"
43

I have a reduction running.
Comment 1 David Binderman 2023-04-27 09:51:01 UTC
Created attachment 54938 [details]
gzipped C++ source code

After an hour of reduction, I have the attached file.

C++ code takes a long time to reduce with cvise.
Comment 2 David Binderman 2023-04-27 09:52:37 UTC
Attempting a bisection.
Comment 3 David Binderman 2023-04-27 10:52:18 UTC
(In reply to David Binderman from comment #2)
> Attempting a bisection.

Current range is a8e1551bdb372aa3..d94ca762f6e0e4f1.
Comment 4 David Binderman 2023-04-27 15:38:57 UTC
(In reply to David Binderman from comment #3)
> (In reply to David Binderman from comment #2)
> > Attempting a bisection.
> 
> Current range is a8e1551bdb372aa3..d94ca762f6e0e4f1.

Latest range is d60cbbfaa9a3ad3b..d94ca762f6e0e4f1, which is 6 commits.

Two of those commits are by Jason Merrill and are the only commits
in the C++ area.

Adding Jason for their best advice.
Comment 5 David Binderman 2023-04-27 16:11:32 UTC
This commit 

commit 95d4c0d2e6318aef88ba0bc607dfc1ec6b7a612f
Author: Jason Merrill <jason@redhat.com>
Date:   Thu Mar 16 16:55:39 2023 -0400

    c++: restore instantiate_decl assert

looks to be a hot candidate.
Comment 6 David Binderman 2023-04-27 19:14:58 UTC
Created attachment 54944 [details]
C++ source code

I can't reduce the code beyond this file.
Comment 7 Sam James 2023-04-28 05:58:29 UTC
Created attachment 54949 [details]
Further reduced version of David's reproducer
Comment 8 Martin Liška 2023-05-02 14:11:02 UTC
So started with r14-283-g95d4c0d2e6318a.
Comment 9 Jason Merrill 2023-05-05 01:09:54 UTC
Dup.

*** This bug has been marked as a duplicate of bug 109658 ***