Skip to content

Commit 13ca222

Browse files
Try fixing performance issue
egraphs-good/egglog#629
1 parent a09aca5 commit 13ca222

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,9 @@ crate-type = ["cdylib"]
1212
[dependencies]
1313
pyo3 = { version = "0.23.0", features = ["extension-module"] }
1414

15-
# include this bugfix https://github.com/egraphs-good/egglog/pull/625
16-
egglog = { git = "https://github.com/egraphs-good/egglog.git", rev = "d2fa5b733de0796fb187dc5a27e570d5644aa75a" }
15+
# include this bugfix https://github.com/egraphs-good/egglog/pull/629
16+
egglog = { git = "https://github.com/saulshanabrook/egg-smol.git", rev = "1e638e6" }
17+
# egglog = { path = "../egg-smol" }
1718
egglog-bridge = { git = "https://github.com/egraphs-good/egglog-backend.git", rev = "1a1f913" }
1819
core-relations = { git = "https://github.com/egraphs-good/egglog-backend.git", rev = "1a1f913" }
1920
egglog-experimental = { git = "https://github.com/egraphs-good/egglog-experimental", rev = "202078f" }
@@ -27,7 +28,9 @@ uuid = { version = "1.16.0", features = ["v4"] }
2728

2829
# Use patched version of egglog in experimental
2930
[patch.'https://github.com/egraphs-good/egglog']
30-
egglog = { git = "https://github.com/egraphs-good//egglog.git", rev = "d2fa5b733de0796fb187dc5a27e570d5644aa75a" }
31+
# egglog = { git = "https://github.com/egraphs-good//egglog.git", rev = "d2fa5b733de0796fb187dc5a27e570d5644aa75a" }
32+
# egglog = { path = "../egg-smol" }
33+
egglog = { git = "https://github.com/saulshanabrook/egg-smol.git", rev = "1e638e6" }
3134

3235
# enable debug symbols for easier profiling
3336
[profile.release]

python/egglog/exp/array_api.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1970,9 +1970,9 @@ def try_evaling(egraph: EGraph, schedule: Schedule, expr: Expr, prim_expr: Built
19701970
Try evaling the expression that will result in a primitive expression being fill.
19711971
if it fails, display the egraph and raise an error.
19721972
"""
1973-
if egraph.check_bool(expr):
1973+
try:
19741974
extracted = egraph.extract(prim_expr)
1975-
else:
1975+
except EggSmolError:
19761976
# If this primitive doesn't exist in the egraph, we need to try to create it by
19771977
# registering the expression and running the schedule
19781978
egraph.register(expr)

0 commit comments

Comments
 (0)