Track local size

This commit is contained in:
Szymon Ożóg
2023-08-18 16:17:49 +02:00
parent 89da2be2e5
commit 07d4731e9f

View File

@@ -69,6 +69,7 @@ def uops_to_triton(function_name:str, uops:List[UOp]):
assert var.min == 0, "local loop must start at 0"
kk(f"{var.expr} = tl.arange({0}, {var.max+1})[{', '.join([':' if i == j else 'None' for j in range(len(args[0]))])}]")
acc_local_shape *= var.max+1
local_size.append(var.max+1)
else:
kk(f"for {var.expr} in range({var.min}, {var.max+1}):")
depth += 1