MCPcopy
hub / github.com/tinygrad/tinygrad / realize

Function realize

tinygrad/schedule/indexing.py:14–18  ·  view source on GitHub ↗
(ctx:dict[UOp, None], tr:UOp)

Source from the content-addressed store, hash-verified

12 Ops.DEFINE_LOCAL, Ops.DEFINE_REG, Ops.LOAD, Ops.CALL, Ops.FUNCTION}
13
14def realize(ctx:dict[UOp, None], tr:UOp) -> None: ctx[tr] = None
15
16def realize_srcs(ctx:dict[UOp, None], rb:UOp) -> None:
17 for s in rb.src:
18 if s.base.op not in ALWAYS_CONTIGUOUS: ctx[s] = None
19
20def realize_store_after_src(ctx:dict[UOp, None], dest:UOp, src:UOp):
21 # don't realize COPY/BUFFER_VIEW when they are the direct source of STORE+AFTER — the target buffer is the output

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…