<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - ICE in clang::InitializationSequence on invalid code"
   href="https://bugs.llvm.org/show_bug.cgi?id=49910">49910</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>ICE in clang::InitializationSequence on invalid code
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>11.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>C++2a
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>ldalessandro@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>blitzrakete@gmail.com, erik.pilkington@gmail.com, llvm-bugs@lists.llvm.org, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Experienced on Debian with 11.0.1.

/home/ldalessa/cswarm/mrwt/examples/dense.cpp:51:29: error: no matching
function for call to 'vector'
  constexpr ttl::Tensor v = ttl::vector("v");
                            ^~~~~~~~~~~
/home/ldalessa/cswarm/mrwt/include/ttl/Tensor.hpp:104:18: note: candidate
template ignored: couldn't infer template argument 'constant'
  constexpr auto vector(std::string_view id) -> Tensor
                 ^
PLEASE submit a bug report to <a href="https://bugs.llvm.org/">https://bugs.llvm.org/</a> and include the crash
backtrace, preprocessed source, and associated run script.
Stack dump:
0.      Program arguments: /usr/bin/clang++ -DDIM=2 -DFMT_LOCALE -DFMT_SHARED
-DLUA_COMPAT_5_2 -DLUA_USE_LINUX -DMRWT_ENABLE_DEBUG -DMRWT_ENABLE_VERBOSE
-DTTL_TREE_INDEX_CAPACITY=8 -I/home/ldalessa/cswarm/mrwt/include
-I/home/ldalessa/cswarm/mrwt/clang/_deps/fmt-src/include
-I/home/ldalessa/cswarm/mrwt/clang/_deps/ce-src/include
-I/home/ldalessa/cswarm/mrwt/clang/_deps/docopt-src
-I/home/ldalessa/cswarm/mrwt/clang/_deps/lua-src/src -isystem
/usr/include/vtk-9.0 -ferror-limit=4 -fconstexpr-steps=12712420 -g
-fopenmp=libomp -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -std=gnu++20 -o
CMakeFiles/dense.dir/dense.cpp.o -c
/home/ldalessa/cswarm/mrwt/examples/dense.cpp 
1.      <eof> parser at end of file
2.      /home/ldalessa/cswarm/mrwt/examples/dense.cpp:78:5: instantiating
function definition 'run_sedov<2>'
 #0 0x00007f628111ff8f llvm::sys::PrintStackTrace(llvm::raw_ostream&)
(/usr/lib/x86_64-linux-gnu/libLLVM-11.so.1+0xbd0f8f)
 #1 0x00007f628111e2f0 llvm::sys::RunSignalHandlers()
(/usr/lib/x86_64-linux-gnu/libLLVM-11.so.1+0xbcf2f0)
 #2 0x00007f628111f6dd llvm::sys::CleanupOnSignal(unsigned long)
(/usr/lib/x86_64-linux-gnu/libLLVM-11.so.1+0xbd06dd)
 #3 0x00007f6281063dc0 (/usr/lib/x86_64-linux-gnu/libLLVM-11.so.1+0xb14dc0)
 #4 0x00007f62882f8140 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x14140)
 #5 0x00007f62869e2c18 clang::InitializationSequence::Perform(clang::Sema&,
clang::InitializedEntity const&, clang::InitializationKind const&,
llvm::MutableArrayRef<clang::Expr*>, clang::QualType*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1395c18)
 #6 0x00007f62867f3f21 (/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x11a6f21)
 #7 0x00007f62867f3695
clang::Sema::SetCtorInitializers(clang::CXXConstructorDecl*, bool,
llvm::ArrayRef<clang::CXXCtorInitializer*>)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x11a6695)
 #8 0x00007f628681672f
clang::Sema::DefineImplicitDefaultConstructor(clang::SourceLocation,
clang::CXXConstructorDecl*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x11c972f)
 #9 0x00007f62866048cb
