Lune

PLDI2021Top-tier venue

Hashing modulo alpha-equivalence

Krzysztof Maziarz, Tom Ellis, Alan Lawrence, Andrew W. Fitzgibbon, Simon Peyton Jones

2021Year
7Citations
3Top-tier citations

Abstract

In many applications one wants to identify identical subtrees of a program syntax tree. This identification should ideally be robust to alpha-renaming of the program, but no existing technique has been shown to achieve this with good efficiency (better than O (𝑛 2 ) in expression size). We present a new, asymptotically efficient way to hash modulo alphaequivalence. A key insight of our method is to use a weak (commutative) hash combiner at exactly one point in the construction, which admits an algorithm with O (𝑛(log 𝑛) 2 ) time complexity. We prove that the use of the commutative combiner nevertheless yields a strong hash with low collision probability. Numerical benchmarks attest to the asymptotic behaviour of the method.

• Theory of computation → Design and analysis of algorithms; • Software and its engineering;

Ask about this paper

Your agent reads all of it.

Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.

Questions to start from

Your agent calls

Luneget_paper_fulltext

Ask in Lune

Free to start. No credit card required.

lune papers fulltext f6abbf6e-a4c4-428d-a2cb-82704b85e0e7

Cited by top-tier papers3

Ask how each one uses it

Related papers

Dusk over the sea between two cliffs drawn in fine vertical lines