This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PTR-PLUS] Merge from the mainline


Hi, I merged the mainline (revision 124602) into the branch and during 
that merge I found a couple more regressions due to scev being improved.

One problem is that when looking at the offset with a POINTER_PLUS_EXPR, 
we have to make sure that the constant gets sign extended by converting 
the constant to sizetype.  The other problem is that in 
number_of_iterations_lt_to_ne, I forgot to change the type which we create 
the difference in; this change parrallels the change which was used for 
assert_loop_rolls_lt.

Committed this patch and the merge to the branch after a bootstrap/test on 
i686-linux-gnu with no regressions.

Thanks,
Andrew Pinski


2007-05-10  Andrew Pinski  <andrew_pinski@playstation.sony.com>

        Merge mainline, revision 124602.

        * fold-const.c  (extract_array_ref): Make sure the offset
        is converted to sizetype.
        (try_move_mult_to_index): Strip the NOPs from the offset.
        (fold_binary <case POINTER_PLUS_EXPR>): Convert the second
        operand to sizetype before calling try_move_mult_to_index.
        * tree-ssa-loop-niter.c (number_of_iterations_lt_to_ne):
        For pointer types, use sizetype when 
        creating MINUS_EXPR/PLUS_EXPRs.
        * tree-ssa-ccp.c (maybe_fold_stmt_indirect): Make sure
        the offset is converted to sizetype.


Attachment: postmerge.diff.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]