clang::Sema::runWithSufficientStackSpace(clang::SourceLocation,
llvm::function_ref<void ()>)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0xfb78cb)
#10 0x00007f62869e8ec4 (/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x139bec4)
#11 0x00007f62869e1184 clang::InitializationSequence::Perform(clang::Sema&,
clang::InitializedEntity const&, clang::InitializationKind const&,
llvm::MutableArrayRef<clang::Expr*>, clang::QualType*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1394184)
#12 0x00007f628674daf2 clang::Sema::ActOnUninitializedDecl(clang::Decl*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1100af2)
#13 0x00007f6286c4e204
clang::Sema::InstantiateVariableInitializer(clang::VarDecl*, clang::VarDecl*,
clang::MultiLevelTemplateArgumentList const&)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1601204)
#14 0x00007f6286c42dc1 clang::Sema::BuildVariableInstantiation(clang::VarDecl*,
clang::VarDecl*, clang::MultiLevelTemplateArgumentList const&,
llvm::SmallVector<clang::Sema::LateInstantiatedAttribute, 16u>*,
clang::DeclContext*, clang::LocalInstantiationScope*, bool,
clang::VarTemplateSpecializationDecl*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x15f5dc1)
#15 0x00007f6286c42641
clang::TemplateDeclInstantiator::VisitVarDecl(clang::VarDecl*, bool,
llvm::ArrayRef<clang::BindingDecl*>*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x15f5641)
#16 0x00007f6286c56c74 (/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1609c74)
#17 0x00007f62866048cb
clang::Sema::runWithSufficientStackSpace(clang::SourceLocation,
llvm::function_ref<void ()>)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0xfb78cb)
#18 0x00007f6286c4f8ab clang::Sema::SubstDecl(clang::Decl*,
clang::DeclContext*, clang::MultiLevelTemplateArgumentList const&)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x16028ab)
#19 0x00007f6286c340ca (/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x15e70ca)
#20 0x00007f6286c2f68e (/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x15e268e)
#21 0x00007f6286c187e1 clang::Sema::SubstStmt(clang::Stmt*,
clang::MultiLevelTemplateArgumentList const&)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x15cb7e1)
#22 0x00007f6286c52090
clang::Sema::InstantiateFunctionDefinition(clang::SourceLocation,
clang::FunctionDecl*, bool, bool, bool)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1605090)
#23 0x00007f6286c54582 clang::Sema::PerformPendingInstantiations(bool)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1607582)
#24 0x00007f6286606055
clang::Sema::ActOnEndOfTranslationUnitFragment(clang::Sema::TUFragmentKind)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0xfb9055)
#25 0x00007f6286606775 clang::Sema::ActOnEndOfTranslationUnit()
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0xfb9775)
#26 0x00007f62860c1bc1
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, bool)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0xa74bc1)
#27 0x00007f62860246ed clang::ParseAST(clang::Sema&, bool, bool)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x9d76ed)
#28 0x00007f62875f00c8 clang::FrontendAction::Execute()
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1fa30c8)
#29 0x00007f62875a6641
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1f59641)
#30 0x00007f6287656200
clang::ExecuteCompilerInvocation(clang::CompilerInstance*)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x2009200)
#31 0x00000000004131bf cc1_main(llvm::ArrayRef<char const*>, char const*,
void*) (/usr/bin/clang+++0x4131bf)
#32 0x00000000004115fe (/usr/bin/clang+++0x4115fe)
#33 0x00007f62872d9732 (/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1c8c732)
#34 0x00007f6281063bcd
llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>)
(/usr/lib/x86_64-linux-gnu/libLLVM-11.so.1+0xb14bcd)
#35 0x00007f62872d8c5f
clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef>
<span class="quote">>, std::__cxx11::basic_string<char, std::char_traits<char>,</span >
std::allocator<char> >*, bool*) const
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1c8bc5f)
#36 0x00007f62872b0a7f
clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&,
clang::driver::Command const*&) const
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1c63a7f)
#37 0x00007f62872b0c27
clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&,
llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) const
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1c63c27)
#38 0x00007f62872c478c
clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&,
llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&)
(/usr/lib/x86_64-linux-gnu/libclang-cpp.so.11+0x1c7778c)
#39 0x00000000004110a3 main (/usr/bin/clang+++0x4110a3)
#40 0x00007f6280083d0a __libc_start_main ./csu/../csu/libc-start.c:308:16
#41 0x000000000040e89a _start (/usr/bin/clang+++0x40e89a)
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
Debian clang version 11.0.1-2
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
clang: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /tmp/dense-feaf8f.cpp
clang: note: diagnostic msg: /tmp/dense-feaf8f.sh
clang: note: diagnostic msg: 

********************</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>