fitzgen commented on issue #5534:
Makes sense to me! I missed the introduction of
side_effects_idempotent
so 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_gvn
for 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_idempotent
for egraph optimization is inis_pure_for_egraph
, defined incranelift/codegen/src/inst_predicates.rs
. I'm not absolutely sure though.
Last updated: Dec 23 2024 at 12:05 UTC