It's debatable whether it should be doing it at all. Rounding up to the next prime might be better (if there was an efficient way to do so)