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

            Bug ID: 116496
           Summary: [modules] ICE in find_dependencies
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, needs-reduction
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: nshead at gcc dot gnu.org
            Blocks: 99227, 103524
  Target Milestone: ---

Modularising the following pair of headers results in an ICE in
find_dependencies, caused by no dependencies having been created for a
specialisation in DECL_TEMPLATE_SPECIALIZATIONS:

g++-15 -std=c++23 -fmodules-ts -xc++-system-header tuple
g++-15 -std=c++23 -fmodules-ts -xc++-system-header functional

/home/wreien/.local/include/c++/15.0.0/functional: internal compiler error:
Segmentation fault
0x3a5c018 internal_error(char const*, ...)
        ../../gcc/gcc/diagnostic-global-context.cc:492
0x1c18c34 crash_signal
        ../../gcc/gcc/toplev.cc:321
0x7f153dc4151f ???
        ./signal/../sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c:0
0x109b254 bool depset::get_flag_bit<0u>() const
        ../../gcc/gcc/cp/module.cc:2387
0x109980d depset::is_binding() const
        ../../gcc/gcc/cp/module.cc:2393
0x109982f depset::get_entity_kind() const
        ../../gcc/gcc/cp/module.cc:2397
0x1080bde operator()
        ../../gcc/gcc/cp/module.cc:13749
0x108141c depset::hash::find_dependencies(module_state*)
        ../../gcc/gcc/cp/module.cc:13767
0x108f9b4 module_state::write_begin(elf_out*, cpp_reader*,
module_state_config&, unsigned int&)
        ../../gcc/gcc/cp/module.cc:18395
0x10974cb finish_module_processing(cpp_reader*)
        ../../gcc/gcc/cp/module.cc:20882
0xfbb98a c_parse_final_cleanups()
        ../../gcc/gcc/cp/decl2.cc:5539
0x1384246 c_common_parse_file()
        ../../gcc/gcc/c-family/c-opts.cc:1333
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.


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99227
[Bug 99227] [meta-bug] [modules] Bugs relating to header-units of STL header
files
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103524
[Bug 103524] [meta-bug] modules issue

Reply via email to