Improve max threads spec in legacy code