more efficient rest-map clearing