rebuild the matching