Scaling Mercurial at Facebook
Our code base has grown organically and its internal dependencies are very complex.So instead of cleaning up the internal dependencies, they decided to rewrite Mercurial. That is the kind of thing Facebook likes to do: for example, when PHP got too slow, they wrote a PHP compiler....