This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/53805] combine_comparisons changes trapping behavior
- From: "glisse at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 06 Jul 2012 21:53:32 +0000
- Subject: [Bug tree-optimization/53805] combine_comparisons changes trapping behavior
- Auto-submitted: auto-generated
- References: <bug-53805-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53805
--- Comment #9 from Marc Glisse <glisse at gcc dot gnu.org> 2012-07-06 21:53:32 UTC ---
Suspicious code:
combine_comparisons has special code that depends on which comparison comes
first, but maybe_fold_and_comparisons calls and_comparisons_1 (and thus
combine_comparisons) with arguments in both orders. I guess this would give a
wrong optimization for ORDERED_EXPR && LT_EXPR, but I am having a hard time
creating an ORDERED_EXPR.
It looks like invert_tree_comparison shouldn't return ERROR_MARK for
(UN)ORDERED_EXPR.