+ (('fge', 0.0, ('b2f', 'a@1')), ('inot', a)),
+
+ (('fge', ('fneg', ('b2f', 'a@1')), 0.0), ('inot', a)),
+
+ (('fne', ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('ior', a, b)),
+ (('fne', ('fmax', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('ior', a, b)),
+ (('fne', ('bcsel', a, 1.0, ('b2f', 'b@1')) , 0.0), ('ior', a, b)),
+ (('fne', ('b2f', 'a@1'), ('fneg', ('b2f', 'b@1'))), ('ior', a, b)),
+ (('fne', ('fmul', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('iand', a, b)),
+ (('fne', ('fmin', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('iand', a, b)),
+ (('fne', ('bcsel', a, ('b2f', 'b@1'), 0.0) , 0.0), ('iand', a, b)),
+ (('fne', ('fadd', ('b2f', 'a@1'), ('fneg', ('b2f', 'b@1'))), 0.0), ('ixor', a, b)),
+ (('fne', ('b2f', 'a@1') , ('b2f', 'b@1') ), ('ixor', a, b)),
+ (('fne', ('fneg', ('b2f', 'a@1')), ('fneg', ('b2f', 'b@1'))), ('ixor', a, b)),
+ (('feq', ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('inot', ('ior', a, b))),
+ (('feq', ('fmax', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('inot', ('ior', a, b))),
+ (('feq', ('bcsel', a, 1.0, ('b2f', 'b@1')) , 0.0), ('inot', ('ior', a, b))),
+ (('feq', ('b2f', 'a@1'), ('fneg', ('b2f', 'b@1'))), ('inot', ('ior', a, b))),
+ (('feq', ('fmul', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('inot', ('iand', a, b))),
+ (('feq', ('fmin', ('b2f', 'a@1'), ('b2f', 'b@1')), 0.0), ('inot', ('iand', a, b))),
+ (('feq', ('bcsel', a, ('b2f', 'b@1'), 0.0) , 0.0), ('inot', ('iand', a, b))),
+ (('feq', ('fadd', ('b2f', 'a@1'), ('fneg', ('b2f', 'b@1'))), 0.0), ('ieq', a, b)),
+ (('feq', ('b2f', 'a@1') , ('b2f', 'b@1') ), ('ieq', a, b)),
+ (('feq', ('fneg', ('b2f', 'a@1')), ('fneg', ('b2f', 'b@1'))), ('ieq', a, b)),
+
+ # -(b2f(a) + b2f(b)) < 0
+ # 0 < b2f(a) + b2f(b)
+ # 0 != b2f(a) + b2f(b) b2f must be 0 or 1, so the sum is non-negative
+ # a || b
+ (('flt', ('fneg', ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1'))), 0.0), ('ior', a, b)),
+ (('flt', 0.0, ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1'))), ('ior', a, b)),
+
+ # -(b2f(a) + b2f(b)) >= 0
+ # 0 >= b2f(a) + b2f(b)
+ # 0 == b2f(a) + b2f(b) b2f must be 0 or 1, so the sum is non-negative
+ # !(a || b)
+ (('fge', ('fneg', ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1'))), 0.0), ('inot', ('ior', a, b))),
+ (('fge', 0.0, ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1'))), ('inot', ('ior', a, b))),
+
+ (('flt', a, ('fneg', a)), ('flt', a, 0.0)),
+ (('fge', a, ('fneg', a)), ('fge', a, 0.0)),
+
+ # Some optimizations (below) convert things like (a < b || c < b) into
+ # (min(a, c) < b). However, this interfers with the previous optimizations
+ # that try to remove comparisons with negated sums of b2f. This just
+ # breaks that apart.
+ (('flt', ('fmin', c, ('fneg', ('fadd', ('b2f', 'a@1'), ('b2f', 'b@1')))), 0.0),
+ ('ior', ('flt', c, 0.0), ('ior', a, b))),
+
+ (('~flt', ('fadd', a, b), a), ('flt', b, 0.0)),
+ (('~fge', ('fadd', a, b), a), ('fge', b, 0.0)),
+ (('~feq', ('fadd', a, b), a), ('feq', b, 0.0)),
+ (('~fne', ('fadd', a, b), a), ('fne', b, 0.0)),
+
+ # Cannot remove the addition from ilt or ige due to overflow.
+ (('ieq', ('iadd', a, b), a), ('ieq', b, 0)),
+ (('ine', ('iadd', a, b), a), ('ine', b, 0)),