> ... We present a new approach for structuring the optimization phase of a compiler. In our approach, optimizations take the form of equality analyses that add equality information to a common intermediate representation. The optimizer works by repeatedly applying these analyses to infer equivalences between program fragments, thus saturating the intermediate representation with equalities. Once saturated, the intermediate representation encodes multiple optimized versions of the input program. At this point, a profitability heuristic picks the final optimized program from the various programs represented in the saturated representation. ...
Fig 18 shows up to a 4x gain, which seems pretty impressive
From https://arxiv.org/abs/1012.1802 we read the following about "equality saturation" which was a new term to me:
> ... We present a new approach for structuring the optimization phase of a compiler. In our approach, optimizations take the form of equality analyses that add equality information to a common intermediate representation. The optimizer works by repeatedly applying these analyses to infer equivalences between program fragments, thus saturating the intermediate representation with equalities. Once saturated, the intermediate representation encodes multiple optimized versions of the input program. At this point, a profitability heuristic picks the final optimized program from the various programs represented in the saturated representation. ...
Fig 18 shows up to a 4x gain, which seems pretty impressive
The paper says at the end:
> Our implementation is available at: https://github.com/jumerckx/Metapractice/tree/taco.
Unfortunately that URL doesn't work for me; maybe it should point to https://github.com/jumerckx/Tamagoyaki