[llvm-bugs] [Bug 36192] New: Assertion failed: Ill-formed basic block

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Feb 1 07:00:18 PST 2018


https://bugs.llvm.org/show_bug.cgi?id=36192

            Bug ID: 36192
           Summary: Assertion failed: Ill-formed basic block
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: LLVM Codegen
          Assignee: unassignedclangbugs at nondot.org
          Reporter: trass3r at gmail.com
                CC: llvm-bugs at lists.llvm.org

struct a {
  template <class b> static void ad(b);
};
using ah = int;
template <class d, class ai, class ac> ai e(d, ai f, ac) {
  try {
    for (;; ++f)
      a::ad(f);
  } catch (...) {
  }
  return f;
}
template <class d, class ai, class ac> void g(d h, ai f, ac i) { e(h, f, i); }
int j, k, m;
class o {
public:
  o(o &) try { g(j, 0, k); } catch (...) {
  }
};
class p {
  o c;
};
class {
public:
  p &be(ah);
} l;
p n = l.be(m);


$ clang-cl /c /Z7 /O2 /EHsc test.cpp

Assertion failed: InsertionPt != Parent->end() && "Ill-formed basic block",
file ..\lib\Transforms\Utils\Local.cpp, line 1377

LLVMSymbolizer: error reading file: PDB Error: Unable to load PDB.  Make sure
the file exists and is readable.  Calling loadDataForExe

#6 0x00007ff76da1f888 llvm::insertDebugValuesForPHIs(class llvm::BasicBlock
*,class llvm::SmallVectorImpl<class llvm::PHINode *> &)
transforms\utils\local.cpp:1378:0
#7 0x00007ff76d9fa059 llvm::formLCSSAForInstructions(class
llvm::SmallVectorImpl<class llvm::Instruction *> &,class llvm::DominatorTree
&,class llvm::LoopInfo &) transforms\utils\lcssa.cpp:228:0
#8 0x00007ff76d9f8814 llvm::formLCSSA(class llvm::Loop &,class
llvm::DominatorTree &,class llvm::LoopInfo *,class llvm::ScalarEvolution *)
transforms\utils\lcssa.cpp:324:0
#9 0x00007ff76d9fa3e1 llvm::formLCSSARecursively(class llvm::Loop &,class
llvm::DominatorTree &,class llvm::LoopInfo *,class llvm::ScalarEvolution *)
transforms\utils\lcssa.cpp:348:0
#10 0x00007ff76d9fa301 formLCSSAOnAllLoops transforms\utils\lcssa.cpp:355:0
#11 0x00007ff76d4b657d llvm::FPPassManager::runOnFunction(class llvm::Function
&) ir\legacypassmanager.cpp:1520:0
#12 0x00007ff76d183206 CGPassManager::RunPassOnSCC
analysis\callgraphsccpass.cpp:156:0
#13 0x00007ff76d182f89 CGPassManager::RunAllPassesOnSCC
analysis\callgraphsccpass.cpp:423:0
#14 0x00007ff76d183e69 CGPassManager::runOnModule
analysis\callgraphsccpass.cpp:479:0
#15 0x00007ff76d4b69ef MPPassManager::runOnModule
ir\legacypassmanager.cpp:1597:0
#16 0x00007ff76d4b5dfb llvm::legacy::PassManagerImpl::run(class llvm::Module &)
ir\legacypassmanager.cpp:1701:0
#17 0x00007ff76dbd485e EmitAssemblyHelper::EmitAssembly
codegen\backendutil.cpp:802:0
#18 0x00007ff76dbd63a1 clang::EmitBackendOutput(class clang::DiagnosticsEngine
&,class clang::HeaderSearchOptions const &,class clang::CodeGenOptions const
&,class clang::TargetOptions const &,class clang::LangOptions const &,class
llvm::DataLayout const &,class llvm::Module *,enum clang::BackendAction,class
std::unique_ptr<class llvm::raw_pwrite_stream,struct std::default_delete<class
llvm::raw_pwrite_stream> >) codegen\backendutil.cpp:1184:0
#19 0x00007ff76f4da92d clang::BackendConsumer::HandleTranslationUnit(class
clang::ASTContext &) codegen\codegenaction.cpp:296:0
#20 0x00007ff76e6626b6 clang::ParseAST(class clang::Sema &,bool,bool)

clang version 7.0.0 (trunk 323966) (llvm/trunk 323965)
Target: x86_64-pc-windows-msvc
Thread model: posix

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180201/ef449f9e/attachment.html>


More information about the llvm-bugs mailing list