https://twitter.com/daisyowl/status/841802094361235456?lang=en
If you ever code something that "feels like a hack but it works," just remember that a CPU is literally a rock that we tricked into thinking.
Not to oversimplify: first you have to flatten the rock and put lightning inside it.