Search optimizations: prevnext cache improvements