refactor: re-run eliminate_perfect_aliases! after alias_elimination! #4537
refactor: re-run eliminate_perfect_aliases! after alias_elimination! #4537AayushSabharwal wants to merge 3 commits into
eliminate_perfect_aliases! after alias_elimination! #4537Conversation
|
Why doesn't |
|
|
|
but it does have a function that runs after it to actually eliminate the aliases, right? Also, wouldn't all of these be aliases found by adding support for the fast path detecting |
Nope. This PR adds that.
I'm not sure. It's technically possible they wouldn't, but I don't know how much that would happen in practice. Once I get JuliaComputing/StateSelection.jl#81 working, I'll check if keeping this change around is worth it, since the main win from this is smaller linsolves. |
|
IMO the order we should go is
I would really like the passes we do to feel grounded and obviously correct/necessary. |
|
Yep, agreed. However, we can't delete |
|
I think there probably is a much simpler way to remove duplicate equations. |
We run
eliminate_perfect_aliases!beforealias_elimination!to (significantly) reduce the number of equations the latter pass has to process. However,alias_elimination!identifies additionalx ~ yequations which can easily be removed byeliminate_perfect_aliases!. This has resulted in better simplification on some models.