A couple of big fixes related to reuse dist/spatial locality.