[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2016-08-24 Thread amker at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=34114 amker at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED CC|

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2016-08-02 Thread amker at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=34114 --- Comment #8 from amker at gcc dot gnu.org --- Author: amker Date: Tue Aug 2 10:13:28 2016 New Revision: 238983 URL: https://gcc.gnu.org/viewcvs?rev=238983=gcc=rev Log: PR tree-optimization/34114 * tree-ssa-loop-niter.c

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2016-08-02 Thread amker at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=34114 --- Comment #7 from amker at gcc dot gnu.org --- Author: amker Date: Tue Aug 2 10:09:33 2016 New Revision: 238982 URL: https://gcc.gnu.org/viewcvs?rev=238982=gcc=rev Log: PR tree-optimization/34114 * fold-const.c

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2007-11-15 Thread steven at gcc dot gnu dot org
--- Comment #1 from steven at gcc dot gnu dot org 2007-11-15 23:31 --- We may be able to propagate somehow that rnd_to_2 is always even. I doubt it is worth the trouble, to be honest... Zdenek may have some thought on this. -- steven at gcc dot gnu dot org changed:

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2007-11-15 Thread lloyd at randombit dot net
--- Comment #2 from lloyd at randombit dot net 2007-11-16 00:50 --- Is there be any way to modify the code such that GCC would have an easier time seeing this? I tried using 'assert(rnd_to_2 % 2 == 0)' (since glibc's __assert_fail is marked with noreturn I thought it might help), but

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2007-11-15 Thread pinskia at gcc dot gnu dot org
--- Comment #4 from pinskia at gcc dot gnu dot org 2007-11-16 01:52 --- (In reply to comment #3) Here's another example, which I think may represent a different case (and which I found much more surprising than the first): no_loop_opt2.c:5: warning: cannot optimize possibly

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2007-11-15 Thread lloyd at randombit dot net
--- Comment #5 from lloyd at randombit dot net 2007-11-16 02:00 --- Argh, you are correct. The original code has unsigned int n = an_input / 160; so this could never occur there, but GCC's inability to tell that this assignment means that n cannot be UINT_MAX (in that code) is

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2007-11-15 Thread lloyd at randombit dot net
--- Comment #3 from lloyd at randombit dot net 2007-11-16 01:49 --- Here's another example, which I think may represent a different case (and which I found much more surprising than the first): $ cat no_loop_opt2.c void g(unsigned int n) { unsigned int k; for(k = 0; k = n;

[Bug tree-optimization/34114] Missed optimization: cannot determine loop termination

2007-11-15 Thread rakdver at gcc dot gnu dot org
--- Comment #6 from rakdver at gcc dot gnu dot org 2007-11-16 02:38 --- (In reply to comment #2) Is there be any way to modify the code such that GCC would have an easier time seeing this? I tried using 'assert(rnd_to_2 % 2 == 0)' (since glibc's __assert_fail is marked with noreturn