(('fne', ('fneg', a), -1.0), ('fne', 1.0, a)),
(('feq', -1.0, ('fneg', a)), ('feq', a, 1.0)),
+ (('flt', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('flt', a, b)),
+ (('flt', '#b(is_gt_0_and_lt_1)', ('fsat(is_used_once)', a)), ('flt', b, a)),
+ (('fge', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('fge', a, b)),
+ (('fge', '#b(is_gt_0_and_lt_1)', ('fsat(is_used_once)', a)), ('fge', b, a)),
+ (('feq', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('feq', a, b)),
+ (('fne', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('fne', a, b)),
+
+ (('fge', ('fsat(is_used_once)', a), 1.0), ('fge', a, 1.0)),
+ (('flt', ('fsat(is_used_once)', a), 1.0), ('flt', a, 1.0)),
+ (('fge', 0.0, ('fsat(is_used_once)', a)), ('fge', 0.0, a)),
+ (('flt', 0.0, ('fsat(is_used_once)', a)), ('flt', 0.0, a)),
+
# 0.0 >= b2f(a)
# b2f(a) <= 0.0
# b2f(a) == 0.0 because b2f(a) can only be 0 or 1
# optimization loop can prevent other optimizations.
(('fneg', ('fneg', a)), a),
+ # These are duplicated from the main optimizations table. The late
+ # patterns that rearrange expressions like x - .5 < 0 to x < .5 can create
+ # new patterns like these. The patterns that compare with zero are removed
+ # because they are unlikely to be created in by anything in
+ # late_optimizations.
+ (('flt', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('flt', a, b)),
+ (('flt', '#b(is_gt_0_and_lt_1)', ('fsat(is_used_once)', a)), ('flt', b, a)),
+ (('fge', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('fge', a, b)),
+ (('fge', '#b(is_gt_0_and_lt_1)', ('fsat(is_used_once)', a)), ('fge', b, a)),
+ (('feq', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('feq', a, b)),
+ (('fne', ('fsat(is_used_once)', a), '#b(is_gt_0_and_lt_1)'), ('fne', a, b)),
+
+ (('fge', ('fsat(is_used_once)', a), 1.0), ('fge', a, 1.0)),
+ (('flt', ('fsat(is_used_once)', a), 1.0), ('flt', a, 1.0)),
+
(('~fge', ('fmin(is_used_once)', ('fadd(is_used_once)', a, b), ('fadd', c, d)), 0.0), ('iand', ('fge', a, ('fneg', b)), ('fge', c, ('fneg', d)))),
(('flt', ('fneg', a), ('fneg', b)), ('flt', b, a)),