Commit 5ac4b056 by Jakub Jelinek Committed by Jakub Jelinek

re PR tree-optimization/83221 (qsort comparator not anti-commutative: -2147483648, -2147483648)

	PR tree-optimization/83221
	* tree-ssa-reassoc.c (sort_by_operand_rank): Shift bb_rank
	down by 16.
	(init_reassoc): Formatting fix.

From-SVN: r255297
parent 9ede7b1b
2017-12-01 Jakub Jelinek <jakub@redhat.com> 2017-12-01 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/83221
* tree-ssa-reassoc.c (sort_by_operand_rank): Shift bb_rank
down by 16.
(init_reassoc): Formatting fix.
PR sanitizer/81275 PR sanitizer/81275
* tree-cfg.c (group_case_labels_stmt): Don't optimize away * tree-cfg.c (group_case_labels_stmt): Don't optimize away
C++ FE implicitly added __builtin_unreachable () until -Wreturn-type C++ FE implicitly added __builtin_unreachable () until -Wreturn-type
...@@ -543,7 +543,7 @@ sort_by_operand_rank (const void *pa, const void *pb) ...@@ -543,7 +543,7 @@ sort_by_operand_rank (const void *pa, const void *pb)
return -1; return -1;
/* If neither is, compare bb_rank. */ /* If neither is, compare bb_rank. */
if (bb_rank[bbb->index] != bb_rank[bba->index]) if (bb_rank[bbb->index] != bb_rank[bba->index])
return bb_rank[bbb->index] - bb_rank[bba->index]; return (bb_rank[bbb->index] >> 16) - (bb_rank[bba->index] >> 16);
} }
bool da = reassoc_stmt_dominates_stmt_p (stmta, stmtb); bool da = reassoc_stmt_dominates_stmt_p (stmta, stmtb);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment