Skip to content

fix view assign replacing prior readers - #1

Open
dyKiU wants to merge 3 commits into
masterfrom
bugfix/view-assign-prior-readers
Open

fix view assign replacing prior readers#1
dyKiU wants to merge 3 commits into
masterfrom
bugfix/view-assign-prior-readers

Conversation

@dyKiU

@dyKiU dyKiU commented Aug 12, 2026

Copy link
Copy Markdown
Owner

No description provided.

@dyKiU
dyKiU force-pushed the bugfix/view-assign-prior-readers branch 10 times, most recently from ec61701 to 17f9f12 Compare August 21, 2026 14:39
@dyKiU
dyKiU force-pushed the bugfix/view-assign-prior-readers branch 2 times, most recently from 7115832 to 9b17819 Compare August 26, 2026 06:36
dyKiU added 3 commits August 29, 2026 08:15
Keep lazy readers on the value they captured before a view assignment while aliases continue to observe the write. Preserve that state through JIT replay and backward, and avoid realizing disjoint readers.
The write range only classifies prior readers, so avoid its graph rewrite when no readers exist. This restores chained view assignment from 73.03 ms to 0.44 ms per assignment while retaining overlap checks when readers are present.
@dyKiU
dyKiU force-pushed the bugfix/view-assign-prior-readers branch from 9b17819 to 0de35ac Compare August 29, 2026 07:19
@github-actions

Copy link
Copy Markdown

Changes

Name                      Lines    Diff    Tokens/Line    Diff
----------------------  -------  ------  -------------  ------
tinygrad/tensor.py          577    +108           16.1    -0.2
tinygrad/engine/jit.py      230      +2           16.1    -0.1


total lines changes: +110

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant