move some external memory circular suffix comparison to internal memory where possible