------- Comment #7 from pixel at mandriva dot com 2007-08-07 22:45 ------- the following patch fixes the testcase ivopts-issue.c, but breaks everything else... someone else will find a correct patch :)
--- gcc-4.2.1/gcc/tree-ssa-loop-ivopts.c.pix 2006-10-06 21:32:04.000000000 +0200 +++ gcc-4.2.1/gcc/tree-ssa-loop-ivopts.c 2007-08-08 00:23:49.000000000 +0200 @@ -3061,7 +3061,9 @@ get_computation_aff (struct loop *loop, expr = fold_convert (ctype, expr); } - if (TYPE_UNSIGNED (utype)) + if (POINTER_TYPE_P (utype)) + uutype = ctype; + else if (TYPE_UNSIGNED (utype)) uutype = utype; else { -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32544