Quick way of deciding which chunks to generate

I’m trying to build a procedural terrain generator with chunks, and I’m having trouble with stuttering after a chunk is generated. I’ve tracked it down to the part of my code that determines what chunk to generate next. The code generates larger and larger rings of chunk coordinates from the players location and compares them against already generated chunk coordinates. I realized this can take exponentially longer and longer, is there any better way to do this?

Thanks!