Holy shit, this is an excellent tour. I want to look at constraint-based
register allocation for my next project, I think. I also wanted to see if it
were possible to synthesize a data format and short x86 opcode sequences that
would satisfy certain mathematical laws, but I did not figure out how to do
that. Maybe we should chat.<p>In particular, I love the tiny tiny Union-Find!<p><pre><code> uf = {}
def find(x):
while x in uf:
x = uf[x]
return x
def union(x,y):
x = find(x)
y = find(y)
if x != y:
uf[x] = y
return y
</code></pre>
That's even smaller than the impl I use in toy projects. Wow.<p>And thanks for linking to my DDCG posts :)