assign early folding (#8093)

* assign early folding [pr]

* move to to_si

* -

* fix generate_dataset

* diff too big

* no recreation, no diff

* gzip

* new sops from tiny10

* final try
This commit is contained in:
qazal
2024-12-07 11:02:55 +02:00
committed by GitHub
parent 00ac0db9d4
commit 07b6d5cf63
6 changed files with 8 additions and 7 deletions

View File

@@ -5,9 +5,9 @@ from test.external.process_replay.process_replay import _pmap
LOGOPS = os.getenv("LOGOPS", "/tmp/sops")
def extract_ast(*args) -> bool:
def extract_ast(*args) -> None:
open(LOGOPS, "a").write(str(args[0]).replace("\n", "").replace(" ", "")+"\n")
return args[-1]
return None
if __name__ == "__main__":
_pmap("kernel", extract_ast)

View File

@@ -1,5 +1,6 @@
#!/bin/bash
export PAGE_SIZE=1
export PYTHONPATH=.
export LOGOPS=/tmp/ops
export RUN_PROCESS_REPLAY=1
rm $LOGOPS
@@ -24,5 +25,5 @@ JIT=2 BIG=1 MPS=1 python -m pytest test/test_speed_v_torch.py
# extract, sort and uniq
extra/optimization/extract_dataset.py
sort -u /tmp/ops > /tmp/sops
sort -u /tmp/ops > /tmp/sops
ls -lh /tmp/ops /tmp/sops