[LLVMbugs] [Bug 15805] New: lib/Transforms/Scalar/SROA.cpp:3058: Assertion `SI.getFalseValue() != OldPtr && "Pointer is both operands!"' failed

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sun Apr 21 09:57:35 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=15805

            Bug ID: 15805
           Summary: lib/Transforms/Scalar/SROA.cpp:3058: Assertion
                    `SI.getFalseValue() != OldPtr && "Pointer is both
                    operands!"' failed
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: antoine.balestrat at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Using LLVM/Clang as of 179981 :

$ cat point.c
int a, b;

void f(void)
{
    while(1);
}

void g(void)
{
    long c, *p = 0;

    f();

    while(c++)
        p = &c;

    b && (p = &c);
    a = a ? c : *p;
}

$ clong -O1 -w point.c
clang: /home/merkil/clang/llvm/lib/Transforms/Scalar/SROA.cpp:3058: bool
{anonymous}::AllocaPartitionRewriter::visitSelectInst(llvm::SelectInst&):
Assertion `SI.getFalseValue() != OldPtr && "Pointer is both operands!"' failed.
0  clang           0x0000000001d63352 llvm::sys::PrintStackTrace(_IO_FILE*) +
34
1  clang           0x0000000001d63071
2  libpthread.so.0 0x00007fad9a565030
3  libc.so.6       0x00007fad99653475 gsignal + 53
4  libc.so.6       0x00007fad996566f0 abort + 384
5  libc.so.6       0x00007fad9964c621 __assert_fail + 241
6  clang           0x00000000019c17aa
7  clang           0x00000000019c950a
8  clang           0x00000000019ca1a1
9  clang           0x00000000019ca6a5
10 clang           0x00000000019cd349
11 clang           0x00000000019cd546
12 clang           0x0000000001cfd61f
llvm::FPPassManager::runOnFunction(llvm::Function&) + 655
13 clang           0x0000000001abad16
14 clang           0x0000000001cfd147
llvm::MPPassManager::runOnModule(llvm::Module&) + 663
15 clang           0x0000000001cfd2ef llvm::PassManagerImpl::run(llvm::Module&)
+ 207
16 clang           0x00000000008f6372
clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::CodeGenOptions
const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::Module*,
clang::BackendAction, llvm::raw_ostream*) + 3458
17 clang           0x00000000008f3fef
18 clang           0x0000000000a572ba clang::ParseAST(clang::Sema&, bool, bool)
+ 538
19 clang           0x00000000008f277e clang::CodeGenAction::ExecuteAction() +
78
20 clang           0x000000000077b989 clang::FrontendAction::Execute() + 265
21 clang           0x000000000075deea
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 346
22 clang           0x0000000000745b12
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1794
23 clang           0x000000000073fe18 cc1_main(char const**, char const**, char
const*, void*) + 920
24 clang           0x0000000000733590 main + 7744
25 libc.so.6       0x00007fad9963fead __libc_start_main + 253
26 clang           0x000000000073f8d1
Stack dump:
0.    Program arguments: /home/merkil/clang/build/Release+Asserts/bin/clang
-cc1 -triple x86_64-unknown-linux-gnu -emit-obj -disable-free -main-file-name
point.c -mrelocation-model static -fmath-errno -masm-verbose
-mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu x86-64
-target-linker-version 2.22 -momit-leaf-frame-pointer -resource-dir
/home/merkil/clang/build/Release+Asserts/bin/../lib/clang/3.3 -internal-isystem
/usr/local/include -internal-isystem
/home/merkil/clang/build/Release+Asserts/bin/../lib/clang/3.3/include
-internal-externc-isystem /usr/include/x86_64-linux-gnu
-internal-externc-isystem /include -internal-externc-isystem /usr/include -O1
-w -fdebug-compilation-dir /home/merkil/creduce/creduce -ferror-limit 19
-fmessage-length 0 -mstackrealign -fobjc-runtime=gcc
-fobjc-default-synthesize-properties -fdiagnostics-show-option -backend-option
-vectorize-loops -o /tmp/point-DEY8DY.o -x c point.c 
1.    <eof> parser at end of file
2.    Per-module optimization passes
3.    Running pass 'CallGraph Pass Manager' on module 'point.c'.
4.    Running pass 'SROA' on function '@g'
clang: error: unable to execute command: Aborted
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
clang version 3.3 (trunk 179981)
Target: x86_64-unknown-linux-gnu
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/20130421/a60e3046/attachment.html>


More information about the llvm-bugs mailing list