https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61929
Bug ID: 61929 Summary: Graphite: Banerjee and Omega differ on distance vectors (internal compiler error in compute_affine_dependence) Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: gcc at crg4 dot com -fcheck-data-deps finds a discrepancy between Banerjee and Omega in gcc 4.9 when compiling the latest RIES source. The error message is: (Number of distance vectors differ: Banerjee has 1, Omega has 2. Banerjee dist vectors: 0 Omega dist vectors: 0 1 data dependence relation: (Data Dep: #(Data Ref: # bb: 44 # stmt: debug_L.555_92 = debug_L; # ref: debug_L # base_object: MEM[(short int *)&debug_L]; #) #(Data Ref: # bb: 44 # stmt: debug_L = debug_L.568_93; # ref: debug_L # base_object: MEM[(short int *)&debug_L]; #) inner loop index: 0 loop nest: (1 ) distance_vector: 0 distance_vector: 1 direction_vector: = direction_vector: + ) ) ries.c: In function ‘set_debug_opts’: ries.c:10391:6: internal compiler error: in compute_affine_dependence, at tree-data-ref.c:4233 void set_debug_opts(char * str) ^ Please submit a full bug report, with preprocessed source if appropriate. ---- The RIES source is available at http://www.mrob.com/pub/ries/src/ries.c.txt and is self-contained (no .h files etc.). I can cause the error with gcc -o ries ries.c -lm -O1 -fcheck-data-deps but not gcc -o ries ries.c -lm -O0 -fcheck-data-deps however I cannot narrow this down to a particular optimization causing the difficulty since gcc -o ries ries.c -lm -O1 -fcheck-data-deps -fno-branch-count-reg -fno-combine-stack-adjustments -fno-compare-elim -fno-cprop-registers -fno-defer-pop -fno-forward-propagate -fno-guess-branch-probability -fno-if-conversion -fno-if-conversion2 -fno-inline-functions-called-once -fno-ipa-profile -fno-ipa-pure-const -fno-ipa-reference -fno-merge-constants -fno-move-loop-invariants -fno-shrink-wrap -fno-split-wide-types -fno-tree-bit-ccp -fno-tree-ccp -fno-tree-ch -fno-tree-copy-prop -fno-tree-copyrename -fno-tree-dce -fno-tree-dominator-opts -fno-tree-dse -fno-tree-fre -fno-tree-pta -fno-tree-sink -fno-tree-slsr -fno-tree-sra -fno-tree-ter still causes the error. It appears that at least one of the Omega and Banerjee algorithms are incorrect. I am running > gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.9/lto-wrapper Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.9.1-1ubuntu2~14.04.3' --with-bugurl=file:///usr/share/doc/gcc-4.9/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.9 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.9 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libmudflap --disable-vtable-verify --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.9-amd64/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.9-amd64 --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.9-amd64 --with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix gcc version 4.9.1 (Ubuntu 4.9.1-1ubuntu2~14.04.3) > uname -a Linux zed 3.2.0-56-generic #86-Ubuntu SMP Wed Oct 23 09:20:45 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux I have no knowledge of either Graphite or RIES; I am merely reporting what appears to be a bug (indeed, as instructed by gcc itself).