[llvm-bugs] [Bug 35864] New: After r320749, Assertion failed: (ScaledReg == nullptr), function SetCombinedField, file lib/CodeGen/CodeGenPrepare.cpp, line 1980.
via llvm-bugs
llvm-bugs at lists.llvm.org
Mon Jan 8 13:51:27 PST 2018
https://bugs.llvm.org/show_bug.cgi?id=35864
Bug ID: 35864
Summary: After r320749, Assertion failed: (ScaledReg ==
nullptr), function SetCombinedField, file
lib/CodeGen/CodeGenPrepare.cpp, line 1980.
Product: new-bugs
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
Assignee: unassignedbugs at nondot.org
Reporter: dimitry at andric.com
CC: llvm-bugs at lists.llvm.org
This bug is different from bug 35805 and bug 35799. As reported in
https://bugs.freebsd.org/224995, clang 6.0.0 (trunk r321545) asserts on
compiling imap/src/imapd/imapd.c of the alpine port:
(gdb) bt
#0 thr_kill () at thr_kill.S:3
#1 0x000000080347b084 in __raise (s=6) at /usr/src/lib/libc/gen/raise.c:54
#2 0x000000080347aff9 in abort () at /usr/src/lib/libc/stdlib/abort.c:67
#3 0x00000008034f8431 in __assert (func=<optimized out>, file=<optimized out>,
line=<optimized out>, failedexpr=<optimized out>) at
/usr/src/lib/libc/gen/assert.c:53
#4 0x000000000114631b in (anonymous
namespace)::CodeGenPrepare::optimizeMemoryInst(llvm::Instruction*,
llvm::Value*, llvm::Type*, unsigned int) ()
#5 0x000000000113cb5c in (anonymous
namespace)::CodeGenPrepare::optimizeInst(llvm::Instruction*, bool&) ()
#6 0x0000000001136177 in (anonymous
namespace)::CodeGenPrepare::runOnFunction(llvm::Function&) ()
#7 0x000000000152ea9a in llvm::FPPassManager::runOnFunction(llvm::Function&)
()
#8 0x000000000152ed03 in llvm::FPPassManager::runOnModule(llvm::Module&) ()
#9 0x000000000152f27b in llvm::legacy::PassManagerImpl::run(llvm::Module&) ()
#10 0x0000000001ba6f33 in clang::EmitBackendOutput(clang::DiagnosticsEngine&,
clang::HeaderSearchOptions const&, clang::CodeGenOptions const&,
clang::TargetOptions const&, clang::LangOptions const&, llvm::DataLayout
const&, llvm::Module*, clang::BackendAction,
std::__1::unique_ptr<llvm::raw_pwrite_stream,
std::__1::default_delete<llvm::raw_pwrite_stream> >) ()
#11 0x0000000002118868 in
clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&) ()
#12 0x0000000002599af2 in clang::ParseAST(clang::Sema&, bool, bool) ()
#13 0x000000000208b68c in clang::FrontendAction::Execute() ()
#14 0x000000000201d0c1 in
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) ()
#15 0x0000000002112cee in
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) ()
#16 0x0000000000d76c95 in cc1_main(llvm::ArrayRef<char const*>, char const*,
void*) ()
#17 0x0000000000d74d9e in main ()
The test case minimizes to:
/* clang -cc1 -triple i386 -S -O2 -vectorize-loops -vectorize-slp
imapd-minimized.c */
char c[0];
enum { d, f } e;
int i();
void m();
void n() {
char j, a, *g, b[0];
int l = i(), k = l;
g = b;
char *h = "PID=";
while (*h)
*g++ = *h++;
h = c;
do
h++;
while (k);
while (h > c)
*g++ = *--h;
switch (e)
case 0: {
h = " in";
while (*h)
*g++ = *h++;
a = 0;
break;
case 1:
h = " in";
while (*h)
*g++ = *h++;
j = 0;
}
m(g - b);
}
As opposed to bug 35805 and bug 35799, which regressed with
https://reviews.llvm.org/rL319302 ("[CGP] Enable complex addr mode"), this
particular bug regressed with https://reviews.llvm.org/rL320749 ("[SimplifyCFG]
don't sink common insts too soon (PR34603)"), which is apparently a fix for bug
34603.
--
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/20180108/cc2e5b72/attachment-0001.html>
More information about the llvm-bugs
mailing list