Commit Graph

184 Commits

Author SHA1 Message Date
qazal
f39e9b4288 match lazy movement ops in uop [pr] (#7944) 2024-11-28 23:03:43 +08:00
qazal
aa7e16744e allow sinking childless consts and fold them [pr] (#7941) 2024-11-28 20:23:37 +08:00
qazal
ea57c52b99 base uop is always contiguous (#7907)
* base is always contiguous

* add test_late_fusion_post_permute_simpler

* Revert "swizzle tc [pr] (#7633)"

This reverts commit f02462c5cb.

* Revert "Revert "swizzle tc [pr] (#7633)""

This reverts commit a26b577d86.

* yay

* minimal diff
2024-11-26 20:13:29 +08:00
qazal
5aee78a0a6 fix uop swizzle on BUFFER, new tests (#7875)
* fix uop swizzle on BUFFER, new tests

* can have view of view
2024-11-24 17:11:09 +08:00
qazal
5399ff6d06 add UOp.const_with_shape [pr] (#7825)
* add UOp.const_with_shape [pr]

* lines
2024-11-21 21:13:23 +08:00
qazal
e378aeb94e assert view degrade to const tests post scheduler graph_rewrite [pr] (#7822)
* assert view degrade to const tests post scheduler graph_rewrite [pr]

* low pri, probably tricky, todo
2024-11-21 19:00:41 +08:00
qazal
75c082b883 move CONST/BIND -> VALID to matchers (#7818)
* delete special const

* move CONST/BIND -> VALID to matchers

* unittests

* fix FUSE_ARANGE=1

* split into two upats

* the right way to access view
2024-11-21 16:07:01 +08:00
geohotstan
8100109c9d Add replicate mode to Tensor.pad (#7608)
* base implementation

* add tests

* actually remove the assertionerror test

* actually only have reflect for this pr

* change the 4 if-else one liner

* maybe use a lambda

* fix

* maybe a lil cleaner

* fix tests

* complete

* small change

---------

Co-authored-by: chenyu <chenyu@fastmail.com>
2024-11-18 10:55:38 -05:00
ignaciosica
597a239e28 Remove UnaryOps, BinaryOps, TernaryOps, MetaOps [pr] (#7725)
* remove unaryops

* remove ternaryops

* remove metaops

* hotfix

* remove binaryops

* hotfix: test_pattern_matcher

---------

Co-authored-by: qazal <77887910+Qazalin@users.noreply.github.com>
2024-11-16 20:56:56 +08:00
qazal
bddee26114 Ops.VALID cleanup, move recursive tests [pr] (#7713) 2024-11-15 20:22:46 +08:00
qazal
703a255301 use the method_cache in test_schedule [pr] (#7712)
* use the method_cache in test_schedule [pr]

* need half
2024-11-15 19:20:47 +08:00
qazal
88f760cc32 test_two_sum doesn't need del (#7711) 2024-11-15 18:50:08 +08:00
qazal
a8da84cce0 recursive swizzle with just graph_rewrite [pr] (#7626) 2024-11-10 20:14:21 +02:00
qazal
092a441748 test swizzle post permute (#7623)
* test swizzle post permute

* add st_fixup assert
2024-11-10 16:18:22 +02:00
qazal
b61266eb97 late fusion spec for big graph [pr] (#7613) 2024-11-09 23:43:11 +08:00
qazal
9d6b03d691 early assert swizzle in kernel [pr] (#7610)
* early assert swizzle in kernel [pr]

* better

* note changes

* TestIndexing 2
2024-11-09 21:54:43 +08:00
George Hotz
205befa788 move is_dtype_supported to device [pr] (#7575) 2024-11-07 20:38:03 +08:00
qazal
1f5ea1e412 late fusion tests, early merge view GroupOp.Buffer [pr] (#7577)
* test_late_fusion_double_transpose

* early merge view buffer ops
2024-11-07 20:04:57 +08:00
qazal
f0fc34e594 swizzle tests from the delete_fuse branch [pr] (#7576)
* swizzle tests from the delete branch [pr]

* actually test torch

* atol
2024-11-07 18:29:06 +08:00
qazal
a9a040398c don't print the entire schedule on assert [pr] (#7565)
* don't print the entire schedule on assert [pr]

* extra
2024-11-06 18:29:50 +08:00
chenyu
c805e3fff5 skip test_jit_batch_split if JIT >= 2 (#7561)
* skip test_jit_batch_split if JIT >= 2

only test graphs

* 1600
2024-11-05 14:59:04 -05:00
chenyu
f2fa183651 increase threshold test_strongly_connected_DAG (#7560)
it shoult test some other properties. flakying with time test https://github.com/chenyuxyz/tinygrad/actions/runs/11688403523/job/32548762512
2024-11-05 11:44:39 -05:00
Carl Basho
630a7f37cf update tests (#7554)
Co-authored-by: John Doe <null@mail.com>
Co-authored-by: chenyu <chenyu@fastmail.com>
2024-11-05 11:35:15 -05:00
geohotstan
934fb73994 fix test_schedule conv2d bug (#7549)
* tests tests tests

* slap a resolve on it

* fix comment
2024-11-05 09:07:25 -05:00
George Hotz
99bd4372a5 Ops.ALU is no more, the arg is just an op (#7525)
* op arg alu [pr]

* more

* more passing

* fix more tests

* more tests passing

* fix single failing test

* so much cleaner

* noop to not have process replay trigger

* fix ptx
2024-11-05 00:22:22 +08:00
qazal
b5718ae135 image dtype fusion tests [pr] (#7530)
* update test_lil_model

* add test_image_matmul
2024-11-04 22:00:16 +08:00
George Hotz
0c19b6298b rename ops to have unique names (#7522) 2024-11-04 17:09:45 +08:00
George Hotz
c8bf09b7d4 s/UOps/Ops (#7500)
* s/UOps/Ops [pr]

* fix
2024-11-03 11:26:10 +08:00
qazal
1a2ee37dd3 hotfix: remove redundant test_schedules [pr] (#7412) 2024-10-31 01:10:31 +08:00
qazal
1383df95af track_rewrites by function call [pr] (#7165)
* named track_rewrites [pr]

* group all of create_schedule_with_vars
2024-10-20 17:45:25 +03:00
chenyu
287a198c4f increase test_strongly_connected_DAG threshold (#7131)
flaky
2024-10-17 11:08:50 -04:00
George Hotz
ded1b38b84 minor dtype cleanup [pr] (#7124)
* minor dtype cleanup [pr]

* use ptr() function
2024-10-17 17:41:23 +08:00
qazal
6acda43a2c test a rewrite of permuted reduce [pr] (#7093)
* test a rewrite of permuted reduce [pr]

* addd rewrite tracker

* expected

* passes
2024-10-16 12:49:54 +03:00
qazal
390171d686 delete SAVE_SCHEDULE=1 [pr] (#7087) 2024-10-16 07:13:20 +03:00
George Hotz
3169cb386d remove graph [pr] (#7085) 2024-10-16 11:40:07 +08:00
qazal
fb29de6cc3 split schedule to view_left and view_right [pr] (#7077)
* split schedule to view_left and view_right [pr]

* move valid
2024-10-16 03:39:38 +03:00
Louis Novy
2ac5aec66b Fix exponential complexity in _is_padding_okay [pr] (#7008)
* preliminary test

* missed Optional

* don't check for cache during recursion

* match style from st_fixup... may be marginally faster?

* pathological test case: strongly connected DAG

* move to test_schedule as this isn't really a fusion

* oops this shouldn't be edited

* Revert "oops this shouldn't be edited"

This reverts commit 487cb027dc.

* Revert "move to test_schedule as this isn't really a fusion"

This reverts commit 48d8c550ce.

* move to test_schedule as this isn't really a fusion

* ok no more merge error funny business
2024-10-14 02:34:47 +03:00
chenyu
04d9b46d51 derivative of softmax is indepedent of max (#7009)
* derivative of softmax is indepedent of max

* update test
2024-10-12 15:59:23 -04:00
chenyu
cae1c41755 test case of softmax backward kernel count (#7022) 2024-10-12 15:46:32 -04:00
qazal
7451812bbf delete AST_REWRITE ctx var (#6995) 2024-10-11 11:33:16 +03:00
qazal
20d3c2d113 unify UOps.SHAPETRACKER and UOps.SWIZZLE with UOps.VIEW (#6955)
* add UOps.VIEW

* update hardcoded asts

* update sops.gz
2024-10-09 02:00:17 +08:00
George Hotz
4df5c7a4ef move lazy to engine [pr] (#6886)
* move lazy to engine [pr]

* engine.lazy
2024-10-04 23:19:26 +08:00
George Hotz
547733e57c stunning_mnist [run_process_replay] (#6828)
* stunning_mnist [run_process_replay]

* add loss to stunning mnist
2024-10-01 15:00:48 +08:00
qazal
391497a311 schedule independent of Device [run_process_replay] (#6829) 2024-10-01 14:46:26 +08:00
qazal
0c24fec9f4 test current behavior of const schedule [run_process_replay] (#6817) 2024-09-30 21:02:01 +08:00
qazal
2ec73d6f05 push swizzle through dim change (#6801)
* push swizzle through dim change

* can this be generic

* generic version

* cleanups
2024-09-30 09:04:59 +08:00
wozeparrot
2b899164c6 no numpy (#6751) 2024-09-26 16:40:18 +08:00
qazal
8a15ccb414 start gc/mem usage tests for buffer schedule [run_process_replay] (#6737)
* gc tests for buffer schedule [run_process_replay]

* assert global counters, maybe del

* check init

* rm global counters
2024-09-26 08:26:31 +08:00
qazal
b629a7998d early assert buffer count limit [run_process_replay] (#6746)
* better error message for buffer count limit [run_process_replay]

* 3.9 needs that

* assert ScheduleItem

* new _test_buf_cnt
2024-09-26 08:24:26 +08:00
wozeparrot
c100f3d406 default threefry (#6116) 2024-09-25 17:45:13 +08:00