multireduce OptOps tests (start) (#4733)

* start

* full tests

* add skips

* unrelated

* notes
This commit is contained in:
qazal
2024-05-27 17:21:33 +08:00
committed by GitHub
parent 0b58203cbe
commit 0e69b22629
3 changed files with 150 additions and 4 deletions

View File

@@ -59,7 +59,7 @@ class TestUOpGraph(unittest.TestCase):
cast = g.add(UOps.CAST, dtypes.float.vec(2), (ld,))
x = g.add(UOps.GEP, dtypes.float, (cast, ), arg=0)
alu = g.add(UOps.ALU, dtypes.float, (x, ), UnaryOps.SQRT)
out = g.add(UOps.STORE, dtypes.float, (d0, idx, alu), UnaryOps.SQRT)
out = g.add(UOps.STORE, dtypes.float, (d0, idx, alu))
g.add(UOps.SINK, None, (out,))
self.assertEqual(len([x for x in g.uops if x.uop is UOps.CAST]), 0)