This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/83255] [8 Regression] [graphite] Wrong code w/ -O1 -floop-nest-optimize
- From: "rguenth at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 04 Dec 2017 10:03:10 +0000
- Subject: [Bug tree-optimization/83255] [8 Regression] [graphite] Wrong code w/ -O1 -floop-nest-optimize
- Auto-submitted: auto-generated
- References: <bug-83255-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83255
--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
Ah, finally a testcase for a fix I have in my tree ;)
It would probably help if we'd emit the loop niters as SSA names instead of
creating weird constraints from them like
[sese-to-poly] adding one extra dimension to the domain for loop_1.
[sese-to-poly] adding constraint to the domain: [P_25] -> { [i1] : i1 >= 0 }
[sese-to-poly] adding constraint to the domain: [P_25] -> { [i1] :
4294967296*floor((-P_25)/4294967296) <= -P_25 - i1 }
Analyzing # of iterations of loop 1
exit condition [l4.8_25 + 1, + , 1](no_overflow) <= 0
bounds on difference of bases: -1 ... 2147483647
result:
# of iterations -(unsigned int) l4.8_25, bounded by 2147483648
...
[scheduler] original ast:
for (int c0 = 0; c0 <= -P_25; c0 += 1)
for (int c1 = 0; c1 <= 2; c1 += 1) {
for (int c2 = 0; c2 <= 2; c2 += 1)
S_5(c0, c1, c2);
S_25(c0, c1);
}