Commit Graph

9198 Commits

Author SHA1 Message Date
uuuvn
e7a26211d2 Queue remote transfers on source (#10871)
https://github.com/tinygrad/tinygrad/pull/10601#issuecomment-2985624147

I personally don't see how that is a good standalone pr, but whatever
2025-06-18 16:08:44 -07:00
uuuvn
a9f3632c4f SessionKey is a dataclass (#10870) 2025-06-18 15:07:31 -07:00
wozeparrot
bdbf121285 fix: contigous -> contiguous (#10868) 2025-06-18 13:09:51 -07:00
qazal
344a220b87 s/lb_refcount/uop_refcount [pr] (#10865) 2025-06-18 21:48:04 +03:00
simone-pietro
f59df04998 Generalize type hint for get_single_element [pr] (#10866)
* Generalize type hint for get_single_element

* Improve wording in assert
2025-06-18 13:13:04 -04:00
chenyu
d71bb6a7b2 remove comma 0.9.4 from benchmark (#10867) 2025-06-18 12:43:59 -04:00
chenyu
b70c7d3631 bert grad accumulation (#10863)
* bert grad accumulation

* realize grad
2025-06-18 12:17:07 -04:00
simone-pietro
56fe5b60a9 Cast int to str for render_cast (#10864)
* Add type hint for render_cast

* Revert "Add type hint for render_cast"

This reverts commit 33858eb711.

* Cast int to str for render_cast
2025-06-18 10:55:27 -04:00
simone-pietro
d8cea1a279 Change rate to int in test_tqdm (#10848) 2025-06-18 08:40:43 -04:00
simone-pietro
0735224ac2 Pass PythonRenderer instance to full_rewrite (#10859) 2025-06-18 08:39:27 -04:00
qazal
96509daaba enable copy folding tests [pr] (#10862) 2025-06-18 13:05:35 +03:00
qazal
84d568d0cc do not import grouper internals in test_schedule [pr] (#10861)
* fix import

* fix test_multitoutput_ast

* fix test_recursive_swizzle

* test_alu_after_copy

* remove that test
2025-06-18 12:47:57 +03:00
qazal
8b879b0314 merge TestTensorUOpSpec with the other spec unittests [pr] (#10860)
* merge TestTensorUOpSpec with the other spec unittests [pr]

* rename to test_uop_spec
2025-06-18 12:12:08 +03:00
qazal
a5f2bb614a remove validate_kernel, it is asserting implementation details [pr] (#10858) 2025-06-18 11:42:36 +03:00
George Hotz
cba6e15937 split grouper and kernelize [pr] (#10854) 2025-06-17 17:54:20 -07:00
George Hotz
75503955bf simple schedule test [pr] (#10853) 2025-06-17 16:19:27 -07:00
chenyu
075a74cf25 add global_batch_size to mlperf bert (#10852)
global_batch_size = grad_acc_steps * batch_size. no-op change to prep grad acc for bert
2025-06-17 17:54:15 -04:00
uuuvn
a51f18f8f9 CI flakiness (#10851)
https://github.com/tinygrad/tinygrad/actions/runs/15718103629/job/44292845140?pr=10753#step:4:161
2025-06-17 14:46:30 -07:00
qazal
e77cd81662 time viz (#10763)
* work

* basic stuff

* work

* also reset

* moving through time

* cleanup

* proper zoom

* add livereload.js

pip install livereload
livereload tinygrad/viz

* minor

* fixed width, remove viewbox

* bit of flexbox magic

* show pid/tid

* merge loops

* min-height

* redo some layout stuff

* create cell groups

* text is hard

* javascript Math.min causes "Maximum call stack size"
bert repro: VIZ=1 PYTHONPATH=. DEFAULT_FLOAT=HALF BS=66 GPUS=6 BERT_LAYERS=2 FUSE_ARANGE=1 MODEL=bert python3 examples/mlperf/model_train.py

* fix recursion issue

* no viz/server changes

* fix test_viz

* everything is a g

* text is easy

* no it's still hard

* livereload+notes

* height: 100% fixes the device bug

* start canvas work

* base canvas

* take chrome's stuff

* serve chrome's thing

* fetch traces from get_profile

* remove junk

* remove some more

* bring everything back again

* dispatch resize events

* base ticks

* hook d3.zoom

* zoom on the x axis

* bring filter back, makes ctrl+drag possible

* remove junk

* Revert "remove junk"

This reverts commit 4987e7bec1.

* draws something, the zooms aren't right

* move to canvas

* fix zooming

* Revert "Revert "remove junk""

This reverts commit 5aac2034fb.

* space key resets zoom

* Divide timelines by device on y axis

* Show kernel names when the width allows

* Clicking on kernel opens it in the kernel graph

* remove livereload.js

* reset diff

* base diff:

- fetch traceEvents
- displayGraph
- flexbox layout
- rest of canvas

* rescale in-place is faster, d3's rescaleX creates a copy

* less

* aesthetics

* map names

* first viz is profiler

* this will work when i make canvas once

* initial cleanups

* factor out of loop

* refactor + only show devices with events

* properly align program rects

* cleaner tick lines

* padding

* listen for resize

* simple zoom

* space more

* i always end up making zoom globl

* how is this ever allowed

* clicking works again

* back button goes back to the same zoom level

* work

* more work

* bring that back

* coloring work and simplify

* black

* keep perfetto button for comparison

* better

* ph===X

* simplify history stuff

* temp: handcoded

* test: flamegraph style leveling

* Revert "temp: handcoded"

This reverts commit bdcd538e88.

* disable flamegraph

* group by pid

* factor y and height out of render

* now flamegraph is easy

* livereload stuff

* remove that

* less
2025-06-17 19:39:34 +03:00
qazal
9e2cb7522a viz: define launch_viz when tracking is enabled (#10846) 2025-06-17 19:38:02 +03:00
Bhavya Gada
3a474ef5b7 move bitwise_and/bitwise_or/bitwise_xor to MathTrait [pr] (#10794)
* move bitwise and, or, xor to MathTrait

* refactor
2025-06-17 09:19:43 -07:00
George Hotz
531d143780 bring back old sharded rand behavior (#10842) 2025-06-16 17:23:47 -07:00
George Hotz
a493eb396c fix view add 0 (#10840) 2025-06-16 16:46:12 -07:00
George Hotz
b5ce227850 Revert "hotfix: remove setrecursionlimit"
This reverts commit acfc81642a.
2025-06-16 16:01:42 -07:00
George Hotz
acfc81642a hotfix: remove setrecursionlimit 2025-06-16 15:31:34 -07:00
George Hotz
00c46e7077 print rules count in match stats (#10839) 2025-06-16 14:56:27 -07:00
George Hotz
e2907360b7 multi is one PM [pr] (#10838)
* multi is one PM [pr]

* disable flaky tests
2025-06-16 14:52:47 -07:00
Sieds Lykles
b1fefb76dd More conditions for (x//c1+a)//c2 -> (x+a*c1)//(c1*c2) (#10834)
* add rule and test

* typo

---------

Co-authored-by: chenyu <chenyu@fastmail.com>
2025-06-16 16:34:52 -04:00
uuuvn
18d936f981 Remote multihost (#10598) 2025-06-16 13:18:56 -07:00
George Hotz
0629e45332 remove cpu graph (#10836)
* remove cpu graph, it's different from the others

* remote was blacklisting CPUGraph

* remove cpugraph from dsp
2025-06-16 11:40:58 -07:00
Sieds Lykles
deb6af0638 Remove incorrect rule for x%-d -> (x%d)*-1 (#10832)
* fix rule and add test

* combine tests
2025-06-16 11:37:44 -04:00
Sieds Lykles
946243dbb2 Change z3 cdiv to euclidian division (#10833)
* change z3_cdiv

* shorter
2025-06-16 11:04:51 -04:00
qazal
2c6fd5bf81 viz: rename to svgZoom (#10831) 2025-06-16 13:05:22 +03:00
qazal
e8ec3f544b viz: helper for keeping state in browser history (#10830) 2025-06-16 12:26:10 +03:00
chenyu
e5d5ae55f9 smaller inputs for test_sort and test_topk (#10829) 2025-06-16 00:21:15 -04:00
nimlgen
c0329148c7 am: check va is aligned to page size (#10815)
* am: check va is aligned to page size

* swap them

* is this faster
2025-06-15 22:51:09 +03:00
Sieds Lykles
ac27c46104 fix UPat get_location after mathtraits refactor (#10814)
* fix UPat get_location

* fold line
2025-06-15 12:47:55 -07:00
George Hotz
5dc1bc6070 switch get_kernel -> get_program [pr] (#10817)
* switch get_kernel -> get_program [pr]

* fix tests
2025-06-15 12:26:50 -07:00
George Hotz
a36b09a715 universal device import [pr] (#10818) 2025-06-15 12:01:02 -07:00
George Hotz
cc5e4e54b8 move type verify to codegen [pr] (#10816) 2025-06-15 12:00:52 -07:00
George Hotz
27cf836958 split ocelot out for autogen, fix CI (#10819)
* split ocelot out for autogen, fix CI

* mac ocelot
2025-06-15 11:37:23 -07:00
Ahmed Harmouche
c380efc220 Support aarch64 linux on webgpu (#10802) 2025-06-14 14:57:18 -04:00
Sieds Lykles
37d3ca152e Adapt >> for division by power of two to all ints (#10803)
* Change divison by power of two to always use shift

* Change test to test int instead of uint

* simplify condition

* add old rule back with comment

* remove import

* use sresolve instead of simplify

* use keyword in simplify instead of sresolve

* webgpu cast y to uint

* remove comment

* explicitly set dtype in wgsl

* without simplify

* undo simplify kwarg

* change test to test both int32 and uint32
2025-06-14 14:55:51 -04:00
chenyu
652db5702b move test_conv_shapetracker and some test_search util into unit test (#10812) 2025-06-14 13:29:32 -04:00
George Hotz
754667093f remove IGNORE stuff (#10796)
* remove IGNORE stuff, was this even tested? [pr]

* delete IGNORE op
2025-06-14 09:59:45 -07:00
leopf
118a09ddcf xor self folding (#10806)
* xor folding

* tests + z3 bitwise xor
2025-06-14 10:01:17 -04:00
qazal
8e6ac18436 viz: make sidebar list responsive to keyboard smashing (#10811)
* expanded is a static style

* only draw the list once

* identify with ids

* state isn't used here anymore

* only toggle states

* less
2025-06-14 13:52:27 +03:00
chenyu
8c28b5d833 move dtype spec tests into unit test (#10808)
* move dtype spec tests into unit test

can clean up more after the split

* skip CI test_backward_sum_acc_dtype
2025-06-13 22:21:22 -04:00
chenyu
7a6df0a161 remove .relu() call in several conv tests in test_ops (#10807)
* remove .relu() call in several conv tests in test_ops

testing negative parts double the effectiveness. keep the relu between two convs and the tests that explicitly test relu

* relax tol
2025-06-13 17:10:16 -04:00
nimlgen
b6e574fcdf am: smu 14.0.3 is smu 14.0.2 (#10714) 2025-06-13 23:07:56 +03:00