-
Notifications
You must be signed in to change notification settings - Fork 8
/
TODO
28 lines (28 loc) · 1.88 KB
/
TODO
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
[ ] Newtype over ClassId and abstract implementation. Only way to get ClassIds is through representation and adding
[ ] Freeze/Unfreeze implementation of Union Find with unboxed vectors
[ ] Point out module should be imported qualified, and rename emptyEG to just `empty`
[ ] Point out that we have pure functional e-graphs!!
quasi quoter or generic programming for writing fixed point expressions and patterns
Rewrite rule quasi quoter
Note: we could provide two analysis interfaces, keeping the very high level one and adding a possible low level one if necessary
Hide modules unnecessary for user like IntToIntMap
Use user-defined TrieMap as the NodeMap?
Should try to delete items from findRepr because it only ever gets bigger. Deleting items could speed things up
FindRepr is almost always at depth0, meaning the issue is with 1time in lookup times, the number of times findRepr is called, and the constant factors
Memoization for Database
Memoization for ReprUnionFind
HashSet for ENodes
Careful with collisions regarding the carefree use of intmaps+hashing...
Consider using unordered containers altogether
Drop Hashable dependency by vendoring generic hash? Can we use Uniques in GHC if we vendor this?
Memo data structure is not good enough, maybe UniqMap
UniqMap
Memoization in find / canonicalize
Memoizatiion?
Analysis should take a type level Symbol to identify it, so we can have multiple analysis for the same language
Test that e-classes are never empty
Should all nodes in maps be canonical? Or better to keep finding them when need to use? Must check which is more common, probably checking is done way less so it's better to just find them when needed
Continuous database carried in the e-graph, also updated when rebuilding... (how?)
If already reached optimal solution (cost == 1) can stop searching?
Delete represented nodes after canonicalizing the id
How to make Fix compatible with Data.Fix