[llvm-bugs] [Bug 42877] New: New PM crash w/ tsan: llvm::Value::assertModuleIsMaterializedImpl() const: Assertion `M->isMaterialized()' failed.
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Aug 2 17:16:27 PDT 2019
https://bugs.llvm.org/show_bug.cgi?id=42877
Bug ID: 42877
Summary: New PM crash w/ tsan:
llvm::Value::assertModuleIsMaterializedImpl() const:
Assertion `M->isMaterialized()' failed.
Product: new-bugs
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
Assignee: leonardchan at google.com
Reporter: rupprecht at google.com
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org
Note: this repro reliably crashes clang, but doesn't always print the same
stack trace. I only get this specific message ~7% of the time.
$ cat repro.c
typedef enum { a } b;
int h;
struct f {
int e;
b c;
};
void static fn1(*d) {
d[1];
for (; 0;)
;
}
void g() {
struct f *x = 0;
switch (x->c)
case a:
fn1(h);
}
int i();
int fn3() {
if (i())
;
}
$ clang \
-cc1 -emit-obj -O3 -w \
-fsanitize=thread -fexperimental-new-pass-manager \
repro.c
Error message:
clang:
/usr/local/google/home/rupprecht/src/llvm-project/llvm/lib/IR/Value.cpp:359:
void llvm::Value::assertModuleIsMaterializedImpl() const: Assertion
`M->isMaterialized()' failed.
Stack dump:
...
#9 0x00007f5d3f164133 llvm::Value::materialized_user_begin()
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/IR/Value.h:391:66
#10 0x00007f5d3f164133 llvm::Value::user_begin()
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/IR/Value.h:397:0
#11 0x00007f5d3f164133 llvm::PredIterator<llvm::BasicBlock,
llvm::Value::user_iterator_impl<llvm::User> >::PredIterator(llvm::BasicBlock*)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/IR/CFG.h:65:0
#12 0x00007f5d3f164133 llvm::pred_begin(llvm::BasicBlock*)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/IR/CFG.h:108:0
#13 0x00007f5d3f164133 llvm::GraphTraits<llvm::Inverse<llvm::BasicBlock*>
>::child_begin(llvm::BasicBlock*)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/IR/CFG.h:327:0
#14 0x00007f5d3f164133
llvm::iterator_range<llvm::GraphTraits<llvm::Inverse<llvm::BasicBlock*>
>::ChildIteratorType> llvm::children<llvm::Inverse<llvm::BasicBlock*>
>(llvm::GraphTraits<llvm::Inverse<llvm::BasicBlock*> >::NodeRef const&)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/ADT/GraphTraits.h:122:0
#15 0x00007f5d3f164133 llvm::LoopInfoBase<llvm::BasicBlock,
llvm::Loop>::analyze(llvm::DominatorTreeBase<llvm::BasicBlock, false> const&)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/Analysis/LoopInfoImpl.h:549:0
#16 0x00007f5d3f16a1d7 llvm::LoopAnalysis::run(llvm::Function&,
llvm::AnalysisManager<llvm::Function>&)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/lib/Analysis/LoopInfo.cpp:924:1
#17 0x00007f5d39d53302
std::enable_if<!(std::is_array<llvm::detail::AnalysisResultModel<llvm::Function,
llvm::LoopAnalysis, llvm::LoopInfo, llvm::PreservedAnalyses,
llvm::AnalysisManager<llvm::Function>::Invalidator, true> >::value),
std::unique_ptr<llvm::detail::AnalysisResultModel<llvm::Function,
llvm::LoopAnalysis, llvm::LoopInfo, llvm::PreservedAnalyses,
llvm::AnalysisManager<llvm::Function>::Invalidator, true>,
std::default_delete<llvm::detail::AnalysisResultModel<llvm::Function,
llvm::LoopAnalysis, llvm::LoopInfo, llvm::PreservedAnalyses,
llvm::AnalysisManager<llvm::Function>::Invalidator, true> > > >::type
llvm::make_unique<llvm::detail::AnalysisResultModel<llvm::Function,
llvm::LoopAnalysis, llvm::LoopInfo, llvm::PreservedAnalyses,
llvm::AnalysisManager<llvm::Function>::Invalidator, true>,
llvm::LoopInfo>(llvm::LoopInfo&&)
/usr/local/google/home/rupprecht/src/llvm-project/llvm/include/llvm/ADT/STLExtras.h:1406:29
--
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/20190803/427f9924/attachment.html>
More information about the llvm-bugs
mailing list