What compiler optimizations happened here?

54 points blocks2762

I’m new to rust from c++, working on a connect 4 project. I was surprised at how crazy the improvement on a release build was. The bot went from processing ~1 M nodes/s to ~5.5 M nodes/s.

How on earth?? I made sure to explicitly do references and stuff to reduce unnecessary copies, so what else could it be doing for such a drastic improvement?

https://github.com/thesilican/connect-n/blob/main/wasm/src/main.rs