@user207421 I'm a professional software developer and am very familiar with the XY problem. This is not an XY problem. I am interested in all of the following: how it works, why it works that way, and how I can make it faster. But the question is primarily about the "how it works" part.