Make prefiltering efficient.