fitzgen commented on issue #5534:
Makes sense to me! I missed the introduction of
side_effects_idempotentso I'm not sure if the egraph case handles it too or if it's only simple-gvn. But I think this should be safe to merge either way.It is just
simple_gvnfor now, but shouldn't be hard to introduce to the egraphs stuff since it's just a predicate on the opcode, and not some deep logic that needs to be copied over. I didn't implement it just because I don't know exactly where that would go yet. Maybe you do?
jameysharp commented on issue #5534:
I think the place to use
side_effects_idempotentfor egraph optimization is inis_pure_for_egraph, defined incranelift/codegen/src/inst_predicates.rs. I'm not absolutely sure though.
Last updated: Dec 06 2025 at 06:05 UTC