Bumping the content cache from 50 entries to 2500 brings the rebuild time for this repository from 6h to 2min or so. It doesn't fix the deep stack nesting.