PR tree-optimization/68431
* tree-vrp.c (extract_range_from_binary_expr_1): Fix condition.
* gcc.dg/tree-ssa/pr68431.c: New test.
From-SVN: r230608
+2015-11-19 Marek Polacek <polacek@redhat.com>
+
+ PR tree-optimization/68431
+ * tree-vrp.c (extract_range_from_binary_expr_1): Fix condition.
+
2015-11-19 Nathan Sidwell <nathanacm.org>
* config/nvptx/nvptx.md (atomic_compare_and_swap<mode>_1,
+2015-11-19 Marek Polacek <polacek@redhat.com>
+
+ PR tree-optimization/68431
+ * gcc.dg/tree-ssa/pr68431.c: New test.
+
2015-11-19 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/68376
--- /dev/null
+/* PR tree-optimization/68431 */
+/* { dg-options "-O2 -fdump-tree-vrp1-details" } */
+
+unsigned int x = 1;
+int
+main (void)
+{
+ long long int a = -2LL;
+ int t = 1 <= (a / x);
+ if (t != 0)
+ __builtin_abort ();
+
+ return 0;
+}
+
+/* { dg-final { scan-tree-dump-times "Folding predicate .*to 0" 1 "vrp1" } } */
if (vr1.type == VR_RANGE
&& !symbolic_range_p (&vr0)
&& !symbolic_range_p (&vr1)
- && !compare_values (vr1.min, zero))
+ && compare_values (vr1.min, zero) != 0)
max = int_const_binop (code, vr0.max, vr1.min);
else
max = zero;