[llvm-bugs] [Bug 35802] New: opt crashes with "opt -instcombine -early-cse-memssa -licm -loop-rotate -loop-vectorize -newgvn -simplifycfg -loop-reroll": Assertion `isSCEVable(V->getType()) && "Value is not SCEVable!"' failed

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Jan 2 16:07:01 PST 2018


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

            Bug ID: 35802
           Summary: opt crashes with "opt -instcombine -early-cse-memssa
                    -licm -loop-rotate -loop-vectorize -newgvn
                    -simplifycfg -loop-reroll": Assertion
                    `isSCEVable(V->getType()) && "Value is not SCEVable!"'
                    failed
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Scalar Optimizations
          Assignee: unassignedbugs at nondot.org
          Reporter: su at cs.ucdavis.edu
                CC: llvm-bugs at lists.llvm.org

Tested with trunk revision 321659. 

$ clangpolly -v
clang version 6.0.0 (http://llvm.org/git/clang.git
d9551a3cb4a454e0818e345bdba510e1cb6dbbdd) (llvm/trunk 321641)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /home/su/bin
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/4.9
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/4.9.4
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5.3.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.4
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.4.7
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.6.4
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.7
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.7.3
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8.5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.9
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.9.4
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.3.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.2.0
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.9
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Candidate multilib: x32;@mx32
Selected multilib: .;@m64
$ 
$ clangpolly -O3 -mllvm -disable-llvm-optzns -c -emit-llvm -o small.bc small.c
$ optpolly -instcombine -early-cse-memssa -licm -loop-rotate -loop-vectorize
-newgvn -simplifycfg -loop-reroll -o small-opt.bc small.bc
optpolly:
/home/su/software/tmp/polly/llvm/lib/Analysis/ScalarEvolution.cpp:3780: const
llvm::SCEV* llvm::ScalarEvolution::getSCEV(llvm::Value*): Assertion
`isSCEVable(V->getType()) && "Value is not SCEVable!"' failed.
LLVMSymbolizer: error reading file: No such file or directory
#0 0x000000000205d92a (optpolly+0x205d92a)
#1 0x000000000205bade (optpolly+0x205bade)
#2 0x000000000205bc40 (optpolly+0x205bc40)
#3 0x00007f272a674330 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x10330)
#4 0x00007f272945cc37 gsignal
/build/eglibc-SvCtMH/eglibc-2.19/signal/../nptl/sysdeps/unix/sysv/linux/raise.c:56:0
#5 0x00007f2729460028 abort
/build/eglibc-SvCtMH/eglibc-2.19/stdlib/abort.c:91:0
#6 0x00007f2729455bf6 __assert_fail_base
/build/eglibc-SvCtMH/eglibc-2.19/assert/assert.c:92:0
#7 0x00007f2729455ca2 (/lib/x86_64-linux-gnu/libc.so.6+0x2fca2)
#8 0x00000000016e4099 (optpolly+0x16e4099)
#9 0x0000000001ec92f6 (optpolly+0x1ec92f6)
#10 0x0000000001ec9390 (optpolly+0x1ec9390)
#11 0x0000000001ec9497 (optpolly+0x1ec9497)
#12 0x0000000001ec9497 (optpolly+0x1ec9497)
#13 0x0000000001eca418 (optpolly+0x1eca418)
#14 0x000000000166083b (optpolly+0x166083b)
#15 0x0000000001b5c6cb (optpolly+0x1b5c6cb)
#16 0x0000000001b5c77c (optpolly+0x1b5c77c)
#17 0x0000000001b5d33a (optpolly+0x1b5d33a)
#18 0x00000000008bb79f (optpolly+0x8bb79f)
#19 0x00007f2729447f45 __libc_start_main
/build/eglibc-SvCtMH/eglibc-2.19/csu/libc-start.c:321:0
#20 0x000000000092d7d6 (optpolly+0x92d7d6)
Stack dump:
0.      Program arguments: optpolly -instcombine -early-cse-memssa -licm
-loop-rotate -loop-vectorize -newgvn -simplifycfg -loop-reroll -o small-opt.bc
small.bc 
1.      Running pass 'Function Pass Manager' on module 'small.bc'.
2.      Running pass 'Loop Pass Manager' on function '@f'
3.      Running pass 'Reroll loops' on basic block '%for.body'
Aborted (core dumped)
$ 


------------------------------


int a, b[1][2], *c[2], d;

void f ()
{
  for (; a; a++)
    for (d = 0; d < 2; d++)
      c[d] = &b[a][d];
}

int main ()
{
  f ();
  return 0;
}

-- 
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/20180103/602de128/attachment.html>


More information about the llvm-bugs mailing list