[PATCH][4.1] Fix PR26763
Tue Apr 4 14:21:00 GMT 2006
On Mon, 3 Apr 2006, Richard Guenther wrote:
> 2006-04-03 Richard Guenther <firstname.lastname@example.org>
> PR tree-optimization/26763
> * fold-const.c (fold_binary): Fold PTR + CST CMP PTR + CST
> only for EQ_EXPR and NE_EXPR.
> * gcc.dg/torture/pr26763-1.c: New testcase.
> * gcc.dg/torture/pr26763-2.c: Likewise.
And this version is OK for the gcc-4_1-branch. Let's keep an
eye open for possible performance issues. This fix is fine as
this is a serious wrong-code regression, but if it costs a lot
in performance, we'll need to investigate (prioritize) a longer
term solution to recover these optimizations.
More information about the Gcc-patches