Aren't most of those shenanigans done early in the VM's lifespan (as Rails boots, actions are called the first time,...), after which the world would be stable, and JIT-related caches wouldn't have to be lost?
That said, there are plenty of Rails apps that do monkey patch Rails internals, for better or worse.