egraphs-good / egglog

egraphs + datalog!
https://egraphs-good.github.io/egglog/
MIT License
458 stars 54 forks source link

SrcFile's debug should not print the whole content #449

Closed yihozhang closed 1 month ago

yihozhang commented 1 month ago

Fixes #447

Before:

> RUST_LOG=debug cargo run --release tests/python_array_optimize.egg 2>&1 >/dev/null | wc 
   26609 14906607 220858043

After:

> RUST_LOG=debug cargo run --release tests/python_array_optimize.egg 2>&1 >/dev/null | wc
   26610  788211 10508203
codspeed-hq[bot] commented 1 month ago

CodSpeed Performance Report

Merging #449 will degrade performances by 9.09%

Comparing fix-debug-print (d9e4ce0) with main (5d637f2)

Summary

⚡ 3 improvements ❌ 3 regressions ✅ 80 untouched benchmarks

:warning: Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark main fix-debug-print Change
bool 1.3 ms 1.4 ms -5.87%
combined-nested 1,025.1 µs 943.8 µs +8.61%
datatypes 589.4 µs 546.7 µs +7.81%
delete 645.6 µs 601.5 µs +7.34%
string 498.4 µs 545.5 µs -8.63%
string_quotes 432.6 µs 475.9 µs -9.09%