mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-02-12 07:35:16 -05:00
use const_like in uop zero folding [pr] (#8470)
This commit is contained in:
@@ -2054,14 +2054,12 @@ class TestBigGraph(unittest.TestCase):
|
||||
assert UPat(Ops.CONST, arg=0).match(sink, {}), f"expected {sink} to collapse to a const 0"
|
||||
assert sink.shape == a.shape
|
||||
|
||||
@unittest.expectedFailure
|
||||
def test_const_folding_ne(self):
|
||||
a = Tensor([1])
|
||||
sink = tensor_rewrite(a != a)
|
||||
assert UPat(Ops.CONST, arg=False).match(sink, {}), f"expected {sink} to collapse to a const False"
|
||||
assert sink.shape == a.shape
|
||||
|
||||
@unittest.expectedFailure
|
||||
def test_const_folding_lt(self):
|
||||
a = Tensor([1])
|
||||
sink = tensor_rewrite(a < a)
|
||||
|
||||
Reference in New Issue
Block a user