minor stuff reading the printed code [pr] (#13177)

This commit is contained in:
chenyu
2025-11-08 21:58:51 -08:00
committed by GitHub
parent 8e868dced8
commit 41e45c20ff
3 changed files with 2 additions and 3 deletions

View File

@@ -38,7 +38,7 @@ def compile(onnx_file):
np.testing.assert_equal(test_val, ret, "JIT run failed")
print("jit run validated")
# checks from compile2
# check gated read_image usage
kernel_count = 0
read_image_count = 0
gated_read_image_count = 0

View File

@@ -41,7 +41,7 @@ def linearize(sink:UOp) -> list[UOp]:
# number the uops in "ideal" order
nkey = {u:i for i,u in enumerate(sorted(lst, key=lambda x: priorities[x]+(x.tuplize if TUPLE_ORDER else ())))}
# then force then to be toposorted in as close to the ideal order as possible
# then force them to be toposorted in as close to the ideal order as possible
heap = [(-nkey[sink], sink)]
newlst = []
while heap:

View File

@@ -34,7 +34,6 @@ def simplify_merge_adjacent(u:UOp) -> UOp|None:
# check if it simplifies
if count_divmod(nidx) <= count_divmod(u):
u = nidx
continue
return u
pm_simplify_ranges = PatternMatcher([